From ab6d52a9f814b6f93558ab81bc92408e9928a223 Mon Sep 17 00:00:00 2001 From: Anthony Stanton Date: Fri, 20 Apr 2018 09:47:00 +0200 Subject: [PATCH] Bump terraform-provider-aws and aws-sdk-go --- .../aws/aws-sdk-go/aws/client/client.go | 6 + .../aws-sdk-go/aws/client/default_retryer.go | 28 +- .../aws/aws-sdk-go/aws/client/logger.go | 4 + .../github.com/aws/aws-sdk-go/aws/config.go | 22 + .../aws-sdk-go/aws/corehandlers/handlers.go | 28 +- .../aws-sdk-go/aws/corehandlers/user_agent.go | 37 + .../aws/aws-sdk-go/aws/defaults/defaults.go | 1 + .../aws/aws-sdk-go/aws/ec2metadata/service.go | 24 + .../aws/aws-sdk-go/aws/endpoints/decode.go | 24 - .../aws/aws-sdk-go/aws/endpoints/defaults.go | 345 +- .../aws/aws-sdk-go/aws/endpoints/endpoints.go | 4 + .../aws/aws-sdk-go/aws/endpoints/v3model.go | 12 +- .../aws-sdk-go/aws/request/offset_reader.go | 4 +- .../aws/aws-sdk-go/aws/request/request.go | 53 +- .../aws/aws-sdk-go/aws/session/session.go | 24 +- .../aws/aws-sdk-go/aws/signer/v4/v4.go | 24 +- vendor/github.com/aws/aws-sdk-go/aws/types.go | 83 + .../github.com/aws/aws-sdk-go/aws/version.go | 2 +- .../aws/aws-sdk-go/internal/sdkio/io_go1.6.go | 10 + .../aws/aws-sdk-go/internal/sdkio/io_go1.7.go | 12 + .../internal/sdkrand/locked_source.go | 29 + .../private/protocol/ec2query/build.go | 2 +- .../private/protocol/query/build.go | 2 +- .../aws/aws-sdk-go/service/acm/api.go | 650 +- .../aws/aws-sdk-go/service/acm/doc.go | 2 +- .../aws/aws-sdk-go/service/acm/errors.go | 13 +- .../aws/aws-sdk-go/service/apigateway/api.go | 910 +- .../service/applicationautoscaling/api.go | 115 +- .../service/applicationautoscaling/doc.go | 13 +- .../service/applicationautoscaling/service.go | 6 +- .../aws/aws-sdk-go/service/appsync/api.go | 54 +- .../aws/aws-sdk-go/service/appsync/service.go | 6 +- .../aws/aws-sdk-go/service/athena/api.go | 22 +- .../aws/aws-sdk-go/service/autoscaling/api.go | 274 +- .../aws/aws-sdk-go/service/autoscaling/doc.go | 7 +- .../aws-sdk-go/service/autoscaling/errors.go | 6 + .../aws/aws-sdk-go/service/batch/api.go | 32 +- .../aws/aws-sdk-go/service/cloud9/api.go | 20 +- .../aws-sdk-go/service/cloudformation/api.go | 223 +- .../aws/aws-sdk-go/service/cloudfront/api.go | 13595 ++++++++++----- .../aws/aws-sdk-go/service/cloudfront/doc.go | 2 +- .../aws-sdk-go/service/cloudfront/errors.go | 134 + .../aws-sdk-go/service/cloudfront/service.go | 2 +- .../aws/aws-sdk-go/service/cloudtrail/api.go | 28 +- .../aws/aws-sdk-go/service/cloudwatch/api.go | 634 +- .../service/cloudwatchevents/api.go | 237 +- .../aws-sdk-go/service/cloudwatchlogs/api.go | 66 +- .../aws/aws-sdk-go/service/codebuild/api.go | 274 +- .../aws/aws-sdk-go/service/codebuild/doc.go | 2 + .../aws/aws-sdk-go/service/codecommit/api.go | 465 +- .../aws/aws-sdk-go/service/codecommit/doc.go | 5 + .../aws-sdk-go/service/codecommit/errors.go | 109 + .../aws/aws-sdk-go/service/codedeploy/api.go | 80 +- .../aws-sdk-go/service/codepipeline/api.go | 54 +- .../aws-sdk-go/service/cognitoidentity/api.go | 36 +- .../service/cognitoidentityprovider/api.go | 190 +- .../aws-sdk-go/service/configservice/api.go | 5314 ++++-- .../aws-sdk-go/service/configservice/doc.go | 12 +- .../service/configservice/errors.go | 35 +- .../service/databasemigrationservice/api.go | 88 +- .../aws/aws-sdk-go/service/dax/api.go | 42 +- .../aws/aws-sdk-go/service/devicefarm/api.go | 1986 ++- .../aws-sdk-go/service/directconnect/api.go | 88 +- .../service/directoryservice/api.go | 80 +- .../aws/aws-sdk-go/service/dynamodb/api.go | 723 +- .../aws/aws-sdk-go/service/dynamodb/errors.go | 30 +- .../aws/aws-sdk-go/service/ec2/api.go | 758 +- .../aws-sdk-go/service/ec2/customizations.go | 53 + .../aws/aws-sdk-go/service/ecr/api.go | 82 +- .../aws/aws-sdk-go/service/ecr/doc.go | 10 +- .../aws/aws-sdk-go/service/ecr/errors.go | 2 +- .../aws/aws-sdk-go/service/ecs/api.go | 660 +- .../aws/aws-sdk-go/service/ecs/errors.go | 2 +- .../aws/aws-sdk-go/service/efs/api.go | 22 +- .../aws/aws-sdk-go/service/elasticache/api.go | 80 +- .../service/elasticbeanstalk/api.go | 333 +- .../service/elasticbeanstalk/errors.go | 2 +- .../service/elasticsearchservice/api.go | 188 +- .../service/elastictranscoder/api.go | 34 +- .../aws/aws-sdk-go/service/elb/api.go | 58 +- .../aws/aws-sdk-go/service/elbv2/api.go | 161 +- .../aws/aws-sdk-go/service/elbv2/errors.go | 4 +- .../aws/aws-sdk-go/service/emr/api.go | 54 +- .../aws/aws-sdk-go/service/firehose/api.go | 14 +- .../aws/aws-sdk-go/service/gamelift/api.go | 300 +- .../aws/aws-sdk-go/service/gamelift/doc.go | 8 +- .../aws/aws-sdk-go/service/glacier/api.go | 90 +- .../aws-sdk-go/service/glacier/treehash.go | 6 +- .../aws/aws-sdk-go/service/glue/api.go | 174 +- .../aws/aws-sdk-go/service/guardduty/api.go | 74 +- .../aws-sdk-go/service/guardduty/service.go | 6 +- .../aws/aws-sdk-go/service/iam/api.go | 1816 +- .../aws/aws-sdk-go/service/inspector/api.go | 66 +- .../aws/aws-sdk-go/service/iot/api.go | 345 +- .../aws/aws-sdk-go/service/iot/service.go | 6 +- .../aws/aws-sdk-go/service/kinesis/api.go | 46 +- .../aws/aws-sdk-go/service/kms/api.go | 70 +- .../aws/aws-sdk-go/service/lambda/api.go | 144 +- .../service/lexmodelbuildingservice/api.go | 10787 ++++++++++++ .../service/lexmodelbuildingservice/doc.go | 30 + .../service/lexmodelbuildingservice/errors.go | 61 + .../lexmodelbuildingservice/service.go | 97 + .../aws/aws-sdk-go/service/lightsail/api.go | 771 +- .../aws-sdk-go/service/lightsail/errors.go | 4 +- .../aws/aws-sdk-go/service/mediastore/api.go | 20 +- .../aws-sdk-go/service/mediastore/service.go | 6 +- .../aws/aws-sdk-go/service/mq/api.go | 34 +- .../aws/aws-sdk-go/service/mq/service.go | 6 +- .../aws/aws-sdk-go/service/opsworks/api.go | 148 +- .../aws-sdk-go/service/organizations/api.go | 14217 ++++++++++++++++ .../aws-sdk-go/service/organizations/doc.go | 137 + .../service/organizations/errors.go | 455 + .../service/organizations/service.go | 95 + .../aws/aws-sdk-go/service/rds/api.go | 220 +- .../aws/aws-sdk-go/service/redshift/api.go | 219 +- .../aws/aws-sdk-go/service/route53/api.go | 121 +- .../aws/aws-sdk-go/service/s3/api.go | 297 +- .../aws/aws-sdk-go/service/s3/body_hash.go | 249 + .../aws/aws-sdk-go/service/s3/content_md5.go | 36 - .../aws-sdk-go/service/s3/customizations.go | 6 + .../aws-sdk-go/service/s3/statusok_error.go | 3 +- .../aws-sdk-go/service/servicecatalog/api.go | 286 +- .../service/servicediscovery/api.go | 382 +- .../service/servicediscovery/errors.go | 4 + .../aws/aws-sdk-go/service/ses/api.go | 140 +- .../aws/aws-sdk-go/service/ses/service.go | 6 +- .../aws/aws-sdk-go/service/sfn/api.go | 38 +- .../aws/aws-sdk-go/service/simpledb/api.go | 20 +- .../aws/aws-sdk-go/service/sns/api.go | 60 +- .../aws/aws-sdk-go/service/sqs/api.go | 40 +- .../aws/aws-sdk-go/service/ssm/api.go | 217 +- .../aws/aws-sdk-go/service/sts/api.go | 151 +- .../aws/aws-sdk-go/service/waf/api.go | 662 +- .../aws/aws-sdk-go/service/waf/errors.go | 26 + .../aws/aws-sdk-go/service/wafregional/api.go | 447 +- .../aws-sdk-go/service/wafregional/errors.go | 26 + .../terraform-provider-aws/CHANGELOG.md | 202 + .../terraform-provider-aws/aws/arn.go | 26 - ...nt_distribution_configuration_structure.go | 23 +- .../terraform-provider-aws/aws/config.go | 37 +- .../aws/data_source_aws_ami.go | 14 +- .../aws/data_source_aws_ami_ids.go | 3 +- .../aws/data_source_aws_availability_zones.go | 30 +- ...data_source_aws_billing_service_account.go | 11 +- ...a_source_aws_cloudtrail_service_account.go | 10 +- .../aws/data_source_aws_db_instance.go | 7 +- .../aws/data_source_aws_dynamodb_table.go | 14 + ...ce_aws_elastic_beanstalk_solution_stack.go | 14 +- .../data_source_aws_elasticache_cluster.go | 12 +- .../data_source_aws_elb_service_account.go | 10 +- .../data_source_aws_iam_policy_document.go | 18 +- .../aws/data_source_aws_iam_role.go | 5 + .../data_source_aws_iam_server_certificate.go | 28 +- .../aws/data_source_aws_instance.go | 23 +- .../aws/data_source_aws_kms_key.go | 110 + ...ata_source_aws_redshift_service_account.go | 10 +- .../aws/data_source_aws_s3_bucket.go | 8 +- .../aws/data_source_aws_security_group.go | 11 +- .../data_source_aws_vpc_endpoint_service.go | 14 +- .../aws/diff_suppress_funcs.go | 4 + .../terraform-provider-aws/aws/provider.go | 33 +- .../aws/resource_aws_acm_certificate.go | 14 +- .../aws/resource_aws_ami.go | 4 - .../aws/resource_aws_api_gateway_api_key.go | 3 +- .../resource_aws_api_gateway_authorizer.go | 106 +- ...urce_aws_api_gateway_client_certificate.go | 4 +- .../resource_aws_api_gateway_deployment.go | 15 +- .../resource_aws_api_gateway_integration.go | 37 +- ...ce_aws_api_gateway_integration_response.go | 4 +- .../aws/resource_aws_api_gateway_method.go | 2 +- ...esource_aws_api_gateway_method_response.go | 2 +- .../aws/resource_aws_api_gateway_rest_api.go | 32 +- .../resource_aws_api_gateway_usage_plan.go | 11 +- .../aws/resource_aws_api_gateway_vpc_link.go | 2 +- .../aws/resource_aws_appautoscaling_policy.go | 25 +- .../aws/resource_aws_appsync_datasource.go | 323 + .../aws/resource_aws_appsync_graphql_api.go | 4 + .../aws/resource_aws_autoscaling_group.go | 42 +- .../aws/resource_aws_autoscaling_policy.go | 178 +- .../resource_aws_batch_compute_environment.go | 131 +- .../aws/resource_aws_batch_job_queue.go | 83 +- .../resource_aws_cloud9_environment_ec2.go | 15 +- .../aws/resource_aws_cloudformation_stack.go | 1 - .../resource_aws_cloudfront_distribution.go | 52 +- ...e_aws_cloudfront_origin_access_identity.go | 10 +- .../aws/resource_aws_codebuild_project.go | 260 +- .../aws/resource_aws_codecommit_repository.go | 28 +- ...source_aws_codedeploy_deployment_config.go | 20 +- ...esource_aws_codedeploy_deployment_group.go | 191 +- .../aws/resource_aws_codepipeline.go | 84 +- ..._cognito_identity_pool_roles_attachment.go | 32 +- .../aws/resource_aws_cognito_user_pool.go | 66 +- .../resource_aws_cognito_user_pool_client.go | 9 +- .../aws/resource_aws_config_config_rule.go | 14 +- .../resource_aws_config_delivery_channel.go | 2 +- .../aws/resource_aws_db_event_subscription.go | 125 +- .../aws/resource_aws_db_instance.go | 72 +- .../aws/resource_aws_db_option_group.go | 69 +- .../aws/resource_aws_db_parameter_group.go | 69 +- .../aws/resource_aws_db_security_group.go | 71 +- .../aws/resource_aws_db_subnet_group.go | 66 +- .../aws/resource_aws_dms_endpoint.go | 13 +- .../resource_aws_dms_replication_instance.go | 3 +- ...source_aws_dms_replication_subnet_group.go | 12 +- .../aws/resource_aws_dms_replication_task.go | 6 +- .../aws/resource_aws_dx_connection.go | 2 +- .../aws/resource_aws_dx_lag.go | 2 +- .../aws/resource_aws_dynamodb_table.go | 94 +- .../aws/resource_aws_dynamodb_table_item.go | 4 +- .../aws/resource_aws_ebs_snapshot.go | 12 +- .../aws/resource_aws_ecs_service.go | 22 +- .../aws/resource_aws_ecs_task_definition.go | 6 +- .../aws/resource_aws_efs_file_system.go | 24 +- .../aws/resource_aws_eip.go | 12 +- .../aws/resource_aws_eip_association.go | 3 + ...ource_aws_elastic_beanstalk_environment.go | 75 + .../aws/resource_aws_elasticache_cluster.go | 356 +- ...ource_aws_elasticache_replication_group.go | 157 +- ...s_elasticache_replication_group_migrate.go | 59 + .../aws/resource_aws_elasticsearch_domain.go | 56 +- .../aws/resource_aws_elb.go | 5 +- .../aws/resource_aws_emr_cluster.go | 349 +- .../aws/resource_aws_emr_instance_group.go | 2 +- ...resource_aws_emr_security_configuration.go | 29 +- .../aws/resource_aws_gamelift_build.go | 11 +- .../aws/resource_aws_guardduty_ipset.go | 16 +- .../resource_aws_guardduty_threatintelset.go | 16 +- .../aws/resource_aws_iam_account_alias.go | 6 +- .../aws/resource_aws_iam_policy_attachment.go | 15 +- .../aws/resource_aws_iam_role.go | 30 + .../resource_aws_iam_server_certificate.go | 24 +- .../aws/resource_aws_iam_user.go | 24 +- .../resource_aws_iam_user_login_profile.go | 96 +- .../aws/resource_aws_iam_user_policy.go | 39 +- .../aws/resource_aws_iam_user_ssh_key.go | 23 +- .../aws/resource_aws_instance.go | 59 +- .../aws/resource_aws_iot_thing.go | 162 + .../aws/resource_aws_key_pair.go | 24 +- ...ce_aws_kinesis_firehose_delivery_stream.go | 331 +- .../aws/resource_aws_kinesis_stream.go | 26 +- .../aws/resource_aws_kms_alias.go | 16 +- .../aws/resource_aws_kms_grant.go | 540 + .../aws/resource_aws_kms_key.go | 26 +- .../aws/resource_aws_lambda_alias.go | 1 + .../aws/resource_aws_lambda_function.go | 119 +- .../aws/resource_aws_launch_configuration.go | 106 +- .../aws/resource_aws_lb.go | 207 +- ...esource_aws_lb_cookie_stickiness_policy.go | 16 +- .../aws/resource_aws_lb_listener.go | 66 +- .../aws/resource_aws_lb_listener_rule.go | 12 +- .../aws/resource_aws_lb_target_group.go | 102 +- .../aws/resource_aws_network_acl.go | 33 +- .../aws/resource_aws_network_interface.go | 4 +- ...source_aws_network_interface_attachment.go | 4 +- .../aws/resource_aws_opsworks_application.go | 28 +- .../aws/resource_aws_opsworks_instance.go | 125 +- .../aws/resource_aws_opsworks_permission.go | 27 +- .../aws/resource_aws_organizations_account.go | 243 + ...resource_aws_organizations_organization.go | 105 + .../aws/resource_aws_rds_cluster.go | 70 +- .../aws/resource_aws_rds_cluster_instance.go | 37 +- ...esource_aws_rds_cluster_parameter_group.go | 68 +- .../aws/resource_aws_redshift_cluster.go | 47 +- .../aws/resource_aws_redshift_subnet_group.go | 29 +- .../aws/resource_aws_route.go | 13 +- .../aws/resource_aws_route53_health_check.go | 14 +- .../aws/resource_aws_route53_record.go | 76 +- .../aws/resource_aws_route53_zone.go | 7 +- .../aws/resource_aws_s3_bucket.go | 99 +- .../aws/resource_aws_s3_bucket_object.go | 133 +- .../aws/resource_aws_security_group.go | 110 +- .../aws/resource_aws_security_group_rule.go | 14 +- .../resource_aws_servicecatalog_portfolio.go | 7 +- .../aws/resource_aws_ses_domain_identity.go | 15 +- .../aws/resource_aws_ses_event_destination.go | 55 +- ...rce_aws_ses_identity_notification_topic.go | 136 + .../aws/resource_aws_ses_template.go | 7 +- .../aws/resource_aws_sfn_activity.go | 2 +- .../aws/resource_aws_sfn_state_machine.go | 2 +- .../aws/resource_aws_sns_topic.go | 9 +- .../resource_aws_sns_topic_subscription.go | 17 +- .../aws/resource_aws_spot_fleet_request.go | 59 +- .../aws/resource_aws_spot_instance_request.go | 2 +- .../aws/resource_aws_sqs_queue.go | 14 +- .../aws/resource_aws_ssm_activation.go | 12 +- .../aws/resource_aws_ssm_association.go | 17 +- .../aws/resource_aws_ssm_document.go | 58 +- ...ource_aws_ssm_maintenance_window_target.go | 28 +- ...esource_aws_ssm_maintenance_window_task.go | 2 +- .../aws/resource_aws_ssm_parameter.go | 136 +- .../aws/resource_aws_vpc_endpoint.go | 21 +- .../resource_aws_vpc_peering_connection.go | 24 +- .../aws/resource_aws_waf_geo_match_set.go | 157 + .../aws/resource_aws_waf_rate_based_rule.go | 39 +- .../aws/resource_aws_waf_regex_match_set.go | 175 + .../aws/resource_aws_waf_regex_pattern_set.go | 144 + .../aws/resource_aws_waf_rule.go | 62 +- .../aws/resource_aws_waf_rule_group.go | 187 + .../resource_aws_waf_size_constraint_set.go | 104 +- .../aws/resource_aws_waf_web_acl.go | 13 +- .../resource_aws_wafregional_geo_match_set.go | 160 + ...esource_aws_wafregional_rate_based_rule.go | 195 + ...esource_aws_wafregional_regex_match_set.go | 179 + ...ource_aws_wafregional_regex_pattern_set.go | 147 + .../aws/resource_aws_wafregional_rule.go | 188 + .../resource_aws_wafregional_rule_group.go | 191 + ...rce_aws_wafregional_size_constraint_set.go | 135 + ...aws_wafregional_sql_injection_match_set.go | 233 + .../aws/resource_aws_wafregional_web_acl.go | 266 + ...rce_aws_wafregional_web_acl_association.go | 128 + .../resource_aws_wafregional_xss_match_set.go | 175 + .../terraform-provider-aws/aws/structure.go | 327 +- .../aws/tagsBeanstalk.go | 11 +- .../terraform-provider-aws/aws/tagsSSM.go | 117 + .../terraform-provider-aws/aws/utils.go | 7 + .../terraform-provider-aws/aws/validators.go | 836 +- .../terraform-provider-aws/aws/waf_helpers.go | 364 + vendor/vendor.json | 978 +- 318 files changed, 62560 insertions(+), 14874 deletions(-) create mode 100644 vendor/github.com/aws/aws-sdk-go/aws/corehandlers/user_agent.go create mode 100644 vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.6.go create mode 100644 vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.7.go create mode 100644 vendor/github.com/aws/aws-sdk-go/internal/sdkrand/locked_source.go create mode 100644 vendor/github.com/aws/aws-sdk-go/service/lexmodelbuildingservice/api.go create mode 100644 vendor/github.com/aws/aws-sdk-go/service/lexmodelbuildingservice/doc.go create mode 100644 vendor/github.com/aws/aws-sdk-go/service/lexmodelbuildingservice/errors.go create mode 100644 vendor/github.com/aws/aws-sdk-go/service/lexmodelbuildingservice/service.go create mode 100644 vendor/github.com/aws/aws-sdk-go/service/organizations/api.go create mode 100644 vendor/github.com/aws/aws-sdk-go/service/organizations/doc.go create mode 100644 vendor/github.com/aws/aws-sdk-go/service/organizations/errors.go create mode 100644 vendor/github.com/aws/aws-sdk-go/service/organizations/service.go create mode 100644 vendor/github.com/aws/aws-sdk-go/service/s3/body_hash.go delete mode 100644 vendor/github.com/aws/aws-sdk-go/service/s3/content_md5.go delete mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/arn.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_kms_key.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_appsync_datasource.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elasticache_replication_group_migrate.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iot_thing.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kms_grant.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_organizations_account.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_organizations_organization.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ses_identity_notification_topic.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_geo_match_set.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_regex_match_set.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_regex_pattern_set.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_rule_group.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_geo_match_set.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_rate_based_rule.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_regex_match_set.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_regex_pattern_set.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_rule.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_rule_group.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_size_constraint_set.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_sql_injection_match_set.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_web_acl.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_web_acl_association.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_xss_match_set.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/tagsSSM.go create mode 100644 vendor/github.com/terraform-providers/terraform-provider-aws/aws/waf_helpers.go diff --git a/vendor/github.com/aws/aws-sdk-go/aws/client/client.go b/vendor/github.com/aws/aws-sdk-go/aws/client/client.go index 788fe6e279b2..3271a18e80e1 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/client/client.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/client/client.go @@ -15,6 +15,12 @@ type Config struct { Endpoint string SigningRegion string SigningName string + + // States that the signing name did not come from a modeled source but + // was derived based on other data. Used by service client constructors + // to determine if the signin name can be overriden based on metadata the + // service has. + SigningNameDerived bool } // ConfigProvider provides a generic way for a service client to receive diff --git a/vendor/github.com/aws/aws-sdk-go/aws/client/default_retryer.go b/vendor/github.com/aws/aws-sdk-go/aws/client/default_retryer.go index 63d2df67c63e..a397b0d044c7 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/client/default_retryer.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/client/default_retryer.go @@ -1,12 +1,11 @@ package client import ( - "math/rand" "strconv" - "sync" "time" "github.com/aws/aws-sdk-go/aws/request" + "github.com/aws/aws-sdk-go/internal/sdkrand" ) // DefaultRetryer implements basic retry logic using exponential backoff for @@ -31,8 +30,6 @@ func (d DefaultRetryer) MaxRetries() int { return d.NumMaxRetries } -var seededRand = rand.New(&lockedSource{src: rand.NewSource(time.Now().UnixNano())}) - // RetryRules returns the delay duration before retrying this request again func (d DefaultRetryer) RetryRules(r *request.Request) time.Duration { // Set the upper limit of delay in retrying at ~five minutes @@ -53,7 +50,7 @@ func (d DefaultRetryer) RetryRules(r *request.Request) time.Duration { retryCount = 13 } - delay := (1 << uint(retryCount)) * (seededRand.Intn(minTime) + minTime) + delay := (1 << uint(retryCount)) * (sdkrand.SeededRand.Intn(minTime) + minTime) return time.Duration(delay) * time.Millisecond } @@ -65,7 +62,7 @@ func (d DefaultRetryer) ShouldRetry(r *request.Request) bool { return *r.Retryable } - if r.HTTPResponse.StatusCode >= 500 { + if r.HTTPResponse.StatusCode >= 500 && r.HTTPResponse.StatusCode != 501 { return true } return r.IsErrorRetryable() || d.shouldThrottle(r) @@ -117,22 +114,3 @@ func canUseRetryAfterHeader(r *request.Request) bool { return true } - -// lockedSource is a thread-safe implementation of rand.Source -type lockedSource struct { - lk sync.Mutex - src rand.Source -} - -func (r *lockedSource) Int63() (n int64) { - r.lk.Lock() - n = r.src.Int63() - r.lk.Unlock() - return -} - -func (r *lockedSource) Seed(seed int64) { - r.lk.Lock() - r.src.Seed(seed) - r.lk.Unlock() -} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/client/logger.go b/vendor/github.com/aws/aws-sdk-go/aws/client/logger.go index 1f39c91f2e99..e223c54cc6c1 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/client/logger.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/client/logger.go @@ -46,6 +46,7 @@ func (reader *teeReaderCloser) Close() error { func logRequest(r *request.Request) { logBody := r.Config.LogLevel.Matches(aws.LogDebugWithHTTPBody) + bodySeekable := aws.IsReaderSeekable(r.Body) dumpedBody, err := httputil.DumpRequestOut(r.HTTPRequest, logBody) if err != nil { r.Config.Logger.Log(fmt.Sprintf(logReqErrMsg, r.ClientInfo.ServiceName, r.Operation.Name, err)) @@ -53,6 +54,9 @@ func logRequest(r *request.Request) { } if logBody { + if !bodySeekable { + r.SetReaderBody(aws.ReadSeekCloser(r.HTTPRequest.Body)) + } // Reset the request body because dumpRequest will re-wrap the r.HTTPRequest's // Body as a NoOpCloser and will not be reset after read by the HTTP // client reader. diff --git a/vendor/github.com/aws/aws-sdk-go/aws/config.go b/vendor/github.com/aws/aws-sdk-go/aws/config.go index 4fd0d072474d..5421b5d4e9ba 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/config.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/config.go @@ -151,6 +151,15 @@ type Config struct { // with accelerate. S3UseAccelerate *bool + // S3DisableContentMD5Validation config option is temporarily disabled, + // For S3 GetObject API calls, #1837. + // + // Set this to `true` to disable the S3 service client from automatically + // adding the ContentMD5 to S3 Object Put and Upload API calls. This option + // will also disable the SDK from performing object ContentMD5 validation + // on GetObject API calls. + S3DisableContentMD5Validation *bool + // Set this to `true` to disable the EC2Metadata client from overriding the // default http.Client's Timeout. This is helpful if you do not want the // EC2Metadata client to create a new http.Client. This options is only @@ -336,6 +345,15 @@ func (c *Config) WithS3Disable100Continue(disable bool) *Config { func (c *Config) WithS3UseAccelerate(enable bool) *Config { c.S3UseAccelerate = &enable return c + +} + +// WithS3DisableContentMD5Validation sets a config +// S3DisableContentMD5Validation value returning a Config pointer for chaining. +func (c *Config) WithS3DisableContentMD5Validation(enable bool) *Config { + c.S3DisableContentMD5Validation = &enable + return c + } // WithUseDualStack sets a config UseDualStack value returning a Config @@ -435,6 +453,10 @@ func mergeInConfig(dst *Config, other *Config) { dst.S3UseAccelerate = other.S3UseAccelerate } + if other.S3DisableContentMD5Validation != nil { + dst.S3DisableContentMD5Validation = other.S3DisableContentMD5Validation + } + if other.UseDualStack != nil { dst.UseDualStack = other.UseDualStack } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go b/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go index 495e3ef62ca9..cfcddf3dc52b 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go @@ -3,12 +3,10 @@ package corehandlers import ( "bytes" "fmt" - "io" "io/ioutil" "net/http" "net/url" "regexp" - "runtime" "strconv" "time" @@ -36,18 +34,13 @@ var BuildContentLengthHandler = request.NamedHandler{Name: "core.BuildContentLen if slength := r.HTTPRequest.Header.Get("Content-Length"); slength != "" { length, _ = strconv.ParseInt(slength, 10, 64) } else { - switch body := r.Body.(type) { - case nil: - length = 0 - case lener: - length = int64(body.Len()) - case io.Seeker: - r.BodyStart, _ = body.Seek(0, 1) - end, _ := body.Seek(0, 2) - body.Seek(r.BodyStart, 0) // make sure to seek back to original location - length = end - r.BodyStart - default: - panic("Cannot get length of body, must provide `ContentLength`") + if r.Body != nil { + var err error + length, err = aws.SeekerLen(r.Body) + if err != nil { + r.Error = awserr.New(request.ErrCodeSerialization, "failed to get request body's length", err) + return + } } } @@ -60,13 +53,6 @@ var BuildContentLengthHandler = request.NamedHandler{Name: "core.BuildContentLen } }} -// SDKVersionUserAgentHandler is a request handler for adding the SDK Version to the user agent. -var SDKVersionUserAgentHandler = request.NamedHandler{ - Name: "core.SDKVersionUserAgentHandler", - Fn: request.MakeAddToUserAgentHandler(aws.SDKName, aws.SDKVersion, - runtime.Version(), runtime.GOOS, runtime.GOARCH), -} - var reStatusCode = regexp.MustCompile(`^(\d{3})`) // ValidateReqSigHandler is a request handler to ensure that the request's diff --git a/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/user_agent.go b/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/user_agent.go new file mode 100644 index 000000000000..a15f496bc08d --- /dev/null +++ b/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/user_agent.go @@ -0,0 +1,37 @@ +package corehandlers + +import ( + "os" + "runtime" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/request" +) + +// SDKVersionUserAgentHandler is a request handler for adding the SDK Version +// to the user agent. +var SDKVersionUserAgentHandler = request.NamedHandler{ + Name: "core.SDKVersionUserAgentHandler", + Fn: request.MakeAddToUserAgentHandler(aws.SDKName, aws.SDKVersion, + runtime.Version(), runtime.GOOS, runtime.GOARCH), +} + +const execEnvVar = `AWS_EXECUTION_ENV` +const execEnvUAKey = `exec_env` + +// AddHostExecEnvUserAgentHander is a request handler appending the SDK's +// execution environment to the user agent. +// +// If the environment variable AWS_EXECUTION_ENV is set, its value will be +// appended to the user agent string. +var AddHostExecEnvUserAgentHander = request.NamedHandler{ + Name: "core.AddHostExecEnvUserAgentHander", + Fn: func(r *request.Request) { + v := os.Getenv(execEnvVar) + if len(v) == 0 { + return + } + + request.AddToUserAgent(r, execEnvUAKey+"/"+v) + }, +} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/defaults/defaults.go b/vendor/github.com/aws/aws-sdk-go/aws/defaults/defaults.go index 2cb08182fb03..3cf1036b625a 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/defaults/defaults.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/defaults/defaults.go @@ -73,6 +73,7 @@ func Handlers() request.Handlers { handlers.Validate.PushBackNamed(corehandlers.ValidateEndpointHandler) handlers.Validate.AfterEachFn = request.HandlerListStopOnError handlers.Build.PushBackNamed(corehandlers.SDKVersionUserAgentHandler) + handlers.Build.PushBackNamed(corehandlers.AddHostExecEnvUserAgentHander) handlers.Build.AfterEachFn = request.HandlerListStopOnError handlers.Sign.PushBackNamed(corehandlers.BuildContentLengthHandler) handlers.Send.PushBackNamed(corehandlers.ValidateReqSigHandler) diff --git a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go b/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go index 5b4379dbd8ed..ef5f73292bac 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go @@ -1,5 +1,10 @@ // Package ec2metadata provides the client for making API calls to the // EC2 Metadata service. +// +// This package's client can be disabled completely by setting the environment +// variable "AWS_EC2_METADATA_DISABLED=true". This environment variable set to +// true instructs the SDK to disable the EC2 Metadata client. The client cannot +// be used while the environemnt variable is set to true, (case insensitive). package ec2metadata import ( @@ -7,17 +12,21 @@ import ( "errors" "io" "net/http" + "os" + "strings" "time" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/aws/client" "github.com/aws/aws-sdk-go/aws/client/metadata" + "github.com/aws/aws-sdk-go/aws/corehandlers" "github.com/aws/aws-sdk-go/aws/request" ) // ServiceName is the name of the service. const ServiceName = "ec2metadata" +const disableServiceEnvVar = "AWS_EC2_METADATA_DISABLED" // A EC2Metadata is an EC2 Metadata service Client. type EC2Metadata struct { @@ -75,6 +84,21 @@ func NewClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegio svc.Handlers.Validate.Clear() svc.Handlers.Validate.PushBack(validateEndpointHandler) + // Disable the EC2 Metadata service if the environment variable is set. + // This shortcirctes the service's functionality to always fail to send + // requests. + if strings.ToLower(os.Getenv(disableServiceEnvVar)) == "true" { + svc.Handlers.Send.SwapNamed(request.NamedHandler{ + Name: corehandlers.SendHandler.Name, + Fn: func(r *request.Request) { + r.Error = awserr.New( + request.CanceledErrorCode, + "EC2 IMDS access disabled via "+disableServiceEnvVar+" env var", + nil) + }, + }) + } + // Add additional options to the service config for _, option := range opts { option(svc.Client) diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/decode.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/decode.go index 6dc035a5357b..74f72de07356 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/decode.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/decode.go @@ -4,7 +4,6 @@ import ( "encoding/json" "fmt" "io" - "os" "github.com/aws/aws-sdk-go/aws/awserr" ) @@ -85,34 +84,11 @@ func decodeV3Endpoints(modelDef modelDefinition, opts DecodeModelOptions) (Resol custAddEC2Metadata(p) custAddS3DualStack(p) custRmIotDataService(p) - - custFixCloudHSMv2SigningName(p) } return ps, nil } -func custFixCloudHSMv2SigningName(p *partition) { - // Workaround for aws/aws-sdk-go#1745 until the endpoint model can be - // fixed upstream. TODO remove this once the endpoints model is updated. - - s, ok := p.Services["cloudhsmv2"] - if !ok { - return - } - - if len(s.Defaults.CredentialScope.Service) != 0 { - fmt.Fprintf(os.Stderr, "cloudhsmv2 signing name already set, ignoring override.\n") - // If the value is already set don't override - return - } - - s.Defaults.CredentialScope.Service = "cloudhsm" - fmt.Fprintf(os.Stderr, "cloudhsmv2 signing name not set, overriding.\n") - - p.Services["cloudhsmv2"] = s -} - func custAddS3DualStack(p *partition) { if p.ID != "aws" { return diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go index 3cdfabe656b4..94934998a37e 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go @@ -45,6 +45,7 @@ const ( // Service identifiers const ( + A4bServiceID = "a4b" // A4b. AcmServiceID = "acm" // Acm. ApiPricingServiceID = "api.pricing" // ApiPricing. ApigatewayServiceID = "apigateway" // Apigateway. @@ -55,6 +56,8 @@ const ( AutoscalingPlansServiceID = "autoscaling-plans" // AutoscalingPlans. BatchServiceID = "batch" // Batch. BudgetsServiceID = "budgets" // Budgets. + CeServiceID = "ce" // Ce. + Cloud9ServiceID = "cloud9" // Cloud9. ClouddirectoryServiceID = "clouddirectory" // Clouddirectory. CloudformationServiceID = "cloudformation" // Cloudformation. CloudfrontServiceID = "cloudfront" // Cloudfront. @@ -70,6 +73,7 @@ const ( CognitoIdentityServiceID = "cognito-identity" // CognitoIdentity. CognitoIdpServiceID = "cognito-idp" // CognitoIdp. CognitoSyncServiceID = "cognito-sync" // CognitoSync. + ComprehendServiceID = "comprehend" // Comprehend. ConfigServiceID = "config" // Config. CurServiceID = "cur" // Cur. DatapipelineServiceID = "datapipeline" // Datapipeline. @@ -99,6 +103,7 @@ const ( GlacierServiceID = "glacier" // Glacier. GlueServiceID = "glue" // Glue. GreengrassServiceID = "greengrass" // Greengrass. + GuarddutyServiceID = "guardduty" // Guardduty. HealthServiceID = "health" // Health. IamServiceID = "iam" // Iam. ImportexportServiceID = "importexport" // Importexport. @@ -113,6 +118,9 @@ const ( LogsServiceID = "logs" // Logs. MachinelearningServiceID = "machinelearning" // Machinelearning. MarketplacecommerceanalyticsServiceID = "marketplacecommerceanalytics" // Marketplacecommerceanalytics. + MediaconvertServiceID = "mediaconvert" // Mediaconvert. + MedialiveServiceID = "medialive" // Medialive. + MediapackageServiceID = "mediapackage" // Mediapackage. MeteringMarketplaceServiceID = "metering.marketplace" // MeteringMarketplace. MghServiceID = "mgh" // Mgh. MobileanalyticsServiceID = "mobileanalytics" // Mobileanalytics. @@ -127,12 +135,17 @@ const ( RdsServiceID = "rds" // Rds. RedshiftServiceID = "redshift" // Redshift. RekognitionServiceID = "rekognition" // Rekognition. + ResourceGroupsServiceID = "resource-groups" // ResourceGroups. Route53ServiceID = "route53" // Route53. Route53domainsServiceID = "route53domains" // Route53domains. RuntimeLexServiceID = "runtime.lex" // RuntimeLex. + RuntimeSagemakerServiceID = "runtime.sagemaker" // RuntimeSagemaker. S3ServiceID = "s3" // S3. + SagemakerServiceID = "sagemaker" // Sagemaker. SdbServiceID = "sdb" // Sdb. + ServerlessrepoServiceID = "serverlessrepo" // Serverlessrepo. ServicecatalogServiceID = "servicecatalog" // Servicecatalog. + ServicediscoveryServiceID = "servicediscovery" // Servicediscovery. ShieldServiceID = "shield" // Shield. SmsServiceID = "sms" // Sms. SnowballServiceID = "snowball" // Snowball. @@ -146,9 +159,11 @@ const ( SupportServiceID = "support" // Support. SwfServiceID = "swf" // Swf. TaggingServiceID = "tagging" // Tagging. + TranslateServiceID = "translate" // Translate. WafServiceID = "waf" // Waf. WafRegionalServiceID = "waf-regional" // WafRegional. WorkdocsServiceID = "workdocs" // Workdocs. + WorkmailServiceID = "workmail" // Workmail. WorkspacesServiceID = "workspaces" // Workspaces. XrayServiceID = "xray" // Xray. ) @@ -246,6 +261,12 @@ var awsPartition = partition{ }, }, Services: services{ + "a4b": service{ + + Endpoints: endpoints{ + "us-east-1": endpoint{}, + }, + }, "acm": service{ Endpoints: endpoints{ @@ -392,13 +413,16 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, + "us-west-1": endpoint{}, "us-west-2": endpoint{}, }, }, @@ -415,11 +439,35 @@ var awsPartition = partition{ }, }, }, + "ce": service{ + PartitionEndpoint: "aws-global", + IsRegionalized: boxedFalse, + + Endpoints: endpoints{ + "aws-global": endpoint{ + Hostname: "ce.us-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + }, + }, + }, + "cloud9": service{ + + Endpoints: endpoints{ + "ap-southeast-1": endpoint{}, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "clouddirectory": service{ Endpoints: endpoints{ "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, + "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "us-east-1": endpoint{}, @@ -536,16 +584,43 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, + "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, + "sa-east-1": endpoint{}, "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, + "us-east-1-fips": endpoint{ + Hostname: "codebuild-fips.us-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + }, + "us-east-2": endpoint{}, + "us-east-2-fips": endpoint{ + Hostname: "codebuild-fips.us-east-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-2", + }, + }, + "us-west-1": endpoint{}, + "us-west-1-fips": endpoint{ + Hostname: "codebuild-fips.us-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-1", + }, + }, + "us-west-2": endpoint{}, + "us-west-2-fips": endpoint{ + Hostname: "codebuild-fips.us-west-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-2", + }, + }, }, }, "codecommit": service{ @@ -599,6 +674,7 @@ var awsPartition = partition{ "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, @@ -610,6 +686,7 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, @@ -670,6 +747,17 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, + "comprehend": service{ + Defaults: endpoint{ + Protocols: []string{"https"}, + }, + Endpoints: endpoints{ + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "config": service{ Endpoints: endpoints{ @@ -711,6 +799,8 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, "ap-south-1": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, "eu-west-1": endpoint{}, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, @@ -939,6 +1029,7 @@ var awsPartition = partition{ "eu-west-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, + "us-west-1": endpoint{}, "us-west-2": endpoint{}, }, }, @@ -1120,6 +1211,8 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, @@ -1139,6 +1232,29 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, + "guardduty": service{ + IsRegionalized: boxedTrue, + Defaults: endpoint{ + Protocols: []string{"https"}, + }, + Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, + "ap-south-1": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "health": service{ Endpoints: endpoints{ @@ -1333,6 +1449,51 @@ var awsPartition = partition{ "us-east-1": endpoint{}, }, }, + "mediaconvert": service{ + + Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, + "ap-south-1": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, + }, + }, + "medialive": service{ + + Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-west-2": endpoint{}, + }, + }, + "mediapackage": service{ + + Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-3": endpoint{}, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "metering.marketplace": service{ Defaults: endpoint{ CredentialScope: credentialScope{ @@ -1349,6 +1510,7 @@ var awsPartition = partition{ "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, @@ -1375,6 +1537,7 @@ var awsPartition = partition{ }, }, Endpoints: endpoints{ + "eu-west-1": endpoint{}, "us-east-1": endpoint{}, }, }, @@ -1418,6 +1581,7 @@ var awsPartition = partition{ "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, @@ -1432,9 +1596,15 @@ var awsPartition = partition{ "opsworks-cm": service{ Endpoints: endpoints{ - "eu-west-1": endpoint{}, - "us-east-1": endpoint{}, - "us-west-2": endpoint{}, + "ap-northeast-1": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "organizations": service{ @@ -1525,10 +1695,31 @@ var awsPartition = partition{ "rekognition": service{ Endpoints: endpoints{ - "eu-west-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-2": endpoint{}, + "ap-northeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-2": endpoint{}, + }, + }, + "resource-groups": service{ + + Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, + "ap-south-1": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "route53": service{ @@ -1561,6 +1752,15 @@ var awsPartition = partition{ "us-east-1": endpoint{}, }, }, + "runtime.sagemaker": service{ + + Endpoints: endpoints{ + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "s3": service{ PartitionEndpoint: "us-east-1", IsRegionalized: boxedTrue, @@ -1620,6 +1820,15 @@ var awsPartition = partition{ }, }, }, + "sagemaker": service{ + + Endpoints: endpoints{ + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "sdb": service{ Defaults: endpoint{ Protocols: []string{"http", "https"}, @@ -1638,6 +1847,55 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, + "serverlessrepo": service{ + Defaults: endpoint{ + Protocols: []string{"https"}, + }, + Endpoints: endpoints{ + "ap-northeast-1": endpoint{ + Protocols: []string{"https"}, + }, + "ap-northeast-2": endpoint{ + Protocols: []string{"https"}, + }, + "ap-south-1": endpoint{ + Protocols: []string{"https"}, + }, + "ap-southeast-1": endpoint{ + Protocols: []string{"https"}, + }, + "ap-southeast-2": endpoint{ + Protocols: []string{"https"}, + }, + "ca-central-1": endpoint{ + Protocols: []string{"https"}, + }, + "eu-central-1": endpoint{ + Protocols: []string{"https"}, + }, + "eu-west-1": endpoint{ + Protocols: []string{"https"}, + }, + "eu-west-2": endpoint{ + Protocols: []string{"https"}, + }, + "sa-east-1": endpoint{ + Protocols: []string{"https"}, + }, + "us-east-1": endpoint{ + Protocols: []string{"https"}, + }, + "us-east-2": endpoint{ + Protocols: []string{"https"}, + }, + "us-west-1": endpoint{ + Protocols: []string{"https"}, + }, + "us-west-2": endpoint{ + Protocols: []string{"https"}, + }, + }, + }, "servicecatalog": service{ Endpoints: endpoints{ @@ -1658,6 +1916,15 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, + "servicediscovery": service{ + + Endpoints: endpoints{ + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "shield": service{ IsRegionalized: boxedFalse, Defaults: endpoint{ @@ -1674,10 +1941,12 @@ var awsPartition = partition{ "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, + "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, @@ -1690,7 +1959,9 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, "ap-south-1": endpoint{}, + "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, @@ -1930,6 +2201,7 @@ var awsPartition = partition{ "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, @@ -1937,6 +2209,16 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, + "translate": service{ + Defaults: endpoint{ + Protocols: []string{"https"}, + }, + Endpoints: endpoints{ + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "waf": service{ PartitionEndpoint: "aws-global", IsRegionalized: boxedFalse, @@ -1973,15 +2255,27 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, + "workmail": service{ + Defaults: endpoint{ + Protocols: []string{"https"}, + }, + Endpoints: endpoints{ + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "workspaces": service{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, + "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-west-2": endpoint{}, }, @@ -2350,7 +2644,8 @@ var awscnPartition = partition{ "tagging": service{ Endpoints: endpoints{ - "cn-north-1": endpoint{}, + "cn-north-1": endpoint{}, + "cn-northwest-1": endpoint{}, }, }, }, @@ -2513,6 +2808,12 @@ var awsusgovPartition = partition{ }, }, }, + "es": service{ + + Endpoints: endpoints{ + "us-gov-west-1": endpoint{}, + }, + }, "events": service{ Endpoints: endpoints{ @@ -2564,12 +2865,28 @@ var awsusgovPartition = partition{ "us-gov-west-1": endpoint{}, }, }, + "metering.marketplace": service{ + Defaults: endpoint{ + CredentialScope: credentialScope{ + Service: "aws-marketplace", + }, + }, + Endpoints: endpoints{ + "us-gov-west-1": endpoint{}, + }, + }, "monitoring": service{ Endpoints: endpoints{ "us-gov-west-1": endpoint{}, }, }, + "polly": service{ + + Endpoints: endpoints{ + "us-gov-west-1": endpoint{}, + }, + }, "rds": service{ Endpoints: endpoints{ @@ -2664,6 +2981,12 @@ var awsusgovPartition = partition{ }, "swf": service{ + Endpoints: endpoints{ + "us-gov-west-1": endpoint{}, + }, + }, + "tagging": service{ + Endpoints: endpoints{ "us-gov-west-1": endpoint{}, }, diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/endpoints.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/endpoints.go index 9c3eedb48d5d..d6be83c1921f 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/endpoints.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/endpoints.go @@ -347,6 +347,10 @@ type ResolvedEndpoint struct { // The service name that should be used for signing requests. SigningName string + // States that the signing name for this endpoint was derived from metadata + // passed in, but was not explicitly modeled. + SigningNameDerived bool + // The signing method that should be used for signing requests. SigningMethod string } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model.go index 13d968a249e3..ff6f76db6eba 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model.go @@ -226,16 +226,20 @@ func (e endpoint) resolve(service, region, dnsSuffix string, defs []endpoint, op if len(signingRegion) == 0 { signingRegion = region } + signingName := e.CredentialScope.Service + var signingNameDerived bool if len(signingName) == 0 { signingName = service + signingNameDerived = true } return ResolvedEndpoint{ - URL: u, - SigningRegion: signingRegion, - SigningName: signingName, - SigningMethod: getByPriority(e.SignatureVersions, signerPriority, defaultSigner), + URL: u, + SigningRegion: signingRegion, + SigningName: signingName, + SigningNameDerived: signingNameDerived, + SigningMethod: getByPriority(e.SignatureVersions, signerPriority, defaultSigner), } } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/offset_reader.go b/vendor/github.com/aws/aws-sdk-go/aws/request/offset_reader.go index 02f07f4a462f..b0c2ef4fe677 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/request/offset_reader.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/request/offset_reader.go @@ -3,6 +3,8 @@ package request import ( "io" "sync" + + "github.com/aws/aws-sdk-go/internal/sdkio" ) // offsetReader is a thread-safe io.ReadCloser to prevent racing @@ -15,7 +17,7 @@ type offsetReader struct { func newOffsetReader(buf io.ReadSeeker, offset int64) *offsetReader { reader := &offsetReader{} - buf.Seek(offset, 0) + buf.Seek(offset, sdkio.SeekStart) reader.buf = buf return reader diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/request.go b/vendor/github.com/aws/aws-sdk-go/aws/request/request.go index 5c7db4982c96..69b7a01ad74a 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/request/request.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/request/request.go @@ -14,6 +14,7 @@ import ( "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/aws/client/metadata" + "github.com/aws/aws-sdk-go/internal/sdkio" ) const ( @@ -224,6 +225,9 @@ func (r *Request) SetContext(ctx aws.Context) { // WillRetry returns if the request's can be retried. func (r *Request) WillRetry() bool { + if !aws.IsReaderSeekable(r.Body) && r.HTTPRequest.Body != NoBody { + return false + } return r.Error != nil && aws.BoolValue(r.Retryable) && r.RetryCount < r.MaxRetries() } @@ -255,6 +259,7 @@ func (r *Request) SetStringBody(s string) { // SetReaderBody will set the request's body reader. func (r *Request) SetReaderBody(reader io.ReadSeeker) { r.Body = reader + r.BodyStart, _ = reader.Seek(0, sdkio.SeekCurrent) // Get the Bodies current offset. r.ResetBody() } @@ -292,6 +297,11 @@ func (r *Request) PresignRequest(expire time.Duration) (string, http.Header, err return getPresignedURL(r, expire) } +// IsPresigned returns true if the request represents a presigned API url. +func (r *Request) IsPresigned() bool { + return r.ExpireTime != 0 +} + func getPresignedURL(r *Request, expire time.Duration) (string, http.Header, error) { if expire <= 0 { return "", nil, awserr.New( @@ -332,7 +342,7 @@ func debugLogReqError(r *Request, stage string, retrying bool, err error) { // Build will build the request's object so it can be signed and sent // to the service. Build will also validate all the request's parameters. -// Anny additional build Handlers set on this request will be run +// Any additional build Handlers set on this request will be run // in the order they were set. // // The request will only be built once. Multiple calls to build will have @@ -393,7 +403,7 @@ func (r *Request) getNextRequestBody() (io.ReadCloser, error) { // of the SDK if they used that field. // // Related golang/go#18257 - l, err := computeBodyLength(r.Body) + l, err := aws.SeekerLen(r.Body) if err != nil { return nil, awserr.New(ErrCodeSerialization, "failed to compute request body size", err) } @@ -411,7 +421,8 @@ func (r *Request) getNextRequestBody() (io.ReadCloser, error) { // Transfer-Encoding: chunked bodies for these methods. // // This would only happen if a aws.ReaderSeekerCloser was used with - // a io.Reader that was not also an io.Seeker. + // a io.Reader that was not also an io.Seeker, or did not implement + // Len() method. switch r.Operation.HTTPMethod { case "GET", "HEAD", "DELETE": body = NoBody @@ -423,42 +434,6 @@ func (r *Request) getNextRequestBody() (io.ReadCloser, error) { return body, nil } -// Attempts to compute the length of the body of the reader using the -// io.Seeker interface. If the value is not seekable because of being -// a ReaderSeekerCloser without an unerlying Seeker -1 will be returned. -// If no error occurs the length of the body will be returned. -func computeBodyLength(r io.ReadSeeker) (int64, error) { - seekable := true - // Determine if the seeker is actually seekable. ReaderSeekerCloser - // hides the fact that a io.Readers might not actually be seekable. - switch v := r.(type) { - case aws.ReaderSeekerCloser: - seekable = v.IsSeeker() - case *aws.ReaderSeekerCloser: - seekable = v.IsSeeker() - } - if !seekable { - return -1, nil - } - - curOffset, err := r.Seek(0, 1) - if err != nil { - return 0, err - } - - endOffset, err := r.Seek(0, 2) - if err != nil { - return 0, err - } - - _, err = r.Seek(curOffset, 0) - if err != nil { - return 0, err - } - - return endOffset - curOffset, nil -} - // GetBody will return an io.ReadSeeker of the Request's underlying // input body with a concurrency safe wrapper. func (r *Request) GetBody() io.ReadSeeker { diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/session.go b/vendor/github.com/aws/aws-sdk-go/aws/session/session.go index 2fc789d6d840..259b5c0fecc0 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/session/session.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/session/session.go @@ -26,7 +26,7 @@ import ( // Sessions are safe to create service clients concurrently, but it is not safe // to mutate the Session concurrently. // -// The Session satisfies the service client's client.ClientConfigProvider. +// The Session satisfies the service client's client.ConfigProvider. type Session struct { Config *aws.Config Handlers request.Handlers @@ -571,11 +571,12 @@ func (s *Session) clientConfigWithErr(serviceName string, cfgs ...*aws.Config) ( } return client.Config{ - Config: s.Config, - Handlers: s.Handlers, - Endpoint: resolved.URL, - SigningRegion: resolved.SigningRegion, - SigningName: resolved.SigningName, + Config: s.Config, + Handlers: s.Handlers, + Endpoint: resolved.URL, + SigningRegion: resolved.SigningRegion, + SigningNameDerived: resolved.SigningNameDerived, + SigningName: resolved.SigningName, }, err } @@ -595,10 +596,11 @@ func (s *Session) ClientConfigNoResolveEndpoint(cfgs ...*aws.Config) client.Conf } return client.Config{ - Config: s.Config, - Handlers: s.Handlers, - Endpoint: resolved.URL, - SigningRegion: resolved.SigningRegion, - SigningName: resolved.SigningName, + Config: s.Config, + Handlers: s.Handlers, + Endpoint: resolved.URL, + SigningRegion: resolved.SigningRegion, + SigningNameDerived: resolved.SigningNameDerived, + SigningName: resolved.SigningName, } } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go b/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go index ccc88b4ac1c4..6e46376125bc 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go @@ -71,6 +71,7 @@ import ( "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/credentials" "github.com/aws/aws-sdk-go/aws/request" + "github.com/aws/aws-sdk-go/internal/sdkio" "github.com/aws/aws-sdk-go/private/protocol/rest" ) @@ -341,7 +342,9 @@ func (v4 Signer) signWithBody(r *http.Request, body io.ReadSeeker, service, regi ctx.sanitizeHostForHeader() ctx.assignAmzQueryValues() - ctx.build(v4.DisableHeaderHoisting) + if err := ctx.build(v4.DisableHeaderHoisting); err != nil { + return nil, err + } // If the request is not presigned the body should be attached to it. This // prevents the confusion of wanting to send a signed request without @@ -503,11 +506,13 @@ func (v4 *Signer) logSigningInfo(ctx *signingCtx) { v4.Logger.Log(msg) } -func (ctx *signingCtx) build(disableHeaderHoisting bool) { +func (ctx *signingCtx) build(disableHeaderHoisting bool) error { ctx.buildTime() // no depends ctx.buildCredentialString() // no depends - ctx.buildBodyDigest() + if err := ctx.buildBodyDigest(); err != nil { + return err + } unsignedHeaders := ctx.Request.Header if ctx.isPresign { @@ -535,6 +540,8 @@ func (ctx *signingCtx) build(disableHeaderHoisting bool) { } ctx.Request.Header.Set("Authorization", strings.Join(parts, ", ")) } + + return nil } func (ctx *signingCtx) buildTime() { @@ -661,7 +668,7 @@ func (ctx *signingCtx) buildSignature() { ctx.signature = hex.EncodeToString(signature) } -func (ctx *signingCtx) buildBodyDigest() { +func (ctx *signingCtx) buildBodyDigest() error { hash := ctx.Request.Header.Get("X-Amz-Content-Sha256") if hash == "" { if ctx.unsignedPayload || (ctx.isPresign && ctx.ServiceName == "s3") { @@ -669,6 +676,9 @@ func (ctx *signingCtx) buildBodyDigest() { } else if ctx.Body == nil { hash = emptyStringSHA256 } else { + if !aws.IsReaderSeekable(ctx.Body) { + return fmt.Errorf("cannot use unseekable request body %T, for signed request with body", ctx.Body) + } hash = hex.EncodeToString(makeSha256Reader(ctx.Body)) } if ctx.unsignedPayload || ctx.ServiceName == "s3" || ctx.ServiceName == "glacier" { @@ -676,6 +686,8 @@ func (ctx *signingCtx) buildBodyDigest() { } } ctx.bodyDigest = hash + + return nil } // isRequestSigned returns if the request is currently signed or presigned @@ -715,8 +727,8 @@ func makeSha256(data []byte) []byte { func makeSha256Reader(reader io.ReadSeeker) []byte { hash := sha256.New() - start, _ := reader.Seek(0, 1) - defer reader.Seek(start, 0) + start, _ := reader.Seek(0, sdkio.SeekCurrent) + defer reader.Seek(start, sdkio.SeekStart) io.Copy(hash, reader) return hash.Sum(nil) diff --git a/vendor/github.com/aws/aws-sdk-go/aws/types.go b/vendor/github.com/aws/aws-sdk-go/aws/types.go index 0e2d864e10a8..8b6f23425a66 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/types.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/types.go @@ -3,6 +3,8 @@ package aws import ( "io" "sync" + + "github.com/aws/aws-sdk-go/internal/sdkio" ) // ReadSeekCloser wraps a io.Reader returning a ReaderSeekerCloser. Should @@ -22,6 +24,22 @@ type ReaderSeekerCloser struct { r io.Reader } +// IsReaderSeekable returns if the underlying reader type can be seeked. A +// io.Reader might not actually be seekable if it is the ReaderSeekerCloser +// type. +func IsReaderSeekable(r io.Reader) bool { + switch v := r.(type) { + case ReaderSeekerCloser: + return v.IsSeeker() + case *ReaderSeekerCloser: + return v.IsSeeker() + case io.ReadSeeker: + return true + default: + return false + } +} + // Read reads from the reader up to size of p. The number of bytes read, and // error if it occurred will be returned. // @@ -56,6 +74,71 @@ func (r ReaderSeekerCloser) IsSeeker() bool { return ok } +// HasLen returns the length of the underlying reader if the value implements +// the Len() int method. +func (r ReaderSeekerCloser) HasLen() (int, bool) { + type lenner interface { + Len() int + } + + if lr, ok := r.r.(lenner); ok { + return lr.Len(), true + } + + return 0, false +} + +// GetLen returns the length of the bytes remaining in the underlying reader. +// Checks first for Len(), then io.Seeker to determine the size of the +// underlying reader. +// +// Will return -1 if the length cannot be determined. +func (r ReaderSeekerCloser) GetLen() (int64, error) { + if l, ok := r.HasLen(); ok { + return int64(l), nil + } + + if s, ok := r.r.(io.Seeker); ok { + return seekerLen(s) + } + + return -1, nil +} + +// SeekerLen attempts to get the number of bytes remaining at the seeker's +// current position. Returns the number of bytes remaining or error. +func SeekerLen(s io.Seeker) (int64, error) { + // Determine if the seeker is actually seekable. ReaderSeekerCloser + // hides the fact that a io.Readers might not actually be seekable. + switch v := s.(type) { + case ReaderSeekerCloser: + return v.GetLen() + case *ReaderSeekerCloser: + return v.GetLen() + } + + return seekerLen(s) +} + +func seekerLen(s io.Seeker) (int64, error) { + curOffset, err := s.Seek(0, sdkio.SeekCurrent) + if err != nil { + return 0, err + } + + endOffset, err := s.Seek(0, sdkio.SeekEnd) + if err != nil { + return 0, err + } + + _, err = s.Seek(curOffset, sdkio.SeekStart) + if err != nil { + return 0, err + } + + return endOffset - curOffset, nil +} + // Close closes the ReaderSeekerCloser. // // If the ReaderSeekerCloser is not an io.Closer nothing will be done. diff --git a/vendor/github.com/aws/aws-sdk-go/aws/version.go b/vendor/github.com/aws/aws-sdk-go/aws/version.go index dd036c971e10..8cfc7e37ed9f 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/version.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/version.go @@ -5,4 +5,4 @@ package aws const SDKName = "aws-sdk-go" // SDKVersion is the version of this SDK -const SDKVersion = "1.12.75" +const SDKVersion = "1.13.28" diff --git a/vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.6.go b/vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.6.go new file mode 100644 index 000000000000..5aa9137e0f93 --- /dev/null +++ b/vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.6.go @@ -0,0 +1,10 @@ +// +build !go1.7 + +package sdkio + +// Copy of Go 1.7 io package's Seeker constants. +const ( + SeekStart = 0 // seek relative to the origin of the file + SeekCurrent = 1 // seek relative to the current offset + SeekEnd = 2 // seek relative to the end +) diff --git a/vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.7.go b/vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.7.go new file mode 100644 index 000000000000..e5f005613b79 --- /dev/null +++ b/vendor/github.com/aws/aws-sdk-go/internal/sdkio/io_go1.7.go @@ -0,0 +1,12 @@ +// +build go1.7 + +package sdkio + +import "io" + +// Alias for Go 1.7 io package Seeker constants +const ( + SeekStart = io.SeekStart // seek relative to the origin of the file + SeekCurrent = io.SeekCurrent // seek relative to the current offset + SeekEnd = io.SeekEnd // seek relative to the end +) diff --git a/vendor/github.com/aws/aws-sdk-go/internal/sdkrand/locked_source.go b/vendor/github.com/aws/aws-sdk-go/internal/sdkrand/locked_source.go new file mode 100644 index 000000000000..0c9802d87706 --- /dev/null +++ b/vendor/github.com/aws/aws-sdk-go/internal/sdkrand/locked_source.go @@ -0,0 +1,29 @@ +package sdkrand + +import ( + "math/rand" + "sync" + "time" +) + +// lockedSource is a thread-safe implementation of rand.Source +type lockedSource struct { + lk sync.Mutex + src rand.Source +} + +func (r *lockedSource) Int63() (n int64) { + r.lk.Lock() + n = r.src.Int63() + r.lk.Unlock() + return +} + +func (r *lockedSource) Seed(seed int64) { + r.lk.Lock() + r.src.Seed(seed) + r.lk.Unlock() +} + +// SeededRand is a new RNG using a thread safe implementation of rand.Source +var SeededRand = rand.New(&lockedSource{src: rand.NewSource(time.Now().UnixNano())}) diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/ec2query/build.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/ec2query/build.go index eedc5bd7d440..3104e6ce4c92 100644 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/ec2query/build.go +++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/ec2query/build.go @@ -24,7 +24,7 @@ func Build(r *request.Request) { r.Error = awserr.New("SerializationError", "failed encoding EC2 Query request", err) } - if r.ExpireTime == 0 { + if !r.IsPresigned() { r.HTTPRequest.Method = "POST" r.HTTPRequest.Header.Set("Content-Type", "application/x-www-form-urlencoded; charset=utf-8") r.SetBufferBody([]byte(body.Encode())) diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go index 18169f0f8ce4..60e5b09d548c 100644 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go +++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go @@ -25,7 +25,7 @@ func Build(r *request.Request) { return } - if r.ExpireTime == 0 { + if !r.IsPresigned() { r.HTTPRequest.Method = "POST" r.HTTPRequest.Header.Set("Content-Type", "application/x-www-form-urlencoded; charset=utf-8") r.SetBufferBody([]byte(body.Encode())) diff --git a/vendor/github.com/aws/aws-sdk-go/service/acm/api.go b/vendor/github.com/aws/aws-sdk-go/service/acm/api.go index b6af6aaa1ffa..71e240316207 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/acm/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/acm/api.go @@ -17,7 +17,7 @@ const opAddTagsToCertificate = "AddTagsToCertificate" // AddTagsToCertificateRequest generates a "aws/request.Request" representing the // client's request for the AddTagsToCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -59,7 +59,7 @@ func (c *ACM) AddTagsToCertificateRequest(input *AddTagsToCertificateInput) (req // AddTagsToCertificate API operation for AWS Certificate Manager. // -// Adds one or more tags to an ACM Certificate. Tags are labels that you can +// Adds one or more tags to an ACM certificate. Tags are labels that you can // use to identify and organize your AWS resources. Each tag consists of a key // and an optional value. You specify the certificate on input by its Amazon // Resource Name (ARN). You specify the tag by using a key-value pair. @@ -69,9 +69,9 @@ func (c *ACM) AddTagsToCertificateRequest(input *AddTagsToCertificateInput) (req // certificates if you want to filter for a common relationship among those // certificates. Similarly, you can apply the same tag to multiple resources // if you want to specify a relationship among those resources. For example, -// you can add the same tag to an ACM Certificate and an Elastic Load Balancing +// you can add the same tag to an ACM certificate and an Elastic Load Balancing // load balancer to indicate that they are both used by the same website. For -// more information, see Tagging ACM Certificates (http://docs.aws.amazon.com/acm/latest/userguide/tags.html). +// more information, see Tagging ACM certificates (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/tags.html). // // To remove one or more tags, use the RemoveTagsFromCertificate action. To // view all of the tags that have been applied to the certificate, use the ListTagsForCertificate @@ -86,7 +86,7 @@ func (c *ACM) AddTagsToCertificateRequest(input *AddTagsToCertificateInput) (req // // Returned Error Codes: // * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// The specified certificate cannot be found in the caller's account, or the +// The specified certificate cannot be found in the caller's account or the // caller's account cannot be found. // // * ErrCodeInvalidArnException "InvalidArnException" @@ -125,7 +125,7 @@ const opDeleteCertificate = "DeleteCertificate" // DeleteCertificateRequest generates a "aws/request.Request" representing the // client's request for the DeleteCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -173,7 +173,7 @@ func (c *ACM) DeleteCertificateRequest(input *DeleteCertificateInput) (req *requ // action. The certificate will not be available for use by AWS services integrated // with ACM. // -// You cannot delete an ACM Certificate that is being used by another AWS service. +// You cannot delete an ACM certificate that is being used by another AWS service. // To delete a certificate that is in use, the certificate association must // first be removed. // @@ -186,7 +186,7 @@ func (c *ACM) DeleteCertificateRequest(input *DeleteCertificateInput) (req *requ // // Returned Error Codes: // * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// The specified certificate cannot be found in the caller's account, or the +// The specified certificate cannot be found in the caller's account or the // caller's account cannot be found. // // * ErrCodeResourceInUseException "ResourceInUseException" @@ -222,7 +222,7 @@ const opDescribeCertificate = "DescribeCertificate" // DescribeCertificateRequest generates a "aws/request.Request" representing the // client's request for the DescribeCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -262,7 +262,7 @@ func (c *ACM) DescribeCertificateRequest(input *DescribeCertificateInput) (req * // DescribeCertificate API operation for AWS Certificate Manager. // -// Returns detailed metadata about the specified ACM Certificate. +// Returns detailed metadata about the specified ACM certificate. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -273,7 +273,7 @@ func (c *ACM) DescribeCertificateRequest(input *DescribeCertificateInput) (req * // // Returned Error Codes: // * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// The specified certificate cannot be found in the caller's account, or the +// The specified certificate cannot be found in the caller's account or the // caller's account cannot be found. // // * ErrCodeInvalidArnException "InvalidArnException" @@ -301,11 +301,105 @@ func (c *ACM) DescribeCertificateWithContext(ctx aws.Context, input *DescribeCer return out, req.Send() } +const opExportCertificate = "ExportCertificate" + +// ExportCertificateRequest generates a "aws/request.Request" representing the +// client's request for the ExportCertificate operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ExportCertificate for more information on using the ExportCertificate +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ExportCertificateRequest method. +// req, resp := client.ExportCertificateRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-2015-12-08/ExportCertificate +func (c *ACM) ExportCertificateRequest(input *ExportCertificateInput) (req *request.Request, output *ExportCertificateOutput) { + op := &request.Operation{ + Name: opExportCertificate, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &ExportCertificateInput{} + } + + output = &ExportCertificateOutput{} + req = c.newRequest(op, input, output) + return +} + +// ExportCertificate API operation for AWS Certificate Manager. +// +// Exports a certificate for use anywhere. You can export the certificate, the +// certificate chain, and the encrypted private key associated with the public +// key embedded in the certificate. You must store the private key securely. +// The private key is a 2048 bit RSA key. You must provide a passphrase for +// the private key when exporting it. You can use the following OpenSSL command +// to decrypt it later. Provide the passphrase when prompted. +// +// openssl rsa -in encrypted_key.pem -out decrypted_key.pem +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Certificate Manager's +// API operation ExportCertificate for usage and error information. +// +// Returned Error Codes: +// * ErrCodeResourceNotFoundException "ResourceNotFoundException" +// The specified certificate cannot be found in the caller's account or the +// caller's account cannot be found. +// +// * ErrCodeRequestInProgressException "RequestInProgressException" +// The certificate request is in process and the certificate in your account +// has not yet been issued. +// +// * ErrCodeInvalidArnException "InvalidArnException" +// The requested Amazon Resource Name (ARN) does not refer to an existing resource. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-2015-12-08/ExportCertificate +func (c *ACM) ExportCertificate(input *ExportCertificateInput) (*ExportCertificateOutput, error) { + req, out := c.ExportCertificateRequest(input) + return out, req.Send() +} + +// ExportCertificateWithContext is the same as ExportCertificate with the addition of +// the ability to pass a context and additional request options. +// +// See ExportCertificate for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ACM) ExportCertificateWithContext(ctx aws.Context, input *ExportCertificateInput, opts ...request.Option) (*ExportCertificateOutput, error) { + req, out := c.ExportCertificateRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opGetCertificate = "GetCertificate" // GetCertificateRequest generates a "aws/request.Request" representing the // client's request for the GetCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -361,7 +455,7 @@ func (c *ACM) GetCertificateRequest(input *GetCertificateInput) (req *request.Re // // Returned Error Codes: // * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// The specified certificate cannot be found in the caller's account, or the +// The specified certificate cannot be found in the caller's account or the // caller's account cannot be found. // // * ErrCodeRequestInProgressException "RequestInProgressException" @@ -397,7 +491,7 @@ const opImportCertificate = "ImportCertificate" // ImportCertificateRequest generates a "aws/request.Request" representing the // client's request for the ImportCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -438,15 +532,15 @@ func (c *ACM) ImportCertificateRequest(input *ImportCertificateInput) (req *requ // ImportCertificate API operation for AWS Certificate Manager. // // Imports a certificate into AWS Certificate Manager (ACM) to use with services -// that are integrated with ACM. Note that integrated services (http://docs.aws.amazon.com/acm/latest/userguide/acm-services.html) +// that are integrated with ACM. Note that integrated services (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/acm-services.html) // allow only certificate types and keys they support to be associated with // their resources. Further, their support differs depending on whether the // certificate is imported into IAM or into ACM. For more information, see the // documentation for each service. For more information about importing certificates -// into ACM, see Importing Certificates (http://docs.aws.amazon.com/acm/latest/userguide/import-certificate.html) +// into ACM, see Importing Certificates (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/import-certificate.html) // in the AWS Certificate Manager User Guide. // -// ACM does not provide managed renewal (http://docs.aws.amazon.com/acm/latest/userguide/acm-renewal.html) +// ACM does not provide managed renewal (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/acm-renewal.html) // for certificates that you import. // // Note the following guidelines when importing third party certificates: @@ -494,15 +588,11 @@ func (c *ACM) ImportCertificateRequest(input *ImportCertificateInput) (req *requ // // Returned Error Codes: // * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// The specified certificate cannot be found in the caller's account, or the +// The specified certificate cannot be found in the caller's account or the // caller's account cannot be found. // // * ErrCodeLimitExceededException "LimitExceededException" -// An ACM limit has been exceeded. For example, you may have input more domains -// than are allowed or you've requested too many certificates for your account. -// See the exception message returned by ACM to determine which limit you have -// violated. For more information about ACM limits, see the Limits (http://docs.aws.amazon.com/acm/latest/userguide/acm-limits.html) -// topic. +// An ACM limit has been exceeded. // // See also, https://docs.aws.amazon.com/goto/WebAPI/acm-2015-12-08/ImportCertificate func (c *ACM) ImportCertificate(input *ImportCertificateInput) (*ImportCertificateOutput, error) { @@ -530,7 +620,7 @@ const opListCertificates = "ListCertificates" // ListCertificatesRequest generates a "aws/request.Request" representing the // client's request for the ListCertificates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -662,7 +752,7 @@ const opListTagsForCertificate = "ListTagsForCertificate" // ListTagsForCertificateRequest generates a "aws/request.Request" representing the // client's request for the ListTagsForCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -702,9 +792,9 @@ func (c *ACM) ListTagsForCertificateRequest(input *ListTagsForCertificateInput) // ListTagsForCertificate API operation for AWS Certificate Manager. // -// Lists the tags that have been applied to the ACM Certificate. Use the certificate's +// Lists the tags that have been applied to the ACM certificate. Use the certificate's // Amazon Resource Name (ARN) to specify the certificate. To add a tag to an -// ACM Certificate, use the AddTagsToCertificate action. To delete a tag, use +// ACM certificate, use the AddTagsToCertificate action. To delete a tag, use // the RemoveTagsFromCertificate action. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -716,7 +806,7 @@ func (c *ACM) ListTagsForCertificateRequest(input *ListTagsForCertificateInput) // // Returned Error Codes: // * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// The specified certificate cannot be found in the caller's account, or the +// The specified certificate cannot be found in the caller's account or the // caller's account cannot be found. // // * ErrCodeInvalidArnException "InvalidArnException" @@ -748,7 +838,7 @@ const opRemoveTagsFromCertificate = "RemoveTagsFromCertificate" // RemoveTagsFromCertificateRequest generates a "aws/request.Request" representing the // client's request for the RemoveTagsFromCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -790,13 +880,13 @@ func (c *ACM) RemoveTagsFromCertificateRequest(input *RemoveTagsFromCertificateI // RemoveTagsFromCertificate API operation for AWS Certificate Manager. // -// Remove one or more tags from an ACM Certificate. A tag consists of a key-value +// Remove one or more tags from an ACM certificate. A tag consists of a key-value // pair. If you do not specify the value portion of the tag when calling this // function, the tag will be removed regardless of value. If you specify a value, // the tag is removed only if it is associated with the specified value. // // To add tags to a certificate, use the AddTagsToCertificate action. To view -// all of the tags that have been applied to a specific ACM Certificate, use +// all of the tags that have been applied to a specific ACM certificate, use // the ListTagsForCertificate action. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -808,7 +898,7 @@ func (c *ACM) RemoveTagsFromCertificateRequest(input *RemoveTagsFromCertificateI // // Returned Error Codes: // * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// The specified certificate cannot be found in the caller's account, or the +// The specified certificate cannot be found in the caller's account or the // caller's account cannot be found. // // * ErrCodeInvalidArnException "InvalidArnException" @@ -844,7 +934,7 @@ const opRequestCertificate = "RequestCertificate" // RequestCertificateRequest generates a "aws/request.Request" representing the // client's request for the RequestCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -884,20 +974,23 @@ func (c *ACM) RequestCertificateRequest(input *RequestCertificateInput) (req *re // RequestCertificate API operation for AWS Certificate Manager. // -// Requests an ACM Certificate for use with other AWS services. To request an -// ACM Certificate, you must specify the fully qualified domain name (FQDN) +// Requests an ACM certificate for use with other AWS services. To request an +// ACM certificate, you must specify the fully qualified domain name (FQDN) // for your site in the DomainName parameter. You can also specify additional -// FQDNs in the SubjectAlternativeNames parameter if users can reach your site -// by using other names. +// FQDNs in the SubjectAlternativeNames parameter. // -// For each domain name you specify, email is sent to the domain owner to request +// Each domain name that you specify must be validated to verify that you own +// or control the domain. You can use DNS validation (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/gs-acm-validate-dns.html) +// or email validation (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/gs-acm-validate-email.html). +// We recommend that you use DNS validation. +// +// If you choose email validation, email is sent to the domain owner to request // approval to issue the certificate. Email is sent to three registered contact // addresses in the WHOIS database and to five common system administration // addresses formed from the DomainName you enter or the optional ValidationDomain -// parameter. For more information, see Validate Domain Ownership (http://docs.aws.amazon.com/acm/latest/userguide/gs-acm-validate.html). +// parameter. For more information, see Validate with Email (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/gs-acm-validate-email.html). // -// After receiving approval from the domain owner, the ACM Certificate is issued. -// For more information, see the AWS Certificate Manager User Guide (http://docs.aws.amazon.com/acm/latest/userguide/). +// After receiving approval from the domain owner, the ACM certificate is issued. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -908,15 +1001,14 @@ func (c *ACM) RequestCertificateRequest(input *RequestCertificateInput) (req *re // // Returned Error Codes: // * ErrCodeLimitExceededException "LimitExceededException" -// An ACM limit has been exceeded. For example, you may have input more domains -// than are allowed or you've requested too many certificates for your account. -// See the exception message returned by ACM to determine which limit you have -// violated. For more information about ACM limits, see the Limits (http://docs.aws.amazon.com/acm/latest/userguide/acm-limits.html) -// topic. +// An ACM limit has been exceeded. // // * ErrCodeInvalidDomainValidationOptionsException "InvalidDomainValidationOptionsException" // One or more values in the DomainValidationOption structure is incorrect. // +// * ErrCodeInvalidArnException "InvalidArnException" +// The requested Amazon Resource Name (ARN) does not refer to an existing resource. +// // See also, https://docs.aws.amazon.com/goto/WebAPI/acm-2015-12-08/RequestCertificate func (c *ACM) RequestCertificate(input *RequestCertificateInput) (*RequestCertificateOutput, error) { req, out := c.RequestCertificateRequest(input) @@ -943,7 +1035,7 @@ const opResendValidationEmail = "ResendValidationEmail" // ResendValidationEmailRequest generates a "aws/request.Request" representing the // client's request for the ResendValidationEmail operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -986,16 +1078,16 @@ func (c *ACM) ResendValidationEmailRequest(input *ResendValidationEmailInput) (r // ResendValidationEmail API operation for AWS Certificate Manager. // // Resends the email that requests domain ownership validation. The domain owner -// or an authorized representative must approve the ACM Certificate before it +// or an authorized representative must approve the ACM certificate before it // can be issued. The certificate can be approved by clicking a link in the // mail to navigate to the Amazon certificate approval website and then clicking // I Approve. However, the validation email can be blocked by spam filters. // Therefore, if you do not receive the original mail, you can request that -// the mail be resent within 72 hours of requesting the ACM Certificate. If +// the mail be resent within 72 hours of requesting the ACM certificate. If // more than 72 hours have elapsed since your original request or since your // last attempt to resend validation mail, you must request a new certificate. // For more information about setting up your contact email addresses, see Configure -// Email for your Domain (http://docs.aws.amazon.com/acm/latest/userguide/setup-email.html). +// Email for your Domain (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/setup-email.html). // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -1006,14 +1098,11 @@ func (c *ACM) ResendValidationEmailRequest(input *ResendValidationEmailInput) (r // // Returned Error Codes: // * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// The specified certificate cannot be found in the caller's account, or the +// The specified certificate cannot be found in the caller's account or the // caller's account cannot be found. // // * ErrCodeInvalidStateException "InvalidStateException" -// Processing has reached an invalid state. For example, this exception can -// occur if the specified domain is not using email validation, or the current -// certificate status does not permit the requested operation. See the exception -// message returned by ACM to determine which state is not valid. +// Processing has reached an invalid state. // // * ErrCodeInvalidArnException "InvalidArnException" // The requested Amazon Resource Name (ARN) does not refer to an existing resource. @@ -1043,10 +1132,104 @@ func (c *ACM) ResendValidationEmailWithContext(ctx aws.Context, input *ResendVal return out, req.Send() } +const opUpdateCertificateOptions = "UpdateCertificateOptions" + +// UpdateCertificateOptionsRequest generates a "aws/request.Request" representing the +// client's request for the UpdateCertificateOptions operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateCertificateOptions for more information on using the UpdateCertificateOptions +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the UpdateCertificateOptionsRequest method. +// req, resp := client.UpdateCertificateOptionsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-2015-12-08/UpdateCertificateOptions +func (c *ACM) UpdateCertificateOptionsRequest(input *UpdateCertificateOptionsInput) (req *request.Request, output *UpdateCertificateOptionsOutput) { + op := &request.Operation{ + Name: opUpdateCertificateOptions, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &UpdateCertificateOptionsInput{} + } + + output = &UpdateCertificateOptionsOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// UpdateCertificateOptions API operation for AWS Certificate Manager. +// +// Updates a certificate. Currently, you can use this function to specify whether +// to opt in to or out of recording your certificate in a certificate transparency +// log. For more information, see Opting Out of Certificate Transparency Logging +// (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/acm-bestpractices.html#best-practices-transparency). +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Certificate Manager's +// API operation UpdateCertificateOptions for usage and error information. +// +// Returned Error Codes: +// * ErrCodeResourceNotFoundException "ResourceNotFoundException" +// The specified certificate cannot be found in the caller's account or the +// caller's account cannot be found. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// An ACM limit has been exceeded. +// +// * ErrCodeInvalidStateException "InvalidStateException" +// Processing has reached an invalid state. +// +// * ErrCodeInvalidArnException "InvalidArnException" +// The requested Amazon Resource Name (ARN) does not refer to an existing resource. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-2015-12-08/UpdateCertificateOptions +func (c *ACM) UpdateCertificateOptions(input *UpdateCertificateOptionsInput) (*UpdateCertificateOptionsOutput, error) { + req, out := c.UpdateCertificateOptionsRequest(input) + return out, req.Send() +} + +// UpdateCertificateOptionsWithContext is the same as UpdateCertificateOptions with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateCertificateOptions for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ACM) UpdateCertificateOptionsWithContext(ctx aws.Context, input *UpdateCertificateOptionsInput, opts ...request.Option) (*UpdateCertificateOptionsOutput, error) { + req, out := c.UpdateCertificateOptionsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + type AddTagsToCertificateInput struct { _ struct{} `type:"structure"` - // String that contains the ARN of the ACM Certificate to which the tag is to + // String that contains the ARN of the ACM certificate to which the tag is to // be applied. This must be of the form: // // arn:aws:acm:region:123456789012:certificate/12345678-1234-1234-1234-123456789012 @@ -1141,6 +1324,12 @@ type CertificateDetail struct { // in the AWS General Reference. CertificateArn *string `min:"20" type:"string"` + // The Amazon Resource Name (ARN) of the ACM PCA private certificate authority + // (CA) that issued the certificate. This has the following format: + // + // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 + CertificateAuthorityArn *string `min:"20" type:"string"` + // The time at which the certificate was requested. This value exists only when // the certificate type is AMAZON_ISSUED. CreatedAt *time.Time `type:"timestamp" timestampFormat:"unix"` @@ -1161,7 +1350,7 @@ type CertificateDetail struct { // The reason the certificate request failed. This value exists only when the // certificate status is FAILED. For more information, see Certificate Request - // Failed (http://docs.aws.amazon.com/acm/latest/userguide/troubleshooting.html#troubleshooting-failed) + // Failed (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/troubleshooting.html#troubleshooting-failed) // in the AWS Certificate Manager User Guide. FailureReason *string `type:"string" enum:"FailureReason"` @@ -1195,7 +1384,17 @@ type CertificateDetail struct { // The time before which the certificate is not valid. NotBefore *time.Time `type:"timestamp" timestampFormat:"unix"` - // Contains information about the status of ACM's managed renewal (http://docs.aws.amazon.com/acm/latest/userguide/acm-renewal.html) + // Value that specifies whether to add the certificate to a transparency log. + // Certificate transparency makes it possible to detect SSL certificates that + // have been mistakenly or maliciously issued. A browser might respond to certificate + // that has not been logged by showing an error message. The logs are cryptographically + // secure. + Options *CertificateOptions `type:"structure"` + + // Specifies whether the certificate is eligible for renewal. + RenewalEligibility *string `type:"string" enum:"RenewalEligibility"` + + // Contains information about the status of ACM's managed renewal (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/acm-renewal.html) // for the certificate. This field exists only when the certificate type is // AMAZON_ISSUED. RenewalSummary *RenewalSummary `type:"structure"` @@ -1230,10 +1429,10 @@ type CertificateDetail struct { // The source of the certificate. For certificates provided by ACM, this value // is AMAZON_ISSUED. For certificates that you imported with ImportCertificate, - // this value is IMPORTED. ACM does not provide managed renewal (http://docs.aws.amazon.com/acm/latest/userguide/acm-renewal.html) + // this value is IMPORTED. ACM does not provide managed renewal (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/acm-renewal.html) // for imported certificates. For more information about the differences between // certificates that you import and those that ACM provides, see Importing Certificates - // (http://docs.aws.amazon.com/acm/latest/userguide/import-certificate.html) + // (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/import-certificate.html) // in the AWS Certificate Manager User Guide. Type *string `type:"string" enum:"CertificateType"` } @@ -1254,6 +1453,12 @@ func (s *CertificateDetail) SetCertificateArn(v string) *CertificateDetail { return s } +// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. +func (s *CertificateDetail) SetCertificateAuthorityArn(v string) *CertificateDetail { + s.CertificateAuthorityArn = &v + return s +} + // SetCreatedAt sets the CreatedAt field's value. func (s *CertificateDetail) SetCreatedAt(v time.Time) *CertificateDetail { s.CreatedAt = &v @@ -1332,6 +1537,18 @@ func (s *CertificateDetail) SetNotBefore(v time.Time) *CertificateDetail { return s } +// SetOptions sets the Options field's value. +func (s *CertificateDetail) SetOptions(v *CertificateOptions) *CertificateDetail { + s.Options = v + return s +} + +// SetRenewalEligibility sets the RenewalEligibility field's value. +func (s *CertificateDetail) SetRenewalEligibility(v string) *CertificateDetail { + s.RenewalEligibility = &v + return s +} + // SetRenewalSummary sets the RenewalSummary field's value. func (s *CertificateDetail) SetRenewalSummary(v *RenewalSummary) *CertificateDetail { s.RenewalSummary = v @@ -1386,6 +1603,37 @@ func (s *CertificateDetail) SetType(v string) *CertificateDetail { return s } +// Structure that contains options for your certificate. Currently, you can +// use this only to specify whether to opt in to or out of certificate transparency +// logging. Some browsers require that public certificates issued for your domain +// be recorded in a log. Certificates that are not logged typically generate +// a browser error. Transparency makes it possible for you to detect SSL/TLS +// certificates that have been mistakenly or maliciously issued for your domain. +// For general information, see Certificate Transparency Logging (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/acm-concepts.html#concept-transparency). +type CertificateOptions struct { + _ struct{} `type:"structure"` + + // You can opt out of certificate transparency logging by specifying the DISABLED + // option. Opt in by specifying ENABLED. + CertificateTransparencyLoggingPreference *string `type:"string" enum:"CertificateTransparencyLoggingPreference"` +} + +// String returns the string representation +func (s CertificateOptions) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CertificateOptions) GoString() string { + return s.String() +} + +// SetCertificateTransparencyLoggingPreference sets the CertificateTransparencyLoggingPreference field's value. +func (s *CertificateOptions) SetCertificateTransparencyLoggingPreference(v string) *CertificateOptions { + s.CertificateTransparencyLoggingPreference = &v + return s +} + // This structure is returned in the response object of ListCertificates action. type CertificateSummary struct { _ struct{} `type:"structure"` @@ -1428,7 +1676,7 @@ func (s *CertificateSummary) SetDomainName(v string) *CertificateSummary { type DeleteCertificateInput struct { _ struct{} `type:"structure"` - // String that contains the ARN of the ACM Certificate to be deleted. This must + // String that contains the ARN of the ACM certificate to be deleted. This must // be of the form: // // arn:aws:acm:region:123456789012:certificate/12345678-1234-1234-1234-123456789012 @@ -1489,7 +1737,7 @@ func (s DeleteCertificateOutput) GoString() string { type DescribeCertificateInput struct { _ struct{} `type:"structure"` - // The Amazon Resource Name (ARN) of the ACM Certificate. The ARN must have + // The Amazon Resource Name (ARN) of the ACM certificate. The ARN must have // the following form: // // arn:aws:acm:region:123456789012:certificate/12345678-1234-1234-1234-123456789012 @@ -1567,7 +1815,7 @@ type DomainValidation struct { DomainName *string `min:"1" type:"string" required:"true"` // Contains the CNAME record that you add to your DNS database for domain validation. - // For more information, see Use DNS to Validate Domain Ownership (http://docs.aws.amazon.com/acm/latest/userguide/gs-acm-validate-dns.html). + // For more information, see Use DNS to Validate Domain Ownership (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/gs-acm-validate-dns.html). ResourceRecord *ResourceRecord `type:"structure"` // The domain name that ACM used to send domain validation emails. @@ -1711,6 +1959,115 @@ func (s *DomainValidationOption) SetValidationDomain(v string) *DomainValidation return s } +type ExportCertificateInput struct { + _ struct{} `type:"structure"` + + // An Amazon Resource Name (ARN) of the issued certificate. This must be of + // the form: + // + // arn:aws:acm:region:account:certificate/12345678-1234-1234-1234-123456789012 + // + // CertificateArn is a required field + CertificateArn *string `min:"20" type:"string" required:"true"` + + // Passphrase to associate with the encrypted exported private key. If you want + // to later decrypt the private key, you must have the passphrase. You can use + // the following OpenSSL command to decrypt a private key: + // + // openssl rsa -in encrypted_key.pem -out decrypted_key.pem + // + // Passphrase is automatically base64 encoded/decoded by the SDK. + // + // Passphrase is a required field + Passphrase []byte `min:"4" type:"blob" required:"true"` +} + +// String returns the string representation +func (s ExportCertificateInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ExportCertificateInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ExportCertificateInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ExportCertificateInput"} + if s.CertificateArn == nil { + invalidParams.Add(request.NewErrParamRequired("CertificateArn")) + } + if s.CertificateArn != nil && len(*s.CertificateArn) < 20 { + invalidParams.Add(request.NewErrParamMinLen("CertificateArn", 20)) + } + if s.Passphrase == nil { + invalidParams.Add(request.NewErrParamRequired("Passphrase")) + } + if s.Passphrase != nil && len(s.Passphrase) < 4 { + invalidParams.Add(request.NewErrParamMinLen("Passphrase", 4)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetCertificateArn sets the CertificateArn field's value. +func (s *ExportCertificateInput) SetCertificateArn(v string) *ExportCertificateInput { + s.CertificateArn = &v + return s +} + +// SetPassphrase sets the Passphrase field's value. +func (s *ExportCertificateInput) SetPassphrase(v []byte) *ExportCertificateInput { + s.Passphrase = v + return s +} + +type ExportCertificateOutput struct { + _ struct{} `type:"structure"` + + // The base64 PEM-encoded certificate. + Certificate *string `min:"1" type:"string"` + + // The base64 PEM-encoded certificate chain. This does not include the certificate + // that you are exporting. + CertificateChain *string `min:"1" type:"string"` + + // The PEM-encoded private key associated with the public key in the certificate. + PrivateKey *string `min:"1" type:"string"` +} + +// String returns the string representation +func (s ExportCertificateOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ExportCertificateOutput) GoString() string { + return s.String() +} + +// SetCertificate sets the Certificate field's value. +func (s *ExportCertificateOutput) SetCertificate(v string) *ExportCertificateOutput { + s.Certificate = &v + return s +} + +// SetCertificateChain sets the CertificateChain field's value. +func (s *ExportCertificateOutput) SetCertificateChain(v string) *ExportCertificateOutput { + s.CertificateChain = &v + return s +} + +// SetPrivateKey sets the PrivateKey field's value. +func (s *ExportCertificateOutput) SetPrivateKey(v string) *ExportCertificateOutput { + s.PrivateKey = &v + return s +} + // The Extended Key Usage X.509 v3 extension defines one or more purposes for // which the public key can be used. This is in addition to or in place of the // basic purposes specified by the Key Usage extension. @@ -1858,7 +2215,7 @@ func (s *GetCertificateInput) SetCertificateArn(v string) *GetCertificateInput { type GetCertificateOutput struct { _ struct{} `type:"structure"` - // String that contains the ACM Certificate represented by the ARN specified + // String that contains the ACM certificate represented by the ARN specified // at input. Certificate *string `min:"1" type:"string"` @@ -2102,7 +2459,7 @@ func (s *ListCertificatesInput) SetNextToken(v string) *ListCertificatesInput { type ListCertificatesOutput struct { _ struct{} `type:"structure"` - // A list of ACM Certificates. + // A list of ACM certificates. CertificateSummaryList []*CertificateSummary `type:"list"` // When the list is truncated, this value is present and contains the value @@ -2135,7 +2492,7 @@ func (s *ListCertificatesOutput) SetNextToken(v string) *ListCertificatesOutput type ListTagsForCertificateInput struct { _ struct{} `type:"structure"` - // String that contains the ARN of the ACM Certificate for which you want to + // String that contains the ARN of the ACM certificate for which you want to // list the tags. This must have the following form: // // arn:aws:acm:region:123456789012:certificate/12345678-1234-1234-1234-123456789012 @@ -2290,14 +2647,14 @@ func (s RemoveTagsFromCertificateOutput) GoString() string { return s.String() } -// Contains information about the status of ACM's managed renewal (http://docs.aws.amazon.com/acm/latest/userguide/acm-renewal.html) +// Contains information about the status of ACM's managed renewal (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/acm-renewal.html) // for the certificate. This structure exists only when the certificate type // is AMAZON_ISSUED. type RenewalSummary struct { _ struct{} `type:"structure"` // Contains information about the validation of each domain name in the certificate, - // as it pertains to ACM's managed renewal (http://docs.aws.amazon.com/acm/latest/userguide/acm-renewal.html). + // as it pertains to ACM's managed renewal (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/acm-renewal.html). // This is different from the initial validation that occurs as a result of // the RequestCertificate request. This field exists only when the certificate // type is AMAZON_ISSUED. @@ -2305,7 +2662,7 @@ type RenewalSummary struct { // DomainValidationOptions is a required field DomainValidationOptions []*DomainValidation `min:"1" type:"list" required:"true"` - // The status of ACM's managed renewal (http://docs.aws.amazon.com/acm/latest/userguide/acm-renewal.html) + // The status of ACM's managed renewal (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/acm-renewal.html) // of the certificate. // // RenewalStatus is a required field @@ -2337,6 +2694,15 @@ func (s *RenewalSummary) SetRenewalStatus(v string) *RenewalSummary { type RequestCertificateInput struct { _ struct{} `type:"structure"` + // The Amazon Resource Name (ARN) of the private certificate authority (CA) + // that will be used to issue the certificate. For more information about private + // CAs, see the AWS Certificate Manager Private Certificate Authority (PCA) + // (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm-pca/latest/userguide/PcaWelcome.html) + // user guide. The ARN must have the following form: + // + // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 + CertificateAuthorityArn *string `min:"20" type:"string"` + // Fully qualified domain name (FQDN), such as www.example.com, of the site // that you want to secure with an ACM Certificate. Use an asterisk (*) to create // a wildcard certificate that protects several sites in the same domain. For @@ -2361,13 +2727,21 @@ type RequestCertificateInput struct { // requesting multiple certificates. IdempotencyToken *string `min:"1" type:"string"` + // Currently, you can use this parameter to specify whether to add the certificate + // to a certificate transparency log. Certificate transparency makes it possible + // to detect SSL/TLS certificates that have been mistakenly or maliciously issued. + // Certificates that have not been logged typically produce an error message + // in a browser. For more information, see Opting Out of Certificate Transparency + // Logging (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/acm-bestpractices.html#best-practices-transparency). + Options *CertificateOptions `type:"structure"` + // Additional FQDNs to be included in the Subject Alternative Name extension - // of the ACM Certificate. For example, add the name www.example.net to a certificate + // of the ACM certificate. For example, add the name www.example.net to a certificate // for which the DomainName field is www.example.com if users can reach your // site by using either name. The maximum number of domain names that you can - // add to an ACM Certificate is 100. However, the initial limit is 10 domain + // add to an ACM certificate is 100. However, the initial limit is 10 domain // names. If you need more than 10 names, you must request a limit increase. - // For more information, see Limits (http://docs.aws.amazon.com/acm/latest/userguide/acm-limits.html). + // For more information, see Limits (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/acm-limits.html). // // The maximum length of a SAN DNS name is 253 octets. The name is made up of // multiple labels separated by periods. No label can be longer than 63 octets. @@ -2385,7 +2759,10 @@ type RequestCertificateInput struct { // the total length of the DNS name (63+1+63+1+63+1+62) exceeds 253 octets. SubjectAlternativeNames []*string `min:"1" type:"list"` - // The method you want to use to validate your domain. + // The method you want to use to validate that you own or control domain. You + // can validate with DNS (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/gs-acm-validate-dns.html) + // or validate with email (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/gs-acm-validate-email.html). + // We recommend that you use DNS validation. ValidationMethod *string `type:"string" enum:"ValidationMethod"` } @@ -2402,6 +2779,9 @@ func (s RequestCertificateInput) GoString() string { // Validate inspects the fields of the type to determine if they are valid. func (s *RequestCertificateInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "RequestCertificateInput"} + if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 20 { + invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 20)) + } if s.DomainName == nil { invalidParams.Add(request.NewErrParamRequired("DomainName")) } @@ -2434,6 +2814,12 @@ func (s *RequestCertificateInput) Validate() error { return nil } +// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. +func (s *RequestCertificateInput) SetCertificateAuthorityArn(v string) *RequestCertificateInput { + s.CertificateAuthorityArn = &v + return s +} + // SetDomainName sets the DomainName field's value. func (s *RequestCertificateInput) SetDomainName(v string) *RequestCertificateInput { s.DomainName = &v @@ -2452,6 +2838,12 @@ func (s *RequestCertificateInput) SetIdempotencyToken(v string) *RequestCertific return s } +// SetOptions sets the Options field's value. +func (s *RequestCertificateInput) SetOptions(v *CertificateOptions) *RequestCertificateInput { + s.Options = v + return s +} + // SetSubjectAlternativeNames sets the SubjectAlternativeNames field's value. func (s *RequestCertificateInput) SetSubjectAlternativeNames(v []*string) *RequestCertificateInput { s.SubjectAlternativeNames = v @@ -2703,6 +3095,81 @@ func (s *Tag) SetValue(v string) *Tag { return s } +type UpdateCertificateOptionsInput struct { + _ struct{} `type:"structure"` + + // ARN of the requested certificate to update. This must be of the form: + // + // arn:aws:acm:us-east-1:account:certificate/12345678-1234-1234-1234-123456789012 + // + // CertificateArn is a required field + CertificateArn *string `min:"20" type:"string" required:"true"` + + // Use to update the options for your certificate. Currently, you can specify + // whether to add your certificate to a transparency log. Certificate transparency + // makes it possible to detect SSL/TLS certificates that have been mistakenly + // or maliciously issued. Certificates that have not been logged typically produce + // an error message in a browser. + // + // Options is a required field + Options *CertificateOptions `type:"structure" required:"true"` +} + +// String returns the string representation +func (s UpdateCertificateOptionsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateCertificateOptionsInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *UpdateCertificateOptionsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateCertificateOptionsInput"} + if s.CertificateArn == nil { + invalidParams.Add(request.NewErrParamRequired("CertificateArn")) + } + if s.CertificateArn != nil && len(*s.CertificateArn) < 20 { + invalidParams.Add(request.NewErrParamMinLen("CertificateArn", 20)) + } + if s.Options == nil { + invalidParams.Add(request.NewErrParamRequired("Options")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetCertificateArn sets the CertificateArn field's value. +func (s *UpdateCertificateOptionsInput) SetCertificateArn(v string) *UpdateCertificateOptionsInput { + s.CertificateArn = &v + return s +} + +// SetOptions sets the Options field's value. +func (s *UpdateCertificateOptionsInput) SetOptions(v *CertificateOptions) *UpdateCertificateOptionsInput { + s.Options = v + return s +} + +type UpdateCertificateOptionsOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s UpdateCertificateOptionsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateCertificateOptionsOutput) GoString() string { + return s.String() +} + const ( // CertificateStatusPendingValidation is a CertificateStatus enum value CertificateStatusPendingValidation = "PENDING_VALIDATION" @@ -2726,12 +3193,23 @@ const ( CertificateStatusFailed = "FAILED" ) +const ( + // CertificateTransparencyLoggingPreferenceEnabled is a CertificateTransparencyLoggingPreference enum value + CertificateTransparencyLoggingPreferenceEnabled = "ENABLED" + + // CertificateTransparencyLoggingPreferenceDisabled is a CertificateTransparencyLoggingPreference enum value + CertificateTransparencyLoggingPreferenceDisabled = "DISABLED" +) + const ( // CertificateTypeImported is a CertificateType enum value CertificateTypeImported = "IMPORTED" // CertificateTypeAmazonIssued is a CertificateType enum value CertificateTypeAmazonIssued = "AMAZON_ISSUED" + + // CertificateTypePrivate is a CertificateType enum value + CertificateTypePrivate = "PRIVATE" ) const ( @@ -2799,6 +3277,24 @@ const ( // FailureReasonCaaError is a FailureReason enum value FailureReasonCaaError = "CAA_ERROR" + // FailureReasonPcaLimitExceeded is a FailureReason enum value + FailureReasonPcaLimitExceeded = "PCA_LIMIT_EXCEEDED" + + // FailureReasonPcaInvalidArn is a FailureReason enum value + FailureReasonPcaInvalidArn = "PCA_INVALID_ARN" + + // FailureReasonPcaInvalidState is a FailureReason enum value + FailureReasonPcaInvalidState = "PCA_INVALID_STATE" + + // FailureReasonPcaRequestFailed is a FailureReason enum value + FailureReasonPcaRequestFailed = "PCA_REQUEST_FAILED" + + // FailureReasonPcaResourceNotFound is a FailureReason enum value + FailureReasonPcaResourceNotFound = "PCA_RESOURCE_NOT_FOUND" + + // FailureReasonPcaInvalidArgs is a FailureReason enum value + FailureReasonPcaInvalidArgs = "PCA_INVALID_ARGS" + // FailureReasonOther is a FailureReason enum value FailureReasonOther = "OTHER" ) @@ -2863,6 +3359,14 @@ const ( RecordTypeCname = "CNAME" ) +const ( + // RenewalEligibilityEligible is a RenewalEligibility enum value + RenewalEligibilityEligible = "ELIGIBLE" + + // RenewalEligibilityIneligible is a RenewalEligibility enum value + RenewalEligibilityIneligible = "INELIGIBLE" +) + const ( // RenewalStatusPendingAutoRenewal is a RenewalStatus enum value RenewalStatusPendingAutoRenewal = "PENDING_AUTO_RENEWAL" diff --git a/vendor/github.com/aws/aws-sdk-go/service/acm/doc.go b/vendor/github.com/aws/aws-sdk-go/service/acm/doc.go index 8a183a969ee6..a8e67c4240d5 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/acm/doc.go +++ b/vendor/github.com/aws/aws-sdk-go/service/acm/doc.go @@ -7,7 +7,7 @@ // // You can use ACM to manage SSL/TLS certificates for your AWS-based websites // and applications. For general information about using ACM, see the AWS Certificate -// Manager User Guide (http://docs.aws.amazon.com/acm/latest/userguide/). +// Manager User Guide (http://docs.aws.amazon.com/http:/docs.aws.amazon.comacm/latest/userguide/). // // See https://docs.aws.amazon.com/goto/WebAPI/acm-2015-12-08 for more information on this service. // diff --git a/vendor/github.com/aws/aws-sdk-go/service/acm/errors.go b/vendor/github.com/aws/aws-sdk-go/service/acm/errors.go index d09bda760b42..421b0d1b625e 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/acm/errors.go +++ b/vendor/github.com/aws/aws-sdk-go/service/acm/errors.go @@ -19,10 +19,7 @@ const ( // ErrCodeInvalidStateException for service response error code // "InvalidStateException". // - // Processing has reached an invalid state. For example, this exception can - // occur if the specified domain is not using email validation, or the current - // certificate status does not permit the requested operation. See the exception - // message returned by ACM to determine which state is not valid. + // Processing has reached an invalid state. ErrCodeInvalidStateException = "InvalidStateException" // ErrCodeInvalidTagException for service response error code @@ -35,11 +32,7 @@ const ( // ErrCodeLimitExceededException for service response error code // "LimitExceededException". // - // An ACM limit has been exceeded. For example, you may have input more domains - // than are allowed or you've requested too many certificates for your account. - // See the exception message returned by ACM to determine which limit you have - // violated. For more information about ACM limits, see the Limits (http://docs.aws.amazon.com/acm/latest/userguide/acm-limits.html) - // topic. + // An ACM limit has been exceeded. ErrCodeLimitExceededException = "LimitExceededException" // ErrCodeRequestInProgressException for service response error code @@ -59,7 +52,7 @@ const ( // ErrCodeResourceNotFoundException for service response error code // "ResourceNotFoundException". // - // The specified certificate cannot be found in the caller's account, or the + // The specified certificate cannot be found in the caller's account or the // caller's account cannot be found. ErrCodeResourceNotFoundException = "ResourceNotFoundException" diff --git a/vendor/github.com/aws/aws-sdk-go/service/apigateway/api.go b/vendor/github.com/aws/aws-sdk-go/service/apigateway/api.go index 656830a9a16d..95cf464ad4fa 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/apigateway/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/apigateway/api.go @@ -16,7 +16,7 @@ const opCreateApiKey = "CreateApiKey" // CreateApiKeyRequest generates a "aws/request.Request" representing the // client's request for the CreateApiKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -112,7 +112,7 @@ const opCreateAuthorizer = "CreateAuthorizer" // CreateAuthorizerRequest generates a "aws/request.Request" representing the // client's request for the CreateAuthorizer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -204,7 +204,7 @@ const opCreateBasePathMapping = "CreateBasePathMapping" // CreateBasePathMappingRequest generates a "aws/request.Request" representing the // client's request for the CreateBasePathMapping operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -295,7 +295,7 @@ const opCreateDeployment = "CreateDeployment" // CreateDeploymentRequest generates a "aws/request.Request" representing the // client's request for the CreateDeployment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -394,7 +394,7 @@ const opCreateDocumentationPart = "CreateDocumentationPart" // CreateDocumentationPartRequest generates a "aws/request.Request" representing the // client's request for the CreateDocumentationPart operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -486,7 +486,7 @@ const opCreateDocumentationVersion = "CreateDocumentationVersion" // CreateDocumentationVersionRequest generates a "aws/request.Request" representing the // client's request for the CreateDocumentationVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -578,7 +578,7 @@ const opCreateDomainName = "CreateDomainName" // CreateDomainNameRequest generates a "aws/request.Request" representing the // client's request for the CreateDomainName operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -666,7 +666,7 @@ const opCreateModel = "CreateModel" // CreateModelRequest generates a "aws/request.Request" representing the // client's request for the CreateModel operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -760,7 +760,7 @@ const opCreateRequestValidator = "CreateRequestValidator" // CreateRequestValidatorRequest generates a "aws/request.Request" representing the // client's request for the CreateRequestValidator operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -850,7 +850,7 @@ const opCreateResource = "CreateResource" // CreateResourceRequest generates a "aws/request.Request" representing the // client's request for the CreateResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -944,7 +944,7 @@ const opCreateRestApi = "CreateRestApi" // CreateRestApiRequest generates a "aws/request.Request" representing the // client's request for the CreateRestApi operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1031,7 +1031,7 @@ const opCreateStage = "CreateStage" // CreateStageRequest generates a "aws/request.Request" representing the // client's request for the CreateStage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1126,7 +1126,7 @@ const opCreateUsagePlan = "CreateUsagePlan" // CreateUsagePlanRequest generates a "aws/request.Request" representing the // client's request for the CreateUsagePlan operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1221,7 +1221,7 @@ const opCreateUsagePlanKey = "CreateUsagePlanKey" // CreateUsagePlanKeyRequest generates a "aws/request.Request" representing the // client's request for the CreateUsagePlanKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1312,7 +1312,7 @@ const opCreateVpcLink = "CreateVpcLink" // CreateVpcLinkRequest generates a "aws/request.Request" representing the // client's request for the CreateVpcLink operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1399,7 +1399,7 @@ const opDeleteApiKey = "DeleteApiKey" // DeleteApiKeyRequest generates a "aws/request.Request" representing the // client's request for the DeleteApiKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1484,7 +1484,7 @@ const opDeleteAuthorizer = "DeleteAuthorizer" // DeleteAuthorizerRequest generates a "aws/request.Request" representing the // client's request for the DeleteAuthorizer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1579,7 +1579,7 @@ const opDeleteBasePathMapping = "DeleteBasePathMapping" // DeleteBasePathMappingRequest generates a "aws/request.Request" representing the // client's request for the DeleteBasePathMapping operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1672,7 +1672,7 @@ const opDeleteClientCertificate = "DeleteClientCertificate" // DeleteClientCertificateRequest generates a "aws/request.Request" representing the // client's request for the DeleteClientCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1761,7 +1761,7 @@ const opDeleteDeployment = "DeleteDeployment" // DeleteDeploymentRequest generates a "aws/request.Request" representing the // client's request for the DeleteDeployment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1851,7 +1851,7 @@ const opDeleteDocumentationPart = "DeleteDocumentationPart" // DeleteDocumentationPartRequest generates a "aws/request.Request" representing the // client's request for the DeleteDocumentationPart operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1942,7 +1942,7 @@ const opDeleteDocumentationVersion = "DeleteDocumentationVersion" // DeleteDocumentationVersionRequest generates a "aws/request.Request" representing the // client's request for the DeleteDocumentationVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2033,7 +2033,7 @@ const opDeleteDomainName = "DeleteDomainName" // DeleteDomainNameRequest generates a "aws/request.Request" representing the // client's request for the DeleteDomainName operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2118,7 +2118,7 @@ const opDeleteGatewayResponse = "DeleteGatewayResponse" // DeleteGatewayResponseRequest generates a "aws/request.Request" representing the // client's request for the DeleteGatewayResponse operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2212,7 +2212,7 @@ const opDeleteIntegration = "DeleteIntegration" // DeleteIntegrationRequest generates a "aws/request.Request" representing the // client's request for the DeleteIntegration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2301,7 +2301,7 @@ const opDeleteIntegrationResponse = "DeleteIntegrationResponse" // DeleteIntegrationResponseRequest generates a "aws/request.Request" representing the // client's request for the DeleteIntegrationResponse operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2394,7 +2394,7 @@ const opDeleteMethod = "DeleteMethod" // DeleteMethodRequest generates a "aws/request.Request" representing the // client's request for the DeleteMethod operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2483,7 +2483,7 @@ const opDeleteMethodResponse = "DeleteMethodResponse" // DeleteMethodResponseRequest generates a "aws/request.Request" representing the // client's request for the DeleteMethodResponse operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2576,7 +2576,7 @@ const opDeleteModel = "DeleteModel" // DeleteModelRequest generates a "aws/request.Request" representing the // client's request for the DeleteModel operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2669,7 +2669,7 @@ const opDeleteRequestValidator = "DeleteRequestValidator" // DeleteRequestValidatorRequest generates a "aws/request.Request" representing the // client's request for the DeleteRequestValidator operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2762,7 +2762,7 @@ const opDeleteResource = "DeleteResource" // DeleteResourceRequest generates a "aws/request.Request" representing the // client's request for the DeleteResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2855,7 +2855,7 @@ const opDeleteRestApi = "DeleteRestApi" // DeleteRestApiRequest generates a "aws/request.Request" representing the // client's request for the DeleteRestApi operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2944,7 +2944,7 @@ const opDeleteStage = "DeleteStage" // DeleteStageRequest generates a "aws/request.Request" representing the // client's request for the DeleteStage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3033,7 +3033,7 @@ const opDeleteUsagePlan = "DeleteUsagePlan" // DeleteUsagePlanRequest generates a "aws/request.Request" representing the // client's request for the DeleteUsagePlan operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3122,7 +3122,7 @@ const opDeleteUsagePlanKey = "DeleteUsagePlanKey" // DeleteUsagePlanKeyRequest generates a "aws/request.Request" representing the // client's request for the DeleteUsagePlanKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3216,7 +3216,7 @@ const opDeleteVpcLink = "DeleteVpcLink" // DeleteVpcLinkRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpcLink operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3305,7 +3305,7 @@ const opFlushStageAuthorizersCache = "FlushStageAuthorizersCache" // FlushStageAuthorizersCacheRequest generates a "aws/request.Request" representing the // client's request for the FlushStageAuthorizersCache operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3394,7 +3394,7 @@ const opFlushStageCache = "FlushStageCache" // FlushStageCacheRequest generates a "aws/request.Request" representing the // client's request for the FlushStageCache operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3483,7 +3483,7 @@ const opGenerateClientCertificate = "GenerateClientCertificate" // GenerateClientCertificateRequest generates a "aws/request.Request" representing the // client's request for the GenerateClientCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3566,7 +3566,7 @@ const opGetAccount = "GetAccount" // GetAccountRequest generates a "aws/request.Request" representing the // client's request for the GetAccount operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3649,7 +3649,7 @@ const opGetApiKey = "GetApiKey" // GetApiKeyRequest generates a "aws/request.Request" representing the // client's request for the GetApiKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3732,7 +3732,7 @@ const opGetApiKeys = "GetApiKeys" // GetApiKeysRequest generates a "aws/request.Request" representing the // client's request for the GetApiKeys operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3872,7 +3872,7 @@ const opGetAuthorizer = "GetAuthorizer" // GetAuthorizerRequest generates a "aws/request.Request" representing the // client's request for the GetAuthorizer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3957,7 +3957,7 @@ const opGetAuthorizers = "GetAuthorizers" // GetAuthorizersRequest generates a "aws/request.Request" representing the // client's request for the GetAuthorizers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4046,7 +4046,7 @@ const opGetBasePathMapping = "GetBasePathMapping" // GetBasePathMappingRequest generates a "aws/request.Request" representing the // client's request for the GetBasePathMapping operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4129,7 +4129,7 @@ const opGetBasePathMappings = "GetBasePathMappings" // GetBasePathMappingsRequest generates a "aws/request.Request" representing the // client's request for the GetBasePathMappings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4268,7 +4268,7 @@ const opGetClientCertificate = "GetClientCertificate" // GetClientCertificateRequest generates a "aws/request.Request" representing the // client's request for the GetClientCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4351,7 +4351,7 @@ const opGetClientCertificates = "GetClientCertificates" // GetClientCertificatesRequest generates a "aws/request.Request" representing the // client's request for the GetClientCertificates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4491,7 +4491,7 @@ const opGetDeployment = "GetDeployment" // GetDeploymentRequest generates a "aws/request.Request" representing the // client's request for the GetDeployment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4578,7 +4578,7 @@ const opGetDeployments = "GetDeployments" // GetDeploymentsRequest generates a "aws/request.Request" representing the // client's request for the GetDeployments operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4722,7 +4722,7 @@ const opGetDocumentationPart = "GetDocumentationPart" // GetDocumentationPartRequest generates a "aws/request.Request" representing the // client's request for the GetDocumentationPart operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4803,7 +4803,7 @@ const opGetDocumentationParts = "GetDocumentationParts" // GetDocumentationPartsRequest generates a "aws/request.Request" representing the // client's request for the GetDocumentationParts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4888,7 +4888,7 @@ const opGetDocumentationVersion = "GetDocumentationVersion" // GetDocumentationVersionRequest generates a "aws/request.Request" representing the // client's request for the GetDocumentationVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4969,7 +4969,7 @@ const opGetDocumentationVersions = "GetDocumentationVersions" // GetDocumentationVersionsRequest generates a "aws/request.Request" representing the // client's request for the GetDocumentationVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5054,7 +5054,7 @@ const opGetDomainName = "GetDomainName" // GetDomainNameRequest generates a "aws/request.Request" representing the // client's request for the GetDomainName operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5142,7 +5142,7 @@ const opGetDomainNames = "GetDomainNames" // GetDomainNamesRequest generates a "aws/request.Request" representing the // client's request for the GetDomainNames operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5282,7 +5282,7 @@ const opGetExport = "GetExport" // GetExportRequest generates a "aws/request.Request" representing the // client's request for the GetExport operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5373,7 +5373,7 @@ const opGetGatewayResponse = "GetGatewayResponse" // GetGatewayResponseRequest generates a "aws/request.Request" representing the // client's request for the GetGatewayResponse operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5456,7 +5456,7 @@ const opGetGatewayResponses = "GetGatewayResponses" // GetGatewayResponsesRequest generates a "aws/request.Request" representing the // client's request for the GetGatewayResponses operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5546,7 +5546,7 @@ const opGetIntegration = "GetIntegration" // GetIntegrationRequest generates a "aws/request.Request" representing the // client's request for the GetIntegration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5629,7 +5629,7 @@ const opGetIntegrationResponse = "GetIntegrationResponse" // GetIntegrationResponseRequest generates a "aws/request.Request" representing the // client's request for the GetIntegrationResponse operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5712,7 +5712,7 @@ const opGetMethod = "GetMethod" // GetMethodRequest generates a "aws/request.Request" representing the // client's request for the GetMethod operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5795,7 +5795,7 @@ const opGetMethodResponse = "GetMethodResponse" // GetMethodResponseRequest generates a "aws/request.Request" representing the // client's request for the GetMethodResponse operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5878,7 +5878,7 @@ const opGetModel = "GetModel" // GetModelRequest generates a "aws/request.Request" representing the // client's request for the GetModel operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5961,7 +5961,7 @@ const opGetModelTemplate = "GetModelTemplate" // GetModelTemplateRequest generates a "aws/request.Request" representing the // client's request for the GetModelTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6049,7 +6049,7 @@ const opGetModels = "GetModels" // GetModelsRequest generates a "aws/request.Request" representing the // client's request for the GetModels operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6192,7 +6192,7 @@ const opGetRequestValidator = "GetRequestValidator" // GetRequestValidatorRequest generates a "aws/request.Request" representing the // client's request for the GetRequestValidator operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6275,7 +6275,7 @@ const opGetRequestValidators = "GetRequestValidators" // GetRequestValidatorsRequest generates a "aws/request.Request" representing the // client's request for the GetRequestValidators operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6362,7 +6362,7 @@ const opGetResource = "GetResource" // GetResourceRequest generates a "aws/request.Request" representing the // client's request for the GetResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6445,7 +6445,7 @@ const opGetResources = "GetResources" // GetResourcesRequest generates a "aws/request.Request" representing the // client's request for the GetResources operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6588,7 +6588,7 @@ const opGetRestApi = "GetRestApi" // GetRestApiRequest generates a "aws/request.Request" representing the // client's request for the GetRestApi operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6671,7 +6671,7 @@ const opGetRestApis = "GetRestApis" // GetRestApisRequest generates a "aws/request.Request" representing the // client's request for the GetRestApis operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6811,7 +6811,7 @@ const opGetSdk = "GetSdk" // GetSdkRequest generates a "aws/request.Request" representing the // client's request for the GetSdk operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6902,7 +6902,7 @@ const opGetSdkType = "GetSdkType" // GetSdkTypeRequest generates a "aws/request.Request" representing the // client's request for the GetSdkType operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6983,7 +6983,7 @@ const opGetSdkTypes = "GetSdkTypes" // GetSdkTypesRequest generates a "aws/request.Request" representing the // client's request for the GetSdkTypes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7061,7 +7061,7 @@ const opGetStage = "GetStage" // GetStageRequest generates a "aws/request.Request" representing the // client's request for the GetStage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7144,7 +7144,7 @@ const opGetStages = "GetStages" // GetStagesRequest generates a "aws/request.Request" representing the // client's request for the GetStages operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7227,7 +7227,7 @@ const opGetTags = "GetTags" // GetTagsRequest generates a "aws/request.Request" representing the // client's request for the GetTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7317,7 +7317,7 @@ const opGetUsage = "GetUsage" // GetUsageRequest generates a "aws/request.Request" representing the // client's request for the GetUsage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7460,7 +7460,7 @@ const opGetUsagePlan = "GetUsagePlan" // GetUsagePlanRequest generates a "aws/request.Request" representing the // client's request for the GetUsagePlan operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7547,7 +7547,7 @@ const opGetUsagePlanKey = "GetUsagePlanKey" // GetUsagePlanKeyRequest generates a "aws/request.Request" representing the // client's request for the GetUsagePlanKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7634,7 +7634,7 @@ const opGetUsagePlanKeys = "GetUsagePlanKeys" // GetUsagePlanKeysRequest generates a "aws/request.Request" representing the // client's request for the GetUsagePlanKeys operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7778,7 +7778,7 @@ const opGetUsagePlans = "GetUsagePlans" // GetUsagePlansRequest generates a "aws/request.Request" representing the // client's request for the GetUsagePlans operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7925,7 +7925,7 @@ const opGetVpcLink = "GetVpcLink" // GetVpcLinkRequest generates a "aws/request.Request" representing the // client's request for the GetVpcLink operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8008,7 +8008,7 @@ const opGetVpcLinks = "GetVpcLinks" // GetVpcLinksRequest generates a "aws/request.Request" representing the // client's request for the GetVpcLinks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8148,7 +8148,7 @@ const opImportApiKeys = "ImportApiKeys" // ImportApiKeysRequest generates a "aws/request.Request" representing the // client's request for the ImportApiKeys operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8242,7 +8242,7 @@ const opImportDocumentationParts = "ImportDocumentationParts" // ImportDocumentationPartsRequest generates a "aws/request.Request" representing the // client's request for the ImportDocumentationParts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8330,7 +8330,7 @@ const opImportRestApi = "ImportRestApi" // ImportRestApiRequest generates a "aws/request.Request" representing the // client's request for the ImportRestApi operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8422,7 +8422,7 @@ const opPutGatewayResponse = "PutGatewayResponse" // PutGatewayResponseRequest generates a "aws/request.Request" representing the // client's request for the PutGatewayResponse operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8513,7 +8513,7 @@ const opPutIntegration = "PutIntegration" // PutIntegrationRequest generates a "aws/request.Request" representing the // client's request for the PutIntegration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8604,7 +8604,7 @@ const opPutIntegrationResponse = "PutIntegrationResponse" // PutIntegrationResponseRequest generates a "aws/request.Request" representing the // client's request for the PutIntegrationResponse operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8698,7 +8698,7 @@ const opPutMethod = "PutMethod" // PutMethodRequest generates a "aws/request.Request" representing the // client's request for the PutMethod operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8792,7 +8792,7 @@ const opPutMethodResponse = "PutMethodResponse" // PutMethodResponseRequest generates a "aws/request.Request" representing the // client's request for the PutMethodResponse operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8886,7 +8886,7 @@ const opPutRestApi = "PutRestApi" // PutRestApiRequest generates a "aws/request.Request" representing the // client's request for the PutRestApi operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8983,7 +8983,7 @@ const opTagResource = "TagResource" // TagResourceRequest generates a "aws/request.Request" representing the // client's request for the TagResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9023,7 +9023,7 @@ func (c *APIGateway) TagResourceRequest(input *TagResourceInput) (req *request.R // TagResource API operation for Amazon API Gateway. // -// Adds or updates Tags on a gievn resource. +// Adds or updates a tag on a given resource. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -9079,7 +9079,7 @@ const opTestInvokeAuthorizer = "TestInvokeAuthorizer" // TestInvokeAuthorizerRequest generates a "aws/request.Request" representing the // client's request for the TestInvokeAuthorizer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9169,7 +9169,7 @@ const opTestInvokeMethod = "TestInvokeMethod" // TestInvokeMethodRequest generates a "aws/request.Request" representing the // client's request for the TestInvokeMethod operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9257,7 +9257,7 @@ const opUntagResource = "UntagResource" // UntagResourceRequest generates a "aws/request.Request" representing the // client's request for the UntagResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9297,7 +9297,7 @@ func (c *APIGateway) UntagResourceRequest(input *UntagResourceInput) (req *reque // UntagResource API operation for Amazon API Gateway. // -// Removes Tags from a given resource. +// Removes a tag from a given resource. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -9350,7 +9350,7 @@ const opUpdateAccount = "UpdateAccount" // UpdateAccountRequest generates a "aws/request.Request" representing the // client's request for the UpdateAccount operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9437,7 +9437,7 @@ const opUpdateApiKey = "UpdateApiKey" // UpdateApiKeyRequest generates a "aws/request.Request" representing the // client's request for the UpdateApiKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9528,7 +9528,7 @@ const opUpdateAuthorizer = "UpdateAuthorizer" // UpdateAuthorizerRequest generates a "aws/request.Request" representing the // client's request for the UpdateAuthorizer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9617,7 +9617,7 @@ const opUpdateBasePathMapping = "UpdateBasePathMapping" // UpdateBasePathMappingRequest generates a "aws/request.Request" representing the // client's request for the UpdateBasePathMapping operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9708,7 +9708,7 @@ const opUpdateClientCertificate = "UpdateClientCertificate" // UpdateClientCertificateRequest generates a "aws/request.Request" representing the // client's request for the UpdateClientCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9795,7 +9795,7 @@ const opUpdateDeployment = "UpdateDeployment" // UpdateDeploymentRequest generates a "aws/request.Request" representing the // client's request for the UpdateDeployment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9886,7 +9886,7 @@ const opUpdateDocumentationPart = "UpdateDocumentationPart" // UpdateDocumentationPartRequest generates a "aws/request.Request" representing the // client's request for the UpdateDocumentationPart operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9978,7 +9978,7 @@ const opUpdateDocumentationVersion = "UpdateDocumentationVersion" // UpdateDocumentationVersionRequest generates a "aws/request.Request" representing the // client's request for the UpdateDocumentationVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10067,7 +10067,7 @@ const opUpdateDomainName = "UpdateDomainName" // UpdateDomainNameRequest generates a "aws/request.Request" representing the // client's request for the UpdateDomainName operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10158,7 +10158,7 @@ const opUpdateGatewayResponse = "UpdateGatewayResponse" // UpdateGatewayResponseRequest generates a "aws/request.Request" representing the // client's request for the UpdateGatewayResponse operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10245,7 +10245,7 @@ const opUpdateIntegration = "UpdateIntegration" // UpdateIntegrationRequest generates a "aws/request.Request" representing the // client's request for the UpdateIntegration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10336,7 +10336,7 @@ const opUpdateIntegrationResponse = "UpdateIntegrationResponse" // UpdateIntegrationResponseRequest generates a "aws/request.Request" representing the // client's request for the UpdateIntegrationResponse operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10427,7 +10427,7 @@ const opUpdateMethod = "UpdateMethod" // UpdateMethodRequest generates a "aws/request.Request" representing the // client's request for the UpdateMethod operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10518,7 +10518,7 @@ const opUpdateMethodResponse = "UpdateMethodResponse" // UpdateMethodResponseRequest generates a "aws/request.Request" representing the // client's request for the UpdateMethodResponse operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10612,7 +10612,7 @@ const opUpdateModel = "UpdateModel" // UpdateModelRequest generates a "aws/request.Request" representing the // client's request for the UpdateModel operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10703,7 +10703,7 @@ const opUpdateRequestValidator = "UpdateRequestValidator" // UpdateRequestValidatorRequest generates a "aws/request.Request" representing the // client's request for the UpdateRequestValidator operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10790,7 +10790,7 @@ const opUpdateResource = "UpdateResource" // UpdateResourceRequest generates a "aws/request.Request" representing the // client's request for the UpdateResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10881,7 +10881,7 @@ const opUpdateRestApi = "UpdateRestApi" // UpdateRestApiRequest generates a "aws/request.Request" representing the // client's request for the UpdateRestApi operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10972,7 +10972,7 @@ const opUpdateStage = "UpdateStage" // UpdateStageRequest generates a "aws/request.Request" representing the // client's request for the UpdateStage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11063,7 +11063,7 @@ const opUpdateUsage = "UpdateUsage" // UpdateUsageRequest generates a "aws/request.Request" representing the // client's request for the UpdateUsage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11151,7 +11151,7 @@ const opUpdateUsagePlan = "UpdateUsagePlan" // UpdateUsagePlanRequest generates a "aws/request.Request" representing the // client's request for the UpdateUsagePlan operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11242,7 +11242,7 @@ const opUpdateVpcLink = "UpdateVpcLink" // UpdateVpcLinkRequest generates a "aws/request.Request" representing the // client's request for the UpdateVpcLink operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11623,11 +11623,11 @@ type Authorizer struct { // The identifier for the authorizer resource. Id *string `locationName:"id" type:"string"` - // The identity source for which authorization is requested. For a TOKEN authorizer, - // this is required and specifies the request header mapping expression for - // the custom header holding the authorization token submitted by the client. - // For example, if the token header name is Auth, the header mapping expression - // is method.request.header.Auth. + // The identity source for which authorization is requested. For a TOKEN or + // COGNITO_USER_POOLS authorizer, this is required and specifies the request + // header mapping expression for the custom header holding the authorization + // token submitted by the client. For example, if the token header name is Auth, + // the header mapping expression is method.request.header.Auth. // For the REQUEST authorizer, this is required when authorization caching is // enabled. The value is a comma-separated string of one or more mapping expressions // of the specified request parameters. For example, if an Auth header, a Name @@ -11640,16 +11640,14 @@ type Authorizer struct { // response without calling the Lambda function. The valid value is a string // of comma-separated mapping expressions of the specified request parameters. // When the authorization caching is not enabled, this property is optional. - // - // For a COGNITO_USER_POOLS authorizer, this property is not used. IdentitySource *string `locationName:"identitySource" type:"string"` // A validation expression for the incoming identity token. For TOKEN authorizers, - // this value is a regular expression. API Gateway will match the incoming token - // from the client against the specified regular expression. It will invoke - // the authorizer's Lambda function there is a match. Otherwise, it will return - // a 401 Unauthorized response without calling the Lambda function. The validation - // expression does not apply to the REQUEST authorizer. + // this value is a regular expression. API Gateway will match the aud field + // of the incoming token from the client against the specified regular expression. + // It will invoke the authorizer's Lambda function when there is a match. Otherwise, + // it will return a 401 Unauthorized response without calling the Lambda function. + // The validation expression does not apply to the REQUEST authorizer. IdentityValidationExpression *string `locationName:"identityValidationExpression" type:"string"` // [Required] The name of the authorizer. @@ -11660,10 +11658,10 @@ type Authorizer struct { // For a TOKEN or REQUEST authorizer, this is not defined. ProviderARNs []*string `locationName:"providerARNs" type:"list"` - // [Required] The authorizer type. Valid values are TOKEN for a Lambda function - // using a single authorization token submitted in a custom header, REQUEST - // for a Lambda function using incoming request parameters, and COGNITO_USER_POOLS - // for using an Amazon Cognito user pool. + // The authorizer type. Valid values are TOKEN for a Lambda function using a + // single authorization token submitted in a custom header, REQUEST for a Lambda + // function using incoming request parameters, and COGNITO_USER_POOLS for using + // an Amazon Cognito user pool. Type *string `locationName:"type" type:"string" enum:"AuthorizerType"` } @@ -12016,11 +12014,11 @@ type CreateAuthorizerInput struct { // is usually of the form /2015-03-31/functions/[FunctionARN]/invocations. AuthorizerUri *string `locationName:"authorizerUri" type:"string"` - // The identity source for which authorization is requested. For a TOKEN authorizer, - // this is required and specifies the request header mapping expression for - // the custom header holding the authorization token submitted by the client. - // For example, if the token header name is Auth, the header mapping expression - // is method.request.header.Auth. + // The identity source for which authorization is requested. For a TOKEN or + // COGNITO_USER_POOLS authorizer, this is required and specifies the request + // header mapping expression for the custom header holding the authorization + // token submitted by the client. For example, if the token header name is Auth, + // the header mapping expression is method.request.header.Auth. // For the REQUEST authorizer, this is required when authorization caching is // enabled. The value is a comma-separated string of one or more mapping expressions // of the specified request parameters. For example, if an Auth header, a Name @@ -12033,16 +12031,14 @@ type CreateAuthorizerInput struct { // response without calling the Lambda function. The valid value is a string // of comma-separated mapping expressions of the specified request parameters. // When the authorization caching is not enabled, this property is optional. - // - // For a COGNITO_USER_POOLS authorizer, this property is not used. IdentitySource *string `locationName:"identitySource" type:"string"` // A validation expression for the incoming identity token. For TOKEN authorizers, - // this value is a regular expression. API Gateway will match the incoming token - // from the client against the specified regular expression. It will invoke - // the authorizer's Lambda function there is a match. Otherwise, it will return - // a 401 Unauthorized response without calling the Lambda function. The validation - // expression does not apply to the REQUEST authorizer. + // this value is a regular expression. API Gateway will match the aud field + // of the incoming token from the client against the specified regular expression. + // It will invoke the authorizer's Lambda function when there is a match. Otherwise, + // it will return a 401 Unauthorized response without calling the Lambda function. + // The validation expression does not apply to the REQUEST authorizer. IdentityValidationExpression *string `locationName:"identityValidationExpression" type:"string"` // [Required] The name of the authorizer. @@ -12055,7 +12051,7 @@ type CreateAuthorizerInput struct { // For a TOKEN or REQUEST authorizer, this is not defined. ProviderARNs []*string `locationName:"providerARNs" type:"list"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -12168,12 +12164,12 @@ type CreateBasePathMappingInput struct { // a base path name after the domain name. BasePath *string `locationName:"basePath" type:"string"` - // The domain name of the BasePathMapping resource to create. + // [Required] The domain name of the BasePathMapping resource to create. // // DomainName is a required field DomainName *string `location:"uri" locationName:"domain_name" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `locationName:"restApiId" type:"string" required:"true"` @@ -12252,7 +12248,7 @@ type CreateDeploymentInput struct { // The description for the Deployment resource to create. Description *string `locationName:"description" type:"string"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -12516,7 +12512,7 @@ type CreateDomainNameInput struct { // key. CertificatePrivateKey *string `locationName:"certificatePrivateKey" type:"string"` - // (Required) The name of the DomainName resource. + // [Required] The name of the DomainName resource. // // DomainName is a required field DomainName *string `locationName:"domainName" type:"string" required:"true"` @@ -12616,7 +12612,7 @@ func (s *CreateDomainNameInput) SetRegionalCertificateName(v string) *CreateDoma type CreateModelInput struct { _ struct{} `type:"structure"` - // The content-type for the model. + // [Required] The content-type for the model. // // ContentType is a required field ContentType *string `locationName:"contentType" type:"string" required:"true"` @@ -12624,18 +12620,18 @@ type CreateModelInput struct { // The description of the model. Description *string `locationName:"description" type:"string"` - // The name of the model. Must be alphanumeric. + // [Required] The name of the model. Must be alphanumeric. // // Name is a required field Name *string `locationName:"name" type:"string" required:"true"` - // The RestApi identifier under which the Model will be created. + // [Required] The RestApi identifier under which the Model will be created. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` - // The schema for the model. For application/json models, this should be JSON-schema - // draft v4 (http://json-schema.org/documentation.html) model. + // The schema for the model. For application/json models, this should be JSON + // schema draft 4 (https://tools.ietf.org/html/draft-zyp-json-schema-04) model. Schema *string `locationName:"schema" type:"string"` } @@ -12705,7 +12701,7 @@ type CreateRequestValidatorInput struct { // The name of the to-be-created RequestValidator. Name *string `locationName:"name" type:"string"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -12770,7 +12766,7 @@ func (s *CreateRequestValidatorInput) SetValidateRequestParameters(v bool) *Crea type CreateResourceInput struct { _ struct{} `type:"structure"` - // The parent resource's identifier. + // [Required] The parent resource's identifier. // // ParentId is a required field ParentId *string `location:"uri" locationName:"parent_id" type:"string" required:"true"` @@ -12780,7 +12776,7 @@ type CreateResourceInput struct { // PathPart is a required field PathPart *string `locationName:"pathPart" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -12837,8 +12833,8 @@ func (s *CreateResourceInput) SetRestApiId(v string) *CreateResourceInput { type CreateRestApiInput struct { _ struct{} `type:"structure"` - // The source of the API key for metring requests according to a usage plan. - // Valid values are HEADER to read the API key from the X-API-Key header of + // The source of the API key for metering requests according to a usage plan. + // Valid values are: HEADER to read the API key from the X-API-Key header of // a request. // AUTHORIZER to read the API key from the UsageIdentifierKey from a custom // authorizer. @@ -12858,18 +12854,22 @@ type CreateRestApiInput struct { // the API. EndpointConfiguration *EndpointConfiguration `locationName:"endpointConfiguration" type:"structure"` - // A nullable integer used to enable (non-negative between 0 and 10485760 (10M) - // bytes, inclusive) or disable (null) compression on an API. When compression - // is enabled, compression or decompression are not applied on the payload if - // the payload size is smaller than this value. Setting it to zero allows compression - // for any payload size. + // A nullable integer that is used to enable compression (with non-negative + // between 0 and 10485760 (10M) bytes, inclusive) or disable compression (with + // a null value) on an API. When compression is enabled, compression or decompression + // is not applied on the payload if the payload size is smaller than this value. + // Setting it to zero allows compression for any payload size. MinimumCompressionSize *int64 `locationName:"minimumCompressionSize" type:"integer"` - // The name of the RestApi. + // [Required] The name of the RestApi. // // Name is a required field Name *string `locationName:"name" type:"string" required:"true"` + // A stringified JSON policy document that applies to this RestApi regardless + // of the caller and Method + Policy *string `locationName:"policy" type:"string"` + // A version identifier for the API. Version *string `locationName:"version" type:"string"` } @@ -12939,6 +12939,12 @@ func (s *CreateRestApiInput) SetName(v string) *CreateRestApiInput { return s } +// SetPolicy sets the Policy field's value. +func (s *CreateRestApiInput) SetPolicy(v string) *CreateRestApiInput { + s.Policy = &v + return s +} + // SetVersion sets the Version field's value. func (s *CreateRestApiInput) SetVersion(v string) *CreateRestApiInput { s.Version = &v @@ -12969,7 +12975,7 @@ type CreateStageInput struct { // The version of the associated API documentation. DocumentationVersion *string `locationName:"documentationVersion" type:"string"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -12979,9 +12985,9 @@ type CreateStageInput struct { // StageName is a required field StageName *string `locationName:"stageName" type:"string" required:"true"` - // Key/Value map of strings. Valid character set is [a-zA-Z+-=._:/]. Tag key - // can be up to 128 characters and must not start with "aws:". Tag value can - // be up to 256 characters. + // The key-value map of strings. The valid character set is [a-zA-Z+-=._:/]. + // The tag key can be up to 128 characters and must not start with aws:. The + // tag value can be up to 256 characters. Tags map[string]*string `locationName:"tags" type:"map"` // A map that defines the stage variables for the new Stage resource. Variable @@ -13091,7 +13097,7 @@ type CreateUsagePlanInput struct { // The description of the usage plan. Description *string `locationName:"description" type:"string"` - // The name of the usage plan. + // [Required] The name of the usage plan. // // Name is a required field Name *string `locationName:"name" type:"string" required:"true"` @@ -13161,18 +13167,18 @@ func (s *CreateUsagePlanInput) SetThrottle(v *ThrottleSettings) *CreateUsagePlan type CreateUsagePlanKeyInput struct { _ struct{} `type:"structure"` - // The identifier of a UsagePlanKey resource for a plan customer. + // [Required] The identifier of a UsagePlanKey resource for a plan customer. // // KeyId is a required field KeyId *string `locationName:"keyId" type:"string" required:"true"` - // The type of a UsagePlanKey resource for a plan customer. + // [Required] The type of a UsagePlanKey resource for a plan customer. // // KeyType is a required field KeyType *string `locationName:"keyType" type:"string" required:"true"` - // The Id of the UsagePlan resource representing the usage plan containing the - // to-be-created UsagePlanKey resource representing a plan customer. + // [Required] The Id of the UsagePlan resource representing the usage plan containing + // the to-be-created UsagePlanKey resource representing a plan customer. // // UsagePlanId is a required field UsagePlanId *string `location:"uri" locationName:"usageplanId" type:"string" required:"true"` @@ -13296,7 +13302,7 @@ func (s *CreateVpcLinkInput) SetTargetArns(v []*string) *CreateVpcLinkInput { type DeleteApiKeyInput struct { _ struct{} `type:"structure"` - // The identifier of the ApiKey resource to be deleted. + // [Required] The identifier of the ApiKey resource to be deleted. // // ApiKey is a required field ApiKey *string `location:"uri" locationName:"api_Key" type:"string" required:"true"` @@ -13349,12 +13355,12 @@ func (s DeleteApiKeyOutput) GoString() string { type DeleteAuthorizerInput struct { _ struct{} `type:"structure"` - // The identifier of the Authorizer resource. + // [Required] The identifier of the Authorizer resource. // // AuthorizerId is a required field AuthorizerId *string `location:"uri" locationName:"authorizer_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -13416,12 +13422,12 @@ func (s DeleteAuthorizerOutput) GoString() string { type DeleteBasePathMappingInput struct { _ struct{} `type:"structure"` - // The base path name of the BasePathMapping resource to delete. + // [Required] The base path name of the BasePathMapping resource to delete. // // BasePath is a required field BasePath *string `location:"uri" locationName:"base_path" type:"string" required:"true"` - // The domain name of the BasePathMapping resource to delete. + // [Required] The domain name of the BasePathMapping resource to delete. // // DomainName is a required field DomainName *string `location:"uri" locationName:"domain_name" type:"string" required:"true"` @@ -13483,7 +13489,7 @@ func (s DeleteBasePathMappingOutput) GoString() string { type DeleteClientCertificateInput struct { _ struct{} `type:"structure"` - // The identifier of the ClientCertificate resource to be deleted. + // [Required] The identifier of the ClientCertificate resource to be deleted. // // ClientCertificateId is a required field ClientCertificateId *string `location:"uri" locationName:"clientcertificate_id" type:"string" required:"true"` @@ -13536,12 +13542,12 @@ func (s DeleteClientCertificateOutput) GoString() string { type DeleteDeploymentInput struct { _ struct{} `type:"structure"` - // The identifier of the Deployment resource to delete. + // [Required] The identifier of the Deployment resource to delete. // // DeploymentId is a required field DeploymentId *string `location:"uri" locationName:"deployment_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -13737,7 +13743,7 @@ func (s DeleteDocumentationVersionOutput) GoString() string { type DeleteDomainNameInput struct { _ struct{} `type:"structure"` - // The name of the DomainName resource to be deleted. + // [Required] The name of the DomainName resource to be deleted. // // DomainName is a required field DomainName *string `location:"uri" locationName:"domain_name" type:"string" required:"true"` @@ -13791,8 +13797,8 @@ func (s DeleteDomainNameOutput) GoString() string { type DeleteGatewayResponseInput struct { _ struct{} `type:"structure"` - // The response type of the associated GatewayResponse. Valid values are ACCESS_DENIED - // + // [Required] The response type of the associated GatewayResponse. Valid values + // are ACCESS_DENIED // API_CONFIGURATION_ERROR // AUTHORIZER_FAILURE // AUTHORIZER_CONFIGURATION_ERROR @@ -13811,12 +13817,12 @@ type DeleteGatewayResponseInput struct { // RESOURCE_NOT_FOUND // THROTTLED // UNAUTHORIZED - // UNSUPPORTED_MEDIA_TYPES + // UNSUPPORTED_MEDIA_TYPE // // ResponseType is a required field ResponseType *string `location:"uri" locationName:"response_type" type:"string" required:"true" enum:"GatewayResponseType"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -13878,17 +13884,17 @@ func (s DeleteGatewayResponseOutput) GoString() string { type DeleteIntegrationInput struct { _ struct{} `type:"structure"` - // Specifies a delete integration request's HTTP method. + // [Required] Specifies a delete integration request's HTTP method. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` - // Specifies a delete integration request's resource identifier. + // [Required] Specifies a delete integration request's resource identifier. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -13959,22 +13965,22 @@ func (s DeleteIntegrationOutput) GoString() string { type DeleteIntegrationResponseInput struct { _ struct{} `type:"structure"` - // Specifies a delete integration response request's HTTP method. + // [Required] Specifies a delete integration response request's HTTP method. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` - // Specifies a delete integration response request's resource identifier. + // [Required] Specifies a delete integration response request's resource identifier. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` - // Specifies a delete integration response request's status code. + // [Required] Specifies a delete integration response request's status code. // // StatusCode is a required field StatusCode *string `location:"uri" locationName:"status_code" type:"string" required:"true"` @@ -14054,17 +14060,17 @@ func (s DeleteIntegrationResponseOutput) GoString() string { type DeleteMethodInput struct { _ struct{} `type:"structure"` - // The HTTP verb of the Method resource. + // [Required] The HTTP verb of the Method resource. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` - // The Resource identifier for the Method resource. + // [Required] The Resource identifier for the Method resource. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -14135,22 +14141,22 @@ func (s DeleteMethodOutput) GoString() string { type DeleteMethodResponseInput struct { _ struct{} `type:"structure"` - // The HTTP verb of the Method resource. + // [Required] The HTTP verb of the Method resource. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` - // The Resource identifier for the MethodResponse resource. + // [Required] The Resource identifier for the MethodResponse resource. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` - // The status code identifier for the MethodResponse resource. + // [Required] The status code identifier for the MethodResponse resource. // // StatusCode is a required field StatusCode *string `location:"uri" locationName:"status_code" type:"string" required:"true"` @@ -14230,12 +14236,12 @@ func (s DeleteMethodResponseOutput) GoString() string { type DeleteModelInput struct { _ struct{} `type:"structure"` - // The name of the model to delete. + // [Required] The name of the model to delete. // // ModelName is a required field ModelName *string `location:"uri" locationName:"model_name" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -14302,7 +14308,7 @@ type DeleteRequestValidatorInput struct { // RequestValidatorId is a required field RequestValidatorId *string `location:"uri" locationName:"requestvalidator_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -14364,12 +14370,12 @@ func (s DeleteRequestValidatorOutput) GoString() string { type DeleteResourceInput struct { _ struct{} `type:"structure"` - // The identifier of the Resource resource. + // [Required] The identifier of the Resource resource. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -14431,7 +14437,7 @@ func (s DeleteResourceOutput) GoString() string { type DeleteRestApiInput struct { _ struct{} `type:"structure"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -14484,12 +14490,12 @@ func (s DeleteRestApiOutput) GoString() string { type DeleteStageInput struct { _ struct{} `type:"structure"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` - // The name of the Stage resource to delete. + // [Required] The name of the Stage resource to delete. // // StageName is a required field StageName *string `location:"uri" locationName:"stage_name" type:"string" required:"true"` @@ -14551,7 +14557,7 @@ func (s DeleteStageOutput) GoString() string { type DeleteUsagePlanInput struct { _ struct{} `type:"structure"` - // The Id of the to-be-deleted usage plan. + // [Required] The Id of the to-be-deleted usage plan. // // UsagePlanId is a required field UsagePlanId *string `location:"uri" locationName:"usageplanId" type:"string" required:"true"` @@ -14591,13 +14597,13 @@ func (s *DeleteUsagePlanInput) SetUsagePlanId(v string) *DeleteUsagePlanInput { type DeleteUsagePlanKeyInput struct { _ struct{} `type:"structure"` - // The Id of the UsagePlanKey resource to be deleted. + // [Required] The Id of the UsagePlanKey resource to be deleted. // // KeyId is a required field KeyId *string `location:"uri" locationName:"keyId" type:"string" required:"true"` - // The Id of the UsagePlan resource representing the usage plan containing the - // to-be-deleted UsagePlanKey resource representing a plan customer. + // [Required] The Id of the UsagePlan resource representing the usage plan containing + // the to-be-deleted UsagePlanKey resource representing a plan customer. // // UsagePlanId is a required field UsagePlanId *string `location:"uri" locationName:"usageplanId" type:"string" required:"true"` @@ -14933,12 +14939,11 @@ type DocumentationPartLocation struct { // of the parent entity exactly. StatusCode *string `locationName:"statusCode" type:"string"` - // The type of API entity to which the documentation content applies. It is - // a valid and required field for API entity types of API, AUTHORIZER, MODEL, - // RESOURCE, METHOD, PATH_PARAMETER, QUERY_PARAMETER, REQUEST_HEADER, REQUEST_BODY, - // RESPONSE, RESPONSE_HEADER, and RESPONSE_BODY. Content inheritance does not - // apply to any entity of the API, AUTHORIZER, METHOD, MODEL, REQUEST_BODY, - // or RESOURCE type. + // [Required] The type of API entity to which the documentation content applies. + // Valid values are API, AUTHORIZER, MODEL, RESOURCE, METHOD, PATH_PARAMETER, + // QUERY_PARAMETER, REQUEST_HEADER, REQUEST_BODY, RESPONSE, RESPONSE_HEADER, + // and RESPONSE_BODY. Content inheritance does not apply to any entity of the + // API, AUTHORIZER, METHOD, MODEL, REQUEST_BODY, or RESOURCE type. // // Type is a required field Type *string `locationName:"type" type:"string" required:"true" enum:"DocumentationPartType"` @@ -15087,7 +15092,7 @@ type DomainName struct { // and AWS Regions and Endpoints for API Gateway (http://docs.aws.amazon.com/general/latest/gr/rande.html#apigateway_region). DistributionHostedZoneId *string `locationName:"distributionHostedZoneId" type:"string"` - // The name of the DomainName resource. + // The custom domain name as an API host name, for example, my-api.example.com. DomainName *string `locationName:"domainName" type:"string"` // The endpoint configuration of this DomainName showing the endpoint types @@ -15289,12 +15294,12 @@ func (s FlushStageAuthorizersCacheOutput) GoString() string { type FlushStageCacheInput struct { _ struct{} `type:"structure"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` - // The name of the stage to flush its cache. + // [Required] The name of the stage to flush its cache. // // StageName is a required field StageName *string `location:"uri" locationName:"stage_name" type:"string" required:"true"` @@ -15395,7 +15400,7 @@ func (s GetAccountInput) GoString() string { type GetApiKeyInput struct { _ struct{} `type:"structure"` - // The identifier of the ApiKey resource. + // [Required] The identifier of the ApiKey resource. // // ApiKey is a required field ApiKey *string `location:"uri" locationName:"api_Key" type:"string" required:"true"` @@ -15452,7 +15457,8 @@ type GetApiKeysInput struct { // key values. IncludeValues *bool `location:"querystring" locationName:"includeValues" type:"boolean"` - // The maximum number of returned results per page. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The name of queried API keys. @@ -15550,12 +15556,12 @@ func (s *GetApiKeysOutput) SetWarnings(v []*string) *GetApiKeysOutput { type GetAuthorizerInput struct { _ struct{} `type:"structure"` - // The identifier of the Authorizer resource. + // [Required] The identifier of the Authorizer resource. // // AuthorizerId is a required field AuthorizerId *string `location:"uri" locationName:"authorizer_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -15603,13 +15609,14 @@ func (s *GetAuthorizerInput) SetRestApiId(v string) *GetAuthorizerInput { type GetAuthorizersInput struct { _ struct{} `type:"structure"` - // The maximum number of returned results per page. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The current pagination position in the paged result set. Position *string `location:"querystring" locationName:"position" type:"string"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -15694,15 +15701,15 @@ func (s *GetAuthorizersOutput) SetPosition(v string) *GetAuthorizersOutput { type GetBasePathMappingInput struct { _ struct{} `type:"structure"` - // The base path name that callers of the API must provide as part of the URL - // after the domain name. This value must be unique for all of the mappings - // across a single API. Leave this blank if you do not want callers to specify - // any base path name after the domain name. + // [Required] The base path name that callers of the API must provide as part + // of the URL after the domain name. This value must be unique for all of the + // mappings across a single API. Leave this blank if you do not want callers + // to specify any base path name after the domain name. // // BasePath is a required field BasePath *string `location:"uri" locationName:"base_path" type:"string" required:"true"` - // The domain name of the BasePathMapping resource to be described. + // [Required] The domain name of the BasePathMapping resource to be described. // // DomainName is a required field DomainName *string `location:"uri" locationName:"domain_name" type:"string" required:"true"` @@ -15750,13 +15757,13 @@ func (s *GetBasePathMappingInput) SetDomainName(v string) *GetBasePathMappingInp type GetBasePathMappingsInput struct { _ struct{} `type:"structure"` - // The domain name of a BasePathMapping resource. + // [Required] The domain name of a BasePathMapping resource. // // DomainName is a required field DomainName *string `location:"uri" locationName:"domain_name" type:"string" required:"true"` - // The maximum number of returned results per page. The value is 25 by default - // and could be between 1 - 500. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The current pagination position in the paged result set. @@ -15842,7 +15849,7 @@ func (s *GetBasePathMappingsOutput) SetPosition(v string) *GetBasePathMappingsOu type GetClientCertificateInput struct { _ struct{} `type:"structure"` - // The identifier of the ClientCertificate resource to be described. + // [Required] The identifier of the ClientCertificate resource to be described. // // ClientCertificateId is a required field ClientCertificateId *string `location:"uri" locationName:"clientcertificate_id" type:"string" required:"true"` @@ -15881,8 +15888,8 @@ func (s *GetClientCertificateInput) SetClientCertificateId(v string) *GetClientC type GetClientCertificatesInput struct { _ struct{} `type:"structure"` - // The maximum number of returned results per page. The value is 25 by default - // and could be between 1 - 500. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The current pagination position in the paged result set. @@ -15949,7 +15956,7 @@ func (s *GetClientCertificatesOutput) SetPosition(v string) *GetClientCertificat type GetDeploymentInput struct { _ struct{} `type:"structure"` - // The identifier of the Deployment resource to get information about. + // [Required] The identifier of the Deployment resource to get information about. // // DeploymentId is a required field DeploymentId *string `location:"uri" locationName:"deployment_id" type:"string" required:"true"` @@ -15963,7 +15970,7 @@ type GetDeploymentInput struct { // list containing only the "apisummary" string. For example, GET /restapis/{restapi_id}/deployments/{deployment_id}?embed=apisummary. Embed []*string `location:"querystring" locationName:"embed" type:"list"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -16017,14 +16024,14 @@ func (s *GetDeploymentInput) SetRestApiId(v string) *GetDeploymentInput { type GetDeploymentsInput struct { _ struct{} `type:"structure"` - // The maximum number of returned results per page. The value is 25 by default - // and could be between 1 - 500. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The current pagination position in the paged result set. Position *string `location:"querystring" locationName:"position" type:"string"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -16172,7 +16179,8 @@ func (s *GetDocumentationPartInput) SetRestApiId(v string) *GetDocumentationPart type GetDocumentationPartsInput struct { _ struct{} `type:"structure"` - // The maximum number of returned results per page. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The status of the API documentation parts to retrieve. Valid values are DOCUMENTED @@ -16354,7 +16362,8 @@ func (s *GetDocumentationVersionInput) SetRestApiId(v string) *GetDocumentationV type GetDocumentationVersionsInput struct { _ struct{} `type:"structure"` - // The maximum number of returned results per page. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The current pagination position in the paged result set. @@ -16449,7 +16458,7 @@ func (s *GetDocumentationVersionsOutput) SetPosition(v string) *GetDocumentation type GetDomainNameInput struct { _ struct{} `type:"structure"` - // The name of the DomainName resource. + // [Required] The name of the DomainName resource. // // DomainName is a required field DomainName *string `location:"uri" locationName:"domain_name" type:"string" required:"true"` @@ -16488,8 +16497,8 @@ func (s *GetDomainNameInput) SetDomainName(v string) *GetDomainNameInput { type GetDomainNamesInput struct { _ struct{} `type:"structure"` - // The maximum number of returned results per page. The value is 25 by default - // and could be between 1 - 500. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The current pagination position in the paged result set. @@ -16561,7 +16570,7 @@ type GetExportInput struct { // be specified in the Accept header for direct API requests. Accepts *string `location:"header" locationName:"Accept" type:"string"` - // The type of export. Currently only 'swagger' is supported. + // [Required] The type of export. Currently only 'swagger' is supported. // // ExportType is a required field ExportType *string `location:"uri" locationName:"export_type" type:"string" required:"true"` @@ -16575,12 +16584,12 @@ type GetExportInput struct { // tool Parameters map[string]*string `location:"querystring" locationName:"parameters" type:"map"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` - // The name of the Stage that will be exported. + // [Required] The name of the Stage that will be exported. // // StageName is a required field StageName *string `location:"uri" locationName:"stage_name" type:"string" required:"true"` @@ -16692,8 +16701,8 @@ func (s *GetExportOutput) SetContentType(v string) *GetExportOutput { type GetGatewayResponseInput struct { _ struct{} `type:"structure"` - // The response type of the associated GatewayResponse. Valid values are ACCESS_DENIED - // + // [Required] The response type of the associated GatewayResponse. Valid values + // are ACCESS_DENIED // API_CONFIGURATION_ERROR // AUTHORIZER_FAILURE // AUTHORIZER_CONFIGURATION_ERROR @@ -16712,12 +16721,12 @@ type GetGatewayResponseInput struct { // RESOURCE_NOT_FOUND // THROTTLED // UNAUTHORIZED - // UNSUPPORTED_MEDIA_TYPES + // UNSUPPORTED_MEDIA_TYPE // // ResponseType is a required field ResponseType *string `location:"uri" locationName:"response_type" type:"string" required:"true" enum:"GatewayResponseType"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -16768,15 +16777,16 @@ func (s *GetGatewayResponseInput) SetRestApiId(v string) *GetGatewayResponseInpu type GetGatewayResponsesInput struct { _ struct{} `type:"structure"` - // The maximum number of returned results per page. The GatewayResponses collection - // does not support pagination and the limit does not apply here. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. The GatewayResponses collection does not support + // pagination and the limit does not apply here. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The current pagination position in the paged result set. The GatewayResponse // collection does not support pagination and the position does not apply here. Position *string `location:"querystring" locationName:"position" type:"string"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -17018,17 +17028,17 @@ func (s *GetGatewayResponsesOutput) SetPosition(v string) *GetGatewayResponsesOu type GetIntegrationInput struct { _ struct{} `type:"structure"` - // Specifies a get integration request's HTTP method. + // [Required] Specifies a get integration request's HTTP method. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` - // Specifies a get integration request's resource identifier + // [Required] Specifies a get integration request's resource identifier // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -17085,22 +17095,22 @@ func (s *GetIntegrationInput) SetRestApiId(v string) *GetIntegrationInput { type GetIntegrationResponseInput struct { _ struct{} `type:"structure"` - // Specifies a get integration response request's HTTP method. + // [Required] Specifies a get integration response request's HTTP method. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` - // Specifies a get integration response request's resource identifier. + // [Required] Specifies a get integration response request's resource identifier. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` - // Specifies a get integration response request's status code. + // [Required] Specifies a get integration response request's status code. // // StatusCode is a required field StatusCode *string `location:"uri" locationName:"status_code" type:"string" required:"true"` @@ -17166,17 +17176,17 @@ func (s *GetIntegrationResponseInput) SetStatusCode(v string) *GetIntegrationRes type GetMethodInput struct { _ struct{} `type:"structure"` - // Specifies the method request's HTTP method type. + // [Required] Specifies the method request's HTTP method type. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` - // The Resource identifier for the Method resource. + // [Required] The Resource identifier for the Method resource. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -17233,22 +17243,22 @@ func (s *GetMethodInput) SetRestApiId(v string) *GetMethodInput { type GetMethodResponseInput struct { _ struct{} `type:"structure"` - // The HTTP verb of the Method resource. + // [Required] The HTTP verb of the Method resource. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` - // The Resource identifier for the MethodResponse resource. + // [Required] The Resource identifier for the MethodResponse resource. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` - // The status code for the MethodResponse resource. + // [Required] The status code for the MethodResponse resource. // // StatusCode is a required field StatusCode *string `location:"uri" locationName:"status_code" type:"string" required:"true"` @@ -17319,12 +17329,12 @@ type GetModelInput struct { // is false. Flatten *bool `location:"querystring" locationName:"flatten" type:"boolean"` - // The name of the model as an identifier. + // [Required] The name of the model as an identifier. // // ModelName is a required field ModelName *string `location:"uri" locationName:"model_name" type:"string" required:"true"` - // The RestApi identifier under which the Model exists. + // [Required] The RestApi identifier under which the Model exists. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -17378,12 +17388,12 @@ func (s *GetModelInput) SetRestApiId(v string) *GetModelInput { type GetModelTemplateInput struct { _ struct{} `type:"structure"` - // The name of the model for which to generate a template. + // [Required] The name of the model for which to generate a template. // // ModelName is a required field ModelName *string `location:"uri" locationName:"model_name" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -17458,14 +17468,14 @@ func (s *GetModelTemplateOutput) SetValue(v string) *GetModelTemplateOutput { type GetModelsInput struct { _ struct{} `type:"structure"` - // The maximum number of returned results per page. The value is 25 by default - // and could be between 1 - 500. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The current pagination position in the paged result set. Position *string `location:"querystring" locationName:"position" type:"string"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -17555,7 +17565,7 @@ type GetRequestValidatorInput struct { // RequestValidatorId is a required field RequestValidatorId *string `location:"uri" locationName:"requestvalidator_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -17603,13 +17613,14 @@ func (s *GetRequestValidatorInput) SetRestApiId(v string) *GetRequestValidatorIn type GetRequestValidatorsInput struct { _ struct{} `type:"structure"` - // The maximum number of returned results per page. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The current pagination position in the paged result set. Position *string `location:"querystring" locationName:"position" type:"string"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -17706,12 +17717,12 @@ type GetResourceInput struct { // /restapis/{restapi_id}/resources/{resource_id}?embed=methods. Embed []*string `location:"querystring" locationName:"embed" type:"list"` - // The identifier for the Resource resource. + // [Required] The identifier for the Resource resource. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -17773,14 +17784,14 @@ type GetResourcesInput struct { // /restapis/{restapi_id}/resources?embed=methods. Embed []*string `location:"querystring" locationName:"embed" type:"list"` - // The maximum number of returned results per page. The value is 25 by default - // and could be between 1 - 500. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The current pagination position in the paged result set. Position *string `location:"querystring" locationName:"position" type:"string"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -17871,7 +17882,7 @@ func (s *GetResourcesOutput) SetPosition(v string) *GetResourcesOutput { type GetRestApiInput struct { _ struct{} `type:"structure"` - // The identifier of the RestApi resource. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -17910,8 +17921,8 @@ func (s *GetRestApiInput) SetRestApiId(v string) *GetRestApiInput { type GetRestApisInput struct { _ struct{} `type:"structure"` - // The maximum number of returned results per page. The value is 25 by default - // and could be between 1 - 500. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The current pagination position in the paged result set. @@ -17986,18 +17997,18 @@ type GetSdkInput struct { // named serviceName and javaPackageName are required. Parameters map[string]*string `location:"querystring" locationName:"parameters" type:"map"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` - // The language for the generated SDK. Currently java, javascript, android, - // objectivec (for iOS), swift (for iOS), and ruby are supported. + // [Required] The language for the generated SDK. Currently java, javascript, + // android, objectivec (for iOS), swift (for iOS), and ruby are supported. // // SdkType is a required field SdkType *string `location:"uri" locationName:"sdk_type" type:"string" required:"true"` - // The name of the Stage that the SDK will use. + // [Required] The name of the Stage that the SDK will use. // // StageName is a required field StageName *string `location:"uri" locationName:"stage_name" type:"string" required:"true"` @@ -18102,7 +18113,7 @@ func (s *GetSdkOutput) SetContentType(v string) *GetSdkOutput { type GetSdkTypeInput struct { _ struct{} `type:"structure"` - // The identifier of the queried SdkType instance. + // [Required] The identifier of the queried SdkType instance. // // Id is a required field Id *string `location:"uri" locationName:"sdktype_id" type:"string" required:"true"` @@ -18141,7 +18152,8 @@ func (s *GetSdkTypeInput) SetId(v string) *GetSdkTypeInput { type GetSdkTypesInput struct { _ struct{} `type:"structure"` - // The maximum number of returned results per page. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The current pagination position in the paged result set. @@ -18206,12 +18218,12 @@ func (s *GetSdkTypesOutput) SetPosition(v string) *GetSdkTypesOutput { type GetStageInput struct { _ struct{} `type:"structure"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` - // The name of the Stage resource to get information about. + // [Required] The name of the Stage resource to get information about. // // StageName is a required field StageName *string `location:"uri" locationName:"stage_name" type:"string" required:"true"` @@ -18262,7 +18274,7 @@ type GetStagesInput struct { // The stages' deployment identifiers. DeploymentId *string `location:"querystring" locationName:"deploymentId" type:"string"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -18334,14 +18346,15 @@ type GetTagsInput struct { _ struct{} `type:"structure"` // (Not currently supported) The maximum number of returned results per page. + // The default value is 25 and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // (Not currently supported) The current pagination position in the paged result // set. Position *string `location:"querystring" locationName:"position" type:"string"` - // [Required] The ARN of a resource that can be tagged. At present, Stage is - // the only taggable resource. + // [Required] The ARN of a resource that can be tagged. The resource ARN must + // be URL-encoded. At present, Stage is the only taggable resource. // // ResourceArn is a required field ResourceArn *string `location:"uri" locationName:"resource_arn" type:"string" required:"true"` @@ -18388,11 +18401,11 @@ func (s *GetTagsInput) SetResourceArn(v string) *GetTagsInput { return s } -// A collection of Tags associated with a given resource. +// The collection of tags. Each tag element is associated with a given resource. type GetTagsOutput struct { _ struct{} `type:"structure"` - // A collection of Tags associated with a given resource. + // The collection of tags. Each tag element is associated with a given resource. Tags map[string]*string `locationName:"tags" type:"map"` } @@ -18417,7 +18430,7 @@ func (s *GetTagsOutput) SetTags(v map[string]*string) *GetTagsOutput { type GetUsageInput struct { _ struct{} `type:"structure"` - // The ending date (e.g., 2016-12-31) of the usage data. + // [Required] The ending date (e.g., 2016-12-31) of the usage data. // // EndDate is a required field EndDate *string `location:"querystring" locationName:"endDate" type:"string" required:"true"` @@ -18425,18 +18438,19 @@ type GetUsageInput struct { // The Id of the API key associated with the resultant usage data. KeyId *string `location:"querystring" locationName:"keyId" type:"string"` - // The maximum number of returned results per page. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The current pagination position in the paged result set. Position *string `location:"querystring" locationName:"position" type:"string"` - // The starting date (e.g., 2016-01-01) of the usage data. + // [Required] The starting date (e.g., 2016-01-01) of the usage data. // // StartDate is a required field StartDate *string `location:"querystring" locationName:"startDate" type:"string" required:"true"` - // The Id of the usage plan associated with the usage data. + // [Required] The Id of the usage plan associated with the usage data. // // UsagePlanId is a required field UsagePlanId *string `location:"uri" locationName:"usageplanId" type:"string" required:"true"` @@ -18511,7 +18525,7 @@ func (s *GetUsageInput) SetUsagePlanId(v string) *GetUsageInput { type GetUsagePlanInput struct { _ struct{} `type:"structure"` - // The identifier of the UsagePlan resource to be retrieved. + // [Required] The identifier of the UsagePlan resource to be retrieved. // // UsagePlanId is a required field UsagePlanId *string `location:"uri" locationName:"usageplanId" type:"string" required:"true"` @@ -18550,14 +18564,14 @@ func (s *GetUsagePlanInput) SetUsagePlanId(v string) *GetUsagePlanInput { type GetUsagePlanKeyInput struct { _ struct{} `type:"structure"` - // The key Id of the to-be-retrieved UsagePlanKey resource representing a plan - // customer. + // [Required] The key Id of the to-be-retrieved UsagePlanKey resource representing + // a plan customer. // // KeyId is a required field KeyId *string `location:"uri" locationName:"keyId" type:"string" required:"true"` - // The Id of the UsagePlan resource representing the usage plan containing the - // to-be-retrieved UsagePlanKey resource representing a plan customer. + // [Required] The Id of the UsagePlan resource representing the usage plan containing + // the to-be-retrieved UsagePlanKey resource representing a plan customer. // // UsagePlanId is a required field UsagePlanId *string `location:"uri" locationName:"usageplanId" type:"string" required:"true"` @@ -18606,7 +18620,8 @@ func (s *GetUsagePlanKeyInput) SetUsagePlanId(v string) *GetUsagePlanKeyInput { type GetUsagePlanKeysInput struct { _ struct{} `type:"structure"` - // The maximum number of returned results per page. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // A query parameter specifying the name of the to-be-returned usage plan keys. @@ -18615,8 +18630,8 @@ type GetUsagePlanKeysInput struct { // The current pagination position in the paged result set. Position *string `location:"querystring" locationName:"position" type:"string"` - // The Id of the UsagePlan resource representing the usage plan containing the - // to-be-retrieved UsagePlanKey resource representing a plan customer. + // [Required] The Id of the UsagePlan resource representing the usage plan containing + // the to-be-retrieved UsagePlanKey resource representing a plan customer. // // UsagePlanId is a required field UsagePlanId *string `location:"uri" locationName:"usageplanId" type:"string" required:"true"` @@ -18711,7 +18726,8 @@ type GetUsagePlansInput struct { // The identifier of the API key associated with the usage plans. KeyId *string `location:"querystring" locationName:"keyId" type:"string"` - // The maximum number of returned results per page. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The current pagination position in the paged result set. @@ -18824,7 +18840,8 @@ func (s *GetVpcLinkInput) SetVpcLinkId(v string) *GetVpcLinkInput { type GetVpcLinksInput struct { _ struct{} `type:"structure"` - // The maximum number of returned results per page. + // The maximum number of returned results per page. The default value is 25 + // and the maximum value is 500. Limit *int64 `location:"querystring" locationName:"limit" type:"integer"` // The current pagination position in the paged result set. @@ -19107,9 +19124,9 @@ func (s *ImportDocumentationPartsOutput) SetWarnings(v []*string) *ImportDocumen type ImportRestApiInput struct { _ struct{} `type:"structure" payload:"Body"` - // The POST request body containing external API definitions. Currently, only - // Swagger definition JSON files are supported. The maximum size of the API - // definition file is 2MB. + // [Required] The POST request body containing external API definitions. Currently, + // only Swagger definition JSON files are supported. The maximum size of the + // API definition file is 2MB. // // Body is a required field Body []byte `locationName:"body" type:"blob" required:"true"` @@ -19611,13 +19628,13 @@ type Method struct { ApiKeyRequired *bool `locationName:"apiKeyRequired" type:"boolean"` // A list of authorization scopes configured on the method. The scopes are used - // with a COGNITO_USER_POOL authorizer to authorize the method invocation. The - // authorization works by matching the method scopes against the scopes parsed - // from the access token in the incoming request. The method invocation is authorized - // if any method scopes matches a claimed scope in the access token. Otherwise, - // the invocation is not authorized. When the method scope is configured, the - // client must provide an access token instead of an identity token for authorization - // purposes. + // with a COGNITO_USER_POOLS authorizer to authorize the method invocation. + // The authorization works by matching the method scopes against the scopes + // parsed from the access token in the incoming request. The method invocation + // is authorized if any method scopes matches a claimed scope in the access + // token. Otherwise, the invocation is not authorized. When the method scope + // is configured, the client must provide an access token instead of an identity + // token for authorization purposes. AuthorizationScopes []*string `locationName:"authorizationScopes" type:"list"` // The method's authorization type. Valid values are NONE for open access, AWS_IAM @@ -20070,12 +20087,12 @@ type Model struct { // The name of the model. Must be an alphanumeric string. Name *string `locationName:"name" type:"string"` - // The schema for the model. For application/json models, this should be JSON-schema - // draft v4 (http://json-schema.org/documentation.html) model. Do not include - // "\*/" characters in the description of any properties because such "\*/" - // characters may be interpreted as the closing marker for comments in some - // languages, such as Java or JavaScript, causing the installation of your API's - // SDK generated by API Gateway to fail. + // The schema for the model. For application/json models, this should be JSON + // schema draft 4 (https://tools.ietf.org/html/draft-zyp-json-schema-04) model. + // Do not include "\*/" characters in the description of any properties because + // such "\*/" characters may be interpreted as the closing marker for comments + // in some languages, such as Java or JavaScript, causing the installation of + // your API's SDK generated by API Gateway to fail. Schema *string `locationName:"schema" type:"string"` } @@ -20203,8 +20220,8 @@ type PutGatewayResponseInput struct { // pairs. ResponseTemplates map[string]*string `locationName:"responseTemplates" type:"map"` - // The response type of the associated GatewayResponse. Valid values are ACCESS_DENIED - // + // [Required] The response type of the associated GatewayResponse. Valid values + // are ACCESS_DENIED // API_CONFIGURATION_ERROR // AUTHORIZER_FAILURE // AUTHORIZER_CONFIGURATION_ERROR @@ -20223,12 +20240,12 @@ type PutGatewayResponseInput struct { // RESOURCE_NOT_FOUND // THROTTLED // UNAUTHORIZED - // UNSUPPORTED_MEDIA_TYPES + // UNSUPPORTED_MEDIA_TYPE // // ResponseType is a required field ResponseType *string `location:"uri" locationName:"response_type" type:"string" required:"true" enum:"GatewayResponseType"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -20331,7 +20348,7 @@ type PutIntegrationInput struct { // Specifies whether credentials are required for a put integration. Credentials *string `locationName:"credentials" type:"string"` - // Specifies a put integration request's HTTP method. + // [Required] Specifies a put integration request's HTTP method. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` @@ -20371,12 +20388,12 @@ type PutIntegrationInput struct { // value. RequestTemplates map[string]*string `locationName:"requestTemplates" type:"map"` - // Specifies a put integration request's resource ID. + // [Required] Specifies a put integration request's resource ID. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -20385,7 +20402,7 @@ type PutIntegrationInput struct { // milliseconds or 29 seconds. TimeoutInMillis *int64 `locationName:"timeoutInMillis" type:"integer"` - // Specifies a put integration input's type. + // [Required] Specifies a put integration input's type. // // Type is a required field Type *string `locationName:"type" type:"string" required:"true" enum:"IntegrationType"` @@ -20559,12 +20576,12 @@ type PutIntegrationResponseInput struct { // from the integration response to the method response without modification. ContentHandling *string `locationName:"contentHandling" type:"string" enum:"ContentHandlingStrategy"` - // Specifies a put integration response request's HTTP method. + // [Required] Specifies a put integration response request's HTTP method. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` - // Specifies a put integration response request's resource identifier. + // [Required] Specifies a put integration response request's resource identifier. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` @@ -20584,7 +20601,7 @@ type PutIntegrationResponseInput struct { // Specifies a put integration response's templates. ResponseTemplates map[string]*string `locationName:"responseTemplates" type:"map"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -20592,8 +20609,8 @@ type PutIntegrationResponseInput struct { // Specifies the selection pattern of a put integration response. SelectionPattern *string `locationName:"selectionPattern" type:"string"` - // Specifies the status code that is used to map the integration response to - // an existing MethodResponse. + // [Required] Specifies the status code that is used to map the integration + // response to an existing MethodResponse. // // StatusCode is a required field StatusCode *string `location:"uri" locationName:"status_code" type:"string" required:"true"` @@ -20687,27 +20704,28 @@ type PutMethodInput struct { ApiKeyRequired *bool `locationName:"apiKeyRequired" type:"boolean"` // A list of authorization scopes configured on the method. The scopes are used - // with a COGNITO_USER_POOL authorizer to authorize the method invocation. The - // authorization works by matching the method scopes against the scopes parsed - // from the access token in the incoming request. The method invocation is authorized - // if any method scopes matches a claimed scope in the access token. Otherwise, - // the invocation is not authorized. When the method scope is configured, the - // client must provide an access token instead of an identity token for authorization - // purposes. + // with a COGNITO_USER_POOLS authorizer to authorize the method invocation. + // The authorization works by matching the method scopes against the scopes + // parsed from the access token in the incoming request. The method invocation + // is authorized if any method scopes matches a claimed scope in the access + // token. Otherwise, the invocation is not authorized. When the method scope + // is configured, the client must provide an access token instead of an identity + // token for authorization purposes. AuthorizationScopes []*string `locationName:"authorizationScopes" type:"list"` - // The method's authorization type. Valid values are NONE for open access, AWS_IAM - // for using AWS IAM permissions, CUSTOM for using a custom authorizer, or COGNITO_USER_POOLS - // for using a Cognito user pool. + // [Required] The method's authorization type. Valid values are NONE for open + // access, AWS_IAM for using AWS IAM permissions, CUSTOM for using a custom + // authorizer, or COGNITO_USER_POOLS for using a Cognito user pool. // // AuthorizationType is a required field AuthorizationType *string `locationName:"authorizationType" type:"string" required:"true"` // Specifies the identifier of an Authorizer to use on this Method, if the type - // is CUSTOM. + // is CUSTOM or COGNITO_USER_POOLS. The authorizer identifier is generated by + // API Gateway when you created the authorizer. AuthorizerId *string `locationName:"authorizerId" type:"string"` - // Specifies the method request's HTTP method type. + // [Required] Specifies the method request's HTTP method type. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` @@ -20735,12 +20753,12 @@ type PutMethodInput struct { // The identifier of a RequestValidator for validating the method request. RequestValidatorId *string `locationName:"requestValidatorId" type:"string"` - // The Resource identifier for the new Method resource. + // [Required] The Resource identifier for the new Method resource. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -20848,12 +20866,12 @@ func (s *PutMethodInput) SetRestApiId(v string) *PutMethodInput { type PutMethodResponseInput struct { _ struct{} `type:"structure"` - // The HTTP verb of the Method resource. + // [Required] The HTTP verb of the Method resource. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` - // The Resource identifier for the Method resource. + // [Required] The Resource identifier for the Method resource. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` @@ -20876,12 +20894,12 @@ type PutMethodResponseInput struct { // where JSON-expression is a valid JSON expression without the $ prefix.) ResponseParameters map[string]*bool `locationName:"responseParameters" type:"map"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` - // The method response's status code. + // [Required] The method response's status code. // // StatusCode is a required field StatusCode *string `location:"uri" locationName:"status_code" type:"string" required:"true"` @@ -20960,9 +20978,9 @@ func (s *PutMethodResponseInput) SetStatusCode(v string) *PutMethodResponseInput type PutRestApiInput struct { _ struct{} `type:"structure" payload:"Body"` - // The PUT request body containing external API definitions. Currently, only - // Swagger definition JSON files are supported. The maximum size of the API - // definition file is 2MB. + // [Required] The PUT request body containing external API definitions. Currently, + // only Swagger definition JSON files are supported. The maximum size of the + // API definition file is 2MB. // // Body is a required field Body []byte `locationName:"body" type:"blob" required:"true"` @@ -20981,7 +20999,7 @@ type PutRestApiInput struct { // ignore=documentation --body 'file:///path/to/imported-api-body.json. Parameters map[string]*string `location:"querystring" locationName:"parameters" type:"map"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -21211,8 +21229,8 @@ func (s *Resource) SetResourceMethods(v map[string]*Method) *Resource { type RestApi struct { _ struct{} `type:"structure"` - // The source of the API key for metring requests according to a usage plan. - // Valid values are HEADER to read the API key from the X-API-Key header of + // The source of the API key for metering requests according to a usage plan. + // Valid values are: HEADER to read the API key from the X-API-Key header of // a request. // AUTHORIZER to read the API key from the UsageIdentifierKey from a custom // authorizer. @@ -21236,16 +21254,20 @@ type RestApi struct { // API Gateway. Id *string `locationName:"id" type:"string"` - // A nullable integer used to enable (non-negative between 0 and 10485760 (10M) - // bytes, inclusive) or disable (null) compression on an API. When compression - // is enabled, compression or decompression are not applied on the payload if - // the payload size is smaller than this value. Setting it to zero allows compression - // for any payload size. + // A nullable integer that is used to enable compression (with non-negative + // between 0 and 10485760 (10M) bytes, inclusive) or disable compression (with + // a null value) on an API. When compression is enabled, compression or decompression + // is not applied on the payload if the payload size is smaller than this value. + // Setting it to zero allows compression for any payload size. MinimumCompressionSize *int64 `locationName:"minimumCompressionSize" type:"integer"` // The API's name. Name *string `locationName:"name" type:"string"` + // A stringified JSON policy document that applies to this RestApi regardless + // of the caller and Method + Policy *string `locationName:"policy" type:"string"` + // A version identifier for the API. Version *string `locationName:"version" type:"string"` @@ -21312,6 +21334,12 @@ func (s *RestApi) SetName(v string) *RestApi { return s } +// SetPolicy sets the Policy field's value. +func (s *RestApi) SetPolicy(v string) *RestApi { + s.Policy = &v + return s +} + // SetVersion sets the Version field's value. func (s *RestApi) SetVersion(v string) *RestApi { s.Version = &v @@ -21486,7 +21514,7 @@ type Stage struct { // (URI) of a call to API Gateway. StageName *string `locationName:"stageName" type:"string"` - // A collection of Tags associated with a given resource. + // The collection of tags. Each tag element is associated with a given resource. Tags map[string]*string `locationName:"tags" type:"map"` // A map that defines the stage variables for a Stage resource. Variable names @@ -21628,19 +21656,19 @@ func (s *StageKey) SetStageName(v string) *StageKey { return s } -// Adds or updates Tags on a gievn resource. +// Adds or updates a tag on a given resource. type TagResourceInput struct { _ struct{} `type:"structure"` - // [Required] The ARN of a resource that can be tagged. At present, Stage is - // the only taggable resource. + // [Required] The ARN of a resource that can be tagged. The resource ARN must + // be URL-encoded. At present, Stage is the only taggable resource. // // ResourceArn is a required field ResourceArn *string `location:"uri" locationName:"resource_arn" type:"string" required:"true"` - // [Required] Key/Value map of strings. Valid character set is [a-zA-Z+-=._:/]. - // Tag key can be up to 128 characters and must not start with "aws:". Tag value - // can be up to 256 characters. + // [Required] The key-value map of strings. The valid character set is [a-zA-Z+-=._:/]. + // The tag key can be up to 128 characters and must not start with aws:. The + // tag value can be up to 256 characters. // // Tags is a required field Tags map[string]*string `locationName:"tags" type:"map" required:"true"` @@ -21705,7 +21733,7 @@ type TestInvokeAuthorizerInput struct { // [Optional] A key-value map of additional context variables. AdditionalContext map[string]*string `locationName:"additionalContext" type:"map"` - // Specifies a test invoke authorizer request's Authorizer ID. + // [Required] Specifies a test invoke authorizer request's Authorizer ID. // // AuthorizerId is a required field AuthorizerId *string `location:"uri" locationName:"authorizer_id" type:"string" required:"true"` @@ -21722,7 +21750,7 @@ type TestInvokeAuthorizerInput struct { // request. Use this to specify path parameters and query string parameters. PathWithQueryString *string `locationName:"pathWithQueryString" type:"string"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -21895,7 +21923,7 @@ type TestInvokeMethodInput struct { // A key-value map of headers to simulate an incoming invocation request. Headers map[string]*string `locationName:"headers" type:"map"` - // Specifies a test invoke method request's HTTP method. + // [Required] Specifies a test invoke method request's HTTP method. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` @@ -21904,12 +21932,12 @@ type TestInvokeMethodInput struct { // Use this to specify path parameters and query string parameters. PathWithQueryString *string `locationName:"pathWithQueryString" type:"string"` - // Specifies a test invoke method request's resource ID. + // [Required] Specifies a test invoke method request's resource ID. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -22093,17 +22121,17 @@ func (s *ThrottleSettings) SetRateLimit(v float64) *ThrottleSettings { return s } -// Removes Tags from a given resource. +// Removes a tag from a given resource. type UntagResourceInput struct { _ struct{} `type:"structure"` - // [Required] The ARN of a resource that can be tagged. At present, Stage is - // the only taggable resource. + // [Required] The ARN of a resource that can be tagged. The resource ARN must + // be URL-encoded. At present, Stage is the only taggable resource. // // ResourceArn is a required field ResourceArn *string `location:"uri" locationName:"resource_arn" type:"string" required:"true"` - // The Tag keys to delete. + // [Required] The Tag keys to delete. // // TagKeys is a required field TagKeys []*string `location:"querystring" locationName:"tagKeys" type:"list" required:"true"` @@ -22190,7 +22218,7 @@ func (s *UpdateAccountInput) SetPatchOperations(v []*PatchOperation) *UpdateAcco type UpdateApiKeyInput struct { _ struct{} `type:"structure"` - // The identifier of the ApiKey resource to be updated. + // [Required] The identifier of the ApiKey resource to be updated. // // ApiKey is a required field ApiKey *string `location:"uri" locationName:"api_Key" type:"string" required:"true"` @@ -22239,7 +22267,7 @@ func (s *UpdateApiKeyInput) SetPatchOperations(v []*PatchOperation) *UpdateApiKe type UpdateAuthorizerInput struct { _ struct{} `type:"structure"` - // The identifier of the Authorizer resource. + // [Required] The identifier of the Authorizer resource. // // AuthorizerId is a required field AuthorizerId *string `location:"uri" locationName:"authorizer_id" type:"string" required:"true"` @@ -22248,7 +22276,7 @@ type UpdateAuthorizerInput struct { // the order specified in this list. PatchOperations []*PatchOperation `locationName:"patchOperations" type:"list"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -22302,12 +22330,12 @@ func (s *UpdateAuthorizerInput) SetRestApiId(v string) *UpdateAuthorizerInput { type UpdateBasePathMappingInput struct { _ struct{} `type:"structure"` - // The base path of the BasePathMapping resource to change. + // [Required] The base path of the BasePathMapping resource to change. // // BasePath is a required field BasePath *string `location:"uri" locationName:"base_path" type:"string" required:"true"` - // The domain name of the BasePathMapping resource to change. + // [Required] The domain name of the BasePathMapping resource to change. // // DomainName is a required field DomainName *string `location:"uri" locationName:"domain_name" type:"string" required:"true"` @@ -22365,7 +22393,7 @@ func (s *UpdateBasePathMappingInput) SetPatchOperations(v []*PatchOperation) *Up type UpdateClientCertificateInput struct { _ struct{} `type:"structure"` - // The identifier of the ClientCertificate resource to be updated. + // [Required] The identifier of the ClientCertificate resource to be updated. // // ClientCertificateId is a required field ClientCertificateId *string `location:"uri" locationName:"clientcertificate_id" type:"string" required:"true"` @@ -22424,7 +22452,7 @@ type UpdateDeploymentInput struct { // the order specified in this list. PatchOperations []*PatchOperation `locationName:"patchOperations" type:"list"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -22604,7 +22632,7 @@ func (s *UpdateDocumentationVersionInput) SetRestApiId(v string) *UpdateDocument type UpdateDomainNameInput struct { _ struct{} `type:"structure"` - // The name of the DomainName resource to be changed. + // [Required] The name of the DomainName resource to be changed. // // DomainName is a required field DomainName *string `location:"uri" locationName:"domain_name" type:"string" required:"true"` @@ -22657,8 +22685,8 @@ type UpdateGatewayResponseInput struct { // the order specified in this list. PatchOperations []*PatchOperation `locationName:"patchOperations" type:"list"` - // The response type of the associated GatewayResponse. Valid values are ACCESS_DENIED - // + // [Required] The response type of the associated GatewayResponse. Valid values + // are ACCESS_DENIED // API_CONFIGURATION_ERROR // AUTHORIZER_FAILURE // AUTHORIZER_CONFIGURATION_ERROR @@ -22677,12 +22705,12 @@ type UpdateGatewayResponseInput struct { // RESOURCE_NOT_FOUND // THROTTLED // UNAUTHORIZED - // UNSUPPORTED_MEDIA_TYPES + // UNSUPPORTED_MEDIA_TYPE // // ResponseType is a required field ResponseType *string `location:"uri" locationName:"response_type" type:"string" required:"true" enum:"GatewayResponseType"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -22809,7 +22837,7 @@ type UpdateGatewayResponseOutput struct { // RESOURCE_NOT_FOUND // THROTTLED // UNAUTHORIZED - // UNSUPPORTED_MEDIA_TYPES + // UNSUPPORTED_MEDIA_TYPE ResponseType *string `locationName:"responseType" type:"string" enum:"GatewayResponseType"` // The HTTP status code for this GatewayResponse. @@ -22860,7 +22888,7 @@ func (s *UpdateGatewayResponseOutput) SetStatusCode(v string) *UpdateGatewayResp type UpdateIntegrationInput struct { _ struct{} `type:"structure"` - // Represents an update integration request's HTTP method. + // [Required] Represents an update integration request's HTTP method. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` @@ -22869,12 +22897,12 @@ type UpdateIntegrationInput struct { // the order specified in this list. PatchOperations []*PatchOperation `locationName:"patchOperations" type:"list"` - // Represents an update integration request's resource identifier. + // [Required] Represents an update integration request's resource identifier. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -22937,7 +22965,7 @@ func (s *UpdateIntegrationInput) SetRestApiId(v string) *UpdateIntegrationInput type UpdateIntegrationResponseInput struct { _ struct{} `type:"structure"` - // Specifies an update integration response request's HTTP method. + // [Required] Specifies an update integration response request's HTTP method. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` @@ -22946,17 +22974,17 @@ type UpdateIntegrationResponseInput struct { // the order specified in this list. PatchOperations []*PatchOperation `locationName:"patchOperations" type:"list"` - // Specifies an update integration response request's resource identifier. + // [Required] Specifies an update integration response request's resource identifier. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` - // Specifies an update integration response request's status code. + // [Required] Specifies an update integration response request's status code. // // StatusCode is a required field StatusCode *string `location:"uri" locationName:"status_code" type:"string" required:"true"` @@ -23028,7 +23056,7 @@ func (s *UpdateIntegrationResponseInput) SetStatusCode(v string) *UpdateIntegrat type UpdateMethodInput struct { _ struct{} `type:"structure"` - // The HTTP verb of the Method resource. + // [Required] The HTTP verb of the Method resource. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` @@ -23037,12 +23065,12 @@ type UpdateMethodInput struct { // the order specified in this list. PatchOperations []*PatchOperation `locationName:"patchOperations" type:"list"` - // The Resource identifier for the Method resource. + // [Required] The Resource identifier for the Method resource. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -23105,7 +23133,7 @@ func (s *UpdateMethodInput) SetRestApiId(v string) *UpdateMethodInput { type UpdateMethodResponseInput struct { _ struct{} `type:"structure"` - // The HTTP verb of the Method resource. + // [Required] The HTTP verb of the Method resource. // // HttpMethod is a required field HttpMethod *string `location:"uri" locationName:"http_method" type:"string" required:"true"` @@ -23114,17 +23142,17 @@ type UpdateMethodResponseInput struct { // the order specified in this list. PatchOperations []*PatchOperation `locationName:"patchOperations" type:"list"` - // The Resource identifier for the MethodResponse resource. + // [Required] The Resource identifier for the MethodResponse resource. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` - // The status code for the MethodResponse resource. + // [Required] The status code for the MethodResponse resource. // // StatusCode is a required field StatusCode *string `location:"uri" locationName:"status_code" type:"string" required:"true"` @@ -23196,7 +23224,7 @@ func (s *UpdateMethodResponseInput) SetStatusCode(v string) *UpdateMethodRespons type UpdateModelInput struct { _ struct{} `type:"structure"` - // The name of the model to update. + // [Required] The name of the model to update. // // ModelName is a required field ModelName *string `location:"uri" locationName:"model_name" type:"string" required:"true"` @@ -23205,7 +23233,7 @@ type UpdateModelInput struct { // the order specified in this list. PatchOperations []*PatchOperation `locationName:"patchOperations" type:"list"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -23268,7 +23296,7 @@ type UpdateRequestValidatorInput struct { // RequestValidatorId is a required field RequestValidatorId *string `location:"uri" locationName:"requestvalidator_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -23387,12 +23415,12 @@ type UpdateResourceInput struct { // the order specified in this list. PatchOperations []*PatchOperation `locationName:"patchOperations" type:"list"` - // The identifier of the Resource resource. + // [Required] The identifier of the Resource resource. // // ResourceId is a required field ResourceId *string `location:"uri" locationName:"resource_id" type:"string" required:"true"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -23450,7 +23478,7 @@ type UpdateRestApiInput struct { // the order specified in this list. PatchOperations []*PatchOperation `locationName:"patchOperations" type:"list"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` @@ -23499,12 +23527,12 @@ type UpdateStageInput struct { // the order specified in this list. PatchOperations []*PatchOperation `locationName:"patchOperations" type:"list"` - // The string identifier of the associated RestApi. + // [Required] The string identifier of the associated RestApi. // // RestApiId is a required field RestApiId *string `location:"uri" locationName:"restapi_id" type:"string" required:"true"` - // The name of the Stage resource to change information about. + // [Required] The name of the Stage resource to change information about. // // StageName is a required field StageName *string `location:"uri" locationName:"stage_name" type:"string" required:"true"` @@ -23559,8 +23587,8 @@ func (s *UpdateStageInput) SetStageName(v string) *UpdateStageInput { type UpdateUsageInput struct { _ struct{} `type:"structure"` - // The identifier of the API key associated with the usage plan in which a temporary - // extension is granted to the remaining quota. + // [Required] The identifier of the API key associated with the usage plan in + // which a temporary extension is granted to the remaining quota. // // KeyId is a required field KeyId *string `location:"uri" locationName:"keyId" type:"string" required:"true"` @@ -23569,7 +23597,7 @@ type UpdateUsageInput struct { // the order specified in this list. PatchOperations []*PatchOperation `locationName:"patchOperations" type:"list"` - // The Id of the usage plan associated with the usage data. + // [Required] The Id of the usage plan associated with the usage data. // // UsagePlanId is a required field UsagePlanId *string `location:"uri" locationName:"usageplanId" type:"string" required:"true"` @@ -23627,7 +23655,7 @@ type UpdateUsagePlanInput struct { // the order specified in this list. PatchOperations []*PatchOperation `locationName:"patchOperations" type:"list"` - // The Id of the to-be-updated usage plan. + // [Required] The Id of the to-be-updated usage plan. // // UsagePlanId is a required field UsagePlanId *string `location:"uri" locationName:"usageplanId" type:"string" required:"true"` @@ -24020,10 +24048,10 @@ const ( ApiKeysFormatCsv = "csv" ) -// [Required] The authorizer type. Valid values are TOKEN for a Lambda function -// using a single authorization token submitted in a custom header, REQUEST -// for a Lambda function using incoming request parameters, and COGNITO_USER_POOLS -// for using an Amazon Cognito user pool. +// The authorizer type. Valid values are TOKEN for a Lambda function using a +// single authorization token submitted in a custom header, REQUEST for a Lambda +// function using incoming request parameters, and COGNITO_USER_POOLS for using +// an Amazon Cognito user pool. const ( // AuthorizerTypeToken is a AuthorizerType enum value AuthorizerTypeToken = "TOKEN" diff --git a/vendor/github.com/aws/aws-sdk-go/service/applicationautoscaling/api.go b/vendor/github.com/aws/aws-sdk-go/service/applicationautoscaling/api.go index f8e763571a7c..1586778ca8bb 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/applicationautoscaling/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/applicationautoscaling/api.go @@ -15,7 +15,7 @@ const opDeleteScalingPolicy = "DeleteScalingPolicy" // DeleteScalingPolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteScalingPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -115,7 +115,7 @@ const opDeleteScheduledAction = "DeleteScheduledAction" // DeleteScheduledActionRequest generates a "aws/request.Request" representing the // client's request for the DeleteScheduledAction operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -209,7 +209,7 @@ const opDeregisterScalableTarget = "DeregisterScalableTarget" // DeregisterScalableTargetRequest generates a "aws/request.Request" representing the // client's request for the DeregisterScalableTarget operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -308,7 +308,7 @@ const opDescribeScalableTargets = "DescribeScalableTargets" // DescribeScalableTargetsRequest generates a "aws/request.Request" representing the // client's request for the DescribeScalableTargets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -460,7 +460,7 @@ const opDescribeScalingActivities = "DescribeScalingActivities" // DescribeScalingActivitiesRequest generates a "aws/request.Request" representing the // client's request for the DescribeScalingActivities operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -614,7 +614,7 @@ const opDescribeScalingPolicies = "DescribeScalingPolicies" // DescribeScalingPoliciesRequest generates a "aws/request.Request" representing the // client's request for the DescribeScalingPolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -774,7 +774,7 @@ const opDescribeScheduledActions = "DescribeScheduledActions" // DescribeScheduledActionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeScheduledActions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -870,7 +870,7 @@ const opPutScalingPolicy = "PutScalingPolicy" // PutScalingPolicyRequest generates a "aws/request.Request" representing the // client's request for the PutScalingPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -988,7 +988,7 @@ const opPutScheduledAction = "PutScheduledAction" // PutScheduledActionRequest generates a "aws/request.Request" representing the // client's request for the PutScheduledAction operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1100,7 +1100,7 @@ const opRegisterScalableTarget = "RegisterScalableTarget" // RegisterScalableTargetRequest generates a "aws/request.Request" representing the // client's request for the RegisterScalableTarget operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1359,6 +1359,9 @@ type DeleteScalingPolicyInput struct { // * Aurora DB cluster - The resource type is cluster and the unique identifier // is the cluster name. Example: cluster:my-db-cluster. // + // * Amazon SageMaker endpoint variants - The resource type is variant and + // the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering. + // // ResourceId is a required field ResourceId *string `min:"1" type:"string" required:"true"` @@ -1391,6 +1394,9 @@ type DeleteScalingPolicyInput struct { // * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora // DB cluster. Available for Aurora MySQL-compatible edition. // + // * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances + // for an Amazon SageMaker model endpoint variant. + // // ScalableDimension is a required field ScalableDimension *string `type:"string" required:"true" enum:"ScalableDimension"` @@ -1505,6 +1511,9 @@ type DeleteScheduledActionInput struct { // * Aurora DB cluster - The resource type is cluster and the unique identifier // is the cluster name. Example: cluster:my-db-cluster. // + // * Amazon SageMaker endpoint variants - The resource type is variant and + // the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering. + // // ResourceId is a required field ResourceId *string `min:"1" type:"string" required:"true"` @@ -1536,6 +1545,9 @@ type DeleteScheduledActionInput struct { // // * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora // DB cluster. Available for Aurora MySQL-compatible edition. + // + // * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances + // for an Amazon SageMaker model endpoint variant. ScalableDimension *string `type:"string" enum:"ScalableDimension"` // The name of the scheduled action. @@ -1651,6 +1663,9 @@ type DeregisterScalableTargetInput struct { // * Aurora DB cluster - The resource type is cluster and the unique identifier // is the cluster name. Example: cluster:my-db-cluster. // + // * Amazon SageMaker endpoint variants - The resource type is variant and + // the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering. + // // ResourceId is a required field ResourceId *string `min:"1" type:"string" required:"true"` @@ -1683,6 +1698,9 @@ type DeregisterScalableTargetInput struct { // * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora // DB cluster. Available for Aurora MySQL-compatible edition. // + // * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances + // for an Amazon SageMaker model endpoint variant. + // // ScalableDimension is a required field ScalableDimension *string `type:"string" required:"true" enum:"ScalableDimension"` @@ -1797,6 +1815,9 @@ type DescribeScalableTargetsInput struct { // // * Aurora DB cluster - The resource type is cluster and the unique identifier // is the cluster name. Example: cluster:my-db-cluster. + // + // * Amazon SageMaker endpoint variants - The resource type is variant and + // the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering. ResourceIds []*string `type:"list"` // The scalable dimension associated with the scalable target. This string consists @@ -1828,6 +1849,9 @@ type DescribeScalableTargetsInput struct { // // * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora // DB cluster. Available for Aurora MySQL-compatible edition. + // + // * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances + // for an Amazon SageMaker model endpoint variant. ScalableDimension *string `type:"string" enum:"ScalableDimension"` // The namespace of the AWS service. For more information, see AWS Service Namespaces @@ -1963,6 +1987,9 @@ type DescribeScalingActivitiesInput struct { // // * Aurora DB cluster - The resource type is cluster and the unique identifier // is the cluster name. Example: cluster:my-db-cluster. + // + // * Amazon SageMaker endpoint variants - The resource type is variant and + // the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering. ResourceId *string `min:"1" type:"string"` // The scalable dimension. This string consists of the service namespace, resource @@ -1994,6 +2021,9 @@ type DescribeScalingActivitiesInput struct { // // * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora // DB cluster. Available for Aurora MySQL-compatible edition. + // + // * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances + // for an Amazon SageMaker model endpoint variant. ScalableDimension *string `type:"string" enum:"ScalableDimension"` // The namespace of the AWS service. For more information, see AWS Service Namespaces @@ -2135,6 +2165,9 @@ type DescribeScalingPoliciesInput struct { // // * Aurora DB cluster - The resource type is cluster and the unique identifier // is the cluster name. Example: cluster:my-db-cluster. + // + // * Amazon SageMaker endpoint variants - The resource type is variant and + // the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering. ResourceId *string `min:"1" type:"string"` // The scalable dimension. This string consists of the service namespace, resource @@ -2166,6 +2199,9 @@ type DescribeScalingPoliciesInput struct { // // * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora // DB cluster. Available for Aurora MySQL-compatible edition. + // + // * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances + // for an Amazon SageMaker model endpoint variant. ScalableDimension *string `type:"string" enum:"ScalableDimension"` // The namespace of the AWS service. For more information, see AWS Service Namespaces @@ -2310,6 +2346,9 @@ type DescribeScheduledActionsInput struct { // // * Aurora DB cluster - The resource type is cluster and the unique identifier // is the cluster name. Example: cluster:my-db-cluster. + // + // * Amazon SageMaker endpoint variants - The resource type is variant and + // the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering. ResourceId *string `min:"1" type:"string"` // The scalable dimension. This string consists of the service namespace, resource @@ -2341,6 +2380,9 @@ type DescribeScheduledActionsInput struct { // // * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora // DB cluster. Available for Aurora MySQL-compatible edition. + // + // * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances + // for an Amazon SageMaker model endpoint variant. ScalableDimension *string `type:"string" enum:"ScalableDimension"` // The names of the scheduled actions to describe. @@ -2604,6 +2646,9 @@ type PutScalingPolicyInput struct { // * Aurora DB cluster - The resource type is cluster and the unique identifier // is the cluster name. Example: cluster:my-db-cluster. // + // * Amazon SageMaker endpoint variants - The resource type is variant and + // the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering. + // // ResourceId is a required field ResourceId *string `min:"1" type:"string" required:"true"` @@ -2636,6 +2681,9 @@ type PutScalingPolicyInput struct { // * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora // DB cluster. Available for Aurora MySQL-compatible edition. // + // * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances + // for an Amazon SageMaker model endpoint variant. + // // ScalableDimension is a required field ScalableDimension *string `type:"string" required:"true" enum:"ScalableDimension"` @@ -2813,6 +2861,9 @@ type PutScheduledActionInput struct { // * Aurora DB cluster - The resource type is cluster and the unique identifier // is the cluster name. Example: cluster:my-db-cluster. // + // * Amazon SageMaker endpoint variants - The resource type is variant and + // the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering. + // // ResourceId is a required field ResourceId *string `min:"1" type:"string" required:"true"` @@ -2845,6 +2896,9 @@ type PutScheduledActionInput struct { // // * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora // DB cluster. Available for Aurora MySQL-compatible edition. + // + // * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances + // for an Amazon SageMaker model endpoint variant. ScalableDimension *string `type:"string" enum:"ScalableDimension"` // The new minimum and maximum capacity. You can set both values or just one. @@ -3021,6 +3075,9 @@ type RegisterScalableTargetInput struct { // * Aurora DB cluster - The resource type is cluster and the unique identifier // is the cluster name. Example: cluster:my-db-cluster. // + // * Amazon SageMaker endpoint variants - The resource type is variant and + // the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering. + // // ResourceId is a required field ResourceId *string `min:"1" type:"string" required:"true"` @@ -3062,6 +3119,9 @@ type RegisterScalableTargetInput struct { // * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora // DB cluster. Available for Aurora MySQL-compatible edition. // + // * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances + // for an Amazon SageMaker model endpoint variant. + // // ScalableDimension is a required field ScalableDimension *string `type:"string" required:"true" enum:"ScalableDimension"` @@ -3201,6 +3261,9 @@ type ScalableTarget struct { // * Aurora DB cluster - The resource type is cluster and the unique identifier // is the cluster name. Example: cluster:my-db-cluster. // + // * Amazon SageMaker endpoint variants - The resource type is variant and + // the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering. + // // ResourceId is a required field ResourceId *string `min:"1" type:"string" required:"true"` @@ -3239,6 +3302,9 @@ type ScalableTarget struct { // * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora // DB cluster. Available for Aurora MySQL-compatible edition. // + // * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances + // for an Amazon SageMaker model endpoint variant. + // // ScalableDimension is a required field ScalableDimension *string `type:"string" required:"true" enum:"ScalableDimension"` @@ -3384,6 +3450,9 @@ type ScalingActivity struct { // * Aurora DB cluster - The resource type is cluster and the unique identifier // is the cluster name. Example: cluster:my-db-cluster. // + // * Amazon SageMaker endpoint variants - The resource type is variant and + // the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering. + // // ResourceId is a required field ResourceId *string `min:"1" type:"string" required:"true"` @@ -3416,6 +3485,9 @@ type ScalingActivity struct { // * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora // DB cluster. Available for Aurora MySQL-compatible edition. // + // * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances + // for an Amazon SageMaker model endpoint variant. + // // ScalableDimension is a required field ScalableDimension *string `type:"string" required:"true" enum:"ScalableDimension"` @@ -3567,6 +3639,9 @@ type ScalingPolicy struct { // * Aurora DB cluster - The resource type is cluster and the unique identifier // is the cluster name. Example: cluster:my-db-cluster. // + // * Amazon SageMaker endpoint variants - The resource type is variant and + // the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering. + // // ResourceId is a required field ResourceId *string `min:"1" type:"string" required:"true"` @@ -3599,6 +3674,9 @@ type ScalingPolicy struct { // * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora // DB cluster. Available for Aurora MySQL-compatible edition. // + // * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances + // for an Amazon SageMaker model endpoint variant. + // // ScalableDimension is a required field ScalableDimension *string `type:"string" required:"true" enum:"ScalableDimension"` @@ -3722,6 +3800,9 @@ type ScheduledAction struct { // * Aurora DB cluster - The resource type is cluster and the unique identifier // is the cluster name. Example: cluster:my-db-cluster. // + // * Amazon SageMaker endpoint variants - The resource type is variant and + // the unique identifier is the resource ID. Example: endpoint/my-end-point/variant/KMeansClustering. + // // ResourceId is a required field ResourceId *string `min:"1" type:"string" required:"true"` @@ -3753,6 +3834,9 @@ type ScheduledAction struct { // // * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora // DB cluster. Available for Aurora MySQL-compatible edition. + // + // * sagemaker:variant:DesiredInstanceCount - The number of EC2 instances + // for an Amazon SageMaker model endpoint variant. ScalableDimension *string `type:"string" enum:"ScalableDimension"` // The new minimum and maximum capacity. You can set both values or just one. @@ -4077,7 +4161,7 @@ func (s *StepScalingPolicyConfiguration) SetStepAdjustments(v []*StepAdjustment) type TargetTrackingScalingPolicyConfiguration struct { _ struct{} `type:"structure"` - // Reserved for future use. + // A customized metric. CustomizedMetricSpecification *CustomizedMetricSpecification `type:"structure"` // Indicates whether scale in by the target tracking policy is disabled. If @@ -4249,6 +4333,9 @@ const ( // MetricTypeEc2spotFleetRequestAverageNetworkOut is a MetricType enum value MetricTypeEc2spotFleetRequestAverageNetworkOut = "EC2SpotFleetRequestAverageNetworkOut" + // MetricTypeSageMakerVariantInvocationsPerInstance is a MetricType enum value + MetricTypeSageMakerVariantInvocationsPerInstance = "SageMakerVariantInvocationsPerInstance" + // MetricTypeEcsserviceAverageCpuutilization is a MetricType enum value MetricTypeEcsserviceAverageCpuutilization = "ECSServiceAverageCPUUtilization" @@ -4291,6 +4378,9 @@ const ( // ScalableDimensionRdsClusterReadReplicaCount is a ScalableDimension enum value ScalableDimensionRdsClusterReadReplicaCount = "rds:cluster:ReadReplicaCount" + + // ScalableDimensionSagemakerVariantDesiredInstanceCount is a ScalableDimension enum value + ScalableDimensionSagemakerVariantDesiredInstanceCount = "sagemaker:variant:DesiredInstanceCount" ) const ( @@ -4331,4 +4421,7 @@ const ( // ServiceNamespaceRds is a ServiceNamespace enum value ServiceNamespaceRds = "rds" + + // ServiceNamespaceSagemaker is a ServiceNamespace enum value + ServiceNamespaceSagemaker = "sagemaker" ) diff --git a/vendor/github.com/aws/aws-sdk-go/service/applicationautoscaling/doc.go b/vendor/github.com/aws/aws-sdk-go/service/applicationautoscaling/doc.go index 7e8c1a102336..674300381660 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/applicationautoscaling/doc.go +++ b/vendor/github.com/aws/aws-sdk-go/service/applicationautoscaling/doc.go @@ -3,9 +3,9 @@ // Package applicationautoscaling provides the client and types for making API // requests to Application Auto Scaling. // -// With Application Auto Scaling, you can automatically scale your AWS resources. -// The experience is similar to that of Auto Scaling (https://aws.amazon.com/autoscaling/). -// You can use Application Auto Scaling to accomplish the following tasks: +// With Application Auto Scaling, you can configure automatic scaling for your +// scalable AWS resources. You can use Application Auto Scaling to accomplish +// the following tasks: // // * Define scaling policies to automatically scale your AWS resources // @@ -41,6 +41,13 @@ // * Amazon Aurora Replicas. For more information, see Using Amazon Aurora // Auto Scaling with Aurora Replicas (http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Aurora.Integrating.AutoScaling.html). // +// * Amazon SageMaker endpoints. For more information, see Automatically +// Scaling Amazon SageMaker Models (http://docs.aws.amazon.com/sagemaker/latest/dg/endpoint-auto-scaling.html). +// +// To configure automatic scaling for multiple resources across multiple services, +// use AWS Auto Scaling to create a scaling plan for your application. For more +// information, see AWS Auto Scaling (http://aws.amazon.com/autoscaling). +// // For a list of supported regions, see AWS Regions and Endpoints: Application // Auto Scaling (http://docs.aws.amazon.com/general/latest/gr/rande.html#as-app_region) // in the AWS General Reference. diff --git a/vendor/github.com/aws/aws-sdk-go/service/applicationautoscaling/service.go b/vendor/github.com/aws/aws-sdk-go/service/applicationautoscaling/service.go index 56103ee27ec3..909c1b80e8da 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/applicationautoscaling/service.go +++ b/vendor/github.com/aws/aws-sdk-go/service/applicationautoscaling/service.go @@ -45,14 +45,14 @@ const ( // svc := applicationautoscaling.New(mySession, aws.NewConfig().WithRegion("us-west-2")) func New(p client.ConfigProvider, cfgs ...*aws.Config) *ApplicationAutoScaling { c := p.ClientConfig(EndpointsID, cfgs...) + if c.SigningNameDerived || len(c.SigningName) == 0 { + c.SigningName = "application-autoscaling" + } return newClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion, c.SigningName) } // newClient creates, initializes and returns a new service client instance. func newClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion, signingName string) *ApplicationAutoScaling { - if len(signingName) == 0 { - signingName = "application-autoscaling" - } svc := &ApplicationAutoScaling{ Client: client.New( cfg, diff --git a/vendor/github.com/aws/aws-sdk-go/service/appsync/api.go b/vendor/github.com/aws/aws-sdk-go/service/appsync/api.go index ce553365c918..5ed7f6e2a502 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/appsync/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/appsync/api.go @@ -12,7 +12,7 @@ const opCreateApiKey = "CreateApiKey" // CreateApiKeyRequest generates a "aws/request.Request" representing the // client's request for the CreateApiKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -115,7 +115,7 @@ const opCreateDataSource = "CreateDataSource" // CreateDataSourceRequest generates a "aws/request.Request" representing the // client's request for the CreateDataSource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -209,7 +209,7 @@ const opCreateGraphqlApi = "CreateGraphqlApi" // CreateGraphqlApiRequest generates a "aws/request.Request" representing the // client's request for the CreateGraphqlApi operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -308,7 +308,7 @@ const opCreateResolver = "CreateResolver" // CreateResolverRequest generates a "aws/request.Request" representing the // client's request for the CreateResolver operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -401,7 +401,7 @@ const opCreateType = "CreateType" // CreateTypeRequest generates a "aws/request.Request" representing the // client's request for the CreateType operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -495,7 +495,7 @@ const opDeleteApiKey = "DeleteApiKey" // DeleteApiKeyRequest generates a "aws/request.Request" representing the // client's request for the DeleteApiKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -585,7 +585,7 @@ const opDeleteDataSource = "DeleteDataSource" // DeleteDataSourceRequest generates a "aws/request.Request" representing the // client's request for the DeleteDataSource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -679,7 +679,7 @@ const opDeleteGraphqlApi = "DeleteGraphqlApi" // DeleteGraphqlApiRequest generates a "aws/request.Request" representing the // client's request for the DeleteGraphqlApi operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -773,7 +773,7 @@ const opDeleteResolver = "DeleteResolver" // DeleteResolverRequest generates a "aws/request.Request" representing the // client's request for the DeleteResolver operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -863,7 +863,7 @@ const opDeleteType = "DeleteType" // DeleteTypeRequest generates a "aws/request.Request" representing the // client's request for the DeleteType operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -957,7 +957,7 @@ const opGetDataSource = "GetDataSource" // GetDataSourceRequest generates a "aws/request.Request" representing the // client's request for the GetDataSource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1051,7 +1051,7 @@ const opGetGraphqlApi = "GetGraphqlApi" // GetGraphqlApiRequest generates a "aws/request.Request" representing the // client's request for the GetGraphqlApi operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1141,7 +1141,7 @@ const opGetIntrospectionSchema = "GetIntrospectionSchema" // GetIntrospectionSchemaRequest generates a "aws/request.Request" representing the // client's request for the GetIntrospectionSchema operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1230,7 +1230,7 @@ const opGetResolver = "GetResolver" // GetResolverRequest generates a "aws/request.Request" representing the // client's request for the GetResolver operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1317,7 +1317,7 @@ const opGetSchemaCreationStatus = "GetSchemaCreationStatus" // GetSchemaCreationStatusRequest generates a "aws/request.Request" representing the // client's request for the GetSchemaCreationStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1407,7 +1407,7 @@ const opGetType = "GetType" // GetTypeRequest generates a "aws/request.Request" representing the // client's request for the GetType operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1501,7 +1501,7 @@ const opListApiKeys = "ListApiKeys" // ListApiKeysRequest generates a "aws/request.Request" representing the // client's request for the ListApiKeys operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1591,7 +1591,7 @@ const opListDataSources = "ListDataSources" // ListDataSourcesRequest generates a "aws/request.Request" representing the // client's request for the ListDataSources operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1681,7 +1681,7 @@ const opListGraphqlApis = "ListGraphqlApis" // ListGraphqlApisRequest generates a "aws/request.Request" representing the // client's request for the ListGraphqlApis operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1767,7 +1767,7 @@ const opListResolvers = "ListResolvers" // ListResolversRequest generates a "aws/request.Request" representing the // client's request for the ListResolvers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1857,7 +1857,7 @@ const opListTypes = "ListTypes" // ListTypesRequest generates a "aws/request.Request" representing the // client's request for the ListTypes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1951,7 +1951,7 @@ const opStartSchemaCreation = "StartSchemaCreation" // StartSchemaCreationRequest generates a "aws/request.Request" representing the // client's request for the StartSchemaCreation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2047,7 +2047,7 @@ const opUpdateApiKey = "UpdateApiKey" // UpdateApiKeyRequest generates a "aws/request.Request" representing the // client's request for the UpdateApiKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2143,7 +2143,7 @@ const opUpdateDataSource = "UpdateDataSource" // UpdateDataSourceRequest generates a "aws/request.Request" representing the // client's request for the UpdateDataSource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2237,7 +2237,7 @@ const opUpdateGraphqlApi = "UpdateGraphqlApi" // UpdateGraphqlApiRequest generates a "aws/request.Request" representing the // client's request for the UpdateGraphqlApi operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2331,7 +2331,7 @@ const opUpdateResolver = "UpdateResolver" // UpdateResolverRequest generates a "aws/request.Request" representing the // client's request for the UpdateResolver operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2421,7 +2421,7 @@ const opUpdateType = "UpdateType" // UpdateTypeRequest generates a "aws/request.Request" representing the // client's request for the UpdateType operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/appsync/service.go b/vendor/github.com/aws/aws-sdk-go/service/appsync/service.go index cdc4698e8e47..6af2be6d9a84 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/appsync/service.go +++ b/vendor/github.com/aws/aws-sdk-go/service/appsync/service.go @@ -45,14 +45,14 @@ const ( // svc := appsync.New(mySession, aws.NewConfig().WithRegion("us-west-2")) func New(p client.ConfigProvider, cfgs ...*aws.Config) *AppSync { c := p.ClientConfig(EndpointsID, cfgs...) + if c.SigningNameDerived || len(c.SigningName) == 0 { + c.SigningName = "appsync" + } return newClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion, c.SigningName) } // newClient creates, initializes and returns a new service client instance. func newClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion, signingName string) *AppSync { - if len(signingName) == 0 { - signingName = "appsync" - } svc := &AppSync{ Client: client.New( cfg, diff --git a/vendor/github.com/aws/aws-sdk-go/service/athena/api.go b/vendor/github.com/aws/aws-sdk-go/service/athena/api.go index 198a0dfbb399..535a99055663 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/athena/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/athena/api.go @@ -14,7 +14,7 @@ const opBatchGetNamedQuery = "BatchGetNamedQuery" // BatchGetNamedQueryRequest generates a "aws/request.Request" representing the // client's request for the BatchGetNamedQuery operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -104,7 +104,7 @@ const opBatchGetQueryExecution = "BatchGetQueryExecution" // BatchGetQueryExecutionRequest generates a "aws/request.Request" representing the // client's request for the BatchGetQueryExecution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -192,7 +192,7 @@ const opCreateNamedQuery = "CreateNamedQuery" // CreateNamedQueryRequest generates a "aws/request.Request" representing the // client's request for the CreateNamedQuery operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -280,7 +280,7 @@ const opDeleteNamedQuery = "DeleteNamedQuery" // DeleteNamedQueryRequest generates a "aws/request.Request" representing the // client's request for the DeleteNamedQuery operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -368,7 +368,7 @@ const opGetNamedQuery = "GetNamedQuery" // GetNamedQueryRequest generates a "aws/request.Request" representing the // client's request for the GetNamedQuery operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -452,7 +452,7 @@ const opGetQueryExecution = "GetQueryExecution" // GetQueryExecutionRequest generates a "aws/request.Request" representing the // client's request for the GetQueryExecution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -537,7 +537,7 @@ const opGetQueryResults = "GetQueryResults" // GetQueryResultsRequest generates a "aws/request.Request" representing the // client's request for the GetQueryResults operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -679,7 +679,7 @@ const opListNamedQueries = "ListNamedQueries" // ListNamedQueriesRequest generates a "aws/request.Request" representing the // client's request for the ListNamedQueries operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -823,7 +823,7 @@ const opListQueryExecutions = "ListQueryExecutions" // ListQueryExecutionsRequest generates a "aws/request.Request" representing the // client's request for the ListQueryExecutions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -967,7 +967,7 @@ const opStartQueryExecution = "StartQueryExecution" // StartQueryExecutionRequest generates a "aws/request.Request" representing the // client's request for the StartQueryExecution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1058,7 +1058,7 @@ const opStopQueryExecution = "StopQueryExecution" // StopQueryExecutionRequest generates a "aws/request.Request" representing the // client's request for the StopQueryExecution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/autoscaling/api.go b/vendor/github.com/aws/aws-sdk-go/service/autoscaling/api.go index 9b7e6bcd9c8c..1f1826493bab 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/autoscaling/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/autoscaling/api.go @@ -17,7 +17,7 @@ const opAttachInstances = "AttachInstances" // AttachInstancesRequest generates a "aws/request.Request" representing the // client's request for the AttachInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -87,6 +87,9 @@ func (c *AutoScaling) AttachInstancesRequest(input *AttachInstancesInput) (req * // You already have a pending update to an Auto Scaling resource (for example, // a group, instance, or load balancer). // +// * ErrCodeServiceLinkedRoleFailure "ServiceLinkedRoleFailure" +// The service-linked role is not yet ready for use. +// // See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-2011-01-01/AttachInstances func (c *AutoScaling) AttachInstances(input *AttachInstancesInput) (*AttachInstancesOutput, error) { req, out := c.AttachInstancesRequest(input) @@ -113,7 +116,7 @@ const opAttachLoadBalancerTargetGroups = "AttachLoadBalancerTargetGroups" // AttachLoadBalancerTargetGroupsRequest generates a "aws/request.Request" representing the // client's request for the AttachLoadBalancerTargetGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -174,6 +177,9 @@ func (c *AutoScaling) AttachLoadBalancerTargetGroupsRequest(input *AttachLoadBal // You already have a pending update to an Auto Scaling resource (for example, // a group, instance, or load balancer). // +// * ErrCodeServiceLinkedRoleFailure "ServiceLinkedRoleFailure" +// The service-linked role is not yet ready for use. +// // See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-2011-01-01/AttachLoadBalancerTargetGroups func (c *AutoScaling) AttachLoadBalancerTargetGroups(input *AttachLoadBalancerTargetGroupsInput) (*AttachLoadBalancerTargetGroupsOutput, error) { req, out := c.AttachLoadBalancerTargetGroupsRequest(input) @@ -200,7 +206,7 @@ const opAttachLoadBalancers = "AttachLoadBalancers" // AttachLoadBalancersRequest generates a "aws/request.Request" representing the // client's request for the AttachLoadBalancers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -264,6 +270,9 @@ func (c *AutoScaling) AttachLoadBalancersRequest(input *AttachLoadBalancersInput // You already have a pending update to an Auto Scaling resource (for example, // a group, instance, or load balancer). // +// * ErrCodeServiceLinkedRoleFailure "ServiceLinkedRoleFailure" +// The service-linked role is not yet ready for use. +// // See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-2011-01-01/AttachLoadBalancers func (c *AutoScaling) AttachLoadBalancers(input *AttachLoadBalancersInput) (*AttachLoadBalancersOutput, error) { req, out := c.AttachLoadBalancersRequest(input) @@ -290,7 +299,7 @@ const opCompleteLifecycleAction = "CompleteLifecycleAction" // CompleteLifecycleActionRequest generates a "aws/request.Request" representing the // client's request for the CompleteLifecycleAction operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -392,7 +401,7 @@ const opCreateAutoScalingGroup = "CreateAutoScalingGroup" // CreateAutoScalingGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateAutoScalingGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -436,9 +445,10 @@ func (c *AutoScaling) CreateAutoScalingGroupRequest(input *CreateAutoScalingGrou // // Creates an Auto Scaling group with the specified name and attributes. // -// If you exceed your maximum limit of Auto Scaling groups, which by default -// is 20 per region, the call fails. For information about viewing and updating -// this limit, see DescribeAccountLimits. +// If you exceed your maximum limit of Auto Scaling groups, the call fails. +// For information about viewing this limit, see DescribeAccountLimits. For +// information about updating this limit, see Auto Scaling Limits (http://docs.aws.amazon.com/autoscaling/latest/userguide/as-account-limits.html) +// in the Auto Scaling User Guide. // // For more information, see Auto Scaling Groups (http://docs.aws.amazon.com/autoscaling/latest/userguide/AutoScalingGroup.html) // in the Auto Scaling User Guide. @@ -464,6 +474,9 @@ func (c *AutoScaling) CreateAutoScalingGroupRequest(input *CreateAutoScalingGrou // You already have a pending update to an Auto Scaling resource (for example, // a group, instance, or load balancer). // +// * ErrCodeServiceLinkedRoleFailure "ServiceLinkedRoleFailure" +// The service-linked role is not yet ready for use. +// // See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-2011-01-01/CreateAutoScalingGroup func (c *AutoScaling) CreateAutoScalingGroup(input *CreateAutoScalingGroupInput) (*CreateAutoScalingGroupOutput, error) { req, out := c.CreateAutoScalingGroupRequest(input) @@ -490,7 +503,7 @@ const opCreateLaunchConfiguration = "CreateLaunchConfiguration" // CreateLaunchConfigurationRequest generates a "aws/request.Request" representing the // client's request for the CreateLaunchConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -534,9 +547,10 @@ func (c *AutoScaling) CreateLaunchConfigurationRequest(input *CreateLaunchConfig // // Creates a launch configuration. // -// If you exceed your maximum limit of launch configurations, which by default -// is 100 per region, the call fails. For information about viewing and updating -// this limit, see DescribeAccountLimits. +// If you exceed your maximum limit of launch configurations, the call fails. +// For information about viewing this limit, see DescribeAccountLimits. For +// information about updating this limit, see Auto Scaling Limits (http://docs.aws.amazon.com/autoscaling/latest/userguide/as-account-limits.html) +// in the Auto Scaling User Guide. // // For more information, see Launch Configurations (http://docs.aws.amazon.com/autoscaling/latest/userguide/LaunchConfiguration.html) // in the Auto Scaling User Guide. @@ -588,7 +602,7 @@ const opCreateOrUpdateTags = "CreateOrUpdateTags" // CreateOrUpdateTagsRequest generates a "aws/request.Request" representing the // client's request for the CreateOrUpdateTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -688,7 +702,7 @@ const opDeleteAutoScalingGroup = "DeleteAutoScalingGroup" // DeleteAutoScalingGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteAutoScalingGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -791,7 +805,7 @@ const opDeleteLaunchConfiguration = "DeleteLaunchConfiguration" // DeleteLaunchConfigurationRequest generates a "aws/request.Request" representing the // client's request for the DeleteLaunchConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -880,7 +894,7 @@ const opDeleteLifecycleHook = "DeleteLifecycleHook" // DeleteLifecycleHookRequest generates a "aws/request.Request" representing the // client's request for the DeleteLifecycleHook operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -963,7 +977,7 @@ const opDeleteNotificationConfiguration = "DeleteNotificationConfiguration" // DeleteNotificationConfigurationRequest generates a "aws/request.Request" representing the // client's request for the DeleteNotificationConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1045,7 +1059,7 @@ const opDeletePolicy = "DeletePolicy" // DeletePolicyRequest generates a "aws/request.Request" representing the // client's request for the DeletePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1104,6 +1118,9 @@ func (c *AutoScaling) DeletePolicyRequest(input *DeletePolicyInput) (req *reques // You already have a pending update to an Auto Scaling resource (for example, // a group, instance, or load balancer). // +// * ErrCodeServiceLinkedRoleFailure "ServiceLinkedRoleFailure" +// The service-linked role is not yet ready for use. +// // See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-2011-01-01/DeletePolicy func (c *AutoScaling) DeletePolicy(input *DeletePolicyInput) (*DeletePolicyOutput, error) { req, out := c.DeletePolicyRequest(input) @@ -1130,7 +1147,7 @@ const opDeleteScheduledAction = "DeleteScheduledAction" // DeleteScheduledActionRequest generates a "aws/request.Request" representing the // client's request for the DeleteScheduledAction operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1212,7 +1229,7 @@ const opDeleteTags = "DeleteTags" // DeleteTagsRequest generates a "aws/request.Request" representing the // client's request for the DeleteTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1297,7 +1314,7 @@ const opDescribeAccountLimits = "DescribeAccountLimits" // DescribeAccountLimitsRequest generates a "aws/request.Request" representing the // client's request for the DescribeAccountLimits operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1339,9 +1356,9 @@ func (c *AutoScaling) DescribeAccountLimitsRequest(input *DescribeAccountLimitsI // // Describes the current Auto Scaling resource limits for your AWS account. // -// For information about requesting an increase in these limits, see AWS Service -// Limits (http://docs.aws.amazon.com/general/latest/gr/aws_service_limits.html) -// in the Amazon Web Services General Reference. +// For information about requesting an increase in these limits, see Auto Scaling +// Limits (http://docs.aws.amazon.com/autoscaling/latest/userguide/as-account-limits.html) +// in the Auto Scaling User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -1381,7 +1398,7 @@ const opDescribeAdjustmentTypes = "DescribeAdjustmentTypes" // DescribeAdjustmentTypesRequest generates a "aws/request.Request" representing the // client's request for the DescribeAdjustmentTypes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1461,7 +1478,7 @@ const opDescribeAutoScalingGroups = "DescribeAutoScalingGroups" // DescribeAutoScalingGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeAutoScalingGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1600,7 +1617,7 @@ const opDescribeAutoScalingInstances = "DescribeAutoScalingInstances" // DescribeAutoScalingInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeAutoScalingInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1739,7 +1756,7 @@ const opDescribeAutoScalingNotificationTypes = "DescribeAutoScalingNotificationT // DescribeAutoScalingNotificationTypesRequest generates a "aws/request.Request" representing the // client's request for the DescribeAutoScalingNotificationTypes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1819,7 +1836,7 @@ const opDescribeLaunchConfigurations = "DescribeLaunchConfigurations" // DescribeLaunchConfigurationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeLaunchConfigurations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1958,7 +1975,7 @@ const opDescribeLifecycleHookTypes = "DescribeLifecycleHookTypes" // DescribeLifecycleHookTypesRequest generates a "aws/request.Request" representing the // client's request for the DescribeLifecycleHookTypes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2038,7 +2055,7 @@ const opDescribeLifecycleHooks = "DescribeLifecycleHooks" // DescribeLifecycleHooksRequest generates a "aws/request.Request" representing the // client's request for the DescribeLifecycleHooks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2118,7 +2135,7 @@ const opDescribeLoadBalancerTargetGroups = "DescribeLoadBalancerTargetGroups" // DescribeLoadBalancerTargetGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeLoadBalancerTargetGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2198,7 +2215,7 @@ const opDescribeLoadBalancers = "DescribeLoadBalancers" // DescribeLoadBalancersRequest generates a "aws/request.Request" representing the // client's request for the DescribeLoadBalancers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2281,7 +2298,7 @@ const opDescribeMetricCollectionTypes = "DescribeMetricCollectionTypes" // DescribeMetricCollectionTypesRequest generates a "aws/request.Request" representing the // client's request for the DescribeMetricCollectionTypes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2364,7 +2381,7 @@ const opDescribeNotificationConfigurations = "DescribeNotificationConfigurations // DescribeNotificationConfigurationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeNotificationConfigurations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2504,7 +2521,7 @@ const opDescribePolicies = "DescribePolicies" // DescribePoliciesRequest generates a "aws/request.Request" representing the // client's request for the DescribePolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2567,6 +2584,9 @@ func (c *AutoScaling) DescribePoliciesRequest(input *DescribePoliciesInput) (req // You already have a pending update to an Auto Scaling resource (for example, // a group, instance, or load balancer). // +// * ErrCodeServiceLinkedRoleFailure "ServiceLinkedRoleFailure" +// The service-linked role is not yet ready for use. +// // See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-2011-01-01/DescribePolicies func (c *AutoScaling) DescribePolicies(input *DescribePoliciesInput) (*DescribePoliciesOutput, error) { req, out := c.DescribePoliciesRequest(input) @@ -2643,7 +2663,7 @@ const opDescribeScalingActivities = "DescribeScalingActivities" // DescribeScalingActivitiesRequest generates a "aws/request.Request" representing the // client's request for the DescribeScalingActivities operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2782,7 +2802,7 @@ const opDescribeScalingProcessTypes = "DescribeScalingProcessTypes" // DescribeScalingProcessTypesRequest generates a "aws/request.Request" representing the // client's request for the DescribeScalingProcessTypes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2862,7 +2882,7 @@ const opDescribeScheduledActions = "DescribeScheduledActions" // DescribeScheduledActionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeScheduledActions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3002,7 +3022,7 @@ const opDescribeTags = "DescribeTags" // DescribeTagsRequest generates a "aws/request.Request" representing the // client's request for the DescribeTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3150,7 +3170,7 @@ const opDescribeTerminationPolicyTypes = "DescribeTerminationPolicyTypes" // DescribeTerminationPolicyTypesRequest generates a "aws/request.Request" representing the // client's request for the DescribeTerminationPolicyTypes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3230,7 +3250,7 @@ const opDetachInstances = "DetachInstances" // DetachInstancesRequest generates a "aws/request.Request" representing the // client's request for the DetachInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3325,7 +3345,7 @@ const opDetachLoadBalancerTargetGroups = "DetachLoadBalancerTargetGroups" // DetachLoadBalancerTargetGroupsRequest generates a "aws/request.Request" representing the // client's request for the DetachLoadBalancerTargetGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3405,7 +3425,7 @@ const opDetachLoadBalancers = "DetachLoadBalancers" // DetachLoadBalancersRequest generates a "aws/request.Request" representing the // client's request for the DetachLoadBalancers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3494,7 +3514,7 @@ const opDisableMetricsCollection = "DisableMetricsCollection" // DisableMetricsCollectionRequest generates a "aws/request.Request" representing the // client's request for the DisableMetricsCollection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3576,7 +3596,7 @@ const opEnableMetricsCollection = "EnableMetricsCollection" // EnableMetricsCollectionRequest generates a "aws/request.Request" representing the // client's request for the EnableMetricsCollection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3660,7 +3680,7 @@ const opEnterStandby = "EnterStandby" // EnterStandbyRequest generates a "aws/request.Request" representing the // client's request for the EnterStandby operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3744,7 +3764,7 @@ const opExecutePolicy = "ExecutePolicy" // ExecutePolicyRequest generates a "aws/request.Request" representing the // client's request for the ExecutePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3830,7 +3850,7 @@ const opExitStandby = "ExitStandby" // ExitStandbyRequest generates a "aws/request.Request" representing the // client's request for the ExitStandby operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3914,7 +3934,7 @@ const opPutLifecycleHook = "PutLifecycleHook" // PutLifecycleHookRequest generates a "aws/request.Request" representing the // client's request for the PutLifecycleHook operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4029,7 +4049,7 @@ const opPutNotificationConfiguration = "PutNotificationConfiguration" // PutNotificationConfigurationRequest generates a "aws/request.Request" representing the // client's request for the PutNotificationConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4098,6 +4118,9 @@ func (c *AutoScaling) PutNotificationConfigurationRequest(input *PutNotification // You already have a pending update to an Auto Scaling resource (for example, // a group, instance, or load balancer). // +// * ErrCodeServiceLinkedRoleFailure "ServiceLinkedRoleFailure" +// The service-linked role is not yet ready for use. +// // See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-2011-01-01/PutNotificationConfiguration func (c *AutoScaling) PutNotificationConfiguration(input *PutNotificationConfigurationInput) (*PutNotificationConfigurationOutput, error) { req, out := c.PutNotificationConfigurationRequest(input) @@ -4124,7 +4147,7 @@ const opPutScalingPolicy = "PutScalingPolicy" // PutScalingPolicyRequest generates a "aws/request.Request" representing the // client's request for the PutScalingPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4191,6 +4214,9 @@ func (c *AutoScaling) PutScalingPolicyRequest(input *PutScalingPolicyInput) (req // You already have a pending update to an Auto Scaling resource (for example, // a group, instance, or load balancer). // +// * ErrCodeServiceLinkedRoleFailure "ServiceLinkedRoleFailure" +// The service-linked role is not yet ready for use. +// // See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-2011-01-01/PutScalingPolicy func (c *AutoScaling) PutScalingPolicy(input *PutScalingPolicyInput) (*PutScalingPolicyOutput, error) { req, out := c.PutScalingPolicyRequest(input) @@ -4217,7 +4243,7 @@ const opPutScheduledUpdateGroupAction = "PutScheduledUpdateGroupAction" // PutScheduledUpdateGroupActionRequest generates a "aws/request.Request" representing the // client's request for the PutScheduledUpdateGroupAction operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4313,7 +4339,7 @@ const opRecordLifecycleActionHeartbeat = "RecordLifecycleActionHeartbeat" // RecordLifecycleActionHeartbeatRequest generates a "aws/request.Request" representing the // client's request for the RecordLifecycleActionHeartbeat operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4416,7 +4442,7 @@ const opResumeProcesses = "ResumeProcesses" // ResumeProcessesRequest generates a "aws/request.Request" representing the // client's request for the ResumeProcesses operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4506,7 +4532,7 @@ const opSetDesiredCapacity = "SetDesiredCapacity" // SetDesiredCapacityRequest generates a "aws/request.Request" representing the // client's request for the SetDesiredCapacity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4595,7 +4621,7 @@ const opSetInstanceHealth = "SetInstanceHealth" // SetInstanceHealthRequest generates a "aws/request.Request" representing the // client's request for the SetInstanceHealth operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4680,7 +4706,7 @@ const opSetInstanceProtection = "SetInstanceProtection" // SetInstanceProtectionRequest generates a "aws/request.Request" representing the // client's request for the SetInstanceProtection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4768,7 +4794,7 @@ const opSuspendProcesses = "SuspendProcesses" // SuspendProcessesRequest generates a "aws/request.Request" representing the // client's request for the SuspendProcesses operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4863,7 +4889,7 @@ const opTerminateInstanceInAutoScalingGroup = "TerminateInstanceInAutoScalingGro // TerminateInstanceInAutoScalingGroupRequest generates a "aws/request.Request" representing the // client's request for the TerminateInstanceInAutoScalingGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4951,7 +4977,7 @@ const opUpdateAutoScalingGroup = "UpdateAutoScalingGroup" // UpdateAutoScalingGroupRequest generates a "aws/request.Request" representing the // client's request for the UpdateAutoScalingGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5033,6 +5059,9 @@ func (c *AutoScaling) UpdateAutoScalingGroupRequest(input *UpdateAutoScalingGrou // You already have a pending update to an Auto Scaling resource (for example, // a group, instance, or load balancer). // +// * ErrCodeServiceLinkedRoleFailure "ServiceLinkedRoleFailure" +// The service-linked role is not yet ready for use. +// // See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-2011-01-01/UpdateAutoScalingGroup func (c *AutoScaling) UpdateAutoScalingGroup(input *UpdateAutoScalingGroupInput) (*UpdateAutoScalingGroupOutput, error) { req, out := c.UpdateAutoScalingGroupRequest(input) @@ -5241,7 +5270,7 @@ type AttachInstancesInput struct { // AutoScalingGroupName is a required field AutoScalingGroupName *string `min:"1" type:"string" required:"true"` - // One or more instance IDs. + // The IDs of the instances. You can specify up to 20 instances. InstanceIds []*string `type:"list"` } @@ -5305,7 +5334,8 @@ type AttachLoadBalancerTargetGroupsInput struct { // AutoScalingGroupName is a required field AutoScalingGroupName *string `min:"1" type:"string" required:"true"` - // The Amazon Resource Names (ARN) of the target groups. + // The Amazon Resource Names (ARN) of the target groups. You can specify up + // to 10 target groups. // // TargetGroupARNs is a required field TargetGroupARNs []*string `type:"list" required:"true"` @@ -5374,7 +5404,7 @@ type AttachLoadBalancersInput struct { // AutoScalingGroupName is a required field AutoScalingGroupName *string `min:"1" type:"string" required:"true"` - // One or more load balancer names. + // The names of the load balancers. You can specify up to 10 load balancers. // // LoadBalancerNames is a required field LoadBalancerNames []*string `type:"list" required:"true"` @@ -5725,6 +5755,12 @@ type CreateAutoScalingGroupInput struct { // in the Amazon Elastic Compute Cloud User Guide. PlacementGroup *string `min:"1" type:"string"` + // The Amazon Resource Name (ARN) of the service-linked role that the Auto Scaling + // group uses to call other AWS services on your behalf. By default, Auto Scaling + // uses a service-linked role named AWSServiceRoleForAutoScaling, which it creates + // if it does not exist. + ServiceLinkedRoleARN *string `min:"1" type:"string"` + // One or more tags. // // For more information, see Tagging Auto Scaling Groups and Instances (http://docs.aws.amazon.com/autoscaling/latest/userguide/autoscaling-tagging.html) @@ -5793,6 +5829,9 @@ func (s *CreateAutoScalingGroupInput) Validate() error { if s.PlacementGroup != nil && len(*s.PlacementGroup) < 1 { invalidParams.Add(request.NewErrParamMinLen("PlacementGroup", 1)) } + if s.ServiceLinkedRoleARN != nil && len(*s.ServiceLinkedRoleARN) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ServiceLinkedRoleARN", 1)) + } if s.VPCZoneIdentifier != nil && len(*s.VPCZoneIdentifier) < 1 { invalidParams.Add(request.NewErrParamMinLen("VPCZoneIdentifier", 1)) } @@ -5918,6 +5957,12 @@ func (s *CreateAutoScalingGroupInput) SetPlacementGroup(v string) *CreateAutoSca return s } +// SetServiceLinkedRoleARN sets the ServiceLinkedRoleARN field's value. +func (s *CreateAutoScalingGroupInput) SetServiceLinkedRoleARN(v string) *CreateAutoScalingGroupInput { + s.ServiceLinkedRoleARN = &v + return s +} + // SetTags sets the Tags field's value. func (s *CreateAutoScalingGroupInput) SetTags(v []*Tag) *CreateAutoScalingGroupInput { s.Tags = v @@ -5968,9 +6013,8 @@ type CreateLaunchConfigurationInput struct { // you create your group. // // Default: If the instance is launched into a default subnet, the default is - // true. If the instance is launched into a nondefault subnet, the default is - // false. For more information, see Supported Platforms (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-supported-platforms.html) - // in the Amazon Elastic Compute Cloud User Guide. + // to assign a public IP address. If the instance is launched into a nondefault + // subnet, the default is not to assign a public IP address. AssociatePublicIpAddress *bool `type:"boolean"` // One or more mappings that specify how block devices are exposed to the instance. @@ -7106,7 +7150,7 @@ type DescribeAutoScalingInstancesInput struct { InstanceIds []*string `type:"list"` // The maximum number of items to return with this call. The default value is - // 50 and the maximum value is 100. + // 50 and the maximum value is 50. MaxRecords *int64 `type:"integer"` // The token for the next set of items to return. (You received this token from @@ -7411,7 +7455,7 @@ type DescribeLoadBalancerTargetGroupsInput struct { AutoScalingGroupName *string `min:"1" type:"string" required:"true"` // The maximum number of items to return with this call. The default value is - // 50 and the maximum value is 100. + // 100 and the maximum value is 100. MaxRecords *int64 `type:"integer"` // The token for the next set of items to return. (You received this token from @@ -7505,7 +7549,7 @@ type DescribeLoadBalancersInput struct { AutoScalingGroupName *string `min:"1" type:"string" required:"true"` // The maximum number of items to return with this call. The default value is - // 50 and the maximum value is 100. + // 100 and the maximum value is 100. MaxRecords *int64 `type:"integer"` // The token for the next set of items to return. (You received this token from @@ -7838,7 +7882,7 @@ type DescribeScalingActivitiesInput struct { AutoScalingGroupName *string `min:"1" type:"string"` // The maximum number of items to return with this call. The default value is - // 100. + // 100 and the maximum value is 100. MaxRecords *int64 `type:"integer"` // The token for the next set of items to return. (You received this token from @@ -8212,11 +8256,11 @@ type DetachInstancesInput struct { // AutoScalingGroupName is a required field AutoScalingGroupName *string `min:"1" type:"string" required:"true"` - // One or more instance IDs. + // The IDs of the instances. You can specify up to 20 instances. InstanceIds []*string `type:"list"` - // If True, the Auto Scaling group decrements the desired capacity value by - // the number of instances detached. + // Indicates whether the Auto Scaling group decrements the desired capacity + // value by the number of instances detached. // // ShouldDecrementDesiredCapacity is a required field ShouldDecrementDesiredCapacity *bool `type:"boolean" required:"true"` @@ -8300,7 +8344,8 @@ type DetachLoadBalancerTargetGroupsInput struct { // AutoScalingGroupName is a required field AutoScalingGroupName *string `min:"1" type:"string" required:"true"` - // The Amazon Resource Names (ARN) of the target groups. + // The Amazon Resource Names (ARN) of the target groups. You can specify up + // to 10 target groups. // // TargetGroupARNs is a required field TargetGroupARNs []*string `type:"list" required:"true"` @@ -8369,7 +8414,7 @@ type DetachLoadBalancersInput struct { // AutoScalingGroupName is a required field AutoScalingGroupName *string `min:"1" type:"string" required:"true"` - // One or more load balancer names. + // The names of the load balancers. You can specify up to 10 load balancers. // // LoadBalancerNames is a required field LoadBalancerNames []*string `type:"list" required:"true"` @@ -8515,9 +8560,8 @@ func (s DisableMetricsCollectionOutput) GoString() string { type Ebs struct { _ struct{} `type:"structure"` - // Indicates whether the volume is deleted on instance termination. - // - // Default: true + // Indicates whether the volume is deleted on instance termination. The default + // is true. DeleteOnTermination *bool `type:"boolean"` // Indicates whether the volume should be encrypted. Encrypted EBS volumes must @@ -8779,14 +8823,11 @@ type EnterStandbyInput struct { // AutoScalingGroupName is a required field AutoScalingGroupName *string `min:"1" type:"string" required:"true"` - // One or more instances to move into Standby mode. You must specify at least - // one instance ID. + // The IDs of the instances. You can specify up to 20 instances. InstanceIds []*string `type:"list"` - // Specifies whether the instances moved to Standby mode count as part of the - // Auto Scaling group's desired capacity. If set, the desired capacity for the - // Auto Scaling group decrements by the number of instances moved to Standby - // mode. + // Indicates whether to decrement the desired capacity of the Auto Scaling group + // by the number of instances moved to Standby mode. // // ShouldDecrementDesiredCapacity is a required field ShouldDecrementDesiredCapacity *bool `type:"boolean" required:"true"` @@ -8874,9 +8915,8 @@ type ExecutePolicyInput struct { // otherwise. BreachThreshold *float64 `type:"double"` - // If this parameter is true, Auto Scaling waits for the cooldown period to - // complete before executing the policy. Otherwise, Auto Scaling executes the - // policy without waiting for the cooldown period to complete. + // Indicates whether Auto Scaling waits for the cooldown period to complete + // before executing the policy. // // This parameter is not supported if the policy type is StepScaling. // @@ -8984,7 +9024,7 @@ type ExitStandbyInput struct { // AutoScalingGroupName is a required field AutoScalingGroupName *string `min:"1" type:"string" required:"true"` - // One or more instance IDs. You must specify at least one instance ID. + // The IDs of the instances. You can specify up to 20 instances. InstanceIds []*string `type:"list"` } @@ -9159,6 +9199,10 @@ type Group struct { // in the Amazon Elastic Compute Cloud User Guide. PlacementGroup *string `min:"1" type:"string"` + // The Amazon Resource Name (ARN) of the service-linked role that the Auto Scaling + // group uses to call other AWS services on your behalf. + ServiceLinkedRoleARN *string `min:"1" type:"string"` + // The current state of the group when DeleteAutoScalingGroup is in progress. Status *string `min:"1" type:"string"` @@ -9293,6 +9337,12 @@ func (s *Group) SetPlacementGroup(v string) *Group { return s } +// SetServiceLinkedRoleARN sets the ServiceLinkedRoleARN field's value. +func (s *Group) SetServiceLinkedRoleARN(v string) *Group { + s.ServiceLinkedRoleARN = &v + return s +} + // SetStatus sets the Status field's value. func (s *Group) SetStatus(v string) *Group { s.Status = &v @@ -9766,8 +9816,10 @@ type LaunchTemplateSpecification struct { // or a template ID. LaunchTemplateName *string `min:"3" type:"string"` - // The version number. By default, the default version of the launch template - // is used. + // The version number, $Latest, or $Default. If the value is $Latest, Auto Scaling + // selects the latest version of the launch template when launching instances. + // If the value is $Default, Auto Scaling selects the default version of the + // launch template when launching instances. The default value is $Default. Version *string `min:"1" type:"string"` } @@ -11542,10 +11594,10 @@ type SetDesiredCapacityInput struct { // DesiredCapacity is a required field DesiredCapacity *int64 `type:"integer" required:"true"` - // By default, SetDesiredCapacity overrides any cooldown period associated with - // the Auto Scaling group. Specify True to make Auto Scaling to wait for the - // cool-down period associated with the Auto Scaling group to complete before - // initiating a scaling activity to set your Auto Scaling group to its new capacity. + // Indicates whether Auto Scaling waits for the cooldown period to complete + // before initiating a scaling activity to set your Auto Scaling group to its + // new capacity. By default, Auto Scaling does not honor the cooldown period + // during manual scaling activities. HonorCooldown *bool `type:"boolean"` } @@ -12076,10 +12128,9 @@ type TargetTrackingConfiguration struct { CustomizedMetricSpecification *CustomizedMetricSpecification `type:"structure"` // Indicates whether scale in by the target tracking policy is disabled. If - // the value is true, scale in is disabled and the target tracking policy won't - // remove instances from the Auto Scaling group. Otherwise, scale in is enabled - // and the target tracking policy can remove instances from the Auto Scaling - // group. The default value is false. + // scale in is disabled, the target tracking policy won't remove instances from + // the Auto Scaling group. Otherwise, the target tracking policy can remove + // instances from the Auto Scaling group. The default is disabled. DisableScaleIn *bool `type:"boolean"` // A predefined metric. You can specify either a predefined metric or a customized @@ -12157,8 +12208,8 @@ type TerminateInstanceInAutoScalingGroupInput struct { // InstanceId is a required field InstanceId *string `min:"1" type:"string" required:"true"` - // If true, terminating the instance also decrements the size of the Auto Scaling - // group. + // Indicates whether terminating the instance also decrements the size of the + // Auto Scaling group. // // ShouldDecrementDesiredCapacity is a required field ShouldDecrementDesiredCapacity *bool `type:"boolean" required:"true"` @@ -12262,12 +12313,12 @@ type UpdateAutoScalingGroupInput struct { // The service to use for the health checks. The valid values are EC2 and ELB. HealthCheckType *string `min:"1" type:"string"` - // The name of the launch configuration. You must specify either a launch configuration - // or a launch template. + // The name of the launch configuration. If you specify a launch configuration, + // you can't specify a launch template. LaunchConfigurationName *string `min:"1" type:"string"` - // The launch template to use to specify the updates. You must specify a launch - // configuration or a launch template. + // The launch template to use to specify the updates. If you specify a launch + // template, you can't specify a launch configuration. LaunchTemplate *LaunchTemplateSpecification `type:"structure"` // The maximum size of the Auto Scaling group. @@ -12285,6 +12336,10 @@ type UpdateAutoScalingGroupInput struct { // in the Amazon Elastic Compute Cloud User Guide. PlacementGroup *string `min:"1" type:"string"` + // The Amazon Resource Name (ARN) of the service-linked role that the Auto Scaling + // group uses to call other AWS services on your behalf. + ServiceLinkedRoleARN *string `min:"1" type:"string"` + // A standalone termination policy or a list of termination policies used to // select the instance to terminate. The policies are executed in the order // that they are listed. @@ -12336,6 +12391,9 @@ func (s *UpdateAutoScalingGroupInput) Validate() error { if s.PlacementGroup != nil && len(*s.PlacementGroup) < 1 { invalidParams.Add(request.NewErrParamMinLen("PlacementGroup", 1)) } + if s.ServiceLinkedRoleARN != nil && len(*s.ServiceLinkedRoleARN) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ServiceLinkedRoleARN", 1)) + } if s.VPCZoneIdentifier != nil && len(*s.VPCZoneIdentifier) < 1 { invalidParams.Add(request.NewErrParamMinLen("VPCZoneIdentifier", 1)) } @@ -12423,6 +12481,12 @@ func (s *UpdateAutoScalingGroupInput) SetPlacementGroup(v string) *UpdateAutoSca return s } +// SetServiceLinkedRoleARN sets the ServiceLinkedRoleARN field's value. +func (s *UpdateAutoScalingGroupInput) SetServiceLinkedRoleARN(v string) *UpdateAutoScalingGroupInput { + s.ServiceLinkedRoleARN = &v + return s +} + // SetTerminationPolicies sets the TerminationPolicies field's value. func (s *UpdateAutoScalingGroupInput) SetTerminationPolicies(v []*string) *UpdateAutoScalingGroupInput { s.TerminationPolicies = v diff --git a/vendor/github.com/aws/aws-sdk-go/service/autoscaling/doc.go b/vendor/github.com/aws/aws-sdk-go/service/autoscaling/doc.go index 34748cf6e739..f431b8aa39bf 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/autoscaling/doc.go +++ b/vendor/github.com/aws/aws-sdk-go/service/autoscaling/doc.go @@ -3,9 +3,10 @@ // Package autoscaling provides the client and types for making API // requests to Auto Scaling. // -// Auto Scaling is designed to automatically launch or terminate EC2 instances -// based on user-defined policies, schedules, and health checks. Use this service -// in conjunction with the Amazon CloudWatch and Elastic Load Balancing services. +// Amazon EC2 Auto Scaling is designed to automatically launch or terminate +// EC2 instances based on user-defined policies, schedules, and health checks. +// Use this service in conjunction with the AWS Auto Scaling, Amazon CloudWatch, +// and Elastic Load Balancing services. // // See https://docs.aws.amazon.com/goto/WebAPI/autoscaling-2011-01-01 for more information on this service. // diff --git a/vendor/github.com/aws/aws-sdk-go/service/autoscaling/errors.go b/vendor/github.com/aws/aws-sdk-go/service/autoscaling/errors.go index 68ab1e3c12dd..be8b7e70b131 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/autoscaling/errors.go +++ b/vendor/github.com/aws/aws-sdk-go/service/autoscaling/errors.go @@ -44,4 +44,10 @@ const ( // The operation can't be performed because there are scaling activities in // progress. ErrCodeScalingActivityInProgressFault = "ScalingActivityInProgress" + + // ErrCodeServiceLinkedRoleFailure for service response error code + // "ServiceLinkedRoleFailure". + // + // The service-linked role is not yet ready for use. + ErrCodeServiceLinkedRoleFailure = "ServiceLinkedRoleFailure" ) diff --git a/vendor/github.com/aws/aws-sdk-go/service/batch/api.go b/vendor/github.com/aws/aws-sdk-go/service/batch/api.go index 9921afa192f8..3ba37aab666d 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/batch/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/batch/api.go @@ -14,7 +14,7 @@ const opCancelJob = "CancelJob" // CancelJobRequest generates a "aws/request.Request" representing the // client's request for the CancelJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -102,7 +102,7 @@ const opCreateComputeEnvironment = "CreateComputeEnvironment" // CreateComputeEnvironmentRequest generates a "aws/request.Request" representing the // client's request for the CreateComputeEnvironment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -207,7 +207,7 @@ const opCreateJobQueue = "CreateJobQueue" // CreateJobQueueRequest generates a "aws/request.Request" representing the // client's request for the CreateJobQueue operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -299,7 +299,7 @@ const opDeleteComputeEnvironment = "DeleteComputeEnvironment" // DeleteComputeEnvironmentRequest generates a "aws/request.Request" representing the // client's request for the DeleteComputeEnvironment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -387,7 +387,7 @@ const opDeleteJobQueue = "DeleteJobQueue" // DeleteJobQueueRequest generates a "aws/request.Request" representing the // client's request for the DeleteJobQueue operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -476,7 +476,7 @@ const opDeregisterJobDefinition = "DeregisterJobDefinition" // DeregisterJobDefinitionRequest generates a "aws/request.Request" representing the // client's request for the DeregisterJobDefinition operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -560,7 +560,7 @@ const opDescribeComputeEnvironments = "DescribeComputeEnvironments" // DescribeComputeEnvironmentsRequest generates a "aws/request.Request" representing the // client's request for the DescribeComputeEnvironments operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -648,7 +648,7 @@ const opDescribeJobDefinitions = "DescribeJobDefinitions" // DescribeJobDefinitionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeJobDefinitions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -733,7 +733,7 @@ const opDescribeJobQueues = "DescribeJobQueues" // DescribeJobQueuesRequest generates a "aws/request.Request" representing the // client's request for the DescribeJobQueues operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -817,7 +817,7 @@ const opDescribeJobs = "DescribeJobs" // DescribeJobsRequest generates a "aws/request.Request" representing the // client's request for the DescribeJobs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -901,7 +901,7 @@ const opListJobs = "ListJobs" // ListJobsRequest generates a "aws/request.Request" representing the // client's request for the ListJobs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -987,7 +987,7 @@ const opRegisterJobDefinition = "RegisterJobDefinition" // RegisterJobDefinitionRequest generates a "aws/request.Request" representing the // client's request for the RegisterJobDefinition operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1071,7 +1071,7 @@ const opSubmitJob = "SubmitJob" // SubmitJobRequest generates a "aws/request.Request" representing the // client's request for the SubmitJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1156,7 +1156,7 @@ const opTerminateJob = "TerminateJob" // TerminateJobRequest generates a "aws/request.Request" representing the // client's request for the TerminateJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1242,7 +1242,7 @@ const opUpdateComputeEnvironment = "UpdateComputeEnvironment" // UpdateComputeEnvironmentRequest generates a "aws/request.Request" representing the // client's request for the UpdateComputeEnvironment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1326,7 +1326,7 @@ const opUpdateJobQueue = "UpdateJobQueue" // UpdateJobQueueRequest generates a "aws/request.Request" representing the // client's request for the UpdateJobQueue operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/cloud9/api.go b/vendor/github.com/aws/aws-sdk-go/service/cloud9/api.go index 9cda728ffe4f..1494b5c02858 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/cloud9/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/cloud9/api.go @@ -14,7 +14,7 @@ const opCreateEnvironmentEC2 = "CreateEnvironmentEC2" // CreateEnvironmentEC2Request generates a "aws/request.Request" representing the // client's request for the CreateEnvironmentEC2 operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -113,7 +113,7 @@ const opCreateEnvironmentMembership = "CreateEnvironmentMembership" // CreateEnvironmentMembershipRequest generates a "aws/request.Request" representing the // client's request for the CreateEnvironmentMembership operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -210,7 +210,7 @@ const opDeleteEnvironment = "DeleteEnvironment" // DeleteEnvironmentRequest generates a "aws/request.Request" representing the // client's request for the DeleteEnvironment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -308,7 +308,7 @@ const opDeleteEnvironmentMembership = "DeleteEnvironmentMembership" // DeleteEnvironmentMembershipRequest generates a "aws/request.Request" representing the // client's request for the DeleteEnvironmentMembership operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -405,7 +405,7 @@ const opDescribeEnvironmentMemberships = "DescribeEnvironmentMemberships" // DescribeEnvironmentMembershipsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEnvironmentMemberships operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -559,7 +559,7 @@ const opDescribeEnvironmentStatus = "DescribeEnvironmentStatus" // DescribeEnvironmentStatusRequest generates a "aws/request.Request" representing the // client's request for the DescribeEnvironmentStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -656,7 +656,7 @@ const opDescribeEnvironments = "DescribeEnvironments" // DescribeEnvironmentsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEnvironments operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -753,7 +753,7 @@ const opListEnvironments = "ListEnvironments" // ListEnvironmentsRequest generates a "aws/request.Request" representing the // client's request for the ListEnvironments operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -906,7 +906,7 @@ const opUpdateEnvironment = "UpdateEnvironment" // UpdateEnvironmentRequest generates a "aws/request.Request" representing the // client's request for the UpdateEnvironment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1003,7 +1003,7 @@ const opUpdateEnvironmentMembership = "UpdateEnvironmentMembership" // UpdateEnvironmentMembershipRequest generates a "aws/request.Request" representing the // client's request for the UpdateEnvironmentMembership operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/cloudformation/api.go b/vendor/github.com/aws/aws-sdk-go/service/cloudformation/api.go index 8a07b648e561..673b3636cebe 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/cloudformation/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/cloudformation/api.go @@ -17,7 +17,7 @@ const opCancelUpdateStack = "CancelUpdateStack" // CancelUpdateStackRequest generates a "aws/request.Request" representing the // client's request for the CancelUpdateStack operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -101,7 +101,7 @@ const opContinueUpdateRollback = "ContinueUpdateRollback" // ContinueUpdateRollbackRequest generates a "aws/request.Request" representing the // client's request for the ContinueUpdateRollback operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -192,7 +192,7 @@ const opCreateChangeSet = "CreateChangeSet" // CreateChangeSetRequest generates a "aws/request.Request" representing the // client's request for the CreateChangeSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -300,7 +300,7 @@ const opCreateStack = "CreateStack" // CreateStackRequest generates a "aws/request.Request" representing the // client's request for the CreateStack operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -393,7 +393,7 @@ const opCreateStackInstances = "CreateStackInstances" // CreateStackInstancesRequest generates a "aws/request.Request" representing the // client's request for the CreateStackInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -494,7 +494,7 @@ const opCreateStackSet = "CreateStackSet" // CreateStackSetRequest generates a "aws/request.Request" representing the // client's request for the CreateStackSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -581,7 +581,7 @@ const opDeleteChangeSet = "DeleteChangeSet" // DeleteChangeSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteChangeSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -666,7 +666,7 @@ const opDeleteStack = "DeleteStack" // DeleteStackRequest generates a "aws/request.Request" representing the // client's request for the DeleteStack operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -749,7 +749,7 @@ const opDeleteStackInstances = "DeleteStackInstances" // DeleteStackInstancesRequest generates a "aws/request.Request" representing the // client's request for the DeleteStackInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -842,7 +842,7 @@ const opDeleteStackSet = "DeleteStackSet" // DeleteStackSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteStackSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -929,7 +929,7 @@ const opDescribeAccountLimits = "DescribeAccountLimits" // DescribeAccountLimitsRequest generates a "aws/request.Request" representing the // client's request for the DescribeAccountLimits operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1004,7 +1004,7 @@ const opDescribeChangeSet = "DescribeChangeSet" // DescribeChangeSetRequest generates a "aws/request.Request" representing the // client's request for the DescribeChangeSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1087,7 +1087,7 @@ const opDescribeStackEvents = "DescribeStackEvents" // DescribeStackEventsRequest generates a "aws/request.Request" representing the // client's request for the DescribeStackEvents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1222,7 +1222,7 @@ const opDescribeStackInstance = "DescribeStackInstance" // DescribeStackInstanceRequest generates a "aws/request.Request" representing the // client's request for the DescribeStackInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1308,7 +1308,7 @@ const opDescribeStackResource = "DescribeStackResource" // DescribeStackResourceRequest generates a "aws/request.Request" representing the // client's request for the DescribeStackResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1385,7 +1385,7 @@ const opDescribeStackResources = "DescribeStackResources" // DescribeStackResourcesRequest generates a "aws/request.Request" representing the // client's request for the DescribeStackResources operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1476,7 +1476,7 @@ const opDescribeStackSet = "DescribeStackSet" // DescribeStackSetRequest generates a "aws/request.Request" representing the // client's request for the DescribeStackSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1555,7 +1555,7 @@ const opDescribeStackSetOperation = "DescribeStackSetOperation" // DescribeStackSetOperationRequest generates a "aws/request.Request" representing the // client's request for the DescribeStackSetOperation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1637,7 +1637,7 @@ const opDescribeStacks = "DescribeStacks" // DescribeStacksRequest generates a "aws/request.Request" representing the // client's request for the DescribeStacks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1770,7 +1770,7 @@ const opEstimateTemplateCost = "EstimateTemplateCost" // EstimateTemplateCostRequest generates a "aws/request.Request" representing the // client's request for the EstimateTemplateCost operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1846,7 +1846,7 @@ const opExecuteChangeSet = "ExecuteChangeSet" // ExecuteChangeSetRequest generates a "aws/request.Request" representing the // client's request for the ExecuteChangeSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1949,7 +1949,7 @@ const opGetStackPolicy = "GetStackPolicy" // GetStackPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetStackPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2024,7 +2024,7 @@ const opGetTemplate = "GetTemplate" // GetTemplateRequest generates a "aws/request.Request" representing the // client's request for the GetTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2110,7 +2110,7 @@ const opGetTemplateSummary = "GetTemplateSummary" // GetTemplateSummaryRequest generates a "aws/request.Request" representing the // client's request for the GetTemplateSummary operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2200,7 +2200,7 @@ const opListChangeSets = "ListChangeSets" // ListChangeSetsRequest generates a "aws/request.Request" representing the // client's request for the ListChangeSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2276,7 +2276,7 @@ const opListExports = "ListExports" // ListExportsRequest generates a "aws/request.Request" representing the // client's request for the ListExports operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2412,7 +2412,7 @@ const opListImports = "ListImports" // ListImportsRequest generates a "aws/request.Request" representing the // client's request for the ListImports operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2548,7 +2548,7 @@ const opListStackInstances = "ListStackInstances" // ListStackInstancesRequest generates a "aws/request.Request" representing the // client's request for the ListStackInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2629,7 +2629,7 @@ const opListStackResources = "ListStackResources" // ListStackResourcesRequest generates a "aws/request.Request" representing the // client's request for the ListStackResources operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2762,7 +2762,7 @@ const opListStackSetOperationResults = "ListStackSetOperationResults" // ListStackSetOperationResultsRequest generates a "aws/request.Request" representing the // client's request for the ListStackSetOperationResults operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2844,7 +2844,7 @@ const opListStackSetOperations = "ListStackSetOperations" // ListStackSetOperationsRequest generates a "aws/request.Request" representing the // client's request for the ListStackSetOperations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2923,7 +2923,7 @@ const opListStackSets = "ListStackSets" // ListStackSetsRequest generates a "aws/request.Request" representing the // client's request for the ListStackSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2998,7 +2998,7 @@ const opListStacks = "ListStacks" // ListStacksRequest generates a "aws/request.Request" representing the // client's request for the ListStacks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3132,7 +3132,7 @@ const opSetStackPolicy = "SetStackPolicy" // SetStackPolicyRequest generates a "aws/request.Request" representing the // client's request for the SetStackPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3208,7 +3208,7 @@ const opSignalResource = "SignalResource" // SignalResourceRequest generates a "aws/request.Request" representing the // client's request for the SignalResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3289,7 +3289,7 @@ const opStopStackSetOperation = "StopStackSetOperation" // StopStackSetOperationRequest generates a "aws/request.Request" representing the // client's request for the StopStackSetOperation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3374,7 +3374,7 @@ const opUpdateStack = "UpdateStack" // UpdateStackRequest generates a "aws/request.Request" representing the // client's request for the UpdateStack operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3465,7 +3465,7 @@ const opUpdateStackInstances = "UpdateStackInstances" // UpdateStackInstancesRequest generates a "aws/request.Request" representing the // client's request for the UpdateStackInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3578,7 +3578,7 @@ const opUpdateStackSet = "UpdateStackSet" // UpdateStackSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateStackSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3676,7 +3676,7 @@ const opUpdateTerminationProtection = "UpdateTerminationProtection" // UpdateTerminationProtectionRequest generates a "aws/request.Request" representing the // client's request for the UpdateTerminationProtection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3758,7 +3758,7 @@ const opValidateTemplate = "ValidateTemplate" // ValidateTemplateRequest generates a "aws/request.Request" representing the // client's request for the ValidateTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5125,6 +5125,16 @@ func (s *CreateStackOutput) SetStackId(v string) *CreateStackOutput { type CreateStackSetInput struct { _ struct{} `type:"structure"` + // The Amazon Resource Number (ARN) of the IAM role to use to create this stack + // set. + // + // Specify an IAM role only if you are using customized administrator roles + // to control which users or groups can manage specific stack sets within the + // same administrator account. For more information, see Define Permissions + // for Multiple Administrators (http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/stacksets-prereqs.html) + // in the AWS CloudFormation User Guide. + AdministrationRoleARN *string `min:"20" type:"string"` + // A list of values that you must specify before AWS CloudFormation can create // certain stack sets. Some stack set templates might include resources that // can affect permissions in your AWS account—for example, by creating new AWS @@ -5229,6 +5239,9 @@ func (s CreateStackSetInput) GoString() string { // Validate inspects the fields of the type to determine if they are valid. func (s *CreateStackSetInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "CreateStackSetInput"} + if s.AdministrationRoleARN != nil && len(*s.AdministrationRoleARN) < 20 { + invalidParams.Add(request.NewErrParamMinLen("AdministrationRoleARN", 20)) + } if s.ClientRequestToken != nil && len(*s.ClientRequestToken) < 1 { invalidParams.Add(request.NewErrParamMinLen("ClientRequestToken", 1)) } @@ -5261,6 +5274,12 @@ func (s *CreateStackSetInput) Validate() error { return nil } +// SetAdministrationRoleARN sets the AdministrationRoleARN field's value. +func (s *CreateStackSetInput) SetAdministrationRoleARN(v string) *CreateStackSetInput { + s.AdministrationRoleARN = &v + return s +} + // SetCapabilities sets the Capabilities field's value. func (s *CreateStackSetInput) SetCapabilities(v []*string) *CreateStackSetInput { s.Capabilities = v @@ -8527,38 +8546,21 @@ func (s *ResourceTargetDefinition) SetRequiresRecreation(v string) *ResourceTarg // Rollback triggers enable you to have AWS CloudFormation monitor the state // of your application during stack creation and updating, and to roll back // that operation if the application breaches the threshold of any of the alarms -// you've specified. For each rollback trigger you create, you specify the Cloudwatch -// alarm that CloudFormation should monitor. CloudFormation monitors the specified -// alarms during the stack create or update operation, and for the specified -// amount of time after all resources have been deployed. If any of the alarms -// goes to ALERT state during the stack operation or the monitoring period, -// CloudFormation rolls back the entire stack operation. If the monitoring period -// expires without any alarms going to ALERT state, CloudFormation proceeds -// to dispose of old resources as usual. -// -// By default, CloudFormation only rolls back stack operations if an alarm goes -// to ALERT state, not INSUFFICIENT_DATA state. To have CloudFormation roll -// back the stack operation if an alarm goes to INSUFFICIENT_DATA state as well, -// edit the CloudWatch alarm to treat missing data as breaching. For more information, -// see Configuring How CloudWatch Alarms Treats Missing Data (http://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/AlarmThatSendsEmail.html). -// -// AWS CloudFormation does not monitor rollback triggers when it rolls back -// a stack during an update operation. +// you've specified. For more information, see Monitor and Roll Back Stack Operations +// (http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-rollback-triggers.html). type RollbackConfiguration struct { _ struct{} `type:"structure"` // The amount of time, in minutes, during which CloudFormation should monitor // all the rollback triggers after the stack creation or update operation deploys - // all necessary resources. If any of the alarms goes to ALERT state during - // the stack operation or this monitoring period, CloudFormation rolls back - // the entire stack operation. Then, for update operations, if the monitoring - // period expires without any alarms going to ALERT state CloudFormation proceeds - // to dispose of old resources as usual. + // all necessary resources. + // + // The default is 0 minutes. // // If you specify a monitoring period but do not specify any rollback triggers, // CloudFormation still waits the specified period of time before cleaning up - // old resources for update operations. You can use this monitoring period to - // perform any manual stack validation desired, and manually cancel the stack + // old resources after update operations. You can use this monitoring period + // to perform any manual stack validation desired, and manually cancel the stack // creation or update (using CancelUpdateStack (http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_CancelUpdateStack.html), // for example) as necessary. // @@ -8576,20 +8578,20 @@ type RollbackConfiguration struct { // parameter, those triggers replace any list of triggers previously specified // for the stack. This means: // - // * If you don't specify this parameter, AWS CloudFormation uses the rollback - // triggers previously specified for this stack, if any. + // * To use the rollback triggers previously specified for this stack, if + // any, don't specify this parameter. // - // * If you specify any rollback triggers using this parameter, you must - // specify all the triggers that you want used for this stack, even triggers - // you've specifed before (for example, when creating the stack or during - // a previous stack update). Any triggers that you don't include in the updated - // list of triggers are no longer applied to the stack. + // * To specify new or updated rollback triggers, you must specify all the + // triggers that you want used for this stack, even triggers you've specifed + // before (for example, when creating the stack or during a previous stack + // update). Any triggers that you don't include in the updated list of triggers + // are no longer applied to the stack. // - // * If you specify an empty list, AWS CloudFormation removes all currently - // specified triggers. + // * To remove all currently specified triggers, specify an empty list for + // this parameter. // - // If a specified Cloudwatch alarm is missing, the entire stack operation fails - // and is rolled back. + // If a specified trigger is missing, the entire stack operation fails and is + // rolled back. RollbackTriggers []*RollbackTrigger `type:"list"` } @@ -8636,7 +8638,7 @@ func (s *RollbackConfiguration) SetRollbackTriggers(v []*RollbackTrigger) *Rollb } // A rollback trigger AWS CloudFormation monitors during creation and updating -// of stacks. If any of the alarms you specify goes to ALERT state during the +// of stacks. If any of the alarms you specify goes to ALARM state during the // stack operation or within the specified monitoring period afterwards, CloudFormation // rolls back the entire stack operation. type RollbackTrigger struct { @@ -8644,6 +8646,9 @@ type RollbackTrigger struct { // The Amazon Resource Name (ARN) of the rollback trigger. // + // If a specified trigger is missing, the entire stack operation fails and is + // rolled back. + // // Arn is a required field Arn *string `type:"string" required:"true"` @@ -9755,6 +9760,15 @@ func (s *StackResourceSummary) SetResourceType(v string) *StackResourceSummary { type StackSet struct { _ struct{} `type:"structure"` + // The Amazon Resource Number (ARN) of the IAM role used to create or update + // the stack set. + // + // Use customized administrator roles to control which users or groups can manage + // specific stack sets within the same administrator account. For more information, + // see Define Permissions for Multiple Administrators (http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/stacksets-prereqs.html) + // in the AWS CloudFormation User Guide. + AdministrationRoleARN *string `min:"20" type:"string"` + // The capabilities that are allowed in the stack set. Some stack set templates // might include resources that can affect permissions in your AWS account—for // example, by creating new AWS Identity and Access Management (IAM) users. @@ -9769,6 +9783,9 @@ type StackSet struct { // A list of input parameters for a stack set. Parameters []*Parameter `type:"list"` + // The Amazon Resource Number (ARN) of the stack set. + StackSetARN *string `type:"string"` + // The ID of the stack set. StackSetId *string `type:"string"` @@ -9797,6 +9814,12 @@ func (s StackSet) GoString() string { return s.String() } +// SetAdministrationRoleARN sets the AdministrationRoleARN field's value. +func (s *StackSet) SetAdministrationRoleARN(v string) *StackSet { + s.AdministrationRoleARN = &v + return s +} + // SetCapabilities sets the Capabilities field's value. func (s *StackSet) SetCapabilities(v []*string) *StackSet { s.Capabilities = v @@ -9815,6 +9838,12 @@ func (s *StackSet) SetParameters(v []*Parameter) *StackSet { return s } +// SetStackSetARN sets the StackSetARN field's value. +func (s *StackSet) SetStackSetARN(v string) *StackSet { + s.StackSetARN = &v + return s +} + // SetStackSetId sets the StackSetId field's value. func (s *StackSet) SetStackSetId(v string) *StackSet { s.StackSetId = &v @@ -9855,6 +9884,15 @@ type StackSetOperation struct { // itself, as well as all associated stack set instances. Action *string `type:"string" enum:"StackSetOperationAction"` + // The Amazon Resource Number (ARN) of the IAM role used to perform this stack + // set operation. + // + // Use customized administrator roles to control which users or groups can manage + // specific stack sets within the same administrator account. For more information, + // see Define Permissions for Multiple Administrators (http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/stacksets-prereqs.html) + // in the AWS CloudFormation User Guide. + AdministrationRoleARN *string `min:"20" type:"string"` + // The time at which the operation was initiated. Note that the creation times // for the stack set operation might differ from the creation time of the individual // stacks themselves. This is because AWS CloudFormation needs to perform preparatory @@ -9920,6 +9958,12 @@ func (s *StackSetOperation) SetAction(v string) *StackSetOperation { return s } +// SetAdministrationRoleARN sets the AdministrationRoleARN field's value. +func (s *StackSetOperation) SetAdministrationRoleARN(v string) *StackSetOperation { + s.AdministrationRoleARN = &v + return s +} + // SetCreationTimestamp sets the CreationTimestamp field's value. func (s *StackSetOperation) SetCreationTimestamp(v time.Time) *StackSetOperation { s.CreationTimestamp = &v @@ -11124,6 +11168,22 @@ func (s *UpdateStackOutput) SetStackId(v string) *UpdateStackOutput { type UpdateStackSetInput struct { _ struct{} `type:"structure"` + // The Amazon Resource Number (ARN) of the IAM role to use to update this stack + // set. + // + // Specify an IAM role only if you are using customized administrator roles + // to control which users or groups can manage specific stack sets within the + // same administrator account. For more information, see Define Permissions + // for Multiple Administrators (http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/stacksets-prereqs.html) + // in the AWS CloudFormation User Guide. + // + // If you specify a customized administrator role, AWS CloudFormation uses that + // role to update the stack. If you do not specify a customized administrator + // role, AWS CloudFormation performs the update using the role previously associated + // with the stack set, so long as you have permissions to perform operations + // on the stack set. + AdministrationRoleARN *string `min:"20" type:"string"` + // A list of values that you must specify before AWS CloudFormation can create // certain stack sets. Some stack set templates might include resources that // can affect permissions in your AWS account—for example, by creating new AWS @@ -11255,6 +11315,9 @@ func (s UpdateStackSetInput) GoString() string { // Validate inspects the fields of the type to determine if they are valid. func (s *UpdateStackSetInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "UpdateStackSetInput"} + if s.AdministrationRoleARN != nil && len(*s.AdministrationRoleARN) < 20 { + invalidParams.Add(request.NewErrParamMinLen("AdministrationRoleARN", 20)) + } if s.Description != nil && len(*s.Description) < 1 { invalidParams.Add(request.NewErrParamMinLen("Description", 1)) } @@ -11292,6 +11355,12 @@ func (s *UpdateStackSetInput) Validate() error { return nil } +// SetAdministrationRoleARN sets the AdministrationRoleARN field's value. +func (s *UpdateStackSetInput) SetAdministrationRoleARN(v string) *UpdateStackSetInput { + s.AdministrationRoleARN = &v + return s +} + // SetCapabilities sets the Capabilities field's value. func (s *UpdateStackSetInput) SetCapabilities(v []*string) *UpdateStackSetInput { s.Capabilities = v diff --git a/vendor/github.com/aws/aws-sdk-go/service/cloudfront/api.go b/vendor/github.com/aws/aws-sdk-go/service/cloudfront/api.go index e7749972f54c..afc3cf2eaa4b 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/cloudfront/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/cloudfront/api.go @@ -13,11 +13,11 @@ import ( "github.com/aws/aws-sdk-go/private/protocol/restxml" ) -const opCreateCloudFrontOriginAccessIdentity = "CreateCloudFrontOriginAccessIdentity2017_03_25" +const opCreateCloudFrontOriginAccessIdentity = "CreateCloudFrontOriginAccessIdentity2017_10_30" // CreateCloudFrontOriginAccessIdentityRequest generates a "aws/request.Request" representing the // client's request for the CreateCloudFrontOriginAccessIdentity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -38,12 +38,12 @@ const opCreateCloudFrontOriginAccessIdentity = "CreateCloudFrontOriginAccessIden // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/CreateCloudFrontOriginAccessIdentity +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreateCloudFrontOriginAccessIdentity func (c *CloudFront) CreateCloudFrontOriginAccessIdentityRequest(input *CreateCloudFrontOriginAccessIdentityInput) (req *request.Request, output *CreateCloudFrontOriginAccessIdentityOutput) { op := &request.Operation{ Name: opCreateCloudFrontOriginAccessIdentity, HTTPMethod: "POST", - HTTPPath: "/2017-03-25/origin-access-identity/cloudfront", + HTTPPath: "/2017-10-30/origin-access-identity/cloudfront", } if input == nil { @@ -92,7 +92,7 @@ func (c *CloudFront) CreateCloudFrontOriginAccessIdentityRequest(input *CreateCl // * ErrCodeInconsistentQuantities "InconsistentQuantities" // The value of Quantity and the size of Items don't match. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/CreateCloudFrontOriginAccessIdentity +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreateCloudFrontOriginAccessIdentity func (c *CloudFront) CreateCloudFrontOriginAccessIdentity(input *CreateCloudFrontOriginAccessIdentityInput) (*CreateCloudFrontOriginAccessIdentityOutput, error) { req, out := c.CreateCloudFrontOriginAccessIdentityRequest(input) return out, req.Send() @@ -114,11 +114,11 @@ func (c *CloudFront) CreateCloudFrontOriginAccessIdentityWithContext(ctx aws.Con return out, req.Send() } -const opCreateDistribution = "CreateDistribution2017_03_25" +const opCreateDistribution = "CreateDistribution2017_10_30" // CreateDistributionRequest generates a "aws/request.Request" representing the // client's request for the CreateDistribution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -139,12 +139,12 @@ const opCreateDistribution = "CreateDistribution2017_03_25" // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/CreateDistribution +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreateDistribution func (c *CloudFront) CreateDistributionRequest(input *CreateDistributionInput) (req *request.Request, output *CreateDistributionOutput) { op := &request.Operation{ Name: opCreateDistribution, HTTPMethod: "POST", - HTTPPath: "/2017-03-25/distribution", + HTTPPath: "/2017-10-30/distribution", } if input == nil { @@ -287,7 +287,18 @@ func (c *CloudFront) CreateDistributionRequest(input *CreateDistributionInput) ( // // * ErrCodeInvalidOriginKeepaliveTimeout "InvalidOriginKeepaliveTimeout" // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/CreateDistribution +// * ErrCodeNoSuchFieldLevelEncryptionConfig "NoSuchFieldLevelEncryptionConfig" +// The specified configuration for field-level encryption doesn't exist. +// +// * ErrCodeIllegalFieldLevelEncryptionConfigAssociationWithCacheBehavior "IllegalFieldLevelEncryptionConfigAssociationWithCacheBehavior" +// The specified configuration for field-level encryption can't be associated +// with the specified cache behavior. +// +// * ErrCodeTooManyDistributionsAssociatedToFieldLevelEncryptionConfig "TooManyDistributionsAssociatedToFieldLevelEncryptionConfig" +// The maximum number of distributions have been associated with the specified +// configuration for field-level encryption. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreateDistribution func (c *CloudFront) CreateDistribution(input *CreateDistributionInput) (*CreateDistributionOutput, error) { req, out := c.CreateDistributionRequest(input) return out, req.Send() @@ -309,11 +320,11 @@ func (c *CloudFront) CreateDistributionWithContext(ctx aws.Context, input *Creat return out, req.Send() } -const opCreateDistributionWithTags = "CreateDistributionWithTags2017_03_25" +const opCreateDistributionWithTags = "CreateDistributionWithTags2017_10_30" // CreateDistributionWithTagsRequest generates a "aws/request.Request" representing the // client's request for the CreateDistributionWithTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -334,12 +345,12 @@ const opCreateDistributionWithTags = "CreateDistributionWithTags2017_03_25" // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/CreateDistributionWithTags +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreateDistributionWithTags func (c *CloudFront) CreateDistributionWithTagsRequest(input *CreateDistributionWithTagsInput) (req *request.Request, output *CreateDistributionWithTagsOutput) { op := &request.Operation{ Name: opCreateDistributionWithTags, HTTPMethod: "POST", - HTTPPath: "/2017-03-25/distribution?WithTags", + HTTPPath: "/2017-10-30/distribution?WithTags", } if input == nil { @@ -483,7 +494,18 @@ func (c *CloudFront) CreateDistributionWithTagsRequest(input *CreateDistribution // // * ErrCodeInvalidOriginKeepaliveTimeout "InvalidOriginKeepaliveTimeout" // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/CreateDistributionWithTags +// * ErrCodeNoSuchFieldLevelEncryptionConfig "NoSuchFieldLevelEncryptionConfig" +// The specified configuration for field-level encryption doesn't exist. +// +// * ErrCodeIllegalFieldLevelEncryptionConfigAssociationWithCacheBehavior "IllegalFieldLevelEncryptionConfigAssociationWithCacheBehavior" +// The specified configuration for field-level encryption can't be associated +// with the specified cache behavior. +// +// * ErrCodeTooManyDistributionsAssociatedToFieldLevelEncryptionConfig "TooManyDistributionsAssociatedToFieldLevelEncryptionConfig" +// The maximum number of distributions have been associated with the specified +// configuration for field-level encryption. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreateDistributionWithTags func (c *CloudFront) CreateDistributionWithTags(input *CreateDistributionWithTagsInput) (*CreateDistributionWithTagsOutput, error) { req, out := c.CreateDistributionWithTagsRequest(input) return out, req.Send() @@ -505,11 +527,216 @@ func (c *CloudFront) CreateDistributionWithTagsWithContext(ctx aws.Context, inpu return out, req.Send() } -const opCreateInvalidation = "CreateInvalidation2017_03_25" +const opCreateFieldLevelEncryptionConfig = "CreateFieldLevelEncryptionConfig2017_10_30" + +// CreateFieldLevelEncryptionConfigRequest generates a "aws/request.Request" representing the +// client's request for the CreateFieldLevelEncryptionConfig operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See CreateFieldLevelEncryptionConfig for more information on using the CreateFieldLevelEncryptionConfig +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the CreateFieldLevelEncryptionConfigRequest method. +// req, resp := client.CreateFieldLevelEncryptionConfigRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreateFieldLevelEncryptionConfig +func (c *CloudFront) CreateFieldLevelEncryptionConfigRequest(input *CreateFieldLevelEncryptionConfigInput) (req *request.Request, output *CreateFieldLevelEncryptionConfigOutput) { + op := &request.Operation{ + Name: opCreateFieldLevelEncryptionConfig, + HTTPMethod: "POST", + HTTPPath: "/2017-10-30/field-level-encryption", + } + + if input == nil { + input = &CreateFieldLevelEncryptionConfigInput{} + } + + output = &CreateFieldLevelEncryptionConfigOutput{} + req = c.newRequest(op, input, output) + return +} + +// CreateFieldLevelEncryptionConfig API operation for Amazon CloudFront. +// +// Create a new field-level encryption configuration. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon CloudFront's +// API operation CreateFieldLevelEncryptionConfig for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInconsistentQuantities "InconsistentQuantities" +// The value of Quantity and the size of Items don't match. +// +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. +// +// * ErrCodeNoSuchFieldLevelEncryptionProfile "NoSuchFieldLevelEncryptionProfile" +// The specified profile for field-level encryption doesn't exist. +// +// * ErrCodeFieldLevelEncryptionConfigAlreadyExists "FieldLevelEncryptionConfigAlreadyExists" +// The specified configuration for field-level encryption already exists. +// +// * ErrCodeTooManyFieldLevelEncryptionConfigs "TooManyFieldLevelEncryptionConfigs" +// The maximum number of configurations for field-level encryption have been +// created. +// +// * ErrCodeTooManyFieldLevelEncryptionQueryArgProfiles "TooManyFieldLevelEncryptionQueryArgProfiles" +// The maximum number of query arg profiles for field-level encryption have +// been created. +// +// * ErrCodeTooManyFieldLevelEncryptionContentTypeProfiles "TooManyFieldLevelEncryptionContentTypeProfiles" +// The maximum number of content type profiles for field-level encryption have +// been created. +// +// * ErrCodeQueryArgProfileEmpty "QueryArgProfileEmpty" +// No profile specified for the field-level encryption query argument. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreateFieldLevelEncryptionConfig +func (c *CloudFront) CreateFieldLevelEncryptionConfig(input *CreateFieldLevelEncryptionConfigInput) (*CreateFieldLevelEncryptionConfigOutput, error) { + req, out := c.CreateFieldLevelEncryptionConfigRequest(input) + return out, req.Send() +} + +// CreateFieldLevelEncryptionConfigWithContext is the same as CreateFieldLevelEncryptionConfig with the addition of +// the ability to pass a context and additional request options. +// +// See CreateFieldLevelEncryptionConfig for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) CreateFieldLevelEncryptionConfigWithContext(ctx aws.Context, input *CreateFieldLevelEncryptionConfigInput, opts ...request.Option) (*CreateFieldLevelEncryptionConfigOutput, error) { + req, out := c.CreateFieldLevelEncryptionConfigRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opCreateFieldLevelEncryptionProfile = "CreateFieldLevelEncryptionProfile2017_10_30" + +// CreateFieldLevelEncryptionProfileRequest generates a "aws/request.Request" representing the +// client's request for the CreateFieldLevelEncryptionProfile operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See CreateFieldLevelEncryptionProfile for more information on using the CreateFieldLevelEncryptionProfile +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the CreateFieldLevelEncryptionProfileRequest method. +// req, resp := client.CreateFieldLevelEncryptionProfileRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreateFieldLevelEncryptionProfile +func (c *CloudFront) CreateFieldLevelEncryptionProfileRequest(input *CreateFieldLevelEncryptionProfileInput) (req *request.Request, output *CreateFieldLevelEncryptionProfileOutput) { + op := &request.Operation{ + Name: opCreateFieldLevelEncryptionProfile, + HTTPMethod: "POST", + HTTPPath: "/2017-10-30/field-level-encryption-profile", + } + + if input == nil { + input = &CreateFieldLevelEncryptionProfileInput{} + } + + output = &CreateFieldLevelEncryptionProfileOutput{} + req = c.newRequest(op, input, output) + return +} + +// CreateFieldLevelEncryptionProfile API operation for Amazon CloudFront. +// +// Create a field-level encryption profile. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon CloudFront's +// API operation CreateFieldLevelEncryptionProfile for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInconsistentQuantities "InconsistentQuantities" +// The value of Quantity and the size of Items don't match. +// +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. +// +// * ErrCodeNoSuchPublicKey "NoSuchPublicKey" +// The specified public key doesn't exist. +// +// * ErrCodeFieldLevelEncryptionProfileAlreadyExists "FieldLevelEncryptionProfileAlreadyExists" +// The specified profile for field-level encryption already exists. +// +// * ErrCodeFieldLevelEncryptionProfileSizeExceeded "FieldLevelEncryptionProfileSizeExceeded" +// The maximum size of a profile for field-level encryption was exceeded. +// +// * ErrCodeTooManyFieldLevelEncryptionProfiles "TooManyFieldLevelEncryptionProfiles" +// The maximum number of profiles for field-level encryption have been created. +// +// * ErrCodeTooManyFieldLevelEncryptionEncryptionEntities "TooManyFieldLevelEncryptionEncryptionEntities" +// The maximum number of encryption entities for field-level encryption have +// been created. +// +// * ErrCodeTooManyFieldLevelEncryptionFieldPatterns "TooManyFieldLevelEncryptionFieldPatterns" +// The maximum number of field patterns for field-level encryption have been +// created. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreateFieldLevelEncryptionProfile +func (c *CloudFront) CreateFieldLevelEncryptionProfile(input *CreateFieldLevelEncryptionProfileInput) (*CreateFieldLevelEncryptionProfileOutput, error) { + req, out := c.CreateFieldLevelEncryptionProfileRequest(input) + return out, req.Send() +} + +// CreateFieldLevelEncryptionProfileWithContext is the same as CreateFieldLevelEncryptionProfile with the addition of +// the ability to pass a context and additional request options. +// +// See CreateFieldLevelEncryptionProfile for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) CreateFieldLevelEncryptionProfileWithContext(ctx aws.Context, input *CreateFieldLevelEncryptionProfileInput, opts ...request.Option) (*CreateFieldLevelEncryptionProfileOutput, error) { + req, out := c.CreateFieldLevelEncryptionProfileRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opCreateInvalidation = "CreateInvalidation2017_10_30" // CreateInvalidationRequest generates a "aws/request.Request" representing the // client's request for the CreateInvalidation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -530,12 +757,12 @@ const opCreateInvalidation = "CreateInvalidation2017_03_25" // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/CreateInvalidation +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreateInvalidation func (c *CloudFront) CreateInvalidationRequest(input *CreateInvalidationInput) (req *request.Request, output *CreateInvalidationOutput) { op := &request.Operation{ Name: opCreateInvalidation, HTTPMethod: "POST", - HTTPPath: "/2017-03-25/distribution/{DistributionId}/invalidation", + HTTPPath: "/2017-10-30/distribution/{DistributionId}/invalidation", } if input == nil { @@ -581,7 +808,7 @@ func (c *CloudFront) CreateInvalidationRequest(input *CreateInvalidationInput) ( // * ErrCodeInconsistentQuantities "InconsistentQuantities" // The value of Quantity and the size of Items don't match. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/CreateInvalidation +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreateInvalidation func (c *CloudFront) CreateInvalidation(input *CreateInvalidationInput) (*CreateInvalidationOutput, error) { req, out := c.CreateInvalidationRequest(input) return out, req.Send() @@ -603,11 +830,98 @@ func (c *CloudFront) CreateInvalidationWithContext(ctx aws.Context, input *Creat return out, req.Send() } -const opCreateStreamingDistribution = "CreateStreamingDistribution2017_03_25" +const opCreatePublicKey = "CreatePublicKey2017_10_30" + +// CreatePublicKeyRequest generates a "aws/request.Request" representing the +// client's request for the CreatePublicKey operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See CreatePublicKey for more information on using the CreatePublicKey +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the CreatePublicKeyRequest method. +// req, resp := client.CreatePublicKeyRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreatePublicKey +func (c *CloudFront) CreatePublicKeyRequest(input *CreatePublicKeyInput) (req *request.Request, output *CreatePublicKeyOutput) { + op := &request.Operation{ + Name: opCreatePublicKey, + HTTPMethod: "POST", + HTTPPath: "/2017-10-30/public-key", + } + + if input == nil { + input = &CreatePublicKeyInput{} + } + + output = &CreatePublicKeyOutput{} + req = c.newRequest(op, input, output) + return +} + +// CreatePublicKey API operation for Amazon CloudFront. +// +// Add a new public key to CloudFront to use, for example, for field-level encryption. +// You can add a maximum of 10 public keys with one AWS account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon CloudFront's +// API operation CreatePublicKey for usage and error information. +// +// Returned Error Codes: +// * ErrCodePublicKeyAlreadyExists "PublicKeyAlreadyExists" +// The specified public key already exists. +// +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. +// +// * ErrCodeTooManyPublicKeys "TooManyPublicKeys" +// The maximum number of public keys for field-level encryption have been created. +// To create a new public key, delete one of the existing keys. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreatePublicKey +func (c *CloudFront) CreatePublicKey(input *CreatePublicKeyInput) (*CreatePublicKeyOutput, error) { + req, out := c.CreatePublicKeyRequest(input) + return out, req.Send() +} + +// CreatePublicKeyWithContext is the same as CreatePublicKey with the addition of +// the ability to pass a context and additional request options. +// +// See CreatePublicKey for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) CreatePublicKeyWithContext(ctx aws.Context, input *CreatePublicKeyInput, opts ...request.Option) (*CreatePublicKeyOutput, error) { + req, out := c.CreatePublicKeyRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opCreateStreamingDistribution = "CreateStreamingDistribution2017_10_30" // CreateStreamingDistributionRequest generates a "aws/request.Request" representing the // client's request for the CreateStreamingDistribution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -628,12 +942,12 @@ const opCreateStreamingDistribution = "CreateStreamingDistribution2017_03_25" // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/CreateStreamingDistribution +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreateStreamingDistribution func (c *CloudFront) CreateStreamingDistributionRequest(input *CreateStreamingDistributionInput) (req *request.Request, output *CreateStreamingDistributionOutput) { op := &request.Operation{ Name: opCreateStreamingDistribution, HTTPMethod: "POST", - HTTPPath: "/2017-03-25/streaming-distribution", + HTTPPath: "/2017-10-30/streaming-distribution", } if input == nil { @@ -720,7 +1034,7 @@ func (c *CloudFront) CreateStreamingDistributionRequest(input *CreateStreamingDi // * ErrCodeInconsistentQuantities "InconsistentQuantities" // The value of Quantity and the size of Items don't match. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/CreateStreamingDistribution +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreateStreamingDistribution func (c *CloudFront) CreateStreamingDistribution(input *CreateStreamingDistributionInput) (*CreateStreamingDistributionOutput, error) { req, out := c.CreateStreamingDistributionRequest(input) return out, req.Send() @@ -742,11 +1056,11 @@ func (c *CloudFront) CreateStreamingDistributionWithContext(ctx aws.Context, inp return out, req.Send() } -const opCreateStreamingDistributionWithTags = "CreateStreamingDistributionWithTags2017_03_25" +const opCreateStreamingDistributionWithTags = "CreateStreamingDistributionWithTags2017_10_30" // CreateStreamingDistributionWithTagsRequest generates a "aws/request.Request" representing the // client's request for the CreateStreamingDistributionWithTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -767,12 +1081,12 @@ const opCreateStreamingDistributionWithTags = "CreateStreamingDistributionWithTa // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/CreateStreamingDistributionWithTags +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreateStreamingDistributionWithTags func (c *CloudFront) CreateStreamingDistributionWithTagsRequest(input *CreateStreamingDistributionWithTagsInput) (req *request.Request, output *CreateStreamingDistributionWithTagsOutput) { op := &request.Operation{ Name: opCreateStreamingDistributionWithTags, HTTPMethod: "POST", - HTTPPath: "/2017-03-25/streaming-distribution?WithTags", + HTTPPath: "/2017-10-30/streaming-distribution?WithTags", } if input == nil { @@ -834,7 +1148,7 @@ func (c *CloudFront) CreateStreamingDistributionWithTagsRequest(input *CreateStr // // * ErrCodeInvalidTagging "InvalidTagging" // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/CreateStreamingDistributionWithTags +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/CreateStreamingDistributionWithTags func (c *CloudFront) CreateStreamingDistributionWithTags(input *CreateStreamingDistributionWithTagsInput) (*CreateStreamingDistributionWithTagsOutput, error) { req, out := c.CreateStreamingDistributionWithTagsRequest(input) return out, req.Send() @@ -856,11 +1170,11 @@ func (c *CloudFront) CreateStreamingDistributionWithTagsWithContext(ctx aws.Cont return out, req.Send() } -const opDeleteCloudFrontOriginAccessIdentity = "DeleteCloudFrontOriginAccessIdentity2017_03_25" +const opDeleteCloudFrontOriginAccessIdentity = "DeleteCloudFrontOriginAccessIdentity2017_10_30" // DeleteCloudFrontOriginAccessIdentityRequest generates a "aws/request.Request" representing the // client's request for the DeleteCloudFrontOriginAccessIdentity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -881,12 +1195,12 @@ const opDeleteCloudFrontOriginAccessIdentity = "DeleteCloudFrontOriginAccessIden // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/DeleteCloudFrontOriginAccessIdentity +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/DeleteCloudFrontOriginAccessIdentity func (c *CloudFront) DeleteCloudFrontOriginAccessIdentityRequest(input *DeleteCloudFrontOriginAccessIdentityInput) (req *request.Request, output *DeleteCloudFrontOriginAccessIdentityOutput) { op := &request.Operation{ Name: opDeleteCloudFrontOriginAccessIdentity, HTTPMethod: "DELETE", - HTTPPath: "/2017-03-25/origin-access-identity/cloudfront/{Id}", + HTTPPath: "/2017-10-30/origin-access-identity/cloudfront/{Id}", } if input == nil { @@ -927,7 +1241,7 @@ func (c *CloudFront) DeleteCloudFrontOriginAccessIdentityRequest(input *DeleteCl // // * ErrCodeOriginAccessIdentityInUse "OriginAccessIdentityInUse" // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/DeleteCloudFrontOriginAccessIdentity +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/DeleteCloudFrontOriginAccessIdentity func (c *CloudFront) DeleteCloudFrontOriginAccessIdentity(input *DeleteCloudFrontOriginAccessIdentityInput) (*DeleteCloudFrontOriginAccessIdentityOutput, error) { req, out := c.DeleteCloudFrontOriginAccessIdentityRequest(input) return out, req.Send() @@ -949,11 +1263,11 @@ func (c *CloudFront) DeleteCloudFrontOriginAccessIdentityWithContext(ctx aws.Con return out, req.Send() } -const opDeleteDistribution = "DeleteDistribution2017_03_25" +const opDeleteDistribution = "DeleteDistribution2017_10_30" // DeleteDistributionRequest generates a "aws/request.Request" representing the // client's request for the DeleteDistribution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -974,12 +1288,12 @@ const opDeleteDistribution = "DeleteDistribution2017_03_25" // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/DeleteDistribution +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/DeleteDistribution func (c *CloudFront) DeleteDistributionRequest(input *DeleteDistributionInput) (req *request.Request, output *DeleteDistributionOutput) { op := &request.Operation{ Name: opDeleteDistribution, HTTPMethod: "DELETE", - HTTPPath: "/2017-03-25/distribution/{Id}", + HTTPPath: "/2017-10-30/distribution/{Id}", } if input == nil { @@ -1020,7 +1334,7 @@ func (c *CloudFront) DeleteDistributionRequest(input *DeleteDistributionInput) ( // The precondition given in one or more of the request-header fields evaluated // to false. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/DeleteDistribution +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/DeleteDistribution func (c *CloudFront) DeleteDistribution(input *DeleteDistributionInput) (*DeleteDistributionOutput, error) { req, out := c.DeleteDistributionRequest(input) return out, req.Send() @@ -1042,156 +1356,438 @@ func (c *CloudFront) DeleteDistributionWithContext(ctx aws.Context, input *Delet return out, req.Send() } -const opDeleteServiceLinkedRole = "DeleteServiceLinkedRole2017_03_25" +const opDeleteFieldLevelEncryptionConfig = "DeleteFieldLevelEncryptionConfig2017_10_30" -// DeleteServiceLinkedRoleRequest generates a "aws/request.Request" representing the -// client's request for the DeleteServiceLinkedRole operation. The "output" return -// value will be populated with the request's response once the request complets +// DeleteFieldLevelEncryptionConfigRequest generates a "aws/request.Request" representing the +// client's request for the DeleteFieldLevelEncryptionConfig operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See DeleteServiceLinkedRole for more information on using the DeleteServiceLinkedRole +// See DeleteFieldLevelEncryptionConfig for more information on using the DeleteFieldLevelEncryptionConfig // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the DeleteServiceLinkedRoleRequest method. -// req, resp := client.DeleteServiceLinkedRoleRequest(params) +// // Example sending a request using the DeleteFieldLevelEncryptionConfigRequest method. +// req, resp := client.DeleteFieldLevelEncryptionConfigRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/DeleteServiceLinkedRole -func (c *CloudFront) DeleteServiceLinkedRoleRequest(input *DeleteServiceLinkedRoleInput) (req *request.Request, output *DeleteServiceLinkedRoleOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/DeleteFieldLevelEncryptionConfig +func (c *CloudFront) DeleteFieldLevelEncryptionConfigRequest(input *DeleteFieldLevelEncryptionConfigInput) (req *request.Request, output *DeleteFieldLevelEncryptionConfigOutput) { op := &request.Operation{ - Name: opDeleteServiceLinkedRole, + Name: opDeleteFieldLevelEncryptionConfig, HTTPMethod: "DELETE", - HTTPPath: "/2017-03-25/service-linked-role/{RoleName}", + HTTPPath: "/2017-10-30/field-level-encryption/{Id}", } if input == nil { - input = &DeleteServiceLinkedRoleInput{} + input = &DeleteFieldLevelEncryptionConfigInput{} } - output = &DeleteServiceLinkedRoleOutput{} + output = &DeleteFieldLevelEncryptionConfigOutput{} req = c.newRequest(op, input, output) req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler) req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } -// DeleteServiceLinkedRole API operation for Amazon CloudFront. +// DeleteFieldLevelEncryptionConfig API operation for Amazon CloudFront. +// +// Remove a field-level encryption configuration. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Amazon CloudFront's -// API operation DeleteServiceLinkedRole for usage and error information. +// API operation DeleteFieldLevelEncryptionConfig for usage and error information. // // Returned Error Codes: -// * ErrCodeInvalidArgument "InvalidArgument" -// The argument is invalid. -// // * ErrCodeAccessDenied "AccessDenied" // Access denied. // -// * ErrCodeResourceInUse "ResourceInUse" +// * ErrCodeInvalidIfMatchVersion "InvalidIfMatchVersion" +// The If-Match version is missing or not valid for the distribution. // -// * ErrCodeNoSuchResource "NoSuchResource" +// * ErrCodeNoSuchFieldLevelEncryptionConfig "NoSuchFieldLevelEncryptionConfig" +// The specified configuration for field-level encryption doesn't exist. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/DeleteServiceLinkedRole -func (c *CloudFront) DeleteServiceLinkedRole(input *DeleteServiceLinkedRoleInput) (*DeleteServiceLinkedRoleOutput, error) { - req, out := c.DeleteServiceLinkedRoleRequest(input) +// * ErrCodePreconditionFailed "PreconditionFailed" +// The precondition given in one or more of the request-header fields evaluated +// to false. +// +// * ErrCodeFieldLevelEncryptionConfigInUse "FieldLevelEncryptionConfigInUse" +// The specified configuration for field-level encryption is in use. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/DeleteFieldLevelEncryptionConfig +func (c *CloudFront) DeleteFieldLevelEncryptionConfig(input *DeleteFieldLevelEncryptionConfigInput) (*DeleteFieldLevelEncryptionConfigOutput, error) { + req, out := c.DeleteFieldLevelEncryptionConfigRequest(input) return out, req.Send() } -// DeleteServiceLinkedRoleWithContext is the same as DeleteServiceLinkedRole with the addition of +// DeleteFieldLevelEncryptionConfigWithContext is the same as DeleteFieldLevelEncryptionConfig with the addition of // the ability to pass a context and additional request options. // -// See DeleteServiceLinkedRole for details on how to use this API operation. +// See DeleteFieldLevelEncryptionConfig for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CloudFront) DeleteServiceLinkedRoleWithContext(ctx aws.Context, input *DeleteServiceLinkedRoleInput, opts ...request.Option) (*DeleteServiceLinkedRoleOutput, error) { - req, out := c.DeleteServiceLinkedRoleRequest(input) +func (c *CloudFront) DeleteFieldLevelEncryptionConfigWithContext(ctx aws.Context, input *DeleteFieldLevelEncryptionConfigInput, opts ...request.Option) (*DeleteFieldLevelEncryptionConfigOutput, error) { + req, out := c.DeleteFieldLevelEncryptionConfigRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opDeleteStreamingDistribution = "DeleteStreamingDistribution2017_03_25" +const opDeleteFieldLevelEncryptionProfile = "DeleteFieldLevelEncryptionProfile2017_10_30" -// DeleteStreamingDistributionRequest generates a "aws/request.Request" representing the -// client's request for the DeleteStreamingDistribution operation. The "output" return -// value will be populated with the request's response once the request complets +// DeleteFieldLevelEncryptionProfileRequest generates a "aws/request.Request" representing the +// client's request for the DeleteFieldLevelEncryptionProfile operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See DeleteStreamingDistribution for more information on using the DeleteStreamingDistribution +// See DeleteFieldLevelEncryptionProfile for more information on using the DeleteFieldLevelEncryptionProfile // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the DeleteStreamingDistributionRequest method. -// req, resp := client.DeleteStreamingDistributionRequest(params) +// // Example sending a request using the DeleteFieldLevelEncryptionProfileRequest method. +// req, resp := client.DeleteFieldLevelEncryptionProfileRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/DeleteStreamingDistribution -func (c *CloudFront) DeleteStreamingDistributionRequest(input *DeleteStreamingDistributionInput) (req *request.Request, output *DeleteStreamingDistributionOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/DeleteFieldLevelEncryptionProfile +func (c *CloudFront) DeleteFieldLevelEncryptionProfileRequest(input *DeleteFieldLevelEncryptionProfileInput) (req *request.Request, output *DeleteFieldLevelEncryptionProfileOutput) { op := &request.Operation{ - Name: opDeleteStreamingDistribution, + Name: opDeleteFieldLevelEncryptionProfile, HTTPMethod: "DELETE", - HTTPPath: "/2017-03-25/streaming-distribution/{Id}", + HTTPPath: "/2017-10-30/field-level-encryption-profile/{Id}", } if input == nil { - input = &DeleteStreamingDistributionInput{} + input = &DeleteFieldLevelEncryptionProfileInput{} } - output = &DeleteStreamingDistributionOutput{} + output = &DeleteFieldLevelEncryptionProfileOutput{} req = c.newRequest(op, input, output) req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler) req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } -// DeleteStreamingDistribution API operation for Amazon CloudFront. +// DeleteFieldLevelEncryptionProfile API operation for Amazon CloudFront. // -// Delete a streaming distribution. To delete an RTMP distribution using the -// CloudFront API, perform the following steps. +// Remove a field-level encryption profile. // -// To delete an RTMP distribution using the CloudFront API: +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. // -// Disable the RTMP distribution. +// See the AWS API reference guide for Amazon CloudFront's +// API operation DeleteFieldLevelEncryptionProfile for usage and error information. // -// Submit a GET Streaming Distribution Config request to get the current configuration -// and the Etag header for the distribution. +// Returned Error Codes: +// * ErrCodeAccessDenied "AccessDenied" +// Access denied. // -// Update the XML document that was returned in the response to your GET Streaming -// Distribution Config request to change the value of Enabled to false. +// * ErrCodeInvalidIfMatchVersion "InvalidIfMatchVersion" +// The If-Match version is missing or not valid for the distribution. // -// Submit a PUT Streaming Distribution Config request to update the configuration -// for your distribution. In the request body, include the XML document that -// you updated in Step 3. Then set the value of the HTTP If-Match header to -// the value of the ETag header that CloudFront returned when you submitted -// the GET Streaming Distribution Config request in Step 2. +// * ErrCodeNoSuchFieldLevelEncryptionProfile "NoSuchFieldLevelEncryptionProfile" +// The specified profile for field-level encryption doesn't exist. +// +// * ErrCodePreconditionFailed "PreconditionFailed" +// The precondition given in one or more of the request-header fields evaluated +// to false. +// +// * ErrCodeFieldLevelEncryptionProfileInUse "FieldLevelEncryptionProfileInUse" +// The specified profile for field-level encryption is in use. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/DeleteFieldLevelEncryptionProfile +func (c *CloudFront) DeleteFieldLevelEncryptionProfile(input *DeleteFieldLevelEncryptionProfileInput) (*DeleteFieldLevelEncryptionProfileOutput, error) { + req, out := c.DeleteFieldLevelEncryptionProfileRequest(input) + return out, req.Send() +} + +// DeleteFieldLevelEncryptionProfileWithContext is the same as DeleteFieldLevelEncryptionProfile with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteFieldLevelEncryptionProfile for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) DeleteFieldLevelEncryptionProfileWithContext(ctx aws.Context, input *DeleteFieldLevelEncryptionProfileInput, opts ...request.Option) (*DeleteFieldLevelEncryptionProfileOutput, error) { + req, out := c.DeleteFieldLevelEncryptionProfileRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeletePublicKey = "DeletePublicKey2017_10_30" + +// DeletePublicKeyRequest generates a "aws/request.Request" representing the +// client's request for the DeletePublicKey operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeletePublicKey for more information on using the DeletePublicKey +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeletePublicKeyRequest method. +// req, resp := client.DeletePublicKeyRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/DeletePublicKey +func (c *CloudFront) DeletePublicKeyRequest(input *DeletePublicKeyInput) (req *request.Request, output *DeletePublicKeyOutput) { + op := &request.Operation{ + Name: opDeletePublicKey, + HTTPMethod: "DELETE", + HTTPPath: "/2017-10-30/public-key/{Id}", + } + + if input == nil { + input = &DeletePublicKeyInput{} + } + + output = &DeletePublicKeyOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeletePublicKey API operation for Amazon CloudFront. +// +// Remove a public key you previously added to CloudFront. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon CloudFront's +// API operation DeletePublicKey for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDenied "AccessDenied" +// Access denied. +// +// * ErrCodePublicKeyInUse "PublicKeyInUse" +// The specified public key is in use. +// +// * ErrCodeInvalidIfMatchVersion "InvalidIfMatchVersion" +// The If-Match version is missing or not valid for the distribution. +// +// * ErrCodeNoSuchPublicKey "NoSuchPublicKey" +// The specified public key doesn't exist. +// +// * ErrCodePreconditionFailed "PreconditionFailed" +// The precondition given in one or more of the request-header fields evaluated +// to false. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/DeletePublicKey +func (c *CloudFront) DeletePublicKey(input *DeletePublicKeyInput) (*DeletePublicKeyOutput, error) { + req, out := c.DeletePublicKeyRequest(input) + return out, req.Send() +} + +// DeletePublicKeyWithContext is the same as DeletePublicKey with the addition of +// the ability to pass a context and additional request options. +// +// See DeletePublicKey for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) DeletePublicKeyWithContext(ctx aws.Context, input *DeletePublicKeyInput, opts ...request.Option) (*DeletePublicKeyOutput, error) { + req, out := c.DeletePublicKeyRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeleteServiceLinkedRole = "DeleteServiceLinkedRole2017_10_30" + +// DeleteServiceLinkedRoleRequest generates a "aws/request.Request" representing the +// client's request for the DeleteServiceLinkedRole operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteServiceLinkedRole for more information on using the DeleteServiceLinkedRole +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteServiceLinkedRoleRequest method. +// req, resp := client.DeleteServiceLinkedRoleRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/DeleteServiceLinkedRole +func (c *CloudFront) DeleteServiceLinkedRoleRequest(input *DeleteServiceLinkedRoleInput) (req *request.Request, output *DeleteServiceLinkedRoleOutput) { + op := &request.Operation{ + Name: opDeleteServiceLinkedRole, + HTTPMethod: "DELETE", + HTTPPath: "/2017-10-30/service-linked-role/{RoleName}", + } + + if input == nil { + input = &DeleteServiceLinkedRoleInput{} + } + + output = &DeleteServiceLinkedRoleOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeleteServiceLinkedRole API operation for Amazon CloudFront. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon CloudFront's +// API operation DeleteServiceLinkedRole for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. +// +// * ErrCodeAccessDenied "AccessDenied" +// Access denied. +// +// * ErrCodeResourceInUse "ResourceInUse" +// +// * ErrCodeNoSuchResource "NoSuchResource" +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/DeleteServiceLinkedRole +func (c *CloudFront) DeleteServiceLinkedRole(input *DeleteServiceLinkedRoleInput) (*DeleteServiceLinkedRoleOutput, error) { + req, out := c.DeleteServiceLinkedRoleRequest(input) + return out, req.Send() +} + +// DeleteServiceLinkedRoleWithContext is the same as DeleteServiceLinkedRole with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteServiceLinkedRole for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) DeleteServiceLinkedRoleWithContext(ctx aws.Context, input *DeleteServiceLinkedRoleInput, opts ...request.Option) (*DeleteServiceLinkedRoleOutput, error) { + req, out := c.DeleteServiceLinkedRoleRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeleteStreamingDistribution = "DeleteStreamingDistribution2017_10_30" + +// DeleteStreamingDistributionRequest generates a "aws/request.Request" representing the +// client's request for the DeleteStreamingDistribution operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteStreamingDistribution for more information on using the DeleteStreamingDistribution +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteStreamingDistributionRequest method. +// req, resp := client.DeleteStreamingDistributionRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/DeleteStreamingDistribution +func (c *CloudFront) DeleteStreamingDistributionRequest(input *DeleteStreamingDistributionInput) (req *request.Request, output *DeleteStreamingDistributionOutput) { + op := &request.Operation{ + Name: opDeleteStreamingDistribution, + HTTPMethod: "DELETE", + HTTPPath: "/2017-10-30/streaming-distribution/{Id}", + } + + if input == nil { + input = &DeleteStreamingDistributionInput{} + } + + output = &DeleteStreamingDistributionOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeleteStreamingDistribution API operation for Amazon CloudFront. +// +// Delete a streaming distribution. To delete an RTMP distribution using the +// CloudFront API, perform the following steps. +// +// To delete an RTMP distribution using the CloudFront API: +// +// Disable the RTMP distribution. +// +// Submit a GET Streaming Distribution Config request to get the current configuration +// and the Etag header for the distribution. +// +// Update the XML document that was returned in the response to your GET Streaming +// Distribution Config request to change the value of Enabled to false. +// +// Submit a PUT Streaming Distribution Config request to update the configuration +// for your distribution. In the request body, include the XML document that +// you updated in Step 3. Then set the value of the HTTP If-Match header to +// the value of the ETag header that CloudFront returned when you submitted +// the GET Streaming Distribution Config request in Step 2. // // Review the response to the PUT Streaming Distribution Config request to confirm // that the distribution was successfully disabled. @@ -1234,7 +1830,7 @@ func (c *CloudFront) DeleteStreamingDistributionRequest(input *DeleteStreamingDi // The precondition given in one or more of the request-header fields evaluated // to false. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/DeleteStreamingDistribution +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/DeleteStreamingDistribution func (c *CloudFront) DeleteStreamingDistribution(input *DeleteStreamingDistributionInput) (*DeleteStreamingDistributionOutput, error) { req, out := c.DeleteStreamingDistributionRequest(input) return out, req.Send() @@ -1256,11 +1852,11 @@ func (c *CloudFront) DeleteStreamingDistributionWithContext(ctx aws.Context, inp return out, req.Send() } -const opGetCloudFrontOriginAccessIdentity = "GetCloudFrontOriginAccessIdentity2017_03_25" +const opGetCloudFrontOriginAccessIdentity = "GetCloudFrontOriginAccessIdentity2017_10_30" // GetCloudFrontOriginAccessIdentityRequest generates a "aws/request.Request" representing the // client's request for the GetCloudFrontOriginAccessIdentity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1281,12 +1877,12 @@ const opGetCloudFrontOriginAccessIdentity = "GetCloudFrontOriginAccessIdentity20 // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/GetCloudFrontOriginAccessIdentity +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetCloudFrontOriginAccessIdentity func (c *CloudFront) GetCloudFrontOriginAccessIdentityRequest(input *GetCloudFrontOriginAccessIdentityInput) (req *request.Request, output *GetCloudFrontOriginAccessIdentityOutput) { op := &request.Operation{ Name: opGetCloudFrontOriginAccessIdentity, HTTPMethod: "GET", - HTTPPath: "/2017-03-25/origin-access-identity/cloudfront/{Id}", + HTTPPath: "/2017-10-30/origin-access-identity/cloudfront/{Id}", } if input == nil { @@ -1316,7 +1912,7 @@ func (c *CloudFront) GetCloudFrontOriginAccessIdentityRequest(input *GetCloudFro // * ErrCodeAccessDenied "AccessDenied" // Access denied. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/GetCloudFrontOriginAccessIdentity +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetCloudFrontOriginAccessIdentity func (c *CloudFront) GetCloudFrontOriginAccessIdentity(input *GetCloudFrontOriginAccessIdentityInput) (*GetCloudFrontOriginAccessIdentityOutput, error) { req, out := c.GetCloudFrontOriginAccessIdentityRequest(input) return out, req.Send() @@ -1338,11 +1934,11 @@ func (c *CloudFront) GetCloudFrontOriginAccessIdentityWithContext(ctx aws.Contex return out, req.Send() } -const opGetCloudFrontOriginAccessIdentityConfig = "GetCloudFrontOriginAccessIdentityConfig2017_03_25" +const opGetCloudFrontOriginAccessIdentityConfig = "GetCloudFrontOriginAccessIdentityConfig2017_10_30" // GetCloudFrontOriginAccessIdentityConfigRequest generates a "aws/request.Request" representing the // client's request for the GetCloudFrontOriginAccessIdentityConfig operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1363,12 +1959,12 @@ const opGetCloudFrontOriginAccessIdentityConfig = "GetCloudFrontOriginAccessIden // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/GetCloudFrontOriginAccessIdentityConfig +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetCloudFrontOriginAccessIdentityConfig func (c *CloudFront) GetCloudFrontOriginAccessIdentityConfigRequest(input *GetCloudFrontOriginAccessIdentityConfigInput) (req *request.Request, output *GetCloudFrontOriginAccessIdentityConfigOutput) { op := &request.Operation{ Name: opGetCloudFrontOriginAccessIdentityConfig, HTTPMethod: "GET", - HTTPPath: "/2017-03-25/origin-access-identity/cloudfront/{Id}/config", + HTTPPath: "/2017-10-30/origin-access-identity/cloudfront/{Id}/config", } if input == nil { @@ -1398,7 +1994,7 @@ func (c *CloudFront) GetCloudFrontOriginAccessIdentityConfigRequest(input *GetCl // * ErrCodeAccessDenied "AccessDenied" // Access denied. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/GetCloudFrontOriginAccessIdentityConfig +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetCloudFrontOriginAccessIdentityConfig func (c *CloudFront) GetCloudFrontOriginAccessIdentityConfig(input *GetCloudFrontOriginAccessIdentityConfigInput) (*GetCloudFrontOriginAccessIdentityConfigOutput, error) { req, out := c.GetCloudFrontOriginAccessIdentityConfigRequest(input) return out, req.Send() @@ -1420,11 +2016,11 @@ func (c *CloudFront) GetCloudFrontOriginAccessIdentityConfigWithContext(ctx aws. return out, req.Send() } -const opGetDistribution = "GetDistribution2017_03_25" +const opGetDistribution = "GetDistribution2017_10_30" // GetDistributionRequest generates a "aws/request.Request" representing the // client's request for the GetDistribution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1445,12 +2041,12 @@ const opGetDistribution = "GetDistribution2017_03_25" // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/GetDistribution +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetDistribution func (c *CloudFront) GetDistributionRequest(input *GetDistributionInput) (req *request.Request, output *GetDistributionOutput) { op := &request.Operation{ Name: opGetDistribution, HTTPMethod: "GET", - HTTPPath: "/2017-03-25/distribution/{Id}", + HTTPPath: "/2017-10-30/distribution/{Id}", } if input == nil { @@ -1480,7 +2076,7 @@ func (c *CloudFront) GetDistributionRequest(input *GetDistributionInput) (req *r // * ErrCodeAccessDenied "AccessDenied" // Access denied. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/GetDistribution +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetDistribution func (c *CloudFront) GetDistribution(input *GetDistributionInput) (*GetDistributionOutput, error) { req, out := c.GetDistributionRequest(input) return out, req.Send() @@ -1502,11 +2098,11 @@ func (c *CloudFront) GetDistributionWithContext(ctx aws.Context, input *GetDistr return out, req.Send() } -const opGetDistributionConfig = "GetDistributionConfig2017_03_25" +const opGetDistributionConfig = "GetDistributionConfig2017_10_30" // GetDistributionConfigRequest generates a "aws/request.Request" representing the // client's request for the GetDistributionConfig operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1527,12 +2123,12 @@ const opGetDistributionConfig = "GetDistributionConfig2017_03_25" // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/GetDistributionConfig +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetDistributionConfig func (c *CloudFront) GetDistributionConfigRequest(input *GetDistributionConfigInput) (req *request.Request, output *GetDistributionConfigOutput) { op := &request.Operation{ Name: opGetDistributionConfig, HTTPMethod: "GET", - HTTPPath: "/2017-03-25/distribution/{Id}/config", + HTTPPath: "/2017-10-30/distribution/{Id}/config", } if input == nil { @@ -1562,7 +2158,7 @@ func (c *CloudFront) GetDistributionConfigRequest(input *GetDistributionConfigIn // * ErrCodeAccessDenied "AccessDenied" // Access denied. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/GetDistributionConfig +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetDistributionConfig func (c *CloudFront) GetDistributionConfig(input *GetDistributionConfigInput) (*GetDistributionConfigOutput, error) { req, out := c.GetDistributionConfigRequest(input) return out, req.Send() @@ -1584,2039 +2180,5343 @@ func (c *CloudFront) GetDistributionConfigWithContext(ctx aws.Context, input *Ge return out, req.Send() } -const opGetInvalidation = "GetInvalidation2017_03_25" +const opGetFieldLevelEncryption = "GetFieldLevelEncryption2017_10_30" -// GetInvalidationRequest generates a "aws/request.Request" representing the -// client's request for the GetInvalidation operation. The "output" return -// value will be populated with the request's response once the request complets +// GetFieldLevelEncryptionRequest generates a "aws/request.Request" representing the +// client's request for the GetFieldLevelEncryption operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetInvalidation for more information on using the GetInvalidation +// See GetFieldLevelEncryption for more information on using the GetFieldLevelEncryption // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the GetInvalidationRequest method. -// req, resp := client.GetInvalidationRequest(params) +// // Example sending a request using the GetFieldLevelEncryptionRequest method. +// req, resp := client.GetFieldLevelEncryptionRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/GetInvalidation -func (c *CloudFront) GetInvalidationRequest(input *GetInvalidationInput) (req *request.Request, output *GetInvalidationOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetFieldLevelEncryption +func (c *CloudFront) GetFieldLevelEncryptionRequest(input *GetFieldLevelEncryptionInput) (req *request.Request, output *GetFieldLevelEncryptionOutput) { op := &request.Operation{ - Name: opGetInvalidation, + Name: opGetFieldLevelEncryption, HTTPMethod: "GET", - HTTPPath: "/2017-03-25/distribution/{DistributionId}/invalidation/{Id}", + HTTPPath: "/2017-10-30/field-level-encryption/{Id}", } if input == nil { - input = &GetInvalidationInput{} + input = &GetFieldLevelEncryptionInput{} } - output = &GetInvalidationOutput{} + output = &GetFieldLevelEncryptionOutput{} req = c.newRequest(op, input, output) return } -// GetInvalidation API operation for Amazon CloudFront. +// GetFieldLevelEncryption API operation for Amazon CloudFront. // -// Get the information about an invalidation. +// Get the field-level encryption configuration information. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Amazon CloudFront's -// API operation GetInvalidation for usage and error information. +// API operation GetFieldLevelEncryption for usage and error information. // // Returned Error Codes: -// * ErrCodeNoSuchInvalidation "NoSuchInvalidation" -// The specified invalidation does not exist. -// -// * ErrCodeNoSuchDistribution "NoSuchDistribution" -// The specified distribution does not exist. -// // * ErrCodeAccessDenied "AccessDenied" // Access denied. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/GetInvalidation -func (c *CloudFront) GetInvalidation(input *GetInvalidationInput) (*GetInvalidationOutput, error) { - req, out := c.GetInvalidationRequest(input) +// * ErrCodeNoSuchFieldLevelEncryptionConfig "NoSuchFieldLevelEncryptionConfig" +// The specified configuration for field-level encryption doesn't exist. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetFieldLevelEncryption +func (c *CloudFront) GetFieldLevelEncryption(input *GetFieldLevelEncryptionInput) (*GetFieldLevelEncryptionOutput, error) { + req, out := c.GetFieldLevelEncryptionRequest(input) return out, req.Send() } -// GetInvalidationWithContext is the same as GetInvalidation with the addition of +// GetFieldLevelEncryptionWithContext is the same as GetFieldLevelEncryption with the addition of // the ability to pass a context and additional request options. // -// See GetInvalidation for details on how to use this API operation. +// See GetFieldLevelEncryption for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CloudFront) GetInvalidationWithContext(ctx aws.Context, input *GetInvalidationInput, opts ...request.Option) (*GetInvalidationOutput, error) { - req, out := c.GetInvalidationRequest(input) +func (c *CloudFront) GetFieldLevelEncryptionWithContext(ctx aws.Context, input *GetFieldLevelEncryptionInput, opts ...request.Option) (*GetFieldLevelEncryptionOutput, error) { + req, out := c.GetFieldLevelEncryptionRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opGetStreamingDistribution = "GetStreamingDistribution2017_03_25" +const opGetFieldLevelEncryptionConfig = "GetFieldLevelEncryptionConfig2017_10_30" -// GetStreamingDistributionRequest generates a "aws/request.Request" representing the -// client's request for the GetStreamingDistribution operation. The "output" return -// value will be populated with the request's response once the request complets +// GetFieldLevelEncryptionConfigRequest generates a "aws/request.Request" representing the +// client's request for the GetFieldLevelEncryptionConfig operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetStreamingDistribution for more information on using the GetStreamingDistribution +// See GetFieldLevelEncryptionConfig for more information on using the GetFieldLevelEncryptionConfig // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the GetStreamingDistributionRequest method. -// req, resp := client.GetStreamingDistributionRequest(params) +// // Example sending a request using the GetFieldLevelEncryptionConfigRequest method. +// req, resp := client.GetFieldLevelEncryptionConfigRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/GetStreamingDistribution -func (c *CloudFront) GetStreamingDistributionRequest(input *GetStreamingDistributionInput) (req *request.Request, output *GetStreamingDistributionOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetFieldLevelEncryptionConfig +func (c *CloudFront) GetFieldLevelEncryptionConfigRequest(input *GetFieldLevelEncryptionConfigInput) (req *request.Request, output *GetFieldLevelEncryptionConfigOutput) { op := &request.Operation{ - Name: opGetStreamingDistribution, + Name: opGetFieldLevelEncryptionConfig, HTTPMethod: "GET", - HTTPPath: "/2017-03-25/streaming-distribution/{Id}", + HTTPPath: "/2017-10-30/field-level-encryption/{Id}/config", } if input == nil { - input = &GetStreamingDistributionInput{} + input = &GetFieldLevelEncryptionConfigInput{} } - output = &GetStreamingDistributionOutput{} + output = &GetFieldLevelEncryptionConfigOutput{} req = c.newRequest(op, input, output) return } -// GetStreamingDistribution API operation for Amazon CloudFront. +// GetFieldLevelEncryptionConfig API operation for Amazon CloudFront. // -// Gets information about a specified RTMP distribution, including the distribution -// configuration. +// Get the field-level encryption configuration information. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Amazon CloudFront's -// API operation GetStreamingDistribution for usage and error information. +// API operation GetFieldLevelEncryptionConfig for usage and error information. // // Returned Error Codes: -// * ErrCodeNoSuchStreamingDistribution "NoSuchStreamingDistribution" -// The specified streaming distribution does not exist. -// // * ErrCodeAccessDenied "AccessDenied" // Access denied. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/GetStreamingDistribution -func (c *CloudFront) GetStreamingDistribution(input *GetStreamingDistributionInput) (*GetStreamingDistributionOutput, error) { - req, out := c.GetStreamingDistributionRequest(input) +// * ErrCodeNoSuchFieldLevelEncryptionConfig "NoSuchFieldLevelEncryptionConfig" +// The specified configuration for field-level encryption doesn't exist. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetFieldLevelEncryptionConfig +func (c *CloudFront) GetFieldLevelEncryptionConfig(input *GetFieldLevelEncryptionConfigInput) (*GetFieldLevelEncryptionConfigOutput, error) { + req, out := c.GetFieldLevelEncryptionConfigRequest(input) return out, req.Send() } -// GetStreamingDistributionWithContext is the same as GetStreamingDistribution with the addition of +// GetFieldLevelEncryptionConfigWithContext is the same as GetFieldLevelEncryptionConfig with the addition of // the ability to pass a context and additional request options. // -// See GetStreamingDistribution for details on how to use this API operation. +// See GetFieldLevelEncryptionConfig for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CloudFront) GetStreamingDistributionWithContext(ctx aws.Context, input *GetStreamingDistributionInput, opts ...request.Option) (*GetStreamingDistributionOutput, error) { - req, out := c.GetStreamingDistributionRequest(input) +func (c *CloudFront) GetFieldLevelEncryptionConfigWithContext(ctx aws.Context, input *GetFieldLevelEncryptionConfigInput, opts ...request.Option) (*GetFieldLevelEncryptionConfigOutput, error) { + req, out := c.GetFieldLevelEncryptionConfigRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opGetStreamingDistributionConfig = "GetStreamingDistributionConfig2017_03_25" +const opGetFieldLevelEncryptionProfile = "GetFieldLevelEncryptionProfile2017_10_30" -// GetStreamingDistributionConfigRequest generates a "aws/request.Request" representing the -// client's request for the GetStreamingDistributionConfig operation. The "output" return -// value will be populated with the request's response once the request complets +// GetFieldLevelEncryptionProfileRequest generates a "aws/request.Request" representing the +// client's request for the GetFieldLevelEncryptionProfile operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetStreamingDistributionConfig for more information on using the GetStreamingDistributionConfig +// See GetFieldLevelEncryptionProfile for more information on using the GetFieldLevelEncryptionProfile // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the GetStreamingDistributionConfigRequest method. -// req, resp := client.GetStreamingDistributionConfigRequest(params) +// // Example sending a request using the GetFieldLevelEncryptionProfileRequest method. +// req, resp := client.GetFieldLevelEncryptionProfileRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/GetStreamingDistributionConfig -func (c *CloudFront) GetStreamingDistributionConfigRequest(input *GetStreamingDistributionConfigInput) (req *request.Request, output *GetStreamingDistributionConfigOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetFieldLevelEncryptionProfile +func (c *CloudFront) GetFieldLevelEncryptionProfileRequest(input *GetFieldLevelEncryptionProfileInput) (req *request.Request, output *GetFieldLevelEncryptionProfileOutput) { op := &request.Operation{ - Name: opGetStreamingDistributionConfig, + Name: opGetFieldLevelEncryptionProfile, HTTPMethod: "GET", - HTTPPath: "/2017-03-25/streaming-distribution/{Id}/config", + HTTPPath: "/2017-10-30/field-level-encryption-profile/{Id}", } if input == nil { - input = &GetStreamingDistributionConfigInput{} + input = &GetFieldLevelEncryptionProfileInput{} } - output = &GetStreamingDistributionConfigOutput{} + output = &GetFieldLevelEncryptionProfileOutput{} req = c.newRequest(op, input, output) return } -// GetStreamingDistributionConfig API operation for Amazon CloudFront. +// GetFieldLevelEncryptionProfile API operation for Amazon CloudFront. // -// Get the configuration information about a streaming distribution. +// Get the field-level encryption profile information. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Amazon CloudFront's -// API operation GetStreamingDistributionConfig for usage and error information. +// API operation GetFieldLevelEncryptionProfile for usage and error information. // // Returned Error Codes: -// * ErrCodeNoSuchStreamingDistribution "NoSuchStreamingDistribution" -// The specified streaming distribution does not exist. -// // * ErrCodeAccessDenied "AccessDenied" // Access denied. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/GetStreamingDistributionConfig -func (c *CloudFront) GetStreamingDistributionConfig(input *GetStreamingDistributionConfigInput) (*GetStreamingDistributionConfigOutput, error) { - req, out := c.GetStreamingDistributionConfigRequest(input) +// * ErrCodeNoSuchFieldLevelEncryptionProfile "NoSuchFieldLevelEncryptionProfile" +// The specified profile for field-level encryption doesn't exist. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetFieldLevelEncryptionProfile +func (c *CloudFront) GetFieldLevelEncryptionProfile(input *GetFieldLevelEncryptionProfileInput) (*GetFieldLevelEncryptionProfileOutput, error) { + req, out := c.GetFieldLevelEncryptionProfileRequest(input) return out, req.Send() } -// GetStreamingDistributionConfigWithContext is the same as GetStreamingDistributionConfig with the addition of +// GetFieldLevelEncryptionProfileWithContext is the same as GetFieldLevelEncryptionProfile with the addition of // the ability to pass a context and additional request options. // -// See GetStreamingDistributionConfig for details on how to use this API operation. +// See GetFieldLevelEncryptionProfile for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CloudFront) GetStreamingDistributionConfigWithContext(ctx aws.Context, input *GetStreamingDistributionConfigInput, opts ...request.Option) (*GetStreamingDistributionConfigOutput, error) { - req, out := c.GetStreamingDistributionConfigRequest(input) +func (c *CloudFront) GetFieldLevelEncryptionProfileWithContext(ctx aws.Context, input *GetFieldLevelEncryptionProfileInput, opts ...request.Option) (*GetFieldLevelEncryptionProfileOutput, error) { + req, out := c.GetFieldLevelEncryptionProfileRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opListCloudFrontOriginAccessIdentities = "ListCloudFrontOriginAccessIdentities2017_03_25" +const opGetFieldLevelEncryptionProfileConfig = "GetFieldLevelEncryptionProfileConfig2017_10_30" -// ListCloudFrontOriginAccessIdentitiesRequest generates a "aws/request.Request" representing the -// client's request for the ListCloudFrontOriginAccessIdentities operation. The "output" return -// value will be populated with the request's response once the request complets +// GetFieldLevelEncryptionProfileConfigRequest generates a "aws/request.Request" representing the +// client's request for the GetFieldLevelEncryptionProfileConfig operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListCloudFrontOriginAccessIdentities for more information on using the ListCloudFrontOriginAccessIdentities +// See GetFieldLevelEncryptionProfileConfig for more information on using the GetFieldLevelEncryptionProfileConfig // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the ListCloudFrontOriginAccessIdentitiesRequest method. -// req, resp := client.ListCloudFrontOriginAccessIdentitiesRequest(params) +// // Example sending a request using the GetFieldLevelEncryptionProfileConfigRequest method. +// req, resp := client.GetFieldLevelEncryptionProfileConfigRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/ListCloudFrontOriginAccessIdentities -func (c *CloudFront) ListCloudFrontOriginAccessIdentitiesRequest(input *ListCloudFrontOriginAccessIdentitiesInput) (req *request.Request, output *ListCloudFrontOriginAccessIdentitiesOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetFieldLevelEncryptionProfileConfig +func (c *CloudFront) GetFieldLevelEncryptionProfileConfigRequest(input *GetFieldLevelEncryptionProfileConfigInput) (req *request.Request, output *GetFieldLevelEncryptionProfileConfigOutput) { op := &request.Operation{ - Name: opListCloudFrontOriginAccessIdentities, + Name: opGetFieldLevelEncryptionProfileConfig, HTTPMethod: "GET", - HTTPPath: "/2017-03-25/origin-access-identity/cloudfront", - Paginator: &request.Paginator{ - InputTokens: []string{"Marker"}, - OutputTokens: []string{"CloudFrontOriginAccessIdentityList.NextMarker"}, - LimitToken: "MaxItems", - TruncationToken: "CloudFrontOriginAccessIdentityList.IsTruncated", - }, + HTTPPath: "/2017-10-30/field-level-encryption-profile/{Id}/config", } if input == nil { - input = &ListCloudFrontOriginAccessIdentitiesInput{} + input = &GetFieldLevelEncryptionProfileConfigInput{} } - output = &ListCloudFrontOriginAccessIdentitiesOutput{} + output = &GetFieldLevelEncryptionProfileConfigOutput{} req = c.newRequest(op, input, output) return } -// ListCloudFrontOriginAccessIdentities API operation for Amazon CloudFront. +// GetFieldLevelEncryptionProfileConfig API operation for Amazon CloudFront. // -// Lists origin access identities. +// Get the field-level encryption profile configuration information. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Amazon CloudFront's -// API operation ListCloudFrontOriginAccessIdentities for usage and error information. +// API operation GetFieldLevelEncryptionProfileConfig for usage and error information. // // Returned Error Codes: -// * ErrCodeInvalidArgument "InvalidArgument" -// The argument is invalid. +// * ErrCodeAccessDenied "AccessDenied" +// Access denied. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/ListCloudFrontOriginAccessIdentities -func (c *CloudFront) ListCloudFrontOriginAccessIdentities(input *ListCloudFrontOriginAccessIdentitiesInput) (*ListCloudFrontOriginAccessIdentitiesOutput, error) { - req, out := c.ListCloudFrontOriginAccessIdentitiesRequest(input) +// * ErrCodeNoSuchFieldLevelEncryptionProfile "NoSuchFieldLevelEncryptionProfile" +// The specified profile for field-level encryption doesn't exist. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetFieldLevelEncryptionProfileConfig +func (c *CloudFront) GetFieldLevelEncryptionProfileConfig(input *GetFieldLevelEncryptionProfileConfigInput) (*GetFieldLevelEncryptionProfileConfigOutput, error) { + req, out := c.GetFieldLevelEncryptionProfileConfigRequest(input) return out, req.Send() } -// ListCloudFrontOriginAccessIdentitiesWithContext is the same as ListCloudFrontOriginAccessIdentities with the addition of +// GetFieldLevelEncryptionProfileConfigWithContext is the same as GetFieldLevelEncryptionProfileConfig with the addition of // the ability to pass a context and additional request options. // -// See ListCloudFrontOriginAccessIdentities for details on how to use this API operation. +// See GetFieldLevelEncryptionProfileConfig for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CloudFront) ListCloudFrontOriginAccessIdentitiesWithContext(ctx aws.Context, input *ListCloudFrontOriginAccessIdentitiesInput, opts ...request.Option) (*ListCloudFrontOriginAccessIdentitiesOutput, error) { - req, out := c.ListCloudFrontOriginAccessIdentitiesRequest(input) +func (c *CloudFront) GetFieldLevelEncryptionProfileConfigWithContext(ctx aws.Context, input *GetFieldLevelEncryptionProfileConfigInput, opts ...request.Option) (*GetFieldLevelEncryptionProfileConfigOutput, error) { + req, out := c.GetFieldLevelEncryptionProfileConfigRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListCloudFrontOriginAccessIdentitiesPages iterates over the pages of a ListCloudFrontOriginAccessIdentities operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See ListCloudFrontOriginAccessIdentities method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a ListCloudFrontOriginAccessIdentities operation. -// pageNum := 0 -// err := client.ListCloudFrontOriginAccessIdentitiesPages(params, -// func(page *ListCloudFrontOriginAccessIdentitiesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *CloudFront) ListCloudFrontOriginAccessIdentitiesPages(input *ListCloudFrontOriginAccessIdentitiesInput, fn func(*ListCloudFrontOriginAccessIdentitiesOutput, bool) bool) error { - return c.ListCloudFrontOriginAccessIdentitiesPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// ListCloudFrontOriginAccessIdentitiesPagesWithContext same as ListCloudFrontOriginAccessIdentitiesPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *CloudFront) ListCloudFrontOriginAccessIdentitiesPagesWithContext(ctx aws.Context, input *ListCloudFrontOriginAccessIdentitiesInput, fn func(*ListCloudFrontOriginAccessIdentitiesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListCloudFrontOriginAccessIdentitiesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListCloudFrontOriginAccessIdentitiesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*ListCloudFrontOriginAccessIdentitiesOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opListDistributions = "ListDistributions2017_03_25" +const opGetInvalidation = "GetInvalidation2017_10_30" -// ListDistributionsRequest generates a "aws/request.Request" representing the -// client's request for the ListDistributions operation. The "output" return -// value will be populated with the request's response once the request complets +// GetInvalidationRequest generates a "aws/request.Request" representing the +// client's request for the GetInvalidation operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListDistributions for more information on using the ListDistributions +// See GetInvalidation for more information on using the GetInvalidation // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the ListDistributionsRequest method. -// req, resp := client.ListDistributionsRequest(params) +// // Example sending a request using the GetInvalidationRequest method. +// req, resp := client.GetInvalidationRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/ListDistributions -func (c *CloudFront) ListDistributionsRequest(input *ListDistributionsInput) (req *request.Request, output *ListDistributionsOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetInvalidation +func (c *CloudFront) GetInvalidationRequest(input *GetInvalidationInput) (req *request.Request, output *GetInvalidationOutput) { op := &request.Operation{ - Name: opListDistributions, + Name: opGetInvalidation, HTTPMethod: "GET", - HTTPPath: "/2017-03-25/distribution", - Paginator: &request.Paginator{ - InputTokens: []string{"Marker"}, - OutputTokens: []string{"DistributionList.NextMarker"}, - LimitToken: "MaxItems", - TruncationToken: "DistributionList.IsTruncated", - }, + HTTPPath: "/2017-10-30/distribution/{DistributionId}/invalidation/{Id}", } if input == nil { - input = &ListDistributionsInput{} + input = &GetInvalidationInput{} } - output = &ListDistributionsOutput{} + output = &GetInvalidationOutput{} req = c.newRequest(op, input, output) return } -// ListDistributions API operation for Amazon CloudFront. +// GetInvalidation API operation for Amazon CloudFront. // -// List distributions. +// Get the information about an invalidation. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Amazon CloudFront's -// API operation ListDistributions for usage and error information. +// API operation GetInvalidation for usage and error information. // // Returned Error Codes: -// * ErrCodeInvalidArgument "InvalidArgument" -// The argument is invalid. +// * ErrCodeNoSuchInvalidation "NoSuchInvalidation" +// The specified invalidation does not exist. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/ListDistributions -func (c *CloudFront) ListDistributions(input *ListDistributionsInput) (*ListDistributionsOutput, error) { - req, out := c.ListDistributionsRequest(input) +// * ErrCodeNoSuchDistribution "NoSuchDistribution" +// The specified distribution does not exist. +// +// * ErrCodeAccessDenied "AccessDenied" +// Access denied. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetInvalidation +func (c *CloudFront) GetInvalidation(input *GetInvalidationInput) (*GetInvalidationOutput, error) { + req, out := c.GetInvalidationRequest(input) return out, req.Send() } -// ListDistributionsWithContext is the same as ListDistributions with the addition of +// GetInvalidationWithContext is the same as GetInvalidation with the addition of // the ability to pass a context and additional request options. // -// See ListDistributions for details on how to use this API operation. +// See GetInvalidation for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CloudFront) ListDistributionsWithContext(ctx aws.Context, input *ListDistributionsInput, opts ...request.Option) (*ListDistributionsOutput, error) { - req, out := c.ListDistributionsRequest(input) +func (c *CloudFront) GetInvalidationWithContext(ctx aws.Context, input *GetInvalidationInput, opts ...request.Option) (*GetInvalidationOutput, error) { + req, out := c.GetInvalidationRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListDistributionsPages iterates over the pages of a ListDistributions operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See ListDistributions method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a ListDistributions operation. -// pageNum := 0 -// err := client.ListDistributionsPages(params, -// func(page *ListDistributionsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *CloudFront) ListDistributionsPages(input *ListDistributionsInput, fn func(*ListDistributionsOutput, bool) bool) error { - return c.ListDistributionsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// ListDistributionsPagesWithContext same as ListDistributionsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *CloudFront) ListDistributionsPagesWithContext(ctx aws.Context, input *ListDistributionsInput, fn func(*ListDistributionsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListDistributionsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListDistributionsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*ListDistributionsOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opListDistributionsByWebACLId = "ListDistributionsByWebACLId2017_03_25" +const opGetPublicKey = "GetPublicKey2017_10_30" -// ListDistributionsByWebACLIdRequest generates a "aws/request.Request" representing the -// client's request for the ListDistributionsByWebACLId operation. The "output" return -// value will be populated with the request's response once the request complets +// GetPublicKeyRequest generates a "aws/request.Request" representing the +// client's request for the GetPublicKey operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListDistributionsByWebACLId for more information on using the ListDistributionsByWebACLId +// See GetPublicKey for more information on using the GetPublicKey // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the ListDistributionsByWebACLIdRequest method. -// req, resp := client.ListDistributionsByWebACLIdRequest(params) +// // Example sending a request using the GetPublicKeyRequest method. +// req, resp := client.GetPublicKeyRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/ListDistributionsByWebACLId -func (c *CloudFront) ListDistributionsByWebACLIdRequest(input *ListDistributionsByWebACLIdInput) (req *request.Request, output *ListDistributionsByWebACLIdOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetPublicKey +func (c *CloudFront) GetPublicKeyRequest(input *GetPublicKeyInput) (req *request.Request, output *GetPublicKeyOutput) { op := &request.Operation{ - Name: opListDistributionsByWebACLId, + Name: opGetPublicKey, HTTPMethod: "GET", - HTTPPath: "/2017-03-25/distributionsByWebACLId/{WebACLId}", + HTTPPath: "/2017-10-30/public-key/{Id}", } if input == nil { - input = &ListDistributionsByWebACLIdInput{} + input = &GetPublicKeyInput{} } - output = &ListDistributionsByWebACLIdOutput{} + output = &GetPublicKeyOutput{} req = c.newRequest(op, input, output) return } -// ListDistributionsByWebACLId API operation for Amazon CloudFront. +// GetPublicKey API operation for Amazon CloudFront. // -// List the distributions that are associated with a specified AWS WAF web ACL. +// Get the public key information. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Amazon CloudFront's -// API operation ListDistributionsByWebACLId for usage and error information. +// API operation GetPublicKey for usage and error information. // // Returned Error Codes: -// * ErrCodeInvalidArgument "InvalidArgument" -// The argument is invalid. +// * ErrCodeAccessDenied "AccessDenied" +// Access denied. // -// * ErrCodeInvalidWebACLId "InvalidWebACLId" +// * ErrCodeNoSuchPublicKey "NoSuchPublicKey" +// The specified public key doesn't exist. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/ListDistributionsByWebACLId -func (c *CloudFront) ListDistributionsByWebACLId(input *ListDistributionsByWebACLIdInput) (*ListDistributionsByWebACLIdOutput, error) { - req, out := c.ListDistributionsByWebACLIdRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetPublicKey +func (c *CloudFront) GetPublicKey(input *GetPublicKeyInput) (*GetPublicKeyOutput, error) { + req, out := c.GetPublicKeyRequest(input) return out, req.Send() } -// ListDistributionsByWebACLIdWithContext is the same as ListDistributionsByWebACLId with the addition of +// GetPublicKeyWithContext is the same as GetPublicKey with the addition of // the ability to pass a context and additional request options. // -// See ListDistributionsByWebACLId for details on how to use this API operation. +// See GetPublicKey for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CloudFront) ListDistributionsByWebACLIdWithContext(ctx aws.Context, input *ListDistributionsByWebACLIdInput, opts ...request.Option) (*ListDistributionsByWebACLIdOutput, error) { - req, out := c.ListDistributionsByWebACLIdRequest(input) +func (c *CloudFront) GetPublicKeyWithContext(ctx aws.Context, input *GetPublicKeyInput, opts ...request.Option) (*GetPublicKeyOutput, error) { + req, out := c.GetPublicKeyRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opListInvalidations = "ListInvalidations2017_03_25" +const opGetPublicKeyConfig = "GetPublicKeyConfig2017_10_30" -// ListInvalidationsRequest generates a "aws/request.Request" representing the -// client's request for the ListInvalidations operation. The "output" return -// value will be populated with the request's response once the request complets +// GetPublicKeyConfigRequest generates a "aws/request.Request" representing the +// client's request for the GetPublicKeyConfig operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListInvalidations for more information on using the ListInvalidations +// See GetPublicKeyConfig for more information on using the GetPublicKeyConfig // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the ListInvalidationsRequest method. -// req, resp := client.ListInvalidationsRequest(params) +// // Example sending a request using the GetPublicKeyConfigRequest method. +// req, resp := client.GetPublicKeyConfigRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/ListInvalidations -func (c *CloudFront) ListInvalidationsRequest(input *ListInvalidationsInput) (req *request.Request, output *ListInvalidationsOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetPublicKeyConfig +func (c *CloudFront) GetPublicKeyConfigRequest(input *GetPublicKeyConfigInput) (req *request.Request, output *GetPublicKeyConfigOutput) { op := &request.Operation{ - Name: opListInvalidations, + Name: opGetPublicKeyConfig, HTTPMethod: "GET", - HTTPPath: "/2017-03-25/distribution/{DistributionId}/invalidation", - Paginator: &request.Paginator{ - InputTokens: []string{"Marker"}, - OutputTokens: []string{"InvalidationList.NextMarker"}, - LimitToken: "MaxItems", - TruncationToken: "InvalidationList.IsTruncated", - }, + HTTPPath: "/2017-10-30/public-key/{Id}/config", } if input == nil { - input = &ListInvalidationsInput{} + input = &GetPublicKeyConfigInput{} } - output = &ListInvalidationsOutput{} + output = &GetPublicKeyConfigOutput{} req = c.newRequest(op, input, output) return } -// ListInvalidations API operation for Amazon CloudFront. +// GetPublicKeyConfig API operation for Amazon CloudFront. // -// Lists invalidation batches. +// Return public key configuration informaation // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Amazon CloudFront's -// API operation ListInvalidations for usage and error information. +// API operation GetPublicKeyConfig for usage and error information. // // Returned Error Codes: -// * ErrCodeInvalidArgument "InvalidArgument" -// The argument is invalid. -// -// * ErrCodeNoSuchDistribution "NoSuchDistribution" -// The specified distribution does not exist. -// // * ErrCodeAccessDenied "AccessDenied" // Access denied. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/ListInvalidations -func (c *CloudFront) ListInvalidations(input *ListInvalidationsInput) (*ListInvalidationsOutput, error) { - req, out := c.ListInvalidationsRequest(input) +// * ErrCodeNoSuchPublicKey "NoSuchPublicKey" +// The specified public key doesn't exist. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetPublicKeyConfig +func (c *CloudFront) GetPublicKeyConfig(input *GetPublicKeyConfigInput) (*GetPublicKeyConfigOutput, error) { + req, out := c.GetPublicKeyConfigRequest(input) return out, req.Send() } -// ListInvalidationsWithContext is the same as ListInvalidations with the addition of +// GetPublicKeyConfigWithContext is the same as GetPublicKeyConfig with the addition of // the ability to pass a context and additional request options. // -// See ListInvalidations for details on how to use this API operation. +// See GetPublicKeyConfig for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CloudFront) ListInvalidationsWithContext(ctx aws.Context, input *ListInvalidationsInput, opts ...request.Option) (*ListInvalidationsOutput, error) { - req, out := c.ListInvalidationsRequest(input) +func (c *CloudFront) GetPublicKeyConfigWithContext(ctx aws.Context, input *GetPublicKeyConfigInput, opts ...request.Option) (*GetPublicKeyConfigOutput, error) { + req, out := c.GetPublicKeyConfigRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListInvalidationsPages iterates over the pages of a ListInvalidations operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See ListInvalidations method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a ListInvalidations operation. -// pageNum := 0 -// err := client.ListInvalidationsPages(params, -// func(page *ListInvalidationsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *CloudFront) ListInvalidationsPages(input *ListInvalidationsInput, fn func(*ListInvalidationsOutput, bool) bool) error { - return c.ListInvalidationsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// ListInvalidationsPagesWithContext same as ListInvalidationsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *CloudFront) ListInvalidationsPagesWithContext(ctx aws.Context, input *ListInvalidationsInput, fn func(*ListInvalidationsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListInvalidationsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListInvalidationsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*ListInvalidationsOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opListStreamingDistributions = "ListStreamingDistributions2017_03_25" +const opGetStreamingDistribution = "GetStreamingDistribution2017_10_30" -// ListStreamingDistributionsRequest generates a "aws/request.Request" representing the -// client's request for the ListStreamingDistributions operation. The "output" return -// value will be populated with the request's response once the request complets +// GetStreamingDistributionRequest generates a "aws/request.Request" representing the +// client's request for the GetStreamingDistribution operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListStreamingDistributions for more information on using the ListStreamingDistributions +// See GetStreamingDistribution for more information on using the GetStreamingDistribution // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the ListStreamingDistributionsRequest method. -// req, resp := client.ListStreamingDistributionsRequest(params) +// // Example sending a request using the GetStreamingDistributionRequest method. +// req, resp := client.GetStreamingDistributionRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/ListStreamingDistributions -func (c *CloudFront) ListStreamingDistributionsRequest(input *ListStreamingDistributionsInput) (req *request.Request, output *ListStreamingDistributionsOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetStreamingDistribution +func (c *CloudFront) GetStreamingDistributionRequest(input *GetStreamingDistributionInput) (req *request.Request, output *GetStreamingDistributionOutput) { op := &request.Operation{ - Name: opListStreamingDistributions, + Name: opGetStreamingDistribution, HTTPMethod: "GET", - HTTPPath: "/2017-03-25/streaming-distribution", - Paginator: &request.Paginator{ - InputTokens: []string{"Marker"}, - OutputTokens: []string{"StreamingDistributionList.NextMarker"}, - LimitToken: "MaxItems", - TruncationToken: "StreamingDistributionList.IsTruncated", - }, + HTTPPath: "/2017-10-30/streaming-distribution/{Id}", } if input == nil { - input = &ListStreamingDistributionsInput{} + input = &GetStreamingDistributionInput{} } - output = &ListStreamingDistributionsOutput{} + output = &GetStreamingDistributionOutput{} req = c.newRequest(op, input, output) return } -// ListStreamingDistributions API operation for Amazon CloudFront. +// GetStreamingDistribution API operation for Amazon CloudFront. // -// List streaming distributions. +// Gets information about a specified RTMP distribution, including the distribution +// configuration. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Amazon CloudFront's -// API operation ListStreamingDistributions for usage and error information. +// API operation GetStreamingDistribution for usage and error information. // // Returned Error Codes: -// * ErrCodeInvalidArgument "InvalidArgument" -// The argument is invalid. +// * ErrCodeNoSuchStreamingDistribution "NoSuchStreamingDistribution" +// The specified streaming distribution does not exist. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/ListStreamingDistributions -func (c *CloudFront) ListStreamingDistributions(input *ListStreamingDistributionsInput) (*ListStreamingDistributionsOutput, error) { - req, out := c.ListStreamingDistributionsRequest(input) +// * ErrCodeAccessDenied "AccessDenied" +// Access denied. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetStreamingDistribution +func (c *CloudFront) GetStreamingDistribution(input *GetStreamingDistributionInput) (*GetStreamingDistributionOutput, error) { + req, out := c.GetStreamingDistributionRequest(input) return out, req.Send() } -// ListStreamingDistributionsWithContext is the same as ListStreamingDistributions with the addition of +// GetStreamingDistributionWithContext is the same as GetStreamingDistribution with the addition of // the ability to pass a context and additional request options. // -// See ListStreamingDistributions for details on how to use this API operation. +// See GetStreamingDistribution for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CloudFront) ListStreamingDistributionsWithContext(ctx aws.Context, input *ListStreamingDistributionsInput, opts ...request.Option) (*ListStreamingDistributionsOutput, error) { - req, out := c.ListStreamingDistributionsRequest(input) +func (c *CloudFront) GetStreamingDistributionWithContext(ctx aws.Context, input *GetStreamingDistributionInput, opts ...request.Option) (*GetStreamingDistributionOutput, error) { + req, out := c.GetStreamingDistributionRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListStreamingDistributionsPages iterates over the pages of a ListStreamingDistributions operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See ListStreamingDistributions method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a ListStreamingDistributions operation. -// pageNum := 0 -// err := client.ListStreamingDistributionsPages(params, -// func(page *ListStreamingDistributionsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *CloudFront) ListStreamingDistributionsPages(input *ListStreamingDistributionsInput, fn func(*ListStreamingDistributionsOutput, bool) bool) error { - return c.ListStreamingDistributionsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// ListStreamingDistributionsPagesWithContext same as ListStreamingDistributionsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *CloudFront) ListStreamingDistributionsPagesWithContext(ctx aws.Context, input *ListStreamingDistributionsInput, fn func(*ListStreamingDistributionsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListStreamingDistributionsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListStreamingDistributionsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*ListStreamingDistributionsOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opListTagsForResource = "ListTagsForResource2017_03_25" +const opGetStreamingDistributionConfig = "GetStreamingDistributionConfig2017_10_30" -// ListTagsForResourceRequest generates a "aws/request.Request" representing the -// client's request for the ListTagsForResource operation. The "output" return -// value will be populated with the request's response once the request complets +// GetStreamingDistributionConfigRequest generates a "aws/request.Request" representing the +// client's request for the GetStreamingDistributionConfig operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListTagsForResource for more information on using the ListTagsForResource +// See GetStreamingDistributionConfig for more information on using the GetStreamingDistributionConfig // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the ListTagsForResourceRequest method. -// req, resp := client.ListTagsForResourceRequest(params) +// // Example sending a request using the GetStreamingDistributionConfigRequest method. +// req, resp := client.GetStreamingDistributionConfigRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/ListTagsForResource -func (c *CloudFront) ListTagsForResourceRequest(input *ListTagsForResourceInput) (req *request.Request, output *ListTagsForResourceOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetStreamingDistributionConfig +func (c *CloudFront) GetStreamingDistributionConfigRequest(input *GetStreamingDistributionConfigInput) (req *request.Request, output *GetStreamingDistributionConfigOutput) { op := &request.Operation{ - Name: opListTagsForResource, + Name: opGetStreamingDistributionConfig, HTTPMethod: "GET", - HTTPPath: "/2017-03-25/tagging", + HTTPPath: "/2017-10-30/streaming-distribution/{Id}/config", } if input == nil { - input = &ListTagsForResourceInput{} + input = &GetStreamingDistributionConfigInput{} } - output = &ListTagsForResourceOutput{} + output = &GetStreamingDistributionConfigOutput{} req = c.newRequest(op, input, output) return } -// ListTagsForResource API operation for Amazon CloudFront. +// GetStreamingDistributionConfig API operation for Amazon CloudFront. // -// List tags for a CloudFront resource. +// Get the configuration information about a streaming distribution. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Amazon CloudFront's -// API operation ListTagsForResource for usage and error information. +// API operation GetStreamingDistributionConfig for usage and error information. // // Returned Error Codes: +// * ErrCodeNoSuchStreamingDistribution "NoSuchStreamingDistribution" +// The specified streaming distribution does not exist. +// // * ErrCodeAccessDenied "AccessDenied" // Access denied. // -// * ErrCodeInvalidArgument "InvalidArgument" -// The argument is invalid. -// -// * ErrCodeInvalidTagging "InvalidTagging" -// -// * ErrCodeNoSuchResource "NoSuchResource" -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/ListTagsForResource -func (c *CloudFront) ListTagsForResource(input *ListTagsForResourceInput) (*ListTagsForResourceOutput, error) { - req, out := c.ListTagsForResourceRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/GetStreamingDistributionConfig +func (c *CloudFront) GetStreamingDistributionConfig(input *GetStreamingDistributionConfigInput) (*GetStreamingDistributionConfigOutput, error) { + req, out := c.GetStreamingDistributionConfigRequest(input) return out, req.Send() } -// ListTagsForResourceWithContext is the same as ListTagsForResource with the addition of +// GetStreamingDistributionConfigWithContext is the same as GetStreamingDistributionConfig with the addition of // the ability to pass a context and additional request options. // -// See ListTagsForResource for details on how to use this API operation. +// See GetStreamingDistributionConfig for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CloudFront) ListTagsForResourceWithContext(ctx aws.Context, input *ListTagsForResourceInput, opts ...request.Option) (*ListTagsForResourceOutput, error) { - req, out := c.ListTagsForResourceRequest(input) +func (c *CloudFront) GetStreamingDistributionConfigWithContext(ctx aws.Context, input *GetStreamingDistributionConfigInput, opts ...request.Option) (*GetStreamingDistributionConfigOutput, error) { + req, out := c.GetStreamingDistributionConfigRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opTagResource = "TagResource2017_03_25" +const opListCloudFrontOriginAccessIdentities = "ListCloudFrontOriginAccessIdentities2017_10_30" -// TagResourceRequest generates a "aws/request.Request" representing the -// client's request for the TagResource operation. The "output" return -// value will be populated with the request's response once the request complets +// ListCloudFrontOriginAccessIdentitiesRequest generates a "aws/request.Request" representing the +// client's request for the ListCloudFrontOriginAccessIdentities operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See TagResource for more information on using the TagResource +// See ListCloudFrontOriginAccessIdentities for more information on using the ListCloudFrontOriginAccessIdentities // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the TagResourceRequest method. -// req, resp := client.TagResourceRequest(params) +// // Example sending a request using the ListCloudFrontOriginAccessIdentitiesRequest method. +// req, resp := client.ListCloudFrontOriginAccessIdentitiesRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/TagResource -func (c *CloudFront) TagResourceRequest(input *TagResourceInput) (req *request.Request, output *TagResourceOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListCloudFrontOriginAccessIdentities +func (c *CloudFront) ListCloudFrontOriginAccessIdentitiesRequest(input *ListCloudFrontOriginAccessIdentitiesInput) (req *request.Request, output *ListCloudFrontOriginAccessIdentitiesOutput) { op := &request.Operation{ - Name: opTagResource, - HTTPMethod: "POST", - HTTPPath: "/2017-03-25/tagging?Operation=Tag", + Name: opListCloudFrontOriginAccessIdentities, + HTTPMethod: "GET", + HTTPPath: "/2017-10-30/origin-access-identity/cloudfront", + Paginator: &request.Paginator{ + InputTokens: []string{"Marker"}, + OutputTokens: []string{"CloudFrontOriginAccessIdentityList.NextMarker"}, + LimitToken: "MaxItems", + TruncationToken: "CloudFrontOriginAccessIdentityList.IsTruncated", + }, } if input == nil { - input = &TagResourceInput{} + input = &ListCloudFrontOriginAccessIdentitiesInput{} } - output = &TagResourceOutput{} + output = &ListCloudFrontOriginAccessIdentitiesOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler) - req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } -// TagResource API operation for Amazon CloudFront. +// ListCloudFrontOriginAccessIdentities API operation for Amazon CloudFront. // -// Add tags to a CloudFront resource. +// Lists origin access identities. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Amazon CloudFront's -// API operation TagResource for usage and error information. +// API operation ListCloudFrontOriginAccessIdentities for usage and error information. // // Returned Error Codes: -// * ErrCodeAccessDenied "AccessDenied" -// Access denied. -// // * ErrCodeInvalidArgument "InvalidArgument" // The argument is invalid. // -// * ErrCodeInvalidTagging "InvalidTagging" -// -// * ErrCodeNoSuchResource "NoSuchResource" -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/TagResource -func (c *CloudFront) TagResource(input *TagResourceInput) (*TagResourceOutput, error) { - req, out := c.TagResourceRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListCloudFrontOriginAccessIdentities +func (c *CloudFront) ListCloudFrontOriginAccessIdentities(input *ListCloudFrontOriginAccessIdentitiesInput) (*ListCloudFrontOriginAccessIdentitiesOutput, error) { + req, out := c.ListCloudFrontOriginAccessIdentitiesRequest(input) return out, req.Send() } -// TagResourceWithContext is the same as TagResource with the addition of +// ListCloudFrontOriginAccessIdentitiesWithContext is the same as ListCloudFrontOriginAccessIdentities with the addition of // the ability to pass a context and additional request options. // -// See TagResource for details on how to use this API operation. +// See ListCloudFrontOriginAccessIdentities for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CloudFront) TagResourceWithContext(ctx aws.Context, input *TagResourceInput, opts ...request.Option) (*TagResourceOutput, error) { - req, out := c.TagResourceRequest(input) +func (c *CloudFront) ListCloudFrontOriginAccessIdentitiesWithContext(ctx aws.Context, input *ListCloudFrontOriginAccessIdentitiesInput, opts ...request.Option) (*ListCloudFrontOriginAccessIdentitiesOutput, error) { + req, out := c.ListCloudFrontOriginAccessIdentitiesRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opUntagResource = "UntagResource2017_03_25" +// ListCloudFrontOriginAccessIdentitiesPages iterates over the pages of a ListCloudFrontOriginAccessIdentities operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListCloudFrontOriginAccessIdentities method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListCloudFrontOriginAccessIdentities operation. +// pageNum := 0 +// err := client.ListCloudFrontOriginAccessIdentitiesPages(params, +// func(page *ListCloudFrontOriginAccessIdentitiesOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *CloudFront) ListCloudFrontOriginAccessIdentitiesPages(input *ListCloudFrontOriginAccessIdentitiesInput, fn func(*ListCloudFrontOriginAccessIdentitiesOutput, bool) bool) error { + return c.ListCloudFrontOriginAccessIdentitiesPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListCloudFrontOriginAccessIdentitiesPagesWithContext same as ListCloudFrontOriginAccessIdentitiesPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) ListCloudFrontOriginAccessIdentitiesPagesWithContext(ctx aws.Context, input *ListCloudFrontOriginAccessIdentitiesInput, fn func(*ListCloudFrontOriginAccessIdentitiesOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListCloudFrontOriginAccessIdentitiesInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListCloudFrontOriginAccessIdentitiesRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } -// UntagResourceRequest generates a "aws/request.Request" representing the -// client's request for the UntagResource operation. The "output" return -// value will be populated with the request's response once the request complets + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListCloudFrontOriginAccessIdentitiesOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListDistributions = "ListDistributions2017_10_30" + +// ListDistributionsRequest generates a "aws/request.Request" representing the +// client's request for the ListDistributions operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See UntagResource for more information on using the UntagResource +// See ListDistributions for more information on using the ListDistributions // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the UntagResourceRequest method. -// req, resp := client.UntagResourceRequest(params) +// // Example sending a request using the ListDistributionsRequest method. +// req, resp := client.ListDistributionsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/UntagResource -func (c *CloudFront) UntagResourceRequest(input *UntagResourceInput) (req *request.Request, output *UntagResourceOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListDistributions +func (c *CloudFront) ListDistributionsRequest(input *ListDistributionsInput) (req *request.Request, output *ListDistributionsOutput) { op := &request.Operation{ - Name: opUntagResource, - HTTPMethod: "POST", - HTTPPath: "/2017-03-25/tagging?Operation=Untag", + Name: opListDistributions, + HTTPMethod: "GET", + HTTPPath: "/2017-10-30/distribution", + Paginator: &request.Paginator{ + InputTokens: []string{"Marker"}, + OutputTokens: []string{"DistributionList.NextMarker"}, + LimitToken: "MaxItems", + TruncationToken: "DistributionList.IsTruncated", + }, } if input == nil { - input = &UntagResourceInput{} + input = &ListDistributionsInput{} } - output = &UntagResourceOutput{} + output = &ListDistributionsOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler) - req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } -// UntagResource API operation for Amazon CloudFront. +// ListDistributions API operation for Amazon CloudFront. // -// Remove tags from a CloudFront resource. +// List distributions. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Amazon CloudFront's -// API operation UntagResource for usage and error information. +// API operation ListDistributions for usage and error information. // // Returned Error Codes: -// * ErrCodeAccessDenied "AccessDenied" -// Access denied. -// // * ErrCodeInvalidArgument "InvalidArgument" // The argument is invalid. // -// * ErrCodeInvalidTagging "InvalidTagging" -// -// * ErrCodeNoSuchResource "NoSuchResource" -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/UntagResource -func (c *CloudFront) UntagResource(input *UntagResourceInput) (*UntagResourceOutput, error) { - req, out := c.UntagResourceRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListDistributions +func (c *CloudFront) ListDistributions(input *ListDistributionsInput) (*ListDistributionsOutput, error) { + req, out := c.ListDistributionsRequest(input) return out, req.Send() } -// UntagResourceWithContext is the same as UntagResource with the addition of +// ListDistributionsWithContext is the same as ListDistributions with the addition of // the ability to pass a context and additional request options. // -// See UntagResource for details on how to use this API operation. +// See ListDistributions for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CloudFront) UntagResourceWithContext(ctx aws.Context, input *UntagResourceInput, opts ...request.Option) (*UntagResourceOutput, error) { - req, out := c.UntagResourceRequest(input) +func (c *CloudFront) ListDistributionsWithContext(ctx aws.Context, input *ListDistributionsInput, opts ...request.Option) (*ListDistributionsOutput, error) { + req, out := c.ListDistributionsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opUpdateCloudFrontOriginAccessIdentity = "UpdateCloudFrontOriginAccessIdentity2017_03_25" +// ListDistributionsPages iterates over the pages of a ListDistributions operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListDistributions method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListDistributions operation. +// pageNum := 0 +// err := client.ListDistributionsPages(params, +// func(page *ListDistributionsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *CloudFront) ListDistributionsPages(input *ListDistributionsInput, fn func(*ListDistributionsOutput, bool) bool) error { + return c.ListDistributionsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListDistributionsPagesWithContext same as ListDistributionsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) ListDistributionsPagesWithContext(ctx aws.Context, input *ListDistributionsInput, fn func(*ListDistributionsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListDistributionsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListDistributionsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListDistributionsOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListDistributionsByWebACLId = "ListDistributionsByWebACLId2017_10_30" -// UpdateCloudFrontOriginAccessIdentityRequest generates a "aws/request.Request" representing the -// client's request for the UpdateCloudFrontOriginAccessIdentity operation. The "output" return -// value will be populated with the request's response once the request complets +// ListDistributionsByWebACLIdRequest generates a "aws/request.Request" representing the +// client's request for the ListDistributionsByWebACLId operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See UpdateCloudFrontOriginAccessIdentity for more information on using the UpdateCloudFrontOriginAccessIdentity +// See ListDistributionsByWebACLId for more information on using the ListDistributionsByWebACLId // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the UpdateCloudFrontOriginAccessIdentityRequest method. -// req, resp := client.UpdateCloudFrontOriginAccessIdentityRequest(params) +// // Example sending a request using the ListDistributionsByWebACLIdRequest method. +// req, resp := client.ListDistributionsByWebACLIdRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/UpdateCloudFrontOriginAccessIdentity -func (c *CloudFront) UpdateCloudFrontOriginAccessIdentityRequest(input *UpdateCloudFrontOriginAccessIdentityInput) (req *request.Request, output *UpdateCloudFrontOriginAccessIdentityOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListDistributionsByWebACLId +func (c *CloudFront) ListDistributionsByWebACLIdRequest(input *ListDistributionsByWebACLIdInput) (req *request.Request, output *ListDistributionsByWebACLIdOutput) { op := &request.Operation{ - Name: opUpdateCloudFrontOriginAccessIdentity, - HTTPMethod: "PUT", - HTTPPath: "/2017-03-25/origin-access-identity/cloudfront/{Id}/config", + Name: opListDistributionsByWebACLId, + HTTPMethod: "GET", + HTTPPath: "/2017-10-30/distributionsByWebACLId/{WebACLId}", } if input == nil { - input = &UpdateCloudFrontOriginAccessIdentityInput{} + input = &ListDistributionsByWebACLIdInput{} } - output = &UpdateCloudFrontOriginAccessIdentityOutput{} + output = &ListDistributionsByWebACLIdOutput{} req = c.newRequest(op, input, output) return } -// UpdateCloudFrontOriginAccessIdentity API operation for Amazon CloudFront. +// ListDistributionsByWebACLId API operation for Amazon CloudFront. // -// Update an origin access identity. +// List the distributions that are associated with a specified AWS WAF web ACL. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Amazon CloudFront's -// API operation UpdateCloudFrontOriginAccessIdentity for usage and error information. +// API operation ListDistributionsByWebACLId for usage and error information. // // Returned Error Codes: -// * ErrCodeAccessDenied "AccessDenied" -// Access denied. -// -// * ErrCodeIllegalUpdate "IllegalUpdate" -// Origin and CallerReference cannot be updated. -// -// * ErrCodeInvalidIfMatchVersion "InvalidIfMatchVersion" -// The If-Match version is missing or not valid for the distribution. -// -// * ErrCodeMissingBody "MissingBody" -// This operation requires a body. Ensure that the body is present and the Content-Type -// header is set. -// -// * ErrCodeNoSuchCloudFrontOriginAccessIdentity "NoSuchCloudFrontOriginAccessIdentity" -// The specified origin access identity does not exist. -// -// * ErrCodePreconditionFailed "PreconditionFailed" -// The precondition given in one or more of the request-header fields evaluated -// to false. -// // * ErrCodeInvalidArgument "InvalidArgument" // The argument is invalid. // -// * ErrCodeInconsistentQuantities "InconsistentQuantities" -// The value of Quantity and the size of Items don't match. +// * ErrCodeInvalidWebACLId "InvalidWebACLId" // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/UpdateCloudFrontOriginAccessIdentity -func (c *CloudFront) UpdateCloudFrontOriginAccessIdentity(input *UpdateCloudFrontOriginAccessIdentityInput) (*UpdateCloudFrontOriginAccessIdentityOutput, error) { - req, out := c.UpdateCloudFrontOriginAccessIdentityRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListDistributionsByWebACLId +func (c *CloudFront) ListDistributionsByWebACLId(input *ListDistributionsByWebACLIdInput) (*ListDistributionsByWebACLIdOutput, error) { + req, out := c.ListDistributionsByWebACLIdRequest(input) return out, req.Send() } -// UpdateCloudFrontOriginAccessIdentityWithContext is the same as UpdateCloudFrontOriginAccessIdentity with the addition of +// ListDistributionsByWebACLIdWithContext is the same as ListDistributionsByWebACLId with the addition of // the ability to pass a context and additional request options. // -// See UpdateCloudFrontOriginAccessIdentity for details on how to use this API operation. +// See ListDistributionsByWebACLId for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CloudFront) UpdateCloudFrontOriginAccessIdentityWithContext(ctx aws.Context, input *UpdateCloudFrontOriginAccessIdentityInput, opts ...request.Option) (*UpdateCloudFrontOriginAccessIdentityOutput, error) { - req, out := c.UpdateCloudFrontOriginAccessIdentityRequest(input) +func (c *CloudFront) ListDistributionsByWebACLIdWithContext(ctx aws.Context, input *ListDistributionsByWebACLIdInput, opts ...request.Option) (*ListDistributionsByWebACLIdOutput, error) { + req, out := c.ListDistributionsByWebACLIdRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opUpdateDistribution = "UpdateDistribution2017_03_25" +const opListFieldLevelEncryptionConfigs = "ListFieldLevelEncryptionConfigs2017_10_30" -// UpdateDistributionRequest generates a "aws/request.Request" representing the -// client's request for the UpdateDistribution operation. The "output" return -// value will be populated with the request's response once the request complets +// ListFieldLevelEncryptionConfigsRequest generates a "aws/request.Request" representing the +// client's request for the ListFieldLevelEncryptionConfigs operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See UpdateDistribution for more information on using the UpdateDistribution +// See ListFieldLevelEncryptionConfigs for more information on using the ListFieldLevelEncryptionConfigs // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the UpdateDistributionRequest method. -// req, resp := client.UpdateDistributionRequest(params) +// // Example sending a request using the ListFieldLevelEncryptionConfigsRequest method. +// req, resp := client.ListFieldLevelEncryptionConfigsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/UpdateDistribution -func (c *CloudFront) UpdateDistributionRequest(input *UpdateDistributionInput) (req *request.Request, output *UpdateDistributionOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListFieldLevelEncryptionConfigs +func (c *CloudFront) ListFieldLevelEncryptionConfigsRequest(input *ListFieldLevelEncryptionConfigsInput) (req *request.Request, output *ListFieldLevelEncryptionConfigsOutput) { op := &request.Operation{ - Name: opUpdateDistribution, - HTTPMethod: "PUT", - HTTPPath: "/2017-03-25/distribution/{Id}/config", + Name: opListFieldLevelEncryptionConfigs, + HTTPMethod: "GET", + HTTPPath: "/2017-10-30/field-level-encryption", } if input == nil { - input = &UpdateDistributionInput{} + input = &ListFieldLevelEncryptionConfigsInput{} } - output = &UpdateDistributionOutput{} + output = &ListFieldLevelEncryptionConfigsOutput{} req = c.newRequest(op, input, output) return } -// UpdateDistribution API operation for Amazon CloudFront. +// ListFieldLevelEncryptionConfigs API operation for Amazon CloudFront. // -// Updates the configuration for a web distribution. Perform the following steps. +// List all field-level encryption configurations that have been created in +// CloudFront for this account. // -// For information about updating a distribution using the CloudFront console, -// see Creating or Updating a Web Distribution Using the CloudFront Console -// (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/distribution-web-creating-console.html) -// in the Amazon CloudFront Developer Guide. +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. // -// To update a web distribution using the CloudFront API +// See the AWS API reference guide for Amazon CloudFront's +// API operation ListFieldLevelEncryptionConfigs for usage and error information. // -// Submit a GetDistributionConfig request to get the current configuration and -// an Etag header for the distribution. +// Returned Error Codes: +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. // -// If you update the distribution again, you need to get a new Etag header. +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListFieldLevelEncryptionConfigs +func (c *CloudFront) ListFieldLevelEncryptionConfigs(input *ListFieldLevelEncryptionConfigsInput) (*ListFieldLevelEncryptionConfigsOutput, error) { + req, out := c.ListFieldLevelEncryptionConfigsRequest(input) + return out, req.Send() +} + +// ListFieldLevelEncryptionConfigsWithContext is the same as ListFieldLevelEncryptionConfigs with the addition of +// the ability to pass a context and additional request options. // -// Update the XML document that was returned in the response to your GetDistributionConfig -// request to include the desired changes. You can't change the value of CallerReference. -// If you try to change this value, CloudFront returns an IllegalUpdate error. +// See ListFieldLevelEncryptionConfigs for details on how to use this API operation. // -// The new configuration replaces the existing configuration; the values that -// you specify in an UpdateDistribution request are not merged into the existing -// configuration. When you add, delete, or replace values in an element that -// allows multiple values (for example, CNAME), you must specify all of the -// values that you want to appear in the updated distribution. In addition, -// you must update the corresponding Quantity element. +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) ListFieldLevelEncryptionConfigsWithContext(ctx aws.Context, input *ListFieldLevelEncryptionConfigsInput, opts ...request.Option) (*ListFieldLevelEncryptionConfigsOutput, error) { + req, out := c.ListFieldLevelEncryptionConfigsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opListFieldLevelEncryptionProfiles = "ListFieldLevelEncryptionProfiles2017_10_30" + +// ListFieldLevelEncryptionProfilesRequest generates a "aws/request.Request" representing the +// client's request for the ListFieldLevelEncryptionProfiles operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. // -// Submit an UpdateDistribution request to update the configuration for your -// distribution: +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. // -// In the request body, include the XML document that you updated in Step 2. -// The request body must include an XML document with a DistributionConfig element. +// See ListFieldLevelEncryptionProfiles for more information on using the ListFieldLevelEncryptionProfiles +// API call, and error handling. // -// Set the value of the HTTP If-Match header to the value of the ETag header -// that CloudFront returned when you submitted the GetDistributionConfig request -// in Step 1. +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// Review the response to the UpdateDistribution request to confirm that the -// configuration was successfully updated. // -// Optional: Submit a GetDistribution request to confirm that your changes have -// propagated. When propagation is complete, the value of Status is Deployed. +// // Example sending a request using the ListFieldLevelEncryptionProfilesRequest method. +// req, resp := client.ListFieldLevelEncryptionProfilesRequest(params) // -// Beginning with the 2012-05-05 version of the CloudFront API, we made substantial -// changes to the format of the XML document that you include in the request -// body when you create or update a distribution. With previous versions of -// the API, we discovered that it was too easy to accidentally delete one or -// more values for an element that accepts multiple values, for example, CNAMEs -// and trusted signers. Our changes for the 2012-05-05 release are intended -// to prevent these accidental deletions and to notify you when there's a mismatch -// between the number of values you say you're specifying in the Quantity element -// and the number of values you're actually specifying. +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListFieldLevelEncryptionProfiles +func (c *CloudFront) ListFieldLevelEncryptionProfilesRequest(input *ListFieldLevelEncryptionProfilesInput) (req *request.Request, output *ListFieldLevelEncryptionProfilesOutput) { + op := &request.Operation{ + Name: opListFieldLevelEncryptionProfiles, + HTTPMethod: "GET", + HTTPPath: "/2017-10-30/field-level-encryption-profile", + } + + if input == nil { + input = &ListFieldLevelEncryptionProfilesInput{} + } + + output = &ListFieldLevelEncryptionProfilesOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListFieldLevelEncryptionProfiles API operation for Amazon CloudFront. +// +// Request a list of field-level encryption profiles that have been created +// in CloudFront for this account. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Amazon CloudFront's -// API operation UpdateDistribution for usage and error information. +// API operation ListFieldLevelEncryptionProfiles for usage and error information. // // Returned Error Codes: -// * ErrCodeAccessDenied "AccessDenied" -// Access denied. -// -// * ErrCodeCNAMEAlreadyExists "CNAMEAlreadyExists" -// -// * ErrCodeIllegalUpdate "IllegalUpdate" -// Origin and CallerReference cannot be updated. -// -// * ErrCodeInvalidIfMatchVersion "InvalidIfMatchVersion" -// The If-Match version is missing or not valid for the distribution. -// -// * ErrCodeMissingBody "MissingBody" -// This operation requires a body. Ensure that the body is present and the Content-Type -// header is set. -// -// * ErrCodeNoSuchDistribution "NoSuchDistribution" -// The specified distribution does not exist. -// -// * ErrCodePreconditionFailed "PreconditionFailed" -// The precondition given in one or more of the request-header fields evaluated -// to false. -// -// * ErrCodeTooManyDistributionCNAMEs "TooManyDistributionCNAMEs" -// Your request contains more CNAMEs than are allowed per distribution. -// -// * ErrCodeInvalidDefaultRootObject "InvalidDefaultRootObject" -// The default root object file name is too big or contains an invalid character. -// -// * ErrCodeInvalidRelativePath "InvalidRelativePath" -// The relative path is too big, is not URL-encoded, or does not begin with -// a slash (/). -// -// * ErrCodeInvalidErrorCode "InvalidErrorCode" -// -// * ErrCodeInvalidResponseCode "InvalidResponseCode" -// // * ErrCodeInvalidArgument "InvalidArgument" // The argument is invalid. // -// * ErrCodeInvalidOriginAccessIdentity "InvalidOriginAccessIdentity" -// The origin access identity is not valid or doesn't exist. -// -// * ErrCodeTooManyTrustedSigners "TooManyTrustedSigners" -// Your request contains more trusted signers than are allowed per distribution. -// -// * ErrCodeTrustedSignerDoesNotExist "TrustedSignerDoesNotExist" -// One or more of your trusted signers don't exist. -// -// * ErrCodeInvalidViewerCertificate "InvalidViewerCertificate" -// -// * ErrCodeInvalidMinimumProtocolVersion "InvalidMinimumProtocolVersion" -// -// * ErrCodeInvalidRequiredProtocol "InvalidRequiredProtocol" -// This operation requires the HTTPS protocol. Ensure that you specify the HTTPS -// protocol in your request, or omit the RequiredProtocols element from your -// distribution configuration. -// -// * ErrCodeNoSuchOrigin "NoSuchOrigin" -// No origin exists with the specified Origin Id. -// -// * ErrCodeTooManyOrigins "TooManyOrigins" -// You cannot create more origins for the distribution. -// -// * ErrCodeTooManyCacheBehaviors "TooManyCacheBehaviors" -// You cannot create more cache behaviors for the distribution. -// -// * ErrCodeTooManyCookieNamesInWhiteList "TooManyCookieNamesInWhiteList" -// Your request contains more cookie names in the whitelist than are allowed -// per cache behavior. -// -// * ErrCodeInvalidForwardCookies "InvalidForwardCookies" -// Your request contains forward cookies option which doesn't match with the -// expectation for the whitelisted list of cookie names. Either list of cookie -// names has been specified when not allowed or list of cookie names is missing -// when expected. -// -// * ErrCodeTooManyHeadersInForwardedValues "TooManyHeadersInForwardedValues" -// -// * ErrCodeInvalidHeadersForS3Origin "InvalidHeadersForS3Origin" -// -// * ErrCodeInconsistentQuantities "InconsistentQuantities" -// The value of Quantity and the size of Items don't match. -// -// * ErrCodeTooManyCertificates "TooManyCertificates" -// You cannot create anymore custom SSL/TLS certificates. -// -// * ErrCodeInvalidLocationCode "InvalidLocationCode" -// -// * ErrCodeInvalidGeoRestrictionParameter "InvalidGeoRestrictionParameter" -// -// * ErrCodeInvalidTTLOrder "InvalidTTLOrder" -// -// * ErrCodeInvalidWebACLId "InvalidWebACLId" -// -// * ErrCodeTooManyOriginCustomHeaders "TooManyOriginCustomHeaders" -// -// * ErrCodeTooManyQueryStringParameters "TooManyQueryStringParameters" -// -// * ErrCodeInvalidQueryStringParameters "InvalidQueryStringParameters" -// -// * ErrCodeTooManyDistributionsWithLambdaAssociations "TooManyDistributionsWithLambdaAssociations" -// Processing your request would cause the maximum number of distributions with -// Lambda function associations per owner to be exceeded. -// -// * ErrCodeTooManyLambdaFunctionAssociations "TooManyLambdaFunctionAssociations" -// Your request contains more Lambda function associations than are allowed -// per distribution. -// -// * ErrCodeInvalidLambdaFunctionAssociation "InvalidLambdaFunctionAssociation" -// The specified Lambda function association is invalid. -// -// * ErrCodeInvalidOriginReadTimeout "InvalidOriginReadTimeout" -// -// * ErrCodeInvalidOriginKeepaliveTimeout "InvalidOriginKeepaliveTimeout" -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/UpdateDistribution -func (c *CloudFront) UpdateDistribution(input *UpdateDistributionInput) (*UpdateDistributionOutput, error) { - req, out := c.UpdateDistributionRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListFieldLevelEncryptionProfiles +func (c *CloudFront) ListFieldLevelEncryptionProfiles(input *ListFieldLevelEncryptionProfilesInput) (*ListFieldLevelEncryptionProfilesOutput, error) { + req, out := c.ListFieldLevelEncryptionProfilesRequest(input) return out, req.Send() } -// UpdateDistributionWithContext is the same as UpdateDistribution with the addition of +// ListFieldLevelEncryptionProfilesWithContext is the same as ListFieldLevelEncryptionProfiles with the addition of // the ability to pass a context and additional request options. // -// See UpdateDistribution for details on how to use this API operation. +// See ListFieldLevelEncryptionProfiles for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CloudFront) UpdateDistributionWithContext(ctx aws.Context, input *UpdateDistributionInput, opts ...request.Option) (*UpdateDistributionOutput, error) { - req, out := c.UpdateDistributionRequest(input) +func (c *CloudFront) ListFieldLevelEncryptionProfilesWithContext(ctx aws.Context, input *ListFieldLevelEncryptionProfilesInput, opts ...request.Option) (*ListFieldLevelEncryptionProfilesOutput, error) { + req, out := c.ListFieldLevelEncryptionProfilesRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opUpdateStreamingDistribution = "UpdateStreamingDistribution2017_03_25" +const opListInvalidations = "ListInvalidations2017_10_30" -// UpdateStreamingDistributionRequest generates a "aws/request.Request" representing the -// client's request for the UpdateStreamingDistribution operation. The "output" return -// value will be populated with the request's response once the request complets +// ListInvalidationsRequest generates a "aws/request.Request" representing the +// client's request for the ListInvalidations operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See UpdateStreamingDistribution for more information on using the UpdateStreamingDistribution +// See ListInvalidations for more information on using the ListInvalidations // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the UpdateStreamingDistributionRequest method. -// req, resp := client.UpdateStreamingDistributionRequest(params) +// // Example sending a request using the ListInvalidationsRequest method. +// req, resp := client.ListInvalidationsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/UpdateStreamingDistribution -func (c *CloudFront) UpdateStreamingDistributionRequest(input *UpdateStreamingDistributionInput) (req *request.Request, output *UpdateStreamingDistributionOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListInvalidations +func (c *CloudFront) ListInvalidationsRequest(input *ListInvalidationsInput) (req *request.Request, output *ListInvalidationsOutput) { op := &request.Operation{ - Name: opUpdateStreamingDistribution, - HTTPMethod: "PUT", - HTTPPath: "/2017-03-25/streaming-distribution/{Id}/config", + Name: opListInvalidations, + HTTPMethod: "GET", + HTTPPath: "/2017-10-30/distribution/{DistributionId}/invalidation", + Paginator: &request.Paginator{ + InputTokens: []string{"Marker"}, + OutputTokens: []string{"InvalidationList.NextMarker"}, + LimitToken: "MaxItems", + TruncationToken: "InvalidationList.IsTruncated", + }, } if input == nil { - input = &UpdateStreamingDistributionInput{} + input = &ListInvalidationsInput{} } - output = &UpdateStreamingDistributionOutput{} + output = &ListInvalidationsOutput{} req = c.newRequest(op, input, output) return } -// UpdateStreamingDistribution API operation for Amazon CloudFront. +// ListInvalidations API operation for Amazon CloudFront. // -// Update a streaming distribution. +// Lists invalidation batches. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for Amazon CloudFront's -// API operation UpdateStreamingDistribution for usage and error information. +// API operation ListInvalidations for usage and error information. // // Returned Error Codes: +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. +// +// * ErrCodeNoSuchDistribution "NoSuchDistribution" +// The specified distribution does not exist. +// // * ErrCodeAccessDenied "AccessDenied" // Access denied. // -// * ErrCodeCNAMEAlreadyExists "CNAMEAlreadyExists" +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListInvalidations +func (c *CloudFront) ListInvalidations(input *ListInvalidationsInput) (*ListInvalidationsOutput, error) { + req, out := c.ListInvalidationsRequest(input) + return out, req.Send() +} + +// ListInvalidationsWithContext is the same as ListInvalidations with the addition of +// the ability to pass a context and additional request options. // -// * ErrCodeIllegalUpdate "IllegalUpdate" -// Origin and CallerReference cannot be updated. +// See ListInvalidations for details on how to use this API operation. // -// * ErrCodeInvalidIfMatchVersion "InvalidIfMatchVersion" -// The If-Match version is missing or not valid for the distribution. +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) ListInvalidationsWithContext(ctx aws.Context, input *ListInvalidationsInput, opts ...request.Option) (*ListInvalidationsOutput, error) { + req, out := c.ListInvalidationsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListInvalidationsPages iterates over the pages of a ListInvalidations operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. // -// * ErrCodeMissingBody "MissingBody" -// This operation requires a body. Ensure that the body is present and the Content-Type -// header is set. +// See ListInvalidations method for more information on how to use this operation. // -// * ErrCodeNoSuchStreamingDistribution "NoSuchStreamingDistribution" -// The specified streaming distribution does not exist. +// Note: This operation can generate multiple requests to a service. // -// * ErrCodePreconditionFailed "PreconditionFailed" -// The precondition given in one or more of the request-header fields evaluated -// to false. +// // Example iterating over at most 3 pages of a ListInvalidations operation. +// pageNum := 0 +// err := client.ListInvalidationsPages(params, +// func(page *ListInvalidationsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) // -// * ErrCodeTooManyStreamingDistributionCNAMEs "TooManyStreamingDistributionCNAMEs" +func (c *CloudFront) ListInvalidationsPages(input *ListInvalidationsInput, fn func(*ListInvalidationsOutput, bool) bool) error { + return c.ListInvalidationsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListInvalidationsPagesWithContext same as ListInvalidationsPages except +// it takes a Context and allows setting request options on the pages. // -// * ErrCodeInvalidArgument "InvalidArgument" -// The argument is invalid. +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) ListInvalidationsPagesWithContext(ctx aws.Context, input *ListInvalidationsInput, fn func(*ListInvalidationsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListInvalidationsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListInvalidationsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListInvalidationsOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListPublicKeys = "ListPublicKeys2017_10_30" + +// ListPublicKeysRequest generates a "aws/request.Request" representing the +// client's request for the ListPublicKeys operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. // -// * ErrCodeInvalidOriginAccessIdentity "InvalidOriginAccessIdentity" -// The origin access identity is not valid or doesn't exist. +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. // -// * ErrCodeTooManyTrustedSigners "TooManyTrustedSigners" -// Your request contains more trusted signers than are allowed per distribution. +// See ListPublicKeys for more information on using the ListPublicKeys +// API call, and error handling. // -// * ErrCodeTrustedSignerDoesNotExist "TrustedSignerDoesNotExist" -// One or more of your trusted signers don't exist. +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// * ErrCodeInconsistentQuantities "InconsistentQuantities" -// The value of Quantity and the size of Items don't match. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25/UpdateStreamingDistribution -func (c *CloudFront) UpdateStreamingDistribution(input *UpdateStreamingDistributionInput) (*UpdateStreamingDistributionOutput, error) { - req, out := c.UpdateStreamingDistributionRequest(input) +// // Example sending a request using the ListPublicKeysRequest method. +// req, resp := client.ListPublicKeysRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListPublicKeys +func (c *CloudFront) ListPublicKeysRequest(input *ListPublicKeysInput) (req *request.Request, output *ListPublicKeysOutput) { + op := &request.Operation{ + Name: opListPublicKeys, + HTTPMethod: "GET", + HTTPPath: "/2017-10-30/public-key", + } + + if input == nil { + input = &ListPublicKeysInput{} + } + + output = &ListPublicKeysOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListPublicKeys API operation for Amazon CloudFront. +// +// List all public keys that have been added to CloudFront for this account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon CloudFront's +// API operation ListPublicKeys for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListPublicKeys +func (c *CloudFront) ListPublicKeys(input *ListPublicKeysInput) (*ListPublicKeysOutput, error) { + req, out := c.ListPublicKeysRequest(input) return out, req.Send() } -// UpdateStreamingDistributionWithContext is the same as UpdateStreamingDistribution with the addition of +// ListPublicKeysWithContext is the same as ListPublicKeys with the addition of // the ability to pass a context and additional request options. // -// See UpdateStreamingDistribution for details on how to use this API operation. +// See ListPublicKeys for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CloudFront) UpdateStreamingDistributionWithContext(ctx aws.Context, input *UpdateStreamingDistributionInput, opts ...request.Option) (*UpdateStreamingDistributionOutput, error) { - req, out := c.UpdateStreamingDistributionRequest(input) +func (c *CloudFront) ListPublicKeysWithContext(ctx aws.Context, input *ListPublicKeysInput, opts ...request.Option) (*ListPublicKeysOutput, error) { + req, out := c.ListPublicKeysRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// A complex type that lists the AWS accounts, if any, that you included in -// the TrustedSigners complex type for this distribution. These are the accounts -// that you want to allow to create signed URLs for private content. +const opListStreamingDistributions = "ListStreamingDistributions2017_10_30" + +// ListStreamingDistributionsRequest generates a "aws/request.Request" representing the +// client's request for the ListStreamingDistributions operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. // -// The Signer complex type lists the AWS account number of the trusted signer -// or self if the signer is the AWS account that created the distribution. The -// Signer element also includes the IDs of any active CloudFront key pairs that -// are associated with the trusted signer's AWS account. If no KeyPairId element -// appears for a Signer, that signer can't create signed URLs. +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. // -// For more information, see Serving Private Content through CloudFront (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/PrivateContent.html) -// in the Amazon CloudFront Developer Guide. -type ActiveTrustedSigners struct { - _ struct{} `type:"structure"` - - // Enabled is true if any of the AWS accounts listed in the TrustedSigners complex - // type for this RTMP distribution have active CloudFront key pairs. If not, - // Enabled is false. - // - // For more information, see ActiveTrustedSigners. - // - // Enabled is a required field - Enabled *bool `type:"boolean" required:"true"` +// See ListStreamingDistributions for more information on using the ListStreamingDistributions +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListStreamingDistributionsRequest method. +// req, resp := client.ListStreamingDistributionsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListStreamingDistributions +func (c *CloudFront) ListStreamingDistributionsRequest(input *ListStreamingDistributionsInput) (req *request.Request, output *ListStreamingDistributionsOutput) { + op := &request.Operation{ + Name: opListStreamingDistributions, + HTTPMethod: "GET", + HTTPPath: "/2017-10-30/streaming-distribution", + Paginator: &request.Paginator{ + InputTokens: []string{"Marker"}, + OutputTokens: []string{"StreamingDistributionList.NextMarker"}, + LimitToken: "MaxItems", + TruncationToken: "StreamingDistributionList.IsTruncated", + }, + } - // A complex type that contains one Signer complex type for each trusted signer - // that is specified in the TrustedSigners complex type. - // - // For more information, see ActiveTrustedSigners. - Items []*Signer `locationNameList:"Signer" type:"list"` + if input == nil { + input = &ListStreamingDistributionsInput{} + } - // A complex type that contains one Signer complex type for each trusted signer - // specified in the TrustedSigners complex type. - // - // For more information, see ActiveTrustedSigners. - // - // Quantity is a required field - Quantity *int64 `type:"integer" required:"true"` + output = &ListStreamingDistributionsOutput{} + req = c.newRequest(op, input, output) + return } -// String returns the string representation -func (s ActiveTrustedSigners) String() string { - return awsutil.Prettify(s) +// ListStreamingDistributions API operation for Amazon CloudFront. +// +// List streaming distributions. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon CloudFront's +// API operation ListStreamingDistributions for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListStreamingDistributions +func (c *CloudFront) ListStreamingDistributions(input *ListStreamingDistributionsInput) (*ListStreamingDistributionsOutput, error) { + req, out := c.ListStreamingDistributionsRequest(input) + return out, req.Send() } -// GoString returns the string representation -func (s ActiveTrustedSigners) GoString() string { - return s.String() +// ListStreamingDistributionsWithContext is the same as ListStreamingDistributions with the addition of +// the ability to pass a context and additional request options. +// +// See ListStreamingDistributions for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) ListStreamingDistributionsWithContext(ctx aws.Context, input *ListStreamingDistributionsInput, opts ...request.Option) (*ListStreamingDistributionsOutput, error) { + req, out := c.ListStreamingDistributionsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() } -// SetEnabled sets the Enabled field's value. -func (s *ActiveTrustedSigners) SetEnabled(v bool) *ActiveTrustedSigners { - s.Enabled = &v - return s +// ListStreamingDistributionsPages iterates over the pages of a ListStreamingDistributions operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListStreamingDistributions method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListStreamingDistributions operation. +// pageNum := 0 +// err := client.ListStreamingDistributionsPages(params, +// func(page *ListStreamingDistributionsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *CloudFront) ListStreamingDistributionsPages(input *ListStreamingDistributionsInput, fn func(*ListStreamingDistributionsOutput, bool) bool) error { + return c.ListStreamingDistributionsPagesWithContext(aws.BackgroundContext(), input, fn) } -// SetItems sets the Items field's value. -func (s *ActiveTrustedSigners) SetItems(v []*Signer) *ActiveTrustedSigners { - s.Items = v - return s -} +// ListStreamingDistributionsPagesWithContext same as ListStreamingDistributionsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) ListStreamingDistributionsPagesWithContext(ctx aws.Context, input *ListStreamingDistributionsInput, fn func(*ListStreamingDistributionsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListStreamingDistributionsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListStreamingDistributionsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } -// SetQuantity sets the Quantity field's value. -func (s *ActiveTrustedSigners) SetQuantity(v int64) *ActiveTrustedSigners { - s.Quantity = &v - return s -} - -// A complex type that contains information about CNAMEs (alternate domain names), -// if any, for this distribution. -type Aliases struct { - _ struct{} `type:"structure"` - - // A complex type that contains the CNAME aliases, if any, that you want to - // associate with this distribution. - Items []*string `locationNameList:"CNAME" type:"list"` - - // The number of CNAME aliases, if any, that you want to associate with this - // distribution. - // - // Quantity is a required field - Quantity *int64 `type:"integer" required:"true"` -} - -// String returns the string representation -func (s Aliases) String() string { - return awsutil.Prettify(s) + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListStreamingDistributionsOutput), !p.HasNextPage()) + } + return p.Err() } -// GoString returns the string representation -func (s Aliases) GoString() string { - return s.String() -} +const opListTagsForResource = "ListTagsForResource2017_10_30" -// Validate inspects the fields of the type to determine if they are valid. -func (s *Aliases) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "Aliases"} - if s.Quantity == nil { - invalidParams.Add(request.NewErrParamRequired("Quantity")) +// ListTagsForResourceRequest generates a "aws/request.Request" representing the +// client's request for the ListTagsForResource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListTagsForResource for more information on using the ListTagsForResource +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListTagsForResourceRequest method. +// req, resp := client.ListTagsForResourceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListTagsForResource +func (c *CloudFront) ListTagsForResourceRequest(input *ListTagsForResourceInput) (req *request.Request, output *ListTagsForResourceOutput) { + op := &request.Operation{ + Name: opListTagsForResource, + HTTPMethod: "GET", + HTTPPath: "/2017-10-30/tagging", } - if invalidParams.Len() > 0 { - return invalidParams + if input == nil { + input = &ListTagsForResourceInput{} } - return nil -} - -// SetItems sets the Items field's value. -func (s *Aliases) SetItems(v []*string) *Aliases { - s.Items = v - return s -} -// SetQuantity sets the Quantity field's value. -func (s *Aliases) SetQuantity(v int64) *Aliases { - s.Quantity = &v - return s + output = &ListTagsForResourceOutput{} + req = c.newRequest(op, input, output) + return } -// A complex type that controls which HTTP methods CloudFront processes and -// forwards to your Amazon S3 bucket or your custom origin. There are three -// choices: +// ListTagsForResource API operation for Amazon CloudFront. // -// * CloudFront forwards only GET and HEAD requests. +// List tags for a CloudFront resource. // -// * CloudFront forwards only GET, HEAD, and OPTIONS requests. +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. // -// * CloudFront forwards GET, HEAD, OPTIONS, PUT, PATCH, POST, and DELETE -// requests. +// See the AWS API reference guide for Amazon CloudFront's +// API operation ListTagsForResource for usage and error information. // -// If you pick the third choice, you may need to restrict access to your Amazon -// S3 bucket or to your custom origin so users can't perform operations that -// you don't want them to. For example, you might not want users to have permissions -// to delete objects from your origin. -type AllowedMethods struct { - _ struct{} `type:"structure"` - - // A complex type that controls whether CloudFront caches the response to requests - // using the specified HTTP methods. There are two choices: - // - // * CloudFront caches responses to GET and HEAD requests. - // - // * CloudFront caches responses to GET, HEAD, and OPTIONS requests. - // - // If you pick the second choice for your Amazon S3 Origin, you may need to - // forward Access-Control-Request-Method, Access-Control-Request-Headers, and - // Origin headers for the responses to be cached correctly. - CachedMethods *CachedMethods `type:"structure"` - - // A complex type that contains the HTTP methods that you want CloudFront to - // process and forward to your origin. - // - // Items is a required field - Items []*string `locationNameList:"Method" type:"list" required:"true"` - - // The number of HTTP methods that you want CloudFront to forward to your origin. - // Valid values are 2 (for GET and HEAD requests), 3 (for GET, HEAD, and OPTIONS - // requests) and 7 (for GET, HEAD, OPTIONS, PUT, PATCH, POST, and DELETE requests). - // - // Quantity is a required field - Quantity *int64 `type:"integer" required:"true"` +// Returned Error Codes: +// * ErrCodeAccessDenied "AccessDenied" +// Access denied. +// +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. +// +// * ErrCodeInvalidTagging "InvalidTagging" +// +// * ErrCodeNoSuchResource "NoSuchResource" +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/ListTagsForResource +func (c *CloudFront) ListTagsForResource(input *ListTagsForResourceInput) (*ListTagsForResourceOutput, error) { + req, out := c.ListTagsForResourceRequest(input) + return out, req.Send() } -// String returns the string representation -func (s AllowedMethods) String() string { - return awsutil.Prettify(s) +// ListTagsForResourceWithContext is the same as ListTagsForResource with the addition of +// the ability to pass a context and additional request options. +// +// See ListTagsForResource for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) ListTagsForResourceWithContext(ctx aws.Context, input *ListTagsForResourceInput, opts ...request.Option) (*ListTagsForResourceOutput, error) { + req, out := c.ListTagsForResourceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() } -// GoString returns the string representation -func (s AllowedMethods) GoString() string { - return s.String() -} +const opTagResource = "TagResource2017_10_30" -// Validate inspects the fields of the type to determine if they are valid. -func (s *AllowedMethods) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "AllowedMethods"} - if s.Items == nil { - invalidParams.Add(request.NewErrParamRequired("Items")) - } - if s.Quantity == nil { - invalidParams.Add(request.NewErrParamRequired("Quantity")) - } - if s.CachedMethods != nil { - if err := s.CachedMethods.Validate(); err != nil { - invalidParams.AddNested("CachedMethods", err.(request.ErrInvalidParams)) - } +// TagResourceRequest generates a "aws/request.Request" representing the +// client's request for the TagResource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See TagResource for more information on using the TagResource +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the TagResourceRequest method. +// req, resp := client.TagResourceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/TagResource +func (c *CloudFront) TagResourceRequest(input *TagResourceInput) (req *request.Request, output *TagResourceOutput) { + op := &request.Operation{ + Name: opTagResource, + HTTPMethod: "POST", + HTTPPath: "/2017-10-30/tagging?Operation=Tag", } - if invalidParams.Len() > 0 { - return invalidParams + if input == nil { + input = &TagResourceInput{} } - return nil -} - -// SetCachedMethods sets the CachedMethods field's value. -func (s *AllowedMethods) SetCachedMethods(v *CachedMethods) *AllowedMethods { - s.CachedMethods = v - return s -} - -// SetItems sets the Items field's value. -func (s *AllowedMethods) SetItems(v []*string) *AllowedMethods { - s.Items = v - return s -} -// SetQuantity sets the Quantity field's value. -func (s *AllowedMethods) SetQuantity(v int64) *AllowedMethods { - s.Quantity = &v - return s + output = &TagResourceOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return } -// A complex type that describes how CloudFront processes requests. +// TagResource API operation for Amazon CloudFront. // -// You must create at least as many cache behaviors (including the default cache -// behavior) as you have origins if you want CloudFront to distribute objects -// from all of the origins. Each cache behavior specifies the one origin from -// which you want CloudFront to get objects. If you have two origins and only -// the default cache behavior, the default cache behavior will cause CloudFront -// to get objects from one of the origins, but the other origin is never used. +// Add tags to a CloudFront resource. // -// For the current limit on the number of cache behaviors that you can add to -// a distribution, see Amazon CloudFront Limits (http://docs.aws.amazon.com/general/latest/gr/aws_service_limits.html#limits_cloudfront) -// in the AWS General Reference. +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. // -// If you don't want to specify any cache behaviors, include only an empty CacheBehaviors -// element. Don't include an empty CacheBehavior element, or CloudFront returns -// a MalformedXML error. +// See the AWS API reference guide for Amazon CloudFront's +// API operation TagResource for usage and error information. // -// To delete all cache behaviors in an existing distribution, update the distribution -// configuration and include only an empty CacheBehaviors element. +// Returned Error Codes: +// * ErrCodeAccessDenied "AccessDenied" +// Access denied. // -// To add, change, or remove one or more cache behaviors, update the distribution +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. +// +// * ErrCodeInvalidTagging "InvalidTagging" +// +// * ErrCodeNoSuchResource "NoSuchResource" +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/TagResource +func (c *CloudFront) TagResource(input *TagResourceInput) (*TagResourceOutput, error) { + req, out := c.TagResourceRequest(input) + return out, req.Send() +} + +// TagResourceWithContext is the same as TagResource with the addition of +// the ability to pass a context and additional request options. +// +// See TagResource for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) TagResourceWithContext(ctx aws.Context, input *TagResourceInput, opts ...request.Option) (*TagResourceOutput, error) { + req, out := c.TagResourceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUntagResource = "UntagResource2017_10_30" + +// UntagResourceRequest generates a "aws/request.Request" representing the +// client's request for the UntagResource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UntagResource for more information on using the UntagResource +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the UntagResourceRequest method. +// req, resp := client.UntagResourceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/UntagResource +func (c *CloudFront) UntagResourceRequest(input *UntagResourceInput) (req *request.Request, output *UntagResourceOutput) { + op := &request.Operation{ + Name: opUntagResource, + HTTPMethod: "POST", + HTTPPath: "/2017-10-30/tagging?Operation=Untag", + } + + if input == nil { + input = &UntagResourceInput{} + } + + output = &UntagResourceOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// UntagResource API operation for Amazon CloudFront. +// +// Remove tags from a CloudFront resource. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon CloudFront's +// API operation UntagResource for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDenied "AccessDenied" +// Access denied. +// +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. +// +// * ErrCodeInvalidTagging "InvalidTagging" +// +// * ErrCodeNoSuchResource "NoSuchResource" +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/UntagResource +func (c *CloudFront) UntagResource(input *UntagResourceInput) (*UntagResourceOutput, error) { + req, out := c.UntagResourceRequest(input) + return out, req.Send() +} + +// UntagResourceWithContext is the same as UntagResource with the addition of +// the ability to pass a context and additional request options. +// +// See UntagResource for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) UntagResourceWithContext(ctx aws.Context, input *UntagResourceInput, opts ...request.Option) (*UntagResourceOutput, error) { + req, out := c.UntagResourceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateCloudFrontOriginAccessIdentity = "UpdateCloudFrontOriginAccessIdentity2017_10_30" + +// UpdateCloudFrontOriginAccessIdentityRequest generates a "aws/request.Request" representing the +// client's request for the UpdateCloudFrontOriginAccessIdentity operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateCloudFrontOriginAccessIdentity for more information on using the UpdateCloudFrontOriginAccessIdentity +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the UpdateCloudFrontOriginAccessIdentityRequest method. +// req, resp := client.UpdateCloudFrontOriginAccessIdentityRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/UpdateCloudFrontOriginAccessIdentity +func (c *CloudFront) UpdateCloudFrontOriginAccessIdentityRequest(input *UpdateCloudFrontOriginAccessIdentityInput) (req *request.Request, output *UpdateCloudFrontOriginAccessIdentityOutput) { + op := &request.Operation{ + Name: opUpdateCloudFrontOriginAccessIdentity, + HTTPMethod: "PUT", + HTTPPath: "/2017-10-30/origin-access-identity/cloudfront/{Id}/config", + } + + if input == nil { + input = &UpdateCloudFrontOriginAccessIdentityInput{} + } + + output = &UpdateCloudFrontOriginAccessIdentityOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateCloudFrontOriginAccessIdentity API operation for Amazon CloudFront. +// +// Update an origin access identity. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon CloudFront's +// API operation UpdateCloudFrontOriginAccessIdentity for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDenied "AccessDenied" +// Access denied. +// +// * ErrCodeIllegalUpdate "IllegalUpdate" +// Origin and CallerReference cannot be updated. +// +// * ErrCodeInvalidIfMatchVersion "InvalidIfMatchVersion" +// The If-Match version is missing or not valid for the distribution. +// +// * ErrCodeMissingBody "MissingBody" +// This operation requires a body. Ensure that the body is present and the Content-Type +// header is set. +// +// * ErrCodeNoSuchCloudFrontOriginAccessIdentity "NoSuchCloudFrontOriginAccessIdentity" +// The specified origin access identity does not exist. +// +// * ErrCodePreconditionFailed "PreconditionFailed" +// The precondition given in one or more of the request-header fields evaluated +// to false. +// +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. +// +// * ErrCodeInconsistentQuantities "InconsistentQuantities" +// The value of Quantity and the size of Items don't match. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/UpdateCloudFrontOriginAccessIdentity +func (c *CloudFront) UpdateCloudFrontOriginAccessIdentity(input *UpdateCloudFrontOriginAccessIdentityInput) (*UpdateCloudFrontOriginAccessIdentityOutput, error) { + req, out := c.UpdateCloudFrontOriginAccessIdentityRequest(input) + return out, req.Send() +} + +// UpdateCloudFrontOriginAccessIdentityWithContext is the same as UpdateCloudFrontOriginAccessIdentity with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateCloudFrontOriginAccessIdentity for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) UpdateCloudFrontOriginAccessIdentityWithContext(ctx aws.Context, input *UpdateCloudFrontOriginAccessIdentityInput, opts ...request.Option) (*UpdateCloudFrontOriginAccessIdentityOutput, error) { + req, out := c.UpdateCloudFrontOriginAccessIdentityRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateDistribution = "UpdateDistribution2017_10_30" + +// UpdateDistributionRequest generates a "aws/request.Request" representing the +// client's request for the UpdateDistribution operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateDistribution for more information on using the UpdateDistribution +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the UpdateDistributionRequest method. +// req, resp := client.UpdateDistributionRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/UpdateDistribution +func (c *CloudFront) UpdateDistributionRequest(input *UpdateDistributionInput) (req *request.Request, output *UpdateDistributionOutput) { + op := &request.Operation{ + Name: opUpdateDistribution, + HTTPMethod: "PUT", + HTTPPath: "/2017-10-30/distribution/{Id}/config", + } + + if input == nil { + input = &UpdateDistributionInput{} + } + + output = &UpdateDistributionOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateDistribution API operation for Amazon CloudFront. +// +// Updates the configuration for a web distribution. Perform the following steps. +// +// For information about updating a distribution using the CloudFront console, +// see Creating or Updating a Web Distribution Using the CloudFront Console +// (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/distribution-web-creating-console.html) +// in the Amazon CloudFront Developer Guide. +// +// To update a web distribution using the CloudFront API +// +// Submit a GetDistributionConfig request to get the current configuration and +// an Etag header for the distribution. +// +// If you update the distribution again, you need to get a new Etag header. +// +// Update the XML document that was returned in the response to your GetDistributionConfig +// request to include the desired changes. You can't change the value of CallerReference. +// If you try to change this value, CloudFront returns an IllegalUpdate error. +// +// The new configuration replaces the existing configuration; the values that +// you specify in an UpdateDistribution request are not merged into the existing +// configuration. When you add, delete, or replace values in an element that +// allows multiple values (for example, CNAME), you must specify all of the +// values that you want to appear in the updated distribution. In addition, +// you must update the corresponding Quantity element. +// +// Submit an UpdateDistribution request to update the configuration for your +// distribution: +// +// In the request body, include the XML document that you updated in Step 2. +// The request body must include an XML document with a DistributionConfig element. +// +// Set the value of the HTTP If-Match header to the value of the ETag header +// that CloudFront returned when you submitted the GetDistributionConfig request +// in Step 1. +// +// Review the response to the UpdateDistribution request to confirm that the +// configuration was successfully updated. +// +// Optional: Submit a GetDistribution request to confirm that your changes have +// propagated. When propagation is complete, the value of Status is Deployed. +// +// Beginning with the 2012-05-05 version of the CloudFront API, we made substantial +// changes to the format of the XML document that you include in the request +// body when you create or update a distribution. With previous versions of +// the API, we discovered that it was too easy to accidentally delete one or +// more values for an element that accepts multiple values, for example, CNAMEs +// and trusted signers. Our changes for the 2012-05-05 release are intended +// to prevent these accidental deletions and to notify you when there's a mismatch +// between the number of values you say you're specifying in the Quantity element +// and the number of values you're actually specifying. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon CloudFront's +// API operation UpdateDistribution for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDenied "AccessDenied" +// Access denied. +// +// * ErrCodeCNAMEAlreadyExists "CNAMEAlreadyExists" +// +// * ErrCodeIllegalUpdate "IllegalUpdate" +// Origin and CallerReference cannot be updated. +// +// * ErrCodeInvalidIfMatchVersion "InvalidIfMatchVersion" +// The If-Match version is missing or not valid for the distribution. +// +// * ErrCodeMissingBody "MissingBody" +// This operation requires a body. Ensure that the body is present and the Content-Type +// header is set. +// +// * ErrCodeNoSuchDistribution "NoSuchDistribution" +// The specified distribution does not exist. +// +// * ErrCodePreconditionFailed "PreconditionFailed" +// The precondition given in one or more of the request-header fields evaluated +// to false. +// +// * ErrCodeTooManyDistributionCNAMEs "TooManyDistributionCNAMEs" +// Your request contains more CNAMEs than are allowed per distribution. +// +// * ErrCodeInvalidDefaultRootObject "InvalidDefaultRootObject" +// The default root object file name is too big or contains an invalid character. +// +// * ErrCodeInvalidRelativePath "InvalidRelativePath" +// The relative path is too big, is not URL-encoded, or does not begin with +// a slash (/). +// +// * ErrCodeInvalidErrorCode "InvalidErrorCode" +// +// * ErrCodeInvalidResponseCode "InvalidResponseCode" +// +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. +// +// * ErrCodeInvalidOriginAccessIdentity "InvalidOriginAccessIdentity" +// The origin access identity is not valid or doesn't exist. +// +// * ErrCodeTooManyTrustedSigners "TooManyTrustedSigners" +// Your request contains more trusted signers than are allowed per distribution. +// +// * ErrCodeTrustedSignerDoesNotExist "TrustedSignerDoesNotExist" +// One or more of your trusted signers don't exist. +// +// * ErrCodeInvalidViewerCertificate "InvalidViewerCertificate" +// +// * ErrCodeInvalidMinimumProtocolVersion "InvalidMinimumProtocolVersion" +// +// * ErrCodeInvalidRequiredProtocol "InvalidRequiredProtocol" +// This operation requires the HTTPS protocol. Ensure that you specify the HTTPS +// protocol in your request, or omit the RequiredProtocols element from your +// distribution configuration. +// +// * ErrCodeNoSuchOrigin "NoSuchOrigin" +// No origin exists with the specified Origin Id. +// +// * ErrCodeTooManyOrigins "TooManyOrigins" +// You cannot create more origins for the distribution. +// +// * ErrCodeTooManyCacheBehaviors "TooManyCacheBehaviors" +// You cannot create more cache behaviors for the distribution. +// +// * ErrCodeTooManyCookieNamesInWhiteList "TooManyCookieNamesInWhiteList" +// Your request contains more cookie names in the whitelist than are allowed +// per cache behavior. +// +// * ErrCodeInvalidForwardCookies "InvalidForwardCookies" +// Your request contains forward cookies option which doesn't match with the +// expectation for the whitelisted list of cookie names. Either list of cookie +// names has been specified when not allowed or list of cookie names is missing +// when expected. +// +// * ErrCodeTooManyHeadersInForwardedValues "TooManyHeadersInForwardedValues" +// +// * ErrCodeInvalidHeadersForS3Origin "InvalidHeadersForS3Origin" +// +// * ErrCodeInconsistentQuantities "InconsistentQuantities" +// The value of Quantity and the size of Items don't match. +// +// * ErrCodeTooManyCertificates "TooManyCertificates" +// You cannot create anymore custom SSL/TLS certificates. +// +// * ErrCodeInvalidLocationCode "InvalidLocationCode" +// +// * ErrCodeInvalidGeoRestrictionParameter "InvalidGeoRestrictionParameter" +// +// * ErrCodeInvalidTTLOrder "InvalidTTLOrder" +// +// * ErrCodeInvalidWebACLId "InvalidWebACLId" +// +// * ErrCodeTooManyOriginCustomHeaders "TooManyOriginCustomHeaders" +// +// * ErrCodeTooManyQueryStringParameters "TooManyQueryStringParameters" +// +// * ErrCodeInvalidQueryStringParameters "InvalidQueryStringParameters" +// +// * ErrCodeTooManyDistributionsWithLambdaAssociations "TooManyDistributionsWithLambdaAssociations" +// Processing your request would cause the maximum number of distributions with +// Lambda function associations per owner to be exceeded. +// +// * ErrCodeTooManyLambdaFunctionAssociations "TooManyLambdaFunctionAssociations" +// Your request contains more Lambda function associations than are allowed +// per distribution. +// +// * ErrCodeInvalidLambdaFunctionAssociation "InvalidLambdaFunctionAssociation" +// The specified Lambda function association is invalid. +// +// * ErrCodeInvalidOriginReadTimeout "InvalidOriginReadTimeout" +// +// * ErrCodeInvalidOriginKeepaliveTimeout "InvalidOriginKeepaliveTimeout" +// +// * ErrCodeNoSuchFieldLevelEncryptionConfig "NoSuchFieldLevelEncryptionConfig" +// The specified configuration for field-level encryption doesn't exist. +// +// * ErrCodeIllegalFieldLevelEncryptionConfigAssociationWithCacheBehavior "IllegalFieldLevelEncryptionConfigAssociationWithCacheBehavior" +// The specified configuration for field-level encryption can't be associated +// with the specified cache behavior. +// +// * ErrCodeTooManyDistributionsAssociatedToFieldLevelEncryptionConfig "TooManyDistributionsAssociatedToFieldLevelEncryptionConfig" +// The maximum number of distributions have been associated with the specified +// configuration for field-level encryption. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/UpdateDistribution +func (c *CloudFront) UpdateDistribution(input *UpdateDistributionInput) (*UpdateDistributionOutput, error) { + req, out := c.UpdateDistributionRequest(input) + return out, req.Send() +} + +// UpdateDistributionWithContext is the same as UpdateDistribution with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateDistribution for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) UpdateDistributionWithContext(ctx aws.Context, input *UpdateDistributionInput, opts ...request.Option) (*UpdateDistributionOutput, error) { + req, out := c.UpdateDistributionRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateFieldLevelEncryptionConfig = "UpdateFieldLevelEncryptionConfig2017_10_30" + +// UpdateFieldLevelEncryptionConfigRequest generates a "aws/request.Request" representing the +// client's request for the UpdateFieldLevelEncryptionConfig operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateFieldLevelEncryptionConfig for more information on using the UpdateFieldLevelEncryptionConfig +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the UpdateFieldLevelEncryptionConfigRequest method. +// req, resp := client.UpdateFieldLevelEncryptionConfigRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/UpdateFieldLevelEncryptionConfig +func (c *CloudFront) UpdateFieldLevelEncryptionConfigRequest(input *UpdateFieldLevelEncryptionConfigInput) (req *request.Request, output *UpdateFieldLevelEncryptionConfigOutput) { + op := &request.Operation{ + Name: opUpdateFieldLevelEncryptionConfig, + HTTPMethod: "PUT", + HTTPPath: "/2017-10-30/field-level-encryption/{Id}/config", + } + + if input == nil { + input = &UpdateFieldLevelEncryptionConfigInput{} + } + + output = &UpdateFieldLevelEncryptionConfigOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateFieldLevelEncryptionConfig API operation for Amazon CloudFront. +// +// Update a field-level encryption configuration. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon CloudFront's +// API operation UpdateFieldLevelEncryptionConfig for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDenied "AccessDenied" +// Access denied. +// +// * ErrCodeIllegalUpdate "IllegalUpdate" +// Origin and CallerReference cannot be updated. +// +// * ErrCodeInconsistentQuantities "InconsistentQuantities" +// The value of Quantity and the size of Items don't match. +// +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. +// +// * ErrCodeInvalidIfMatchVersion "InvalidIfMatchVersion" +// The If-Match version is missing or not valid for the distribution. +// +// * ErrCodeNoSuchFieldLevelEncryptionProfile "NoSuchFieldLevelEncryptionProfile" +// The specified profile for field-level encryption doesn't exist. +// +// * ErrCodeNoSuchFieldLevelEncryptionConfig "NoSuchFieldLevelEncryptionConfig" +// The specified configuration for field-level encryption doesn't exist. +// +// * ErrCodePreconditionFailed "PreconditionFailed" +// The precondition given in one or more of the request-header fields evaluated +// to false. +// +// * ErrCodeTooManyFieldLevelEncryptionQueryArgProfiles "TooManyFieldLevelEncryptionQueryArgProfiles" +// The maximum number of query arg profiles for field-level encryption have +// been created. +// +// * ErrCodeTooManyFieldLevelEncryptionContentTypeProfiles "TooManyFieldLevelEncryptionContentTypeProfiles" +// The maximum number of content type profiles for field-level encryption have +// been created. +// +// * ErrCodeQueryArgProfileEmpty "QueryArgProfileEmpty" +// No profile specified for the field-level encryption query argument. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/UpdateFieldLevelEncryptionConfig +func (c *CloudFront) UpdateFieldLevelEncryptionConfig(input *UpdateFieldLevelEncryptionConfigInput) (*UpdateFieldLevelEncryptionConfigOutput, error) { + req, out := c.UpdateFieldLevelEncryptionConfigRequest(input) + return out, req.Send() +} + +// UpdateFieldLevelEncryptionConfigWithContext is the same as UpdateFieldLevelEncryptionConfig with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateFieldLevelEncryptionConfig for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) UpdateFieldLevelEncryptionConfigWithContext(ctx aws.Context, input *UpdateFieldLevelEncryptionConfigInput, opts ...request.Option) (*UpdateFieldLevelEncryptionConfigOutput, error) { + req, out := c.UpdateFieldLevelEncryptionConfigRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateFieldLevelEncryptionProfile = "UpdateFieldLevelEncryptionProfile2017_10_30" + +// UpdateFieldLevelEncryptionProfileRequest generates a "aws/request.Request" representing the +// client's request for the UpdateFieldLevelEncryptionProfile operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateFieldLevelEncryptionProfile for more information on using the UpdateFieldLevelEncryptionProfile +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the UpdateFieldLevelEncryptionProfileRequest method. +// req, resp := client.UpdateFieldLevelEncryptionProfileRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/UpdateFieldLevelEncryptionProfile +func (c *CloudFront) UpdateFieldLevelEncryptionProfileRequest(input *UpdateFieldLevelEncryptionProfileInput) (req *request.Request, output *UpdateFieldLevelEncryptionProfileOutput) { + op := &request.Operation{ + Name: opUpdateFieldLevelEncryptionProfile, + HTTPMethod: "PUT", + HTTPPath: "/2017-10-30/field-level-encryption-profile/{Id}/config", + } + + if input == nil { + input = &UpdateFieldLevelEncryptionProfileInput{} + } + + output = &UpdateFieldLevelEncryptionProfileOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateFieldLevelEncryptionProfile API operation for Amazon CloudFront. +// +// Update a field-level encryption profile. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon CloudFront's +// API operation UpdateFieldLevelEncryptionProfile for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDenied "AccessDenied" +// Access denied. +// +// * ErrCodeFieldLevelEncryptionProfileAlreadyExists "FieldLevelEncryptionProfileAlreadyExists" +// The specified profile for field-level encryption already exists. +// +// * ErrCodeIllegalUpdate "IllegalUpdate" +// Origin and CallerReference cannot be updated. +// +// * ErrCodeInconsistentQuantities "InconsistentQuantities" +// The value of Quantity and the size of Items don't match. +// +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. +// +// * ErrCodeInvalidIfMatchVersion "InvalidIfMatchVersion" +// The If-Match version is missing or not valid for the distribution. +// +// * ErrCodeNoSuchPublicKey "NoSuchPublicKey" +// The specified public key doesn't exist. +// +// * ErrCodeNoSuchFieldLevelEncryptionProfile "NoSuchFieldLevelEncryptionProfile" +// The specified profile for field-level encryption doesn't exist. +// +// * ErrCodePreconditionFailed "PreconditionFailed" +// The precondition given in one or more of the request-header fields evaluated +// to false. +// +// * ErrCodeFieldLevelEncryptionProfileSizeExceeded "FieldLevelEncryptionProfileSizeExceeded" +// The maximum size of a profile for field-level encryption was exceeded. +// +// * ErrCodeTooManyFieldLevelEncryptionEncryptionEntities "TooManyFieldLevelEncryptionEncryptionEntities" +// The maximum number of encryption entities for field-level encryption have +// been created. +// +// * ErrCodeTooManyFieldLevelEncryptionFieldPatterns "TooManyFieldLevelEncryptionFieldPatterns" +// The maximum number of field patterns for field-level encryption have been +// created. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/UpdateFieldLevelEncryptionProfile +func (c *CloudFront) UpdateFieldLevelEncryptionProfile(input *UpdateFieldLevelEncryptionProfileInput) (*UpdateFieldLevelEncryptionProfileOutput, error) { + req, out := c.UpdateFieldLevelEncryptionProfileRequest(input) + return out, req.Send() +} + +// UpdateFieldLevelEncryptionProfileWithContext is the same as UpdateFieldLevelEncryptionProfile with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateFieldLevelEncryptionProfile for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) UpdateFieldLevelEncryptionProfileWithContext(ctx aws.Context, input *UpdateFieldLevelEncryptionProfileInput, opts ...request.Option) (*UpdateFieldLevelEncryptionProfileOutput, error) { + req, out := c.UpdateFieldLevelEncryptionProfileRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdatePublicKey = "UpdatePublicKey2017_10_30" + +// UpdatePublicKeyRequest generates a "aws/request.Request" representing the +// client's request for the UpdatePublicKey operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdatePublicKey for more information on using the UpdatePublicKey +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the UpdatePublicKeyRequest method. +// req, resp := client.UpdatePublicKeyRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/UpdatePublicKey +func (c *CloudFront) UpdatePublicKeyRequest(input *UpdatePublicKeyInput) (req *request.Request, output *UpdatePublicKeyOutput) { + op := &request.Operation{ + Name: opUpdatePublicKey, + HTTPMethod: "PUT", + HTTPPath: "/2017-10-30/public-key/{Id}/config", + } + + if input == nil { + input = &UpdatePublicKeyInput{} + } + + output = &UpdatePublicKeyOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdatePublicKey API operation for Amazon CloudFront. +// +// Update public key information. Note that the only value you can change is +// the comment. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon CloudFront's +// API operation UpdatePublicKey for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDenied "AccessDenied" +// Access denied. +// +// * ErrCodeCannotChangeImmutablePublicKeyFields "CannotChangeImmutablePublicKeyFields" +// You can't change the value of a public key. +// +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. +// +// * ErrCodeInvalidIfMatchVersion "InvalidIfMatchVersion" +// The If-Match version is missing or not valid for the distribution. +// +// * ErrCodeIllegalUpdate "IllegalUpdate" +// Origin and CallerReference cannot be updated. +// +// * ErrCodeNoSuchPublicKey "NoSuchPublicKey" +// The specified public key doesn't exist. +// +// * ErrCodePreconditionFailed "PreconditionFailed" +// The precondition given in one or more of the request-header fields evaluated +// to false. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/UpdatePublicKey +func (c *CloudFront) UpdatePublicKey(input *UpdatePublicKeyInput) (*UpdatePublicKeyOutput, error) { + req, out := c.UpdatePublicKeyRequest(input) + return out, req.Send() +} + +// UpdatePublicKeyWithContext is the same as UpdatePublicKey with the addition of +// the ability to pass a context and additional request options. +// +// See UpdatePublicKey for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) UpdatePublicKeyWithContext(ctx aws.Context, input *UpdatePublicKeyInput, opts ...request.Option) (*UpdatePublicKeyOutput, error) { + req, out := c.UpdatePublicKeyRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateStreamingDistribution = "UpdateStreamingDistribution2017_10_30" + +// UpdateStreamingDistributionRequest generates a "aws/request.Request" representing the +// client's request for the UpdateStreamingDistribution operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateStreamingDistribution for more information on using the UpdateStreamingDistribution +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the UpdateStreamingDistributionRequest method. +// req, resp := client.UpdateStreamingDistributionRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/UpdateStreamingDistribution +func (c *CloudFront) UpdateStreamingDistributionRequest(input *UpdateStreamingDistributionInput) (req *request.Request, output *UpdateStreamingDistributionOutput) { + op := &request.Operation{ + Name: opUpdateStreamingDistribution, + HTTPMethod: "PUT", + HTTPPath: "/2017-10-30/streaming-distribution/{Id}/config", + } + + if input == nil { + input = &UpdateStreamingDistributionInput{} + } + + output = &UpdateStreamingDistributionOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateStreamingDistribution API operation for Amazon CloudFront. +// +// Update a streaming distribution. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon CloudFront's +// API operation UpdateStreamingDistribution for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDenied "AccessDenied" +// Access denied. +// +// * ErrCodeCNAMEAlreadyExists "CNAMEAlreadyExists" +// +// * ErrCodeIllegalUpdate "IllegalUpdate" +// Origin and CallerReference cannot be updated. +// +// * ErrCodeInvalidIfMatchVersion "InvalidIfMatchVersion" +// The If-Match version is missing or not valid for the distribution. +// +// * ErrCodeMissingBody "MissingBody" +// This operation requires a body. Ensure that the body is present and the Content-Type +// header is set. +// +// * ErrCodeNoSuchStreamingDistribution "NoSuchStreamingDistribution" +// The specified streaming distribution does not exist. +// +// * ErrCodePreconditionFailed "PreconditionFailed" +// The precondition given in one or more of the request-header fields evaluated +// to false. +// +// * ErrCodeTooManyStreamingDistributionCNAMEs "TooManyStreamingDistributionCNAMEs" +// +// * ErrCodeInvalidArgument "InvalidArgument" +// The argument is invalid. +// +// * ErrCodeInvalidOriginAccessIdentity "InvalidOriginAccessIdentity" +// The origin access identity is not valid or doesn't exist. +// +// * ErrCodeTooManyTrustedSigners "TooManyTrustedSigners" +// Your request contains more trusted signers than are allowed per distribution. +// +// * ErrCodeTrustedSignerDoesNotExist "TrustedSignerDoesNotExist" +// One or more of your trusted signers don't exist. +// +// * ErrCodeInconsistentQuantities "InconsistentQuantities" +// The value of Quantity and the size of Items don't match. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30/UpdateStreamingDistribution +func (c *CloudFront) UpdateStreamingDistribution(input *UpdateStreamingDistributionInput) (*UpdateStreamingDistributionOutput, error) { + req, out := c.UpdateStreamingDistributionRequest(input) + return out, req.Send() +} + +// UpdateStreamingDistributionWithContext is the same as UpdateStreamingDistribution with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateStreamingDistribution for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudFront) UpdateStreamingDistributionWithContext(ctx aws.Context, input *UpdateStreamingDistributionInput, opts ...request.Option) (*UpdateStreamingDistributionOutput, error) { + req, out := c.UpdateStreamingDistributionRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// A complex type that lists the AWS accounts, if any, that you included in +// the TrustedSigners complex type for this distribution. These are the accounts +// that you want to allow to create signed URLs for private content. +// +// The Signer complex type lists the AWS account number of the trusted signer +// or self if the signer is the AWS account that created the distribution. The +// Signer element also includes the IDs of any active CloudFront key pairs that +// are associated with the trusted signer's AWS account. If no KeyPairId element +// appears for a Signer, that signer can't create signed URLs. +// +// For more information, see Serving Private Content through CloudFront (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/PrivateContent.html) +// in the Amazon CloudFront Developer Guide. +type ActiveTrustedSigners struct { + _ struct{} `type:"structure"` + + // Enabled is true if any of the AWS accounts listed in the TrustedSigners complex + // type for this RTMP distribution have active CloudFront key pairs. If not, + // Enabled is false. + // + // For more information, see ActiveTrustedSigners. + // + // Enabled is a required field + Enabled *bool `type:"boolean" required:"true"` + + // A complex type that contains one Signer complex type for each trusted signer + // that is specified in the TrustedSigners complex type. + // + // For more information, see ActiveTrustedSigners. + Items []*Signer `locationNameList:"Signer" type:"list"` + + // A complex type that contains one Signer complex type for each trusted signer + // specified in the TrustedSigners complex type. + // + // For more information, see ActiveTrustedSigners. + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` +} + +// String returns the string representation +func (s ActiveTrustedSigners) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ActiveTrustedSigners) GoString() string { + return s.String() +} + +// SetEnabled sets the Enabled field's value. +func (s *ActiveTrustedSigners) SetEnabled(v bool) *ActiveTrustedSigners { + s.Enabled = &v + return s +} + +// SetItems sets the Items field's value. +func (s *ActiveTrustedSigners) SetItems(v []*Signer) *ActiveTrustedSigners { + s.Items = v + return s +} + +// SetQuantity sets the Quantity field's value. +func (s *ActiveTrustedSigners) SetQuantity(v int64) *ActiveTrustedSigners { + s.Quantity = &v + return s +} + +// A complex type that contains information about CNAMEs (alternate domain names), +// if any, for this distribution. +type Aliases struct { + _ struct{} `type:"structure"` + + // A complex type that contains the CNAME aliases, if any, that you want to + // associate with this distribution. + Items []*string `locationNameList:"CNAME" type:"list"` + + // The number of CNAME aliases, if any, that you want to associate with this + // distribution. + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` +} + +// String returns the string representation +func (s Aliases) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s Aliases) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *Aliases) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "Aliases"} + if s.Quantity == nil { + invalidParams.Add(request.NewErrParamRequired("Quantity")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetItems sets the Items field's value. +func (s *Aliases) SetItems(v []*string) *Aliases { + s.Items = v + return s +} + +// SetQuantity sets the Quantity field's value. +func (s *Aliases) SetQuantity(v int64) *Aliases { + s.Quantity = &v + return s +} + +// A complex type that controls which HTTP methods CloudFront processes and +// forwards to your Amazon S3 bucket or your custom origin. There are three +// choices: +// +// * CloudFront forwards only GET and HEAD requests. +// +// * CloudFront forwards only GET, HEAD, and OPTIONS requests. +// +// * CloudFront forwards GET, HEAD, OPTIONS, PUT, PATCH, POST, and DELETE +// requests. +// +// If you pick the third choice, you may need to restrict access to your Amazon +// S3 bucket or to your custom origin so users can't perform operations that +// you don't want them to. For example, you might not want users to have permissions +// to delete objects from your origin. +type AllowedMethods struct { + _ struct{} `type:"structure"` + + // A complex type that controls whether CloudFront caches the response to requests + // using the specified HTTP methods. There are two choices: + // + // * CloudFront caches responses to GET and HEAD requests. + // + // * CloudFront caches responses to GET, HEAD, and OPTIONS requests. + // + // If you pick the second choice for your Amazon S3 Origin, you may need to + // forward Access-Control-Request-Method, Access-Control-Request-Headers, and + // Origin headers for the responses to be cached correctly. + CachedMethods *CachedMethods `type:"structure"` + + // A complex type that contains the HTTP methods that you want CloudFront to + // process and forward to your origin. + // + // Items is a required field + Items []*string `locationNameList:"Method" type:"list" required:"true"` + + // The number of HTTP methods that you want CloudFront to forward to your origin. + // Valid values are 2 (for GET and HEAD requests), 3 (for GET, HEAD, and OPTIONS + // requests) and 7 (for GET, HEAD, OPTIONS, PUT, PATCH, POST, and DELETE requests). + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` +} + +// String returns the string representation +func (s AllowedMethods) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s AllowedMethods) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *AllowedMethods) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "AllowedMethods"} + if s.Items == nil { + invalidParams.Add(request.NewErrParamRequired("Items")) + } + if s.Quantity == nil { + invalidParams.Add(request.NewErrParamRequired("Quantity")) + } + if s.CachedMethods != nil { + if err := s.CachedMethods.Validate(); err != nil { + invalidParams.AddNested("CachedMethods", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetCachedMethods sets the CachedMethods field's value. +func (s *AllowedMethods) SetCachedMethods(v *CachedMethods) *AllowedMethods { + s.CachedMethods = v + return s +} + +// SetItems sets the Items field's value. +func (s *AllowedMethods) SetItems(v []*string) *AllowedMethods { + s.Items = v + return s +} + +// SetQuantity sets the Quantity field's value. +func (s *AllowedMethods) SetQuantity(v int64) *AllowedMethods { + s.Quantity = &v + return s +} + +// A complex type that describes how CloudFront processes requests. +// +// You must create at least as many cache behaviors (including the default cache +// behavior) as you have origins if you want CloudFront to distribute objects +// from all of the origins. Each cache behavior specifies the one origin from +// which you want CloudFront to get objects. If you have two origins and only +// the default cache behavior, the default cache behavior will cause CloudFront +// to get objects from one of the origins, but the other origin is never used. +// +// For the current limit on the number of cache behaviors that you can add to +// a distribution, see Amazon CloudFront Limits (http://docs.aws.amazon.com/general/latest/gr/aws_service_limits.html#limits_cloudfront) +// in the AWS General Reference. +// +// If you don't want to specify any cache behaviors, include only an empty CacheBehaviors +// element. Don't include an empty CacheBehavior element, or CloudFront returns +// a MalformedXML error. +// +// To delete all cache behaviors in an existing distribution, update the distribution +// configuration and include only an empty CacheBehaviors element. +// +// To add, change, or remove one or more cache behaviors, update the distribution // configuration and specify all of the cache behaviors that you want to include // in the updated distribution. // -// For more information about cache behaviors, see Cache Behaviors (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/distribution-web-values-specify.html#DownloadDistValuesCacheBehavior) +// For more information about cache behaviors, see Cache Behaviors (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/distribution-web-values-specify.html#DownloadDistValuesCacheBehavior) +// in the Amazon CloudFront Developer Guide. +type CacheBehavior struct { + _ struct{} `type:"structure"` + + // A complex type that controls which HTTP methods CloudFront processes and + // forwards to your Amazon S3 bucket or your custom origin. There are three + // choices: + // + // * CloudFront forwards only GET and HEAD requests. + // + // * CloudFront forwards only GET, HEAD, and OPTIONS requests. + // + // * CloudFront forwards GET, HEAD, OPTIONS, PUT, PATCH, POST, and DELETE + // requests. + // + // If you pick the third choice, you may need to restrict access to your Amazon + // S3 bucket or to your custom origin so users can't perform operations that + // you don't want them to. For example, you might not want users to have permissions + // to delete objects from your origin. + AllowedMethods *AllowedMethods `type:"structure"` + + // Whether you want CloudFront to automatically compress certain files for this + // cache behavior. If so, specify true; if not, specify false. For more information, + // see Serving Compressed Files (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/ServingCompressedFiles.html) + // in the Amazon CloudFront Developer Guide. + Compress *bool `type:"boolean"` + + // The default amount of time that you want objects to stay in CloudFront caches + // before CloudFront forwards another request to your origin to determine whether + // the object has been updated. The value that you specify applies only when + // your origin does not add HTTP headers such as Cache-Control max-age, Cache-Control + // s-maxage, and Expires to objects. For more information, see Specifying How + // Long Objects and Errors Stay in a CloudFront Edge Cache (Expiration) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html) + // in the Amazon CloudFront Developer Guide. + DefaultTTL *int64 `type:"long"` + + FieldLevelEncryptionId *string `type:"string"` + + // A complex type that specifies how CloudFront handles query strings and cookies. + // + // ForwardedValues is a required field + ForwardedValues *ForwardedValues `type:"structure" required:"true"` + + // A complex type that contains zero or more Lambda function associations for + // a cache behavior. + LambdaFunctionAssociations *LambdaFunctionAssociations `type:"structure"` + + // The maximum amount of time that you want objects to stay in CloudFront caches + // before CloudFront forwards another request to your origin to determine whether + // the object has been updated. The value that you specify applies only when + // your origin adds HTTP headers such as Cache-Control max-age, Cache-Control + // s-maxage, and Expires to objects. For more information, see Specifying How + // Long Objects and Errors Stay in a CloudFront Edge Cache (Expiration) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html) + // in the Amazon CloudFront Developer Guide. + MaxTTL *int64 `type:"long"` + + // The minimum amount of time that you want objects to stay in CloudFront caches + // before CloudFront forwards another request to your origin to determine whether + // the object has been updated. For more information, see Specifying How Long + // Objects and Errors Stay in a CloudFront Edge Cache (Expiration) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html) + // in the Amazon Amazon CloudFront Developer Guide. + // + // You must specify 0 for MinTTL if you configure CloudFront to forward all + // headers to your origin (under Headers, if you specify 1 for Quantity and + // * for Name). + // + // MinTTL is a required field + MinTTL *int64 `type:"long" required:"true"` + + // The pattern (for example, images/*.jpg) that specifies which requests to + // apply the behavior to. When CloudFront receives a viewer request, the requested + // path is compared with path patterns in the order in which cache behaviors + // are listed in the distribution. + // + // You can optionally include a slash (/) at the beginning of the path pattern. + // For example, /images/*.jpg. CloudFront behavior is the same with or without + // the leading /. + // + // The path pattern for the default cache behavior is * and cannot be changed. + // If the request for an object does not match the path pattern for any cache + // behaviors, CloudFront applies the behavior in the default cache behavior. + // + // For more information, see Path Pattern (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/distribution-web-values-specify.html#DownloadDistValuesPathPattern) + // in the Amazon CloudFront Developer Guide. + // + // PathPattern is a required field + PathPattern *string `type:"string" required:"true"` + + // Indicates whether you want to distribute media files in the Microsoft Smooth + // Streaming format using the origin that is associated with this cache behavior. + // If so, specify true; if not, specify false. If you specify true for SmoothStreaming, + // you can still distribute other content using this cache behavior if the content + // matches the value of PathPattern. + SmoothStreaming *bool `type:"boolean"` + + // The value of ID for the origin that you want CloudFront to route requests + // to when a request matches the path pattern either for a cache behavior or + // for the default cache behavior. + // + // TargetOriginId is a required field + TargetOriginId *string `type:"string" required:"true"` + + // A complex type that specifies the AWS accounts, if any, that you want to + // allow to create signed URLs for private content. + // + // If you want to require signed URLs in requests for objects in the target + // origin that match the PathPattern for this cache behavior, specify true for + // Enabled, and specify the applicable values for Quantity and Items. For more + // information, see Serving Private Content through CloudFront (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/PrivateContent.html) + // in the Amazon Amazon CloudFront Developer Guide. + // + // If you don't want to require signed URLs in requests for objects that match + // PathPattern, specify false for Enabled and 0 for Quantity. Omit Items. + // + // To add, change, or remove one or more trusted signers, change Enabled to + // true (if it's currently false), change Quantity as applicable, and specify + // all of the trusted signers that you want to include in the updated distribution. + // + // TrustedSigners is a required field + TrustedSigners *TrustedSigners `type:"structure" required:"true"` + + // The protocol that viewers can use to access the files in the origin specified + // by TargetOriginId when a request matches the path pattern in PathPattern. + // You can specify the following options: + // + // * allow-all: Viewers can use HTTP or HTTPS. + // + // * redirect-to-https: If a viewer submits an HTTP request, CloudFront returns + // an HTTP status code of 301 (Moved Permanently) to the viewer along with + // the HTTPS URL. The viewer then resubmits the request using the new URL. + // + // + // * https-only: If a viewer sends an HTTP request, CloudFront returns an + // HTTP status code of 403 (Forbidden). + // + // For more information about requiring the HTTPS protocol, see Using an HTTPS + // Connection to Access Your Objects (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/SecureConnections.html) + // in the Amazon CloudFront Developer Guide. + // + // The only way to guarantee that viewers retrieve an object that was fetched + // from the origin using HTTPS is never to use any other protocol to fetch the + // object. If you have recently changed from HTTP to HTTPS, we recommend that + // you clear your objects' cache because cached objects are protocol agnostic. + // That means that an edge location will return an object from the cache regardless + // of whether the current request protocol matches the protocol used previously. + // For more information, see Specifying How Long Objects and Errors Stay in + // a CloudFront Edge Cache (Expiration) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html) + // in the Amazon CloudFront Developer Guide. + // + // ViewerProtocolPolicy is a required field + ViewerProtocolPolicy *string `type:"string" required:"true" enum:"ViewerProtocolPolicy"` +} + +// String returns the string representation +func (s CacheBehavior) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CacheBehavior) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CacheBehavior) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CacheBehavior"} + if s.ForwardedValues == nil { + invalidParams.Add(request.NewErrParamRequired("ForwardedValues")) + } + if s.MinTTL == nil { + invalidParams.Add(request.NewErrParamRequired("MinTTL")) + } + if s.PathPattern == nil { + invalidParams.Add(request.NewErrParamRequired("PathPattern")) + } + if s.TargetOriginId == nil { + invalidParams.Add(request.NewErrParamRequired("TargetOriginId")) + } + if s.TrustedSigners == nil { + invalidParams.Add(request.NewErrParamRequired("TrustedSigners")) + } + if s.ViewerProtocolPolicy == nil { + invalidParams.Add(request.NewErrParamRequired("ViewerProtocolPolicy")) + } + if s.AllowedMethods != nil { + if err := s.AllowedMethods.Validate(); err != nil { + invalidParams.AddNested("AllowedMethods", err.(request.ErrInvalidParams)) + } + } + if s.ForwardedValues != nil { + if err := s.ForwardedValues.Validate(); err != nil { + invalidParams.AddNested("ForwardedValues", err.(request.ErrInvalidParams)) + } + } + if s.LambdaFunctionAssociations != nil { + if err := s.LambdaFunctionAssociations.Validate(); err != nil { + invalidParams.AddNested("LambdaFunctionAssociations", err.(request.ErrInvalidParams)) + } + } + if s.TrustedSigners != nil { + if err := s.TrustedSigners.Validate(); err != nil { + invalidParams.AddNested("TrustedSigners", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAllowedMethods sets the AllowedMethods field's value. +func (s *CacheBehavior) SetAllowedMethods(v *AllowedMethods) *CacheBehavior { + s.AllowedMethods = v + return s +} + +// SetCompress sets the Compress field's value. +func (s *CacheBehavior) SetCompress(v bool) *CacheBehavior { + s.Compress = &v + return s +} + +// SetDefaultTTL sets the DefaultTTL field's value. +func (s *CacheBehavior) SetDefaultTTL(v int64) *CacheBehavior { + s.DefaultTTL = &v + return s +} + +// SetFieldLevelEncryptionId sets the FieldLevelEncryptionId field's value. +func (s *CacheBehavior) SetFieldLevelEncryptionId(v string) *CacheBehavior { + s.FieldLevelEncryptionId = &v + return s +} + +// SetForwardedValues sets the ForwardedValues field's value. +func (s *CacheBehavior) SetForwardedValues(v *ForwardedValues) *CacheBehavior { + s.ForwardedValues = v + return s +} + +// SetLambdaFunctionAssociations sets the LambdaFunctionAssociations field's value. +func (s *CacheBehavior) SetLambdaFunctionAssociations(v *LambdaFunctionAssociations) *CacheBehavior { + s.LambdaFunctionAssociations = v + return s +} + +// SetMaxTTL sets the MaxTTL field's value. +func (s *CacheBehavior) SetMaxTTL(v int64) *CacheBehavior { + s.MaxTTL = &v + return s +} + +// SetMinTTL sets the MinTTL field's value. +func (s *CacheBehavior) SetMinTTL(v int64) *CacheBehavior { + s.MinTTL = &v + return s +} + +// SetPathPattern sets the PathPattern field's value. +func (s *CacheBehavior) SetPathPattern(v string) *CacheBehavior { + s.PathPattern = &v + return s +} + +// SetSmoothStreaming sets the SmoothStreaming field's value. +func (s *CacheBehavior) SetSmoothStreaming(v bool) *CacheBehavior { + s.SmoothStreaming = &v + return s +} + +// SetTargetOriginId sets the TargetOriginId field's value. +func (s *CacheBehavior) SetTargetOriginId(v string) *CacheBehavior { + s.TargetOriginId = &v + return s +} + +// SetTrustedSigners sets the TrustedSigners field's value. +func (s *CacheBehavior) SetTrustedSigners(v *TrustedSigners) *CacheBehavior { + s.TrustedSigners = v + return s +} + +// SetViewerProtocolPolicy sets the ViewerProtocolPolicy field's value. +func (s *CacheBehavior) SetViewerProtocolPolicy(v string) *CacheBehavior { + s.ViewerProtocolPolicy = &v + return s +} + +// A complex type that contains zero or more CacheBehavior elements. +type CacheBehaviors struct { + _ struct{} `type:"structure"` + + // Optional: A complex type that contains cache behaviors for this distribution. + // If Quantity is 0, you can omit Items. + Items []*CacheBehavior `locationNameList:"CacheBehavior" type:"list"` + + // The number of cache behaviors for this distribution. + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` +} + +// String returns the string representation +func (s CacheBehaviors) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CacheBehaviors) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CacheBehaviors) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CacheBehaviors"} + if s.Quantity == nil { + invalidParams.Add(request.NewErrParamRequired("Quantity")) + } + if s.Items != nil { + for i, v := range s.Items { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Items", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetItems sets the Items field's value. +func (s *CacheBehaviors) SetItems(v []*CacheBehavior) *CacheBehaviors { + s.Items = v + return s +} + +// SetQuantity sets the Quantity field's value. +func (s *CacheBehaviors) SetQuantity(v int64) *CacheBehaviors { + s.Quantity = &v + return s +} + +// A complex type that controls whether CloudFront caches the response to requests +// using the specified HTTP methods. There are two choices: +// +// * CloudFront caches responses to GET and HEAD requests. +// +// * CloudFront caches responses to GET, HEAD, and OPTIONS requests. +// +// If you pick the second choice for your Amazon S3 Origin, you may need to +// forward Access-Control-Request-Method, Access-Control-Request-Headers, and +// Origin headers for the responses to be cached correctly. +type CachedMethods struct { + _ struct{} `type:"structure"` + + // A complex type that contains the HTTP methods that you want CloudFront to + // cache responses to. + // + // Items is a required field + Items []*string `locationNameList:"Method" type:"list" required:"true"` + + // The number of HTTP methods for which you want CloudFront to cache responses. + // Valid values are 2 (for caching responses to GET and HEAD requests) and 3 + // (for caching responses to GET, HEAD, and OPTIONS requests). + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` +} + +// String returns the string representation +func (s CachedMethods) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CachedMethods) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CachedMethods) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CachedMethods"} + if s.Items == nil { + invalidParams.Add(request.NewErrParamRequired("Items")) + } + if s.Quantity == nil { + invalidParams.Add(request.NewErrParamRequired("Quantity")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetItems sets the Items field's value. +func (s *CachedMethods) SetItems(v []*string) *CachedMethods { + s.Items = v + return s +} + +// SetQuantity sets the Quantity field's value. +func (s *CachedMethods) SetQuantity(v int64) *CachedMethods { + s.Quantity = &v + return s +} + +// A field-level encryption content type profile. +type ContentTypeProfile struct { + _ struct{} `type:"structure"` + + // The content type for a field-level encryption content type-profile mapping. + // + // ContentType is a required field + ContentType *string `type:"string" required:"true"` + + // The format for a field-level encryption content type-profile mapping. + // + // Format is a required field + Format *string `type:"string" required:"true" enum:"Format"` + + // The profile ID for a field-level encryption content type-profile mapping. + ProfileId *string `type:"string"` +} + +// String returns the string representation +func (s ContentTypeProfile) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ContentTypeProfile) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ContentTypeProfile) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ContentTypeProfile"} + if s.ContentType == nil { + invalidParams.Add(request.NewErrParamRequired("ContentType")) + } + if s.Format == nil { + invalidParams.Add(request.NewErrParamRequired("Format")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetContentType sets the ContentType field's value. +func (s *ContentTypeProfile) SetContentType(v string) *ContentTypeProfile { + s.ContentType = &v + return s +} + +// SetFormat sets the Format field's value. +func (s *ContentTypeProfile) SetFormat(v string) *ContentTypeProfile { + s.Format = &v + return s +} + +// SetProfileId sets the ProfileId field's value. +func (s *ContentTypeProfile) SetProfileId(v string) *ContentTypeProfile { + s.ProfileId = &v + return s +} + +// The configuration for a field-level encryption content type-profile mapping. +type ContentTypeProfileConfig struct { + _ struct{} `type:"structure"` + + // The configuration for a field-level encryption content type-profile. + ContentTypeProfiles *ContentTypeProfiles `type:"structure"` + + // The setting in a field-level encryption content type-profile mapping that + // specifies what to do when an unknown content type is provided for the profile. + // If true, content is forwarded without being encrypted when the content type + // is unknown. If false (the default), an error is returned when the content + // type is unknown. + // + // ForwardWhenContentTypeIsUnknown is a required field + ForwardWhenContentTypeIsUnknown *bool `type:"boolean" required:"true"` +} + +// String returns the string representation +func (s ContentTypeProfileConfig) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ContentTypeProfileConfig) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ContentTypeProfileConfig) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ContentTypeProfileConfig"} + if s.ForwardWhenContentTypeIsUnknown == nil { + invalidParams.Add(request.NewErrParamRequired("ForwardWhenContentTypeIsUnknown")) + } + if s.ContentTypeProfiles != nil { + if err := s.ContentTypeProfiles.Validate(); err != nil { + invalidParams.AddNested("ContentTypeProfiles", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetContentTypeProfiles sets the ContentTypeProfiles field's value. +func (s *ContentTypeProfileConfig) SetContentTypeProfiles(v *ContentTypeProfiles) *ContentTypeProfileConfig { + s.ContentTypeProfiles = v + return s +} + +// SetForwardWhenContentTypeIsUnknown sets the ForwardWhenContentTypeIsUnknown field's value. +func (s *ContentTypeProfileConfig) SetForwardWhenContentTypeIsUnknown(v bool) *ContentTypeProfileConfig { + s.ForwardWhenContentTypeIsUnknown = &v + return s +} + +// Field-level encryption content type-profile. +type ContentTypeProfiles struct { + _ struct{} `type:"structure"` + + // Items in a field-level encryption content type-profile mapping. + Items []*ContentTypeProfile `locationNameList:"ContentTypeProfile" type:"list"` + + // The number of field-level encryption content type-profile mappings. + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` +} + +// String returns the string representation +func (s ContentTypeProfiles) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ContentTypeProfiles) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ContentTypeProfiles) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ContentTypeProfiles"} + if s.Quantity == nil { + invalidParams.Add(request.NewErrParamRequired("Quantity")) + } + if s.Items != nil { + for i, v := range s.Items { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Items", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetItems sets the Items field's value. +func (s *ContentTypeProfiles) SetItems(v []*ContentTypeProfile) *ContentTypeProfiles { + s.Items = v + return s +} + +// SetQuantity sets the Quantity field's value. +func (s *ContentTypeProfiles) SetQuantity(v int64) *ContentTypeProfiles { + s.Quantity = &v + return s +} + +// A complex type that specifies whether you want CloudFront to forward cookies +// to the origin and, if so, which ones. For more information about forwarding +// cookies to the origin, see How CloudFront Forwards, Caches, and Logs Cookies +// (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Cookies.html) +// in the Amazon CloudFront Developer Guide. +type CookieNames struct { + _ struct{} `type:"structure"` + + // A complex type that contains one Name element for each cookie that you want + // CloudFront to forward to the origin for this cache behavior. + Items []*string `locationNameList:"Name" type:"list"` + + // The number of different cookies that you want CloudFront to forward to the + // origin for this cache behavior. + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` +} + +// String returns the string representation +func (s CookieNames) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CookieNames) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CookieNames) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CookieNames"} + if s.Quantity == nil { + invalidParams.Add(request.NewErrParamRequired("Quantity")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetItems sets the Items field's value. +func (s *CookieNames) SetItems(v []*string) *CookieNames { + s.Items = v + return s +} + +// SetQuantity sets the Quantity field's value. +func (s *CookieNames) SetQuantity(v int64) *CookieNames { + s.Quantity = &v + return s +} + +// A complex type that specifies whether you want CloudFront to forward cookies +// to the origin and, if so, which ones. For more information about forwarding +// cookies to the origin, see How CloudFront Forwards, Caches, and Logs Cookies +// (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Cookies.html) +// in the Amazon CloudFront Developer Guide. +type CookiePreference struct { + _ struct{} `type:"structure"` + + // Specifies which cookies to forward to the origin for this cache behavior: + // all, none, or the list of cookies specified in the WhitelistedNames complex + // type. + // + // Amazon S3 doesn't process cookies. When the cache behavior is forwarding + // requests to an Amazon S3 origin, specify none for the Forward element. + // + // Forward is a required field + Forward *string `type:"string" required:"true" enum:"ItemSelection"` + + // Required if you specify whitelist for the value of Forward:. A complex type + // that specifies how many different cookies you want CloudFront to forward + // to the origin for this cache behavior and, if you want to forward selected + // cookies, the names of those cookies. + // + // If you specify all or none for the value of Forward, omit WhitelistedNames. + // If you change the value of Forward from whitelist to all or none and you + // don't delete the WhitelistedNames element and its child elements, CloudFront + // deletes them automatically. + // + // For the current limit on the number of cookie names that you can whitelist + // for each cache behavior, see Amazon CloudFront Limits (http://docs.aws.amazon.com/general/latest/gr/aws_service_limits.html#limits_cloudfront) + // in the AWS General Reference. + WhitelistedNames *CookieNames `type:"structure"` +} + +// String returns the string representation +func (s CookiePreference) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CookiePreference) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CookiePreference) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CookiePreference"} + if s.Forward == nil { + invalidParams.Add(request.NewErrParamRequired("Forward")) + } + if s.WhitelistedNames != nil { + if err := s.WhitelistedNames.Validate(); err != nil { + invalidParams.AddNested("WhitelistedNames", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetForward sets the Forward field's value. +func (s *CookiePreference) SetForward(v string) *CookiePreference { + s.Forward = &v + return s +} + +// SetWhitelistedNames sets the WhitelistedNames field's value. +func (s *CookiePreference) SetWhitelistedNames(v *CookieNames) *CookiePreference { + s.WhitelistedNames = v + return s +} + +// The request to create a new origin access identity. +type CreateCloudFrontOriginAccessIdentityInput struct { + _ struct{} `type:"structure" payload:"CloudFrontOriginAccessIdentityConfig"` + + // The current configuration information for the identity. + // + // CloudFrontOriginAccessIdentityConfig is a required field + CloudFrontOriginAccessIdentityConfig *OriginAccessIdentityConfig `locationName:"CloudFrontOriginAccessIdentityConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` +} + +// String returns the string representation +func (s CreateCloudFrontOriginAccessIdentityInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateCloudFrontOriginAccessIdentityInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateCloudFrontOriginAccessIdentityInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateCloudFrontOriginAccessIdentityInput"} + if s.CloudFrontOriginAccessIdentityConfig == nil { + invalidParams.Add(request.NewErrParamRequired("CloudFrontOriginAccessIdentityConfig")) + } + if s.CloudFrontOriginAccessIdentityConfig != nil { + if err := s.CloudFrontOriginAccessIdentityConfig.Validate(); err != nil { + invalidParams.AddNested("CloudFrontOriginAccessIdentityConfig", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetCloudFrontOriginAccessIdentityConfig sets the CloudFrontOriginAccessIdentityConfig field's value. +func (s *CreateCloudFrontOriginAccessIdentityInput) SetCloudFrontOriginAccessIdentityConfig(v *OriginAccessIdentityConfig) *CreateCloudFrontOriginAccessIdentityInput { + s.CloudFrontOriginAccessIdentityConfig = v + return s +} + +// The returned result of the corresponding request. +type CreateCloudFrontOriginAccessIdentityOutput struct { + _ struct{} `type:"structure" payload:"CloudFrontOriginAccessIdentity"` + + // The origin access identity's information. + CloudFrontOriginAccessIdentity *OriginAccessIdentity `type:"structure"` + + // The current version of the origin access identity created. + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // The fully qualified URI of the new origin access identity just created. For + // example: https://cloudfront.amazonaws.com/2010-11-01/origin-access-identity/cloudfront/E74FTE3AJFJ256A. + Location *string `location:"header" locationName:"Location" type:"string"` +} + +// String returns the string representation +func (s CreateCloudFrontOriginAccessIdentityOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateCloudFrontOriginAccessIdentityOutput) GoString() string { + return s.String() +} + +// SetCloudFrontOriginAccessIdentity sets the CloudFrontOriginAccessIdentity field's value. +func (s *CreateCloudFrontOriginAccessIdentityOutput) SetCloudFrontOriginAccessIdentity(v *OriginAccessIdentity) *CreateCloudFrontOriginAccessIdentityOutput { + s.CloudFrontOriginAccessIdentity = v + return s +} + +// SetETag sets the ETag field's value. +func (s *CreateCloudFrontOriginAccessIdentityOutput) SetETag(v string) *CreateCloudFrontOriginAccessIdentityOutput { + s.ETag = &v + return s +} + +// SetLocation sets the Location field's value. +func (s *CreateCloudFrontOriginAccessIdentityOutput) SetLocation(v string) *CreateCloudFrontOriginAccessIdentityOutput { + s.Location = &v + return s +} + +// The request to create a new distribution. +type CreateDistributionInput struct { + _ struct{} `type:"structure" payload:"DistributionConfig"` + + // The distribution's configuration information. + // + // DistributionConfig is a required field + DistributionConfig *DistributionConfig `locationName:"DistributionConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` +} + +// String returns the string representation +func (s CreateDistributionInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateDistributionInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateDistributionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateDistributionInput"} + if s.DistributionConfig == nil { + invalidParams.Add(request.NewErrParamRequired("DistributionConfig")) + } + if s.DistributionConfig != nil { + if err := s.DistributionConfig.Validate(); err != nil { + invalidParams.AddNested("DistributionConfig", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDistributionConfig sets the DistributionConfig field's value. +func (s *CreateDistributionInput) SetDistributionConfig(v *DistributionConfig) *CreateDistributionInput { + s.DistributionConfig = v + return s +} + +// The returned result of the corresponding request. +type CreateDistributionOutput struct { + _ struct{} `type:"structure" payload:"Distribution"` + + // The distribution's information. + Distribution *Distribution `type:"structure"` + + // The current version of the distribution created. + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // The fully qualified URI of the new distribution resource just created. For + // example: https://cloudfront.amazonaws.com/2010-11-01/distribution/EDFDVBD632BHDS5. + Location *string `location:"header" locationName:"Location" type:"string"` +} + +// String returns the string representation +func (s CreateDistributionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateDistributionOutput) GoString() string { + return s.String() +} + +// SetDistribution sets the Distribution field's value. +func (s *CreateDistributionOutput) SetDistribution(v *Distribution) *CreateDistributionOutput { + s.Distribution = v + return s +} + +// SetETag sets the ETag field's value. +func (s *CreateDistributionOutput) SetETag(v string) *CreateDistributionOutput { + s.ETag = &v + return s +} + +// SetLocation sets the Location field's value. +func (s *CreateDistributionOutput) SetLocation(v string) *CreateDistributionOutput { + s.Location = &v + return s +} + +// The request to create a new distribution with tags. +type CreateDistributionWithTagsInput struct { + _ struct{} `type:"structure" payload:"DistributionConfigWithTags"` + + // The distribution's configuration information. + // + // DistributionConfigWithTags is a required field + DistributionConfigWithTags *DistributionConfigWithTags `locationName:"DistributionConfigWithTags" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` +} + +// String returns the string representation +func (s CreateDistributionWithTagsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateDistributionWithTagsInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateDistributionWithTagsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateDistributionWithTagsInput"} + if s.DistributionConfigWithTags == nil { + invalidParams.Add(request.NewErrParamRequired("DistributionConfigWithTags")) + } + if s.DistributionConfigWithTags != nil { + if err := s.DistributionConfigWithTags.Validate(); err != nil { + invalidParams.AddNested("DistributionConfigWithTags", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDistributionConfigWithTags sets the DistributionConfigWithTags field's value. +func (s *CreateDistributionWithTagsInput) SetDistributionConfigWithTags(v *DistributionConfigWithTags) *CreateDistributionWithTagsInput { + s.DistributionConfigWithTags = v + return s +} + +// The returned result of the corresponding request. +type CreateDistributionWithTagsOutput struct { + _ struct{} `type:"structure" payload:"Distribution"` + + // The distribution's information. + Distribution *Distribution `type:"structure"` + + // The current version of the distribution created. + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // The fully qualified URI of the new distribution resource just created. For + // example: https://cloudfront.amazonaws.com/2010-11-01/distribution/EDFDVBD632BHDS5. + Location *string `location:"header" locationName:"Location" type:"string"` +} + +// String returns the string representation +func (s CreateDistributionWithTagsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateDistributionWithTagsOutput) GoString() string { + return s.String() +} + +// SetDistribution sets the Distribution field's value. +func (s *CreateDistributionWithTagsOutput) SetDistribution(v *Distribution) *CreateDistributionWithTagsOutput { + s.Distribution = v + return s +} + +// SetETag sets the ETag field's value. +func (s *CreateDistributionWithTagsOutput) SetETag(v string) *CreateDistributionWithTagsOutput { + s.ETag = &v + return s +} + +// SetLocation sets the Location field's value. +func (s *CreateDistributionWithTagsOutput) SetLocation(v string) *CreateDistributionWithTagsOutput { + s.Location = &v + return s +} + +type CreateFieldLevelEncryptionConfigInput struct { + _ struct{} `type:"structure" payload:"FieldLevelEncryptionConfig"` + + // The request to create a new field-level encryption configuration. + // + // FieldLevelEncryptionConfig is a required field + FieldLevelEncryptionConfig *FieldLevelEncryptionConfig `locationName:"FieldLevelEncryptionConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` +} + +// String returns the string representation +func (s CreateFieldLevelEncryptionConfigInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateFieldLevelEncryptionConfigInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateFieldLevelEncryptionConfigInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateFieldLevelEncryptionConfigInput"} + if s.FieldLevelEncryptionConfig == nil { + invalidParams.Add(request.NewErrParamRequired("FieldLevelEncryptionConfig")) + } + if s.FieldLevelEncryptionConfig != nil { + if err := s.FieldLevelEncryptionConfig.Validate(); err != nil { + invalidParams.AddNested("FieldLevelEncryptionConfig", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFieldLevelEncryptionConfig sets the FieldLevelEncryptionConfig field's value. +func (s *CreateFieldLevelEncryptionConfigInput) SetFieldLevelEncryptionConfig(v *FieldLevelEncryptionConfig) *CreateFieldLevelEncryptionConfigInput { + s.FieldLevelEncryptionConfig = v + return s +} + +type CreateFieldLevelEncryptionConfigOutput struct { + _ struct{} `type:"structure" payload:"FieldLevelEncryption"` + + // The current version of the field level encryption configuration. For example: + // E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // Returned when you create a new field-level encryption configuration. + FieldLevelEncryption *FieldLevelEncryption `type:"structure"` + + // The fully qualified URI of the new configuration resource just created. For + // example: https://cloudfront.amazonaws.com/2010-11-01/field-level-encryption-config/EDFDVBD632BHDS5. + Location *string `location:"header" locationName:"Location" type:"string"` +} + +// String returns the string representation +func (s CreateFieldLevelEncryptionConfigOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateFieldLevelEncryptionConfigOutput) GoString() string { + return s.String() +} + +// SetETag sets the ETag field's value. +func (s *CreateFieldLevelEncryptionConfigOutput) SetETag(v string) *CreateFieldLevelEncryptionConfigOutput { + s.ETag = &v + return s +} + +// SetFieldLevelEncryption sets the FieldLevelEncryption field's value. +func (s *CreateFieldLevelEncryptionConfigOutput) SetFieldLevelEncryption(v *FieldLevelEncryption) *CreateFieldLevelEncryptionConfigOutput { + s.FieldLevelEncryption = v + return s +} + +// SetLocation sets the Location field's value. +func (s *CreateFieldLevelEncryptionConfigOutput) SetLocation(v string) *CreateFieldLevelEncryptionConfigOutput { + s.Location = &v + return s +} + +type CreateFieldLevelEncryptionProfileInput struct { + _ struct{} `type:"structure" payload:"FieldLevelEncryptionProfileConfig"` + + // The request to create a field-level encryption profile. + // + // FieldLevelEncryptionProfileConfig is a required field + FieldLevelEncryptionProfileConfig *FieldLevelEncryptionProfileConfig `locationName:"FieldLevelEncryptionProfileConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` +} + +// String returns the string representation +func (s CreateFieldLevelEncryptionProfileInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateFieldLevelEncryptionProfileInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateFieldLevelEncryptionProfileInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateFieldLevelEncryptionProfileInput"} + if s.FieldLevelEncryptionProfileConfig == nil { + invalidParams.Add(request.NewErrParamRequired("FieldLevelEncryptionProfileConfig")) + } + if s.FieldLevelEncryptionProfileConfig != nil { + if err := s.FieldLevelEncryptionProfileConfig.Validate(); err != nil { + invalidParams.AddNested("FieldLevelEncryptionProfileConfig", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFieldLevelEncryptionProfileConfig sets the FieldLevelEncryptionProfileConfig field's value. +func (s *CreateFieldLevelEncryptionProfileInput) SetFieldLevelEncryptionProfileConfig(v *FieldLevelEncryptionProfileConfig) *CreateFieldLevelEncryptionProfileInput { + s.FieldLevelEncryptionProfileConfig = v + return s +} + +type CreateFieldLevelEncryptionProfileOutput struct { + _ struct{} `type:"structure" payload:"FieldLevelEncryptionProfile"` + + // The current version of the field level encryption profile. For example: E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // Returned when you create a new field-level encryption profile. + FieldLevelEncryptionProfile *FieldLevelEncryptionProfile `type:"structure"` + + // The fully qualified URI of the new profile resource just created. For example: + // https://cloudfront.amazonaws.com/2010-11-01/field-level-encryption-profile/EDFDVBD632BHDS5. + Location *string `location:"header" locationName:"Location" type:"string"` +} + +// String returns the string representation +func (s CreateFieldLevelEncryptionProfileOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateFieldLevelEncryptionProfileOutput) GoString() string { + return s.String() +} + +// SetETag sets the ETag field's value. +func (s *CreateFieldLevelEncryptionProfileOutput) SetETag(v string) *CreateFieldLevelEncryptionProfileOutput { + s.ETag = &v + return s +} + +// SetFieldLevelEncryptionProfile sets the FieldLevelEncryptionProfile field's value. +func (s *CreateFieldLevelEncryptionProfileOutput) SetFieldLevelEncryptionProfile(v *FieldLevelEncryptionProfile) *CreateFieldLevelEncryptionProfileOutput { + s.FieldLevelEncryptionProfile = v + return s +} + +// SetLocation sets the Location field's value. +func (s *CreateFieldLevelEncryptionProfileOutput) SetLocation(v string) *CreateFieldLevelEncryptionProfileOutput { + s.Location = &v + return s +} + +// The request to create an invalidation. +type CreateInvalidationInput struct { + _ struct{} `type:"structure" payload:"InvalidationBatch"` + + // The distribution's id. + // + // DistributionId is a required field + DistributionId *string `location:"uri" locationName:"DistributionId" type:"string" required:"true"` + + // The batch information for the invalidation. + // + // InvalidationBatch is a required field + InvalidationBatch *InvalidationBatch `locationName:"InvalidationBatch" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` +} + +// String returns the string representation +func (s CreateInvalidationInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateInvalidationInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateInvalidationInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateInvalidationInput"} + if s.DistributionId == nil { + invalidParams.Add(request.NewErrParamRequired("DistributionId")) + } + if s.InvalidationBatch == nil { + invalidParams.Add(request.NewErrParamRequired("InvalidationBatch")) + } + if s.InvalidationBatch != nil { + if err := s.InvalidationBatch.Validate(); err != nil { + invalidParams.AddNested("InvalidationBatch", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDistributionId sets the DistributionId field's value. +func (s *CreateInvalidationInput) SetDistributionId(v string) *CreateInvalidationInput { + s.DistributionId = &v + return s +} + +// SetInvalidationBatch sets the InvalidationBatch field's value. +func (s *CreateInvalidationInput) SetInvalidationBatch(v *InvalidationBatch) *CreateInvalidationInput { + s.InvalidationBatch = v + return s +} + +// The returned result of the corresponding request. +type CreateInvalidationOutput struct { + _ struct{} `type:"structure" payload:"Invalidation"` + + // The invalidation's information. + Invalidation *Invalidation `type:"structure"` + + // The fully qualified URI of the distribution and invalidation batch request, + // including the Invalidation ID. + Location *string `location:"header" locationName:"Location" type:"string"` +} + +// String returns the string representation +func (s CreateInvalidationOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateInvalidationOutput) GoString() string { + return s.String() +} + +// SetInvalidation sets the Invalidation field's value. +func (s *CreateInvalidationOutput) SetInvalidation(v *Invalidation) *CreateInvalidationOutput { + s.Invalidation = v + return s +} + +// SetLocation sets the Location field's value. +func (s *CreateInvalidationOutput) SetLocation(v string) *CreateInvalidationOutput { + s.Location = &v + return s +} + +type CreatePublicKeyInput struct { + _ struct{} `type:"structure" payload:"PublicKeyConfig"` + + // The request to add a public key to CloudFront. + // + // PublicKeyConfig is a required field + PublicKeyConfig *PublicKeyConfig `locationName:"PublicKeyConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` +} + +// String returns the string representation +func (s CreatePublicKeyInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreatePublicKeyInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreatePublicKeyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreatePublicKeyInput"} + if s.PublicKeyConfig == nil { + invalidParams.Add(request.NewErrParamRequired("PublicKeyConfig")) + } + if s.PublicKeyConfig != nil { + if err := s.PublicKeyConfig.Validate(); err != nil { + invalidParams.AddNested("PublicKeyConfig", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetPublicKeyConfig sets the PublicKeyConfig field's value. +func (s *CreatePublicKeyInput) SetPublicKeyConfig(v *PublicKeyConfig) *CreatePublicKeyInput { + s.PublicKeyConfig = v + return s +} + +type CreatePublicKeyOutput struct { + _ struct{} `type:"structure" payload:"PublicKey"` + + // The current version of the public key. For example: E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // The fully qualified URI of the new public key resource just created. For + // example: https://cloudfront.amazonaws.com/2010-11-01/cloudfront-public-key/EDFDVBD632BHDS5. + Location *string `location:"header" locationName:"Location" type:"string"` + + // Returned when you add a public key. + PublicKey *PublicKey `type:"structure"` +} + +// String returns the string representation +func (s CreatePublicKeyOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreatePublicKeyOutput) GoString() string { + return s.String() +} + +// SetETag sets the ETag field's value. +func (s *CreatePublicKeyOutput) SetETag(v string) *CreatePublicKeyOutput { + s.ETag = &v + return s +} + +// SetLocation sets the Location field's value. +func (s *CreatePublicKeyOutput) SetLocation(v string) *CreatePublicKeyOutput { + s.Location = &v + return s +} + +// SetPublicKey sets the PublicKey field's value. +func (s *CreatePublicKeyOutput) SetPublicKey(v *PublicKey) *CreatePublicKeyOutput { + s.PublicKey = v + return s +} + +// The request to create a new streaming distribution. +type CreateStreamingDistributionInput struct { + _ struct{} `type:"structure" payload:"StreamingDistributionConfig"` + + // The streaming distribution's configuration information. + // + // StreamingDistributionConfig is a required field + StreamingDistributionConfig *StreamingDistributionConfig `locationName:"StreamingDistributionConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` +} + +// String returns the string representation +func (s CreateStreamingDistributionInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateStreamingDistributionInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateStreamingDistributionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateStreamingDistributionInput"} + if s.StreamingDistributionConfig == nil { + invalidParams.Add(request.NewErrParamRequired("StreamingDistributionConfig")) + } + if s.StreamingDistributionConfig != nil { + if err := s.StreamingDistributionConfig.Validate(); err != nil { + invalidParams.AddNested("StreamingDistributionConfig", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetStreamingDistributionConfig sets the StreamingDistributionConfig field's value. +func (s *CreateStreamingDistributionInput) SetStreamingDistributionConfig(v *StreamingDistributionConfig) *CreateStreamingDistributionInput { + s.StreamingDistributionConfig = v + return s +} + +// The returned result of the corresponding request. +type CreateStreamingDistributionOutput struct { + _ struct{} `type:"structure" payload:"StreamingDistribution"` + + // The current version of the streaming distribution created. + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // The fully qualified URI of the new streaming distribution resource just created. + // For example: https://cloudfront.amazonaws.com/2010-11-01/streaming-distribution/EGTXBD79H29TRA8. + Location *string `location:"header" locationName:"Location" type:"string"` + + // The streaming distribution's information. + StreamingDistribution *StreamingDistribution `type:"structure"` +} + +// String returns the string representation +func (s CreateStreamingDistributionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateStreamingDistributionOutput) GoString() string { + return s.String() +} + +// SetETag sets the ETag field's value. +func (s *CreateStreamingDistributionOutput) SetETag(v string) *CreateStreamingDistributionOutput { + s.ETag = &v + return s +} + +// SetLocation sets the Location field's value. +func (s *CreateStreamingDistributionOutput) SetLocation(v string) *CreateStreamingDistributionOutput { + s.Location = &v + return s +} + +// SetStreamingDistribution sets the StreamingDistribution field's value. +func (s *CreateStreamingDistributionOutput) SetStreamingDistribution(v *StreamingDistribution) *CreateStreamingDistributionOutput { + s.StreamingDistribution = v + return s +} + +// The request to create a new streaming distribution with tags. +type CreateStreamingDistributionWithTagsInput struct { + _ struct{} `type:"structure" payload:"StreamingDistributionConfigWithTags"` + + // The streaming distribution's configuration information. + // + // StreamingDistributionConfigWithTags is a required field + StreamingDistributionConfigWithTags *StreamingDistributionConfigWithTags `locationName:"StreamingDistributionConfigWithTags" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` +} + +// String returns the string representation +func (s CreateStreamingDistributionWithTagsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateStreamingDistributionWithTagsInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateStreamingDistributionWithTagsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateStreamingDistributionWithTagsInput"} + if s.StreamingDistributionConfigWithTags == nil { + invalidParams.Add(request.NewErrParamRequired("StreamingDistributionConfigWithTags")) + } + if s.StreamingDistributionConfigWithTags != nil { + if err := s.StreamingDistributionConfigWithTags.Validate(); err != nil { + invalidParams.AddNested("StreamingDistributionConfigWithTags", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetStreamingDistributionConfigWithTags sets the StreamingDistributionConfigWithTags field's value. +func (s *CreateStreamingDistributionWithTagsInput) SetStreamingDistributionConfigWithTags(v *StreamingDistributionConfigWithTags) *CreateStreamingDistributionWithTagsInput { + s.StreamingDistributionConfigWithTags = v + return s +} + +// The returned result of the corresponding request. +type CreateStreamingDistributionWithTagsOutput struct { + _ struct{} `type:"structure" payload:"StreamingDistribution"` + + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // The fully qualified URI of the new streaming distribution resource just created. + // For example: https://cloudfront.amazonaws.com/2010-11-01/streaming-distribution/EGTXBD79H29TRA8. + Location *string `location:"header" locationName:"Location" type:"string"` + + // The streaming distribution's information. + StreamingDistribution *StreamingDistribution `type:"structure"` +} + +// String returns the string representation +func (s CreateStreamingDistributionWithTagsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateStreamingDistributionWithTagsOutput) GoString() string { + return s.String() +} + +// SetETag sets the ETag field's value. +func (s *CreateStreamingDistributionWithTagsOutput) SetETag(v string) *CreateStreamingDistributionWithTagsOutput { + s.ETag = &v + return s +} + +// SetLocation sets the Location field's value. +func (s *CreateStreamingDistributionWithTagsOutput) SetLocation(v string) *CreateStreamingDistributionWithTagsOutput { + s.Location = &v + return s +} + +// SetStreamingDistribution sets the StreamingDistribution field's value. +func (s *CreateStreamingDistributionWithTagsOutput) SetStreamingDistribution(v *StreamingDistribution) *CreateStreamingDistributionWithTagsOutput { + s.StreamingDistribution = v + return s +} + +// A complex type that controls: +// +// * Whether CloudFront replaces HTTP status codes in the 4xx and 5xx range +// with custom error messages before returning the response to the viewer. +// +// +// * How long CloudFront caches HTTP status codes in the 4xx and 5xx range. +// +// For more information about custom error pages, see Customizing Error Responses +// (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/custom-error-pages.html) +// in the Amazon CloudFront Developer Guide. +type CustomErrorResponse struct { + _ struct{} `type:"structure"` + + // The minimum amount of time, in seconds, that you want CloudFront to cache + // the HTTP status code specified in ErrorCode. When this time period has elapsed, + // CloudFront queries your origin to see whether the problem that caused the + // error has been resolved and the requested object is now available. + // + // If you don't want to specify a value, include an empty element, , + // in the XML document. + // + // For more information, see Customizing Error Responses (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/custom-error-pages.html) + // in the Amazon CloudFront Developer Guide. + ErrorCachingMinTTL *int64 `type:"long"` + + // The HTTP status code for which you want to specify a custom error page and/or + // a caching duration. + // + // ErrorCode is a required field + ErrorCode *int64 `type:"integer" required:"true"` + + // The HTTP status code that you want CloudFront to return to the viewer along + // with the custom error page. There are a variety of reasons that you might + // want CloudFront to return a status code different from the status code that + // your origin returned to CloudFront, for example: + // + // * Some Internet devices (some firewalls and corporate proxies, for example) + // intercept HTTP 4xx and 5xx and prevent the response from being returned + // to the viewer. If you substitute 200, the response typically won't be + // intercepted. + // + // * If you don't care about distinguishing among different client errors + // or server errors, you can specify 400 or 500 as the ResponseCode for all + // 4xx or 5xx errors. + // + // * You might want to return a 200 status code (OK) and static website so + // your customers don't know that your website is down. + // + // If you specify a value for ResponseCode, you must also specify a value for + // ResponsePagePath. If you don't want to specify a value, include an empty + // element, , in the XML document. + ResponseCode *string `type:"string"` + + // The path to the custom error page that you want CloudFront to return to a + // viewer when your origin returns the HTTP status code specified by ErrorCode, + // for example, /4xx-errors/403-forbidden.html. If you want to store your objects + // and your custom error pages in different locations, your distribution must + // include a cache behavior for which the following is true: + // + // * The value of PathPattern matches the path to your custom error messages. + // For example, suppose you saved custom error pages for 4xx errors in an + // Amazon S3 bucket in a directory named /4xx-errors. Your distribution must + // include a cache behavior for which the path pattern routes requests for + // your custom error pages to that location, for example, /4xx-errors/*. + // + // + // * The value of TargetOriginId specifies the value of the ID element for + // the origin that contains your custom error pages. + // + // If you specify a value for ResponsePagePath, you must also specify a value + // for ResponseCode. If you don't want to specify a value, include an empty + // element, , in the XML document. + // + // We recommend that you store custom error pages in an Amazon S3 bucket. If + // you store custom error pages on an HTTP server and the server starts to return + // 5xx errors, CloudFront can't get the files that you want to return to viewers + // because the origin server is unavailable. + ResponsePagePath *string `type:"string"` +} + +// String returns the string representation +func (s CustomErrorResponse) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CustomErrorResponse) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CustomErrorResponse) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CustomErrorResponse"} + if s.ErrorCode == nil { + invalidParams.Add(request.NewErrParamRequired("ErrorCode")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetErrorCachingMinTTL sets the ErrorCachingMinTTL field's value. +func (s *CustomErrorResponse) SetErrorCachingMinTTL(v int64) *CustomErrorResponse { + s.ErrorCachingMinTTL = &v + return s +} + +// SetErrorCode sets the ErrorCode field's value. +func (s *CustomErrorResponse) SetErrorCode(v int64) *CustomErrorResponse { + s.ErrorCode = &v + return s +} + +// SetResponseCode sets the ResponseCode field's value. +func (s *CustomErrorResponse) SetResponseCode(v string) *CustomErrorResponse { + s.ResponseCode = &v + return s +} + +// SetResponsePagePath sets the ResponsePagePath field's value. +func (s *CustomErrorResponse) SetResponsePagePath(v string) *CustomErrorResponse { + s.ResponsePagePath = &v + return s +} + +// A complex type that controls: +// +// * Whether CloudFront replaces HTTP status codes in the 4xx and 5xx range +// with custom error messages before returning the response to the viewer. +// +// * How long CloudFront caches HTTP status codes in the 4xx and 5xx range. +// +// For more information about custom error pages, see Customizing Error Responses +// (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/custom-error-pages.html) +// in the Amazon CloudFront Developer Guide. +type CustomErrorResponses struct { + _ struct{} `type:"structure"` + + // A complex type that contains a CustomErrorResponse element for each HTTP + // status code for which you want to specify a custom error page and/or a caching + // duration. + Items []*CustomErrorResponse `locationNameList:"CustomErrorResponse" type:"list"` + + // The number of HTTP status codes for which you want to specify a custom error + // page and/or a caching duration. If Quantity is 0, you can omit Items. + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` +} + +// String returns the string representation +func (s CustomErrorResponses) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CustomErrorResponses) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CustomErrorResponses) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CustomErrorResponses"} + if s.Quantity == nil { + invalidParams.Add(request.NewErrParamRequired("Quantity")) + } + if s.Items != nil { + for i, v := range s.Items { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Items", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetItems sets the Items field's value. +func (s *CustomErrorResponses) SetItems(v []*CustomErrorResponse) *CustomErrorResponses { + s.Items = v + return s +} + +// SetQuantity sets the Quantity field's value. +func (s *CustomErrorResponses) SetQuantity(v int64) *CustomErrorResponses { + s.Quantity = &v + return s +} + +// A complex type that contains the list of Custom Headers for each origin. +type CustomHeaders struct { + _ struct{} `type:"structure"` + + // Optional: A list that contains one OriginCustomHeader element for each custom + // header that you want CloudFront to forward to the origin. If Quantity is + // 0, omit Items. + Items []*OriginCustomHeader `locationNameList:"OriginCustomHeader" type:"list"` + + // The number of custom headers, if any, for this distribution. + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` +} + +// String returns the string representation +func (s CustomHeaders) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CustomHeaders) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CustomHeaders) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CustomHeaders"} + if s.Quantity == nil { + invalidParams.Add(request.NewErrParamRequired("Quantity")) + } + if s.Items != nil { + for i, v := range s.Items { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Items", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetItems sets the Items field's value. +func (s *CustomHeaders) SetItems(v []*OriginCustomHeader) *CustomHeaders { + s.Items = v + return s +} + +// SetQuantity sets the Quantity field's value. +func (s *CustomHeaders) SetQuantity(v int64) *CustomHeaders { + s.Quantity = &v + return s +} + +// A customer origin. +type CustomOriginConfig struct { + _ struct{} `type:"structure"` + + // The HTTP port the custom origin listens on. + // + // HTTPPort is a required field + HTTPPort *int64 `type:"integer" required:"true"` + + // The HTTPS port the custom origin listens on. + // + // HTTPSPort is a required field + HTTPSPort *int64 `type:"integer" required:"true"` + + // You can create a custom keep-alive timeout. All timeout units are in seconds. + // The default keep-alive timeout is 5 seconds, but you can configure custom + // timeout lengths using the CloudFront API. The minimum timeout length is 1 + // second; the maximum is 60 seconds. + // + // If you need to increase the maximum time limit, contact the AWS Support Center + // (https://console.aws.amazon.com/support/home#/). + OriginKeepaliveTimeout *int64 `type:"integer"` + + // The origin protocol policy to apply to your origin. + // + // OriginProtocolPolicy is a required field + OriginProtocolPolicy *string `type:"string" required:"true" enum:"OriginProtocolPolicy"` + + // You can create a custom origin read timeout. All timeout units are in seconds. + // The default origin read timeout is 30 seconds, but you can configure custom + // timeout lengths using the CloudFront API. The minimum timeout length is 4 + // seconds; the maximum is 60 seconds. + // + // If you need to increase the maximum time limit, contact the AWS Support Center + // (https://console.aws.amazon.com/support/home#/). + OriginReadTimeout *int64 `type:"integer"` + + // The SSL/TLS protocols that you want CloudFront to use when communicating + // with your origin over HTTPS. + OriginSslProtocols *OriginSslProtocols `type:"structure"` +} + +// String returns the string representation +func (s CustomOriginConfig) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CustomOriginConfig) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CustomOriginConfig) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CustomOriginConfig"} + if s.HTTPPort == nil { + invalidParams.Add(request.NewErrParamRequired("HTTPPort")) + } + if s.HTTPSPort == nil { + invalidParams.Add(request.NewErrParamRequired("HTTPSPort")) + } + if s.OriginProtocolPolicy == nil { + invalidParams.Add(request.NewErrParamRequired("OriginProtocolPolicy")) + } + if s.OriginSslProtocols != nil { + if err := s.OriginSslProtocols.Validate(); err != nil { + invalidParams.AddNested("OriginSslProtocols", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetHTTPPort sets the HTTPPort field's value. +func (s *CustomOriginConfig) SetHTTPPort(v int64) *CustomOriginConfig { + s.HTTPPort = &v + return s +} + +// SetHTTPSPort sets the HTTPSPort field's value. +func (s *CustomOriginConfig) SetHTTPSPort(v int64) *CustomOriginConfig { + s.HTTPSPort = &v + return s +} + +// SetOriginKeepaliveTimeout sets the OriginKeepaliveTimeout field's value. +func (s *CustomOriginConfig) SetOriginKeepaliveTimeout(v int64) *CustomOriginConfig { + s.OriginKeepaliveTimeout = &v + return s +} + +// SetOriginProtocolPolicy sets the OriginProtocolPolicy field's value. +func (s *CustomOriginConfig) SetOriginProtocolPolicy(v string) *CustomOriginConfig { + s.OriginProtocolPolicy = &v + return s +} + +// SetOriginReadTimeout sets the OriginReadTimeout field's value. +func (s *CustomOriginConfig) SetOriginReadTimeout(v int64) *CustomOriginConfig { + s.OriginReadTimeout = &v + return s +} + +// SetOriginSslProtocols sets the OriginSslProtocols field's value. +func (s *CustomOriginConfig) SetOriginSslProtocols(v *OriginSslProtocols) *CustomOriginConfig { + s.OriginSslProtocols = v + return s +} + +// A complex type that describes the default cache behavior if you don't specify +// a CacheBehavior element or if files don't match any of the values of PathPattern +// in CacheBehavior elements. You must create exactly one default cache behavior. +type DefaultCacheBehavior struct { + _ struct{} `type:"structure"` + + // A complex type that controls which HTTP methods CloudFront processes and + // forwards to your Amazon S3 bucket or your custom origin. There are three + // choices: + // + // * CloudFront forwards only GET and HEAD requests. + // + // * CloudFront forwards only GET, HEAD, and OPTIONS requests. + // + // * CloudFront forwards GET, HEAD, OPTIONS, PUT, PATCH, POST, and DELETE + // requests. + // + // If you pick the third choice, you may need to restrict access to your Amazon + // S3 bucket or to your custom origin so users can't perform operations that + // you don't want them to. For example, you might not want users to have permissions + // to delete objects from your origin. + AllowedMethods *AllowedMethods `type:"structure"` + + // Whether you want CloudFront to automatically compress certain files for this + // cache behavior. If so, specify true; if not, specify false. For more information, + // see Serving Compressed Files (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/ServingCompressedFiles.html) + // in the Amazon CloudFront Developer Guide. + Compress *bool `type:"boolean"` + + // The default amount of time that you want objects to stay in CloudFront caches + // before CloudFront forwards another request to your origin to determine whether + // the object has been updated. The value that you specify applies only when + // your origin does not add HTTP headers such as Cache-Control max-age, Cache-Control + // s-maxage, and Expires to objects. For more information, see Specifying How + // Long Objects and Errors Stay in a CloudFront Edge Cache (Expiration) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html) + // in the Amazon CloudFront Developer Guide. + DefaultTTL *int64 `type:"long"` + + FieldLevelEncryptionId *string `type:"string"` + + // A complex type that specifies how CloudFront handles query strings and cookies. + // + // ForwardedValues is a required field + ForwardedValues *ForwardedValues `type:"structure" required:"true"` + + // A complex type that contains zero or more Lambda function associations for + // a cache behavior. + LambdaFunctionAssociations *LambdaFunctionAssociations `type:"structure"` + + MaxTTL *int64 `type:"long"` + + // The minimum amount of time that you want objects to stay in CloudFront caches + // before CloudFront forwards another request to your origin to determine whether + // the object has been updated. For more information, see Specifying How Long + // Objects and Errors Stay in a CloudFront Edge Cache (Expiration) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html) + // in the Amazon Amazon CloudFront Developer Guide. + // + // You must specify 0 for MinTTL if you configure CloudFront to forward all + // headers to your origin (under Headers, if you specify 1 for Quantity and + // * for Name). + // + // MinTTL is a required field + MinTTL *int64 `type:"long" required:"true"` + + // Indicates whether you want to distribute media files in the Microsoft Smooth + // Streaming format using the origin that is associated with this cache behavior. + // If so, specify true; if not, specify false. If you specify true for SmoothStreaming, + // you can still distribute other content using this cache behavior if the content + // matches the value of PathPattern. + SmoothStreaming *bool `type:"boolean"` + + // The value of ID for the origin that you want CloudFront to route requests + // to when a request matches the path pattern either for a cache behavior or + // for the default cache behavior. + // + // TargetOriginId is a required field + TargetOriginId *string `type:"string" required:"true"` + + // A complex type that specifies the AWS accounts, if any, that you want to + // allow to create signed URLs for private content. + // + // If you want to require signed URLs in requests for objects in the target + // origin that match the PathPattern for this cache behavior, specify true for + // Enabled, and specify the applicable values for Quantity and Items. For more + // information, see Serving Private Content through CloudFront (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/PrivateContent.html) + // in the Amazon Amazon CloudFront Developer Guide. + // + // If you don't want to require signed URLs in requests for objects that match + // PathPattern, specify false for Enabled and 0 for Quantity. Omit Items. + // + // To add, change, or remove one or more trusted signers, change Enabled to + // true (if it's currently false), change Quantity as applicable, and specify + // all of the trusted signers that you want to include in the updated distribution. + // + // TrustedSigners is a required field + TrustedSigners *TrustedSigners `type:"structure" required:"true"` + + // The protocol that viewers can use to access the files in the origin specified + // by TargetOriginId when a request matches the path pattern in PathPattern. + // You can specify the following options: + // + // * allow-all: Viewers can use HTTP or HTTPS. + // + // * redirect-to-https: If a viewer submits an HTTP request, CloudFront returns + // an HTTP status code of 301 (Moved Permanently) to the viewer along with + // the HTTPS URL. The viewer then resubmits the request using the new URL. + // + // * https-only: If a viewer sends an HTTP request, CloudFront returns an + // HTTP status code of 403 (Forbidden). + // + // For more information about requiring the HTTPS protocol, see Using an HTTPS + // Connection to Access Your Objects (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/SecureConnections.html) + // in the Amazon CloudFront Developer Guide. + // + // The only way to guarantee that viewers retrieve an object that was fetched + // from the origin using HTTPS is never to use any other protocol to fetch the + // object. If you have recently changed from HTTP to HTTPS, we recommend that + // you clear your objects' cache because cached objects are protocol agnostic. + // That means that an edge location will return an object from the cache regardless + // of whether the current request protocol matches the protocol used previously. + // For more information, see Specifying How Long Objects and Errors Stay in + // a CloudFront Edge Cache (Expiration) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html) + // in the Amazon CloudFront Developer Guide. + // + // ViewerProtocolPolicy is a required field + ViewerProtocolPolicy *string `type:"string" required:"true" enum:"ViewerProtocolPolicy"` +} + +// String returns the string representation +func (s DefaultCacheBehavior) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DefaultCacheBehavior) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DefaultCacheBehavior) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DefaultCacheBehavior"} + if s.ForwardedValues == nil { + invalidParams.Add(request.NewErrParamRequired("ForwardedValues")) + } + if s.MinTTL == nil { + invalidParams.Add(request.NewErrParamRequired("MinTTL")) + } + if s.TargetOriginId == nil { + invalidParams.Add(request.NewErrParamRequired("TargetOriginId")) + } + if s.TrustedSigners == nil { + invalidParams.Add(request.NewErrParamRequired("TrustedSigners")) + } + if s.ViewerProtocolPolicy == nil { + invalidParams.Add(request.NewErrParamRequired("ViewerProtocolPolicy")) + } + if s.AllowedMethods != nil { + if err := s.AllowedMethods.Validate(); err != nil { + invalidParams.AddNested("AllowedMethods", err.(request.ErrInvalidParams)) + } + } + if s.ForwardedValues != nil { + if err := s.ForwardedValues.Validate(); err != nil { + invalidParams.AddNested("ForwardedValues", err.(request.ErrInvalidParams)) + } + } + if s.LambdaFunctionAssociations != nil { + if err := s.LambdaFunctionAssociations.Validate(); err != nil { + invalidParams.AddNested("LambdaFunctionAssociations", err.(request.ErrInvalidParams)) + } + } + if s.TrustedSigners != nil { + if err := s.TrustedSigners.Validate(); err != nil { + invalidParams.AddNested("TrustedSigners", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAllowedMethods sets the AllowedMethods field's value. +func (s *DefaultCacheBehavior) SetAllowedMethods(v *AllowedMethods) *DefaultCacheBehavior { + s.AllowedMethods = v + return s +} + +// SetCompress sets the Compress field's value. +func (s *DefaultCacheBehavior) SetCompress(v bool) *DefaultCacheBehavior { + s.Compress = &v + return s +} + +// SetDefaultTTL sets the DefaultTTL field's value. +func (s *DefaultCacheBehavior) SetDefaultTTL(v int64) *DefaultCacheBehavior { + s.DefaultTTL = &v + return s +} + +// SetFieldLevelEncryptionId sets the FieldLevelEncryptionId field's value. +func (s *DefaultCacheBehavior) SetFieldLevelEncryptionId(v string) *DefaultCacheBehavior { + s.FieldLevelEncryptionId = &v + return s +} + +// SetForwardedValues sets the ForwardedValues field's value. +func (s *DefaultCacheBehavior) SetForwardedValues(v *ForwardedValues) *DefaultCacheBehavior { + s.ForwardedValues = v + return s +} + +// SetLambdaFunctionAssociations sets the LambdaFunctionAssociations field's value. +func (s *DefaultCacheBehavior) SetLambdaFunctionAssociations(v *LambdaFunctionAssociations) *DefaultCacheBehavior { + s.LambdaFunctionAssociations = v + return s +} + +// SetMaxTTL sets the MaxTTL field's value. +func (s *DefaultCacheBehavior) SetMaxTTL(v int64) *DefaultCacheBehavior { + s.MaxTTL = &v + return s +} + +// SetMinTTL sets the MinTTL field's value. +func (s *DefaultCacheBehavior) SetMinTTL(v int64) *DefaultCacheBehavior { + s.MinTTL = &v + return s +} + +// SetSmoothStreaming sets the SmoothStreaming field's value. +func (s *DefaultCacheBehavior) SetSmoothStreaming(v bool) *DefaultCacheBehavior { + s.SmoothStreaming = &v + return s +} + +// SetTargetOriginId sets the TargetOriginId field's value. +func (s *DefaultCacheBehavior) SetTargetOriginId(v string) *DefaultCacheBehavior { + s.TargetOriginId = &v + return s +} + +// SetTrustedSigners sets the TrustedSigners field's value. +func (s *DefaultCacheBehavior) SetTrustedSigners(v *TrustedSigners) *DefaultCacheBehavior { + s.TrustedSigners = v + return s +} + +// SetViewerProtocolPolicy sets the ViewerProtocolPolicy field's value. +func (s *DefaultCacheBehavior) SetViewerProtocolPolicy(v string) *DefaultCacheBehavior { + s.ViewerProtocolPolicy = &v + return s +} + +// Deletes a origin access identity. +type DeleteCloudFrontOriginAccessIdentityInput struct { + _ struct{} `type:"structure"` + + // The origin access identity's ID. + // + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + + // The value of the ETag header you received from a previous GET or PUT request. + // For example: E2QWRUHAPOMQZL. + IfMatch *string `location:"header" locationName:"If-Match" type:"string"` +} + +// String returns the string representation +func (s DeleteCloudFrontOriginAccessIdentityInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteCloudFrontOriginAccessIdentityInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteCloudFrontOriginAccessIdentityInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteCloudFrontOriginAccessIdentityInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetId sets the Id field's value. +func (s *DeleteCloudFrontOriginAccessIdentityInput) SetId(v string) *DeleteCloudFrontOriginAccessIdentityInput { + s.Id = &v + return s +} + +// SetIfMatch sets the IfMatch field's value. +func (s *DeleteCloudFrontOriginAccessIdentityInput) SetIfMatch(v string) *DeleteCloudFrontOriginAccessIdentityInput { + s.IfMatch = &v + return s +} + +type DeleteCloudFrontOriginAccessIdentityOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteCloudFrontOriginAccessIdentityOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteCloudFrontOriginAccessIdentityOutput) GoString() string { + return s.String() +} + +// This action deletes a web distribution. To delete a web distribution using +// the CloudFront API, perform the following steps. +// +// To delete a web distribution using the CloudFront API: +// +// Disable the web distribution +// +// Submit a GET Distribution Config request to get the current configuration +// and the Etag header for the distribution. +// +// Update the XML document that was returned in the response to your GET Distribution +// Config request to change the value of Enabled to false. +// +// Submit a PUT Distribution Config request to update the configuration for +// your distribution. In the request body, include the XML document that you +// updated in Step 3. Set the value of the HTTP If-Match header to the value +// of the ETag header that CloudFront returned when you submitted the GET Distribution +// Config request in Step 2. +// +// Review the response to the PUT Distribution Config request to confirm that +// the distribution was successfully disabled. +// +// Submit a GET Distribution request to confirm that your changes have propagated. +// When propagation is complete, the value of Status is Deployed. +// +// Submit a DELETE Distribution request. Set the value of the HTTP If-Match +// header to the value of the ETag header that CloudFront returned when you +// submitted the GET Distribution Config request in Step 6. +// +// Review the response to your DELETE Distribution request to confirm that the +// distribution was successfully deleted. +// +// For information about deleting a distribution using the CloudFront console, +// see Deleting a Distribution (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/HowToDeleteDistribution.html) // in the Amazon CloudFront Developer Guide. -type CacheBehavior struct { +type DeleteDistributionInput struct { _ struct{} `type:"structure"` - // A complex type that controls which HTTP methods CloudFront processes and - // forwards to your Amazon S3 bucket or your custom origin. There are three - // choices: - // - // * CloudFront forwards only GET and HEAD requests. - // - // * CloudFront forwards only GET, HEAD, and OPTIONS requests. + // The distribution ID. // - // * CloudFront forwards GET, HEAD, OPTIONS, PUT, PATCH, POST, and DELETE - // requests. + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + + // The value of the ETag header that you received when you disabled the distribution. + // For example: E2QWRUHAPOMQZL. + IfMatch *string `location:"header" locationName:"If-Match" type:"string"` +} + +// String returns the string representation +func (s DeleteDistributionInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteDistributionInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteDistributionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteDistributionInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetId sets the Id field's value. +func (s *DeleteDistributionInput) SetId(v string) *DeleteDistributionInput { + s.Id = &v + return s +} + +// SetIfMatch sets the IfMatch field's value. +func (s *DeleteDistributionInput) SetIfMatch(v string) *DeleteDistributionInput { + s.IfMatch = &v + return s +} + +type DeleteDistributionOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteDistributionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteDistributionOutput) GoString() string { + return s.String() +} + +type DeleteFieldLevelEncryptionConfigInput struct { + _ struct{} `type:"structure"` + + // The ID of the configuration you want to delete from CloudFront. // - // If you pick the third choice, you may need to restrict access to your Amazon - // S3 bucket or to your custom origin so users can't perform operations that - // you don't want them to. For example, you might not want users to have permissions - // to delete objects from your origin. - AllowedMethods *AllowedMethods `type:"structure"` + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + + // The value of the ETag header that you received when retrieving the configuration + // identity to delete. For example: E2QWRUHAPOMQZL. + IfMatch *string `location:"header" locationName:"If-Match" type:"string"` +} + +// String returns the string representation +func (s DeleteFieldLevelEncryptionConfigInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteFieldLevelEncryptionConfigInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteFieldLevelEncryptionConfigInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteFieldLevelEncryptionConfigInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetId sets the Id field's value. +func (s *DeleteFieldLevelEncryptionConfigInput) SetId(v string) *DeleteFieldLevelEncryptionConfigInput { + s.Id = &v + return s +} + +// SetIfMatch sets the IfMatch field's value. +func (s *DeleteFieldLevelEncryptionConfigInput) SetIfMatch(v string) *DeleteFieldLevelEncryptionConfigInput { + s.IfMatch = &v + return s +} + +type DeleteFieldLevelEncryptionConfigOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteFieldLevelEncryptionConfigOutput) String() string { + return awsutil.Prettify(s) +} - // Whether you want CloudFront to automatically compress certain files for this - // cache behavior. If so, specify true; if not, specify false. For more information, - // see Serving Compressed Files (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/ServingCompressedFiles.html) - // in the Amazon CloudFront Developer Guide. - Compress *bool `type:"boolean"` +// GoString returns the string representation +func (s DeleteFieldLevelEncryptionConfigOutput) GoString() string { + return s.String() +} - // The default amount of time that you want objects to stay in CloudFront caches - // before CloudFront forwards another request to your origin to determine whether - // the object has been updated. The value that you specify applies only when - // your origin does not add HTTP headers such as Cache-Control max-age, Cache-Control - // s-maxage, and Expires to objects. For more information, see Specifying How - // Long Objects and Errors Stay in a CloudFront Edge Cache (Expiration) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html) - // in the Amazon CloudFront Developer Guide. - DefaultTTL *int64 `type:"long"` +type DeleteFieldLevelEncryptionProfileInput struct { + _ struct{} `type:"structure"` - // A complex type that specifies how CloudFront handles query strings and cookies. + // Request the ID of the profile you want to delete from CloudFront. // - // ForwardedValues is a required field - ForwardedValues *ForwardedValues `type:"structure" required:"true"` + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` - // A complex type that contains zero or more Lambda function associations for - // a cache behavior. - LambdaFunctionAssociations *LambdaFunctionAssociations `type:"structure"` + // The value of the ETag header that you received when retrieving the profile + // to delete. For example: E2QWRUHAPOMQZL. + IfMatch *string `location:"header" locationName:"If-Match" type:"string"` +} - // The maximum amount of time that you want objects to stay in CloudFront caches - // before CloudFront forwards another request to your origin to determine whether - // the object has been updated. The value that you specify applies only when - // your origin adds HTTP headers such as Cache-Control max-age, Cache-Control - // s-maxage, and Expires to objects. For more information, see Specifying How - // Long Objects and Errors Stay in a CloudFront Edge Cache (Expiration) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html) - // in the Amazon CloudFront Developer Guide. - MaxTTL *int64 `type:"long"` +// String returns the string representation +func (s DeleteFieldLevelEncryptionProfileInput) String() string { + return awsutil.Prettify(s) +} - // The minimum amount of time that you want objects to stay in CloudFront caches - // before CloudFront forwards another request to your origin to determine whether - // the object has been updated. For more information, see Specifying How Long - // Objects and Errors Stay in a CloudFront Edge Cache (Expiration) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html) - // in the Amazon Amazon CloudFront Developer Guide. - // - // You must specify 0 for MinTTL if you configure CloudFront to forward all - // headers to your origin (under Headers, if you specify 1 for Quantity and - // * for Name). - // - // MinTTL is a required field - MinTTL *int64 `type:"long" required:"true"` +// GoString returns the string representation +func (s DeleteFieldLevelEncryptionProfileInput) GoString() string { + return s.String() +} - // The pattern (for example, images/*.jpg) that specifies which requests to - // apply the behavior to. When CloudFront receives a viewer request, the requested - // path is compared with path patterns in the order in which cache behaviors - // are listed in the distribution. - // - // You can optionally include a slash (/) at the beginning of the path pattern. - // For example, /images/*.jpg. CloudFront behavior is the same with or without - // the leading /. - // - // The path pattern for the default cache behavior is * and cannot be changed. - // If the request for an object does not match the path pattern for any cache - // behaviors, CloudFront applies the behavior in the default cache behavior. - // - // For more information, see Path Pattern (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/distribution-web-values-specify.html#DownloadDistValuesPathPattern) - // in the Amazon CloudFront Developer Guide. - // - // PathPattern is a required field - PathPattern *string `type:"string" required:"true"` +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteFieldLevelEncryptionProfileInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteFieldLevelEncryptionProfileInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } - // Indicates whether you want to distribute media files in the Microsoft Smooth - // Streaming format using the origin that is associated with this cache behavior. - // If so, specify true; if not, specify false. If you specify true for SmoothStreaming, - // you can still distribute other content using this cache behavior if the content - // matches the value of PathPattern. - SmoothStreaming *bool `type:"boolean"` + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} - // The value of ID for the origin that you want CloudFront to route requests - // to when a request matches the path pattern either for a cache behavior or - // for the default cache behavior. - // - // TargetOriginId is a required field - TargetOriginId *string `type:"string" required:"true"` +// SetId sets the Id field's value. +func (s *DeleteFieldLevelEncryptionProfileInput) SetId(v string) *DeleteFieldLevelEncryptionProfileInput { + s.Id = &v + return s +} - // A complex type that specifies the AWS accounts, if any, that you want to - // allow to create signed URLs for private content. - // - // If you want to require signed URLs in requests for objects in the target - // origin that match the PathPattern for this cache behavior, specify true for - // Enabled, and specify the applicable values for Quantity and Items. For more - // information, see Serving Private Content through CloudFront (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/PrivateContent.html) - // in the Amazon Amazon CloudFront Developer Guide. - // - // If you don't want to require signed URLs in requests for objects that match - // PathPattern, specify false for Enabled and 0 for Quantity. Omit Items. - // - // To add, change, or remove one or more trusted signers, change Enabled to - // true (if it's currently false), change Quantity as applicable, and specify - // all of the trusted signers that you want to include in the updated distribution. - // - // TrustedSigners is a required field - TrustedSigners *TrustedSigners `type:"structure" required:"true"` +// SetIfMatch sets the IfMatch field's value. +func (s *DeleteFieldLevelEncryptionProfileInput) SetIfMatch(v string) *DeleteFieldLevelEncryptionProfileInput { + s.IfMatch = &v + return s +} - // The protocol that viewers can use to access the files in the origin specified - // by TargetOriginId when a request matches the path pattern in PathPattern. - // You can specify the following options: - // - // * allow-all: Viewers can use HTTP or HTTPS. - // - // * redirect-to-https: If a viewer submits an HTTP request, CloudFront returns - // an HTTP status code of 301 (Moved Permanently) to the viewer along with - // the HTTPS URL. The viewer then resubmits the request using the new URL. - // - // - // * https-only: If a viewer sends an HTTP request, CloudFront returns an - // HTTP status code of 403 (Forbidden). - // - // For more information about requiring the HTTPS protocol, see Using an HTTPS - // Connection to Access Your Objects (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/SecureConnections.html) - // in the Amazon CloudFront Developer Guide. - // - // The only way to guarantee that viewers retrieve an object that was fetched - // from the origin using HTTPS is never to use any other protocol to fetch the - // object. If you have recently changed from HTTP to HTTPS, we recommend that - // you clear your objects' cache because cached objects are protocol agnostic. - // That means that an edge location will return an object from the cache regardless - // of whether the current request protocol matches the protocol used previously. - // For more information, see Specifying How Long Objects and Errors Stay in - // a CloudFront Edge Cache (Expiration) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html) - // in the Amazon CloudFront Developer Guide. +type DeleteFieldLevelEncryptionProfileOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteFieldLevelEncryptionProfileOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteFieldLevelEncryptionProfileOutput) GoString() string { + return s.String() +} + +type DeletePublicKeyInput struct { + _ struct{} `type:"structure"` + + // The ID of the public key you want to remove from CloudFront. // - // ViewerProtocolPolicy is a required field - ViewerProtocolPolicy *string `type:"string" required:"true" enum:"ViewerProtocolPolicy"` + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + + // The value of the ETag header that you received when retrieving the public + // key identity to delete. For example: E2QWRUHAPOMQZL. + IfMatch *string `location:"header" locationName:"If-Match" type:"string"` } // String returns the string representation -func (s CacheBehavior) String() string { +func (s DeletePublicKeyInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s CacheBehavior) GoString() string { +func (s DeletePublicKeyInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *CacheBehavior) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CacheBehavior"} - if s.ForwardedValues == nil { - invalidParams.Add(request.NewErrParamRequired("ForwardedValues")) - } - if s.MinTTL == nil { - invalidParams.Add(request.NewErrParamRequired("MinTTL")) - } - if s.PathPattern == nil { - invalidParams.Add(request.NewErrParamRequired("PathPattern")) - } - if s.TargetOriginId == nil { - invalidParams.Add(request.NewErrParamRequired("TargetOriginId")) - } - if s.TrustedSigners == nil { - invalidParams.Add(request.NewErrParamRequired("TrustedSigners")) - } - if s.ViewerProtocolPolicy == nil { - invalidParams.Add(request.NewErrParamRequired("ViewerProtocolPolicy")) - } - if s.AllowedMethods != nil { - if err := s.AllowedMethods.Validate(); err != nil { - invalidParams.AddNested("AllowedMethods", err.(request.ErrInvalidParams)) - } - } - if s.ForwardedValues != nil { - if err := s.ForwardedValues.Validate(); err != nil { - invalidParams.AddNested("ForwardedValues", err.(request.ErrInvalidParams)) - } - } - if s.LambdaFunctionAssociations != nil { - if err := s.LambdaFunctionAssociations.Validate(); err != nil { - invalidParams.AddNested("LambdaFunctionAssociations", err.(request.ErrInvalidParams)) - } - } - if s.TrustedSigners != nil { - if err := s.TrustedSigners.Validate(); err != nil { - invalidParams.AddNested("TrustedSigners", err.(request.ErrInvalidParams)) - } +func (s *DeletePublicKeyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeletePublicKeyInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) } if invalidParams.Len() > 0 { @@ -3625,117 +7525,111 @@ func (s *CacheBehavior) Validate() error { return nil } -// SetAllowedMethods sets the AllowedMethods field's value. -func (s *CacheBehavior) SetAllowedMethods(v *AllowedMethods) *CacheBehavior { - s.AllowedMethods = v +// SetId sets the Id field's value. +func (s *DeletePublicKeyInput) SetId(v string) *DeletePublicKeyInput { + s.Id = &v return s } -// SetCompress sets the Compress field's value. -func (s *CacheBehavior) SetCompress(v bool) *CacheBehavior { - s.Compress = &v +// SetIfMatch sets the IfMatch field's value. +func (s *DeletePublicKeyInput) SetIfMatch(v string) *DeletePublicKeyInput { + s.IfMatch = &v return s } -// SetDefaultTTL sets the DefaultTTL field's value. -func (s *CacheBehavior) SetDefaultTTL(v int64) *CacheBehavior { - s.DefaultTTL = &v - return s +type DeletePublicKeyOutput struct { + _ struct{} `type:"structure"` } -// SetForwardedValues sets the ForwardedValues field's value. -func (s *CacheBehavior) SetForwardedValues(v *ForwardedValues) *CacheBehavior { - s.ForwardedValues = v - return s +// String returns the string representation +func (s DeletePublicKeyOutput) String() string { + return awsutil.Prettify(s) } -// SetLambdaFunctionAssociations sets the LambdaFunctionAssociations field's value. -func (s *CacheBehavior) SetLambdaFunctionAssociations(v *LambdaFunctionAssociations) *CacheBehavior { - s.LambdaFunctionAssociations = v - return s +// GoString returns the string representation +func (s DeletePublicKeyOutput) GoString() string { + return s.String() } -// SetMaxTTL sets the MaxTTL field's value. -func (s *CacheBehavior) SetMaxTTL(v int64) *CacheBehavior { - s.MaxTTL = &v - return s +type DeleteServiceLinkedRoleInput struct { + _ struct{} `type:"structure"` + + // RoleName is a required field + RoleName *string `location:"uri" locationName:"RoleName" type:"string" required:"true"` } -// SetMinTTL sets the MinTTL field's value. -func (s *CacheBehavior) SetMinTTL(v int64) *CacheBehavior { - s.MinTTL = &v - return s +// String returns the string representation +func (s DeleteServiceLinkedRoleInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteServiceLinkedRoleInput) GoString() string { + return s.String() } -// SetPathPattern sets the PathPattern field's value. -func (s *CacheBehavior) SetPathPattern(v string) *CacheBehavior { - s.PathPattern = &v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteServiceLinkedRoleInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteServiceLinkedRoleInput"} + if s.RoleName == nil { + invalidParams.Add(request.NewErrParamRequired("RoleName")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetSmoothStreaming sets the SmoothStreaming field's value. -func (s *CacheBehavior) SetSmoothStreaming(v bool) *CacheBehavior { - s.SmoothStreaming = &v +// SetRoleName sets the RoleName field's value. +func (s *DeleteServiceLinkedRoleInput) SetRoleName(v string) *DeleteServiceLinkedRoleInput { + s.RoleName = &v return s } -// SetTargetOriginId sets the TargetOriginId field's value. -func (s *CacheBehavior) SetTargetOriginId(v string) *CacheBehavior { - s.TargetOriginId = &v - return s +type DeleteServiceLinkedRoleOutput struct { + _ struct{} `type:"structure"` } -// SetTrustedSigners sets the TrustedSigners field's value. -func (s *CacheBehavior) SetTrustedSigners(v *TrustedSigners) *CacheBehavior { - s.TrustedSigners = v - return s +// String returns the string representation +func (s DeleteServiceLinkedRoleOutput) String() string { + return awsutil.Prettify(s) } -// SetViewerProtocolPolicy sets the ViewerProtocolPolicy field's value. -func (s *CacheBehavior) SetViewerProtocolPolicy(v string) *CacheBehavior { - s.ViewerProtocolPolicy = &v - return s +// GoString returns the string representation +func (s DeleteServiceLinkedRoleOutput) GoString() string { + return s.String() } -// A complex type that contains zero or more CacheBehavior elements. -type CacheBehaviors struct { +// The request to delete a streaming distribution. +type DeleteStreamingDistributionInput struct { _ struct{} `type:"structure"` - // Optional: A complex type that contains cache behaviors for this distribution. - // If Quantity is 0, you can omit Items. - Items []*CacheBehavior `locationNameList:"CacheBehavior" type:"list"` - - // The number of cache behaviors for this distribution. + // The distribution ID. // - // Quantity is a required field - Quantity *int64 `type:"integer" required:"true"` + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + + // The value of the ETag header that you received when you disabled the streaming + // distribution. For example: E2QWRUHAPOMQZL. + IfMatch *string `location:"header" locationName:"If-Match" type:"string"` } // String returns the string representation -func (s CacheBehaviors) String() string { +func (s DeleteStreamingDistributionInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s CacheBehaviors) GoString() string { +func (s DeleteStreamingDistributionInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *CacheBehaviors) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CacheBehaviors"} - if s.Quantity == nil { - invalidParams.Add(request.NewErrParamRequired("Quantity")) - } - if s.Items != nil { - for i, v := range s.Items { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Items", i), err.(request.ErrInvalidParams)) - } - } +func (s *DeleteStreamingDistributionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteStreamingDistributionInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) } if invalidParams.Len() > 0 { @@ -3744,509 +7638,627 @@ func (s *CacheBehaviors) Validate() error { return nil } -// SetItems sets the Items field's value. -func (s *CacheBehaviors) SetItems(v []*CacheBehavior) *CacheBehaviors { - s.Items = v +// SetId sets the Id field's value. +func (s *DeleteStreamingDistributionInput) SetId(v string) *DeleteStreamingDistributionInput { + s.Id = &v return s } -// SetQuantity sets the Quantity field's value. -func (s *CacheBehaviors) SetQuantity(v int64) *CacheBehaviors { - s.Quantity = &v +// SetIfMatch sets the IfMatch field's value. +func (s *DeleteStreamingDistributionInput) SetIfMatch(v string) *DeleteStreamingDistributionInput { + s.IfMatch = &v return s } -// A complex type that controls whether CloudFront caches the response to requests -// using the specified HTTP methods. There are two choices: -// -// * CloudFront caches responses to GET and HEAD requests. -// -// * CloudFront caches responses to GET, HEAD, and OPTIONS requests. -// -// If you pick the second choice for your Amazon S3 Origin, you may need to -// forward Access-Control-Request-Method, Access-Control-Request-Headers, and -// Origin headers for the responses to be cached correctly. -type CachedMethods struct { +type DeleteStreamingDistributionOutput struct { _ struct{} `type:"structure"` +} - // A complex type that contains the HTTP methods that you want CloudFront to - // cache responses to. +// String returns the string representation +func (s DeleteStreamingDistributionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteStreamingDistributionOutput) GoString() string { + return s.String() +} + +// The distribution's information. +type Distribution struct { + _ struct{} `type:"structure"` + + // The ARN (Amazon Resource Name) for the distribution. For example: arn:aws:cloudfront::123456789012:distribution/EDFDVBD632BHDS5, + // where 123456789012 is your AWS account ID. // - // Items is a required field - Items []*string `locationNameList:"Method" type:"list" required:"true"` + // ARN is a required field + ARN *string `type:"string" required:"true"` - // The number of HTTP methods for which you want CloudFront to cache responses. - // Valid values are 2 (for caching responses to GET and HEAD requests) and 3 - // (for caching responses to GET, HEAD, and OPTIONS requests). + // CloudFront automatically adds this element to the response only if you've + // set up the distribution to serve private content with signed URLs. The element + // lists the key pair IDs that CloudFront is aware of for each trusted signer. + // The Signer child element lists the AWS account number of the trusted signer + // (or an empty Self element if the signer is you). The Signer element also + // includes the IDs of any active key pairs associated with the trusted signer's + // AWS account. If no KeyPairId element appears for a Signer, that signer can't + // create working signed URLs. // - // Quantity is a required field - Quantity *int64 `type:"integer" required:"true"` + // ActiveTrustedSigners is a required field + ActiveTrustedSigners *ActiveTrustedSigners `type:"structure" required:"true"` + + // The current configuration information for the distribution. Send a GET request + // to the /CloudFront API version/distribution ID/config resource. + // + // DistributionConfig is a required field + DistributionConfig *DistributionConfig `type:"structure" required:"true"` + + // The domain name corresponding to the distribution, for example, d111111abcdef8.cloudfront.net. + // + // DomainName is a required field + DomainName *string `type:"string" required:"true"` + + // The identifier for the distribution. For example: EDFDVBD632BHDS5. + // + // Id is a required field + Id *string `type:"string" required:"true"` + + // The number of invalidation batches currently in progress. + // + // InProgressInvalidationBatches is a required field + InProgressInvalidationBatches *int64 `type:"integer" required:"true"` + + // The date and time the distribution was last modified. + // + // LastModifiedTime is a required field + LastModifiedTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // This response element indicates the current status of the distribution. When + // the status is Deployed, the distribution's information is fully propagated + // to all CloudFront edge locations. + // + // Status is a required field + Status *string `type:"string" required:"true"` } // String returns the string representation -func (s CachedMethods) String() string { +func (s Distribution) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s CachedMethods) GoString() string { +func (s Distribution) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *CachedMethods) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CachedMethods"} - if s.Items == nil { - invalidParams.Add(request.NewErrParamRequired("Items")) - } - if s.Quantity == nil { - invalidParams.Add(request.NewErrParamRequired("Quantity")) - } +// SetARN sets the ARN field's value. +func (s *Distribution) SetARN(v string) *Distribution { + s.ARN = &v + return s +} - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetActiveTrustedSigners sets the ActiveTrustedSigners field's value. +func (s *Distribution) SetActiveTrustedSigners(v *ActiveTrustedSigners) *Distribution { + s.ActiveTrustedSigners = v + return s } -// SetItems sets the Items field's value. -func (s *CachedMethods) SetItems(v []*string) *CachedMethods { - s.Items = v +// SetDistributionConfig sets the DistributionConfig field's value. +func (s *Distribution) SetDistributionConfig(v *DistributionConfig) *Distribution { + s.DistributionConfig = v + return s +} + +// SetDomainName sets the DomainName field's value. +func (s *Distribution) SetDomainName(v string) *Distribution { + s.DomainName = &v + return s +} + +// SetId sets the Id field's value. +func (s *Distribution) SetId(v string) *Distribution { + s.Id = &v + return s +} + +// SetInProgressInvalidationBatches sets the InProgressInvalidationBatches field's value. +func (s *Distribution) SetInProgressInvalidationBatches(v int64) *Distribution { + s.InProgressInvalidationBatches = &v + return s +} + +// SetLastModifiedTime sets the LastModifiedTime field's value. +func (s *Distribution) SetLastModifiedTime(v time.Time) *Distribution { + s.LastModifiedTime = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *Distribution) SetStatus(v string) *Distribution { + s.Status = &v return s } -// SetQuantity sets the Quantity field's value. -func (s *CachedMethods) SetQuantity(v int64) *CachedMethods { - s.Quantity = &v - return s -} +// A distribution configuration. +type DistributionConfig struct { + _ struct{} `type:"structure"` + + // A complex type that contains information about CNAMEs (alternate domain names), + // if any, for this distribution. + Aliases *Aliases `type:"structure"` + + // A complex type that contains zero or more CacheBehavior elements. + CacheBehaviors *CacheBehaviors `type:"structure"` + + // A unique value (for example, a date-time stamp) that ensures that the request + // can't be replayed. + // + // If the value of CallerReference is new (regardless of the content of the + // DistributionConfig object), CloudFront creates a new distribution. + // + // If CallerReference is a value you already sent in a previous request to create + // a distribution, and if the content of the DistributionConfig is identical + // to the original request (ignoring white space), CloudFront returns the same + // the response that it returned to the original request. + // + // If CallerReference is a value you already sent in a previous request to create + // a distribution but the content of the DistributionConfig is different from + // the original request, CloudFront returns a DistributionAlreadyExists error. + // + // CallerReference is a required field + CallerReference *string `type:"string" required:"true"` + + // Any comments you want to include about the distribution. + // + // If you don't want to specify a comment, include an empty Comment element. + // + // To delete an existing comment, update the distribution configuration and + // include an empty Comment element. + // + // To add or change a comment, update the distribution configuration and specify + // the new comment. + // + // Comment is a required field + Comment *string `type:"string" required:"true"` -// A complex type that specifies whether you want CloudFront to forward cookies -// to the origin and, if so, which ones. For more information about forwarding -// cookies to the origin, see How CloudFront Forwards, Caches, and Logs Cookies -// (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Cookies.html) -// in the Amazon CloudFront Developer Guide. -type CookieNames struct { - _ struct{} `type:"structure"` + // A complex type that controls the following: + // + // * Whether CloudFront replaces HTTP status codes in the 4xx and 5xx range + // with custom error messages before returning the response to the viewer. + // + // * How long CloudFront caches HTTP status codes in the 4xx and 5xx range. + // + // For more information about custom error pages, see Customizing Error Responses + // (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/custom-error-pages.html) + // in the Amazon CloudFront Developer Guide. + CustomErrorResponses *CustomErrorResponses `type:"structure"` - // A complex type that contains one Name element for each cookie that you want - // CloudFront to forward to the origin for this cache behavior. - Items []*string `locationNameList:"Name" type:"list"` + // A complex type that describes the default cache behavior if you don't specify + // a CacheBehavior element or if files don't match any of the values of PathPattern + // in CacheBehavior elements. You must create exactly one default cache behavior. + // + // DefaultCacheBehavior is a required field + DefaultCacheBehavior *DefaultCacheBehavior `type:"structure" required:"true"` - // The number of different cookies that you want CloudFront to forward to the - // origin for this cache behavior. + // The object that you want CloudFront to request from your origin (for example, + // index.html) when a viewer requests the root URL for your distribution (http://www.example.com) + // instead of an object in your distribution (http://www.example.com/product-description.html). + // Specifying a default root object avoids exposing the contents of your distribution. // - // Quantity is a required field - Quantity *int64 `type:"integer" required:"true"` -} + // Specify only the object name, for example, index.html. Don't add a / before + // the object name. + // + // If you don't want to specify a default root object when you create a distribution, + // include an empty DefaultRootObject element. + // + // To delete the default root object from an existing distribution, update the + // distribution configuration and include an empty DefaultRootObject element. + // + // To replace the default root object, update the distribution configuration + // and specify the new object. + // + // For more information about the default root object, see Creating a Default + // Root Object (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/DefaultRootObject.html) + // in the Amazon CloudFront Developer Guide. + DefaultRootObject *string `type:"string"` -// String returns the string representation -func (s CookieNames) String() string { - return awsutil.Prettify(s) -} + // From this field, you can enable or disable the selected distribution. + // + // If you specify false for Enabled but you specify values for Bucket and Prefix, + // the values are automatically deleted. + // + // Enabled is a required field + Enabled *bool `type:"boolean" required:"true"` -// GoString returns the string representation -func (s CookieNames) GoString() string { - return s.String() -} + // (Optional) Specify the maximum HTTP version that you want viewers to use + // to communicate with CloudFront. The default value for new web distributions + // is http2. Viewers that don't support HTTP/2 automatically use an earlier + // HTTP version. + // + // For viewers and CloudFront to use HTTP/2, viewers must support TLS 1.2 or + // later, and must support Server Name Identification (SNI). + // + // In general, configuring CloudFront to communicate with viewers using HTTP/2 + // reduces latency. You can improve performance by optimizing for HTTP/2. For + // more information, do an Internet search for "http/2 optimization." + HttpVersion *string `type:"string" enum:"HttpVersion"` -// Validate inspects the fields of the type to determine if they are valid. -func (s *CookieNames) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CookieNames"} - if s.Quantity == nil { - invalidParams.Add(request.NewErrParamRequired("Quantity")) - } + // If you want CloudFront to respond to IPv6 DNS requests with an IPv6 address + // for your distribution, specify true. If you specify false, CloudFront responds + // to IPv6 DNS requests with the DNS response code NOERROR and with no IP addresses. + // This allows viewers to submit a second request, for an IPv4 address for your + // distribution. + // + // In general, you should enable IPv6 if you have users on IPv6 networks who + // want to access your content. However, if you're using signed URLs or signed + // cookies to restrict access to your content, and if you're using a custom + // policy that includes the IpAddress parameter to restrict the IP addresses + // that can access your content, don't enable IPv6. If you want to restrict + // access to some content by IP address and not restrict access to other content + // (or restrict access but not by IP address), you can create two distributions. + // For more information, see Creating a Signed URL Using a Custom Policy (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/private-content-creating-signed-url-custom-policy.html) + // in the Amazon CloudFront Developer Guide. + // + // If you're using an Amazon Route 53 alias resource record set to route traffic + // to your CloudFront distribution, you need to create a second alias resource + // record set when both of the following are true: + // + // * You enable IPv6 for the distribution + // + // * You're using alternate domain names in the URLs for your objects + // + // For more information, see Routing Traffic to an Amazon CloudFront Web Distribution + // by Using Your Domain Name (http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/routing-to-cloudfront-distribution.html) + // in the Amazon Route 53 Developer Guide. + // + // If you created a CNAME resource record set, either with Amazon Route 53 or + // with another DNS service, you don't need to make any changes. A CNAME record + // will route traffic to your distribution regardless of the IP address format + // of the viewer request. + IsIPV6Enabled *bool `type:"boolean"` - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} + // A complex type that controls whether access logs are written for the distribution. + // + // For more information about logging, see Access Logs (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/AccessLogs.html) + // in the Amazon CloudFront Developer Guide. + Logging *LoggingConfig `type:"structure"` -// SetItems sets the Items field's value. -func (s *CookieNames) SetItems(v []*string) *CookieNames { - s.Items = v - return s -} + // A complex type that contains information about origins for this distribution. + // + // Origins is a required field + Origins *Origins `type:"structure" required:"true"` -// SetQuantity sets the Quantity field's value. -func (s *CookieNames) SetQuantity(v int64) *CookieNames { - s.Quantity = &v - return s -} + // The price class that corresponds with the maximum price that you want to + // pay for CloudFront service. If you specify PriceClass_All, CloudFront responds + // to requests for your objects from all CloudFront edge locations. + // + // If you specify a price class other than PriceClass_All, CloudFront serves + // your objects from the CloudFront edge location that has the lowest latency + // among the edge locations in your price class. Viewers who are in or near + // regions that are excluded from your specified price class may encounter slower + // performance. + // + // For more information about price classes, see Choosing the Price Class for + // a CloudFront Distribution (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/PriceClass.html) + // in the Amazon CloudFront Developer Guide. For information about CloudFront + // pricing, including how price classes map to CloudFront regions, see Amazon + // CloudFront Pricing (https://aws.amazon.com/cloudfront/pricing/). + PriceClass *string `type:"string" enum:"PriceClass"` -// A complex type that specifies whether you want CloudFront to forward cookies -// to the origin and, if so, which ones. For more information about forwarding -// cookies to the origin, see How CloudFront Forwards, Caches, and Logs Cookies -// (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Cookies.html) -// in the Amazon CloudFront Developer Guide. -type CookiePreference struct { - _ struct{} `type:"structure"` + // A complex type that identifies ways in which you want to restrict distribution + // of your content. + Restrictions *Restrictions `type:"structure"` - // Specifies which cookies to forward to the origin for this cache behavior: - // all, none, or the list of cookies specified in the WhitelistedNames complex - // type. + // A complex type that specifies the following: + // + // * Whether you want viewers to use HTTP or HTTPS to request your objects. + // + // * If you want viewers to use HTTPS, whether you're using an alternate + // domain name such as example.com or the CloudFront domain name for your + // distribution, such as d111111abcdef8.cloudfront.net. + // + // * If you're using an alternate domain name, whether AWS Certificate Manager + // (ACM) provided the certificate, or you purchased a certificate from a + // third-party certificate authority and imported it into ACM or uploaded + // it to the IAM certificate store. + // + // You must specify only one of the following values: + // + // * ViewerCertificate$ACMCertificateArn + // + // * ViewerCertificate$IAMCertificateId + // + // * ViewerCertificate$CloudFrontDefaultCertificate + // + // Don't specify false for CloudFrontDefaultCertificate. + // + // If you want viewers to use HTTP instead of HTTPS to request your objects: + // Specify the following value: + // + // true + // + // In addition, specify allow-all for ViewerProtocolPolicy for all of your cache + // behaviors. + // + // If you want viewers to use HTTPS to request your objects: Choose the type + // of certificate that you want to use based on whether you're using an alternate + // domain name for your objects or the CloudFront domain name: + // + // * If you're using an alternate domain name, such as example.com: Specify + // one of the following values, depending on whether ACM provided your certificate + // or you purchased your certificate from third-party certificate authority: + // + // ARN for ACM SSL/TLS certificate where + // ARN for ACM SSL/TLS certificate is the ARN for the ACM SSL/TLS certificate + // that you want to use for this distribution. + // + // IAM certificate ID where IAM certificate + // ID is the ID that IAM returned when you added the certificate to the IAM + // certificate store. + // + // If you specify ACMCertificateArn or IAMCertificateId, you must also specify + // a value for SSLSupportMethod. + // + // If you choose to use an ACM certificate or a certificate in the IAM certificate + // store, we recommend that you use only an alternate domain name in your + // object URLs (https://example.com/logo.jpg). If you use the domain name + // that is associated with your CloudFront distribution (such as https://d111111abcdef8.cloudfront.net/logo.jpg) + // and the viewer supports SNI, then CloudFront behaves normally. However, + // if the browser does not support SNI, the user's experience depends on + // the value that you choose for SSLSupportMethod: + // + // vip: The viewer displays a warning because there is a mismatch between the + // CloudFront domain name and the domain name in your SSL/TLS certificate. // - // Amazon S3 doesn't process cookies. When the cache behavior is forwarding - // requests to an Amazon S3 origin, specify none for the Forward element. + // sni-only: CloudFront drops the connection with the browser without returning + // the object. // - // Forward is a required field - Forward *string `type:"string" required:"true" enum:"ItemSelection"` - - // Required if you specify whitelist for the value of Forward:. A complex type - // that specifies how many different cookies you want CloudFront to forward - // to the origin for this cache behavior and, if you want to forward selected - // cookies, the names of those cookies. + // * If you're using the CloudFront domain name for your distribution, such + // as d111111abcdef8.cloudfront.net: Specify the following value: // - // If you specify all or none for the value of Forward, omit WhitelistedNames. - // If you change the value of Forward from whitelist to all or none and you - // don't delete the WhitelistedNames element and its child elements, CloudFront - // deletes them automatically. + // true // - // For the current limit on the number of cookie names that you can whitelist - // for each cache behavior, see Amazon CloudFront Limits (http://docs.aws.amazon.com/general/latest/gr/aws_service_limits.html#limits_cloudfront) - // in the AWS General Reference. - WhitelistedNames *CookieNames `type:"structure"` + // If you want viewers to use HTTPS, you must also specify one of the following + // values in your cache behaviors: + // + // * https-only + // + // * redirect-to-https + // + // You can also optionally require that CloudFront use HTTPS to communicate + // with your origin by specifying one of the following values for the applicable + // origins: + // + // * https-only + // + // * match-viewer + // + // For more information, see Using Alternate Domain Names and HTTPS (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/SecureConnections.html#CNAMEsAndHTTPS) + // in the Amazon CloudFront Developer Guide. + ViewerCertificate *ViewerCertificate `type:"structure"` + + // A unique identifier that specifies the AWS WAF web ACL, if any, to associate + // with this distribution. + // + // AWS WAF is a web application firewall that lets you monitor the HTTP and + // HTTPS requests that are forwarded to CloudFront, and lets you control access + // to your content. Based on conditions that you specify, such as the IP addresses + // that requests originate from or the values of query strings, CloudFront responds + // to requests either with the requested content or with an HTTP 403 status + // code (Forbidden). You can also configure CloudFront to return a custom error + // page when a request is blocked. For more information about AWS WAF, see the + // AWS WAF Developer Guide (http://docs.aws.amazon.com/waf/latest/developerguide/what-is-aws-waf.html). + WebACLId *string `type:"string"` } // String returns the string representation -func (s CookiePreference) String() string { +func (s DistributionConfig) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s CookiePreference) GoString() string { +func (s DistributionConfig) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *CookiePreference) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CookiePreference"} - if s.Forward == nil { - invalidParams.Add(request.NewErrParamRequired("Forward")) +func (s *DistributionConfig) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DistributionConfig"} + if s.CallerReference == nil { + invalidParams.Add(request.NewErrParamRequired("CallerReference")) } - if s.WhitelistedNames != nil { - if err := s.WhitelistedNames.Validate(); err != nil { - invalidParams.AddNested("WhitelistedNames", err.(request.ErrInvalidParams)) - } + if s.Comment == nil { + invalidParams.Add(request.NewErrParamRequired("Comment")) } - - if invalidParams.Len() > 0 { - return invalidParams + if s.DefaultCacheBehavior == nil { + invalidParams.Add(request.NewErrParamRequired("DefaultCacheBehavior")) } - return nil -} - -// SetForward sets the Forward field's value. -func (s *CookiePreference) SetForward(v string) *CookiePreference { - s.Forward = &v - return s -} - -// SetWhitelistedNames sets the WhitelistedNames field's value. -func (s *CookiePreference) SetWhitelistedNames(v *CookieNames) *CookiePreference { - s.WhitelistedNames = v - return s -} - -// The request to create a new origin access identity. -type CreateCloudFrontOriginAccessIdentityInput struct { - _ struct{} `type:"structure" payload:"CloudFrontOriginAccessIdentityConfig"` - - // The current configuration information for the identity. - // - // CloudFrontOriginAccessIdentityConfig is a required field - CloudFrontOriginAccessIdentityConfig *OriginAccessIdentityConfig `locationName:"CloudFrontOriginAccessIdentityConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-03-25/"` -} - -// String returns the string representation -func (s CreateCloudFrontOriginAccessIdentityInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateCloudFrontOriginAccessIdentityInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreateCloudFrontOriginAccessIdentityInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateCloudFrontOriginAccessIdentityInput"} - if s.CloudFrontOriginAccessIdentityConfig == nil { - invalidParams.Add(request.NewErrParamRequired("CloudFrontOriginAccessIdentityConfig")) + if s.Enabled == nil { + invalidParams.Add(request.NewErrParamRequired("Enabled")) } - if s.CloudFrontOriginAccessIdentityConfig != nil { - if err := s.CloudFrontOriginAccessIdentityConfig.Validate(); err != nil { - invalidParams.AddNested("CloudFrontOriginAccessIdentityConfig", err.(request.ErrInvalidParams)) + if s.Origins == nil { + invalidParams.Add(request.NewErrParamRequired("Origins")) + } + if s.Aliases != nil { + if err := s.Aliases.Validate(); err != nil { + invalidParams.AddNested("Aliases", err.(request.ErrInvalidParams)) } } - - if invalidParams.Len() > 0 { - return invalidParams + if s.CacheBehaviors != nil { + if err := s.CacheBehaviors.Validate(); err != nil { + invalidParams.AddNested("CacheBehaviors", err.(request.ErrInvalidParams)) + } } - return nil -} - -// SetCloudFrontOriginAccessIdentityConfig sets the CloudFrontOriginAccessIdentityConfig field's value. -func (s *CreateCloudFrontOriginAccessIdentityInput) SetCloudFrontOriginAccessIdentityConfig(v *OriginAccessIdentityConfig) *CreateCloudFrontOriginAccessIdentityInput { - s.CloudFrontOriginAccessIdentityConfig = v - return s -} - -// The returned result of the corresponding request. -type CreateCloudFrontOriginAccessIdentityOutput struct { - _ struct{} `type:"structure" payload:"CloudFrontOriginAccessIdentity"` - - // The origin access identity's information. - CloudFrontOriginAccessIdentity *OriginAccessIdentity `type:"structure"` - - // The current version of the origin access identity created. - ETag *string `location:"header" locationName:"ETag" type:"string"` - - // The fully qualified URI of the new origin access identity just created. For - // example: https://cloudfront.amazonaws.com/2010-11-01/origin-access-identity/cloudfront/E74FTE3AJFJ256A. - Location *string `location:"header" locationName:"Location" type:"string"` -} - -// String returns the string representation -func (s CreateCloudFrontOriginAccessIdentityOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateCloudFrontOriginAccessIdentityOutput) GoString() string { - return s.String() -} - -// SetCloudFrontOriginAccessIdentity sets the CloudFrontOriginAccessIdentity field's value. -func (s *CreateCloudFrontOriginAccessIdentityOutput) SetCloudFrontOriginAccessIdentity(v *OriginAccessIdentity) *CreateCloudFrontOriginAccessIdentityOutput { - s.CloudFrontOriginAccessIdentity = v - return s -} - -// SetETag sets the ETag field's value. -func (s *CreateCloudFrontOriginAccessIdentityOutput) SetETag(v string) *CreateCloudFrontOriginAccessIdentityOutput { - s.ETag = &v - return s -} - -// SetLocation sets the Location field's value. -func (s *CreateCloudFrontOriginAccessIdentityOutput) SetLocation(v string) *CreateCloudFrontOriginAccessIdentityOutput { - s.Location = &v - return s -} - -// The request to create a new distribution. -type CreateDistributionInput struct { - _ struct{} `type:"structure" payload:"DistributionConfig"` - - // The distribution's configuration information. - // - // DistributionConfig is a required field - DistributionConfig *DistributionConfig `locationName:"DistributionConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-03-25/"` -} - -// String returns the string representation -func (s CreateDistributionInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateDistributionInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreateDistributionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateDistributionInput"} - if s.DistributionConfig == nil { - invalidParams.Add(request.NewErrParamRequired("DistributionConfig")) + if s.CustomErrorResponses != nil { + if err := s.CustomErrorResponses.Validate(); err != nil { + invalidParams.AddNested("CustomErrorResponses", err.(request.ErrInvalidParams)) + } } - if s.DistributionConfig != nil { - if err := s.DistributionConfig.Validate(); err != nil { - invalidParams.AddNested("DistributionConfig", err.(request.ErrInvalidParams)) + if s.DefaultCacheBehavior != nil { + if err := s.DefaultCacheBehavior.Validate(); err != nil { + invalidParams.AddNested("DefaultCacheBehavior", err.(request.ErrInvalidParams)) } } - - if invalidParams.Len() > 0 { - return invalidParams + if s.Logging != nil { + if err := s.Logging.Validate(); err != nil { + invalidParams.AddNested("Logging", err.(request.ErrInvalidParams)) + } + } + if s.Origins != nil { + if err := s.Origins.Validate(); err != nil { + invalidParams.AddNested("Origins", err.(request.ErrInvalidParams)) + } + } + if s.Restrictions != nil { + if err := s.Restrictions.Validate(); err != nil { + invalidParams.AddNested("Restrictions", err.(request.ErrInvalidParams)) + } } - return nil -} - -// SetDistributionConfig sets the DistributionConfig field's value. -func (s *CreateDistributionInput) SetDistributionConfig(v *DistributionConfig) *CreateDistributionInput { - s.DistributionConfig = v - return s -} - -// The returned result of the corresponding request. -type CreateDistributionOutput struct { - _ struct{} `type:"structure" payload:"Distribution"` - - // The distribution's information. - Distribution *Distribution `type:"structure"` - - // The current version of the distribution created. - ETag *string `location:"header" locationName:"ETag" type:"string"` - // The fully qualified URI of the new distribution resource just created. For - // example: https://cloudfront.amazonaws.com/2010-11-01/distribution/EDFDVBD632BHDS5. - Location *string `location:"header" locationName:"Location" type:"string"` + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// String returns the string representation -func (s CreateDistributionOutput) String() string { - return awsutil.Prettify(s) +// SetAliases sets the Aliases field's value. +func (s *DistributionConfig) SetAliases(v *Aliases) *DistributionConfig { + s.Aliases = v + return s } -// GoString returns the string representation -func (s CreateDistributionOutput) GoString() string { - return s.String() +// SetCacheBehaviors sets the CacheBehaviors field's value. +func (s *DistributionConfig) SetCacheBehaviors(v *CacheBehaviors) *DistributionConfig { + s.CacheBehaviors = v + return s } -// SetDistribution sets the Distribution field's value. -func (s *CreateDistributionOutput) SetDistribution(v *Distribution) *CreateDistributionOutput { - s.Distribution = v +// SetCallerReference sets the CallerReference field's value. +func (s *DistributionConfig) SetCallerReference(v string) *DistributionConfig { + s.CallerReference = &v return s } -// SetETag sets the ETag field's value. -func (s *CreateDistributionOutput) SetETag(v string) *CreateDistributionOutput { - s.ETag = &v +// SetComment sets the Comment field's value. +func (s *DistributionConfig) SetComment(v string) *DistributionConfig { + s.Comment = &v return s } -// SetLocation sets the Location field's value. -func (s *CreateDistributionOutput) SetLocation(v string) *CreateDistributionOutput { - s.Location = &v +// SetCustomErrorResponses sets the CustomErrorResponses field's value. +func (s *DistributionConfig) SetCustomErrorResponses(v *CustomErrorResponses) *DistributionConfig { + s.CustomErrorResponses = v return s } -// The request to create a new distribution with tags. -type CreateDistributionWithTagsInput struct { - _ struct{} `type:"structure" payload:"DistributionConfigWithTags"` - - // The distribution's configuration information. - // - // DistributionConfigWithTags is a required field - DistributionConfigWithTags *DistributionConfigWithTags `locationName:"DistributionConfigWithTags" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-03-25/"` +// SetDefaultCacheBehavior sets the DefaultCacheBehavior field's value. +func (s *DistributionConfig) SetDefaultCacheBehavior(v *DefaultCacheBehavior) *DistributionConfig { + s.DefaultCacheBehavior = v + return s } -// String returns the string representation -func (s CreateDistributionWithTagsInput) String() string { - return awsutil.Prettify(s) +// SetDefaultRootObject sets the DefaultRootObject field's value. +func (s *DistributionConfig) SetDefaultRootObject(v string) *DistributionConfig { + s.DefaultRootObject = &v + return s } -// GoString returns the string representation -func (s CreateDistributionWithTagsInput) GoString() string { - return s.String() +// SetEnabled sets the Enabled field's value. +func (s *DistributionConfig) SetEnabled(v bool) *DistributionConfig { + s.Enabled = &v + return s } -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreateDistributionWithTagsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateDistributionWithTagsInput"} - if s.DistributionConfigWithTags == nil { - invalidParams.Add(request.NewErrParamRequired("DistributionConfigWithTags")) - } - if s.DistributionConfigWithTags != nil { - if err := s.DistributionConfigWithTags.Validate(); err != nil { - invalidParams.AddNested("DistributionConfigWithTags", err.(request.ErrInvalidParams)) - } - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetHttpVersion sets the HttpVersion field's value. +func (s *DistributionConfig) SetHttpVersion(v string) *DistributionConfig { + s.HttpVersion = &v + return s } -// SetDistributionConfigWithTags sets the DistributionConfigWithTags field's value. -func (s *CreateDistributionWithTagsInput) SetDistributionConfigWithTags(v *DistributionConfigWithTags) *CreateDistributionWithTagsInput { - s.DistributionConfigWithTags = v +// SetIsIPV6Enabled sets the IsIPV6Enabled field's value. +func (s *DistributionConfig) SetIsIPV6Enabled(v bool) *DistributionConfig { + s.IsIPV6Enabled = &v return s } -// The returned result of the corresponding request. -type CreateDistributionWithTagsOutput struct { - _ struct{} `type:"structure" payload:"Distribution"` - - // The distribution's information. - Distribution *Distribution `type:"structure"` - - // The current version of the distribution created. - ETag *string `location:"header" locationName:"ETag" type:"string"` - - // The fully qualified URI of the new distribution resource just created. For - // example: https://cloudfront.amazonaws.com/2010-11-01/distribution/EDFDVBD632BHDS5. - Location *string `location:"header" locationName:"Location" type:"string"` +// SetLogging sets the Logging field's value. +func (s *DistributionConfig) SetLogging(v *LoggingConfig) *DistributionConfig { + s.Logging = v + return s } -// String returns the string representation -func (s CreateDistributionWithTagsOutput) String() string { - return awsutil.Prettify(s) +// SetOrigins sets the Origins field's value. +func (s *DistributionConfig) SetOrigins(v *Origins) *DistributionConfig { + s.Origins = v + return s } -// GoString returns the string representation -func (s CreateDistributionWithTagsOutput) GoString() string { - return s.String() +// SetPriceClass sets the PriceClass field's value. +func (s *DistributionConfig) SetPriceClass(v string) *DistributionConfig { + s.PriceClass = &v + return s } -// SetDistribution sets the Distribution field's value. -func (s *CreateDistributionWithTagsOutput) SetDistribution(v *Distribution) *CreateDistributionWithTagsOutput { - s.Distribution = v +// SetRestrictions sets the Restrictions field's value. +func (s *DistributionConfig) SetRestrictions(v *Restrictions) *DistributionConfig { + s.Restrictions = v return s } -// SetETag sets the ETag field's value. -func (s *CreateDistributionWithTagsOutput) SetETag(v string) *CreateDistributionWithTagsOutput { - s.ETag = &v +// SetViewerCertificate sets the ViewerCertificate field's value. +func (s *DistributionConfig) SetViewerCertificate(v *ViewerCertificate) *DistributionConfig { + s.ViewerCertificate = v return s } -// SetLocation sets the Location field's value. -func (s *CreateDistributionWithTagsOutput) SetLocation(v string) *CreateDistributionWithTagsOutput { - s.Location = &v +// SetWebACLId sets the WebACLId field's value. +func (s *DistributionConfig) SetWebACLId(v string) *DistributionConfig { + s.WebACLId = &v return s } -// The request to create an invalidation. -type CreateInvalidationInput struct { - _ struct{} `type:"structure" payload:"InvalidationBatch"` +// A distribution Configuration and a list of tags to be associated with the +// distribution. +type DistributionConfigWithTags struct { + _ struct{} `type:"structure"` - // The distribution's id. + // A distribution configuration. // - // DistributionId is a required field - DistributionId *string `location:"uri" locationName:"DistributionId" type:"string" required:"true"` + // DistributionConfig is a required field + DistributionConfig *DistributionConfig `type:"structure" required:"true"` - // The batch information for the invalidation. + // A complex type that contains zero or more Tag elements. // - // InvalidationBatch is a required field - InvalidationBatch *InvalidationBatch `locationName:"InvalidationBatch" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-03-25/"` + // Tags is a required field + Tags *Tags `type:"structure" required:"true"` } // String returns the string representation -func (s CreateInvalidationInput) String() string { +func (s DistributionConfigWithTags) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s CreateInvalidationInput) GoString() string { +func (s DistributionConfigWithTags) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *CreateInvalidationInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateInvalidationInput"} - if s.DistributionId == nil { - invalidParams.Add(request.NewErrParamRequired("DistributionId")) +func (s *DistributionConfigWithTags) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DistributionConfigWithTags"} + if s.DistributionConfig == nil { + invalidParams.Add(request.NewErrParamRequired("DistributionConfig")) } - if s.InvalidationBatch == nil { - invalidParams.Add(request.NewErrParamRequired("InvalidationBatch")) + if s.Tags == nil { + invalidParams.Add(request.NewErrParamRequired("Tags")) } - if s.InvalidationBatch != nil { - if err := s.InvalidationBatch.Validate(); err != nil { - invalidParams.AddNested("InvalidationBatch", err.(request.ErrInvalidParams)) + if s.DistributionConfig != nil { + if err := s.DistributionConfig.Validate(); err != nil { + invalidParams.AddNested("DistributionConfig", err.(request.ErrInvalidParams)) + } + } + if s.Tags != nil { + if err := s.Tags.Validate(); err != nil { + invalidParams.AddNested("Tags", err.(request.ErrInvalidParams)) } } @@ -4256,451 +8268,435 @@ func (s *CreateInvalidationInput) Validate() error { return nil } -// SetDistributionId sets the DistributionId field's value. -func (s *CreateInvalidationInput) SetDistributionId(v string) *CreateInvalidationInput { - s.DistributionId = &v +// SetDistributionConfig sets the DistributionConfig field's value. +func (s *DistributionConfigWithTags) SetDistributionConfig(v *DistributionConfig) *DistributionConfigWithTags { + s.DistributionConfig = v return s } -// SetInvalidationBatch sets the InvalidationBatch field's value. -func (s *CreateInvalidationInput) SetInvalidationBatch(v *InvalidationBatch) *CreateInvalidationInput { - s.InvalidationBatch = v +// SetTags sets the Tags field's value. +func (s *DistributionConfigWithTags) SetTags(v *Tags) *DistributionConfigWithTags { + s.Tags = v return s } -// The returned result of the corresponding request. -type CreateInvalidationOutput struct { - _ struct{} `type:"structure" payload:"Invalidation"` +// A distribution list. +type DistributionList struct { + _ struct{} `type:"structure"` - // The invalidation's information. - Invalidation *Invalidation `type:"structure"` + // A flag that indicates whether more distributions remain to be listed. If + // your results were truncated, you can make a follow-up pagination request + // using the Marker request parameter to retrieve more distributions in the + // list. + // + // IsTruncated is a required field + IsTruncated *bool `type:"boolean" required:"true"` - // The fully qualified URI of the distribution and invalidation batch request, - // including the Invalidation ID. - Location *string `location:"header" locationName:"Location" type:"string"` + // A complex type that contains one DistributionSummary element for each distribution + // that was created by the current AWS account. + Items []*DistributionSummary `locationNameList:"DistributionSummary" type:"list"` + + // The value you provided for the Marker request parameter. + // + // Marker is a required field + Marker *string `type:"string" required:"true"` + + // The value you provided for the MaxItems request parameter. + // + // MaxItems is a required field + MaxItems *int64 `type:"integer" required:"true"` + + // If IsTruncated is true, this element is present and contains the value you + // can use for the Marker request parameter to continue listing your distributions + // where they left off. + NextMarker *string `type:"string"` + + // The number of distributions that were created by the current AWS account. + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` +} + +// String returns the string representation +func (s DistributionList) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DistributionList) GoString() string { + return s.String() +} + +// SetIsTruncated sets the IsTruncated field's value. +func (s *DistributionList) SetIsTruncated(v bool) *DistributionList { + s.IsTruncated = &v + return s +} + +// SetItems sets the Items field's value. +func (s *DistributionList) SetItems(v []*DistributionSummary) *DistributionList { + s.Items = v + return s } -// String returns the string representation -func (s CreateInvalidationOutput) String() string { - return awsutil.Prettify(s) +// SetMarker sets the Marker field's value. +func (s *DistributionList) SetMarker(v string) *DistributionList { + s.Marker = &v + return s } -// GoString returns the string representation -func (s CreateInvalidationOutput) GoString() string { - return s.String() +// SetMaxItems sets the MaxItems field's value. +func (s *DistributionList) SetMaxItems(v int64) *DistributionList { + s.MaxItems = &v + return s } -// SetInvalidation sets the Invalidation field's value. -func (s *CreateInvalidationOutput) SetInvalidation(v *Invalidation) *CreateInvalidationOutput { - s.Invalidation = v +// SetNextMarker sets the NextMarker field's value. +func (s *DistributionList) SetNextMarker(v string) *DistributionList { + s.NextMarker = &v return s } -// SetLocation sets the Location field's value. -func (s *CreateInvalidationOutput) SetLocation(v string) *CreateInvalidationOutput { - s.Location = &v +// SetQuantity sets the Quantity field's value. +func (s *DistributionList) SetQuantity(v int64) *DistributionList { + s.Quantity = &v return s } -// The request to create a new streaming distribution. -type CreateStreamingDistributionInput struct { - _ struct{} `type:"structure" payload:"StreamingDistributionConfig"` +// A summary of the information about a CloudFront distribution. +type DistributionSummary struct { + _ struct{} `type:"structure"` - // The streaming distribution's configuration information. + // The ARN (Amazon Resource Name) for the distribution. For example: arn:aws:cloudfront::123456789012:distribution/EDFDVBD632BHDS5, + // where 123456789012 is your AWS account ID. // - // StreamingDistributionConfig is a required field - StreamingDistributionConfig *StreamingDistributionConfig `locationName:"StreamingDistributionConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-03-25/"` -} + // ARN is a required field + ARN *string `type:"string" required:"true"` -// String returns the string representation -func (s CreateStreamingDistributionInput) String() string { - return awsutil.Prettify(s) -} + // A complex type that contains information about CNAMEs (alternate domain names), + // if any, for this distribution. + // + // Aliases is a required field + Aliases *Aliases `type:"structure" required:"true"` -// GoString returns the string representation -func (s CreateStreamingDistributionInput) GoString() string { - return s.String() -} + // A complex type that contains zero or more CacheBehavior elements. + // + // CacheBehaviors is a required field + CacheBehaviors *CacheBehaviors `type:"structure" required:"true"` -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreateStreamingDistributionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateStreamingDistributionInput"} - if s.StreamingDistributionConfig == nil { - invalidParams.Add(request.NewErrParamRequired("StreamingDistributionConfig")) - } - if s.StreamingDistributionConfig != nil { - if err := s.StreamingDistributionConfig.Validate(); err != nil { - invalidParams.AddNested("StreamingDistributionConfig", err.(request.ErrInvalidParams)) - } - } + // The comment originally specified when this distribution was created. + // + // Comment is a required field + Comment *string `type:"string" required:"true"` - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} + // A complex type that contains zero or more CustomErrorResponses elements. + // + // CustomErrorResponses is a required field + CustomErrorResponses *CustomErrorResponses `type:"structure" required:"true"` -// SetStreamingDistributionConfig sets the StreamingDistributionConfig field's value. -func (s *CreateStreamingDistributionInput) SetStreamingDistributionConfig(v *StreamingDistributionConfig) *CreateStreamingDistributionInput { - s.StreamingDistributionConfig = v - return s -} + // A complex type that describes the default cache behavior if you don't specify + // a CacheBehavior element or if files don't match any of the values of PathPattern + // in CacheBehavior elements. You must create exactly one default cache behavior. + // + // DefaultCacheBehavior is a required field + DefaultCacheBehavior *DefaultCacheBehavior `type:"structure" required:"true"` -// The returned result of the corresponding request. -type CreateStreamingDistributionOutput struct { - _ struct{} `type:"structure" payload:"StreamingDistribution"` + // The domain name that corresponds to the distribution, for example, d111111abcdef8.cloudfront.net. + // + // DomainName is a required field + DomainName *string `type:"string" required:"true"` - // The current version of the streaming distribution created. - ETag *string `location:"header" locationName:"ETag" type:"string"` + // Whether the distribution is enabled to accept user requests for content. + // + // Enabled is a required field + Enabled *bool `type:"boolean" required:"true"` - // The fully qualified URI of the new streaming distribution resource just created. - // For example: https://cloudfront.amazonaws.com/2010-11-01/streaming-distribution/EGTXBD79H29TRA8. - Location *string `location:"header" locationName:"Location" type:"string"` + // Specify the maximum HTTP version that you want viewers to use to communicate + // with CloudFront. The default value for new web distributions is http2. Viewers + // that don't support HTTP/2 will automatically use an earlier version. + // + // HttpVersion is a required field + HttpVersion *string `type:"string" required:"true" enum:"HttpVersion"` - // The streaming distribution's information. - StreamingDistribution *StreamingDistribution `type:"structure"` -} + // The identifier for the distribution. For example: EDFDVBD632BHDS5. + // + // Id is a required field + Id *string `type:"string" required:"true"` -// String returns the string representation -func (s CreateStreamingDistributionOutput) String() string { - return awsutil.Prettify(s) -} + // Whether CloudFront responds to IPv6 DNS requests with an IPv6 address for + // your distribution. + // + // IsIPV6Enabled is a required field + IsIPV6Enabled *bool `type:"boolean" required:"true"` -// GoString returns the string representation -func (s CreateStreamingDistributionOutput) GoString() string { - return s.String() -} + // The date and time the distribution was last modified. + // + // LastModifiedTime is a required field + LastModifiedTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"` -// SetETag sets the ETag field's value. -func (s *CreateStreamingDistributionOutput) SetETag(v string) *CreateStreamingDistributionOutput { - s.ETag = &v - return s -} + // A complex type that contains information about origins for this distribution. + // + // Origins is a required field + Origins *Origins `type:"structure" required:"true"` -// SetLocation sets the Location field's value. -func (s *CreateStreamingDistributionOutput) SetLocation(v string) *CreateStreamingDistributionOutput { - s.Location = &v - return s -} + // PriceClass is a required field + PriceClass *string `type:"string" required:"true" enum:"PriceClass"` -// SetStreamingDistribution sets the StreamingDistribution field's value. -func (s *CreateStreamingDistributionOutput) SetStreamingDistribution(v *StreamingDistribution) *CreateStreamingDistributionOutput { - s.StreamingDistribution = v - return s -} + // A complex type that identifies ways in which you want to restrict distribution + // of your content. + // + // Restrictions is a required field + Restrictions *Restrictions `type:"structure" required:"true"` -// The request to create a new streaming distribution with tags. -type CreateStreamingDistributionWithTagsInput struct { - _ struct{} `type:"structure" payload:"StreamingDistributionConfigWithTags"` + // The current status of the distribution. When the status is Deployed, the + // distribution's information is propagated to all CloudFront edge locations. + // + // Status is a required field + Status *string `type:"string" required:"true"` + + // A complex type that specifies the following: + // + // * Whether you want viewers to use HTTP or HTTPS to request your objects. + // + // * If you want viewers to use HTTPS, whether you're using an alternate + // domain name such as example.com or the CloudFront domain name for your + // distribution, such as d111111abcdef8.cloudfront.net. + // + // * If you're using an alternate domain name, whether AWS Certificate Manager + // (ACM) provided the certificate, or you purchased a certificate from a + // third-party certificate authority and imported it into ACM or uploaded + // it to the IAM certificate store. + // + // You must specify only one of the following values: + // + // * ViewerCertificate$ACMCertificateArn + // + // * ViewerCertificate$IAMCertificateId + // + // * ViewerCertificate$CloudFrontDefaultCertificate + // + // Don't specify false for CloudFrontDefaultCertificate. + // + // If you want viewers to use HTTP instead of HTTPS to request your objects: + // Specify the following value: + // + // true + // + // In addition, specify allow-all for ViewerProtocolPolicy for all of your cache + // behaviors. + // + // If you want viewers to use HTTPS to request your objects: Choose the type + // of certificate that you want to use based on whether you're using an alternate + // domain name for your objects or the CloudFront domain name: + // + // * If you're using an alternate domain name, such as example.com: Specify + // one of the following values, depending on whether ACM provided your certificate + // or you purchased your certificate from third-party certificate authority: + // + // ARN for ACM SSL/TLS certificate where + // ARN for ACM SSL/TLS certificate is the ARN for the ACM SSL/TLS certificate + // that you want to use for this distribution. + // + // IAM certificate ID where IAM certificate + // ID is the ID that IAM returned when you added the certificate to the IAM + // certificate store. + // + // If you specify ACMCertificateArn or IAMCertificateId, you must also specify + // a value for SSLSupportMethod. + // + // If you choose to use an ACM certificate or a certificate in the IAM certificate + // store, we recommend that you use only an alternate domain name in your + // object URLs (https://example.com/logo.jpg). If you use the domain name + // that is associated with your CloudFront distribution (such as https://d111111abcdef8.cloudfront.net/logo.jpg) + // and the viewer supports SNI, then CloudFront behaves normally. However, + // if the browser does not support SNI, the user's experience depends on + // the value that you choose for SSLSupportMethod: + // + // vip: The viewer displays a warning because there is a mismatch between the + // CloudFront domain name and the domain name in your SSL/TLS certificate. + // + // sni-only: CloudFront drops the connection with the browser without returning + // the object. + // + // * If you're using the CloudFront domain name for your distribution, such + // as d111111abcdef8.cloudfront.net: Specify the following value: + // + // true + // + // If you want viewers to use HTTPS, you must also specify one of the following + // values in your cache behaviors: + // + // * https-only + // + // * redirect-to-https + // + // You can also optionally require that CloudFront use HTTPS to communicate + // with your origin by specifying one of the following values for the applicable + // origins: + // + // * https-only + // + // * match-viewer + // + // For more information, see Using Alternate Domain Names and HTTPS (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/SecureConnections.html#CNAMEsAndHTTPS) + // in the Amazon CloudFront Developer Guide. + // + // ViewerCertificate is a required field + ViewerCertificate *ViewerCertificate `type:"structure" required:"true"` - // The streaming distribution's configuration information. + // The Web ACL Id (if any) associated with the distribution. // - // StreamingDistributionConfigWithTags is a required field - StreamingDistributionConfigWithTags *StreamingDistributionConfigWithTags `locationName:"StreamingDistributionConfigWithTags" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-03-25/"` + // WebACLId is a required field + WebACLId *string `type:"string" required:"true"` } // String returns the string representation -func (s CreateStreamingDistributionWithTagsInput) String() string { +func (s DistributionSummary) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s CreateStreamingDistributionWithTagsInput) GoString() string { +func (s DistributionSummary) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreateStreamingDistributionWithTagsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateStreamingDistributionWithTagsInput"} - if s.StreamingDistributionConfigWithTags == nil { - invalidParams.Add(request.NewErrParamRequired("StreamingDistributionConfigWithTags")) - } - if s.StreamingDistributionConfigWithTags != nil { - if err := s.StreamingDistributionConfigWithTags.Validate(); err != nil { - invalidParams.AddNested("StreamingDistributionConfigWithTags", err.(request.ErrInvalidParams)) - } - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetStreamingDistributionConfigWithTags sets the StreamingDistributionConfigWithTags field's value. -func (s *CreateStreamingDistributionWithTagsInput) SetStreamingDistributionConfigWithTags(v *StreamingDistributionConfigWithTags) *CreateStreamingDistributionWithTagsInput { - s.StreamingDistributionConfigWithTags = v +// SetARN sets the ARN field's value. +func (s *DistributionSummary) SetARN(v string) *DistributionSummary { + s.ARN = &v return s } -// The returned result of the corresponding request. -type CreateStreamingDistributionWithTagsOutput struct { - _ struct{} `type:"structure" payload:"StreamingDistribution"` - - ETag *string `location:"header" locationName:"ETag" type:"string"` - - // The fully qualified URI of the new streaming distribution resource just created. - // For example: https://cloudfront.amazonaws.com/2010-11-01/streaming-distribution/EGTXBD79H29TRA8. - Location *string `location:"header" locationName:"Location" type:"string"` - - // The streaming distribution's information. - StreamingDistribution *StreamingDistribution `type:"structure"` -} - -// String returns the string representation -func (s CreateStreamingDistributionWithTagsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateStreamingDistributionWithTagsOutput) GoString() string { - return s.String() -} - -// SetETag sets the ETag field's value. -func (s *CreateStreamingDistributionWithTagsOutput) SetETag(v string) *CreateStreamingDistributionWithTagsOutput { - s.ETag = &v +// SetAliases sets the Aliases field's value. +func (s *DistributionSummary) SetAliases(v *Aliases) *DistributionSummary { + s.Aliases = v return s } -// SetLocation sets the Location field's value. -func (s *CreateStreamingDistributionWithTagsOutput) SetLocation(v string) *CreateStreamingDistributionWithTagsOutput { - s.Location = &v +// SetCacheBehaviors sets the CacheBehaviors field's value. +func (s *DistributionSummary) SetCacheBehaviors(v *CacheBehaviors) *DistributionSummary { + s.CacheBehaviors = v return s } -// SetStreamingDistribution sets the StreamingDistribution field's value. -func (s *CreateStreamingDistributionWithTagsOutput) SetStreamingDistribution(v *StreamingDistribution) *CreateStreamingDistributionWithTagsOutput { - s.StreamingDistribution = v +// SetComment sets the Comment field's value. +func (s *DistributionSummary) SetComment(v string) *DistributionSummary { + s.Comment = &v return s } -// A complex type that controls: -// -// * Whether CloudFront replaces HTTP status codes in the 4xx and 5xx range -// with custom error messages before returning the response to the viewer. -// -// -// * How long CloudFront caches HTTP status codes in the 4xx and 5xx range. -// -// For more information about custom error pages, see Customizing Error Responses -// (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/custom-error-pages.html) -// in the Amazon CloudFront Developer Guide. -type CustomErrorResponse struct { - _ struct{} `type:"structure"` - - // The minimum amount of time, in seconds, that you want CloudFront to cache - // the HTTP status code specified in ErrorCode. When this time period has elapsed, - // CloudFront queries your origin to see whether the problem that caused the - // error has been resolved and the requested object is now available. - // - // If you don't want to specify a value, include an empty element, , - // in the XML document. - // - // For more information, see Customizing Error Responses (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/custom-error-pages.html) - // in the Amazon CloudFront Developer Guide. - ErrorCachingMinTTL *int64 `type:"long"` - - // The HTTP status code for which you want to specify a custom error page and/or - // a caching duration. - // - // ErrorCode is a required field - ErrorCode *int64 `type:"integer" required:"true"` - - // The HTTP status code that you want CloudFront to return to the viewer along - // with the custom error page. There are a variety of reasons that you might - // want CloudFront to return a status code different from the status code that - // your origin returned to CloudFront, for example: - // - // * Some Internet devices (some firewalls and corporate proxies, for example) - // intercept HTTP 4xx and 5xx and prevent the response from being returned - // to the viewer. If you substitute 200, the response typically won't be - // intercepted. - // - // * If you don't care about distinguishing among different client errors - // or server errors, you can specify 400 or 500 as the ResponseCode for all - // 4xx or 5xx errors. - // - // * You might want to return a 200 status code (OK) and static website so - // your customers don't know that your website is down. - // - // If you specify a value for ResponseCode, you must also specify a value for - // ResponsePagePath. If you don't want to specify a value, include an empty - // element, , in the XML document. - ResponseCode *string `type:"string"` - - // The path to the custom error page that you want CloudFront to return to a - // viewer when your origin returns the HTTP status code specified by ErrorCode, - // for example, /4xx-errors/403-forbidden.html. If you want to store your objects - // and your custom error pages in different locations, your distribution must - // include a cache behavior for which the following is true: - // - // * The value of PathPattern matches the path to your custom error messages. - // For example, suppose you saved custom error pages for 4xx errors in an - // Amazon S3 bucket in a directory named /4xx-errors. Your distribution must - // include a cache behavior for which the path pattern routes requests for - // your custom error pages to that location, for example, /4xx-errors/*. - // - // - // * The value of TargetOriginId specifies the value of the ID element for - // the origin that contains your custom error pages. - // - // If you specify a value for ResponsePagePath, you must also specify a value - // for ResponseCode. If you don't want to specify a value, include an empty - // element, , in the XML document. - // - // We recommend that you store custom error pages in an Amazon S3 bucket. If - // you store custom error pages on an HTTP server and the server starts to return - // 5xx errors, CloudFront can't get the files that you want to return to viewers - // because the origin server is unavailable. - ResponsePagePath *string `type:"string"` -} - -// String returns the string representation -func (s CustomErrorResponse) String() string { - return awsutil.Prettify(s) +// SetCustomErrorResponses sets the CustomErrorResponses field's value. +func (s *DistributionSummary) SetCustomErrorResponses(v *CustomErrorResponses) *DistributionSummary { + s.CustomErrorResponses = v + return s } -// GoString returns the string representation -func (s CustomErrorResponse) GoString() string { - return s.String() +// SetDefaultCacheBehavior sets the DefaultCacheBehavior field's value. +func (s *DistributionSummary) SetDefaultCacheBehavior(v *DefaultCacheBehavior) *DistributionSummary { + s.DefaultCacheBehavior = v + return s } -// Validate inspects the fields of the type to determine if they are valid. -func (s *CustomErrorResponse) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CustomErrorResponse"} - if s.ErrorCode == nil { - invalidParams.Add(request.NewErrParamRequired("ErrorCode")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetDomainName sets the DomainName field's value. +func (s *DistributionSummary) SetDomainName(v string) *DistributionSummary { + s.DomainName = &v + return s } -// SetErrorCachingMinTTL sets the ErrorCachingMinTTL field's value. -func (s *CustomErrorResponse) SetErrorCachingMinTTL(v int64) *CustomErrorResponse { - s.ErrorCachingMinTTL = &v +// SetEnabled sets the Enabled field's value. +func (s *DistributionSummary) SetEnabled(v bool) *DistributionSummary { + s.Enabled = &v return s } -// SetErrorCode sets the ErrorCode field's value. -func (s *CustomErrorResponse) SetErrorCode(v int64) *CustomErrorResponse { - s.ErrorCode = &v +// SetHttpVersion sets the HttpVersion field's value. +func (s *DistributionSummary) SetHttpVersion(v string) *DistributionSummary { + s.HttpVersion = &v return s } -// SetResponseCode sets the ResponseCode field's value. -func (s *CustomErrorResponse) SetResponseCode(v string) *CustomErrorResponse { - s.ResponseCode = &v +// SetId sets the Id field's value. +func (s *DistributionSummary) SetId(v string) *DistributionSummary { + s.Id = &v return s } -// SetResponsePagePath sets the ResponsePagePath field's value. -func (s *CustomErrorResponse) SetResponsePagePath(v string) *CustomErrorResponse { - s.ResponsePagePath = &v +// SetIsIPV6Enabled sets the IsIPV6Enabled field's value. +func (s *DistributionSummary) SetIsIPV6Enabled(v bool) *DistributionSummary { + s.IsIPV6Enabled = &v return s } -// A complex type that controls: -// -// * Whether CloudFront replaces HTTP status codes in the 4xx and 5xx range -// with custom error messages before returning the response to the viewer. -// -// * How long CloudFront caches HTTP status codes in the 4xx and 5xx range. -// -// For more information about custom error pages, see Customizing Error Responses -// (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/custom-error-pages.html) -// in the Amazon CloudFront Developer Guide. -type CustomErrorResponses struct { - _ struct{} `type:"structure"` - - // A complex type that contains a CustomErrorResponse element for each HTTP - // status code for which you want to specify a custom error page and/or a caching - // duration. - Items []*CustomErrorResponse `locationNameList:"CustomErrorResponse" type:"list"` - - // The number of HTTP status codes for which you want to specify a custom error - // page and/or a caching duration. If Quantity is 0, you can omit Items. - // - // Quantity is a required field - Quantity *int64 `type:"integer" required:"true"` +// SetLastModifiedTime sets the LastModifiedTime field's value. +func (s *DistributionSummary) SetLastModifiedTime(v time.Time) *DistributionSummary { + s.LastModifiedTime = &v + return s } -// String returns the string representation -func (s CustomErrorResponses) String() string { - return awsutil.Prettify(s) +// SetOrigins sets the Origins field's value. +func (s *DistributionSummary) SetOrigins(v *Origins) *DistributionSummary { + s.Origins = v + return s } -// GoString returns the string representation -func (s CustomErrorResponses) GoString() string { - return s.String() +// SetPriceClass sets the PriceClass field's value. +func (s *DistributionSummary) SetPriceClass(v string) *DistributionSummary { + s.PriceClass = &v + return s } -// Validate inspects the fields of the type to determine if they are valid. -func (s *CustomErrorResponses) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CustomErrorResponses"} - if s.Quantity == nil { - invalidParams.Add(request.NewErrParamRequired("Quantity")) - } - if s.Items != nil { - for i, v := range s.Items { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Items", i), err.(request.ErrInvalidParams)) - } - } - } +// SetRestrictions sets the Restrictions field's value. +func (s *DistributionSummary) SetRestrictions(v *Restrictions) *DistributionSummary { + s.Restrictions = v + return s +} - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetStatus sets the Status field's value. +func (s *DistributionSummary) SetStatus(v string) *DistributionSummary { + s.Status = &v + return s } -// SetItems sets the Items field's value. -func (s *CustomErrorResponses) SetItems(v []*CustomErrorResponse) *CustomErrorResponses { - s.Items = v +// SetViewerCertificate sets the ViewerCertificate field's value. +func (s *DistributionSummary) SetViewerCertificate(v *ViewerCertificate) *DistributionSummary { + s.ViewerCertificate = v return s } -// SetQuantity sets the Quantity field's value. -func (s *CustomErrorResponses) SetQuantity(v int64) *CustomErrorResponses { - s.Quantity = &v +// SetWebACLId sets the WebACLId field's value. +func (s *DistributionSummary) SetWebACLId(v string) *DistributionSummary { + s.WebACLId = &v return s } -// A complex type that contains the list of Custom Headers for each origin. -type CustomHeaders struct { +// Complex data type for field-level encryption profiles that includes all of +// the encryption entities. +type EncryptionEntities struct { _ struct{} `type:"structure"` - // Optional: A list that contains one OriginCustomHeader element for each custom - // header that you want CloudFront to forward to the origin. If Quantity is - // 0, omit Items. - Items []*OriginCustomHeader `locationNameList:"OriginCustomHeader" type:"list"` + // An array of field patterns in a field-level encryption content type-profile + // mapping. + Items []*EncryptionEntity `locationNameList:"EncryptionEntity" type:"list"` - // The number of custom headers, if any, for this distribution. + // Number of field pattern items in a field-level encryption content type-profile + // mapping. // // Quantity is a required field Quantity *int64 `type:"integer" required:"true"` } // String returns the string representation -func (s CustomHeaders) String() string { +func (s EncryptionEntities) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s CustomHeaders) GoString() string { +func (s EncryptionEntities) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *CustomHeaders) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CustomHeaders"} +func (s *EncryptionEntities) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "EncryptionEntities"} if s.Quantity == nil { invalidParams.Add(request.NewErrParamRequired("Quantity")) } @@ -4722,84 +8718,70 @@ func (s *CustomHeaders) Validate() error { } // SetItems sets the Items field's value. -func (s *CustomHeaders) SetItems(v []*OriginCustomHeader) *CustomHeaders { +func (s *EncryptionEntities) SetItems(v []*EncryptionEntity) *EncryptionEntities { s.Items = v return s } // SetQuantity sets the Quantity field's value. -func (s *CustomHeaders) SetQuantity(v int64) *CustomHeaders { +func (s *EncryptionEntities) SetQuantity(v int64) *EncryptionEntities { s.Quantity = &v return s } -// A customer origin. -type CustomOriginConfig struct { +// Complex data type for field-level encryption profiles that includes the encryption +// key and field pattern specifications. +type EncryptionEntity struct { _ struct{} `type:"structure"` - // The HTTP port the custom origin listens on. - // - // HTTPPort is a required field - HTTPPort *int64 `type:"integer" required:"true"` - - // The HTTPS port the custom origin listens on. - // - // HTTPSPort is a required field - HTTPSPort *int64 `type:"integer" required:"true"` - - // You can create a custom keep-alive timeout. All timeout units are in seconds. - // The default keep-alive timeout is 5 seconds, but you can configure custom - // timeout lengths using the CloudFront API. The minimum timeout length is 1 - // second; the maximum is 60 seconds. + // Field patterns in a field-level encryption content type profile specify the + // fields that you want to be encrypted. You can provide the full field name, + // or any beginning characters followed by a wildcard (*). You can't overlap + // field patterns. For example, you can't have both ABC* and AB*. Note that + // field patterns are case-sensitive. // - // If you need to increase the maximum time limit, contact the AWS Support Center - // (https://console.aws.amazon.com/support/home#/). - OriginKeepaliveTimeout *int64 `type:"integer"` + // FieldPatterns is a required field + FieldPatterns *FieldPatterns `type:"structure" required:"true"` - // The origin protocol policy to apply to your origin. + // The provider associated with the public key being used for encryption. This + // value must also be provided with the private key for applications to be able + // to decrypt data. // - // OriginProtocolPolicy is a required field - OriginProtocolPolicy *string `type:"string" required:"true" enum:"OriginProtocolPolicy"` + // ProviderId is a required field + ProviderId *string `type:"string" required:"true"` - // You can create a custom origin read timeout. All timeout units are in seconds. - // The default origin read timeout is 30 seconds, but you can configure custom - // timeout lengths using the CloudFront API. The minimum timeout length is 4 - // seconds; the maximum is 60 seconds. + // The public key associated with a set of field-level encryption patterns, + // to be used when encrypting the fields that match the patterns. // - // If you need to increase the maximum time limit, contact the AWS Support Center - // (https://console.aws.amazon.com/support/home#/). - OriginReadTimeout *int64 `type:"integer"` - - // The SSL/TLS protocols that you want CloudFront to use when communicating - // with your origin over HTTPS. - OriginSslProtocols *OriginSslProtocols `type:"structure"` + // PublicKeyId is a required field + PublicKeyId *string `type:"string" required:"true"` } // String returns the string representation -func (s CustomOriginConfig) String() string { +func (s EncryptionEntity) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s CustomOriginConfig) GoString() string { +func (s EncryptionEntity) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *CustomOriginConfig) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CustomOriginConfig"} - if s.HTTPPort == nil { - invalidParams.Add(request.NewErrParamRequired("HTTPPort")) +func (s *EncryptionEntity) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "EncryptionEntity"} + if s.FieldPatterns == nil { + invalidParams.Add(request.NewErrParamRequired("FieldPatterns")) } - if s.HTTPSPort == nil { - invalidParams.Add(request.NewErrParamRequired("HTTPSPort")) + if s.ProviderId == nil { + invalidParams.Add(request.NewErrParamRequired("ProviderId")) } - if s.OriginProtocolPolicy == nil { - invalidParams.Add(request.NewErrParamRequired("OriginProtocolPolicy")) + if s.PublicKeyId == nil { + invalidParams.Add(request.NewErrParamRequired("PublicKeyId")) } - if s.OriginSslProtocols != nil { - if err := s.OriginSslProtocols.Validate(); err != nil { - invalidParams.AddNested("OriginSslProtocols", err.(request.ErrInvalidParams)) + if s.FieldPatterns != nil { + if err := s.FieldPatterns.Validate(); err != nil { + invalidParams.AddNested("FieldPatterns", err.(request.ErrInvalidParams)) } } @@ -4809,214 +8791,123 @@ func (s *CustomOriginConfig) Validate() error { return nil } -// SetHTTPPort sets the HTTPPort field's value. -func (s *CustomOriginConfig) SetHTTPPort(v int64) *CustomOriginConfig { - s.HTTPPort = &v - return s -} - -// SetHTTPSPort sets the HTTPSPort field's value. -func (s *CustomOriginConfig) SetHTTPSPort(v int64) *CustomOriginConfig { - s.HTTPSPort = &v - return s -} - -// SetOriginKeepaliveTimeout sets the OriginKeepaliveTimeout field's value. -func (s *CustomOriginConfig) SetOriginKeepaliveTimeout(v int64) *CustomOriginConfig { - s.OriginKeepaliveTimeout = &v - return s -} - -// SetOriginProtocolPolicy sets the OriginProtocolPolicy field's value. -func (s *CustomOriginConfig) SetOriginProtocolPolicy(v string) *CustomOriginConfig { - s.OriginProtocolPolicy = &v +// SetFieldPatterns sets the FieldPatterns field's value. +func (s *EncryptionEntity) SetFieldPatterns(v *FieldPatterns) *EncryptionEntity { + s.FieldPatterns = v return s } -// SetOriginReadTimeout sets the OriginReadTimeout field's value. -func (s *CustomOriginConfig) SetOriginReadTimeout(v int64) *CustomOriginConfig { - s.OriginReadTimeout = &v +// SetProviderId sets the ProviderId field's value. +func (s *EncryptionEntity) SetProviderId(v string) *EncryptionEntity { + s.ProviderId = &v return s } -// SetOriginSslProtocols sets the OriginSslProtocols field's value. -func (s *CustomOriginConfig) SetOriginSslProtocols(v *OriginSslProtocols) *CustomOriginConfig { - s.OriginSslProtocols = v +// SetPublicKeyId sets the PublicKeyId field's value. +func (s *EncryptionEntity) SetPublicKeyId(v string) *EncryptionEntity { + s.PublicKeyId = &v return s } -// A complex type that describes the default cache behavior if you don't specify -// a CacheBehavior element or if files don't match any of the values of PathPattern -// in CacheBehavior elements. You must create exactly one default cache behavior. -type DefaultCacheBehavior struct { +// A complex data type that includes the profile configurations and other options +// specified for field-level encryption. +type FieldLevelEncryption struct { _ struct{} `type:"structure"` - // A complex type that controls which HTTP methods CloudFront processes and - // forwards to your Amazon S3 bucket or your custom origin. There are three - // choices: + // A complex data type that includes the profile configurations specified for + // field-level encryption. // - // * CloudFront forwards only GET and HEAD requests. - // - // * CloudFront forwards only GET, HEAD, and OPTIONS requests. - // - // * CloudFront forwards GET, HEAD, OPTIONS, PUT, PATCH, POST, and DELETE - // requests. - // - // If you pick the third choice, you may need to restrict access to your Amazon - // S3 bucket or to your custom origin so users can't perform operations that - // you don't want them to. For example, you might not want users to have permissions - // to delete objects from your origin. - AllowedMethods *AllowedMethods `type:"structure"` - - // Whether you want CloudFront to automatically compress certain files for this - // cache behavior. If so, specify true; if not, specify false. For more information, - // see Serving Compressed Files (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/ServingCompressedFiles.html) - // in the Amazon CloudFront Developer Guide. - Compress *bool `type:"boolean"` - - // The default amount of time that you want objects to stay in CloudFront caches - // before CloudFront forwards another request to your origin to determine whether - // the object has been updated. The value that you specify applies only when - // your origin does not add HTTP headers such as Cache-Control max-age, Cache-Control - // s-maxage, and Expires to objects. For more information, see Specifying How - // Long Objects and Errors Stay in a CloudFront Edge Cache (Expiration) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html) - // in the Amazon CloudFront Developer Guide. - DefaultTTL *int64 `type:"long"` + // FieldLevelEncryptionConfig is a required field + FieldLevelEncryptionConfig *FieldLevelEncryptionConfig `type:"structure" required:"true"` - // A complex type that specifies how CloudFront handles query strings and cookies. + // The configuration ID for a field-level encryption configuration which includes + // a set of profiles that specify certain selected data fields to be encrypted + // by specific public keys. // - // ForwardedValues is a required field - ForwardedValues *ForwardedValues `type:"structure" required:"true"` - - // A complex type that contains zero or more Lambda function associations for - // a cache behavior. - LambdaFunctionAssociations *LambdaFunctionAssociations `type:"structure"` - - MaxTTL *int64 `type:"long"` + // Id is a required field + Id *string `type:"string" required:"true"` - // The minimum amount of time that you want objects to stay in CloudFront caches - // before CloudFront forwards another request to your origin to determine whether - // the object has been updated. For more information, see Specifying How Long - // Objects and Errors Stay in a CloudFront Edge Cache (Expiration) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html) - // in the Amazon Amazon CloudFront Developer Guide. - // - // You must specify 0 for MinTTL if you configure CloudFront to forward all - // headers to your origin (under Headers, if you specify 1 for Quantity and - // * for Name). + // The last time the field-level encryption configuration was changed. // - // MinTTL is a required field - MinTTL *int64 `type:"long" required:"true"` + // LastModifiedTime is a required field + LastModifiedTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"` +} - // Indicates whether you want to distribute media files in the Microsoft Smooth - // Streaming format using the origin that is associated with this cache behavior. - // If so, specify true; if not, specify false. If you specify true for SmoothStreaming, - // you can still distribute other content using this cache behavior if the content - // matches the value of PathPattern. - SmoothStreaming *bool `type:"boolean"` +// String returns the string representation +func (s FieldLevelEncryption) String() string { + return awsutil.Prettify(s) +} - // The value of ID for the origin that you want CloudFront to route requests - // to when a request matches the path pattern either for a cache behavior or - // for the default cache behavior. - // - // TargetOriginId is a required field - TargetOriginId *string `type:"string" required:"true"` +// GoString returns the string representation +func (s FieldLevelEncryption) GoString() string { + return s.String() +} - // A complex type that specifies the AWS accounts, if any, that you want to - // allow to create signed URLs for private content. - // - // If you want to require signed URLs in requests for objects in the target - // origin that match the PathPattern for this cache behavior, specify true for - // Enabled, and specify the applicable values for Quantity and Items. For more - // information, see Serving Private Content through CloudFront (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/PrivateContent.html) - // in the Amazon Amazon CloudFront Developer Guide. - // - // If you don't want to require signed URLs in requests for objects that match - // PathPattern, specify false for Enabled and 0 for Quantity. Omit Items. - // - // To add, change, or remove one or more trusted signers, change Enabled to - // true (if it's currently false), change Quantity as applicable, and specify - // all of the trusted signers that you want to include in the updated distribution. - // - // TrustedSigners is a required field - TrustedSigners *TrustedSigners `type:"structure" required:"true"` +// SetFieldLevelEncryptionConfig sets the FieldLevelEncryptionConfig field's value. +func (s *FieldLevelEncryption) SetFieldLevelEncryptionConfig(v *FieldLevelEncryptionConfig) *FieldLevelEncryption { + s.FieldLevelEncryptionConfig = v + return s +} - // The protocol that viewers can use to access the files in the origin specified - // by TargetOriginId when a request matches the path pattern in PathPattern. - // You can specify the following options: - // - // * allow-all: Viewers can use HTTP or HTTPS. - // - // * redirect-to-https: If a viewer submits an HTTP request, CloudFront returns - // an HTTP status code of 301 (Moved Permanently) to the viewer along with - // the HTTPS URL. The viewer then resubmits the request using the new URL. - // - // * https-only: If a viewer sends an HTTP request, CloudFront returns an - // HTTP status code of 403 (Forbidden). - // - // For more information about requiring the HTTPS protocol, see Using an HTTPS - // Connection to Access Your Objects (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/SecureConnections.html) - // in the Amazon CloudFront Developer Guide. - // - // The only way to guarantee that viewers retrieve an object that was fetched - // from the origin using HTTPS is never to use any other protocol to fetch the - // object. If you have recently changed from HTTP to HTTPS, we recommend that - // you clear your objects' cache because cached objects are protocol agnostic. - // That means that an edge location will return an object from the cache regardless - // of whether the current request protocol matches the protocol used previously. - // For more information, see Specifying How Long Objects and Errors Stay in - // a CloudFront Edge Cache (Expiration) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html) - // in the Amazon CloudFront Developer Guide. +// SetId sets the Id field's value. +func (s *FieldLevelEncryption) SetId(v string) *FieldLevelEncryption { + s.Id = &v + return s +} + +// SetLastModifiedTime sets the LastModifiedTime field's value. +func (s *FieldLevelEncryption) SetLastModifiedTime(v time.Time) *FieldLevelEncryption { + s.LastModifiedTime = &v + return s +} + +// A complex data type that includes the profile configurations specified for +// field-level encryption. +type FieldLevelEncryptionConfig struct { + _ struct{} `type:"structure"` + + // A unique number that ensures the request can't be replayed. // - // ViewerProtocolPolicy is a required field - ViewerProtocolPolicy *string `type:"string" required:"true" enum:"ViewerProtocolPolicy"` + // CallerReference is a required field + CallerReference *string `type:"string" required:"true"` + + // An optional comment about the configuration. + Comment *string `type:"string"` + + // A complex data type that specifies when to forward content if a content type + // isn't recognized and profiles to use as by default in a request if a query + // argument doesn't specify a profile to use. + ContentTypeProfileConfig *ContentTypeProfileConfig `type:"structure"` + + // A complex data type that specifies when to forward content if a profile isn't + // found and the profile that can be provided as a query argument in a request. + QueryArgProfileConfig *QueryArgProfileConfig `type:"structure"` } // String returns the string representation -func (s DefaultCacheBehavior) String() string { +func (s FieldLevelEncryptionConfig) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s DefaultCacheBehavior) GoString() string { +func (s FieldLevelEncryptionConfig) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DefaultCacheBehavior) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DefaultCacheBehavior"} - if s.ForwardedValues == nil { - invalidParams.Add(request.NewErrParamRequired("ForwardedValues")) - } - if s.MinTTL == nil { - invalidParams.Add(request.NewErrParamRequired("MinTTL")) - } - if s.TargetOriginId == nil { - invalidParams.Add(request.NewErrParamRequired("TargetOriginId")) - } - if s.TrustedSigners == nil { - invalidParams.Add(request.NewErrParamRequired("TrustedSigners")) - } - if s.ViewerProtocolPolicy == nil { - invalidParams.Add(request.NewErrParamRequired("ViewerProtocolPolicy")) - } - if s.AllowedMethods != nil { - if err := s.AllowedMethods.Validate(); err != nil { - invalidParams.AddNested("AllowedMethods", err.(request.ErrInvalidParams)) - } - } - if s.ForwardedValues != nil { - if err := s.ForwardedValues.Validate(); err != nil { - invalidParams.AddNested("ForwardedValues", err.(request.ErrInvalidParams)) - } +func (s *FieldLevelEncryptionConfig) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FieldLevelEncryptionConfig"} + if s.CallerReference == nil { + invalidParams.Add(request.NewErrParamRequired("CallerReference")) } - if s.LambdaFunctionAssociations != nil { - if err := s.LambdaFunctionAssociations.Validate(); err != nil { - invalidParams.AddNested("LambdaFunctionAssociations", err.(request.ErrInvalidParams)) + if s.ContentTypeProfileConfig != nil { + if err := s.ContentTypeProfileConfig.Validate(); err != nil { + invalidParams.AddNested("ContentTypeProfileConfig", err.(request.ErrInvalidParams)) } } - if s.TrustedSigners != nil { - if err := s.TrustedSigners.Validate(); err != nil { - invalidParams.AddNested("TrustedSigners", err.(request.ErrInvalidParams)) + if s.QueryArgProfileConfig != nil { + if err := s.QueryArgProfileConfig.Validate(); err != nil { + invalidParams.AddNested("QueryArgProfileConfig", err.(request.ErrInvalidParams)) } } @@ -5026,198 +8917,189 @@ func (s *DefaultCacheBehavior) Validate() error { return nil } -// SetAllowedMethods sets the AllowedMethods field's value. -func (s *DefaultCacheBehavior) SetAllowedMethods(v *AllowedMethods) *DefaultCacheBehavior { - s.AllowedMethods = v +// SetCallerReference sets the CallerReference field's value. +func (s *FieldLevelEncryptionConfig) SetCallerReference(v string) *FieldLevelEncryptionConfig { + s.CallerReference = &v return s } -// SetCompress sets the Compress field's value. -func (s *DefaultCacheBehavior) SetCompress(v bool) *DefaultCacheBehavior { - s.Compress = &v +// SetComment sets the Comment field's value. +func (s *FieldLevelEncryptionConfig) SetComment(v string) *FieldLevelEncryptionConfig { + s.Comment = &v return s } -// SetDefaultTTL sets the DefaultTTL field's value. -func (s *DefaultCacheBehavior) SetDefaultTTL(v int64) *DefaultCacheBehavior { - s.DefaultTTL = &v +// SetContentTypeProfileConfig sets the ContentTypeProfileConfig field's value. +func (s *FieldLevelEncryptionConfig) SetContentTypeProfileConfig(v *ContentTypeProfileConfig) *FieldLevelEncryptionConfig { + s.ContentTypeProfileConfig = v return s } -// SetForwardedValues sets the ForwardedValues field's value. -func (s *DefaultCacheBehavior) SetForwardedValues(v *ForwardedValues) *DefaultCacheBehavior { - s.ForwardedValues = v +// SetQueryArgProfileConfig sets the QueryArgProfileConfig field's value. +func (s *FieldLevelEncryptionConfig) SetQueryArgProfileConfig(v *QueryArgProfileConfig) *FieldLevelEncryptionConfig { + s.QueryArgProfileConfig = v return s } -// SetLambdaFunctionAssociations sets the LambdaFunctionAssociations field's value. -func (s *DefaultCacheBehavior) SetLambdaFunctionAssociations(v *LambdaFunctionAssociations) *DefaultCacheBehavior { - s.LambdaFunctionAssociations = v - return s +// List of field-level encrpytion configurations. +type FieldLevelEncryptionList struct { + _ struct{} `type:"structure"` + + // An array of field-level encryption items. + Items []*FieldLevelEncryptionSummary `locationNameList:"FieldLevelEncryptionSummary" type:"list"` + + // The maximum number of elements you want in the response body. + // + // MaxItems is a required field + MaxItems *int64 `type:"integer" required:"true"` + + // If there are more elements to be listed, this element is present and contains + // the value that you can use for the Marker request parameter to continue listing + // your configurations where you left off. + NextMarker *string `type:"string"` + + // The number of field-level encryption items. + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` } -// SetMaxTTL sets the MaxTTL field's value. -func (s *DefaultCacheBehavior) SetMaxTTL(v int64) *DefaultCacheBehavior { - s.MaxTTL = &v - return s +// String returns the string representation +func (s FieldLevelEncryptionList) String() string { + return awsutil.Prettify(s) } -// SetMinTTL sets the MinTTL field's value. -func (s *DefaultCacheBehavior) SetMinTTL(v int64) *DefaultCacheBehavior { - s.MinTTL = &v - return s +// GoString returns the string representation +func (s FieldLevelEncryptionList) GoString() string { + return s.String() } -// SetSmoothStreaming sets the SmoothStreaming field's value. -func (s *DefaultCacheBehavior) SetSmoothStreaming(v bool) *DefaultCacheBehavior { - s.SmoothStreaming = &v +// SetItems sets the Items field's value. +func (s *FieldLevelEncryptionList) SetItems(v []*FieldLevelEncryptionSummary) *FieldLevelEncryptionList { + s.Items = v return s } -// SetTargetOriginId sets the TargetOriginId field's value. -func (s *DefaultCacheBehavior) SetTargetOriginId(v string) *DefaultCacheBehavior { - s.TargetOriginId = &v +// SetMaxItems sets the MaxItems field's value. +func (s *FieldLevelEncryptionList) SetMaxItems(v int64) *FieldLevelEncryptionList { + s.MaxItems = &v return s } -// SetTrustedSigners sets the TrustedSigners field's value. -func (s *DefaultCacheBehavior) SetTrustedSigners(v *TrustedSigners) *DefaultCacheBehavior { - s.TrustedSigners = v +// SetNextMarker sets the NextMarker field's value. +func (s *FieldLevelEncryptionList) SetNextMarker(v string) *FieldLevelEncryptionList { + s.NextMarker = &v return s } -// SetViewerProtocolPolicy sets the ViewerProtocolPolicy field's value. -func (s *DefaultCacheBehavior) SetViewerProtocolPolicy(v string) *DefaultCacheBehavior { - s.ViewerProtocolPolicy = &v +// SetQuantity sets the Quantity field's value. +func (s *FieldLevelEncryptionList) SetQuantity(v int64) *FieldLevelEncryptionList { + s.Quantity = &v return s } -// Deletes a origin access identity. -type DeleteCloudFrontOriginAccessIdentityInput struct { +// A complex data type for field-level encryption profiles. +type FieldLevelEncryptionProfile struct { _ struct{} `type:"structure"` - // The origin access identity's ID. + // A complex data type that includes the profile name and the encryption entities + // for the field-level encryption profile. + // + // FieldLevelEncryptionProfileConfig is a required field + FieldLevelEncryptionProfileConfig *FieldLevelEncryptionProfileConfig `type:"structure" required:"true"` + + // The ID for a field-level encryption profile configuration which includes + // a set of profiles that specify certain selected data fields to be encrypted + // by specific public keys. // // Id is a required field - Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + Id *string `type:"string" required:"true"` - // The value of the ETag header you received from a previous GET or PUT request. - // For example: E2QWRUHAPOMQZL. - IfMatch *string `location:"header" locationName:"If-Match" type:"string"` + // The last time the field-level encryption profile was updated. + // + // LastModifiedTime is a required field + LastModifiedTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"` } // String returns the string representation -func (s DeleteCloudFrontOriginAccessIdentityInput) String() string { +func (s FieldLevelEncryptionProfile) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s DeleteCloudFrontOriginAccessIdentityInput) GoString() string { +func (s FieldLevelEncryptionProfile) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteCloudFrontOriginAccessIdentityInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteCloudFrontOriginAccessIdentityInput"} - if s.Id == nil { - invalidParams.Add(request.NewErrParamRequired("Id")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetFieldLevelEncryptionProfileConfig sets the FieldLevelEncryptionProfileConfig field's value. +func (s *FieldLevelEncryptionProfile) SetFieldLevelEncryptionProfileConfig(v *FieldLevelEncryptionProfileConfig) *FieldLevelEncryptionProfile { + s.FieldLevelEncryptionProfileConfig = v + return s } // SetId sets the Id field's value. -func (s *DeleteCloudFrontOriginAccessIdentityInput) SetId(v string) *DeleteCloudFrontOriginAccessIdentityInput { +func (s *FieldLevelEncryptionProfile) SetId(v string) *FieldLevelEncryptionProfile { s.Id = &v return s } -// SetIfMatch sets the IfMatch field's value. -func (s *DeleteCloudFrontOriginAccessIdentityInput) SetIfMatch(v string) *DeleteCloudFrontOriginAccessIdentityInput { - s.IfMatch = &v +// SetLastModifiedTime sets the LastModifiedTime field's value. +func (s *FieldLevelEncryptionProfile) SetLastModifiedTime(v time.Time) *FieldLevelEncryptionProfile { + s.LastModifiedTime = &v return s } -type DeleteCloudFrontOriginAccessIdentityOutput struct { +// A complex data type of profiles for the field-level encryption. +type FieldLevelEncryptionProfileConfig struct { _ struct{} `type:"structure"` -} - -// String returns the string representation -func (s DeleteCloudFrontOriginAccessIdentityOutput) String() string { - return awsutil.Prettify(s) -} -// GoString returns the string representation -func (s DeleteCloudFrontOriginAccessIdentityOutput) GoString() string { - return s.String() -} + // A unique number that ensures the request can't be replayed. + // + // CallerReference is a required field + CallerReference *string `type:"string" required:"true"` -// This action deletes a web distribution. To delete a web distribution using -// the CloudFront API, perform the following steps. -// -// To delete a web distribution using the CloudFront API: -// -// Disable the web distribution -// -// Submit a GET Distribution Config request to get the current configuration -// and the Etag header for the distribution. -// -// Update the XML document that was returned in the response to your GET Distribution -// Config request to change the value of Enabled to false. -// -// Submit a PUT Distribution Config request to update the configuration for -// your distribution. In the request body, include the XML document that you -// updated in Step 3. Set the value of the HTTP If-Match header to the value -// of the ETag header that CloudFront returned when you submitted the GET Distribution -// Config request in Step 2. -// -// Review the response to the PUT Distribution Config request to confirm that -// the distribution was successfully disabled. -// -// Submit a GET Distribution request to confirm that your changes have propagated. -// When propagation is complete, the value of Status is Deployed. -// -// Submit a DELETE Distribution request. Set the value of the HTTP If-Match -// header to the value of the ETag header that CloudFront returned when you -// submitted the GET Distribution Config request in Step 6. -// -// Review the response to your DELETE Distribution request to confirm that the -// distribution was successfully deleted. -// -// For information about deleting a distribution using the CloudFront console, -// see Deleting a Distribution (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/HowToDeleteDistribution.html) -// in the Amazon CloudFront Developer Guide. -type DeleteDistributionInput struct { - _ struct{} `type:"structure"` + // An optional comment for the field-level encryption profile. + Comment *string `type:"string"` - // The distribution ID. + // A complex data type of encryption entities for the field-level encryption + // profile that include the public key ID, provider, and field patterns for + // specifying which fields to encrypt with this key. // - // Id is a required field - Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + // EncryptionEntities is a required field + EncryptionEntities *EncryptionEntities `type:"structure" required:"true"` - // The value of the ETag header that you received when you disabled the distribution. - // For example: E2QWRUHAPOMQZL. - IfMatch *string `location:"header" locationName:"If-Match" type:"string"` + // Profile name for the field-level encryption profile. + // + // Name is a required field + Name *string `type:"string" required:"true"` } // String returns the string representation -func (s DeleteDistributionInput) String() string { +func (s FieldLevelEncryptionProfileConfig) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s DeleteDistributionInput) GoString() string { +func (s FieldLevelEncryptionProfileConfig) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteDistributionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteDistributionInput"} - if s.Id == nil { - invalidParams.Add(request.NewErrParamRequired("Id")) +func (s *FieldLevelEncryptionProfileConfig) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FieldLevelEncryptionProfileConfig"} + if s.CallerReference == nil { + invalidParams.Add(request.NewErrParamRequired("CallerReference")) + } + if s.EncryptionEntities == nil { + invalidParams.Add(request.NewErrParamRequired("EncryptionEntities")) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.EncryptionEntities != nil { + if err := s.EncryptionEntities.Validate(); err != nil { + invalidParams.AddNested("EncryptionEntities", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -5226,593 +9108,643 @@ func (s *DeleteDistributionInput) Validate() error { return nil } -// SetId sets the Id field's value. -func (s *DeleteDistributionInput) SetId(v string) *DeleteDistributionInput { - s.Id = &v +// SetCallerReference sets the CallerReference field's value. +func (s *FieldLevelEncryptionProfileConfig) SetCallerReference(v string) *FieldLevelEncryptionProfileConfig { + s.CallerReference = &v return s } -// SetIfMatch sets the IfMatch field's value. -func (s *DeleteDistributionInput) SetIfMatch(v string) *DeleteDistributionInput { - s.IfMatch = &v +// SetComment sets the Comment field's value. +func (s *FieldLevelEncryptionProfileConfig) SetComment(v string) *FieldLevelEncryptionProfileConfig { + s.Comment = &v return s } -type DeleteDistributionOutput struct { - _ struct{} `type:"structure"` -} - -// String returns the string representation -func (s DeleteDistributionOutput) String() string { - return awsutil.Prettify(s) +// SetEncryptionEntities sets the EncryptionEntities field's value. +func (s *FieldLevelEncryptionProfileConfig) SetEncryptionEntities(v *EncryptionEntities) *FieldLevelEncryptionProfileConfig { + s.EncryptionEntities = v + return s } -// GoString returns the string representation -func (s DeleteDistributionOutput) GoString() string { - return s.String() +// SetName sets the Name field's value. +func (s *FieldLevelEncryptionProfileConfig) SetName(v string) *FieldLevelEncryptionProfileConfig { + s.Name = &v + return s } -type DeleteServiceLinkedRoleInput struct { +// List of field-level encryption profiles. +type FieldLevelEncryptionProfileList struct { _ struct{} `type:"structure"` - // RoleName is a required field - RoleName *string `location:"uri" locationName:"RoleName" type:"string" required:"true"` + // The field-level encryption profile items. + Items []*FieldLevelEncryptionProfileSummary `locationNameList:"FieldLevelEncryptionProfileSummary" type:"list"` + + // The maximum number of field-level encryption profiles you want in the response + // body. + // + // MaxItems is a required field + MaxItems *int64 `type:"integer" required:"true"` + + // If there are more elements to be listed, this element is present and contains + // the value that you can use for the Marker request parameter to continue listing + // your profiles where you left off. + NextMarker *string `type:"string"` + + // The number of field-level encryption profiles. + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` } // String returns the string representation -func (s DeleteServiceLinkedRoleInput) String() string { +func (s FieldLevelEncryptionProfileList) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s DeleteServiceLinkedRoleInput) GoString() string { +func (s FieldLevelEncryptionProfileList) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteServiceLinkedRoleInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteServiceLinkedRoleInput"} - if s.RoleName == nil { - invalidParams.Add(request.NewErrParamRequired("RoleName")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetRoleName sets the RoleName field's value. -func (s *DeleteServiceLinkedRoleInput) SetRoleName(v string) *DeleteServiceLinkedRoleInput { - s.RoleName = &v +// SetItems sets the Items field's value. +func (s *FieldLevelEncryptionProfileList) SetItems(v []*FieldLevelEncryptionProfileSummary) *FieldLevelEncryptionProfileList { + s.Items = v return s } -type DeleteServiceLinkedRoleOutput struct { - _ struct{} `type:"structure"` +// SetMaxItems sets the MaxItems field's value. +func (s *FieldLevelEncryptionProfileList) SetMaxItems(v int64) *FieldLevelEncryptionProfileList { + s.MaxItems = &v + return s } -// String returns the string representation -func (s DeleteServiceLinkedRoleOutput) String() string { - return awsutil.Prettify(s) +// SetNextMarker sets the NextMarker field's value. +func (s *FieldLevelEncryptionProfileList) SetNextMarker(v string) *FieldLevelEncryptionProfileList { + s.NextMarker = &v + return s } -// GoString returns the string representation -func (s DeleteServiceLinkedRoleOutput) GoString() string { - return s.String() +// SetQuantity sets the Quantity field's value. +func (s *FieldLevelEncryptionProfileList) SetQuantity(v int64) *FieldLevelEncryptionProfileList { + s.Quantity = &v + return s } -// The request to delete a streaming distribution. -type DeleteStreamingDistributionInput struct { +// The field-level encryption profile summary. +type FieldLevelEncryptionProfileSummary struct { _ struct{} `type:"structure"` - // The distribution ID. + // An optional comment for the field-level encryption profile summary. + Comment *string `type:"string"` + + // A complex data type of encryption entities for the field-level encryption + // profile that include the public key ID, provider, and field patterns for + // specifying which fields to encrypt with this key. + // + // EncryptionEntities is a required field + EncryptionEntities *EncryptionEntities `type:"structure" required:"true"` + + // ID for the field-level encryption profile summary. // // Id is a required field - Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + Id *string `type:"string" required:"true"` - // The value of the ETag header that you received when you disabled the streaming - // distribution. For example: E2QWRUHAPOMQZL. - IfMatch *string `location:"header" locationName:"If-Match" type:"string"` + // The time when the the field-level encryption profile summary was last updated. + // + // LastModifiedTime is a required field + LastModifiedTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // Name for the field-level encryption profile summary. + // + // Name is a required field + Name *string `type:"string" required:"true"` } // String returns the string representation -func (s DeleteStreamingDistributionInput) String() string { +func (s FieldLevelEncryptionProfileSummary) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s DeleteStreamingDistributionInput) GoString() string { +func (s FieldLevelEncryptionProfileSummary) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteStreamingDistributionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteStreamingDistributionInput"} - if s.Id == nil { - invalidParams.Add(request.NewErrParamRequired("Id")) - } +// SetComment sets the Comment field's value. +func (s *FieldLevelEncryptionProfileSummary) SetComment(v string) *FieldLevelEncryptionProfileSummary { + s.Comment = &v + return s +} - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetEncryptionEntities sets the EncryptionEntities field's value. +func (s *FieldLevelEncryptionProfileSummary) SetEncryptionEntities(v *EncryptionEntities) *FieldLevelEncryptionProfileSummary { + s.EncryptionEntities = v + return s } // SetId sets the Id field's value. -func (s *DeleteStreamingDistributionInput) SetId(v string) *DeleteStreamingDistributionInput { +func (s *FieldLevelEncryptionProfileSummary) SetId(v string) *FieldLevelEncryptionProfileSummary { s.Id = &v return s } -// SetIfMatch sets the IfMatch field's value. -func (s *DeleteStreamingDistributionInput) SetIfMatch(v string) *DeleteStreamingDistributionInput { - s.IfMatch = &v +// SetLastModifiedTime sets the LastModifiedTime field's value. +func (s *FieldLevelEncryptionProfileSummary) SetLastModifiedTime(v time.Time) *FieldLevelEncryptionProfileSummary { + s.LastModifiedTime = &v return s } -type DeleteStreamingDistributionOutput struct { - _ struct{} `type:"structure"` -} - -// String returns the string representation -func (s DeleteStreamingDistributionOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteStreamingDistributionOutput) GoString() string { - return s.String() +// SetName sets the Name field's value. +func (s *FieldLevelEncryptionProfileSummary) SetName(v string) *FieldLevelEncryptionProfileSummary { + s.Name = &v + return s } -// The distribution's information. -type Distribution struct { +// A summary of a field-level encryption item. +type FieldLevelEncryptionSummary struct { _ struct{} `type:"structure"` - // The ARN (Amazon Resource Name) for the distribution. For example: arn:aws:cloudfront::123456789012:distribution/EDFDVBD632BHDS5, - // where 123456789012 is your AWS account ID. - // - // ARN is a required field - ARN *string `type:"string" required:"true"` - - // CloudFront automatically adds this element to the response only if you've - // set up the distribution to serve private content with signed URLs. The element - // lists the key pair IDs that CloudFront is aware of for each trusted signer. - // The Signer child element lists the AWS account number of the trusted signer - // (or an empty Self element if the signer is you). The Signer element also - // includes the IDs of any active key pairs associated with the trusted signer's - // AWS account. If no KeyPairId element appears for a Signer, that signer can't - // create working signed URLs. - // - // ActiveTrustedSigners is a required field - ActiveTrustedSigners *ActiveTrustedSigners `type:"structure" required:"true"` - - // The current configuration information for the distribution. Send a GET request - // to the /CloudFront API version/distribution ID/config resource. - // - // DistributionConfig is a required field - DistributionConfig *DistributionConfig `type:"structure" required:"true"` + // An optional comment about the field-level encryption item. + Comment *string `type:"string"` - // The domain name corresponding to the distribution, for example, d111111abcdef8.cloudfront.net. - // - // DomainName is a required field - DomainName *string `type:"string" required:"true"` + // A summary of a content type-profile mapping. + ContentTypeProfileConfig *ContentTypeProfileConfig `type:"structure"` - // The identifier for the distribution. For example: EDFDVBD632BHDS5. + // The unique ID of a field-level encryption item. // // Id is a required field Id *string `type:"string" required:"true"` - // The number of invalidation batches currently in progress. - // - // InProgressInvalidationBatches is a required field - InProgressInvalidationBatches *int64 `type:"integer" required:"true"` - - // The date and time the distribution was last modified. + // The last time that the summary of field-level encryption items was modified. // // LastModifiedTime is a required field LastModifiedTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"` - // This response element indicates the current status of the distribution. When - // the status is Deployed, the distribution's information is fully propagated - // to all CloudFront edge locations. - // - // Status is a required field - Status *string `type:"string" required:"true"` + // A summary of a query argument-profile mapping. + QueryArgProfileConfig *QueryArgProfileConfig `type:"structure"` } // String returns the string representation -func (s Distribution) String() string { +func (s FieldLevelEncryptionSummary) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s Distribution) GoString() string { +func (s FieldLevelEncryptionSummary) GoString() string { return s.String() } -// SetARN sets the ARN field's value. -func (s *Distribution) SetARN(v string) *Distribution { - s.ARN = &v - return s -} - -// SetActiveTrustedSigners sets the ActiveTrustedSigners field's value. -func (s *Distribution) SetActiveTrustedSigners(v *ActiveTrustedSigners) *Distribution { - s.ActiveTrustedSigners = v - return s -} - -// SetDistributionConfig sets the DistributionConfig field's value. -func (s *Distribution) SetDistributionConfig(v *DistributionConfig) *Distribution { - s.DistributionConfig = v +// SetComment sets the Comment field's value. +func (s *FieldLevelEncryptionSummary) SetComment(v string) *FieldLevelEncryptionSummary { + s.Comment = &v return s } -// SetDomainName sets the DomainName field's value. -func (s *Distribution) SetDomainName(v string) *Distribution { - s.DomainName = &v +// SetContentTypeProfileConfig sets the ContentTypeProfileConfig field's value. +func (s *FieldLevelEncryptionSummary) SetContentTypeProfileConfig(v *ContentTypeProfileConfig) *FieldLevelEncryptionSummary { + s.ContentTypeProfileConfig = v return s } // SetId sets the Id field's value. -func (s *Distribution) SetId(v string) *Distribution { +func (s *FieldLevelEncryptionSummary) SetId(v string) *FieldLevelEncryptionSummary { s.Id = &v return s } -// SetInProgressInvalidationBatches sets the InProgressInvalidationBatches field's value. -func (s *Distribution) SetInProgressInvalidationBatches(v int64) *Distribution { - s.InProgressInvalidationBatches = &v - return s -} - // SetLastModifiedTime sets the LastModifiedTime field's value. -func (s *Distribution) SetLastModifiedTime(v time.Time) *Distribution { +func (s *FieldLevelEncryptionSummary) SetLastModifiedTime(v time.Time) *FieldLevelEncryptionSummary { s.LastModifiedTime = &v return s } -// SetStatus sets the Status field's value. -func (s *Distribution) SetStatus(v string) *Distribution { - s.Status = &v +// SetQueryArgProfileConfig sets the QueryArgProfileConfig field's value. +func (s *FieldLevelEncryptionSummary) SetQueryArgProfileConfig(v *QueryArgProfileConfig) *FieldLevelEncryptionSummary { + s.QueryArgProfileConfig = v return s } -// A distribution configuration. -type DistributionConfig struct { +// A complex data type that includes the field patterns to match for field-level +// encryption. +type FieldPatterns struct { _ struct{} `type:"structure"` - // A complex type that contains information about CNAMEs (alternate domain names), - // if any, for this distribution. - Aliases *Aliases `type:"structure"` - - // A complex type that contains zero or more CacheBehavior elements. - CacheBehaviors *CacheBehaviors `type:"structure"` + // An array of the field-level encryption field patterns. + Items []*string `locationNameList:"FieldPattern" type:"list"` - // A unique value (for example, a date-time stamp) that ensures that the request - // can't be replayed. - // - // If the value of CallerReference is new (regardless of the content of the - // DistributionConfig object), CloudFront creates a new distribution. - // - // If CallerReference is a value you already sent in a previous request to create - // a distribution, and if the content of the DistributionConfig is identical - // to the original request (ignoring white space), CloudFront returns the same - // the response that it returned to the original request. - // - // If CallerReference is a value you already sent in a previous request to create - // a distribution but the content of the DistributionConfig is different from - // the original request, CloudFront returns a DistributionAlreadyExists error. + // The number of field-level encryption field patterns. // - // CallerReference is a required field - CallerReference *string `type:"string" required:"true"` + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` +} - // Any comments you want to include about the distribution. - // - // If you don't want to specify a comment, include an empty Comment element. - // - // To delete an existing comment, update the distribution configuration and - // include an empty Comment element. - // - // To add or change a comment, update the distribution configuration and specify - // the new comment. - // - // Comment is a required field - Comment *string `type:"string" required:"true"` +// String returns the string representation +func (s FieldPatterns) String() string { + return awsutil.Prettify(s) +} - // A complex type that controls the following: - // - // * Whether CloudFront replaces HTTP status codes in the 4xx and 5xx range - // with custom error messages before returning the response to the viewer. - // - // * How long CloudFront caches HTTP status codes in the 4xx and 5xx range. - // - // For more information about custom error pages, see Customizing Error Responses - // (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/custom-error-pages.html) - // in the Amazon CloudFront Developer Guide. - CustomErrorResponses *CustomErrorResponses `type:"structure"` +// GoString returns the string representation +func (s FieldPatterns) GoString() string { + return s.String() +} - // A complex type that describes the default cache behavior if you don't specify - // a CacheBehavior element or if files don't match any of the values of PathPattern - // in CacheBehavior elements. You must create exactly one default cache behavior. - // - // DefaultCacheBehavior is a required field - DefaultCacheBehavior *DefaultCacheBehavior `type:"structure" required:"true"` +// Validate inspects the fields of the type to determine if they are valid. +func (s *FieldPatterns) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FieldPatterns"} + if s.Quantity == nil { + invalidParams.Add(request.NewErrParamRequired("Quantity")) + } - // The object that you want CloudFront to request from your origin (for example, - // index.html) when a viewer requests the root URL for your distribution (http://www.example.com) - // instead of an object in your distribution (http://www.example.com/product-description.html). - // Specifying a default root object avoids exposing the contents of your distribution. - // - // Specify only the object name, for example, index.html. Don't add a / before - // the object name. - // - // If you don't want to specify a default root object when you create a distribution, - // include an empty DefaultRootObject element. - // - // To delete the default root object from an existing distribution, update the - // distribution configuration and include an empty DefaultRootObject element. - // - // To replace the default root object, update the distribution configuration - // and specify the new object. - // - // For more information about the default root object, see Creating a Default - // Root Object (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/DefaultRootObject.html) - // in the Amazon CloudFront Developer Guide. - DefaultRootObject *string `type:"string"` + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} - // From this field, you can enable or disable the selected distribution. - // - // If you specify false for Enabled but you specify values for Bucket and Prefix, - // the values are automatically deleted. - // - // Enabled is a required field - Enabled *bool `type:"boolean" required:"true"` +// SetItems sets the Items field's value. +func (s *FieldPatterns) SetItems(v []*string) *FieldPatterns { + s.Items = v + return s +} - // (Optional) Specify the maximum HTTP version that you want viewers to use - // to communicate with CloudFront. The default value for new web distributions - // is http2. Viewers that don't support HTTP/2 automatically use an earlier - // HTTP version. - // - // For viewers and CloudFront to use HTTP/2, viewers must support TLS 1.2 or - // later, and must support Server Name Identification (SNI). - // - // In general, configuring CloudFront to communicate with viewers using HTTP/2 - // reduces latency. You can improve performance by optimizing for HTTP/2. For - // more information, do an Internet search for "http/2 optimization." - HttpVersion *string `type:"string" enum:"HttpVersion"` +// SetQuantity sets the Quantity field's value. +func (s *FieldPatterns) SetQuantity(v int64) *FieldPatterns { + s.Quantity = &v + return s +} - // If you want CloudFront to respond to IPv6 DNS requests with an IPv6 address - // for your distribution, specify true. If you specify false, CloudFront responds - // to IPv6 DNS requests with the DNS response code NOERROR and with no IP addresses. - // This allows viewers to submit a second request, for an IPv4 address for your - // distribution. - // - // In general, you should enable IPv6 if you have users on IPv6 networks who - // want to access your content. However, if you're using signed URLs or signed - // cookies to restrict access to your content, and if you're using a custom - // policy that includes the IpAddress parameter to restrict the IP addresses - // that can access your content, don't enable IPv6. If you want to restrict - // access to some content by IP address and not restrict access to other content - // (or restrict access but not by IP address), you can create two distributions. - // For more information, see Creating a Signed URL Using a Custom Policy (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/private-content-creating-signed-url-custom-policy.html) +// A complex type that specifies how CloudFront handles query strings and cookies. +type ForwardedValues struct { + _ struct{} `type:"structure"` + + // A complex type that specifies whether you want CloudFront to forward cookies + // to the origin and, if so, which ones. For more information about forwarding + // cookies to the origin, see How CloudFront Forwards, Caches, and Logs Cookies + // (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Cookies.html) // in the Amazon CloudFront Developer Guide. // - // If you're using an Amazon Route 53 alias resource record set to route traffic - // to your CloudFront distribution, you need to create a second alias resource - // record set when both of the following are true: - // - // * You enable IPv6 for the distribution + // Cookies is a required field + Cookies *CookiePreference `type:"structure" required:"true"` + + // A complex type that specifies the Headers, if any, that you want CloudFront + // to base caching on for this cache behavior. + Headers *Headers `type:"structure"` + + // Indicates whether you want CloudFront to forward query strings to the origin + // that is associated with this cache behavior and cache based on the query + // string parameters. CloudFront behavior depends on the value of QueryString + // and on the values that you specify for QueryStringCacheKeys, if any: // - // * You're using alternate domain names in the URLs for your objects + // If you specify true for QueryString and you don't specify any values for + // QueryStringCacheKeys, CloudFront forwards all query string parameters to + // the origin and caches based on all query string parameters. Depending on + // how many query string parameters and values you have, this can adversely + // affect performance because CloudFront must forward more requests to the origin. // - // For more information, see Routing Traffic to an Amazon CloudFront Web Distribution - // by Using Your Domain Name (http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/routing-to-cloudfront-distribution.html) - // in the Amazon Route 53 Developer Guide. + // If you specify true for QueryString and you specify one or more values for + // QueryStringCacheKeys, CloudFront forwards all query string parameters to + // the origin, but it only caches based on the query string parameters that + // you specify. // - // If you created a CNAME resource record set, either with Amazon Route 53 or - // with another DNS service, you don't need to make any changes. A CNAME record - // will route traffic to your distribution regardless of the IP address format - // of the viewer request. - IsIPV6Enabled *bool `type:"boolean"` - - // A complex type that controls whether access logs are written for the distribution. + // If you specify false for QueryString, CloudFront doesn't forward any query + // string parameters to the origin, and doesn't cache based on query string + // parameters. // - // For more information about logging, see Access Logs (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/AccessLogs.html) + // For more information, see Configuring CloudFront to Cache Based on Query + // String Parameters (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/QueryStringParameters.html) // in the Amazon CloudFront Developer Guide. - Logging *LoggingConfig `type:"structure"` - - // A complex type that contains information about origins for this distribution. // - // Origins is a required field - Origins *Origins `type:"structure" required:"true"` + // QueryString is a required field + QueryString *bool `type:"boolean" required:"true"` - // The price class that corresponds with the maximum price that you want to - // pay for CloudFront service. If you specify PriceClass_All, CloudFront responds - // to requests for your objects from all CloudFront edge locations. - // - // If you specify a price class other than PriceClass_All, CloudFront serves - // your objects from the CloudFront edge location that has the lowest latency - // among the edge locations in your price class. Viewers who are in or near - // regions that are excluded from your specified price class may encounter slower - // performance. - // - // For more information about price classes, see Choosing the Price Class for - // a CloudFront Distribution (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/PriceClass.html) - // in the Amazon CloudFront Developer Guide. For information about CloudFront - // pricing, including how price classes map to CloudFront regions, see Amazon - // CloudFront Pricing (https://aws.amazon.com/cloudfront/pricing/). - PriceClass *string `type:"string" enum:"PriceClass"` + // A complex type that contains information about the query string parameters + // that you want CloudFront to use for caching for this cache behavior. + QueryStringCacheKeys *QueryStringCacheKeys `type:"structure"` +} - // A complex type that identifies ways in which you want to restrict distribution - // of your content. - Restrictions *Restrictions `type:"structure"` +// String returns the string representation +func (s ForwardedValues) String() string { + return awsutil.Prettify(s) +} - // A complex type that specifies the following: - // - // * Whether you want viewers to use HTTP or HTTPS to request your objects. - // - // * If you want viewers to use HTTPS, whether you're using an alternate - // domain name such as example.com or the CloudFront domain name for your - // distribution, such as d111111abcdef8.cloudfront.net. - // - // * If you're using an alternate domain name, whether AWS Certificate Manager - // (ACM) provided the certificate, or you purchased a certificate from a - // third-party certificate authority and imported it into ACM or uploaded - // it to the IAM certificate store. - // - // You must specify only one of the following values: - // - // * ViewerCertificate$ACMCertificateArn - // - // * ViewerCertificate$IAMCertificateId - // - // * ViewerCertificate$CloudFrontDefaultCertificate - // - // Don't specify false for CloudFrontDefaultCertificate. - // - // If you want viewers to use HTTP instead of HTTPS to request your objects: - // Specify the following value: - // - // true - // - // In addition, specify allow-all for ViewerProtocolPolicy for all of your cache - // behaviors. - // - // If you want viewers to use HTTPS to request your objects: Choose the type - // of certificate that you want to use based on whether you're using an alternate - // domain name for your objects or the CloudFront domain name: - // - // * If you're using an alternate domain name, such as example.com: Specify - // one of the following values, depending on whether ACM provided your certificate - // or you purchased your certificate from third-party certificate authority: - // - // ARN for ACM SSL/TLS certificate where - // ARN for ACM SSL/TLS certificate is the ARN for the ACM SSL/TLS certificate - // that you want to use for this distribution. - // - // IAM certificate ID where IAM certificate - // ID is the ID that IAM returned when you added the certificate to the IAM - // certificate store. - // - // If you specify ACMCertificateArn or IAMCertificateId, you must also specify - // a value for SSLSupportMethod. - // - // If you choose to use an ACM certificate or a certificate in the IAM certificate - // store, we recommend that you use only an alternate domain name in your - // object URLs (https://example.com/logo.jpg). If you use the domain name - // that is associated with your CloudFront distribution (such as https://d111111abcdef8.cloudfront.net/logo.jpg) - // and the viewer supports SNI, then CloudFront behaves normally. However, - // if the browser does not support SNI, the user's experience depends on - // the value that you choose for SSLSupportMethod: - // - // vip: The viewer displays a warning because there is a mismatch between the - // CloudFront domain name and the domain name in your SSL/TLS certificate. - // - // sni-only: CloudFront drops the connection with the browser without returning - // the object. - // - // * If you're using the CloudFront domain name for your distribution, such - // as d111111abcdef8.cloudfront.net: Specify the following value: - // - // true - // - // If you want viewers to use HTTPS, you must also specify one of the following - // values in your cache behaviors: +// GoString returns the string representation +func (s ForwardedValues) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ForwardedValues) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ForwardedValues"} + if s.Cookies == nil { + invalidParams.Add(request.NewErrParamRequired("Cookies")) + } + if s.QueryString == nil { + invalidParams.Add(request.NewErrParamRequired("QueryString")) + } + if s.Cookies != nil { + if err := s.Cookies.Validate(); err != nil { + invalidParams.AddNested("Cookies", err.(request.ErrInvalidParams)) + } + } + if s.Headers != nil { + if err := s.Headers.Validate(); err != nil { + invalidParams.AddNested("Headers", err.(request.ErrInvalidParams)) + } + } + if s.QueryStringCacheKeys != nil { + if err := s.QueryStringCacheKeys.Validate(); err != nil { + invalidParams.AddNested("QueryStringCacheKeys", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetCookies sets the Cookies field's value. +func (s *ForwardedValues) SetCookies(v *CookiePreference) *ForwardedValues { + s.Cookies = v + return s +} + +// SetHeaders sets the Headers field's value. +func (s *ForwardedValues) SetHeaders(v *Headers) *ForwardedValues { + s.Headers = v + return s +} + +// SetQueryString sets the QueryString field's value. +func (s *ForwardedValues) SetQueryString(v bool) *ForwardedValues { + s.QueryString = &v + return s +} + +// SetQueryStringCacheKeys sets the QueryStringCacheKeys field's value. +func (s *ForwardedValues) SetQueryStringCacheKeys(v *QueryStringCacheKeys) *ForwardedValues { + s.QueryStringCacheKeys = v + return s +} + +// A complex type that controls the countries in which your content is distributed. +// CloudFront determines the location of your users using MaxMind GeoIP databases. +type GeoRestriction struct { + _ struct{} `type:"structure"` + + // A complex type that contains a Location element for each country in which + // you want CloudFront either to distribute your content (whitelist) or not + // distribute your content (blacklist). // - // * https-only + // The Location element is a two-letter, uppercase country code for a country + // that you want to include in your blacklist or whitelist. Include one Location + // element for each country. // - // * redirect-to-https + // CloudFront and MaxMind both use ISO 3166 country codes. For the current list + // of countries and the corresponding codes, see ISO 3166-1-alpha-2 code on + // the International Organization for Standardization website. You can also + // refer to the country list on the CloudFront console, which includes both + // country names and codes. + Items []*string `locationNameList:"Location" type:"list"` + + // When geo restriction is enabled, this is the number of countries in your + // whitelist or blacklist. Otherwise, when it is not enabled, Quantity is 0, + // and you can omit Items. // - // You can also optionally require that CloudFront use HTTPS to communicate - // with your origin by specifying one of the following values for the applicable - // origins: + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` + + // The method that you want to use to restrict distribution of your content + // by country: // - // * https-only + // * none: No geo restriction is enabled, meaning access to content is not + // restricted by client geo location. // - // * match-viewer + // * blacklist: The Location elements specify the countries in which you + // don't want CloudFront to distribute your content. // - // For more information, see Using Alternate Domain Names and HTTPS (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/SecureConnections.html#CNAMEsAndHTTPS) - // in the Amazon CloudFront Developer Guide. - ViewerCertificate *ViewerCertificate `type:"structure"` - - // A unique identifier that specifies the AWS WAF web ACL, if any, to associate - // with this distribution. + // * whitelist: The Location elements specify the countries in which you + // want CloudFront to distribute your content. // - // AWS WAF is a web application firewall that lets you monitor the HTTP and - // HTTPS requests that are forwarded to CloudFront, and lets you control access - // to your content. Based on conditions that you specify, such as the IP addresses - // that requests originate from or the values of query strings, CloudFront responds - // to requests either with the requested content or with an HTTP 403 status - // code (Forbidden). You can also configure CloudFront to return a custom error - // page when a request is blocked. For more information about AWS WAF, see the - // AWS WAF Developer Guide (http://docs.aws.amazon.com/waf/latest/developerguide/what-is-aws-waf.html). - WebACLId *string `type:"string"` + // RestrictionType is a required field + RestrictionType *string `type:"string" required:"true" enum:"GeoRestrictionType"` } // String returns the string representation -func (s DistributionConfig) String() string { +func (s GeoRestriction) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s DistributionConfig) GoString() string { +func (s GeoRestriction) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DistributionConfig) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DistributionConfig"} - if s.CallerReference == nil { - invalidParams.Add(request.NewErrParamRequired("CallerReference")) - } - if s.Comment == nil { - invalidParams.Add(request.NewErrParamRequired("Comment")) - } - if s.DefaultCacheBehavior == nil { - invalidParams.Add(request.NewErrParamRequired("DefaultCacheBehavior")) - } - if s.Enabled == nil { - invalidParams.Add(request.NewErrParamRequired("Enabled")) - } - if s.Origins == nil { - invalidParams.Add(request.NewErrParamRequired("Origins")) +func (s *GeoRestriction) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GeoRestriction"} + if s.Quantity == nil { + invalidParams.Add(request.NewErrParamRequired("Quantity")) } - if s.Aliases != nil { - if err := s.Aliases.Validate(); err != nil { - invalidParams.AddNested("Aliases", err.(request.ErrInvalidParams)) - } + if s.RestrictionType == nil { + invalidParams.Add(request.NewErrParamRequired("RestrictionType")) } - if s.CacheBehaviors != nil { - if err := s.CacheBehaviors.Validate(); err != nil { - invalidParams.AddNested("CacheBehaviors", err.(request.ErrInvalidParams)) - } + + if invalidParams.Len() > 0 { + return invalidParams } - if s.CustomErrorResponses != nil { - if err := s.CustomErrorResponses.Validate(); err != nil { - invalidParams.AddNested("CustomErrorResponses", err.(request.ErrInvalidParams)) - } + return nil +} + +// SetItems sets the Items field's value. +func (s *GeoRestriction) SetItems(v []*string) *GeoRestriction { + s.Items = v + return s +} + +// SetQuantity sets the Quantity field's value. +func (s *GeoRestriction) SetQuantity(v int64) *GeoRestriction { + s.Quantity = &v + return s +} + +// SetRestrictionType sets the RestrictionType field's value. +func (s *GeoRestriction) SetRestrictionType(v string) *GeoRestriction { + s.RestrictionType = &v + return s +} + +// The origin access identity's configuration information. For more information, +// see CloudFrontOriginAccessIdentityConfigComplexType. +type GetCloudFrontOriginAccessIdentityConfigInput struct { + _ struct{} `type:"structure"` + + // The identity's ID. + // + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` +} + +// String returns the string representation +func (s GetCloudFrontOriginAccessIdentityConfigInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetCloudFrontOriginAccessIdentityConfigInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetCloudFrontOriginAccessIdentityConfigInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetCloudFrontOriginAccessIdentityConfigInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) } - if s.DefaultCacheBehavior != nil { - if err := s.DefaultCacheBehavior.Validate(); err != nil { - invalidParams.AddNested("DefaultCacheBehavior", err.(request.ErrInvalidParams)) - } + + if invalidParams.Len() > 0 { + return invalidParams } - if s.Logging != nil { - if err := s.Logging.Validate(); err != nil { - invalidParams.AddNested("Logging", err.(request.ErrInvalidParams)) - } + return nil +} + +// SetId sets the Id field's value. +func (s *GetCloudFrontOriginAccessIdentityConfigInput) SetId(v string) *GetCloudFrontOriginAccessIdentityConfigInput { + s.Id = &v + return s +} + +// The returned result of the corresponding request. +type GetCloudFrontOriginAccessIdentityConfigOutput struct { + _ struct{} `type:"structure" payload:"CloudFrontOriginAccessIdentityConfig"` + + // The origin access identity's configuration information. + CloudFrontOriginAccessIdentityConfig *OriginAccessIdentityConfig `type:"structure"` + + // The current version of the configuration. For example: E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` +} + +// String returns the string representation +func (s GetCloudFrontOriginAccessIdentityConfigOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetCloudFrontOriginAccessIdentityConfigOutput) GoString() string { + return s.String() +} + +// SetCloudFrontOriginAccessIdentityConfig sets the CloudFrontOriginAccessIdentityConfig field's value. +func (s *GetCloudFrontOriginAccessIdentityConfigOutput) SetCloudFrontOriginAccessIdentityConfig(v *OriginAccessIdentityConfig) *GetCloudFrontOriginAccessIdentityConfigOutput { + s.CloudFrontOriginAccessIdentityConfig = v + return s +} + +// SetETag sets the ETag field's value. +func (s *GetCloudFrontOriginAccessIdentityConfigOutput) SetETag(v string) *GetCloudFrontOriginAccessIdentityConfigOutput { + s.ETag = &v + return s +} + +// The request to get an origin access identity's information. +type GetCloudFrontOriginAccessIdentityInput struct { + _ struct{} `type:"structure"` + + // The identity's ID. + // + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` +} + +// String returns the string representation +func (s GetCloudFrontOriginAccessIdentityInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetCloudFrontOriginAccessIdentityInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetCloudFrontOriginAccessIdentityInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetCloudFrontOriginAccessIdentityInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) } - if s.Origins != nil { - if err := s.Origins.Validate(); err != nil { - invalidParams.AddNested("Origins", err.(request.ErrInvalidParams)) - } + + if invalidParams.Len() > 0 { + return invalidParams } - if s.Restrictions != nil { - if err := s.Restrictions.Validate(); err != nil { - invalidParams.AddNested("Restrictions", err.(request.ErrInvalidParams)) - } + return nil +} + +// SetId sets the Id field's value. +func (s *GetCloudFrontOriginAccessIdentityInput) SetId(v string) *GetCloudFrontOriginAccessIdentityInput { + s.Id = &v + return s +} + +// The returned result of the corresponding request. +type GetCloudFrontOriginAccessIdentityOutput struct { + _ struct{} `type:"structure" payload:"CloudFrontOriginAccessIdentity"` + + // The origin access identity's information. + CloudFrontOriginAccessIdentity *OriginAccessIdentity `type:"structure"` + + // The current version of the origin access identity's information. For example: + // E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` +} + +// String returns the string representation +func (s GetCloudFrontOriginAccessIdentityOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetCloudFrontOriginAccessIdentityOutput) GoString() string { + return s.String() +} + +// SetCloudFrontOriginAccessIdentity sets the CloudFrontOriginAccessIdentity field's value. +func (s *GetCloudFrontOriginAccessIdentityOutput) SetCloudFrontOriginAccessIdentity(v *OriginAccessIdentity) *GetCloudFrontOriginAccessIdentityOutput { + s.CloudFrontOriginAccessIdentity = v + return s +} + +// SetETag sets the ETag field's value. +func (s *GetCloudFrontOriginAccessIdentityOutput) SetETag(v string) *GetCloudFrontOriginAccessIdentityOutput { + s.ETag = &v + return s +} + +// The request to get a distribution configuration. +type GetDistributionConfigInput struct { + _ struct{} `type:"structure"` + + // The distribution's ID. + // + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` +} + +// String returns the string representation +func (s GetDistributionConfigInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetDistributionConfigInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetDistributionConfigInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetDistributionConfigInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) } if invalidParams.Len() > 0 { @@ -5821,146 +9753,141 @@ func (s *DistributionConfig) Validate() error { return nil } -// SetAliases sets the Aliases field's value. -func (s *DistributionConfig) SetAliases(v *Aliases) *DistributionConfig { - s.Aliases = v +// SetId sets the Id field's value. +func (s *GetDistributionConfigInput) SetId(v string) *GetDistributionConfigInput { + s.Id = &v return s } -// SetCacheBehaviors sets the CacheBehaviors field's value. -func (s *DistributionConfig) SetCacheBehaviors(v *CacheBehaviors) *DistributionConfig { - s.CacheBehaviors = v - return s +// The returned result of the corresponding request. +type GetDistributionConfigOutput struct { + _ struct{} `type:"structure" payload:"DistributionConfig"` + + // The distribution's configuration information. + DistributionConfig *DistributionConfig `type:"structure"` + + // The current version of the configuration. For example: E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` } -// SetCallerReference sets the CallerReference field's value. -func (s *DistributionConfig) SetCallerReference(v string) *DistributionConfig { - s.CallerReference = &v - return s +// String returns the string representation +func (s GetDistributionConfigOutput) String() string { + return awsutil.Prettify(s) } -// SetComment sets the Comment field's value. -func (s *DistributionConfig) SetComment(v string) *DistributionConfig { - s.Comment = &v - return s +// GoString returns the string representation +func (s GetDistributionConfigOutput) GoString() string { + return s.String() } -// SetCustomErrorResponses sets the CustomErrorResponses field's value. -func (s *DistributionConfig) SetCustomErrorResponses(v *CustomErrorResponses) *DistributionConfig { - s.CustomErrorResponses = v +// SetDistributionConfig sets the DistributionConfig field's value. +func (s *GetDistributionConfigOutput) SetDistributionConfig(v *DistributionConfig) *GetDistributionConfigOutput { + s.DistributionConfig = v return s } -// SetDefaultCacheBehavior sets the DefaultCacheBehavior field's value. -func (s *DistributionConfig) SetDefaultCacheBehavior(v *DefaultCacheBehavior) *DistributionConfig { - s.DefaultCacheBehavior = v +// SetETag sets the ETag field's value. +func (s *GetDistributionConfigOutput) SetETag(v string) *GetDistributionConfigOutput { + s.ETag = &v return s } -// SetDefaultRootObject sets the DefaultRootObject field's value. -func (s *DistributionConfig) SetDefaultRootObject(v string) *DistributionConfig { - s.DefaultRootObject = &v - return s +// The request to get a distribution's information. +type GetDistributionInput struct { + _ struct{} `type:"structure"` + + // The distribution's ID. + // + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` } -// SetEnabled sets the Enabled field's value. -func (s *DistributionConfig) SetEnabled(v bool) *DistributionConfig { - s.Enabled = &v - return s +// String returns the string representation +func (s GetDistributionInput) String() string { + return awsutil.Prettify(s) } -// SetHttpVersion sets the HttpVersion field's value. -func (s *DistributionConfig) SetHttpVersion(v string) *DistributionConfig { - s.HttpVersion = &v - return s +// GoString returns the string representation +func (s GetDistributionInput) GoString() string { + return s.String() } -// SetIsIPV6Enabled sets the IsIPV6Enabled field's value. -func (s *DistributionConfig) SetIsIPV6Enabled(v bool) *DistributionConfig { - s.IsIPV6Enabled = &v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetDistributionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetDistributionInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetLogging sets the Logging field's value. -func (s *DistributionConfig) SetLogging(v *LoggingConfig) *DistributionConfig { - s.Logging = v +// SetId sets the Id field's value. +func (s *GetDistributionInput) SetId(v string) *GetDistributionInput { + s.Id = &v return s } -// SetOrigins sets the Origins field's value. -func (s *DistributionConfig) SetOrigins(v *Origins) *DistributionConfig { - s.Origins = v - return s +// The returned result of the corresponding request. +type GetDistributionOutput struct { + _ struct{} `type:"structure" payload:"Distribution"` + + // The distribution's information. + Distribution *Distribution `type:"structure"` + + // The current version of the distribution's information. For example: E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` } -// SetPriceClass sets the PriceClass field's value. -func (s *DistributionConfig) SetPriceClass(v string) *DistributionConfig { - s.PriceClass = &v - return s +// String returns the string representation +func (s GetDistributionOutput) String() string { + return awsutil.Prettify(s) } -// SetRestrictions sets the Restrictions field's value. -func (s *DistributionConfig) SetRestrictions(v *Restrictions) *DistributionConfig { - s.Restrictions = v - return s +// GoString returns the string representation +func (s GetDistributionOutput) GoString() string { + return s.String() } -// SetViewerCertificate sets the ViewerCertificate field's value. -func (s *DistributionConfig) SetViewerCertificate(v *ViewerCertificate) *DistributionConfig { - s.ViewerCertificate = v +// SetDistribution sets the Distribution field's value. +func (s *GetDistributionOutput) SetDistribution(v *Distribution) *GetDistributionOutput { + s.Distribution = v return s } -// SetWebACLId sets the WebACLId field's value. -func (s *DistributionConfig) SetWebACLId(v string) *DistributionConfig { - s.WebACLId = &v +// SetETag sets the ETag field's value. +func (s *GetDistributionOutput) SetETag(v string) *GetDistributionOutput { + s.ETag = &v return s } -// A distribution Configuration and a list of tags to be associated with the -// distribution. -type DistributionConfigWithTags struct { +type GetFieldLevelEncryptionConfigInput struct { _ struct{} `type:"structure"` - // A distribution configuration. - // - // DistributionConfig is a required field - DistributionConfig *DistributionConfig `type:"structure" required:"true"` - - // A complex type that contains zero or more Tag elements. + // Request the ID for the field-level encryption configuration information. // - // Tags is a required field - Tags *Tags `type:"structure" required:"true"` + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` } // String returns the string representation -func (s DistributionConfigWithTags) String() string { +func (s GetFieldLevelEncryptionConfigInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s DistributionConfigWithTags) GoString() string { +func (s GetFieldLevelEncryptionConfigInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DistributionConfigWithTags) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DistributionConfigWithTags"} - if s.DistributionConfig == nil { - invalidParams.Add(request.NewErrParamRequired("DistributionConfig")) - } - if s.Tags == nil { - invalidParams.Add(request.NewErrParamRequired("Tags")) - } - if s.DistributionConfig != nil { - if err := s.DistributionConfig.Validate(); err != nil { - invalidParams.AddNested("DistributionConfig", err.(request.ErrInvalidParams)) - } - } - if s.Tags != nil { - if err := s.Tags.Validate(); err != nil { - invalidParams.AddNested("Tags", err.(request.ErrInvalidParams)) - } +func (s *GetFieldLevelEncryptionConfigInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetFieldLevelEncryptionConfigInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) } if invalidParams.Len() > 0 { @@ -5969,488 +9896,500 @@ func (s *DistributionConfigWithTags) Validate() error { return nil } -// SetDistributionConfig sets the DistributionConfig field's value. -func (s *DistributionConfigWithTags) SetDistributionConfig(v *DistributionConfig) *DistributionConfigWithTags { - s.DistributionConfig = v +// SetId sets the Id field's value. +func (s *GetFieldLevelEncryptionConfigInput) SetId(v string) *GetFieldLevelEncryptionConfigInput { + s.Id = &v return s } -// SetTags sets the Tags field's value. -func (s *DistributionConfigWithTags) SetTags(v *Tags) *DistributionConfigWithTags { - s.Tags = v - return s -} +type GetFieldLevelEncryptionConfigOutput struct { + _ struct{} `type:"structure" payload:"FieldLevelEncryptionConfig"` -// A distribution list. -type DistributionList struct { - _ struct{} `type:"structure"` + // The current version of the field level encryption configuration. For example: + // E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` - // A flag that indicates whether more distributions remain to be listed. If - // your results were truncated, you can make a follow-up pagination request - // using the Marker request parameter to retrieve more distributions in the - // list. - // - // IsTruncated is a required field - IsTruncated *bool `type:"boolean" required:"true"` + // Return the field-level encryption configuration information. + FieldLevelEncryptionConfig *FieldLevelEncryptionConfig `type:"structure"` +} - // A complex type that contains one DistributionSummary element for each distribution - // that was created by the current AWS account. - Items []*DistributionSummary `locationNameList:"DistributionSummary" type:"list"` +// String returns the string representation +func (s GetFieldLevelEncryptionConfigOutput) String() string { + return awsutil.Prettify(s) +} - // The value you provided for the Marker request parameter. - // - // Marker is a required field - Marker *string `type:"string" required:"true"` +// GoString returns the string representation +func (s GetFieldLevelEncryptionConfigOutput) GoString() string { + return s.String() +} - // The value you provided for the MaxItems request parameter. - // - // MaxItems is a required field - MaxItems *int64 `type:"integer" required:"true"` +// SetETag sets the ETag field's value. +func (s *GetFieldLevelEncryptionConfigOutput) SetETag(v string) *GetFieldLevelEncryptionConfigOutput { + s.ETag = &v + return s +} + +// SetFieldLevelEncryptionConfig sets the FieldLevelEncryptionConfig field's value. +func (s *GetFieldLevelEncryptionConfigOutput) SetFieldLevelEncryptionConfig(v *FieldLevelEncryptionConfig) *GetFieldLevelEncryptionConfigOutput { + s.FieldLevelEncryptionConfig = v + return s +} - // If IsTruncated is true, this element is present and contains the value you - // can use for the Marker request parameter to continue listing your distributions - // where they left off. - NextMarker *string `type:"string"` +type GetFieldLevelEncryptionInput struct { + _ struct{} `type:"structure"` - // The number of distributions that were created by the current AWS account. + // Request the ID for the field-level encryption configuration information. // - // Quantity is a required field - Quantity *int64 `type:"integer" required:"true"` + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` } // String returns the string representation -func (s DistributionList) String() string { +func (s GetFieldLevelEncryptionInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s DistributionList) GoString() string { +func (s GetFieldLevelEncryptionInput) GoString() string { return s.String() } -// SetIsTruncated sets the IsTruncated field's value. -func (s *DistributionList) SetIsTruncated(v bool) *DistributionList { - s.IsTruncated = &v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetFieldLevelEncryptionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetFieldLevelEncryptionInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetItems sets the Items field's value. -func (s *DistributionList) SetItems(v []*DistributionSummary) *DistributionList { - s.Items = v +// SetId sets the Id field's value. +func (s *GetFieldLevelEncryptionInput) SetId(v string) *GetFieldLevelEncryptionInput { + s.Id = &v return s } -// SetMarker sets the Marker field's value. -func (s *DistributionList) SetMarker(v string) *DistributionList { - s.Marker = &v - return s +type GetFieldLevelEncryptionOutput struct { + _ struct{} `type:"structure" payload:"FieldLevelEncryption"` + + // The current version of the field level encryption configuration. For example: + // E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // Return the field-level encryption configuration information. + FieldLevelEncryption *FieldLevelEncryption `type:"structure"` } -// SetMaxItems sets the MaxItems field's value. -func (s *DistributionList) SetMaxItems(v int64) *DistributionList { - s.MaxItems = &v - return s +// String returns the string representation +func (s GetFieldLevelEncryptionOutput) String() string { + return awsutil.Prettify(s) } -// SetNextMarker sets the NextMarker field's value. -func (s *DistributionList) SetNextMarker(v string) *DistributionList { - s.NextMarker = &v +// GoString returns the string representation +func (s GetFieldLevelEncryptionOutput) GoString() string { + return s.String() +} + +// SetETag sets the ETag field's value. +func (s *GetFieldLevelEncryptionOutput) SetETag(v string) *GetFieldLevelEncryptionOutput { + s.ETag = &v return s } -// SetQuantity sets the Quantity field's value. -func (s *DistributionList) SetQuantity(v int64) *DistributionList { - s.Quantity = &v +// SetFieldLevelEncryption sets the FieldLevelEncryption field's value. +func (s *GetFieldLevelEncryptionOutput) SetFieldLevelEncryption(v *FieldLevelEncryption) *GetFieldLevelEncryptionOutput { + s.FieldLevelEncryption = v return s } -// A summary of the information about a CloudFront distribution. -type DistributionSummary struct { +type GetFieldLevelEncryptionProfileConfigInput struct { _ struct{} `type:"structure"` - // The ARN (Amazon Resource Name) for the distribution. For example: arn:aws:cloudfront::123456789012:distribution/EDFDVBD632BHDS5, - // where 123456789012 is your AWS account ID. - // - // ARN is a required field - ARN *string `type:"string" required:"true"` - - // A complex type that contains information about CNAMEs (alternate domain names), - // if any, for this distribution. - // - // Aliases is a required field - Aliases *Aliases `type:"structure" required:"true"` - - // A complex type that contains zero or more CacheBehavior elements. - // - // CacheBehaviors is a required field - CacheBehaviors *CacheBehaviors `type:"structure" required:"true"` - - // The comment originally specified when this distribution was created. - // - // Comment is a required field - Comment *string `type:"string" required:"true"` - - // A complex type that contains zero or more CustomErrorResponses elements. - // - // CustomErrorResponses is a required field - CustomErrorResponses *CustomErrorResponses `type:"structure" required:"true"` - - // A complex type that describes the default cache behavior if you don't specify - // a CacheBehavior element or if files don't match any of the values of PathPattern - // in CacheBehavior elements. You must create exactly one default cache behavior. + // Get the ID for the field-level encryption profile configuration information. // - // DefaultCacheBehavior is a required field - DefaultCacheBehavior *DefaultCacheBehavior `type:"structure" required:"true"` + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` +} - // The domain name that corresponds to the distribution, for example, d111111abcdef8.cloudfront.net. - // - // DomainName is a required field - DomainName *string `type:"string" required:"true"` +// String returns the string representation +func (s GetFieldLevelEncryptionProfileConfigInput) String() string { + return awsutil.Prettify(s) +} - // Whether the distribution is enabled to accept user requests for content. - // - // Enabled is a required field - Enabled *bool `type:"boolean" required:"true"` +// GoString returns the string representation +func (s GetFieldLevelEncryptionProfileConfigInput) GoString() string { + return s.String() +} - // Specify the maximum HTTP version that you want viewers to use to communicate - // with CloudFront. The default value for new web distributions is http2. Viewers - // that don't support HTTP/2 will automatically use an earlier version. - // - // HttpVersion is a required field - HttpVersion *string `type:"string" required:"true" enum:"HttpVersion"` +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetFieldLevelEncryptionProfileConfigInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetFieldLevelEncryptionProfileConfigInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } - // The identifier for the distribution. For example: EDFDVBD632BHDS5. - // - // Id is a required field - Id *string `type:"string" required:"true"` + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} - // Whether CloudFront responds to IPv6 DNS requests with an IPv6 address for - // your distribution. - // - // IsIPV6Enabled is a required field - IsIPV6Enabled *bool `type:"boolean" required:"true"` +// SetId sets the Id field's value. +func (s *GetFieldLevelEncryptionProfileConfigInput) SetId(v string) *GetFieldLevelEncryptionProfileConfigInput { + s.Id = &v + return s +} - // The date and time the distribution was last modified. - // - // LastModifiedTime is a required field - LastModifiedTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"` +type GetFieldLevelEncryptionProfileConfigOutput struct { + _ struct{} `type:"structure" payload:"FieldLevelEncryptionProfileConfig"` - // A complex type that contains information about origins for this distribution. - // - // Origins is a required field - Origins *Origins `type:"structure" required:"true"` + // The current version of the field-level encryption profile configuration result. + // For example: E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` - // PriceClass is a required field - PriceClass *string `type:"string" required:"true" enum:"PriceClass"` + // Return the field-level encryption profile configuration information. + FieldLevelEncryptionProfileConfig *FieldLevelEncryptionProfileConfig `type:"structure"` +} - // A complex type that identifies ways in which you want to restrict distribution - // of your content. - // - // Restrictions is a required field - Restrictions *Restrictions `type:"structure" required:"true"` +// String returns the string representation +func (s GetFieldLevelEncryptionProfileConfigOutput) String() string { + return awsutil.Prettify(s) +} - // The current status of the distribution. When the status is Deployed, the - // distribution's information is propagated to all CloudFront edge locations. - // - // Status is a required field - Status *string `type:"string" required:"true"` +// GoString returns the string representation +func (s GetFieldLevelEncryptionProfileConfigOutput) GoString() string { + return s.String() +} - // A complex type that specifies the following: - // - // * Whether you want viewers to use HTTP or HTTPS to request your objects. - // - // * If you want viewers to use HTTPS, whether you're using an alternate - // domain name such as example.com or the CloudFront domain name for your - // distribution, such as d111111abcdef8.cloudfront.net. - // - // * If you're using an alternate domain name, whether AWS Certificate Manager - // (ACM) provided the certificate, or you purchased a certificate from a - // third-party certificate authority and imported it into ACM or uploaded - // it to the IAM certificate store. - // - // You must specify only one of the following values: - // - // * ViewerCertificate$ACMCertificateArn - // - // * ViewerCertificate$IAMCertificateId - // - // * ViewerCertificate$CloudFrontDefaultCertificate - // - // Don't specify false for CloudFrontDefaultCertificate. - // - // If you want viewers to use HTTP instead of HTTPS to request your objects: - // Specify the following value: - // - // true - // - // In addition, specify allow-all for ViewerProtocolPolicy for all of your cache - // behaviors. - // - // If you want viewers to use HTTPS to request your objects: Choose the type - // of certificate that you want to use based on whether you're using an alternate - // domain name for your objects or the CloudFront domain name: - // - // * If you're using an alternate domain name, such as example.com: Specify - // one of the following values, depending on whether ACM provided your certificate - // or you purchased your certificate from third-party certificate authority: - // - // ARN for ACM SSL/TLS certificate where - // ARN for ACM SSL/TLS certificate is the ARN for the ACM SSL/TLS certificate - // that you want to use for this distribution. - // - // IAM certificate ID where IAM certificate - // ID is the ID that IAM returned when you added the certificate to the IAM - // certificate store. - // - // If you specify ACMCertificateArn or IAMCertificateId, you must also specify - // a value for SSLSupportMethod. - // - // If you choose to use an ACM certificate or a certificate in the IAM certificate - // store, we recommend that you use only an alternate domain name in your - // object URLs (https://example.com/logo.jpg). If you use the domain name - // that is associated with your CloudFront distribution (such as https://d111111abcdef8.cloudfront.net/logo.jpg) - // and the viewer supports SNI, then CloudFront behaves normally. However, - // if the browser does not support SNI, the user's experience depends on - // the value that you choose for SSLSupportMethod: - // - // vip: The viewer displays a warning because there is a mismatch between the - // CloudFront domain name and the domain name in your SSL/TLS certificate. - // - // sni-only: CloudFront drops the connection with the browser without returning - // the object. - // - // * If you're using the CloudFront domain name for your distribution, such - // as d111111abcdef8.cloudfront.net: Specify the following value: - // - // true - // - // If you want viewers to use HTTPS, you must also specify one of the following - // values in your cache behaviors: - // - // * https-only - // - // * redirect-to-https - // - // You can also optionally require that CloudFront use HTTPS to communicate - // with your origin by specifying one of the following values for the applicable - // origins: - // - // * https-only - // - // * match-viewer - // - // For more information, see Using Alternate Domain Names and HTTPS (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/SecureConnections.html#CNAMEsAndHTTPS) - // in the Amazon CloudFront Developer Guide. - // - // ViewerCertificate is a required field - ViewerCertificate *ViewerCertificate `type:"structure" required:"true"` +// SetETag sets the ETag field's value. +func (s *GetFieldLevelEncryptionProfileConfigOutput) SetETag(v string) *GetFieldLevelEncryptionProfileConfigOutput { + s.ETag = &v + return s +} - // The Web ACL Id (if any) associated with the distribution. +// SetFieldLevelEncryptionProfileConfig sets the FieldLevelEncryptionProfileConfig field's value. +func (s *GetFieldLevelEncryptionProfileConfigOutput) SetFieldLevelEncryptionProfileConfig(v *FieldLevelEncryptionProfileConfig) *GetFieldLevelEncryptionProfileConfigOutput { + s.FieldLevelEncryptionProfileConfig = v + return s +} + +type GetFieldLevelEncryptionProfileInput struct { + _ struct{} `type:"structure"` + + // Get the ID for the field-level encryption profile information. // - // WebACLId is a required field - WebACLId *string `type:"string" required:"true"` + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` } // String returns the string representation -func (s DistributionSummary) String() string { +func (s GetFieldLevelEncryptionProfileInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s DistributionSummary) GoString() string { +func (s GetFieldLevelEncryptionProfileInput) GoString() string { return s.String() } -// SetARN sets the ARN field's value. -func (s *DistributionSummary) SetARN(v string) *DistributionSummary { - s.ARN = &v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetFieldLevelEncryptionProfileInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetFieldLevelEncryptionProfileInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetAliases sets the Aliases field's value. -func (s *DistributionSummary) SetAliases(v *Aliases) *DistributionSummary { - s.Aliases = v +// SetId sets the Id field's value. +func (s *GetFieldLevelEncryptionProfileInput) SetId(v string) *GetFieldLevelEncryptionProfileInput { + s.Id = &v return s } -// SetCacheBehaviors sets the CacheBehaviors field's value. -func (s *DistributionSummary) SetCacheBehaviors(v *CacheBehaviors) *DistributionSummary { - s.CacheBehaviors = v - return s +type GetFieldLevelEncryptionProfileOutput struct { + _ struct{} `type:"structure" payload:"FieldLevelEncryptionProfile"` + + // The current version of the field level encryption profile. For example: E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // Return the field-level encryption profile information. + FieldLevelEncryptionProfile *FieldLevelEncryptionProfile `type:"structure"` } -// SetComment sets the Comment field's value. -func (s *DistributionSummary) SetComment(v string) *DistributionSummary { - s.Comment = &v - return s +// String returns the string representation +func (s GetFieldLevelEncryptionProfileOutput) String() string { + return awsutil.Prettify(s) } -// SetCustomErrorResponses sets the CustomErrorResponses field's value. -func (s *DistributionSummary) SetCustomErrorResponses(v *CustomErrorResponses) *DistributionSummary { - s.CustomErrorResponses = v - return s +// GoString returns the string representation +func (s GetFieldLevelEncryptionProfileOutput) GoString() string { + return s.String() } -// SetDefaultCacheBehavior sets the DefaultCacheBehavior field's value. -func (s *DistributionSummary) SetDefaultCacheBehavior(v *DefaultCacheBehavior) *DistributionSummary { - s.DefaultCacheBehavior = v +// SetETag sets the ETag field's value. +func (s *GetFieldLevelEncryptionProfileOutput) SetETag(v string) *GetFieldLevelEncryptionProfileOutput { + s.ETag = &v return s } -// SetDomainName sets the DomainName field's value. -func (s *DistributionSummary) SetDomainName(v string) *DistributionSummary { - s.DomainName = &v +// SetFieldLevelEncryptionProfile sets the FieldLevelEncryptionProfile field's value. +func (s *GetFieldLevelEncryptionProfileOutput) SetFieldLevelEncryptionProfile(v *FieldLevelEncryptionProfile) *GetFieldLevelEncryptionProfileOutput { + s.FieldLevelEncryptionProfile = v return s } -// SetEnabled sets the Enabled field's value. -func (s *DistributionSummary) SetEnabled(v bool) *DistributionSummary { - s.Enabled = &v - return s +// The request to get an invalidation's information. +type GetInvalidationInput struct { + _ struct{} `type:"structure"` + + // The distribution's ID. + // + // DistributionId is a required field + DistributionId *string `location:"uri" locationName:"DistributionId" type:"string" required:"true"` + + // The identifier for the invalidation request, for example, IDFDVBD632BHDS5. + // + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` } -// SetHttpVersion sets the HttpVersion field's value. -func (s *DistributionSummary) SetHttpVersion(v string) *DistributionSummary { - s.HttpVersion = &v +// String returns the string representation +func (s GetInvalidationInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetInvalidationInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetInvalidationInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetInvalidationInput"} + if s.DistributionId == nil { + invalidParams.Add(request.NewErrParamRequired("DistributionId")) + } + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDistributionId sets the DistributionId field's value. +func (s *GetInvalidationInput) SetDistributionId(v string) *GetInvalidationInput { + s.DistributionId = &v return s } // SetId sets the Id field's value. -func (s *DistributionSummary) SetId(v string) *DistributionSummary { +func (s *GetInvalidationInput) SetId(v string) *GetInvalidationInput { s.Id = &v return s } -// SetIsIPV6Enabled sets the IsIPV6Enabled field's value. -func (s *DistributionSummary) SetIsIPV6Enabled(v bool) *DistributionSummary { - s.IsIPV6Enabled = &v - return s +// The returned result of the corresponding request. +type GetInvalidationOutput struct { + _ struct{} `type:"structure" payload:"Invalidation"` + + // The invalidation's information. For more information, see Invalidation Complex + // Type (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/InvalidationDatatype.html). + Invalidation *Invalidation `type:"structure"` } -// SetLastModifiedTime sets the LastModifiedTime field's value. -func (s *DistributionSummary) SetLastModifiedTime(v time.Time) *DistributionSummary { - s.LastModifiedTime = &v - return s +// String returns the string representation +func (s GetInvalidationOutput) String() string { + return awsutil.Prettify(s) } -// SetOrigins sets the Origins field's value. -func (s *DistributionSummary) SetOrigins(v *Origins) *DistributionSummary { - s.Origins = v - return s +// GoString returns the string representation +func (s GetInvalidationOutput) GoString() string { + return s.String() } -// SetPriceClass sets the PriceClass field's value. -func (s *DistributionSummary) SetPriceClass(v string) *DistributionSummary { - s.PriceClass = &v +// SetInvalidation sets the Invalidation field's value. +func (s *GetInvalidationOutput) SetInvalidation(v *Invalidation) *GetInvalidationOutput { + s.Invalidation = v return s } -// SetRestrictions sets the Restrictions field's value. -func (s *DistributionSummary) SetRestrictions(v *Restrictions) *DistributionSummary { - s.Restrictions = v - return s +type GetPublicKeyConfigInput struct { + _ struct{} `type:"structure"` + + // Request the ID for the public key configuration. + // + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` } -// SetStatus sets the Status field's value. -func (s *DistributionSummary) SetStatus(v string) *DistributionSummary { - s.Status = &v +// String returns the string representation +func (s GetPublicKeyConfigInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetPublicKeyConfigInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetPublicKeyConfigInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetPublicKeyConfigInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetId sets the Id field's value. +func (s *GetPublicKeyConfigInput) SetId(v string) *GetPublicKeyConfigInput { + s.Id = &v return s } -// SetViewerCertificate sets the ViewerCertificate field's value. -func (s *DistributionSummary) SetViewerCertificate(v *ViewerCertificate) *DistributionSummary { - s.ViewerCertificate = v +type GetPublicKeyConfigOutput struct { + _ struct{} `type:"structure" payload:"PublicKeyConfig"` + + // The current version of the public key configuration. For example: E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // Return the result for the public key configuration. + PublicKeyConfig *PublicKeyConfig `type:"structure"` +} + +// String returns the string representation +func (s GetPublicKeyConfigOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetPublicKeyConfigOutput) GoString() string { + return s.String() +} + +// SetETag sets the ETag field's value. +func (s *GetPublicKeyConfigOutput) SetETag(v string) *GetPublicKeyConfigOutput { + s.ETag = &v return s } -// SetWebACLId sets the WebACLId field's value. -func (s *DistributionSummary) SetWebACLId(v string) *DistributionSummary { - s.WebACLId = &v +// SetPublicKeyConfig sets the PublicKeyConfig field's value. +func (s *GetPublicKeyConfigOutput) SetPublicKeyConfig(v *PublicKeyConfig) *GetPublicKeyConfigOutput { + s.PublicKeyConfig = v return s } -// A complex type that specifies how CloudFront handles query strings and cookies. -type ForwardedValues struct { +type GetPublicKeyInput struct { _ struct{} `type:"structure"` - // A complex type that specifies whether you want CloudFront to forward cookies - // to the origin and, if so, which ones. For more information about forwarding - // cookies to the origin, see How CloudFront Forwards, Caches, and Logs Cookies - // (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Cookies.html) - // in the Amazon CloudFront Developer Guide. + // Request the ID for the public key. // - // Cookies is a required field - Cookies *CookiePreference `type:"structure" required:"true"` + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` +} - // A complex type that specifies the Headers, if any, that you want CloudFront - // to base caching on for this cache behavior. - Headers *Headers `type:"structure"` +// String returns the string representation +func (s GetPublicKeyInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetPublicKeyInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetPublicKeyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetPublicKeyInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetId sets the Id field's value. +func (s *GetPublicKeyInput) SetId(v string) *GetPublicKeyInput { + s.Id = &v + return s +} + +type GetPublicKeyOutput struct { + _ struct{} `type:"structure" payload:"PublicKey"` + + // The current version of the public key. For example: E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // Return the public key. + PublicKey *PublicKey `type:"structure"` +} + +// String returns the string representation +func (s GetPublicKeyOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetPublicKeyOutput) GoString() string { + return s.String() +} + +// SetETag sets the ETag field's value. +func (s *GetPublicKeyOutput) SetETag(v string) *GetPublicKeyOutput { + s.ETag = &v + return s +} + +// SetPublicKey sets the PublicKey field's value. +func (s *GetPublicKeyOutput) SetPublicKey(v *PublicKey) *GetPublicKeyOutput { + s.PublicKey = v + return s +} + +// To request to get a streaming distribution configuration. +type GetStreamingDistributionConfigInput struct { + _ struct{} `type:"structure"` - // Indicates whether you want CloudFront to forward query strings to the origin - // that is associated with this cache behavior and cache based on the query - // string parameters. CloudFront behavior depends on the value of QueryString - // and on the values that you specify for QueryStringCacheKeys, if any: - // - // If you specify true for QueryString and you don't specify any values for - // QueryStringCacheKeys, CloudFront forwards all query string parameters to - // the origin and caches based on all query string parameters. Depending on - // how many query string parameters and values you have, this can adversely - // affect performance because CloudFront must forward more requests to the origin. - // - // If you specify true for QueryString and you specify one or more values for - // QueryStringCacheKeys, CloudFront forwards all query string parameters to - // the origin, but it only caches based on the query string parameters that - // you specify. - // - // If you specify false for QueryString, CloudFront doesn't forward any query - // string parameters to the origin, and doesn't cache based on query string - // parameters. - // - // For more information, see Configuring CloudFront to Cache Based on Query - // String Parameters (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/QueryStringParameters.html) - // in the Amazon CloudFront Developer Guide. + // The streaming distribution's ID. // - // QueryString is a required field - QueryString *bool `type:"boolean" required:"true"` - - // A complex type that contains information about the query string parameters - // that you want CloudFront to use for caching for this cache behavior. - QueryStringCacheKeys *QueryStringCacheKeys `type:"structure"` + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` } // String returns the string representation -func (s ForwardedValues) String() string { +func (s GetStreamingDistributionConfigInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s ForwardedValues) GoString() string { +func (s GetStreamingDistributionConfigInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ForwardedValues) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ForwardedValues"} - if s.Cookies == nil { - invalidParams.Add(request.NewErrParamRequired("Cookies")) - } - if s.QueryString == nil { - invalidParams.Add(request.NewErrParamRequired("QueryString")) - } - if s.Cookies != nil { - if err := s.Cookies.Validate(); err != nil { - invalidParams.AddNested("Cookies", err.(request.ErrInvalidParams)) - } - } - if s.Headers != nil { - if err := s.Headers.Validate(); err != nil { - invalidParams.AddNested("Headers", err.(request.ErrInvalidParams)) - } - } - if s.QueryStringCacheKeys != nil { - if err := s.QueryStringCacheKeys.Validate(); err != nil { - invalidParams.AddNested("QueryStringCacheKeys", err.(request.ErrInvalidParams)) - } +func (s *GetStreamingDistributionConfigInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetStreamingDistributionConfigInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) } if invalidParams.Len() > 0 { @@ -6459,91 +10398,70 @@ func (s *ForwardedValues) Validate() error { return nil } -// SetCookies sets the Cookies field's value. -func (s *ForwardedValues) SetCookies(v *CookiePreference) *ForwardedValues { - s.Cookies = v +// SetId sets the Id field's value. +func (s *GetStreamingDistributionConfigInput) SetId(v string) *GetStreamingDistributionConfigInput { + s.Id = &v return s } -// SetHeaders sets the Headers field's value. -func (s *ForwardedValues) SetHeaders(v *Headers) *ForwardedValues { - s.Headers = v - return s +// The returned result of the corresponding request. +type GetStreamingDistributionConfigOutput struct { + _ struct{} `type:"structure" payload:"StreamingDistributionConfig"` + + // The current version of the configuration. For example: E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // The streaming distribution's configuration information. + StreamingDistributionConfig *StreamingDistributionConfig `type:"structure"` } -// SetQueryString sets the QueryString field's value. -func (s *ForwardedValues) SetQueryString(v bool) *ForwardedValues { - s.QueryString = &v +// String returns the string representation +func (s GetStreamingDistributionConfigOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetStreamingDistributionConfigOutput) GoString() string { + return s.String() +} + +// SetETag sets the ETag field's value. +func (s *GetStreamingDistributionConfigOutput) SetETag(v string) *GetStreamingDistributionConfigOutput { + s.ETag = &v return s } -// SetQueryStringCacheKeys sets the QueryStringCacheKeys field's value. -func (s *ForwardedValues) SetQueryStringCacheKeys(v *QueryStringCacheKeys) *ForwardedValues { - s.QueryStringCacheKeys = v +// SetStreamingDistributionConfig sets the StreamingDistributionConfig field's value. +func (s *GetStreamingDistributionConfigOutput) SetStreamingDistributionConfig(v *StreamingDistributionConfig) *GetStreamingDistributionConfigOutput { + s.StreamingDistributionConfig = v return s } -// A complex type that controls the countries in which your content is distributed. -// CloudFront determines the location of your users using MaxMind GeoIP databases. -type GeoRestriction struct { +// The request to get a streaming distribution's information. +type GetStreamingDistributionInput struct { _ struct{} `type:"structure"` - // A complex type that contains a Location element for each country in which - // you want CloudFront either to distribute your content (whitelist) or not - // distribute your content (blacklist). - // - // The Location element is a two-letter, uppercase country code for a country - // that you want to include in your blacklist or whitelist. Include one Location - // element for each country. - // - // CloudFront and MaxMind both use ISO 3166 country codes. For the current list - // of countries and the corresponding codes, see ISO 3166-1-alpha-2 code on - // the International Organization for Standardization website. You can also - // refer to the country list on the CloudFront console, which includes both - // country names and codes. - Items []*string `locationNameList:"Location" type:"list"` - - // When geo restriction is enabled, this is the number of countries in your - // whitelist or blacklist. Otherwise, when it is not enabled, Quantity is 0, - // and you can omit Items. - // - // Quantity is a required field - Quantity *int64 `type:"integer" required:"true"` - - // The method that you want to use to restrict distribution of your content - // by country: - // - // * none: No geo restriction is enabled, meaning access to content is not - // restricted by client geo location. - // - // * blacklist: The Location elements specify the countries in which you - // don't want CloudFront to distribute your content. - // - // * whitelist: The Location elements specify the countries in which you - // want CloudFront to distribute your content. + // The streaming distribution's ID. // - // RestrictionType is a required field - RestrictionType *string `type:"string" required:"true" enum:"GeoRestrictionType"` + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` } // String returns the string representation -func (s GeoRestriction) String() string { +func (s GetStreamingDistributionInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s GeoRestriction) GoString() string { +func (s GetStreamingDistributionInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *GeoRestriction) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GeoRestriction"} - if s.Quantity == nil { - invalidParams.Add(request.NewErrParamRequired("Quantity")) - } - if s.RestrictionType == nil { - invalidParams.Add(request.NewErrParamRequired("RestrictionType")) +func (s *GetStreamingDistributionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetStreamingDistributionInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) } if invalidParams.Len() > 0 { @@ -6552,50 +10470,112 @@ func (s *GeoRestriction) Validate() error { return nil } -// SetItems sets the Items field's value. -func (s *GeoRestriction) SetItems(v []*string) *GeoRestriction { - s.Items = v +// SetId sets the Id field's value. +func (s *GetStreamingDistributionInput) SetId(v string) *GetStreamingDistributionInput { + s.Id = &v return s } -// SetQuantity sets the Quantity field's value. -func (s *GeoRestriction) SetQuantity(v int64) *GeoRestriction { - s.Quantity = &v +// The returned result of the corresponding request. +type GetStreamingDistributionOutput struct { + _ struct{} `type:"structure" payload:"StreamingDistribution"` + + // The current version of the streaming distribution's information. For example: + // E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // The streaming distribution's information. + StreamingDistribution *StreamingDistribution `type:"structure"` +} + +// String returns the string representation +func (s GetStreamingDistributionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetStreamingDistributionOutput) GoString() string { + return s.String() +} + +// SetETag sets the ETag field's value. +func (s *GetStreamingDistributionOutput) SetETag(v string) *GetStreamingDistributionOutput { + s.ETag = &v return s } -// SetRestrictionType sets the RestrictionType field's value. -func (s *GeoRestriction) SetRestrictionType(v string) *GeoRestriction { - s.RestrictionType = &v +// SetStreamingDistribution sets the StreamingDistribution field's value. +func (s *GetStreamingDistributionOutput) SetStreamingDistribution(v *StreamingDistribution) *GetStreamingDistributionOutput { + s.StreamingDistribution = v return s } -// The origin access identity's configuration information. For more information, -// see CloudFrontOriginAccessIdentityConfigComplexType. -type GetCloudFrontOriginAccessIdentityConfigInput struct { +// A complex type that specifies the request headers, if any, that you want +// CloudFront to base caching on for this cache behavior. +// +// For the headers that you specify, CloudFront caches separate versions of +// a specified object based on the header values in viewer requests. For example, +// suppose viewer requests for logo.jpg contain a custom product header that +// has a value of either acme or apex, and you configure CloudFront to cache +// your content based on values in the product header. CloudFront forwards the +// product header to the origin and caches the response from the origin once +// for each header value. For more information about caching based on header +// values, see How CloudFront Forwards and Caches Headers (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/header-caching.html) +// in the Amazon CloudFront Developer Guide. +type Headers struct { _ struct{} `type:"structure"` - // The identity's ID. + // A list that contains one Name element for each header that you want CloudFront + // to use for caching in this cache behavior. If Quantity is 0, omit Items. + Items []*string `locationNameList:"Name" type:"list"` + + // The number of different headers that you want CloudFront to base caching + // on for this cache behavior. You can configure each cache behavior in a web + // distribution to do one of the following: // - // Id is a required field - Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + // * Forward all headers to your origin: Specify 1 for Quantity and * for + // Name. + // + // CloudFront doesn't cache the objects that are associated with this cache + // behavior. Instead, CloudFront sends every request to the origin. + // + // * Forward a whitelist of headers you specify: Specify the number of headers + // that you want CloudFront to base caching on. Then specify the header names + // in Name elements. CloudFront caches your objects based on the values in + // the specified headers. + // + // * Forward only the default headers: Specify 0 for Quantity and omit Items. + // In this configuration, CloudFront doesn't cache based on the values in + // the request headers. + // + // Regardless of which option you choose, CloudFront forwards headers to your + // origin based on whether the origin is an S3 bucket or a custom origin. See + // the following documentation: + // + // * S3 bucket: See HTTP Request Headers That CloudFront Removes or Updates + // (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/RequestAndResponseBehaviorS3Origin.html#request-s3-removed-headers) + // + // * Custom origin: See HTTP Request Headers and CloudFront Behavior (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/RequestAndResponseBehaviorCustomOrigin.html#request-custom-headers-behavior) + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` } // String returns the string representation -func (s GetCloudFrontOriginAccessIdentityConfigInput) String() string { +func (s Headers) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s GetCloudFrontOriginAccessIdentityConfigInput) GoString() string { +func (s Headers) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *GetCloudFrontOriginAccessIdentityConfigInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetCloudFrontOriginAccessIdentityConfigInput"} - if s.Id == nil { - invalidParams.Add(request.NewErrParamRequired("Id")) +func (s *Headers) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "Headers"} + if s.Quantity == nil { + invalidParams.Add(request.NewErrParamRequired("Quantity")) } if invalidParams.Len() > 0 { @@ -6604,70 +10584,133 @@ func (s *GetCloudFrontOriginAccessIdentityConfigInput) Validate() error { return nil } -// SetId sets the Id field's value. -func (s *GetCloudFrontOriginAccessIdentityConfigInput) SetId(v string) *GetCloudFrontOriginAccessIdentityConfigInput { - s.Id = &v +// SetItems sets the Items field's value. +func (s *Headers) SetItems(v []*string) *Headers { + s.Items = v return s } -// The returned result of the corresponding request. -type GetCloudFrontOriginAccessIdentityConfigOutput struct { - _ struct{} `type:"structure" payload:"CloudFrontOriginAccessIdentityConfig"` +// SetQuantity sets the Quantity field's value. +func (s *Headers) SetQuantity(v int64) *Headers { + s.Quantity = &v + return s +} - // The origin access identity's configuration information. - CloudFrontOriginAccessIdentityConfig *OriginAccessIdentityConfig `type:"structure"` +// An invalidation. +type Invalidation struct { + _ struct{} `type:"structure"` - // The current version of the configuration. For example: E2QWRUHAPOMQZL. - ETag *string `location:"header" locationName:"ETag" type:"string"` + // The date and time the invalidation request was first made. + // + // CreateTime is a required field + CreateTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The identifier for the invalidation request. For example: IDFDVBD632BHDS5. + // + // Id is a required field + Id *string `type:"string" required:"true"` + + // The current invalidation information for the batch request. + // + // InvalidationBatch is a required field + InvalidationBatch *InvalidationBatch `type:"structure" required:"true"` + + // The status of the invalidation request. When the invalidation batch is finished, + // the status is Completed. + // + // Status is a required field + Status *string `type:"string" required:"true"` } // String returns the string representation -func (s GetCloudFrontOriginAccessIdentityConfigOutput) String() string { +func (s Invalidation) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s GetCloudFrontOriginAccessIdentityConfigOutput) GoString() string { +func (s Invalidation) GoString() string { return s.String() } -// SetCloudFrontOriginAccessIdentityConfig sets the CloudFrontOriginAccessIdentityConfig field's value. -func (s *GetCloudFrontOriginAccessIdentityConfigOutput) SetCloudFrontOriginAccessIdentityConfig(v *OriginAccessIdentityConfig) *GetCloudFrontOriginAccessIdentityConfigOutput { - s.CloudFrontOriginAccessIdentityConfig = v +// SetCreateTime sets the CreateTime field's value. +func (s *Invalidation) SetCreateTime(v time.Time) *Invalidation { + s.CreateTime = &v return s } -// SetETag sets the ETag field's value. -func (s *GetCloudFrontOriginAccessIdentityConfigOutput) SetETag(v string) *GetCloudFrontOriginAccessIdentityConfigOutput { - s.ETag = &v +// SetId sets the Id field's value. +func (s *Invalidation) SetId(v string) *Invalidation { + s.Id = &v return s } -// The request to get an origin access identity's information. -type GetCloudFrontOriginAccessIdentityInput struct { +// SetInvalidationBatch sets the InvalidationBatch field's value. +func (s *Invalidation) SetInvalidationBatch(v *InvalidationBatch) *Invalidation { + s.InvalidationBatch = v + return s +} + +// SetStatus sets the Status field's value. +func (s *Invalidation) SetStatus(v string) *Invalidation { + s.Status = &v + return s +} + +// An invalidation batch. +type InvalidationBatch struct { _ struct{} `type:"structure"` - // The identity's ID. + // A value that you specify to uniquely identify an invalidation request. CloudFront + // uses the value to prevent you from accidentally resubmitting an identical + // request. Whenever you create a new invalidation request, you must specify + // a new value for CallerReference and change other values in the request as + // applicable. One way to ensure that the value of CallerReference is unique + // is to use a timestamp, for example, 20120301090000. // - // Id is a required field - Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + // If you make a second invalidation request with the same value for CallerReference, + // and if the rest of the request is the same, CloudFront doesn't create a new + // invalidation request. Instead, CloudFront returns information about the invalidation + // request that you previously created with the same CallerReference. + // + // If CallerReference is a value you already sent in a previous invalidation + // batch request but the content of any Path is different from the original + // request, CloudFront returns an InvalidationBatchAlreadyExists error. + // + // CallerReference is a required field + CallerReference *string `type:"string" required:"true"` + + // A complex type that contains information about the objects that you want + // to invalidate. For more information, see Specifying the Objects to Invalidate + // (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Invalidation.html#invalidation-specifying-objects) + // in the Amazon CloudFront Developer Guide. + // + // Paths is a required field + Paths *Paths `type:"structure" required:"true"` } // String returns the string representation -func (s GetCloudFrontOriginAccessIdentityInput) String() string { +func (s InvalidationBatch) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s GetCloudFrontOriginAccessIdentityInput) GoString() string { +func (s InvalidationBatch) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *GetCloudFrontOriginAccessIdentityInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetCloudFrontOriginAccessIdentityInput"} - if s.Id == nil { - invalidParams.Add(request.NewErrParamRequired("Id")) +func (s *InvalidationBatch) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "InvalidationBatch"} + if s.CallerReference == nil { + invalidParams.Add(request.NewErrParamRequired("CallerReference")) + } + if s.Paths == nil { + invalidParams.Add(request.NewErrParamRequired("Paths")) + } + if s.Paths != nil { + if err := s.Paths.Validate(); err != nil { + invalidParams.AddNested("Paths", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -6676,223 +10719,250 @@ func (s *GetCloudFrontOriginAccessIdentityInput) Validate() error { return nil } -// SetId sets the Id field's value. -func (s *GetCloudFrontOriginAccessIdentityInput) SetId(v string) *GetCloudFrontOriginAccessIdentityInput { - s.Id = &v +// SetCallerReference sets the CallerReference field's value. +func (s *InvalidationBatch) SetCallerReference(v string) *InvalidationBatch { + s.CallerReference = &v return s } -// The returned result of the corresponding request. -type GetCloudFrontOriginAccessIdentityOutput struct { - _ struct{} `type:"structure" payload:"CloudFrontOriginAccessIdentity"` - - // The origin access identity's information. - CloudFrontOriginAccessIdentity *OriginAccessIdentity `type:"structure"` - - // The current version of the origin access identity's information. For example: - // E2QWRUHAPOMQZL. - ETag *string `location:"header" locationName:"ETag" type:"string"` +// SetPaths sets the Paths field's value. +func (s *InvalidationBatch) SetPaths(v *Paths) *InvalidationBatch { + s.Paths = v + return s } -// String returns the string representation -func (s GetCloudFrontOriginAccessIdentityOutput) String() string { - return awsutil.Prettify(s) -} +// The InvalidationList complex type describes the list of invalidation objects. +// For more information about invalidation, see Invalidating Objects (Web Distributions +// Only) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Invalidation.html) +// in the Amazon CloudFront Developer Guide. +type InvalidationList struct { + _ struct{} `type:"structure"` -// GoString returns the string representation -func (s GetCloudFrontOriginAccessIdentityOutput) GoString() string { - return s.String() -} + // A flag that indicates whether more invalidation batch requests remain to + // be listed. If your results were truncated, you can make a follow-up pagination + // request using the Marker request parameter to retrieve more invalidation + // batches in the list. + // + // IsTruncated is a required field + IsTruncated *bool `type:"boolean" required:"true"` -// SetCloudFrontOriginAccessIdentity sets the CloudFrontOriginAccessIdentity field's value. -func (s *GetCloudFrontOriginAccessIdentityOutput) SetCloudFrontOriginAccessIdentity(v *OriginAccessIdentity) *GetCloudFrontOriginAccessIdentityOutput { - s.CloudFrontOriginAccessIdentity = v - return s -} + // A complex type that contains one InvalidationSummary element for each invalidation + // batch created by the current AWS account. + Items []*InvalidationSummary `locationNameList:"InvalidationSummary" type:"list"` -// SetETag sets the ETag field's value. -func (s *GetCloudFrontOriginAccessIdentityOutput) SetETag(v string) *GetCloudFrontOriginAccessIdentityOutput { - s.ETag = &v - return s -} + // The value that you provided for the Marker request parameter. + // + // Marker is a required field + Marker *string `type:"string" required:"true"` -// The request to get a distribution configuration. -type GetDistributionConfigInput struct { - _ struct{} `type:"structure"` + // The value that you provided for the MaxItems request parameter. + // + // MaxItems is a required field + MaxItems *int64 `type:"integer" required:"true"` - // The distribution's ID. + // If IsTruncated is true, this element is present and contains the value that + // you can use for the Marker request parameter to continue listing your invalidation + // batches where they left off. + NextMarker *string `type:"string"` + + // The number of invalidation batches that were created by the current AWS account. // - // Id is a required field - Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` } // String returns the string representation -func (s GetDistributionConfigInput) String() string { +func (s InvalidationList) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s GetDistributionConfigInput) GoString() string { +func (s InvalidationList) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *GetDistributionConfigInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetDistributionConfigInput"} - if s.Id == nil { - invalidParams.Add(request.NewErrParamRequired("Id")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetId sets the Id field's value. -func (s *GetDistributionConfigInput) SetId(v string) *GetDistributionConfigInput { - s.Id = &v +// SetIsTruncated sets the IsTruncated field's value. +func (s *InvalidationList) SetIsTruncated(v bool) *InvalidationList { + s.IsTruncated = &v return s } -// The returned result of the corresponding request. -type GetDistributionConfigOutput struct { - _ struct{} `type:"structure" payload:"DistributionConfig"` - - // The distribution's configuration information. - DistributionConfig *DistributionConfig `type:"structure"` - - // The current version of the configuration. For example: E2QWRUHAPOMQZL. - ETag *string `location:"header" locationName:"ETag" type:"string"` -} - -// String returns the string representation -func (s GetDistributionConfigOutput) String() string { - return awsutil.Prettify(s) +// SetItems sets the Items field's value. +func (s *InvalidationList) SetItems(v []*InvalidationSummary) *InvalidationList { + s.Items = v + return s } -// GoString returns the string representation -func (s GetDistributionConfigOutput) GoString() string { - return s.String() +// SetMarker sets the Marker field's value. +func (s *InvalidationList) SetMarker(v string) *InvalidationList { + s.Marker = &v + return s } -// SetDistributionConfig sets the DistributionConfig field's value. -func (s *GetDistributionConfigOutput) SetDistributionConfig(v *DistributionConfig) *GetDistributionConfigOutput { - s.DistributionConfig = v +// SetMaxItems sets the MaxItems field's value. +func (s *InvalidationList) SetMaxItems(v int64) *InvalidationList { + s.MaxItems = &v return s } -// SetETag sets the ETag field's value. -func (s *GetDistributionConfigOutput) SetETag(v string) *GetDistributionConfigOutput { - s.ETag = &v +// SetNextMarker sets the NextMarker field's value. +func (s *InvalidationList) SetNextMarker(v string) *InvalidationList { + s.NextMarker = &v return s } -// The request to get a distribution's information. -type GetDistributionInput struct { +// SetQuantity sets the Quantity field's value. +func (s *InvalidationList) SetQuantity(v int64) *InvalidationList { + s.Quantity = &v + return s +} + +// A summary of an invalidation request. +type InvalidationSummary struct { _ struct{} `type:"structure"` - // The distribution's ID. + // CreateTime is a required field + CreateTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The unique ID for an invalidation request. // // Id is a required field - Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + Id *string `type:"string" required:"true"` + + // The status of an invalidation request. + // + // Status is a required field + Status *string `type:"string" required:"true"` } // String returns the string representation -func (s GetDistributionInput) String() string { +func (s InvalidationSummary) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s GetDistributionInput) GoString() string { +func (s InvalidationSummary) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *GetDistributionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetDistributionInput"} - if s.Id == nil { - invalidParams.Add(request.NewErrParamRequired("Id")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetCreateTime sets the CreateTime field's value. +func (s *InvalidationSummary) SetCreateTime(v time.Time) *InvalidationSummary { + s.CreateTime = &v + return s } // SetId sets the Id field's value. -func (s *GetDistributionInput) SetId(v string) *GetDistributionInput { +func (s *InvalidationSummary) SetId(v string) *InvalidationSummary { s.Id = &v return s } -// The returned result of the corresponding request. -type GetDistributionOutput struct { - _ struct{} `type:"structure" payload:"Distribution"` +// SetStatus sets the Status field's value. +func (s *InvalidationSummary) SetStatus(v string) *InvalidationSummary { + s.Status = &v + return s +} - // The distribution's information. - Distribution *Distribution `type:"structure"` +// A complex type that lists the active CloudFront key pairs, if any, that are +// associated with AwsAccountNumber. +// +// For more information, see ActiveTrustedSigners. +type KeyPairIds struct { + _ struct{} `type:"structure"` - // The current version of the distribution's information. For example: E2QWRUHAPOMQZL. - ETag *string `location:"header" locationName:"ETag" type:"string"` + // A complex type that lists the active CloudFront key pairs, if any, that are + // associated with AwsAccountNumber. + // + // For more information, see ActiveTrustedSigners. + Items []*string `locationNameList:"KeyPairId" type:"list"` + + // The number of active CloudFront key pairs for AwsAccountNumber. + // + // For more information, see ActiveTrustedSigners. + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` } // String returns the string representation -func (s GetDistributionOutput) String() string { +func (s KeyPairIds) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s GetDistributionOutput) GoString() string { +func (s KeyPairIds) GoString() string { return s.String() } -// SetDistribution sets the Distribution field's value. -func (s *GetDistributionOutput) SetDistribution(v *Distribution) *GetDistributionOutput { - s.Distribution = v +// SetItems sets the Items field's value. +func (s *KeyPairIds) SetItems(v []*string) *KeyPairIds { + s.Items = v return s } -// SetETag sets the ETag field's value. -func (s *GetDistributionOutput) SetETag(v string) *GetDistributionOutput { - s.ETag = &v +// SetQuantity sets the Quantity field's value. +func (s *KeyPairIds) SetQuantity(v int64) *KeyPairIds { + s.Quantity = &v return s } -// The request to get an invalidation's information. -type GetInvalidationInput struct { +// A complex type that contains a Lambda function association. +type LambdaFunctionAssociation struct { _ struct{} `type:"structure"` - // The distribution's ID. + // Specifies the event type that triggers a Lambda function invocation. You + // can specify the following values: // - // DistributionId is a required field - DistributionId *string `location:"uri" locationName:"DistributionId" type:"string" required:"true"` + // * viewer-request: The function executes when CloudFront receives a request + // from a viewer and before it checks to see whether the requested object + // is in the edge cache. + // + // * origin-request: The function executes only when CloudFront forwards + // a request to your origin. When the requested object is in the edge cache, + // the function doesn't execute. + // + // * origin-response: The function executes after CloudFront receives a response + // from the origin and before it caches the object in the response. When + // the requested object is in the edge cache, the function doesn't execute. + // + // If the origin returns an HTTP status code other than HTTP 200 (OK), the function + // doesn't execute. + // + // * viewer-response: The function executes before CloudFront returns the + // requested object to the viewer. The function executes regardless of whether + // the object was already in the edge cache. + // + // If the origin returns an HTTP status code other than HTTP 200 (OK), the function + // doesn't execute. + // + // EventType is a required field + EventType *string `type:"string" required:"true" enum:"EventType"` - // The identifier for the invalidation request, for example, IDFDVBD632BHDS5. + // The ARN of the Lambda function. You must specify the ARN of a function version; + // you can't specify a Lambda alias or $LATEST. // - // Id is a required field - Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + // LambdaFunctionARN is a required field + LambdaFunctionARN *string `type:"string" required:"true"` } // String returns the string representation -func (s GetInvalidationInput) String() string { +func (s LambdaFunctionAssociation) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s GetInvalidationInput) GoString() string { +func (s LambdaFunctionAssociation) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *GetInvalidationInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetInvalidationInput"} - if s.DistributionId == nil { - invalidParams.Add(request.NewErrParamRequired("DistributionId")) +func (s *LambdaFunctionAssociation) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "LambdaFunctionAssociation"} + if s.EventType == nil { + invalidParams.Add(request.NewErrParamRequired("EventType")) } - if s.Id == nil { - invalidParams.Add(request.NewErrParamRequired("Id")) + if s.LambdaFunctionARN == nil { + invalidParams.Add(request.NewErrParamRequired("LambdaFunctionARN")) } if invalidParams.Len() > 0 { @@ -6901,140 +10971,187 @@ func (s *GetInvalidationInput) Validate() error { return nil } -// SetDistributionId sets the DistributionId field's value. -func (s *GetInvalidationInput) SetDistributionId(v string) *GetInvalidationInput { - s.DistributionId = &v +// SetEventType sets the EventType field's value. +func (s *LambdaFunctionAssociation) SetEventType(v string) *LambdaFunctionAssociation { + s.EventType = &v return s } -// SetId sets the Id field's value. -func (s *GetInvalidationInput) SetId(v string) *GetInvalidationInput { - s.Id = &v +// SetLambdaFunctionARN sets the LambdaFunctionARN field's value. +func (s *LambdaFunctionAssociation) SetLambdaFunctionARN(v string) *LambdaFunctionAssociation { + s.LambdaFunctionARN = &v return s } -// The returned result of the corresponding request. -type GetInvalidationOutput struct { - _ struct{} `type:"structure" payload:"Invalidation"` +// A complex type that specifies a list of Lambda functions associations for +// a cache behavior. +// +// If you want to invoke one or more Lambda functions triggered by requests +// that match the PathPattern of the cache behavior, specify the applicable +// values for Quantity and Items. Note that there can be up to 4 LambdaFunctionAssociation +// items in this list (one for each possible value of EventType) and each EventType +// can be associated with the Lambda function only once. +// +// If you don't want to invoke any Lambda functions for the requests that match +// PathPattern, specify 0 for Quantity and omit Items. +type LambdaFunctionAssociations struct { + _ struct{} `type:"structure"` - // The invalidation's information. For more information, see Invalidation Complex - // Type (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/InvalidationDatatype.html). - Invalidation *Invalidation `type:"structure"` + // Optional: A complex type that contains LambdaFunctionAssociation items for + // this cache behavior. If Quantity is 0, you can omit Items. + Items []*LambdaFunctionAssociation `locationNameList:"LambdaFunctionAssociation" type:"list"` + + // The number of Lambda function associations for this cache behavior. + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` } // String returns the string representation -func (s GetInvalidationOutput) String() string { +func (s LambdaFunctionAssociations) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s GetInvalidationOutput) GoString() string { +func (s LambdaFunctionAssociations) GoString() string { return s.String() } -// SetInvalidation sets the Invalidation field's value. -func (s *GetInvalidationOutput) SetInvalidation(v *Invalidation) *GetInvalidationOutput { - s.Invalidation = v +// Validate inspects the fields of the type to determine if they are valid. +func (s *LambdaFunctionAssociations) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "LambdaFunctionAssociations"} + if s.Quantity == nil { + invalidParams.Add(request.NewErrParamRequired("Quantity")) + } + if s.Items != nil { + for i, v := range s.Items { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Items", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetItems sets the Items field's value. +func (s *LambdaFunctionAssociations) SetItems(v []*LambdaFunctionAssociation) *LambdaFunctionAssociations { + s.Items = v return s } -// To request to get a streaming distribution configuration. -type GetStreamingDistributionConfigInput struct { +// SetQuantity sets the Quantity field's value. +func (s *LambdaFunctionAssociations) SetQuantity(v int64) *LambdaFunctionAssociations { + s.Quantity = &v + return s +} + +// The request to list origin access identities. +type ListCloudFrontOriginAccessIdentitiesInput struct { _ struct{} `type:"structure"` - // The streaming distribution's ID. - // - // Id is a required field - Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + // Use this when paginating results to indicate where to begin in your list + // of origin access identities. The results include identities in the list that + // occur after the marker. To get the next page of results, set the Marker to + // the value of the NextMarker from the current page's response (which is also + // the ID of the last identity on that page). + Marker *string `location:"querystring" locationName:"Marker" type:"string"` + + // The maximum number of origin access identities you want in the response body. + MaxItems *int64 `location:"querystring" locationName:"MaxItems" type:"integer"` } // String returns the string representation -func (s GetStreamingDistributionConfigInput) String() string { +func (s ListCloudFrontOriginAccessIdentitiesInput) String() string { return awsutil.Prettify(s) } -// GoString returns the string representation -func (s GetStreamingDistributionConfigInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *GetStreamingDistributionConfigInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetStreamingDistributionConfigInput"} - if s.Id == nil { - invalidParams.Add(request.NewErrParamRequired("Id")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// GoString returns the string representation +func (s ListCloudFrontOriginAccessIdentitiesInput) GoString() string { + return s.String() } -// SetId sets the Id field's value. -func (s *GetStreamingDistributionConfigInput) SetId(v string) *GetStreamingDistributionConfigInput { - s.Id = &v +// SetMarker sets the Marker field's value. +func (s *ListCloudFrontOriginAccessIdentitiesInput) SetMarker(v string) *ListCloudFrontOriginAccessIdentitiesInput { + s.Marker = &v return s } -// The returned result of the corresponding request. -type GetStreamingDistributionConfigOutput struct { - _ struct{} `type:"structure" payload:"StreamingDistributionConfig"` +// SetMaxItems sets the MaxItems field's value. +func (s *ListCloudFrontOriginAccessIdentitiesInput) SetMaxItems(v int64) *ListCloudFrontOriginAccessIdentitiesInput { + s.MaxItems = &v + return s +} - // The current version of the configuration. For example: E2QWRUHAPOMQZL. - ETag *string `location:"header" locationName:"ETag" type:"string"` +// The returned result of the corresponding request. +type ListCloudFrontOriginAccessIdentitiesOutput struct { + _ struct{} `type:"structure" payload:"CloudFrontOriginAccessIdentityList"` - // The streaming distribution's configuration information. - StreamingDistributionConfig *StreamingDistributionConfig `type:"structure"` + // The CloudFrontOriginAccessIdentityList type. + CloudFrontOriginAccessIdentityList *OriginAccessIdentityList `type:"structure"` } // String returns the string representation -func (s GetStreamingDistributionConfigOutput) String() string { +func (s ListCloudFrontOriginAccessIdentitiesOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s GetStreamingDistributionConfigOutput) GoString() string { +func (s ListCloudFrontOriginAccessIdentitiesOutput) GoString() string { return s.String() } -// SetETag sets the ETag field's value. -func (s *GetStreamingDistributionConfigOutput) SetETag(v string) *GetStreamingDistributionConfigOutput { - s.ETag = &v - return s -} - -// SetStreamingDistributionConfig sets the StreamingDistributionConfig field's value. -func (s *GetStreamingDistributionConfigOutput) SetStreamingDistributionConfig(v *StreamingDistributionConfig) *GetStreamingDistributionConfigOutput { - s.StreamingDistributionConfig = v +// SetCloudFrontOriginAccessIdentityList sets the CloudFrontOriginAccessIdentityList field's value. +func (s *ListCloudFrontOriginAccessIdentitiesOutput) SetCloudFrontOriginAccessIdentityList(v *OriginAccessIdentityList) *ListCloudFrontOriginAccessIdentitiesOutput { + s.CloudFrontOriginAccessIdentityList = v return s } -// The request to get a streaming distribution's information. -type GetStreamingDistributionInput struct { +// The request to list distributions that are associated with a specified AWS +// WAF web ACL. +type ListDistributionsByWebACLIdInput struct { _ struct{} `type:"structure"` - // The streaming distribution's ID. + // Use Marker and MaxItems to control pagination of results. If you have more + // than MaxItems distributions that satisfy the request, the response includes + // a NextMarker element. To get the next page of results, submit another request. + // For the value of Marker, specify the value of NextMarker from the last response. + // (For the first request, omit Marker.) + Marker *string `location:"querystring" locationName:"Marker" type:"string"` + + // The maximum number of distributions that you want CloudFront to return in + // the response body. The maximum and default values are both 100. + MaxItems *int64 `location:"querystring" locationName:"MaxItems" type:"integer"` + + // The ID of the AWS WAF web ACL that you want to list the associated distributions. + // If you specify "null" for the ID, the request returns a list of the distributions + // that aren't associated with a web ACL. // - // Id is a required field - Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + // WebACLId is a required field + WebACLId *string `location:"uri" locationName:"WebACLId" type:"string" required:"true"` } // String returns the string representation -func (s GetStreamingDistributionInput) String() string { +func (s ListDistributionsByWebACLIdInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s GetStreamingDistributionInput) GoString() string { +func (s ListDistributionsByWebACLIdInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *GetStreamingDistributionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetStreamingDistributionInput"} - if s.Id == nil { - invalidParams.Add(request.NewErrParamRequired("Id")) +func (s *ListDistributionsByWebACLIdInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListDistributionsByWebACLIdInput"} + if s.WebACLId == nil { + invalidParams.Add(request.NewErrParamRequired("WebACLId")) } if invalidParams.Len() > 0 { @@ -7043,538 +11160,462 @@ func (s *GetStreamingDistributionInput) Validate() error { return nil } -// SetId sets the Id field's value. -func (s *GetStreamingDistributionInput) SetId(v string) *GetStreamingDistributionInput { - s.Id = &v +// SetMarker sets the Marker field's value. +func (s *ListDistributionsByWebACLIdInput) SetMarker(v string) *ListDistributionsByWebACLIdInput { + s.Marker = &v return s } -// The returned result of the corresponding request. -type GetStreamingDistributionOutput struct { - _ struct{} `type:"structure" payload:"StreamingDistribution"` +// SetMaxItems sets the MaxItems field's value. +func (s *ListDistributionsByWebACLIdInput) SetMaxItems(v int64) *ListDistributionsByWebACLIdInput { + s.MaxItems = &v + return s +} - // The current version of the streaming distribution's information. For example: - // E2QWRUHAPOMQZL. - ETag *string `location:"header" locationName:"ETag" type:"string"` +// SetWebACLId sets the WebACLId field's value. +func (s *ListDistributionsByWebACLIdInput) SetWebACLId(v string) *ListDistributionsByWebACLIdInput { + s.WebACLId = &v + return s +} - // The streaming distribution's information. - StreamingDistribution *StreamingDistribution `type:"structure"` +// The response to a request to list the distributions that are associated with +// a specified AWS WAF web ACL. +type ListDistributionsByWebACLIdOutput struct { + _ struct{} `type:"structure" payload:"DistributionList"` + + // The DistributionList type. + DistributionList *DistributionList `type:"structure"` } // String returns the string representation -func (s GetStreamingDistributionOutput) String() string { +func (s ListDistributionsByWebACLIdOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s GetStreamingDistributionOutput) GoString() string { +func (s ListDistributionsByWebACLIdOutput) GoString() string { return s.String() } -// SetETag sets the ETag field's value. -func (s *GetStreamingDistributionOutput) SetETag(v string) *GetStreamingDistributionOutput { - s.ETag = &v - return s -} - -// SetStreamingDistribution sets the StreamingDistribution field's value. -func (s *GetStreamingDistributionOutput) SetStreamingDistribution(v *StreamingDistribution) *GetStreamingDistributionOutput { - s.StreamingDistribution = v +// SetDistributionList sets the DistributionList field's value. +func (s *ListDistributionsByWebACLIdOutput) SetDistributionList(v *DistributionList) *ListDistributionsByWebACLIdOutput { + s.DistributionList = v return s } -// A complex type that specifies the request headers, if any, that you want -// CloudFront to base caching on for this cache behavior. -// -// For the headers that you specify, CloudFront caches separate versions of -// a specified object based on the header values in viewer requests. For example, -// suppose viewer requests for logo.jpg contain a custom product header that -// has a value of either acme or apex, and you configure CloudFront to cache -// your content based on values in the product header. CloudFront forwards the -// product header to the origin and caches the response from the origin once -// for each header value. For more information about caching based on header -// values, see How CloudFront Forwards and Caches Headers (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/header-caching.html) -// in the Amazon CloudFront Developer Guide. -type Headers struct { +// The request to list your distributions. +type ListDistributionsInput struct { _ struct{} `type:"structure"` - // A list that contains one Name element for each header that you want CloudFront - // to use for caching in this cache behavior. If Quantity is 0, omit Items. - Items []*string `locationNameList:"Name" type:"list"` + // Use this when paginating results to indicate where to begin in your list + // of distributions. The results include distributions in the list that occur + // after the marker. To get the next page of results, set the Marker to the + // value of the NextMarker from the current page's response (which is also the + // ID of the last distribution on that page). + Marker *string `location:"querystring" locationName:"Marker" type:"string"` - // The number of different headers that you want CloudFront to base caching - // on for this cache behavior. You can configure each cache behavior in a web - // distribution to do one of the following: - // - // * Forward all headers to your origin: Specify 1 for Quantity and * for - // Name. - // - // CloudFront doesn't cache the objects that are associated with this cache - // behavior. Instead, CloudFront sends every request to the origin. - // - // * Forward a whitelist of headers you specify: Specify the number of headers - // that you want CloudFront to base caching on. Then specify the header names - // in Name elements. CloudFront caches your objects based on the values in - // the specified headers. - // - // * Forward only the default headers: Specify 0 for Quantity and omit Items. - // In this configuration, CloudFront doesn't cache based on the values in - // the request headers. - // - // Regardless of which option you choose, CloudFront forwards headers to your - // origin based on whether the origin is an S3 bucket or a custom origin. See - // the following documentation: - // - // * S3 bucket: See HTTP Request Headers That CloudFront Removes or Updates - // (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/RequestAndResponseBehaviorS3Origin.html#request-s3-removed-headers) - // - // * Custom origin: See HTTP Request Headers and CloudFront Behavior (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/RequestAndResponseBehaviorCustomOrigin.html#request-custom-headers-behavior) - // - // Quantity is a required field - Quantity *int64 `type:"integer" required:"true"` + // The maximum number of distributions you want in the response body. + MaxItems *int64 `location:"querystring" locationName:"MaxItems" type:"integer"` } // String returns the string representation -func (s Headers) String() string { +func (s ListDistributionsInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s Headers) GoString() string { +func (s ListDistributionsInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *Headers) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "Headers"} - if s.Quantity == nil { - invalidParams.Add(request.NewErrParamRequired("Quantity")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetMarker sets the Marker field's value. +func (s *ListDistributionsInput) SetMarker(v string) *ListDistributionsInput { + s.Marker = &v + return s } -// SetItems sets the Items field's value. -func (s *Headers) SetItems(v []*string) *Headers { - s.Items = v +// SetMaxItems sets the MaxItems field's value. +func (s *ListDistributionsInput) SetMaxItems(v int64) *ListDistributionsInput { + s.MaxItems = &v return s } -// SetQuantity sets the Quantity field's value. -func (s *Headers) SetQuantity(v int64) *Headers { - s.Quantity = &v - return s +// The returned result of the corresponding request. +type ListDistributionsOutput struct { + _ struct{} `type:"structure" payload:"DistributionList"` + + // The DistributionList type. + DistributionList *DistributionList `type:"structure"` } -// An invalidation. -type Invalidation struct { - _ struct{} `type:"structure"` +// String returns the string representation +func (s ListDistributionsOutput) String() string { + return awsutil.Prettify(s) +} - // The date and time the invalidation request was first made. - // - // CreateTime is a required field - CreateTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"` +// GoString returns the string representation +func (s ListDistributionsOutput) GoString() string { + return s.String() +} - // The identifier for the invalidation request. For example: IDFDVBD632BHDS5. - // - // Id is a required field - Id *string `type:"string" required:"true"` +// SetDistributionList sets the DistributionList field's value. +func (s *ListDistributionsOutput) SetDistributionList(v *DistributionList) *ListDistributionsOutput { + s.DistributionList = v + return s +} - // The current invalidation information for the batch request. - // - // InvalidationBatch is a required field - InvalidationBatch *InvalidationBatch `type:"structure" required:"true"` +type ListFieldLevelEncryptionConfigsInput struct { + _ struct{} `type:"structure"` - // The status of the invalidation request. When the invalidation batch is finished, - // the status is Completed. - // - // Status is a required field - Status *string `type:"string" required:"true"` + // Use this when paginating results to indicate where to begin in your list + // of configurations. The results include configurations in the list that occur + // after the marker. To get the next page of results, set the Marker to the + // value of the NextMarker from the current page's response (which is also the + // ID of the last configuration on that page). + Marker *string `location:"querystring" locationName:"Marker" type:"string"` + + // The maximum number of field-level encryption configurations you want in the + // response body. + MaxItems *int64 `location:"querystring" locationName:"MaxItems" type:"integer"` } // String returns the string representation -func (s Invalidation) String() string { +func (s ListFieldLevelEncryptionConfigsInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s Invalidation) GoString() string { +func (s ListFieldLevelEncryptionConfigsInput) GoString() string { return s.String() } -// SetCreateTime sets the CreateTime field's value. -func (s *Invalidation) SetCreateTime(v time.Time) *Invalidation { - s.CreateTime = &v +// SetMarker sets the Marker field's value. +func (s *ListFieldLevelEncryptionConfigsInput) SetMarker(v string) *ListFieldLevelEncryptionConfigsInput { + s.Marker = &v return s } -// SetId sets the Id field's value. -func (s *Invalidation) SetId(v string) *Invalidation { - s.Id = &v +// SetMaxItems sets the MaxItems field's value. +func (s *ListFieldLevelEncryptionConfigsInput) SetMaxItems(v int64) *ListFieldLevelEncryptionConfigsInput { + s.MaxItems = &v return s } -// SetInvalidationBatch sets the InvalidationBatch field's value. -func (s *Invalidation) SetInvalidationBatch(v *InvalidationBatch) *Invalidation { - s.InvalidationBatch = v - return s +type ListFieldLevelEncryptionConfigsOutput struct { + _ struct{} `type:"structure" payload:"FieldLevelEncryptionList"` + + // Returns a list of all field-level encryption configurations that have been + // created in CloudFront for this account. + FieldLevelEncryptionList *FieldLevelEncryptionList `type:"structure"` } -// SetStatus sets the Status field's value. -func (s *Invalidation) SetStatus(v string) *Invalidation { - s.Status = &v +// String returns the string representation +func (s ListFieldLevelEncryptionConfigsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListFieldLevelEncryptionConfigsOutput) GoString() string { + return s.String() +} + +// SetFieldLevelEncryptionList sets the FieldLevelEncryptionList field's value. +func (s *ListFieldLevelEncryptionConfigsOutput) SetFieldLevelEncryptionList(v *FieldLevelEncryptionList) *ListFieldLevelEncryptionConfigsOutput { + s.FieldLevelEncryptionList = v return s } -// An invalidation batch. -type InvalidationBatch struct { +type ListFieldLevelEncryptionProfilesInput struct { _ struct{} `type:"structure"` - // A value that you specify to uniquely identify an invalidation request. CloudFront - // uses the value to prevent you from accidentally resubmitting an identical - // request. Whenever you create a new invalidation request, you must specify - // a new value for CallerReference and change other values in the request as - // applicable. One way to ensure that the value of CallerReference is unique - // is to use a timestamp, for example, 20120301090000. - // - // If you make a second invalidation request with the same value for CallerReference, - // and if the rest of the request is the same, CloudFront doesn't create a new - // invalidation request. Instead, CloudFront returns information about the invalidation - // request that you previously created with the same CallerReference. - // - // If CallerReference is a value you already sent in a previous invalidation - // batch request but the content of any Path is different from the original - // request, CloudFront returns an InvalidationBatchAlreadyExists error. - // - // CallerReference is a required field - CallerReference *string `type:"string" required:"true"` + // Use this when paginating results to indicate where to begin in your list + // of profiles. The results include profiles in the list that occur after the + // marker. To get the next page of results, set the Marker to the value of the + // NextMarker from the current page's response (which is also the ID of the + // last profile on that page). + Marker *string `location:"querystring" locationName:"Marker" type:"string"` - // A complex type that contains information about the objects that you want - // to invalidate. For more information, see Specifying the Objects to Invalidate - // (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Invalidation.html#invalidation-specifying-objects) - // in the Amazon CloudFront Developer Guide. - // - // Paths is a required field - Paths *Paths `type:"structure" required:"true"` + // The maximum number of field-level encryption profiles you want in the response + // body. + MaxItems *int64 `location:"querystring" locationName:"MaxItems" type:"integer"` } // String returns the string representation -func (s InvalidationBatch) String() string { +func (s ListFieldLevelEncryptionProfilesInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s InvalidationBatch) GoString() string { +func (s ListFieldLevelEncryptionProfilesInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *InvalidationBatch) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "InvalidationBatch"} - if s.CallerReference == nil { - invalidParams.Add(request.NewErrParamRequired("CallerReference")) - } - if s.Paths == nil { - invalidParams.Add(request.NewErrParamRequired("Paths")) - } - if s.Paths != nil { - if err := s.Paths.Validate(); err != nil { - invalidParams.AddNested("Paths", err.(request.ErrInvalidParams)) - } - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetMarker sets the Marker field's value. +func (s *ListFieldLevelEncryptionProfilesInput) SetMarker(v string) *ListFieldLevelEncryptionProfilesInput { + s.Marker = &v + return s } -// SetCallerReference sets the CallerReference field's value. -func (s *InvalidationBatch) SetCallerReference(v string) *InvalidationBatch { - s.CallerReference = &v +// SetMaxItems sets the MaxItems field's value. +func (s *ListFieldLevelEncryptionProfilesInput) SetMaxItems(v int64) *ListFieldLevelEncryptionProfilesInput { + s.MaxItems = &v return s } -// SetPaths sets the Paths field's value. -func (s *InvalidationBatch) SetPaths(v *Paths) *InvalidationBatch { - s.Paths = v - return s +type ListFieldLevelEncryptionProfilesOutput struct { + _ struct{} `type:"structure" payload:"FieldLevelEncryptionProfileList"` + + // Returns a list of the field-level encryption profiles that have been created + // in CloudFront for this account. + FieldLevelEncryptionProfileList *FieldLevelEncryptionProfileList `type:"structure"` } -// The InvalidationList complex type describes the list of invalidation objects. -// For more information about invalidation, see Invalidating Objects (Web Distributions -// Only) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Invalidation.html) -// in the Amazon CloudFront Developer Guide. -type InvalidationList struct { - _ struct{} `type:"structure"` +// String returns the string representation +func (s ListFieldLevelEncryptionProfilesOutput) String() string { + return awsutil.Prettify(s) +} - // A flag that indicates whether more invalidation batch requests remain to - // be listed. If your results were truncated, you can make a follow-up pagination - // request using the Marker request parameter to retrieve more invalidation - // batches in the list. - // - // IsTruncated is a required field - IsTruncated *bool `type:"boolean" required:"true"` +// GoString returns the string representation +func (s ListFieldLevelEncryptionProfilesOutput) GoString() string { + return s.String() +} - // A complex type that contains one InvalidationSummary element for each invalidation - // batch created by the current AWS account. - Items []*InvalidationSummary `locationNameList:"InvalidationSummary" type:"list"` +// SetFieldLevelEncryptionProfileList sets the FieldLevelEncryptionProfileList field's value. +func (s *ListFieldLevelEncryptionProfilesOutput) SetFieldLevelEncryptionProfileList(v *FieldLevelEncryptionProfileList) *ListFieldLevelEncryptionProfilesOutput { + s.FieldLevelEncryptionProfileList = v + return s +} - // The value that you provided for the Marker request parameter. - // - // Marker is a required field - Marker *string `type:"string" required:"true"` +// The request to list invalidations. +type ListInvalidationsInput struct { + _ struct{} `type:"structure"` - // The value that you provided for the MaxItems request parameter. + // The distribution's ID. // - // MaxItems is a required field - MaxItems *int64 `type:"integer" required:"true"` + // DistributionId is a required field + DistributionId *string `location:"uri" locationName:"DistributionId" type:"string" required:"true"` - // If IsTruncated is true, this element is present and contains the value that - // you can use for the Marker request parameter to continue listing your invalidation - // batches where they left off. - NextMarker *string `type:"string"` + // Use this parameter when paginating results to indicate where to begin in + // your list of invalidation batches. Because the results are returned in decreasing + // order from most recent to oldest, the most recent results are on the first + // page, the second page will contain earlier results, and so on. To get the + // next page of results, set Marker to the value of the NextMarker from the + // current page's response. This value is the same as the ID of the last invalidation + // batch on that page. + Marker *string `location:"querystring" locationName:"Marker" type:"string"` - // The number of invalidation batches that were created by the current AWS account. - // - // Quantity is a required field - Quantity *int64 `type:"integer" required:"true"` + // The maximum number of invalidation batches that you want in the response + // body. + MaxItems *int64 `location:"querystring" locationName:"MaxItems" type:"integer"` } // String returns the string representation -func (s InvalidationList) String() string { +func (s ListInvalidationsInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s InvalidationList) GoString() string { +func (s ListInvalidationsInput) GoString() string { return s.String() } -// SetIsTruncated sets the IsTruncated field's value. -func (s *InvalidationList) SetIsTruncated(v bool) *InvalidationList { - s.IsTruncated = &v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListInvalidationsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListInvalidationsInput"} + if s.DistributionId == nil { + invalidParams.Add(request.NewErrParamRequired("DistributionId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetItems sets the Items field's value. -func (s *InvalidationList) SetItems(v []*InvalidationSummary) *InvalidationList { - s.Items = v +// SetDistributionId sets the DistributionId field's value. +func (s *ListInvalidationsInput) SetDistributionId(v string) *ListInvalidationsInput { + s.DistributionId = &v return s } // SetMarker sets the Marker field's value. -func (s *InvalidationList) SetMarker(v string) *InvalidationList { +func (s *ListInvalidationsInput) SetMarker(v string) *ListInvalidationsInput { s.Marker = &v return s } // SetMaxItems sets the MaxItems field's value. -func (s *InvalidationList) SetMaxItems(v int64) *InvalidationList { +func (s *ListInvalidationsInput) SetMaxItems(v int64) *ListInvalidationsInput { s.MaxItems = &v return s } -// SetNextMarker sets the NextMarker field's value. -func (s *InvalidationList) SetNextMarker(v string) *InvalidationList { - s.NextMarker = &v - return s +// The returned result of the corresponding request. +type ListInvalidationsOutput struct { + _ struct{} `type:"structure" payload:"InvalidationList"` + + // Information about invalidation batches. + InvalidationList *InvalidationList `type:"structure"` } -// SetQuantity sets the Quantity field's value. -func (s *InvalidationList) SetQuantity(v int64) *InvalidationList { - s.Quantity = &v +// String returns the string representation +func (s ListInvalidationsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListInvalidationsOutput) GoString() string { + return s.String() +} + +// SetInvalidationList sets the InvalidationList field's value. +func (s *ListInvalidationsOutput) SetInvalidationList(v *InvalidationList) *ListInvalidationsOutput { + s.InvalidationList = v return s } -// A summary of an invalidation request. -type InvalidationSummary struct { +type ListPublicKeysInput struct { _ struct{} `type:"structure"` - // CreateTime is a required field - CreateTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"` - - // The unique ID for an invalidation request. - // - // Id is a required field - Id *string `type:"string" required:"true"` + // Use this when paginating results to indicate where to begin in your list + // of public keys. The results include public keys in the list that occur after + // the marker. To get the next page of results, set the Marker to the value + // of the NextMarker from the current page's response (which is also the ID + // of the last public key on that page). + Marker *string `location:"querystring" locationName:"Marker" type:"string"` - // The status of an invalidation request. - // - // Status is a required field - Status *string `type:"string" required:"true"` + // The maximum number of public keys you want in the response body. + MaxItems *int64 `location:"querystring" locationName:"MaxItems" type:"integer"` } // String returns the string representation -func (s InvalidationSummary) String() string { +func (s ListPublicKeysInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s InvalidationSummary) GoString() string { +func (s ListPublicKeysInput) GoString() string { return s.String() } -// SetCreateTime sets the CreateTime field's value. -func (s *InvalidationSummary) SetCreateTime(v time.Time) *InvalidationSummary { - s.CreateTime = &v +// SetMarker sets the Marker field's value. +func (s *ListPublicKeysInput) SetMarker(v string) *ListPublicKeysInput { + s.Marker = &v return s } -// SetId sets the Id field's value. -func (s *InvalidationSummary) SetId(v string) *InvalidationSummary { - s.Id = &v +// SetMaxItems sets the MaxItems field's value. +func (s *ListPublicKeysInput) SetMaxItems(v int64) *ListPublicKeysInput { + s.MaxItems = &v return s } -// SetStatus sets the Status field's value. -func (s *InvalidationSummary) SetStatus(v string) *InvalidationSummary { - s.Status = &v - return s +type ListPublicKeysOutput struct { + _ struct{} `type:"structure" payload:"PublicKeyList"` + + // Returns a list of all public keys that have been added to CloudFront for + // this account. + PublicKeyList *PublicKeyList `type:"structure"` } -// A complex type that lists the active CloudFront key pairs, if any, that are -// associated with AwsAccountNumber. -// -// For more information, see ActiveTrustedSigners. -type KeyPairIds struct { +// String returns the string representation +func (s ListPublicKeysOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListPublicKeysOutput) GoString() string { + return s.String() +} + +// SetPublicKeyList sets the PublicKeyList field's value. +func (s *ListPublicKeysOutput) SetPublicKeyList(v *PublicKeyList) *ListPublicKeysOutput { + s.PublicKeyList = v + return s +} + +// The request to list your streaming distributions. +type ListStreamingDistributionsInput struct { _ struct{} `type:"structure"` - // A complex type that lists the active CloudFront key pairs, if any, that are - // associated with AwsAccountNumber. - // - // For more information, see ActiveTrustedSigners. - Items []*string `locationNameList:"KeyPairId" type:"list"` + // The value that you provided for the Marker request parameter. + Marker *string `location:"querystring" locationName:"Marker" type:"string"` - // The number of active CloudFront key pairs for AwsAccountNumber. - // - // For more information, see ActiveTrustedSigners. - // - // Quantity is a required field - Quantity *int64 `type:"integer" required:"true"` + // The value that you provided for the MaxItems request parameter. + MaxItems *int64 `location:"querystring" locationName:"MaxItems" type:"integer"` } // String returns the string representation -func (s KeyPairIds) String() string { +func (s ListStreamingDistributionsInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s KeyPairIds) GoString() string { +func (s ListStreamingDistributionsInput) GoString() string { return s.String() } -// SetItems sets the Items field's value. -func (s *KeyPairIds) SetItems(v []*string) *KeyPairIds { - s.Items = v +// SetMarker sets the Marker field's value. +func (s *ListStreamingDistributionsInput) SetMarker(v string) *ListStreamingDistributionsInput { + s.Marker = &v return s } -// SetQuantity sets the Quantity field's value. -func (s *KeyPairIds) SetQuantity(v int64) *KeyPairIds { - s.Quantity = &v +// SetMaxItems sets the MaxItems field's value. +func (s *ListStreamingDistributionsInput) SetMaxItems(v int64) *ListStreamingDistributionsInput { + s.MaxItems = &v return s } -// A complex type that contains a Lambda function association. -type LambdaFunctionAssociation struct { - _ struct{} `type:"structure"` - - // Specifies the event type that triggers a Lambda function invocation. You - // can specify the following values: - // - // * viewer-request: The function executes when CloudFront receives a request - // from a viewer and before it checks to see whether the requested object - // is in the edge cache. - // - // * origin-request: The function executes only when CloudFront forwards - // a request to your origin. When the requested object is in the edge cache, - // the function doesn't execute. - // - // * origin-response: The function executes after CloudFront receives a response - // from the origin and before it caches the object in the response. When - // the requested object is in the edge cache, the function doesn't execute. - // - // If the origin returns an HTTP status code other than HTTP 200 (OK), the function - // doesn't execute. - // - // * viewer-response: The function executes before CloudFront returns the - // requested object to the viewer. The function executes regardless of whether - // the object was already in the edge cache. - // - // If the origin returns an HTTP status code other than HTTP 200 (OK), the function - // doesn't execute. - EventType *string `type:"string" enum:"EventType"` +// The returned result of the corresponding request. +type ListStreamingDistributionsOutput struct { + _ struct{} `type:"structure" payload:"StreamingDistributionList"` - // The ARN of the Lambda function. You must specify the ARN of a function version; - // you can't specify a Lambda alias or $LATEST. - LambdaFunctionARN *string `type:"string"` + // The StreamingDistributionList type. + StreamingDistributionList *StreamingDistributionList `type:"structure"` } // String returns the string representation -func (s LambdaFunctionAssociation) String() string { +func (s ListStreamingDistributionsOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s LambdaFunctionAssociation) GoString() string { +func (s ListStreamingDistributionsOutput) GoString() string { return s.String() } -// SetEventType sets the EventType field's value. -func (s *LambdaFunctionAssociation) SetEventType(v string) *LambdaFunctionAssociation { - s.EventType = &v - return s -} - -// SetLambdaFunctionARN sets the LambdaFunctionARN field's value. -func (s *LambdaFunctionAssociation) SetLambdaFunctionARN(v string) *LambdaFunctionAssociation { - s.LambdaFunctionARN = &v +// SetStreamingDistributionList sets the StreamingDistributionList field's value. +func (s *ListStreamingDistributionsOutput) SetStreamingDistributionList(v *StreamingDistributionList) *ListStreamingDistributionsOutput { + s.StreamingDistributionList = v return s } -// A complex type that specifies a list of Lambda functions associations for -// a cache behavior. -// -// If you want to invoke one or more Lambda functions triggered by requests -// that match the PathPattern of the cache behavior, specify the applicable -// values for Quantity and Items. Note that there can be up to 4 LambdaFunctionAssociation -// items in this list (one for each possible value of EventType) and each EventType -// can be associated with the Lambda function only once. -// -// If you don't want to invoke any Lambda functions for the requests that match -// PathPattern, specify 0 for Quantity and omit Items. -type LambdaFunctionAssociations struct { +// The request to list tags for a CloudFront resource. +type ListTagsForResourceInput struct { _ struct{} `type:"structure"` - // Optional: A complex type that contains LambdaFunctionAssociation items for - // this cache behavior. If Quantity is 0, you can omit Items. - Items []*LambdaFunctionAssociation `locationNameList:"LambdaFunctionAssociation" type:"list"` - - // The number of Lambda function associations for this cache behavior. + // An ARN of a CloudFront resource. // - // Quantity is a required field - Quantity *int64 `type:"integer" required:"true"` + // Resource is a required field + Resource *string `location:"querystring" locationName:"Resource" type:"string" required:"true"` } // String returns the string representation -func (s LambdaFunctionAssociations) String() string { +func (s ListTagsForResourceInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s LambdaFunctionAssociations) GoString() string { +func (s ListTagsForResourceInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *LambdaFunctionAssociations) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "LambdaFunctionAssociations"} - if s.Quantity == nil { - invalidParams.Add(request.NewErrParamRequired("Quantity")) +func (s *ListTagsForResourceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListTagsForResourceInput"} + if s.Resource == nil { + invalidParams.Add(request.NewErrParamRequired("Resource")) } if invalidParams.Len() > 0 { @@ -7583,118 +11624,251 @@ func (s *LambdaFunctionAssociations) Validate() error { return nil } -// SetItems sets the Items field's value. -func (s *LambdaFunctionAssociations) SetItems(v []*LambdaFunctionAssociation) *LambdaFunctionAssociations { - s.Items = v - return s -} - -// SetQuantity sets the Quantity field's value. -func (s *LambdaFunctionAssociations) SetQuantity(v int64) *LambdaFunctionAssociations { - s.Quantity = &v +// SetResource sets the Resource field's value. +func (s *ListTagsForResourceInput) SetResource(v string) *ListTagsForResourceInput { + s.Resource = &v return s } -// The request to list origin access identities. -type ListCloudFrontOriginAccessIdentitiesInput struct { - _ struct{} `type:"structure"` - - // Use this when paginating results to indicate where to begin in your list - // of origin access identities. The results include identities in the list that - // occur after the marker. To get the next page of results, set the Marker to - // the value of the NextMarker from the current page's response (which is also - // the ID of the last identity on that page). - Marker *string `location:"querystring" locationName:"Marker" type:"string"` +// The returned result of the corresponding request. +type ListTagsForResourceOutput struct { + _ struct{} `type:"structure" payload:"Tags"` - // The maximum number of origin access identities you want in the response body. - MaxItems *int64 `location:"querystring" locationName:"MaxItems" type:"integer"` + // A complex type that contains zero or more Tag elements. + // + // Tags is a required field + Tags *Tags `type:"structure" required:"true"` } // String returns the string representation -func (s ListCloudFrontOriginAccessIdentitiesInput) String() string { +func (s ListTagsForResourceOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s ListCloudFrontOriginAccessIdentitiesInput) GoString() string { +func (s ListTagsForResourceOutput) GoString() string { return s.String() } -// SetMarker sets the Marker field's value. -func (s *ListCloudFrontOriginAccessIdentitiesInput) SetMarker(v string) *ListCloudFrontOriginAccessIdentitiesInput { - s.Marker = &v +// SetTags sets the Tags field's value. +func (s *ListTagsForResourceOutput) SetTags(v *Tags) *ListTagsForResourceOutput { + s.Tags = v return s } -// SetMaxItems sets the MaxItems field's value. -func (s *ListCloudFrontOriginAccessIdentitiesInput) SetMaxItems(v int64) *ListCloudFrontOriginAccessIdentitiesInput { - s.MaxItems = &v - return s -} +// A complex type that controls whether access logs are written for the distribution. +type LoggingConfig struct { + _ struct{} `type:"structure"` -// The returned result of the corresponding request. -type ListCloudFrontOriginAccessIdentitiesOutput struct { - _ struct{} `type:"structure" payload:"CloudFrontOriginAccessIdentityList"` + // The Amazon S3 bucket to store the access logs in, for example, myawslogbucket.s3.amazonaws.com. + // + // Bucket is a required field + Bucket *string `type:"string" required:"true"` - // The CloudFrontOriginAccessIdentityList type. - CloudFrontOriginAccessIdentityList *OriginAccessIdentityList `type:"structure"` + // Specifies whether you want CloudFront to save access logs to an Amazon S3 + // bucket. If you don't want to enable logging when you create a distribution + // or if you want to disable logging for an existing distribution, specify false + // for Enabled, and specify empty Bucket and Prefix elements. If you specify + // false for Enabled but you specify values for Bucket, prefix, and IncludeCookies, + // the values are automatically deleted. + // + // Enabled is a required field + Enabled *bool `type:"boolean" required:"true"` + + // Specifies whether you want CloudFront to include cookies in access logs, + // specify true for IncludeCookies. If you choose to include cookies in logs, + // CloudFront logs all cookies regardless of how you configure the cache behaviors + // for this distribution. If you don't want to include cookies when you create + // a distribution or if you want to disable include cookies for an existing + // distribution, specify false for IncludeCookies. + // + // IncludeCookies is a required field + IncludeCookies *bool `type:"boolean" required:"true"` + + // An optional string that you want CloudFront to prefix to the access log filenames + // for this distribution, for example, myprefix/. If you want to enable logging, + // but you don't want to specify a prefix, you still must include an empty Prefix + // element in the Logging element. + // + // Prefix is a required field + Prefix *string `type:"string" required:"true"` } // String returns the string representation -func (s ListCloudFrontOriginAccessIdentitiesOutput) String() string { +func (s LoggingConfig) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s ListCloudFrontOriginAccessIdentitiesOutput) GoString() string { +func (s LoggingConfig) GoString() string { return s.String() } -// SetCloudFrontOriginAccessIdentityList sets the CloudFrontOriginAccessIdentityList field's value. -func (s *ListCloudFrontOriginAccessIdentitiesOutput) SetCloudFrontOriginAccessIdentityList(v *OriginAccessIdentityList) *ListCloudFrontOriginAccessIdentitiesOutput { - s.CloudFrontOriginAccessIdentityList = v +// Validate inspects the fields of the type to determine if they are valid. +func (s *LoggingConfig) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "LoggingConfig"} + if s.Bucket == nil { + invalidParams.Add(request.NewErrParamRequired("Bucket")) + } + if s.Enabled == nil { + invalidParams.Add(request.NewErrParamRequired("Enabled")) + } + if s.IncludeCookies == nil { + invalidParams.Add(request.NewErrParamRequired("IncludeCookies")) + } + if s.Prefix == nil { + invalidParams.Add(request.NewErrParamRequired("Prefix")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetBucket sets the Bucket field's value. +func (s *LoggingConfig) SetBucket(v string) *LoggingConfig { + s.Bucket = &v + return s +} + +// SetEnabled sets the Enabled field's value. +func (s *LoggingConfig) SetEnabled(v bool) *LoggingConfig { + s.Enabled = &v + return s +} + +// SetIncludeCookies sets the IncludeCookies field's value. +func (s *LoggingConfig) SetIncludeCookies(v bool) *LoggingConfig { + s.IncludeCookies = &v + return s +} + +// SetPrefix sets the Prefix field's value. +func (s *LoggingConfig) SetPrefix(v string) *LoggingConfig { + s.Prefix = &v return s } -// The request to list distributions that are associated with a specified AWS -// WAF web ACL. -type ListDistributionsByWebACLIdInput struct { +// A complex type that describes the Amazon S3 bucket or the HTTP server (for +// example, a web server) from which CloudFront gets your files. You must create +// at least one origin. +// +// For the current limit on the number of origins that you can create for a +// distribution, see Amazon CloudFront Limits (http://docs.aws.amazon.com/general/latest/gr/aws_service_limits.html#limits_cloudfront) +// in the AWS General Reference. +type Origin struct { _ struct{} `type:"structure"` - // Use Marker and MaxItems to control pagination of results. If you have more - // than MaxItems distributions that satisfy the request, the response includes - // a NextMarker element. To get the next page of results, submit another request. - // For the value of Marker, specify the value of NextMarker from the last response. - // (For the first request, omit Marker.) - Marker *string `location:"querystring" locationName:"Marker" type:"string"` + // A complex type that contains names and values for the custom headers that + // you want. + CustomHeaders *CustomHeaders `type:"structure"` - // The maximum number of distributions that you want CloudFront to return in - // the response body. The maximum and default values are both 100. - MaxItems *int64 `location:"querystring" locationName:"MaxItems" type:"integer"` + // A complex type that contains information about a custom origin. If the origin + // is an Amazon S3 bucket, use the S3OriginConfig element instead. + CustomOriginConfig *CustomOriginConfig `type:"structure"` - // The ID of the AWS WAF web ACL that you want to list the associated distributions. - // If you specify "null" for the ID, the request returns a list of the distributions - // that aren't associated with a web ACL. + // Amazon S3 origins: The DNS name of the Amazon S3 bucket from which you want + // CloudFront to get objects for this origin, for example, myawsbucket.s3.amazonaws.com. // - // WebACLId is a required field - WebACLId *string `location:"uri" locationName:"WebACLId" type:"string" required:"true"` + // Constraints for Amazon S3 origins: + // + // * If you configured Amazon S3 Transfer Acceleration for your bucket, don't + // specify the s3-accelerate endpoint for DomainName. + // + // * The bucket name must be between 3 and 63 characters long (inclusive). + // + // * The bucket name must contain only lowercase characters, numbers, periods, + // underscores, and dashes. + // + // * The bucket name must not contain adjacent periods. + // + // Custom Origins: The DNS domain name for the HTTP server from which you want + // CloudFront to get objects for this origin, for example, www.example.com. + // + // Constraints for custom origins: + // + // * DomainName must be a valid DNS name that contains only a-z, A-Z, 0-9, + // dot (.), hyphen (-), or underscore (_) characters. + // + // * The name cannot exceed 128 characters. + // + // DomainName is a required field + DomainName *string `type:"string" required:"true"` + + // A unique identifier for the origin. The value of Id must be unique within + // the distribution. + // + // When you specify the value of TargetOriginId for the default cache behavior + // or for another cache behavior, you indicate the origin to which you want + // the cache behavior to route requests by specifying the value of the Id element + // for that origin. When a request matches the path pattern for that cache behavior, + // CloudFront routes the request to the specified origin. For more information, + // see Cache Behavior Settings (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/distribution-web-values-specify.html#DownloadDistValuesCacheBehavior) + // in the Amazon CloudFront Developer Guide. + // + // Id is a required field + Id *string `type:"string" required:"true"` + + // An optional element that causes CloudFront to request your content from a + // directory in your Amazon S3 bucket or your custom origin. When you include + // the OriginPath element, specify the directory name, beginning with a /. CloudFront + // appends the directory name to the value of DomainName, for example, example.com/production. + // Do not include a / at the end of the directory name. + // + // For example, suppose you've specified the following values for your distribution: + // + // * DomainName: An Amazon S3 bucket named myawsbucket. + // + // * OriginPath: /production + // + // * CNAME: example.com + // + // When a user enters example.com/index.html in a browser, CloudFront sends + // a request to Amazon S3 for myawsbucket/production/index.html. + // + // When a user enters example.com/acme/index.html in a browser, CloudFront sends + // a request to Amazon S3 for myawsbucket/production/acme/index.html. + OriginPath *string `type:"string"` + + // A complex type that contains information about the Amazon S3 origin. If the + // origin is a custom origin, use the CustomOriginConfig element instead. + S3OriginConfig *S3OriginConfig `type:"structure"` } // String returns the string representation -func (s ListDistributionsByWebACLIdInput) String() string { +func (s Origin) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s ListDistributionsByWebACLIdInput) GoString() string { +func (s Origin) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListDistributionsByWebACLIdInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListDistributionsByWebACLIdInput"} - if s.WebACLId == nil { - invalidParams.Add(request.NewErrParamRequired("WebACLId")) +func (s *Origin) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "Origin"} + if s.DomainName == nil { + invalidParams.Add(request.NewErrParamRequired("DomainName")) + } + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } + if s.CustomHeaders != nil { + if err := s.CustomHeaders.Validate(); err != nil { + invalidParams.AddNested("CustomHeaders", err.(request.ErrInvalidParams)) + } + } + if s.CustomOriginConfig != nil { + if err := s.CustomOriginConfig.Validate(); err != nil { + invalidParams.AddNested("CustomOriginConfig", err.(request.ErrInvalidParams)) + } + } + if s.S3OriginConfig != nil { + if err := s.S3OriginConfig.Validate(); err != nil { + invalidParams.AddNested("S3OriginConfig", err.(request.ErrInvalidParams)) + } } if invalidParams.Len() > 0 { @@ -7703,148 +11877,137 @@ func (s *ListDistributionsByWebACLIdInput) Validate() error { return nil } -// SetMarker sets the Marker field's value. -func (s *ListDistributionsByWebACLIdInput) SetMarker(v string) *ListDistributionsByWebACLIdInput { - s.Marker = &v +// SetCustomHeaders sets the CustomHeaders field's value. +func (s *Origin) SetCustomHeaders(v *CustomHeaders) *Origin { + s.CustomHeaders = v return s } -// SetMaxItems sets the MaxItems field's value. -func (s *ListDistributionsByWebACLIdInput) SetMaxItems(v int64) *ListDistributionsByWebACLIdInput { - s.MaxItems = &v +// SetCustomOriginConfig sets the CustomOriginConfig field's value. +func (s *Origin) SetCustomOriginConfig(v *CustomOriginConfig) *Origin { + s.CustomOriginConfig = v return s } -// SetWebACLId sets the WebACLId field's value. -func (s *ListDistributionsByWebACLIdInput) SetWebACLId(v string) *ListDistributionsByWebACLIdInput { - s.WebACLId = &v +// SetDomainName sets the DomainName field's value. +func (s *Origin) SetDomainName(v string) *Origin { + s.DomainName = &v return s } -// The response to a request to list the distributions that are associated with -// a specified AWS WAF web ACL. -type ListDistributionsByWebACLIdOutput struct { - _ struct{} `type:"structure" payload:"DistributionList"` - - // The DistributionList type. - DistributionList *DistributionList `type:"structure"` -} - -// String returns the string representation -func (s ListDistributionsByWebACLIdOutput) String() string { - return awsutil.Prettify(s) +// SetId sets the Id field's value. +func (s *Origin) SetId(v string) *Origin { + s.Id = &v + return s } -// GoString returns the string representation -func (s ListDistributionsByWebACLIdOutput) GoString() string { - return s.String() +// SetOriginPath sets the OriginPath field's value. +func (s *Origin) SetOriginPath(v string) *Origin { + s.OriginPath = &v + return s } -// SetDistributionList sets the DistributionList field's value. -func (s *ListDistributionsByWebACLIdOutput) SetDistributionList(v *DistributionList) *ListDistributionsByWebACLIdOutput { - s.DistributionList = v +// SetS3OriginConfig sets the S3OriginConfig field's value. +func (s *Origin) SetS3OriginConfig(v *S3OriginConfig) *Origin { + s.S3OriginConfig = v return s } -// The request to list your distributions. -type ListDistributionsInput struct { +// CloudFront origin access identity. +type OriginAccessIdentity struct { _ struct{} `type:"structure"` - // Use this when paginating results to indicate where to begin in your list - // of distributions. The results include distributions in the list that occur - // after the marker. To get the next page of results, set the Marker to the - // value of the NextMarker from the current page's response (which is also the - // ID of the last distribution on that page). - Marker *string `location:"querystring" locationName:"Marker" type:"string"` + // The current configuration information for the identity. + CloudFrontOriginAccessIdentityConfig *OriginAccessIdentityConfig `type:"structure"` - // The maximum number of distributions you want in the response body. - MaxItems *int64 `location:"querystring" locationName:"MaxItems" type:"integer"` + // The ID for the origin access identity, for example, E74FTE3AJFJ256A. + // + // Id is a required field + Id *string `type:"string" required:"true"` + + // The Amazon S3 canonical user ID for the origin access identity, used when + // giving the origin access identity read permission to an object in Amazon + // S3. + // + // S3CanonicalUserId is a required field + S3CanonicalUserId *string `type:"string" required:"true"` } // String returns the string representation -func (s ListDistributionsInput) String() string { +func (s OriginAccessIdentity) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s ListDistributionsInput) GoString() string { +func (s OriginAccessIdentity) GoString() string { return s.String() } -// SetMarker sets the Marker field's value. -func (s *ListDistributionsInput) SetMarker(v string) *ListDistributionsInput { - s.Marker = &v +// SetCloudFrontOriginAccessIdentityConfig sets the CloudFrontOriginAccessIdentityConfig field's value. +func (s *OriginAccessIdentity) SetCloudFrontOriginAccessIdentityConfig(v *OriginAccessIdentityConfig) *OriginAccessIdentity { + s.CloudFrontOriginAccessIdentityConfig = v return s } -// SetMaxItems sets the MaxItems field's value. -func (s *ListDistributionsInput) SetMaxItems(v int64) *ListDistributionsInput { - s.MaxItems = &v +// SetId sets the Id field's value. +func (s *OriginAccessIdentity) SetId(v string) *OriginAccessIdentity { + s.Id = &v return s } -// The returned result of the corresponding request. -type ListDistributionsOutput struct { - _ struct{} `type:"structure" payload:"DistributionList"` - - // The DistributionList type. - DistributionList *DistributionList `type:"structure"` -} - -// String returns the string representation -func (s ListDistributionsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ListDistributionsOutput) GoString() string { - return s.String() -} - -// SetDistributionList sets the DistributionList field's value. -func (s *ListDistributionsOutput) SetDistributionList(v *DistributionList) *ListDistributionsOutput { - s.DistributionList = v +// SetS3CanonicalUserId sets the S3CanonicalUserId field's value. +func (s *OriginAccessIdentity) SetS3CanonicalUserId(v string) *OriginAccessIdentity { + s.S3CanonicalUserId = &v return s } -// The request to list invalidations. -type ListInvalidationsInput struct { +// Origin access identity configuration. Send a GET request to the /CloudFront +// API version/CloudFront/identity ID/config resource. +type OriginAccessIdentityConfig struct { _ struct{} `type:"structure"` - // The distribution's ID. + // A unique number that ensures the request can't be replayed. + // + // If the CallerReference is new (no matter the content of the CloudFrontOriginAccessIdentityConfig + // object), a new origin access identity is created. + // + // If the CallerReference is a value already sent in a previous identity request, + // and the content of the CloudFrontOriginAccessIdentityConfig is identical + // to the original request (ignoring white space), the response includes the + // same information returned to the original request. + // + // If the CallerReference is a value you already sent in a previous request + // to create an identity, but the content of the CloudFrontOriginAccessIdentityConfig + // is different from the original request, CloudFront returns a CloudFrontOriginAccessIdentityAlreadyExists + // error. // - // DistributionId is a required field - DistributionId *string `location:"uri" locationName:"DistributionId" type:"string" required:"true"` - - // Use this parameter when paginating results to indicate where to begin in - // your list of invalidation batches. Because the results are returned in decreasing - // order from most recent to oldest, the most recent results are on the first - // page, the second page will contain earlier results, and so on. To get the - // next page of results, set Marker to the value of the NextMarker from the - // current page's response. This value is the same as the ID of the last invalidation - // batch on that page. - Marker *string `location:"querystring" locationName:"Marker" type:"string"` + // CallerReference is a required field + CallerReference *string `type:"string" required:"true"` - // The maximum number of invalidation batches that you want in the response - // body. - MaxItems *int64 `location:"querystring" locationName:"MaxItems" type:"integer"` + // Any comments you want to include about the origin access identity. + // + // Comment is a required field + Comment *string `type:"string" required:"true"` } // String returns the string representation -func (s ListInvalidationsInput) String() string { +func (s OriginAccessIdentityConfig) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s ListInvalidationsInput) GoString() string { +func (s OriginAccessIdentityConfig) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListInvalidationsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListInvalidationsInput"} - if s.DistributionId == nil { - invalidParams.Add(request.NewErrParamRequired("DistributionId")) +func (s *OriginAccessIdentityConfig) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "OriginAccessIdentityConfig"} + if s.CallerReference == nil { + invalidParams.Add(request.NewErrParamRequired("CallerReference")) + } + if s.Comment == nil { + invalidParams.Add(request.NewErrParamRequired("Comment")) } if invalidParams.Len() > 0 { @@ -7853,232 +12016,254 @@ func (s *ListInvalidationsInput) Validate() error { return nil } -// SetDistributionId sets the DistributionId field's value. -func (s *ListInvalidationsInput) SetDistributionId(v string) *ListInvalidationsInput { - s.DistributionId = &v +// SetCallerReference sets the CallerReference field's value. +func (s *OriginAccessIdentityConfig) SetCallerReference(v string) *OriginAccessIdentityConfig { + s.CallerReference = &v return s } -// SetMarker sets the Marker field's value. -func (s *ListInvalidationsInput) SetMarker(v string) *ListInvalidationsInput { - s.Marker = &v +// SetComment sets the Comment field's value. +func (s *OriginAccessIdentityConfig) SetComment(v string) *OriginAccessIdentityConfig { + s.Comment = &v return s } -// SetMaxItems sets the MaxItems field's value. -func (s *ListInvalidationsInput) SetMaxItems(v int64) *ListInvalidationsInput { - s.MaxItems = &v - return s -} +// Lists the origin access identities for CloudFront.Send a GET request to the +// /CloudFront API version/origin-access-identity/cloudfront resource. The response +// includes a CloudFrontOriginAccessIdentityList element with zero or more CloudFrontOriginAccessIdentitySummary +// child elements. By default, your entire list of origin access identities +// is returned in one single page. If the list is long, you can paginate it +// using the MaxItems and Marker parameters. +type OriginAccessIdentityList struct { + _ struct{} `type:"structure"` -// The returned result of the corresponding request. -type ListInvalidationsOutput struct { - _ struct{} `type:"structure" payload:"InvalidationList"` + // A flag that indicates whether more origin access identities remain to be + // listed. If your results were truncated, you can make a follow-up pagination + // request using the Marker request parameter to retrieve more items in the + // list. + // + // IsTruncated is a required field + IsTruncated *bool `type:"boolean" required:"true"` - // Information about invalidation batches. - InvalidationList *InvalidationList `type:"structure"` + // A complex type that contains one CloudFrontOriginAccessIdentitySummary element + // for each origin access identity that was created by the current AWS account. + Items []*OriginAccessIdentitySummary `locationNameList:"CloudFrontOriginAccessIdentitySummary" type:"list"` + + // Use this when paginating results to indicate where to begin in your list + // of origin access identities. The results include identities in the list that + // occur after the marker. To get the next page of results, set the Marker to + // the value of the NextMarker from the current page's response (which is also + // the ID of the last identity on that page). + // + // Marker is a required field + Marker *string `type:"string" required:"true"` + + // The maximum number of origin access identities you want in the response body. + // + // MaxItems is a required field + MaxItems *int64 `type:"integer" required:"true"` + + // If IsTruncated is true, this element is present and contains the value you + // can use for the Marker request parameter to continue listing your origin + // access identities where they left off. + NextMarker *string `type:"string"` + + // The number of CloudFront origin access identities that were created by the + // current AWS account. + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` } // String returns the string representation -func (s ListInvalidationsOutput) String() string { +func (s OriginAccessIdentityList) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s ListInvalidationsOutput) GoString() string { +func (s OriginAccessIdentityList) GoString() string { return s.String() } -// SetInvalidationList sets the InvalidationList field's value. -func (s *ListInvalidationsOutput) SetInvalidationList(v *InvalidationList) *ListInvalidationsOutput { - s.InvalidationList = v +// SetIsTruncated sets the IsTruncated field's value. +func (s *OriginAccessIdentityList) SetIsTruncated(v bool) *OriginAccessIdentityList { + s.IsTruncated = &v return s } -// The request to list your streaming distributions. -type ListStreamingDistributionsInput struct { - _ struct{} `type:"structure"` - - // The value that you provided for the Marker request parameter. - Marker *string `location:"querystring" locationName:"Marker" type:"string"` - - // The value that you provided for the MaxItems request parameter. - MaxItems *int64 `location:"querystring" locationName:"MaxItems" type:"integer"` -} - -// String returns the string representation -func (s ListStreamingDistributionsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ListStreamingDistributionsInput) GoString() string { - return s.String() +// SetItems sets the Items field's value. +func (s *OriginAccessIdentityList) SetItems(v []*OriginAccessIdentitySummary) *OriginAccessIdentityList { + s.Items = v + return s } // SetMarker sets the Marker field's value. -func (s *ListStreamingDistributionsInput) SetMarker(v string) *ListStreamingDistributionsInput { +func (s *OriginAccessIdentityList) SetMarker(v string) *OriginAccessIdentityList { s.Marker = &v return s } // SetMaxItems sets the MaxItems field's value. -func (s *ListStreamingDistributionsInput) SetMaxItems(v int64) *ListStreamingDistributionsInput { +func (s *OriginAccessIdentityList) SetMaxItems(v int64) *OriginAccessIdentityList { s.MaxItems = &v return s } -// The returned result of the corresponding request. -type ListStreamingDistributionsOutput struct { - _ struct{} `type:"structure" payload:"StreamingDistributionList"` - - // The StreamingDistributionList type. - StreamingDistributionList *StreamingDistributionList `type:"structure"` -} - -// String returns the string representation -func (s ListStreamingDistributionsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ListStreamingDistributionsOutput) GoString() string { - return s.String() +// SetNextMarker sets the NextMarker field's value. +func (s *OriginAccessIdentityList) SetNextMarker(v string) *OriginAccessIdentityList { + s.NextMarker = &v + return s } -// SetStreamingDistributionList sets the StreamingDistributionList field's value. -func (s *ListStreamingDistributionsOutput) SetStreamingDistributionList(v *StreamingDistributionList) *ListStreamingDistributionsOutput { - s.StreamingDistributionList = v +// SetQuantity sets the Quantity field's value. +func (s *OriginAccessIdentityList) SetQuantity(v int64) *OriginAccessIdentityList { + s.Quantity = &v return s } -// The request to list tags for a CloudFront resource. -type ListTagsForResourceInput struct { +// Summary of the information about a CloudFront origin access identity. +type OriginAccessIdentitySummary struct { _ struct{} `type:"structure"` - // An ARN of a CloudFront resource. + // The comment for this origin access identity, as originally specified when + // created. // - // Resource is a required field - Resource *string `location:"querystring" locationName:"Resource" type:"string" required:"true"` + // Comment is a required field + Comment *string `type:"string" required:"true"` + + // The ID for the origin access identity. For example: E74FTE3AJFJ256A. + // + // Id is a required field + Id *string `type:"string" required:"true"` + + // The Amazon S3 canonical user ID for the origin access identity, which you + // use when giving the origin access identity read permission to an object in + // Amazon S3. + // + // S3CanonicalUserId is a required field + S3CanonicalUserId *string `type:"string" required:"true"` } // String returns the string representation -func (s ListTagsForResourceInput) String() string { +func (s OriginAccessIdentitySummary) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s ListTagsForResourceInput) GoString() string { +func (s OriginAccessIdentitySummary) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *ListTagsForResourceInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListTagsForResourceInput"} - if s.Resource == nil { - invalidParams.Add(request.NewErrParamRequired("Resource")) - } +// SetComment sets the Comment field's value. +func (s *OriginAccessIdentitySummary) SetComment(v string) *OriginAccessIdentitySummary { + s.Comment = &v + return s +} - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetId sets the Id field's value. +func (s *OriginAccessIdentitySummary) SetId(v string) *OriginAccessIdentitySummary { + s.Id = &v + return s } -// SetResource sets the Resource field's value. -func (s *ListTagsForResourceInput) SetResource(v string) *ListTagsForResourceInput { - s.Resource = &v +// SetS3CanonicalUserId sets the S3CanonicalUserId field's value. +func (s *OriginAccessIdentitySummary) SetS3CanonicalUserId(v string) *OriginAccessIdentitySummary { + s.S3CanonicalUserId = &v return s } -// The returned result of the corresponding request. -type ListTagsForResourceOutput struct { - _ struct{} `type:"structure" payload:"Tags"` +// A complex type that contains HeaderName and HeaderValue elements, if any, +// for this distribution. +type OriginCustomHeader struct { + _ struct{} `type:"structure"` - // A complex type that contains zero or more Tag elements. + // The name of a header that you want CloudFront to forward to your origin. + // For more information, see Forwarding Custom Headers to Your Origin (Web Distributions + // Only) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/forward-custom-headers.html) + // in the Amazon Amazon CloudFront Developer Guide. // - // Tags is a required field - Tags *Tags `type:"structure" required:"true"` + // HeaderName is a required field + HeaderName *string `type:"string" required:"true"` + + // The value for the header that you specified in the HeaderName field. + // + // HeaderValue is a required field + HeaderValue *string `type:"string" required:"true"` } // String returns the string representation -func (s ListTagsForResourceOutput) String() string { +func (s OriginCustomHeader) String() string { return awsutil.Prettify(s) } -// GoString returns the string representation -func (s ListTagsForResourceOutput) GoString() string { - return s.String() +// GoString returns the string representation +func (s OriginCustomHeader) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *OriginCustomHeader) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "OriginCustomHeader"} + if s.HeaderName == nil { + invalidParams.Add(request.NewErrParamRequired("HeaderName")) + } + if s.HeaderValue == nil { + invalidParams.Add(request.NewErrParamRequired("HeaderValue")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetHeaderName sets the HeaderName field's value. +func (s *OriginCustomHeader) SetHeaderName(v string) *OriginCustomHeader { + s.HeaderName = &v + return s } -// SetTags sets the Tags field's value. -func (s *ListTagsForResourceOutput) SetTags(v *Tags) *ListTagsForResourceOutput { - s.Tags = v +// SetHeaderValue sets the HeaderValue field's value. +func (s *OriginCustomHeader) SetHeaderValue(v string) *OriginCustomHeader { + s.HeaderValue = &v return s } -// A complex type that controls whether access logs are written for the distribution. -type LoggingConfig struct { +// A complex type that contains information about the SSL/TLS protocols that +// CloudFront can use when establishing an HTTPS connection with your origin. +type OriginSslProtocols struct { _ struct{} `type:"structure"` - // The Amazon S3 bucket to store the access logs in, for example, myawslogbucket.s3.amazonaws.com. - // - // Bucket is a required field - Bucket *string `type:"string" required:"true"` - - // Specifies whether you want CloudFront to save access logs to an Amazon S3 - // bucket. If you don't want to enable logging when you create a distribution - // or if you want to disable logging for an existing distribution, specify false - // for Enabled, and specify empty Bucket and Prefix elements. If you specify - // false for Enabled but you specify values for Bucket, prefix, and IncludeCookies, - // the values are automatically deleted. - // - // Enabled is a required field - Enabled *bool `type:"boolean" required:"true"` - - // Specifies whether you want CloudFront to include cookies in access logs, - // specify true for IncludeCookies. If you choose to include cookies in logs, - // CloudFront logs all cookies regardless of how you configure the cache behaviors - // for this distribution. If you don't want to include cookies when you create - // a distribution or if you want to disable include cookies for an existing - // distribution, specify false for IncludeCookies. + // A list that contains allowed SSL/TLS protocols for this distribution. // - // IncludeCookies is a required field - IncludeCookies *bool `type:"boolean" required:"true"` + // Items is a required field + Items []*string `locationNameList:"SslProtocol" type:"list" required:"true"` - // An optional string that you want CloudFront to prefix to the access log filenames - // for this distribution, for example, myprefix/. If you want to enable logging, - // but you don't want to specify a prefix, you still must include an empty Prefix - // element in the Logging element. + // The number of SSL/TLS protocols that you want to allow CloudFront to use + // when establishing an HTTPS connection with this origin. // - // Prefix is a required field - Prefix *string `type:"string" required:"true"` + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` } // String returns the string representation -func (s LoggingConfig) String() string { +func (s OriginSslProtocols) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s LoggingConfig) GoString() string { +func (s OriginSslProtocols) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *LoggingConfig) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "LoggingConfig"} - if s.Bucket == nil { - invalidParams.Add(request.NewErrParamRequired("Bucket")) - } - if s.Enabled == nil { - invalidParams.Add(request.NewErrParamRequired("Enabled")) - } - if s.IncludeCookies == nil { - invalidParams.Add(request.NewErrParamRequired("IncludeCookies")) +func (s *OriginSslProtocols) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "OriginSslProtocols"} + if s.Items == nil { + invalidParams.Add(request.NewErrParamRequired("Items")) } - if s.Prefix == nil { - invalidParams.Add(request.NewErrParamRequired("Prefix")) + if s.Quantity == nil { + invalidParams.Add(request.NewErrParamRequired("Quantity")) } if invalidParams.Len() > 0 { @@ -8087,148 +12272,58 @@ func (s *LoggingConfig) Validate() error { return nil } -// SetBucket sets the Bucket field's value. -func (s *LoggingConfig) SetBucket(v string) *LoggingConfig { - s.Bucket = &v - return s -} - -// SetEnabled sets the Enabled field's value. -func (s *LoggingConfig) SetEnabled(v bool) *LoggingConfig { - s.Enabled = &v - return s -} - -// SetIncludeCookies sets the IncludeCookies field's value. -func (s *LoggingConfig) SetIncludeCookies(v bool) *LoggingConfig { - s.IncludeCookies = &v +// SetItems sets the Items field's value. +func (s *OriginSslProtocols) SetItems(v []*string) *OriginSslProtocols { + s.Items = v return s } -// SetPrefix sets the Prefix field's value. -func (s *LoggingConfig) SetPrefix(v string) *LoggingConfig { - s.Prefix = &v +// SetQuantity sets the Quantity field's value. +func (s *OriginSslProtocols) SetQuantity(v int64) *OriginSslProtocols { + s.Quantity = &v return s } -// A complex type that describes the Amazon S3 bucket or the HTTP server (for -// example, a web server) from which CloudFront gets your files. You must create -// at least one origin. -// -// For the current limit on the number of origins that you can create for a -// distribution, see Amazon CloudFront Limits (http://docs.aws.amazon.com/general/latest/gr/aws_service_limits.html#limits_cloudfront) -// in the AWS General Reference. -type Origin struct { +// A complex type that contains information about origins for this distribution. +type Origins struct { _ struct{} `type:"structure"` - // A complex type that contains names and values for the custom headers that - // you want. - CustomHeaders *CustomHeaders `type:"structure"` - - // A complex type that contains information about a custom origin. If the origin - // is an Amazon S3 bucket, use the S3OriginConfig element instead. - CustomOriginConfig *CustomOriginConfig `type:"structure"` - - // Amazon S3 origins: The DNS name of the Amazon S3 bucket from which you want - // CloudFront to get objects for this origin, for example, myawsbucket.s3.amazonaws.com. - // - // Constraints for Amazon S3 origins: - // - // * If you configured Amazon S3 Transfer Acceleration for your bucket, don't - // specify the s3-accelerate endpoint for DomainName. - // - // * The bucket name must be between 3 and 63 characters long (inclusive). - // - // * The bucket name must contain only lowercase characters, numbers, periods, - // underscores, and dashes. - // - // * The bucket name must not contain adjacent periods. - // - // Custom Origins: The DNS domain name for the HTTP server from which you want - // CloudFront to get objects for this origin, for example, www.example.com. - // - // Constraints for custom origins: - // - // * DomainName must be a valid DNS name that contains only a-z, A-Z, 0-9, - // dot (.), hyphen (-), or underscore (_) characters. - // - // * The name cannot exceed 128 characters. - // - // DomainName is a required field - DomainName *string `type:"string" required:"true"` - - // A unique identifier for the origin. The value of Id must be unique within - // the distribution. - // - // When you specify the value of TargetOriginId for the default cache behavior - // or for another cache behavior, you indicate the origin to which you want - // the cache behavior to route requests by specifying the value of the Id element - // for that origin. When a request matches the path pattern for that cache behavior, - // CloudFront routes the request to the specified origin. For more information, - // see Cache Behavior Settings (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/distribution-web-values-specify.html#DownloadDistValuesCacheBehavior) - // in the Amazon CloudFront Developer Guide. - // - // Id is a required field - Id *string `type:"string" required:"true"` + // A complex type that contains origins for this distribution. + Items []*Origin `locationNameList:"Origin" min:"1" type:"list"` - // An optional element that causes CloudFront to request your content from a - // directory in your Amazon S3 bucket or your custom origin. When you include - // the OriginPath element, specify the directory name, beginning with a /. CloudFront - // appends the directory name to the value of DomainName, for example, example.com/production. - // Do not include a / at the end of the directory name. - // - // For example, suppose you've specified the following values for your distribution: - // - // * DomainName: An Amazon S3 bucket named myawsbucket. - // - // * OriginPath: /production - // - // * CNAME: example.com - // - // When a user enters example.com/index.html in a browser, CloudFront sends - // a request to Amazon S3 for myawsbucket/production/index.html. + // The number of origins for this distribution. // - // When a user enters example.com/acme/index.html in a browser, CloudFront sends - // a request to Amazon S3 for myawsbucket/production/acme/index.html. - OriginPath *string `type:"string"` - - // A complex type that contains information about the Amazon S3 origin. If the - // origin is a custom origin, use the CustomOriginConfig element instead. - S3OriginConfig *S3OriginConfig `type:"structure"` + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` } // String returns the string representation -func (s Origin) String() string { +func (s Origins) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s Origin) GoString() string { +func (s Origins) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *Origin) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "Origin"} - if s.DomainName == nil { - invalidParams.Add(request.NewErrParamRequired("DomainName")) - } - if s.Id == nil { - invalidParams.Add(request.NewErrParamRequired("Id")) - } - if s.CustomHeaders != nil { - if err := s.CustomHeaders.Validate(); err != nil { - invalidParams.AddNested("CustomHeaders", err.(request.ErrInvalidParams)) - } +func (s *Origins) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "Origins"} + if s.Items != nil && len(s.Items) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Items", 1)) } - if s.CustomOriginConfig != nil { - if err := s.CustomOriginConfig.Validate(); err != nil { - invalidParams.AddNested("CustomOriginConfig", err.(request.ErrInvalidParams)) - } + if s.Quantity == nil { + invalidParams.Add(request.NewErrParamRequired("Quantity")) } - if s.S3OriginConfig != nil { - if err := s.S3OriginConfig.Validate(); err != nil { - invalidParams.AddNested("S3OriginConfig", err.(request.ErrInvalidParams)) + if s.Items != nil { + for i, v := range s.Items { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Items", i), err.(request.ErrInvalidParams)) + } } } @@ -8238,137 +12333,166 @@ func (s *Origin) Validate() error { return nil } -// SetCustomHeaders sets the CustomHeaders field's value. -func (s *Origin) SetCustomHeaders(v *CustomHeaders) *Origin { - s.CustomHeaders = v +// SetItems sets the Items field's value. +func (s *Origins) SetItems(v []*Origin) *Origins { + s.Items = v + return s +} + +// SetQuantity sets the Quantity field's value. +func (s *Origins) SetQuantity(v int64) *Origins { + s.Quantity = &v return s } -// SetCustomOriginConfig sets the CustomOriginConfig field's value. -func (s *Origin) SetCustomOriginConfig(v *CustomOriginConfig) *Origin { - s.CustomOriginConfig = v - return s +// A complex type that contains information about the objects that you want +// to invalidate. For more information, see Specifying the Objects to Invalidate +// (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Invalidation.html#invalidation-specifying-objects) +// in the Amazon CloudFront Developer Guide. +type Paths struct { + _ struct{} `type:"structure"` + + // A complex type that contains a list of the paths that you want to invalidate. + Items []*string `locationNameList:"Path" type:"list"` + + // The number of objects that you want to invalidate. + // + // Quantity is a required field + Quantity *int64 `type:"integer" required:"true"` +} + +// String returns the string representation +func (s Paths) String() string { + return awsutil.Prettify(s) } -// SetDomainName sets the DomainName field's value. -func (s *Origin) SetDomainName(v string) *Origin { - s.DomainName = &v - return s +// GoString returns the string representation +func (s Paths) GoString() string { + return s.String() } -// SetId sets the Id field's value. -func (s *Origin) SetId(v string) *Origin { - s.Id = &v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *Paths) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "Paths"} + if s.Quantity == nil { + invalidParams.Add(request.NewErrParamRequired("Quantity")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetOriginPath sets the OriginPath field's value. -func (s *Origin) SetOriginPath(v string) *Origin { - s.OriginPath = &v +// SetItems sets the Items field's value. +func (s *Paths) SetItems(v []*string) *Paths { + s.Items = v return s } -// SetS3OriginConfig sets the S3OriginConfig field's value. -func (s *Origin) SetS3OriginConfig(v *S3OriginConfig) *Origin { - s.S3OriginConfig = v +// SetQuantity sets the Quantity field's value. +func (s *Paths) SetQuantity(v int64) *Paths { + s.Quantity = &v return s } -// CloudFront origin access identity. -type OriginAccessIdentity struct { +// A complex data type of public keys you add to CloudFront to use with features +// like field-level encryption. +type PublicKey struct { _ struct{} `type:"structure"` - // The current configuration information for the identity. - CloudFrontOriginAccessIdentityConfig *OriginAccessIdentityConfig `type:"structure"` + // A time you added a public key to CloudFront. + // + // CreatedTime is a required field + CreatedTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"` - // The ID for the origin access identity, for example, E74FTE3AJFJ256A. + // A unique ID assigned to a public key you've added to CloudFront. // // Id is a required field Id *string `type:"string" required:"true"` - // The Amazon S3 canonical user ID for the origin access identity, used when - // giving the origin access identity read permission to an object in Amazon - // S3. + // A complex data type for a public key you add to CloudFront to use with features + // like field-level encryption. // - // S3CanonicalUserId is a required field - S3CanonicalUserId *string `type:"string" required:"true"` + // PublicKeyConfig is a required field + PublicKeyConfig *PublicKeyConfig `type:"structure" required:"true"` } // String returns the string representation -func (s OriginAccessIdentity) String() string { +func (s PublicKey) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s OriginAccessIdentity) GoString() string { +func (s PublicKey) GoString() string { return s.String() } -// SetCloudFrontOriginAccessIdentityConfig sets the CloudFrontOriginAccessIdentityConfig field's value. -func (s *OriginAccessIdentity) SetCloudFrontOriginAccessIdentityConfig(v *OriginAccessIdentityConfig) *OriginAccessIdentity { - s.CloudFrontOriginAccessIdentityConfig = v +// SetCreatedTime sets the CreatedTime field's value. +func (s *PublicKey) SetCreatedTime(v time.Time) *PublicKey { + s.CreatedTime = &v return s } // SetId sets the Id field's value. -func (s *OriginAccessIdentity) SetId(v string) *OriginAccessIdentity { +func (s *PublicKey) SetId(v string) *PublicKey { s.Id = &v return s } -// SetS3CanonicalUserId sets the S3CanonicalUserId field's value. -func (s *OriginAccessIdentity) SetS3CanonicalUserId(v string) *OriginAccessIdentity { - s.S3CanonicalUserId = &v +// SetPublicKeyConfig sets the PublicKeyConfig field's value. +func (s *PublicKey) SetPublicKeyConfig(v *PublicKeyConfig) *PublicKey { + s.PublicKeyConfig = v return s } -// Origin access identity configuration. Send a GET request to the /CloudFront -// API version/CloudFront/identity ID/config resource. -type OriginAccessIdentityConfig struct { +// Information about a public key you add to CloudFront to use with features +// like field-level encryption. +type PublicKeyConfig struct { _ struct{} `type:"structure"` // A unique number that ensures the request can't be replayed. // - // If the CallerReference is new (no matter the content of the CloudFrontOriginAccessIdentityConfig - // object), a new origin access identity is created. - // - // If the CallerReference is a value already sent in a previous identity request, - // and the content of the CloudFrontOriginAccessIdentityConfig is identical - // to the original request (ignoring white space), the response includes the - // same information returned to the original request. - // - // If the CallerReference is a value you already sent in a previous request - // to create an identity, but the content of the CloudFrontOriginAccessIdentityConfig - // is different from the original request, CloudFront returns a CloudFrontOriginAccessIdentityAlreadyExists - // error. - // // CallerReference is a required field CallerReference *string `type:"string" required:"true"` - // Any comments you want to include about the origin access identity. + // An optional comment about a public key. + Comment *string `type:"string"` + + // The encoded public key that you want to add to CloudFront to use with features + // like field-level encryption. // - // Comment is a required field - Comment *string `type:"string" required:"true"` + // EncodedKey is a required field + EncodedKey *string `type:"string" required:"true"` + + // The name for a public key you add to CloudFront to use with features like + // field-level encryption. + // + // Name is a required field + Name *string `type:"string" required:"true"` } // String returns the string representation -func (s OriginAccessIdentityConfig) String() string { +func (s PublicKeyConfig) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s OriginAccessIdentityConfig) GoString() string { +func (s PublicKeyConfig) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *OriginAccessIdentityConfig) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "OriginAccessIdentityConfig"} +func (s *PublicKeyConfig) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PublicKeyConfig"} if s.CallerReference == nil { invalidParams.Add(request.NewErrParamRequired("CallerReference")) } - if s.Comment == nil { - invalidParams.Add(request.NewErrParamRequired("Comment")) + if s.EncodedKey == nil { + invalidParams.Add(request.NewErrParamRequired("EncodedKey")) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) } if invalidParams.Len() > 0 { @@ -8378,253 +12502,190 @@ func (s *OriginAccessIdentityConfig) Validate() error { } // SetCallerReference sets the CallerReference field's value. -func (s *OriginAccessIdentityConfig) SetCallerReference(v string) *OriginAccessIdentityConfig { +func (s *PublicKeyConfig) SetCallerReference(v string) *PublicKeyConfig { s.CallerReference = &v return s } // SetComment sets the Comment field's value. -func (s *OriginAccessIdentityConfig) SetComment(v string) *OriginAccessIdentityConfig { +func (s *PublicKeyConfig) SetComment(v string) *PublicKeyConfig { s.Comment = &v return s } -// Lists the origin access identities for CloudFront.Send a GET request to the -// /CloudFront API version/origin-access-identity/cloudfront resource. The response -// includes a CloudFrontOriginAccessIdentityList element with zero or more CloudFrontOriginAccessIdentitySummary -// child elements. By default, your entire list of origin access identities -// is returned in one single page. If the list is long, you can paginate it -// using the MaxItems and Marker parameters. -type OriginAccessIdentityList struct { - _ struct{} `type:"structure"` +// SetEncodedKey sets the EncodedKey field's value. +func (s *PublicKeyConfig) SetEncodedKey(v string) *PublicKeyConfig { + s.EncodedKey = &v + return s +} - // A flag that indicates whether more origin access identities remain to be - // listed. If your results were truncated, you can make a follow-up pagination - // request using the Marker request parameter to retrieve more items in the - // list. - // - // IsTruncated is a required field - IsTruncated *bool `type:"boolean" required:"true"` +// SetName sets the Name field's value. +func (s *PublicKeyConfig) SetName(v string) *PublicKeyConfig { + s.Name = &v + return s +} - // A complex type that contains one CloudFrontOriginAccessIdentitySummary element - // for each origin access identity that was created by the current AWS account. - Items []*OriginAccessIdentitySummary `locationNameList:"CloudFrontOriginAccessIdentitySummary" type:"list"` +// A list of public keys you've added to CloudFront to use with features like +// field-level encryption. +type PublicKeyList struct { + _ struct{} `type:"structure"` - // Use this when paginating results to indicate where to begin in your list - // of origin access identities. The results include identities in the list that - // occur after the marker. To get the next page of results, set the Marker to - // the value of the NextMarker from the current page's response (which is also - // the ID of the last identity on that page). - // - // Marker is a required field - Marker *string `type:"string" required:"true"` + // An array of information about a public key you add to CloudFront to use with + // features like field-level encryption. + Items []*PublicKeySummary `locationNameList:"PublicKeySummary" type:"list"` - // The maximum number of origin access identities you want in the response body. + // The maximum number of public keys you want in the response body. // // MaxItems is a required field MaxItems *int64 `type:"integer" required:"true"` - // If IsTruncated is true, this element is present and contains the value you - // can use for the Marker request parameter to continue listing your origin - // access identities where they left off. + // If there are more elements to be listed, this element is present and contains + // the value that you can use for the Marker request parameter to continue listing + // your public keys where you left off. NextMarker *string `type:"string"` - // The number of CloudFront origin access identities that were created by the - // current AWS account. + // The number of public keys you added to CloudFront to use with features like + // field-level encryption. // // Quantity is a required field Quantity *int64 `type:"integer" required:"true"` } // String returns the string representation -func (s OriginAccessIdentityList) String() string { +func (s PublicKeyList) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s OriginAccessIdentityList) GoString() string { +func (s PublicKeyList) GoString() string { return s.String() } -// SetIsTruncated sets the IsTruncated field's value. -func (s *OriginAccessIdentityList) SetIsTruncated(v bool) *OriginAccessIdentityList { - s.IsTruncated = &v - return s -} - // SetItems sets the Items field's value. -func (s *OriginAccessIdentityList) SetItems(v []*OriginAccessIdentitySummary) *OriginAccessIdentityList { +func (s *PublicKeyList) SetItems(v []*PublicKeySummary) *PublicKeyList { s.Items = v return s } -// SetMarker sets the Marker field's value. -func (s *OriginAccessIdentityList) SetMarker(v string) *OriginAccessIdentityList { - s.Marker = &v - return s -} - // SetMaxItems sets the MaxItems field's value. -func (s *OriginAccessIdentityList) SetMaxItems(v int64) *OriginAccessIdentityList { +func (s *PublicKeyList) SetMaxItems(v int64) *PublicKeyList { s.MaxItems = &v return s } // SetNextMarker sets the NextMarker field's value. -func (s *OriginAccessIdentityList) SetNextMarker(v string) *OriginAccessIdentityList { +func (s *PublicKeyList) SetNextMarker(v string) *PublicKeyList { s.NextMarker = &v return s } // SetQuantity sets the Quantity field's value. -func (s *OriginAccessIdentityList) SetQuantity(v int64) *OriginAccessIdentityList { +func (s *PublicKeyList) SetQuantity(v int64) *PublicKeyList { s.Quantity = &v return s } -// Summary of the information about a CloudFront origin access identity. -type OriginAccessIdentitySummary struct { +// Public key information summary. +type PublicKeySummary struct { _ struct{} `type:"structure"` - // The comment for this origin access identity, as originally specified when - // created. + // Comment for public key information summary. + Comment *string `type:"string"` + + // Creation time for public key information summary. // - // Comment is a required field - Comment *string `type:"string" required:"true"` + // CreatedTime is a required field + CreatedTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"` - // The ID for the origin access identity. For example: E74FTE3AJFJ256A. + // Encoded key for public key information summary. + // + // EncodedKey is a required field + EncodedKey *string `type:"string" required:"true"` + + // ID for public key information summary. // // Id is a required field Id *string `type:"string" required:"true"` - // The Amazon S3 canonical user ID for the origin access identity, which you - // use when giving the origin access identity read permission to an object in - // Amazon S3. + // Name for public key information summary. // - // S3CanonicalUserId is a required field - S3CanonicalUserId *string `type:"string" required:"true"` + // Name is a required field + Name *string `type:"string" required:"true"` } // String returns the string representation -func (s OriginAccessIdentitySummary) String() string { +func (s PublicKeySummary) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s OriginAccessIdentitySummary) GoString() string { +func (s PublicKeySummary) GoString() string { return s.String() } // SetComment sets the Comment field's value. -func (s *OriginAccessIdentitySummary) SetComment(v string) *OriginAccessIdentitySummary { +func (s *PublicKeySummary) SetComment(v string) *PublicKeySummary { s.Comment = &v return s } -// SetId sets the Id field's value. -func (s *OriginAccessIdentitySummary) SetId(v string) *OriginAccessIdentitySummary { - s.Id = &v +// SetCreatedTime sets the CreatedTime field's value. +func (s *PublicKeySummary) SetCreatedTime(v time.Time) *PublicKeySummary { + s.CreatedTime = &v return s } -// SetS3CanonicalUserId sets the S3CanonicalUserId field's value. -func (s *OriginAccessIdentitySummary) SetS3CanonicalUserId(v string) *OriginAccessIdentitySummary { - s.S3CanonicalUserId = &v +// SetEncodedKey sets the EncodedKey field's value. +func (s *PublicKeySummary) SetEncodedKey(v string) *PublicKeySummary { + s.EncodedKey = &v return s } -// A complex type that contains HeaderName and HeaderValue elements, if any, -// for this distribution. -type OriginCustomHeader struct { - _ struct{} `type:"structure"` - - // The name of a header that you want CloudFront to forward to your origin. - // For more information, see Forwarding Custom Headers to Your Origin (Web Distributions - // Only) (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/forward-custom-headers.html) - // in the Amazon Amazon CloudFront Developer Guide. - // - // HeaderName is a required field - HeaderName *string `type:"string" required:"true"` - - // The value for the header that you specified in the HeaderName field. - // - // HeaderValue is a required field - HeaderValue *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s OriginCustomHeader) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s OriginCustomHeader) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *OriginCustomHeader) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "OriginCustomHeader"} - if s.HeaderName == nil { - invalidParams.Add(request.NewErrParamRequired("HeaderName")) - } - if s.HeaderValue == nil { - invalidParams.Add(request.NewErrParamRequired("HeaderValue")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetHeaderName sets the HeaderName field's value. -func (s *OriginCustomHeader) SetHeaderName(v string) *OriginCustomHeader { - s.HeaderName = &v +// SetId sets the Id field's value. +func (s *PublicKeySummary) SetId(v string) *PublicKeySummary { + s.Id = &v return s } -// SetHeaderValue sets the HeaderValue field's value. -func (s *OriginCustomHeader) SetHeaderValue(v string) *OriginCustomHeader { - s.HeaderValue = &v +// SetName sets the Name field's value. +func (s *PublicKeySummary) SetName(v string) *PublicKeySummary { + s.Name = &v return s } -// A complex type that contains information about the SSL/TLS protocols that -// CloudFront can use when establishing an HTTPS connection with your origin. -type OriginSslProtocols struct { +// Query argument-profile mapping for field-level encryption. +type QueryArgProfile struct { _ struct{} `type:"structure"` - // A list that contains allowed SSL/TLS protocols for this distribution. + // ID of profile to use for field-level encryption query argument-profile mapping // - // Items is a required field - Items []*string `locationNameList:"SslProtocol" type:"list" required:"true"` + // ProfileId is a required field + ProfileId *string `type:"string" required:"true"` - // The number of SSL/TLS protocols that you want to allow CloudFront to use - // when establishing an HTTPS connection with this origin. + // Query argument for field-level encryption query argument-profile mapping. // - // Quantity is a required field - Quantity *int64 `type:"integer" required:"true"` + // QueryArg is a required field + QueryArg *string `type:"string" required:"true"` } // String returns the string representation -func (s OriginSslProtocols) String() string { +func (s QueryArgProfile) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s OriginSslProtocols) GoString() string { +func (s QueryArgProfile) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *OriginSslProtocols) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "OriginSslProtocols"} - if s.Items == nil { - invalidParams.Add(request.NewErrParamRequired("Items")) +func (s *QueryArgProfile) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "QueryArgProfile"} + if s.ProfileId == nil { + invalidParams.Add(request.NewErrParamRequired("ProfileId")) } - if s.Quantity == nil { - invalidParams.Add(request.NewErrParamRequired("Quantity")) + if s.QueryArg == nil { + invalidParams.Add(request.NewErrParamRequired("QueryArg")) } if invalidParams.Len() > 0 { @@ -8633,58 +12694,52 @@ func (s *OriginSslProtocols) Validate() error { return nil } -// SetItems sets the Items field's value. -func (s *OriginSslProtocols) SetItems(v []*string) *OriginSslProtocols { - s.Items = v +// SetProfileId sets the ProfileId field's value. +func (s *QueryArgProfile) SetProfileId(v string) *QueryArgProfile { + s.ProfileId = &v return s } -// SetQuantity sets the Quantity field's value. -func (s *OriginSslProtocols) SetQuantity(v int64) *OriginSslProtocols { - s.Quantity = &v +// SetQueryArg sets the QueryArg field's value. +func (s *QueryArgProfile) SetQueryArg(v string) *QueryArgProfile { + s.QueryArg = &v return s } -// A complex type that contains information about origins for this distribution. -type Origins struct { - _ struct{} `type:"structure"` - - // A complex type that contains origins for this distribution. - Items []*Origin `locationNameList:"Origin" min:"1" type:"list"` - - // The number of origins for this distribution. +// Configuration for query argument-profile mapping for field-level encryption. +type QueryArgProfileConfig struct { + _ struct{} `type:"structure"` + + // Flag to set if you want a request to be forwarded to the origin even if the + // profile specified by the field-level encryption query argument, fle-profile, + // is unknown. // - // Quantity is a required field - Quantity *int64 `type:"integer" required:"true"` + // ForwardWhenQueryArgProfileIsUnknown is a required field + ForwardWhenQueryArgProfileIsUnknown *bool `type:"boolean" required:"true"` + + // Profiles specified for query argument-profile mapping for field-level encryption. + QueryArgProfiles *QueryArgProfiles `type:"structure"` } // String returns the string representation -func (s Origins) String() string { +func (s QueryArgProfileConfig) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s Origins) GoString() string { +func (s QueryArgProfileConfig) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *Origins) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "Origins"} - if s.Items != nil && len(s.Items) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Items", 1)) - } - if s.Quantity == nil { - invalidParams.Add(request.NewErrParamRequired("Quantity")) - } - if s.Items != nil { - for i, v := range s.Items { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Items", i), err.(request.ErrInvalidParams)) - } +func (s *QueryArgProfileConfig) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "QueryArgProfileConfig"} + if s.ForwardWhenQueryArgProfileIsUnknown == nil { + invalidParams.Add(request.NewErrParamRequired("ForwardWhenQueryArgProfileIsUnknown")) + } + if s.QueryArgProfiles != nil { + if err := s.QueryArgProfiles.Validate(); err != nil { + invalidParams.AddNested("QueryArgProfiles", err.(request.ErrInvalidParams)) } } @@ -8694,50 +12749,57 @@ func (s *Origins) Validate() error { return nil } -// SetItems sets the Items field's value. -func (s *Origins) SetItems(v []*Origin) *Origins { - s.Items = v +// SetForwardWhenQueryArgProfileIsUnknown sets the ForwardWhenQueryArgProfileIsUnknown field's value. +func (s *QueryArgProfileConfig) SetForwardWhenQueryArgProfileIsUnknown(v bool) *QueryArgProfileConfig { + s.ForwardWhenQueryArgProfileIsUnknown = &v return s } -// SetQuantity sets the Quantity field's value. -func (s *Origins) SetQuantity(v int64) *Origins { - s.Quantity = &v +// SetQueryArgProfiles sets the QueryArgProfiles field's value. +func (s *QueryArgProfileConfig) SetQueryArgProfiles(v *QueryArgProfiles) *QueryArgProfileConfig { + s.QueryArgProfiles = v return s } -// A complex type that contains information about the objects that you want -// to invalidate. For more information, see Specifying the Objects to Invalidate -// (http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Invalidation.html#invalidation-specifying-objects) -// in the Amazon CloudFront Developer Guide. -type Paths struct { +// Query argument-profile mapping for field-level encryption. +type QueryArgProfiles struct { _ struct{} `type:"structure"` - // A complex type that contains a list of the paths that you want to invalidate. - Items []*string `locationNameList:"Path" type:"list"` + // Number of items for query argument-profile mapping for field-level encryption. + Items []*QueryArgProfile `locationNameList:"QueryArgProfile" type:"list"` - // The number of objects that you want to invalidate. + // Number of profiles for query argument-profile mapping for field-level encryption. // // Quantity is a required field Quantity *int64 `type:"integer" required:"true"` } // String returns the string representation -func (s Paths) String() string { +func (s QueryArgProfiles) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s Paths) GoString() string { +func (s QueryArgProfiles) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *Paths) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "Paths"} +func (s *QueryArgProfiles) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "QueryArgProfiles"} if s.Quantity == nil { invalidParams.Add(request.NewErrParamRequired("Quantity")) } + if s.Items != nil { + for i, v := range s.Items { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Items", i), err.(request.ErrInvalidParams)) + } + } + } if invalidParams.Len() > 0 { return invalidParams @@ -8746,13 +12808,13 @@ func (s *Paths) Validate() error { } // SetItems sets the Items field's value. -func (s *Paths) SetItems(v []*string) *Paths { +func (s *QueryArgProfiles) SetItems(v []*QueryArgProfile) *QueryArgProfiles { s.Items = v return s } // SetQuantity sets the Quantity field's value. -func (s *Paths) SetQuantity(v int64) *Paths { +func (s *QueryArgProfiles) SetQuantity(v int64) *QueryArgProfiles { s.Quantity = &v return s } @@ -9752,7 +13814,7 @@ type TagResourceInput struct { // A complex type that contains zero or more Tag elements. // // Tags is a required field - Tags *Tags `locationName:"Tags" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-03-25/"` + Tags *Tags `locationName:"Tags" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` } // String returns the string representation @@ -9949,7 +14011,7 @@ type UntagResourceInput struct { // A complex type that contains zero or more Tag key elements. // // TagKeys is a required field - TagKeys *TagKeys `locationName:"TagKeys" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-03-25/"` + TagKeys *TagKeys `locationName:"TagKeys" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` } // String returns the string representation @@ -10011,7 +14073,7 @@ type UpdateCloudFrontOriginAccessIdentityInput struct { // The identity's configuration information. // // CloudFrontOriginAccessIdentityConfig is a required field - CloudFrontOriginAccessIdentityConfig *OriginAccessIdentityConfig `locationName:"CloudFrontOriginAccessIdentityConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-03-25/"` + CloudFrontOriginAccessIdentityConfig *OriginAccessIdentityConfig `locationName:"CloudFrontOriginAccessIdentityConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` // The identity's id. // @@ -10112,7 +14174,7 @@ type UpdateDistributionInput struct { // The distribution's configuration information. // // DistributionConfig is a required field - DistributionConfig *DistributionConfig `locationName:"DistributionConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-03-25/"` + DistributionConfig *DistributionConfig `locationName:"DistributionConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` // The distribution's id. // @@ -10206,6 +14268,304 @@ func (s *UpdateDistributionOutput) SetETag(v string) *UpdateDistributionOutput { return s } +type UpdateFieldLevelEncryptionConfigInput struct { + _ struct{} `type:"structure" payload:"FieldLevelEncryptionConfig"` + + // Request to update a field-level encryption configuration. + // + // FieldLevelEncryptionConfig is a required field + FieldLevelEncryptionConfig *FieldLevelEncryptionConfig `locationName:"FieldLevelEncryptionConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` + + // The ID of the configuration you want to update. + // + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + + // The value of the ETag header that you received when retrieving the configuration + // identity to update. For example: E2QWRUHAPOMQZL. + IfMatch *string `location:"header" locationName:"If-Match" type:"string"` +} + +// String returns the string representation +func (s UpdateFieldLevelEncryptionConfigInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateFieldLevelEncryptionConfigInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *UpdateFieldLevelEncryptionConfigInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateFieldLevelEncryptionConfigInput"} + if s.FieldLevelEncryptionConfig == nil { + invalidParams.Add(request.NewErrParamRequired("FieldLevelEncryptionConfig")) + } + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } + if s.FieldLevelEncryptionConfig != nil { + if err := s.FieldLevelEncryptionConfig.Validate(); err != nil { + invalidParams.AddNested("FieldLevelEncryptionConfig", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFieldLevelEncryptionConfig sets the FieldLevelEncryptionConfig field's value. +func (s *UpdateFieldLevelEncryptionConfigInput) SetFieldLevelEncryptionConfig(v *FieldLevelEncryptionConfig) *UpdateFieldLevelEncryptionConfigInput { + s.FieldLevelEncryptionConfig = v + return s +} + +// SetId sets the Id field's value. +func (s *UpdateFieldLevelEncryptionConfigInput) SetId(v string) *UpdateFieldLevelEncryptionConfigInput { + s.Id = &v + return s +} + +// SetIfMatch sets the IfMatch field's value. +func (s *UpdateFieldLevelEncryptionConfigInput) SetIfMatch(v string) *UpdateFieldLevelEncryptionConfigInput { + s.IfMatch = &v + return s +} + +type UpdateFieldLevelEncryptionConfigOutput struct { + _ struct{} `type:"structure" payload:"FieldLevelEncryption"` + + // The value of the ETag header that you received when updating the configuration. + // For example: E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // Return the results of updating the configuration. + FieldLevelEncryption *FieldLevelEncryption `type:"structure"` +} + +// String returns the string representation +func (s UpdateFieldLevelEncryptionConfigOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateFieldLevelEncryptionConfigOutput) GoString() string { + return s.String() +} + +// SetETag sets the ETag field's value. +func (s *UpdateFieldLevelEncryptionConfigOutput) SetETag(v string) *UpdateFieldLevelEncryptionConfigOutput { + s.ETag = &v + return s +} + +// SetFieldLevelEncryption sets the FieldLevelEncryption field's value. +func (s *UpdateFieldLevelEncryptionConfigOutput) SetFieldLevelEncryption(v *FieldLevelEncryption) *UpdateFieldLevelEncryptionConfigOutput { + s.FieldLevelEncryption = v + return s +} + +type UpdateFieldLevelEncryptionProfileInput struct { + _ struct{} `type:"structure" payload:"FieldLevelEncryptionProfileConfig"` + + // Request to update a field-level encryption profile. + // + // FieldLevelEncryptionProfileConfig is a required field + FieldLevelEncryptionProfileConfig *FieldLevelEncryptionProfileConfig `locationName:"FieldLevelEncryptionProfileConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` + + // The ID of the field-level encryption profile request. + // + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + + // The value of the ETag header that you received when retrieving the profile + // identity to update. For example: E2QWRUHAPOMQZL. + IfMatch *string `location:"header" locationName:"If-Match" type:"string"` +} + +// String returns the string representation +func (s UpdateFieldLevelEncryptionProfileInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateFieldLevelEncryptionProfileInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *UpdateFieldLevelEncryptionProfileInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateFieldLevelEncryptionProfileInput"} + if s.FieldLevelEncryptionProfileConfig == nil { + invalidParams.Add(request.NewErrParamRequired("FieldLevelEncryptionProfileConfig")) + } + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } + if s.FieldLevelEncryptionProfileConfig != nil { + if err := s.FieldLevelEncryptionProfileConfig.Validate(); err != nil { + invalidParams.AddNested("FieldLevelEncryptionProfileConfig", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFieldLevelEncryptionProfileConfig sets the FieldLevelEncryptionProfileConfig field's value. +func (s *UpdateFieldLevelEncryptionProfileInput) SetFieldLevelEncryptionProfileConfig(v *FieldLevelEncryptionProfileConfig) *UpdateFieldLevelEncryptionProfileInput { + s.FieldLevelEncryptionProfileConfig = v + return s +} + +// SetId sets the Id field's value. +func (s *UpdateFieldLevelEncryptionProfileInput) SetId(v string) *UpdateFieldLevelEncryptionProfileInput { + s.Id = &v + return s +} + +// SetIfMatch sets the IfMatch field's value. +func (s *UpdateFieldLevelEncryptionProfileInput) SetIfMatch(v string) *UpdateFieldLevelEncryptionProfileInput { + s.IfMatch = &v + return s +} + +type UpdateFieldLevelEncryptionProfileOutput struct { + _ struct{} `type:"structure" payload:"FieldLevelEncryptionProfile"` + + // The result of the field-level encryption profile request. + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // Return the results of updating the profile. + FieldLevelEncryptionProfile *FieldLevelEncryptionProfile `type:"structure"` +} + +// String returns the string representation +func (s UpdateFieldLevelEncryptionProfileOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateFieldLevelEncryptionProfileOutput) GoString() string { + return s.String() +} + +// SetETag sets the ETag field's value. +func (s *UpdateFieldLevelEncryptionProfileOutput) SetETag(v string) *UpdateFieldLevelEncryptionProfileOutput { + s.ETag = &v + return s +} + +// SetFieldLevelEncryptionProfile sets the FieldLevelEncryptionProfile field's value. +func (s *UpdateFieldLevelEncryptionProfileOutput) SetFieldLevelEncryptionProfile(v *FieldLevelEncryptionProfile) *UpdateFieldLevelEncryptionProfileOutput { + s.FieldLevelEncryptionProfile = v + return s +} + +type UpdatePublicKeyInput struct { + _ struct{} `type:"structure" payload:"PublicKeyConfig"` + + // ID of the public key to be updated. + // + // Id is a required field + Id *string `location:"uri" locationName:"Id" type:"string" required:"true"` + + // The value of the ETag header that you received when retrieving the public + // key to update. For example: E2QWRUHAPOMQZL. + IfMatch *string `location:"header" locationName:"If-Match" type:"string"` + + // Request to update public key information. + // + // PublicKeyConfig is a required field + PublicKeyConfig *PublicKeyConfig `locationName:"PublicKeyConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` +} + +// String returns the string representation +func (s UpdatePublicKeyInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdatePublicKeyInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *UpdatePublicKeyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdatePublicKeyInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } + if s.PublicKeyConfig == nil { + invalidParams.Add(request.NewErrParamRequired("PublicKeyConfig")) + } + if s.PublicKeyConfig != nil { + if err := s.PublicKeyConfig.Validate(); err != nil { + invalidParams.AddNested("PublicKeyConfig", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetId sets the Id field's value. +func (s *UpdatePublicKeyInput) SetId(v string) *UpdatePublicKeyInput { + s.Id = &v + return s +} + +// SetIfMatch sets the IfMatch field's value. +func (s *UpdatePublicKeyInput) SetIfMatch(v string) *UpdatePublicKeyInput { + s.IfMatch = &v + return s +} + +// SetPublicKeyConfig sets the PublicKeyConfig field's value. +func (s *UpdatePublicKeyInput) SetPublicKeyConfig(v *PublicKeyConfig) *UpdatePublicKeyInput { + s.PublicKeyConfig = v + return s +} + +type UpdatePublicKeyOutput struct { + _ struct{} `type:"structure" payload:"PublicKey"` + + // The current version of the update public key result. For example: E2QWRUHAPOMQZL. + ETag *string `location:"header" locationName:"ETag" type:"string"` + + // Return the results of updating the public key. + PublicKey *PublicKey `type:"structure"` +} + +// String returns the string representation +func (s UpdatePublicKeyOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdatePublicKeyOutput) GoString() string { + return s.String() +} + +// SetETag sets the ETag field's value. +func (s *UpdatePublicKeyOutput) SetETag(v string) *UpdatePublicKeyOutput { + s.ETag = &v + return s +} + +// SetPublicKey sets the PublicKey field's value. +func (s *UpdatePublicKeyOutput) SetPublicKey(v *PublicKey) *UpdatePublicKeyOutput { + s.PublicKey = v + return s +} + // The request to update a streaming distribution. type UpdateStreamingDistributionInput struct { _ struct{} `type:"structure" payload:"StreamingDistributionConfig"` @@ -10222,7 +14582,7 @@ type UpdateStreamingDistributionInput struct { // The streaming distribution's configuration information. // // StreamingDistributionConfig is a required field - StreamingDistributionConfig *StreamingDistributionConfig `locationName:"StreamingDistributionConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-03-25/"` + StreamingDistributionConfig *StreamingDistributionConfig `locationName:"StreamingDistributionConfig" type:"structure" required:"true" xmlURI:"http://cloudfront.amazonaws.com/doc/2017-10-30/"` } // String returns the string representation @@ -10565,6 +14925,11 @@ const ( EventTypeOriginResponse = "origin-response" ) +const ( + // FormatUrlencoded is a Format enum value + FormatUrlencoded = "URLEncoded" +) + const ( // GeoRestrictionTypeBlacklist is a GeoRestrictionType enum value GeoRestrictionTypeBlacklist = "blacklist" diff --git a/vendor/github.com/aws/aws-sdk-go/service/cloudfront/doc.go b/vendor/github.com/aws/aws-sdk-go/service/cloudfront/doc.go index 5fb8d3622a2b..e5125244fbcd 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/cloudfront/doc.go +++ b/vendor/github.com/aws/aws-sdk-go/service/cloudfront/doc.go @@ -8,7 +8,7 @@ // errors. For detailed information about CloudFront features, see the Amazon // CloudFront Developer Guide. // -// See https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-03-25 for more information on this service. +// See https://docs.aws.amazon.com/goto/WebAPI/cloudfront-2017-10-30 for more information on this service. // // See cloudfront package documentation for more information. // https://docs.aws.amazon.com/sdk-for-go/api/service/cloudfront/ diff --git a/vendor/github.com/aws/aws-sdk-go/service/cloudfront/errors.go b/vendor/github.com/aws/aws-sdk-go/service/cloudfront/errors.go index ed66a11e51ba..1f5ce88f1aa9 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/cloudfront/errors.go +++ b/vendor/github.com/aws/aws-sdk-go/service/cloudfront/errors.go @@ -18,6 +18,12 @@ const ( // "CNAMEAlreadyExists". ErrCodeCNAMEAlreadyExists = "CNAMEAlreadyExists" + // ErrCodeCannotChangeImmutablePublicKeyFields for service response error code + // "CannotChangeImmutablePublicKeyFields". + // + // You can't change the value of a public key. + ErrCodeCannotChangeImmutablePublicKeyFields = "CannotChangeImmutablePublicKeyFields" + // ErrCodeDistributionAlreadyExists for service response error code // "DistributionAlreadyExists". // @@ -29,6 +35,43 @@ const ( // "DistributionNotDisabled". ErrCodeDistributionNotDisabled = "DistributionNotDisabled" + // ErrCodeFieldLevelEncryptionConfigAlreadyExists for service response error code + // "FieldLevelEncryptionConfigAlreadyExists". + // + // The specified configuration for field-level encryption already exists. + ErrCodeFieldLevelEncryptionConfigAlreadyExists = "FieldLevelEncryptionConfigAlreadyExists" + + // ErrCodeFieldLevelEncryptionConfigInUse for service response error code + // "FieldLevelEncryptionConfigInUse". + // + // The specified configuration for field-level encryption is in use. + ErrCodeFieldLevelEncryptionConfigInUse = "FieldLevelEncryptionConfigInUse" + + // ErrCodeFieldLevelEncryptionProfileAlreadyExists for service response error code + // "FieldLevelEncryptionProfileAlreadyExists". + // + // The specified profile for field-level encryption already exists. + ErrCodeFieldLevelEncryptionProfileAlreadyExists = "FieldLevelEncryptionProfileAlreadyExists" + + // ErrCodeFieldLevelEncryptionProfileInUse for service response error code + // "FieldLevelEncryptionProfileInUse". + // + // The specified profile for field-level encryption is in use. + ErrCodeFieldLevelEncryptionProfileInUse = "FieldLevelEncryptionProfileInUse" + + // ErrCodeFieldLevelEncryptionProfileSizeExceeded for service response error code + // "FieldLevelEncryptionProfileSizeExceeded". + // + // The maximum size of a profile for field-level encryption was exceeded. + ErrCodeFieldLevelEncryptionProfileSizeExceeded = "FieldLevelEncryptionProfileSizeExceeded" + + // ErrCodeIllegalFieldLevelEncryptionConfigAssociationWithCacheBehavior for service response error code + // "IllegalFieldLevelEncryptionConfigAssociationWithCacheBehavior". + // + // The specified configuration for field-level encryption can't be associated + // with the specified cache behavior. + ErrCodeIllegalFieldLevelEncryptionConfigAssociationWithCacheBehavior = "IllegalFieldLevelEncryptionConfigAssociationWithCacheBehavior" + // ErrCodeIllegalUpdate for service response error code // "IllegalUpdate". // @@ -180,6 +223,18 @@ const ( // The specified distribution does not exist. ErrCodeNoSuchDistribution = "NoSuchDistribution" + // ErrCodeNoSuchFieldLevelEncryptionConfig for service response error code + // "NoSuchFieldLevelEncryptionConfig". + // + // The specified configuration for field-level encryption doesn't exist. + ErrCodeNoSuchFieldLevelEncryptionConfig = "NoSuchFieldLevelEncryptionConfig" + + // ErrCodeNoSuchFieldLevelEncryptionProfile for service response error code + // "NoSuchFieldLevelEncryptionProfile". + // + // The specified profile for field-level encryption doesn't exist. + ErrCodeNoSuchFieldLevelEncryptionProfile = "NoSuchFieldLevelEncryptionProfile" + // ErrCodeNoSuchInvalidation for service response error code // "NoSuchInvalidation". // @@ -192,6 +247,12 @@ const ( // No origin exists with the specified Origin Id. ErrCodeNoSuchOrigin = "NoSuchOrigin" + // ErrCodeNoSuchPublicKey for service response error code + // "NoSuchPublicKey". + // + // The specified public key doesn't exist. + ErrCodeNoSuchPublicKey = "NoSuchPublicKey" + // ErrCodeNoSuchResource for service response error code // "NoSuchResource". ErrCodeNoSuchResource = "NoSuchResource" @@ -222,6 +283,24 @@ const ( // to false. ErrCodePreconditionFailed = "PreconditionFailed" + // ErrCodePublicKeyAlreadyExists for service response error code + // "PublicKeyAlreadyExists". + // + // The specified public key already exists. + ErrCodePublicKeyAlreadyExists = "PublicKeyAlreadyExists" + + // ErrCodePublicKeyInUse for service response error code + // "PublicKeyInUse". + // + // The specified public key is in use. + ErrCodePublicKeyInUse = "PublicKeyInUse" + + // ErrCodeQueryArgProfileEmpty for service response error code + // "QueryArgProfileEmpty". + // + // No profile specified for the field-level encryption query argument. + ErrCodeQueryArgProfileEmpty = "QueryArgProfileEmpty" + // ErrCodeResourceInUse for service response error code // "ResourceInUse". ErrCodeResourceInUse = "ResourceInUse" @@ -273,6 +352,13 @@ const ( // allowed. ErrCodeTooManyDistributions = "TooManyDistributions" + // ErrCodeTooManyDistributionsAssociatedToFieldLevelEncryptionConfig for service response error code + // "TooManyDistributionsAssociatedToFieldLevelEncryptionConfig". + // + // The maximum number of distributions have been associated with the specified + // configuration for field-level encryption. + ErrCodeTooManyDistributionsAssociatedToFieldLevelEncryptionConfig = "TooManyDistributionsAssociatedToFieldLevelEncryptionConfig" + // ErrCodeTooManyDistributionsWithLambdaAssociations for service response error code // "TooManyDistributionsWithLambdaAssociations". // @@ -280,6 +366,47 @@ const ( // Lambda function associations per owner to be exceeded. ErrCodeTooManyDistributionsWithLambdaAssociations = "TooManyDistributionsWithLambdaAssociations" + // ErrCodeTooManyFieldLevelEncryptionConfigs for service response error code + // "TooManyFieldLevelEncryptionConfigs". + // + // The maximum number of configurations for field-level encryption have been + // created. + ErrCodeTooManyFieldLevelEncryptionConfigs = "TooManyFieldLevelEncryptionConfigs" + + // ErrCodeTooManyFieldLevelEncryptionContentTypeProfiles for service response error code + // "TooManyFieldLevelEncryptionContentTypeProfiles". + // + // The maximum number of content type profiles for field-level encryption have + // been created. + ErrCodeTooManyFieldLevelEncryptionContentTypeProfiles = "TooManyFieldLevelEncryptionContentTypeProfiles" + + // ErrCodeTooManyFieldLevelEncryptionEncryptionEntities for service response error code + // "TooManyFieldLevelEncryptionEncryptionEntities". + // + // The maximum number of encryption entities for field-level encryption have + // been created. + ErrCodeTooManyFieldLevelEncryptionEncryptionEntities = "TooManyFieldLevelEncryptionEncryptionEntities" + + // ErrCodeTooManyFieldLevelEncryptionFieldPatterns for service response error code + // "TooManyFieldLevelEncryptionFieldPatterns". + // + // The maximum number of field patterns for field-level encryption have been + // created. + ErrCodeTooManyFieldLevelEncryptionFieldPatterns = "TooManyFieldLevelEncryptionFieldPatterns" + + // ErrCodeTooManyFieldLevelEncryptionProfiles for service response error code + // "TooManyFieldLevelEncryptionProfiles". + // + // The maximum number of profiles for field-level encryption have been created. + ErrCodeTooManyFieldLevelEncryptionProfiles = "TooManyFieldLevelEncryptionProfiles" + + // ErrCodeTooManyFieldLevelEncryptionQueryArgProfiles for service response error code + // "TooManyFieldLevelEncryptionQueryArgProfiles". + // + // The maximum number of query arg profiles for field-level encryption have + // been created. + ErrCodeTooManyFieldLevelEncryptionQueryArgProfiles = "TooManyFieldLevelEncryptionQueryArgProfiles" + // ErrCodeTooManyHeadersInForwardedValues for service response error code // "TooManyHeadersInForwardedValues". ErrCodeTooManyHeadersInForwardedValues = "TooManyHeadersInForwardedValues" @@ -308,6 +435,13 @@ const ( // You cannot create more origins for the distribution. ErrCodeTooManyOrigins = "TooManyOrigins" + // ErrCodeTooManyPublicKeys for service response error code + // "TooManyPublicKeys". + // + // The maximum number of public keys for field-level encryption have been created. + // To create a new public key, delete one of the existing keys. + ErrCodeTooManyPublicKeys = "TooManyPublicKeys" + // ErrCodeTooManyQueryStringParameters for service response error code // "TooManyQueryStringParameters". ErrCodeTooManyQueryStringParameters = "TooManyQueryStringParameters" diff --git a/vendor/github.com/aws/aws-sdk-go/service/cloudfront/service.go b/vendor/github.com/aws/aws-sdk-go/service/cloudfront/service.go index 75dcf86e8dcc..a07f021130f1 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/cloudfront/service.go +++ b/vendor/github.com/aws/aws-sdk-go/service/cloudfront/service.go @@ -58,7 +58,7 @@ func newClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegio SigningName: signingName, SigningRegion: signingRegion, Endpoint: endpoint, - APIVersion: "2017-03-25", + APIVersion: "2017-10-30", }, handlers, ), diff --git a/vendor/github.com/aws/aws-sdk-go/service/cloudtrail/api.go b/vendor/github.com/aws/aws-sdk-go/service/cloudtrail/api.go index 646949fa2dfc..c6ad246ec960 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/cloudtrail/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/cloudtrail/api.go @@ -15,7 +15,7 @@ const opAddTags = "AddTags" // AddTagsRequest generates a "aws/request.Request" representing the // client's request for the AddTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -139,7 +139,7 @@ const opCreateTrail = "CreateTrail" // CreateTrailRequest generates a "aws/request.Request" representing the // client's request for the CreateTrail operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -297,7 +297,7 @@ const opDeleteTrail = "DeleteTrail" // DeleteTrailRequest generates a "aws/request.Request" representing the // client's request for the DeleteTrail operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -398,7 +398,7 @@ const opDescribeTrails = "DescribeTrails" // DescribeTrailsRequest generates a "aws/request.Request" representing the // client's request for the DescribeTrails operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -481,7 +481,7 @@ const opGetEventSelectors = "GetEventSelectors" // GetEventSelectorsRequest generates a "aws/request.Request" representing the // client's request for the GetEventSelectors operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -594,7 +594,7 @@ const opGetTrailStatus = "GetTrailStatus" // GetTrailStatusRequest generates a "aws/request.Request" representing the // client's request for the GetTrailStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -693,7 +693,7 @@ const opListPublicKeys = "ListPublicKeys" // ListPublicKeysRequest generates a "aws/request.Request" representing the // client's request for the ListPublicKeys operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -789,7 +789,7 @@ const opListTags = "ListTags" // ListTagsRequest generates a "aws/request.Request" representing the // client's request for the ListTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -903,7 +903,7 @@ const opLookupEvents = "LookupEvents" // LookupEventsRequest generates a "aws/request.Request" representing the // client's request for the LookupEvents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1074,7 +1074,7 @@ const opPutEventSelectors = "PutEventSelectors" // PutEventSelectorsRequest generates a "aws/request.Request" representing the // client's request for the PutEventSelectors operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1218,7 +1218,7 @@ const opRemoveTags = "RemoveTags" // RemoveTagsRequest generates a "aws/request.Request" representing the // client's request for the RemoveTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1333,7 +1333,7 @@ const opStartLogging = "StartLogging" // StartLoggingRequest generates a "aws/request.Request" representing the // client's request for the StartLogging operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1436,7 +1436,7 @@ const opStopLogging = "StopLogging" // StopLoggingRequest generates a "aws/request.Request" representing the // client's request for the StopLogging operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1541,7 +1541,7 @@ const opUpdateTrail = "UpdateTrail" // UpdateTrailRequest generates a "aws/request.Request" representing the // client's request for the UpdateTrail operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/cloudwatch/api.go b/vendor/github.com/aws/aws-sdk-go/service/cloudwatch/api.go index 2675be8486dd..38519a2ac377 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/cloudwatch/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/cloudwatch/api.go @@ -17,7 +17,7 @@ const opDeleteAlarms = "DeleteAlarms" // DeleteAlarmsRequest generates a "aws/request.Request" representing the // client's request for the DeleteAlarms operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -98,7 +98,7 @@ const opDeleteDashboards = "DeleteDashboards" // DeleteDashboardsRequest generates a "aws/request.Request" representing the // client's request for the DeleteDashboards operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -184,7 +184,7 @@ const opDescribeAlarmHistory = "DescribeAlarmHistory" // DescribeAlarmHistoryRequest generates a "aws/request.Request" representing the // client's request for the DescribeAlarmHistory operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -323,7 +323,7 @@ const opDescribeAlarms = "DescribeAlarms" // DescribeAlarmsRequest generates a "aws/request.Request" representing the // client's request for the DescribeAlarms operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -460,7 +460,7 @@ const opDescribeAlarmsForMetric = "DescribeAlarmsForMetric" // DescribeAlarmsForMetricRequest generates a "aws/request.Request" representing the // client's request for the DescribeAlarmsForMetric operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -535,7 +535,7 @@ const opDisableAlarmActions = "DisableAlarmActions" // DisableAlarmActionsRequest generates a "aws/request.Request" representing the // client's request for the DisableAlarmActions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -612,7 +612,7 @@ const opEnableAlarmActions = "EnableAlarmActions" // EnableAlarmActionsRequest generates a "aws/request.Request" representing the // client's request for the EnableAlarmActions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -688,7 +688,7 @@ const opGetDashboard = "GetDashboard" // GetDashboardRequest generates a "aws/request.Request" representing the // client's request for the GetDashboard operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -773,11 +773,101 @@ func (c *CloudWatch) GetDashboardWithContext(ctx aws.Context, input *GetDashboar return out, req.Send() } +const opGetMetricData = "GetMetricData" + +// GetMetricDataRequest generates a "aws/request.Request" representing the +// client's request for the GetMetricData operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetMetricData for more information on using the GetMetricData +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetMetricDataRequest method. +// req, resp := client.GetMetricDataRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/GetMetricData +func (c *CloudWatch) GetMetricDataRequest(input *GetMetricDataInput) (req *request.Request, output *GetMetricDataOutput) { + op := &request.Operation{ + Name: opGetMetricData, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &GetMetricDataInput{} + } + + output = &GetMetricDataOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetMetricData API operation for Amazon CloudWatch. +// +// You can use the GetMetricData API to retrieve as many as 100 different metrics +// in a single request, with a total of as many as 100,800 datapoints. You can +// also optionally perform math expressions on the values of the returned statistics, +// to create new time series that represent new insights into your data. For +// example, using Lambda metrics, you could divide the Errors metric by the +// Invocations metric to get an error rate time series. For more information +// about metric math expressions, see Metric Math Syntax and Functions (http://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/using-metric-math.html#metric-math-syntax) +// in the Amazon CloudWatch User Guide. +// +// Calls to the GetMetricData API have a different pricing structure than calls +// to GetMetricStatistics. For more information about pricing, see Amazon CloudWatch +// Pricing (https://aws.amazon.com/cloudwatch/pricing/). +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon CloudWatch's +// API operation GetMetricData for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInvalidNextToken "InvalidNextToken" +// The next token specified is invalid. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/GetMetricData +func (c *CloudWatch) GetMetricData(input *GetMetricDataInput) (*GetMetricDataOutput, error) { + req, out := c.GetMetricDataRequest(input) + return out, req.Send() +} + +// GetMetricDataWithContext is the same as GetMetricData with the addition of +// the ability to pass a context and additional request options. +// +// See GetMetricData for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CloudWatch) GetMetricDataWithContext(ctx aws.Context, input *GetMetricDataInput, opts ...request.Option) (*GetMetricDataOutput, error) { + req, out := c.GetMetricDataRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opGetMetricStatistics = "GetMetricStatistics" // GetMetricStatisticsRequest generates a "aws/request.Request" representing the // client's request for the GetMetricStatistics operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -915,7 +1005,7 @@ const opListDashboards = "ListDashboards" // ListDashboardsRequest generates a "aws/request.Request" representing the // client's request for the ListDashboards operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -999,7 +1089,7 @@ const opListMetrics = "ListMetrics" // ListMetricsRequest generates a "aws/request.Request" representing the // client's request for the ListMetrics operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1145,7 +1235,7 @@ const opPutDashboard = "PutDashboard" // PutDashboardRequest generates a "aws/request.Request" representing the // client's request for the PutDashboard operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1245,7 +1335,7 @@ const opPutMetricAlarm = "PutMetricAlarm" // PutMetricAlarmRequest generates a "aws/request.Request" representing the // client's request for the PutMetricAlarm operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1367,7 +1457,7 @@ const opPutMetricData = "PutMetricData" // PutMetricDataRequest generates a "aws/request.Request" representing the // client's request for the PutMetricData operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1485,7 +1575,7 @@ const opSetAlarmState = "SetAlarmState" // SetAlarmStateRequest generates a "aws/request.Request" representing the // client's request for the SetAlarmState operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2588,6 +2678,150 @@ func (s *GetDashboardOutput) SetDashboardName(v string) *GetDashboardOutput { return s } +type GetMetricDataInput struct { + _ struct{} `type:"structure"` + + // The time stamp indicating the latest data to be returned. + // + // EndTime is a required field + EndTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"` + + // The maximum number of data points the request should return before paginating. + // If you omit this, the default of 100,800 is used. + MaxDatapoints *int64 `type:"integer"` + + // The metric queries to be returned. A single GetMetricData call can include + // as many as 100 MetricDataQuery structures. Each of these structures can specify + // either a metric to retrieve, or a math expression to perform on retrieved + // data. + // + // MetricDataQueries is a required field + MetricDataQueries []*MetricDataQuery `type:"list" required:"true"` + + // Include this value, if it was returned by the previous call, to get the next + // set of data points. + NextToken *string `type:"string"` + + // The order in which data points should be returned. TimestampDescending returns + // the newest data first and paginates when the MaxDatapoints limit is reached. + // TimestampAscending returns the oldest data first and paginates when the MaxDatapoints + // limit is reached. + ScanBy *string `type:"string" enum:"ScanBy"` + + // The time stamp indicating the earliest data to be returned. + // + // StartTime is a required field + StartTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"` +} + +// String returns the string representation +func (s GetMetricDataInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetMetricDataInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetMetricDataInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetMetricDataInput"} + if s.EndTime == nil { + invalidParams.Add(request.NewErrParamRequired("EndTime")) + } + if s.MetricDataQueries == nil { + invalidParams.Add(request.NewErrParamRequired("MetricDataQueries")) + } + if s.StartTime == nil { + invalidParams.Add(request.NewErrParamRequired("StartTime")) + } + if s.MetricDataQueries != nil { + for i, v := range s.MetricDataQueries { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "MetricDataQueries", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetEndTime sets the EndTime field's value. +func (s *GetMetricDataInput) SetEndTime(v time.Time) *GetMetricDataInput { + s.EndTime = &v + return s +} + +// SetMaxDatapoints sets the MaxDatapoints field's value. +func (s *GetMetricDataInput) SetMaxDatapoints(v int64) *GetMetricDataInput { + s.MaxDatapoints = &v + return s +} + +// SetMetricDataQueries sets the MetricDataQueries field's value. +func (s *GetMetricDataInput) SetMetricDataQueries(v []*MetricDataQuery) *GetMetricDataInput { + s.MetricDataQueries = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetMetricDataInput) SetNextToken(v string) *GetMetricDataInput { + s.NextToken = &v + return s +} + +// SetScanBy sets the ScanBy field's value. +func (s *GetMetricDataInput) SetScanBy(v string) *GetMetricDataInput { + s.ScanBy = &v + return s +} + +// SetStartTime sets the StartTime field's value. +func (s *GetMetricDataInput) SetStartTime(v time.Time) *GetMetricDataInput { + s.StartTime = &v + return s +} + +type GetMetricDataOutput struct { + _ struct{} `type:"structure"` + + // The metrics that are returned, including the metric name, namespace, and + // dimensions. + MetricDataResults []*MetricDataResult `type:"list"` + + // A token that marks the next batch of returned results. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s GetMetricDataOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetMetricDataOutput) GoString() string { + return s.String() +} + +// SetMetricDataResults sets the MetricDataResults field's value. +func (s *GetMetricDataOutput) SetMetricDataResults(v []*MetricDataResult) *GetMetricDataOutput { + s.MetricDataResults = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetMetricDataOutput) SetNextToken(v string) *GetMetricDataOutput { + s.NextToken = &v + return s +} + type GetMetricStatisticsInput struct { _ struct{} `type:"structure"` @@ -2682,8 +2916,8 @@ type GetMetricStatisticsInput struct { Statistics []*string `min:"1" type:"list"` // The unit for a given metric. Metrics may be reported in multiple units. Not - // supplying a unit results in all units being returned. If the metric only - // ever reports one unit, specifying a unit has no effect. + // supplying a unit results in all units being returned. If you specify only + // a unit that the metric does not report, the results of the call are null. Unit *string `type:"string" enum:"StandardUnit"` } @@ -3009,6 +3243,39 @@ func (s *ListMetricsOutput) SetNextToken(v string) *ListMetricsOutput { return s } +// A message returned by the GetMetricDataAPI, including a code and a description. +type MessageData struct { + _ struct{} `type:"structure"` + + // The error code or status code associated with the message. + Code *string `type:"string"` + + // The message text. + Value *string `type:"string"` +} + +// String returns the string representation +func (s MessageData) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s MessageData) GoString() string { + return s.String() +} + +// SetCode sets the Code field's value. +func (s *MessageData) SetCode(v string) *MessageData { + s.Code = &v + return s +} + +// SetValue sets the Value field's value. +func (s *MessageData) SetValue(v string) *MessageData { + s.Value = &v + return s +} + // Represents a specific metric. type Metric struct { _ struct{} `type:"structure"` @@ -3033,6 +3300,32 @@ func (s Metric) GoString() string { return s.String() } +// Validate inspects the fields of the type to determine if they are valid. +func (s *Metric) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "Metric"} + if s.MetricName != nil && len(*s.MetricName) < 1 { + invalidParams.Add(request.NewErrParamMinLen("MetricName", 1)) + } + if s.Namespace != nil && len(*s.Namespace) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) + } + if s.Dimensions != nil { + for i, v := range s.Dimensions { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Dimensions", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + // SetDimensions sets the Dimensions field's value. func (s *Metric) SetDimensions(v []*Dimension) *Metric { s.Dimensions = v @@ -3303,6 +3596,197 @@ func (s *MetricAlarm) SetUnit(v string) *MetricAlarm { return s } +// This structure indicates the metric data to return, and whether this call +// is just retrieving a batch set of data for one metric, or is performing a +// math expression on metric data. A single GetMetricData call can include up +// to 100 MetricDataQuery structures. +type MetricDataQuery struct { + _ struct{} `type:"structure"` + + // The math expression to be performed on the returned data, if this structure + // is performing a math expression. For more information about metric math expressions, + // see Metric Math Syntax and Functions (http://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/using-metric-math.html#metric-math-syntax) + // in the Amazon CloudWatch User Guide. + // + // Within one MetricDataQuery structure, you must specify either Expression + // or MetricStat but not both. + Expression *string `min:"1" type:"string"` + + // A short name used to tie this structure to the results in the response. This + // name must be unique within a single call to GetMetricData. If you are performing + // math expressions on this set of data, this name represents that data and + // can serve as a variable in the mathematical expression. The valid characters + // are letters, numbers, and underscore. The first character must be a lowercase + // letter. + // + // Id is a required field + Id *string `min:"1" type:"string" required:"true"` + + // A human-readable label for this metric or expression. This is especially + // useful if this is an expression, so that you know what the value represents. + // If the metric or expression is shown in a CloudWatch dashboard widget, the + // label is shown. If Label is omitted, CloudWatch generates a default. + Label *string `type:"string"` + + // The metric to be returned, along with statistics, period, and units. Use + // this parameter only if this structure is performing a data retrieval and + // not performing a math expression on the returned data. + // + // Within one MetricDataQuery structure, you must specify either Expression + // or MetricStat but not both. + MetricStat *MetricStat `type:"structure"` + + // Indicates whether to return the time stamps and raw data values of this metric. + // If you are performing this call just to do math expressions and do not also + // need the raw data returned, you can specify False. If you omit this, the + // default of True is used. + ReturnData *bool `type:"boolean"` +} + +// String returns the string representation +func (s MetricDataQuery) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s MetricDataQuery) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *MetricDataQuery) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "MetricDataQuery"} + if s.Expression != nil && len(*s.Expression) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Expression", 1)) + } + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } + if s.Id != nil && len(*s.Id) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Id", 1)) + } + if s.MetricStat != nil { + if err := s.MetricStat.Validate(); err != nil { + invalidParams.AddNested("MetricStat", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetExpression sets the Expression field's value. +func (s *MetricDataQuery) SetExpression(v string) *MetricDataQuery { + s.Expression = &v + return s +} + +// SetId sets the Id field's value. +func (s *MetricDataQuery) SetId(v string) *MetricDataQuery { + s.Id = &v + return s +} + +// SetLabel sets the Label field's value. +func (s *MetricDataQuery) SetLabel(v string) *MetricDataQuery { + s.Label = &v + return s +} + +// SetMetricStat sets the MetricStat field's value. +func (s *MetricDataQuery) SetMetricStat(v *MetricStat) *MetricDataQuery { + s.MetricStat = v + return s +} + +// SetReturnData sets the ReturnData field's value. +func (s *MetricDataQuery) SetReturnData(v bool) *MetricDataQuery { + s.ReturnData = &v + return s +} + +// A GetMetricData call returns an array of MetricDataResult structures. Each +// of these structures includes the data points for that metric, along with +// the time stamps of those data points and other identifying information. +type MetricDataResult struct { + _ struct{} `type:"structure"` + + // The short name you specified to represent this metric. + Id *string `min:"1" type:"string"` + + // The human-readable label associated with the data. + Label *string `type:"string"` + + // A list of messages with additional information about the data returned. + Messages []*MessageData `type:"list"` + + // The status of the returned data. Complete indicates that all data points + // in the requested time range were returned. PartialData means that an incomplete + // set of data points were returned. You can use the NextToken value that was + // returned and repeat your request to get more data points. NextToken is not + // returned if you are performing a math expression. InternalError indicates + // that an error occurred. Retry your request using NextToken, if present. + StatusCode *string `type:"string" enum:"StatusCode"` + + // The time stamps for the data points, formatted in Unix timestamp format. + // The number of time stamps always matches the number of values and the value + // for Timestamps[x] is Values[x]. + Timestamps []*time.Time `type:"list"` + + // The data points for the metric corresponding to Timestamps. The number of + // values always matches the number of time stamps and the time stamp for Values[x] + // is Timestamps[x]. + Values []*float64 `type:"list"` +} + +// String returns the string representation +func (s MetricDataResult) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s MetricDataResult) GoString() string { + return s.String() +} + +// SetId sets the Id field's value. +func (s *MetricDataResult) SetId(v string) *MetricDataResult { + s.Id = &v + return s +} + +// SetLabel sets the Label field's value. +func (s *MetricDataResult) SetLabel(v string) *MetricDataResult { + s.Label = &v + return s +} + +// SetMessages sets the Messages field's value. +func (s *MetricDataResult) SetMessages(v []*MessageData) *MetricDataResult { + s.Messages = v + return s +} + +// SetStatusCode sets the StatusCode field's value. +func (s *MetricDataResult) SetStatusCode(v string) *MetricDataResult { + s.StatusCode = &v + return s +} + +// SetTimestamps sets the Timestamps field's value. +func (s *MetricDataResult) SetTimestamps(v []*time.Time) *MetricDataResult { + s.Timestamps = v + return s +} + +// SetValues sets the Values field's value. +func (s *MetricDataResult) SetValues(v []*float64) *MetricDataResult { + s.Values = v + return s +} + // Encapsulates the information sent to either create a metric or add new values // to be aggregated into an existing metric. type MetricDatum struct { @@ -3433,6 +3917,92 @@ func (s *MetricDatum) SetValue(v float64) *MetricDatum { return s } +// This structure defines the metric to be returned, along with the statistics, +// period, and units. +type MetricStat struct { + _ struct{} `type:"structure"` + + // The metric to return, including the metric name, namespace, and dimensions. + // + // Metric is a required field + Metric *Metric `type:"structure" required:"true"` + + // The period to use when retrieving the metric. + // + // Period is a required field + Period *int64 `min:"1" type:"integer" required:"true"` + + // The statistic to return. It can include any CloudWatch statistic or extended + // statistic. + // + // Stat is a required field + Stat *string `type:"string" required:"true"` + + // The unit to use for the returned data points. + Unit *string `type:"string" enum:"StandardUnit"` +} + +// String returns the string representation +func (s MetricStat) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s MetricStat) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *MetricStat) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "MetricStat"} + if s.Metric == nil { + invalidParams.Add(request.NewErrParamRequired("Metric")) + } + if s.Period == nil { + invalidParams.Add(request.NewErrParamRequired("Period")) + } + if s.Period != nil && *s.Period < 1 { + invalidParams.Add(request.NewErrParamMinValue("Period", 1)) + } + if s.Stat == nil { + invalidParams.Add(request.NewErrParamRequired("Stat")) + } + if s.Metric != nil { + if err := s.Metric.Validate(); err != nil { + invalidParams.AddNested("Metric", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMetric sets the Metric field's value. +func (s *MetricStat) SetMetric(v *Metric) *MetricStat { + s.Metric = v + return s +} + +// SetPeriod sets the Period field's value. +func (s *MetricStat) SetPeriod(v int64) *MetricStat { + s.Period = &v + return s +} + +// SetStat sets the Stat field's value. +func (s *MetricStat) SetStat(v string) *MetricStat { + s.Stat = &v + return s +} + +// SetUnit sets the Unit field's value. +func (s *MetricStat) SetUnit(v string) *MetricStat { + s.Unit = &v + return s +} + type PutDashboardInput struct { _ struct{} `type:"structure"` @@ -3556,7 +4126,10 @@ type PutMetricAlarmInput struct { // ComparisonOperator is a required field ComparisonOperator *string `type:"string" required:"true" enum:"ComparisonOperator"` - // The number of datapoints that must be breaching to trigger the alarm. + // The number of datapoints that must be breaching to trigger the alarm. This + // is used only if you are setting an "M out of N" alarm. In that case, this + // value is the M. For more information, see Evaluating an Alarm (http://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/AlarmThatSendsEmail.html#alarm-evaluation) + // in the Amazon CloudWatch User Guide. DatapointsToAlarm *int64 `min:"1" type:"integer"` // The dimensions for the metric associated with the alarm. @@ -3573,6 +4146,10 @@ type PutMetricAlarmInput struct { EvaluateLowSampleCountPercentile *string `min:"1" type:"string"` // The number of periods over which data is compared to the specified threshold. + // If you are setting an alarm which requires that a number of consecutive data + // points be breaching to trigger the alarm, this value specifies that number. + // If you are setting an "M out of N" alarm, this value is the N. + // // An alarm's total current evaluation period can be no longer than one day, // so this number multiplied by Period cannot be more than 86,400 seconds. // @@ -3623,7 +4200,7 @@ type PutMetricAlarmInput struct { // values are 10, 30, and any multiple of 60. // // Be sure to specify 10 or 30 only for metrics that are stored by a PutMetricData - // call with a StorageResolution of 1. If you specify a Period of 10 or 30 for + // call with a StorageResolution of 1. If you specify a period of 10 or 30 for // a metric that does not have sub-minute resolution, the alarm still attempts // to gather data at the period rate that you specify. In this case, it does // not receive data for the attempts that do not correspond to a one-minute @@ -4151,6 +4728,14 @@ const ( HistoryItemTypeAction = "Action" ) +const ( + // ScanByTimestampDescending is a ScanBy enum value + ScanByTimestampDescending = "TimestampDescending" + + // ScanByTimestampAscending is a ScanBy enum value + ScanByTimestampAscending = "TimestampAscending" +) + const ( // StandardUnitSeconds is a StandardUnit enum value StandardUnitSeconds = "Seconds" @@ -4261,3 +4846,14 @@ const ( // StatisticMaximum is a Statistic enum value StatisticMaximum = "Maximum" ) + +const ( + // StatusCodeComplete is a StatusCode enum value + StatusCodeComplete = "Complete" + + // StatusCodeInternalError is a StatusCode enum value + StatusCodeInternalError = "InternalError" + + // StatusCodePartialData is a StatusCode enum value + StatusCodePartialData = "PartialData" +) diff --git a/vendor/github.com/aws/aws-sdk-go/service/cloudwatchevents/api.go b/vendor/github.com/aws/aws-sdk-go/service/cloudwatchevents/api.go index 5fe3d8738740..3fe033736ffb 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/cloudwatchevents/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/cloudwatchevents/api.go @@ -17,7 +17,7 @@ const opDeleteRule = "DeleteRule" // DeleteRuleRequest generates a "aws/request.Request" representing the // client's request for the DeleteRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -107,7 +107,7 @@ const opDescribeEventBus = "DescribeEventBus" // DescribeEventBusRequest generates a "aws/request.Request" representing the // client's request for the DescribeEventBus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -191,7 +191,7 @@ const opDescribeRule = "DescribeRule" // DescribeRuleRequest generates a "aws/request.Request" representing the // client's request for the DescribeRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -273,7 +273,7 @@ const opDisableRule = "DisableRule" // DisableRuleRequest generates a "aws/request.Request" representing the // client's request for the DisableRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -364,7 +364,7 @@ const opEnableRule = "EnableRule" // EnableRuleRequest generates a "aws/request.Request" representing the // client's request for the EnableRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -455,7 +455,7 @@ const opListRuleNamesByTarget = "ListRuleNamesByTarget" // ListRuleNamesByTargetRequest generates a "aws/request.Request" representing the // client's request for the ListRuleNamesByTarget operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -535,7 +535,7 @@ const opListRules = "ListRules" // ListRulesRequest generates a "aws/request.Request" representing the // client's request for the ListRules operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -615,7 +615,7 @@ const opListTargetsByRule = "ListTargetsByRule" // ListTargetsByRuleRequest generates a "aws/request.Request" representing the // client's request for the ListTargetsByRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -697,7 +697,7 @@ const opPutEvents = "PutEvents" // PutEventsRequest generates a "aws/request.Request" representing the // client's request for the PutEvents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -777,7 +777,7 @@ const opPutPermission = "PutPermission" // PutPermissionRequest generates a "aws/request.Request" representing the // client's request for the PutPermission operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -878,7 +878,7 @@ const opPutRule = "PutRule" // PutRuleRequest generates a "aws/request.Request" representing the // client's request for the PutRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -921,6 +921,11 @@ func (c *CloudWatchEvents) PutRuleRequest(input *PutRuleInput) (req *request.Req // Creates or updates the specified rule. Rules are enabled by default, or based // on value of the state. You can disable a rule using DisableRule. // +// If you are updating an existing rule, the rule is completely replaced with +// what you specify in this PutRule command. If you omit arguments in PutRule, +// the old values for those arguments are not kept. Instead, they are replaced +// with null values. +// // When you create or update a rule, incoming events might not immediately start // matching to new or updated rules. Please allow a short period of time for // changes to take effect. @@ -982,7 +987,7 @@ const opPutTargets = "PutTargets" // PutTargetsRequest generates a "aws/request.Request" representing the // client's request for the PutTargets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1041,13 +1046,15 @@ func (c *CloudWatchEvents) PutTargetsRequest(input *PutTargetsInput) (req *reque // // * AWS Step Functions state machines // +// * AWS Batch jobs +// // * Pipelines in Amazon Code Pipeline // // * Amazon Inspector assessment templates // // * Amazon SNS topics // -// * Amazon SQS queues +// * Amazon SQS queues, including FIFO queues // // * The default event bus of another AWS account // @@ -1099,8 +1106,8 @@ func (c *CloudWatchEvents) PutTargetsRequest(input *PutTargetsInput) (req *reque // are extracted from the event and used as values in a template that you // specify as the input to the target. // -// When you specify Input, InputPath, or InputTransformer, you must use JSON -// dot notation, not bracket notation. +// When you specify InputPath or InputTransformer, you must use JSON dot notation, +// not bracket notation. // // When you add targets to a rule and the associated rule triggers soon after, // new or updated targets might not be immediately invoked. Please allow a short @@ -1157,7 +1164,7 @@ const opRemovePermission = "RemovePermission" // RemovePermissionRequest generates a "aws/request.Request" representing the // client's request for the RemovePermission operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1247,7 +1254,7 @@ const opRemoveTargets = "RemoveTargets" // RemoveTargetsRequest generates a "aws/request.Request" representing the // client's request for the RemoveTargets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1342,7 +1349,7 @@ const opTestEventPattern = "TestEventPattern" // TestEventPatternRequest generates a "aws/request.Request" representing the // client's request for the TestEventPattern operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1425,6 +1432,140 @@ func (c *CloudWatchEvents) TestEventPatternWithContext(ctx aws.Context, input *T return out, req.Send() } +// The array properties for the submitted job, such as the size of the array. +// The array size can be between 2 and 10,000. If you specify array properties +// for a job, it becomes an array job. This parameter is used only if the target +// is an AWS Batch job. +type BatchArrayProperties struct { + _ struct{} `type:"structure"` + + // The size of the array, if this is an array batch job. Valid values are integers + // between 2 and 10,000. + Size *int64 `type:"integer"` +} + +// String returns the string representation +func (s BatchArrayProperties) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s BatchArrayProperties) GoString() string { + return s.String() +} + +// SetSize sets the Size field's value. +func (s *BatchArrayProperties) SetSize(v int64) *BatchArrayProperties { + s.Size = &v + return s +} + +// The custom parameters to be used when the target is an AWS Batch job. +type BatchParameters struct { + _ struct{} `type:"structure"` + + // The array properties for the submitted job, such as the size of the array. + // The array size can be between 2 and 10,000. If you specify array properties + // for a job, it becomes an array job. This parameter is used only if the target + // is an AWS Batch job. + ArrayProperties *BatchArrayProperties `type:"structure"` + + // The ARN or name of the job definition to use if the event target is an AWS + // Batch job. This job definition must already exist. + // + // JobDefinition is a required field + JobDefinition *string `type:"string" required:"true"` + + // The name to use for this execution of the job, if the target is an AWS Batch + // job. + // + // JobName is a required field + JobName *string `type:"string" required:"true"` + + // The retry strategy to use for failed jobs, if the target is an AWS Batch + // job. The retry strategy is the number of times to retry the failed job execution. + // Valid values are 1 to 10. When you specify a retry strategy here, it overrides + // the retry strategy defined in the job definition. + RetryStrategy *BatchRetryStrategy `type:"structure"` +} + +// String returns the string representation +func (s BatchParameters) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s BatchParameters) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *BatchParameters) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "BatchParameters"} + if s.JobDefinition == nil { + invalidParams.Add(request.NewErrParamRequired("JobDefinition")) + } + if s.JobName == nil { + invalidParams.Add(request.NewErrParamRequired("JobName")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetArrayProperties sets the ArrayProperties field's value. +func (s *BatchParameters) SetArrayProperties(v *BatchArrayProperties) *BatchParameters { + s.ArrayProperties = v + return s +} + +// SetJobDefinition sets the JobDefinition field's value. +func (s *BatchParameters) SetJobDefinition(v string) *BatchParameters { + s.JobDefinition = &v + return s +} + +// SetJobName sets the JobName field's value. +func (s *BatchParameters) SetJobName(v string) *BatchParameters { + s.JobName = &v + return s +} + +// SetRetryStrategy sets the RetryStrategy field's value. +func (s *BatchParameters) SetRetryStrategy(v *BatchRetryStrategy) *BatchParameters { + s.RetryStrategy = v + return s +} + +// The retry strategy to use for failed jobs, if the target is an AWS Batch +// job. If you specify a retry strategy here, it overrides the retry strategy +// defined in the job definition. +type BatchRetryStrategy struct { + _ struct{} `type:"structure"` + + // The number of times to attempt to retry, if the job fails. Valid values are + // 1 to 10. + Attempts *int64 `type:"integer"` +} + +// String returns the string representation +func (s BatchRetryStrategy) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s BatchRetryStrategy) GoString() string { + return s.String() +} + +// SetAttempts sets the Attempts field's value. +func (s *BatchRetryStrategy) SetAttempts(v int64) *BatchRetryStrategy { + s.Attempts = &v + return s +} + type DeleteRuleInput struct { _ struct{} `type:"structure"` @@ -2290,8 +2431,8 @@ func (s *PutEventsOutput) SetFailedEntryCount(v int64) *PutEventsOutput { type PutEventsRequestEntry struct { _ struct{} `type:"structure"` - // In the JSON sense, an object containing fields, which may also contain nested - // subobjects. No constraints are imposed on its contents. + // A valid JSON string. There is no other schema imposed. The JSON string may + // contain fields and nested subobjects. Detail *string `type:"string"` // Free-form string used to decide what fields to expect in the event detail. @@ -3134,6 +3275,31 @@ func (s *RunCommandTarget) SetValues(v []*string) *RunCommandTarget { return s } +// This structure includes the custom parameter to be used when the target is +// an SQS FIFO queue. +type SqsParameters struct { + _ struct{} `type:"structure"` + + // The FIFO message group ID to use as the target. + MessageGroupId *string `type:"string"` +} + +// String returns the string representation +func (s SqsParameters) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s SqsParameters) GoString() string { + return s.String() +} + +// SetMessageGroupId sets the MessageGroupId field's value. +func (s *SqsParameters) SetMessageGroupId(v string) *SqsParameters { + s.MessageGroupId = &v + return s +} + // Targets are the resources to be invoked when a rule is triggered. Target // types include EC2 instances, AWS Lambda functions, Amazon Kinesis streams, // Amazon ECS tasks, AWS Step Functions state machines, Run Command, and built-in @@ -3146,6 +3312,12 @@ type Target struct { // Arn is a required field Arn *string `min:"1" type:"string" required:"true"` + // Contains the job definition, job name, and other parameters if the event + // target is an AWS Batch job. For more information about AWS Batch, see Jobs + // (http://docs.aws.amazon.com/batch/latest/userguide/jobs.html) in the AWS + // Batch User Guide. + BatchParameters *BatchParameters `type:"structure"` + // Contains the Amazon ECS task definition and task count to be used, if the // event target is an Amazon ECS task. For more information about Amazon ECS // tasks, see Task Definitions (http://docs.aws.amazon.com/AmazonECS/latest/developerguide/task_defintions.html) @@ -3158,9 +3330,8 @@ type Target struct { Id *string `min:"1" type:"string" required:"true"` // Valid JSON text passed to the target. In this case, nothing from the event - // itself is passed to the target. You must use JSON dot notation, not bracket - // notation. For more information, see The JavaScript Object Notation (JSON) - // Data Interchange Format (http://www.rfc-editor.org/rfc/rfc7159.txt). + // itself is passed to the target. For more information, see The JavaScript + // Object Notation (JSON) Data Interchange Format (http://www.rfc-editor.org/rfc/rfc7159.txt). Input *string `type:"string"` // The value of the JSONPath that is used for extracting part of the matched @@ -3185,6 +3356,9 @@ type Target struct { // Parameters used when you are using the rule to invoke Amazon EC2 Run Command. RunCommandParameters *RunCommandParameters `type:"structure"` + + // Contains the message group ID to use when the target is a FIFO queue. + SqsParameters *SqsParameters `type:"structure"` } // String returns the string representation @@ -3215,6 +3389,11 @@ func (s *Target) Validate() error { if s.RoleArn != nil && len(*s.RoleArn) < 1 { invalidParams.Add(request.NewErrParamMinLen("RoleArn", 1)) } + if s.BatchParameters != nil { + if err := s.BatchParameters.Validate(); err != nil { + invalidParams.AddNested("BatchParameters", err.(request.ErrInvalidParams)) + } + } if s.EcsParameters != nil { if err := s.EcsParameters.Validate(); err != nil { invalidParams.AddNested("EcsParameters", err.(request.ErrInvalidParams)) @@ -3248,6 +3427,12 @@ func (s *Target) SetArn(v string) *Target { return s } +// SetBatchParameters sets the BatchParameters field's value. +func (s *Target) SetBatchParameters(v *BatchParameters) *Target { + s.BatchParameters = v + return s +} + // SetEcsParameters sets the EcsParameters field's value. func (s *Target) SetEcsParameters(v *EcsParameters) *Target { s.EcsParameters = v @@ -3296,6 +3481,12 @@ func (s *Target) SetRunCommandParameters(v *RunCommandParameters) *Target { return s } +// SetSqsParameters sets the SqsParameters field's value. +func (s *Target) SetSqsParameters(v *SqsParameters) *Target { + s.SqsParameters = v + return s +} + type TestEventPatternInput struct { _ struct{} `type:"structure"` diff --git a/vendor/github.com/aws/aws-sdk-go/service/cloudwatchlogs/api.go b/vendor/github.com/aws/aws-sdk-go/service/cloudwatchlogs/api.go index aaebe84d35dc..43a77742fc6f 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/cloudwatchlogs/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/cloudwatchlogs/api.go @@ -16,7 +16,7 @@ const opAssociateKmsKey = "AssociateKmsKey" // AssociateKmsKeyRequest generates a "aws/request.Request" representing the // client's request for the AssociateKmsKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -119,7 +119,7 @@ const opCancelExportTask = "CancelExportTask" // CancelExportTaskRequest generates a "aws/request.Request" representing the // client's request for the CancelExportTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -211,7 +211,7 @@ const opCreateExportTask = "CreateExportTask" // CreateExportTaskRequest generates a "aws/request.Request" representing the // client's request for the CreateExportTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -316,7 +316,7 @@ const opCreateLogGroup = "CreateLogGroup" // CreateLogGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateLogGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -430,7 +430,7 @@ const opCreateLogStream = "CreateLogStream" // CreateLogStreamRequest generates a "aws/request.Request" representing the // client's request for the CreateLogStream operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -531,7 +531,7 @@ const opDeleteDestination = "DeleteDestination" // DeleteDestinationRequest generates a "aws/request.Request" representing the // client's request for the DeleteDestination operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -623,7 +623,7 @@ const opDeleteLogGroup = "DeleteLogGroup" // DeleteLogGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteLogGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -714,7 +714,7 @@ const opDeleteLogStream = "DeleteLogStream" // DeleteLogStreamRequest generates a "aws/request.Request" representing the // client's request for the DeleteLogStream operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -805,7 +805,7 @@ const opDeleteMetricFilter = "DeleteMetricFilter" // DeleteMetricFilterRequest generates a "aws/request.Request" representing the // client's request for the DeleteMetricFilter operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -895,7 +895,7 @@ const opDeleteResourcePolicy = "DeleteResourcePolicy" // DeleteResourcePolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteResourcePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -983,7 +983,7 @@ const opDeleteRetentionPolicy = "DeleteRetentionPolicy" // DeleteRetentionPolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteRetentionPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1076,7 +1076,7 @@ const opDeleteSubscriptionFilter = "DeleteSubscriptionFilter" // DeleteSubscriptionFilterRequest generates a "aws/request.Request" representing the // client's request for the DeleteSubscriptionFilter operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1166,7 +1166,7 @@ const opDescribeDestinations = "DescribeDestinations" // DescribeDestinationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeDestinations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1305,7 +1305,7 @@ const opDescribeExportTasks = "DescribeExportTasks" // DescribeExportTasksRequest generates a "aws/request.Request" representing the // client's request for the DescribeExportTasks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1388,7 +1388,7 @@ const opDescribeLogGroups = "DescribeLogGroups" // DescribeLogGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeLogGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1527,7 +1527,7 @@ const opDescribeLogStreams = "DescribeLogStreams" // DescribeLogStreamsRequest generates a "aws/request.Request" representing the // client's request for the DescribeLogStreams operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1673,7 +1673,7 @@ const opDescribeMetricFilters = "DescribeMetricFilters" // DescribeMetricFiltersRequest generates a "aws/request.Request" representing the // client's request for the DescribeMetricFilters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1816,7 +1816,7 @@ const opDescribeResourcePolicies = "DescribeResourcePolicies" // DescribeResourcePoliciesRequest generates a "aws/request.Request" representing the // client's request for the DescribeResourcePolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1898,7 +1898,7 @@ const opDescribeSubscriptionFilters = "DescribeSubscriptionFilters" // DescribeSubscriptionFiltersRequest generates a "aws/request.Request" representing the // client's request for the DescribeSubscriptionFilters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2041,7 +2041,7 @@ const opDisassociateKmsKey = "DisassociateKmsKey" // DisassociateKmsKeyRequest generates a "aws/request.Request" representing the // client's request for the DisassociateKmsKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2139,7 +2139,7 @@ const opFilterLogEvents = "FilterLogEvents" // FilterLogEventsRequest generates a "aws/request.Request" representing the // client's request for the FilterLogEvents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2288,7 +2288,7 @@ const opGetLogEvents = "GetLogEvents" // GetLogEventsRequest generates a "aws/request.Request" representing the // client's request for the GetLogEvents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2434,7 +2434,7 @@ const opListTagsLogGroup = "ListTagsLogGroup" // ListTagsLogGroupRequest generates a "aws/request.Request" representing the // client's request for the ListTagsLogGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2516,7 +2516,7 @@ const opPutDestination = "PutDestination" // PutDestinationRequest generates a "aws/request.Request" representing the // client's request for the PutDestination operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2611,7 +2611,7 @@ const opPutDestinationPolicy = "PutDestinationPolicy" // PutDestinationPolicyRequest generates a "aws/request.Request" representing the // client's request for the PutDestinationPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2701,7 +2701,7 @@ const opPutLogEvents = "PutLogEvents" // PutLogEventsRequest generates a "aws/request.Request" representing the // client's request for the PutLogEvents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2819,7 +2819,7 @@ const opPutMetricFilter = "PutMetricFilter" // PutMetricFilterRequest generates a "aws/request.Request" representing the // client's request for the PutMetricFilter operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2917,7 +2917,7 @@ const opPutResourcePolicy = "PutResourcePolicy" // PutResourcePolicyRequest generates a "aws/request.Request" representing the // client's request for the PutResourcePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3004,7 +3004,7 @@ const opPutRetentionPolicy = "PutRetentionPolicy" // PutRetentionPolicyRequest generates a "aws/request.Request" representing the // client's request for the PutRetentionPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3096,7 +3096,7 @@ const opPutSubscriptionFilter = "PutSubscriptionFilter" // PutSubscriptionFilterRequest generates a "aws/request.Request" representing the // client's request for the PutSubscriptionFilter operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3209,7 +3209,7 @@ const opTagLogGroup = "TagLogGroup" // TagLogGroupRequest generates a "aws/request.Request" representing the // client's request for the TagLogGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3300,7 +3300,7 @@ const opTestMetricFilter = "TestMetricFilter" // TestMetricFilterRequest generates a "aws/request.Request" representing the // client's request for the TestMetricFilter operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3384,7 +3384,7 @@ const opUntagLogGroup = "UntagLogGroup" // UntagLogGroupRequest generates a "aws/request.Request" representing the // client's request for the UntagLogGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/codebuild/api.go b/vendor/github.com/aws/aws-sdk-go/service/codebuild/api.go index 433c34bfff36..a8f83ca0f13d 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/codebuild/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/codebuild/api.go @@ -15,7 +15,7 @@ const opBatchDeleteBuilds = "BatchDeleteBuilds" // BatchDeleteBuildsRequest generates a "aws/request.Request" representing the // client's request for the BatchDeleteBuilds operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -94,7 +94,7 @@ const opBatchGetBuilds = "BatchGetBuilds" // BatchGetBuildsRequest generates a "aws/request.Request" representing the // client's request for the BatchGetBuilds operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -173,7 +173,7 @@ const opBatchGetProjects = "BatchGetProjects" // BatchGetProjectsRequest generates a "aws/request.Request" representing the // client's request for the BatchGetProjects operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -252,7 +252,7 @@ const opCreateProject = "CreateProject" // CreateProjectRequest generates a "aws/request.Request" representing the // client's request for the CreateProject operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -338,7 +338,7 @@ const opCreateWebhook = "CreateWebhook" // CreateWebhookRequest generates a "aws/request.Request" representing the // client's request for the CreateWebhook operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -438,7 +438,7 @@ const opDeleteProject = "DeleteProject" // DeleteProjectRequest generates a "aws/request.Request" representing the // client's request for the DeleteProject operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -517,7 +517,7 @@ const opDeleteWebhook = "DeleteWebhook" // DeleteWebhookRequest generates a "aws/request.Request" representing the // client's request for the DeleteWebhook operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -604,7 +604,7 @@ const opInvalidateProjectCache = "InvalidateProjectCache" // InvalidateProjectCacheRequest generates a "aws/request.Request" representing the // client's request for the InvalidateProjectCache operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -686,7 +686,7 @@ const opListBuilds = "ListBuilds" // ListBuildsRequest generates a "aws/request.Request" representing the // client's request for the ListBuilds operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -765,7 +765,7 @@ const opListBuildsForProject = "ListBuildsForProject" // ListBuildsForProjectRequest generates a "aws/request.Request" representing the // client's request for the ListBuildsForProject operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -848,7 +848,7 @@ const opListCuratedEnvironmentImages = "ListCuratedEnvironmentImages" // ListCuratedEnvironmentImagesRequest generates a "aws/request.Request" representing the // client's request for the ListCuratedEnvironmentImages operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -922,7 +922,7 @@ const opListProjects = "ListProjects" // ListProjectsRequest generates a "aws/request.Request" representing the // client's request for the ListProjects operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1002,7 +1002,7 @@ const opStartBuild = "StartBuild" // StartBuildRequest generates a "aws/request.Request" representing the // client's request for the StartBuild operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1087,7 +1087,7 @@ const opStopBuild = "StopBuild" // StopBuildRequest generates a "aws/request.Request" representing the // client's request for the StopBuild operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1169,7 +1169,7 @@ const opUpdateProject = "UpdateProject" // UpdateProjectRequest generates a "aws/request.Request" representing the // client's request for the UpdateProject operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1247,6 +1247,91 @@ func (c *CodeBuild) UpdateProjectWithContext(ctx aws.Context, input *UpdateProje return out, req.Send() } +const opUpdateWebhook = "UpdateWebhook" + +// UpdateWebhookRequest generates a "aws/request.Request" representing the +// client's request for the UpdateWebhook operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateWebhook for more information on using the UpdateWebhook +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the UpdateWebhookRequest method. +// req, resp := client.UpdateWebhookRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codebuild-2016-10-06/UpdateWebhook +func (c *CodeBuild) UpdateWebhookRequest(input *UpdateWebhookInput) (req *request.Request, output *UpdateWebhookOutput) { + op := &request.Operation{ + Name: opUpdateWebhook, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &UpdateWebhookInput{} + } + + output = &UpdateWebhookOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateWebhook API operation for AWS CodeBuild. +// +// Updates the webhook associated with an AWS CodeBuild build project. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS CodeBuild's +// API operation UpdateWebhook for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInvalidInputException "InvalidInputException" +// The input value that was provided is not valid. +// +// * ErrCodeResourceNotFoundException "ResourceNotFoundException" +// The specified AWS resource cannot be found. +// +// * ErrCodeOAuthProviderException "OAuthProviderException" +// There was a problem with the underlying OAuth provider. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codebuild-2016-10-06/UpdateWebhook +func (c *CodeBuild) UpdateWebhook(input *UpdateWebhookInput) (*UpdateWebhookOutput, error) { + req, out := c.UpdateWebhookRequest(input) + return out, req.Send() +} + +// UpdateWebhookWithContext is the same as UpdateWebhook with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateWebhook for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeBuild) UpdateWebhookWithContext(ctx aws.Context, input *UpdateWebhookInput, opts ...request.Option) (*UpdateWebhookOutput, error) { + req, out := c.UpdateWebhookRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + type BatchDeleteBuildsInput struct { _ struct{} `type:"structure"` @@ -1531,7 +1616,7 @@ type Build struct { // about any current build phase that is not yet complete. Phases []*BuildPhase `locationName:"phases" type:"list"` - // The name of the build project. + // The name of the AWS CodeBuild project. ProjectName *string `locationName:"projectName" min:"1" type:"string"` // Information about the source code to be built. @@ -2107,7 +2192,13 @@ func (s *CreateProjectOutput) SetProject(v *Project) *CreateProjectOutput { type CreateWebhookInput struct { _ struct{} `type:"structure"` - // The name of the build project. + // A regular expression used to determine which branches in a repository are + // built when a webhook is triggered. If the name of a branch matches the regular + // expression, then it is built. If it doesn't match, then it is not. If branchFilter + // is empty, then all branches are built. + BranchFilter *string `locationName:"branchFilter" type:"string"` + + // The name of the AWS CodeBuild project. // // ProjectName is a required field ProjectName *string `locationName:"projectName" min:"2" type:"string" required:"true"` @@ -2139,6 +2230,12 @@ func (s *CreateWebhookInput) Validate() error { return nil } +// SetBranchFilter sets the BranchFilter field's value. +func (s *CreateWebhookInput) SetBranchFilter(v string) *CreateWebhookInput { + s.BranchFilter = &v + return s +} + // SetProjectName sets the ProjectName field's value. func (s *CreateWebhookInput) SetProjectName(v string) *CreateWebhookInput { s.ProjectName = &v @@ -2227,7 +2324,7 @@ func (s DeleteProjectOutput) GoString() string { type DeleteWebhookInput struct { _ struct{} `type:"structure"` - // The name of the build project. + // The name of the AWS CodeBuild project. // // ProjectName is a required field ProjectName *string `locationName:"projectName" min:"2" type:"string" required:"true"` @@ -2467,7 +2564,8 @@ func (s *EnvironmentVariable) SetValue(v string) *EnvironmentVariable { type InvalidateProjectCacheInput struct { _ struct{} `type:"structure"` - // The name of the build project that the cache will be reset for. + // The name of the AWS CodeBuild build project that the cache will be reset + // for. // // ProjectName is a required field ProjectName *string `locationName:"projectName" min:"1" type:"string" required:"true"` @@ -2530,7 +2628,7 @@ type ListBuildsForProjectInput struct { // until no more next tokens are returned. NextToken *string `locationName:"nextToken" type:"string"` - // The name of the build project. + // The name of the AWS CodeBuild project. // // ProjectName is a required field ProjectName *string `locationName:"projectName" min:"1" type:"string" required:"true"` @@ -3414,17 +3512,15 @@ type ProjectEnvironment struct { // Image is a required field Image *string `locationName:"image" min:"1" type:"string" required:"true"` - // If set to true, enables running the Docker daemon inside a Docker container; - // otherwise, false or not specified (the default). This value must be set to - // true only if this build project will be used to build Docker images, and - // the specified build environment image is not one provided by AWS CodeBuild - // with Docker support. Otherwise, all associated builds that attempt to interact - // with the Docker daemon will fail. Note that you must also start the Docker - // daemon so that your builds can interact with it as needed. One way to do - // this is to initialize the Docker daemon in the install phase of your build - // spec by running the following build commands. (Do not run the following build - // commands if the specified build environment image is provided by AWS CodeBuild - // with Docker support.) + // Enables running the Docker daemon inside a Docker container. Set to true + // only if the build project is be used to build Docker images, and the specified + // build environment image is not provided by AWS CodeBuild with Docker support. + // Otherwise, all associated builds that attempt to interact with the Docker + // daemon will fail. Note that you must also start the Docker daemon so that + // builds can interact with it. One way to do this is to initialize the Docker + // daemon during the install phase of your build spec by running the following + // build commands. (Do not run the following build commands if the specified + // build environment image is provided by AWS CodeBuild with Docker support.) // // - nohup /usr/local/bin/dockerd --host=unix:///var/run/docker.sock --host=tcp://0.0.0.0:2375 // --storage-driver=overlay& - timeout -t 15 sh -c "until docker info; do echo @@ -3737,7 +3833,7 @@ type StartBuildInput struct { // for this build only, any previous depth of history defined in the build project. GitCloneDepthOverride *int64 `locationName:"gitCloneDepthOverride" type:"integer"` - // The name of the build project to start running a build. + // The name of the AWS CodeBuild build project to start running a build. // // ProjectName is a required field ProjectName *string `locationName:"projectName" min:"1" type:"string" required:"true"` @@ -4215,6 +4311,93 @@ func (s *UpdateProjectOutput) SetProject(v *Project) *UpdateProjectOutput { return s } +type UpdateWebhookInput struct { + _ struct{} `type:"structure"` + + // A regular expression used to determine which branches in a repository are + // built when a webhook is triggered. If the name of a branch matches the regular + // expression, then it is built. If it doesn't match, then it is not. If branchFilter + // is empty, then all branches are built. + BranchFilter *string `locationName:"branchFilter" type:"string"` + + // The name of the AWS CodeBuild project. + // + // ProjectName is a required field + ProjectName *string `locationName:"projectName" min:"2" type:"string" required:"true"` + + // A boolean value that specifies whether the associated repository's secret + // token should be updated. + RotateSecret *bool `locationName:"rotateSecret" type:"boolean"` +} + +// String returns the string representation +func (s UpdateWebhookInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateWebhookInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *UpdateWebhookInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateWebhookInput"} + if s.ProjectName == nil { + invalidParams.Add(request.NewErrParamRequired("ProjectName")) + } + if s.ProjectName != nil && len(*s.ProjectName) < 2 { + invalidParams.Add(request.NewErrParamMinLen("ProjectName", 2)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetBranchFilter sets the BranchFilter field's value. +func (s *UpdateWebhookInput) SetBranchFilter(v string) *UpdateWebhookInput { + s.BranchFilter = &v + return s +} + +// SetProjectName sets the ProjectName field's value. +func (s *UpdateWebhookInput) SetProjectName(v string) *UpdateWebhookInput { + s.ProjectName = &v + return s +} + +// SetRotateSecret sets the RotateSecret field's value. +func (s *UpdateWebhookInput) SetRotateSecret(v bool) *UpdateWebhookInput { + s.RotateSecret = &v + return s +} + +type UpdateWebhookOutput struct { + _ struct{} `type:"structure"` + + // Information about a repository's webhook that is associated with a project + // in AWS CodeBuild. + Webhook *Webhook `locationName:"webhook" type:"structure"` +} + +// String returns the string representation +func (s UpdateWebhookOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateWebhookOutput) GoString() string { + return s.String() +} + +// SetWebhook sets the Webhook field's value. +func (s *UpdateWebhookOutput) SetWebhook(v *Webhook) *UpdateWebhookOutput { + s.Webhook = v + return s +} + // Information about the VPC configuration that AWS CodeBuild will access. type VpcConfig struct { _ struct{} `type:"structure"` @@ -4275,12 +4458,19 @@ func (s *VpcConfig) SetVpcId(v string) *VpcConfig { type Webhook struct { _ struct{} `type:"structure"` - // This is the server endpoint that will receive the webhook payload. + // A regular expression used to determine which branches in a repository are + // built when a webhook is triggered. If the name of a branch matches the regular + // expression, then it is built. If it doesn't match, then it is not. If branchFilter + // is empty, then all branches are built. + BranchFilter *string `locationName:"branchFilter" type:"string"` + + // A timestamp indicating the last time a repository's secret token was modified. + LastModifiedSecret *time.Time `locationName:"lastModifiedSecret" type:"timestamp" timestampFormat:"unix"` + + // The CodeBuild endpoint where webhook events are sent. PayloadUrl *string `locationName:"payloadUrl" min:"1" type:"string"` - // Use this secret while creating a webhook in GitHub for Enterprise. The secret - // allows webhook requests sent by GitHub for Enterprise to be authenticated - // by AWS CodeBuild. + // The secret token of the associated repository. Secret *string `locationName:"secret" min:"1" type:"string"` // The URL to the webhook. @@ -4297,6 +4487,18 @@ func (s Webhook) GoString() string { return s.String() } +// SetBranchFilter sets the BranchFilter field's value. +func (s *Webhook) SetBranchFilter(v string) *Webhook { + s.BranchFilter = &v + return s +} + +// SetLastModifiedSecret sets the LastModifiedSecret field's value. +func (s *Webhook) SetLastModifiedSecret(v time.Time) *Webhook { + s.LastModifiedSecret = &v + return s +} + // SetPayloadUrl sets the PayloadUrl field's value. func (s *Webhook) SetPayloadUrl(v string) *Webhook { s.PayloadUrl = &v diff --git a/vendor/github.com/aws/aws-sdk-go/service/codebuild/doc.go b/vendor/github.com/aws/aws-sdk-go/service/codebuild/doc.go index 5bab7179bbaa..91c473e1dfdd 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/codebuild/doc.go +++ b/vendor/github.com/aws/aws-sdk-go/service/codebuild/doc.go @@ -33,6 +33,8 @@ // begin automatically rebuilding the source code every time a code change // is pushed to the repository. // +// * UpdateWebhook: Changes the settings of an existing webhook. +// // * DeleteProject: Deletes a build project. // // * DeleteWebhook: For an existing AWS CodeBuild build project that has diff --git a/vendor/github.com/aws/aws-sdk-go/service/codecommit/api.go b/vendor/github.com/aws/aws-sdk-go/service/codecommit/api.go index c8d885d6d35b..7a4f4df26df2 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/codecommit/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/codecommit/api.go @@ -17,7 +17,7 @@ const opBatchGetRepositories = "BatchGetRepositories" // BatchGetRepositoriesRequest generates a "aws/request.Request" representing the // client's request for the BatchGetRepositories operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -128,7 +128,7 @@ const opCreateBranch = "CreateBranch" // CreateBranchRequest generates a "aws/request.Request" representing the // client's request for the CreateBranch operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -256,7 +256,7 @@ const opCreatePullRequest = "CreatePullRequest" // CreatePullRequestRequest generates a "aws/request.Request" representing the // client's request for the CreatePullRequest operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -433,7 +433,7 @@ const opCreateRepository = "CreateRepository" // CreateRepositoryRequest generates a "aws/request.Request" representing the // client's request for the CreateRepository operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -543,7 +543,7 @@ const opDeleteBranch = "DeleteBranch" // DeleteBranchRequest generates a "aws/request.Request" representing the // client's request for the DeleteBranch operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -659,7 +659,7 @@ const opDeleteCommentContent = "DeleteCommentContent" // DeleteCommentContentRequest generates a "aws/request.Request" representing the // client's request for the DeleteCommentContent operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -750,7 +750,7 @@ const opDeleteRepository = "DeleteRepository" // DeleteRepositoryRequest generates a "aws/request.Request" representing the // client's request for the DeleteRepository operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -856,7 +856,7 @@ const opDescribePullRequestEvents = "DescribePullRequestEvents" // DescribePullRequestEventsRequest generates a "aws/request.Request" representing the // client's request for the DescribePullRequestEvents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1032,7 +1032,7 @@ const opGetBlob = "GetBlob" // GetBlobRequest generates a "aws/request.Request" representing the // client's request for the GetBlob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1150,7 +1150,7 @@ const opGetBranch = "GetBranch" // GetBranchRequest generates a "aws/request.Request" representing the // client's request for the GetBranch operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1264,7 +1264,7 @@ const opGetComment = "GetComment" // GetCommentRequest generates a "aws/request.Request" representing the // client's request for the GetComment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1355,7 +1355,7 @@ const opGetCommentsForComparedCommit = "GetCommentsForComparedCommit" // GetCommentsForComparedCommitRequest generates a "aws/request.Request" representing the // client's request for the GetCommentsForComparedCommit operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1531,7 +1531,7 @@ const opGetCommentsForPullRequest = "GetCommentsForPullRequest" // GetCommentsForPullRequestRequest generates a "aws/request.Request" representing the // client's request for the GetCommentsForPullRequest operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1724,7 +1724,7 @@ const opGetCommit = "GetCommit" // GetCommitRequest generates a "aws/request.Request" representing the // client's request for the GetCommit operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1838,7 +1838,7 @@ const opGetDifferences = "GetDifferences" // GetDifferencesRequest generates a "aws/request.Request" representing the // client's request for the GetDifferences operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2025,7 +2025,7 @@ const opGetMergeConflicts = "GetMergeConflicts" // GetMergeConflictsRequest generates a "aws/request.Request" representing the // client's request for the GetMergeConflicts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2159,7 +2159,7 @@ const opGetPullRequest = "GetPullRequest" // GetPullRequestRequest generates a "aws/request.Request" representing the // client's request for the GetPullRequest operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2262,7 +2262,7 @@ const opGetRepository = "GetRepository" // GetRepositoryRequest generates a "aws/request.Request" representing the // client's request for the GetRepository operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2372,7 +2372,7 @@ const opGetRepositoryTriggers = "GetRepositoryTriggers" // GetRepositoryTriggersRequest generates a "aws/request.Request" representing the // client's request for the GetRepositoryTriggers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2476,7 +2476,7 @@ const opListBranches = "ListBranches" // ListBranchesRequest generates a "aws/request.Request" representing the // client's request for the ListBranches operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2639,7 +2639,7 @@ const opListPullRequests = "ListPullRequests" // ListPullRequestsRequest generates a "aws/request.Request" representing the // client's request for the ListPullRequests operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2817,7 +2817,7 @@ const opListRepositories = "ListRepositories" // ListRepositoriesRequest generates a "aws/request.Request" representing the // client's request for the ListRepositories operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2958,7 +2958,7 @@ const opMergePullRequestByFastForward = "MergePullRequestByFastForward" // MergePullRequestByFastForwardRequest generates a "aws/request.Request" representing the // client's request for the MergePullRequestByFastForward operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3094,7 +3094,7 @@ const opPostCommentForComparedCommit = "PostCommentForComparedCommit" // PostCommentForComparedCommitRequest generates a "aws/request.Request" representing the // client's request for the PostCommentForComparedCommit operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3254,7 +3254,7 @@ const opPostCommentForPullRequest = "PostCommentForPullRequest" // PostCommentForPullRequestRequest generates a "aws/request.Request" representing the // client's request for the PostCommentForPullRequest operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3434,7 +3434,7 @@ const opPostCommentReply = "PostCommentReply" // PostCommentReplyRequest generates a "aws/request.Request" representing the // client's request for the PostCommentReply operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3539,11 +3539,197 @@ func (c *CodeCommit) PostCommentReplyWithContext(ctx aws.Context, input *PostCom return out, req.Send() } +const opPutFile = "PutFile" + +// PutFileRequest generates a "aws/request.Request" representing the +// client's request for the PutFile operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See PutFile for more information on using the PutFile +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the PutFileRequest method. +// req, resp := client.PutFileRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codecommit-2015-04-13/PutFile +func (c *CodeCommit) PutFileRequest(input *PutFileInput) (req *request.Request, output *PutFileOutput) { + op := &request.Operation{ + Name: opPutFile, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &PutFileInput{} + } + + output = &PutFileOutput{} + req = c.newRequest(op, input, output) + return +} + +// PutFile API operation for AWS CodeCommit. +// +// Adds or updates a file in an AWS CodeCommit repository. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS CodeCommit's +// API operation PutFile for usage and error information. +// +// Returned Error Codes: +// * ErrCodeRepositoryNameRequiredException "RepositoryNameRequiredException" +// A repository name is required but was not specified. +// +// * ErrCodeInvalidRepositoryNameException "InvalidRepositoryNameException" +// At least one specified repository name is not valid. +// +// This exception only occurs when a specified repository name is not valid. +// Other exceptions occur when a required repository parameter is missing, or +// when a specified repository does not exist. +// +// * ErrCodeRepositoryDoesNotExistException "RepositoryDoesNotExistException" +// The specified repository does not exist. +// +// * ErrCodeParentCommitIdRequiredException "ParentCommitIdRequiredException" +// A parent commit ID is required. To view the full commit ID of a branch in +// a repository, use GetBranch or a Git command (for example, git pull or git +// log). +// +// * ErrCodeInvalidParentCommitIdException "InvalidParentCommitIdException" +// The parent commit ID is not valid. The commit ID cannot be empty, and must +// match the head commit ID for the branch of the repository where you want +// to add or update a file. +// +// * ErrCodeParentCommitDoesNotExistException "ParentCommitDoesNotExistException" +// The parent commit ID is not valid. The specified parent commit ID does not +// exist in the specified branch of the repository. +// +// * ErrCodeParentCommitIdOutdatedException "ParentCommitIdOutdatedException" +// The file could not be added because the provided parent commit ID is not +// the current tip of the specified branch. To view the full commit ID of the +// current head of the branch, use GetBranch. +// +// * ErrCodeFileContentRequiredException "FileContentRequiredException" +// The file cannot be added because it is empty. Empty files cannot be added +// to the repository with this API. +// +// * ErrCodeFileContentSizeLimitExceededException "FileContentSizeLimitExceededException" +// The file cannot be added because it is too large. The maximum file size that +// can be added using PutFile is 6 MB. For files larger than 6 MB but smaller +// than 2 GB, add them using a Git client. +// +// * ErrCodePathRequiredException "PathRequiredException" +// The filePath for a location cannot be empty or null. +// +// * ErrCodeInvalidPathException "InvalidPathException" +// The specified path is not valid. +// +// * ErrCodeBranchNameRequiredException "BranchNameRequiredException" +// A branch name is required but was not specified. +// +// * ErrCodeInvalidBranchNameException "InvalidBranchNameException" +// The specified reference name is not valid. +// +// * ErrCodeBranchDoesNotExistException "BranchDoesNotExistException" +// The specified branch does not exist. +// +// * ErrCodeBranchNameIsTagNameException "BranchNameIsTagNameException" +// The specified branch name is not valid because it is a tag name. Type the +// name of a current branch in the repository. For a list of valid branch names, +// use ListBranches. +// +// * ErrCodeInvalidFileModeException "InvalidFileModeException" +// The specified file mode permission is not valid. For a list of valid file +// mode permissions, see PutFile. +// +// * ErrCodeNameLengthExceededException "NameLengthExceededException" +// The file name is not valid because it has exceeded the character limit for +// file names. File names, including the path to the file, cannot exceed the +// character limit. +// +// * ErrCodeInvalidEmailException "InvalidEmailException" +// The specified email address either contains one or more characters that are +// not allowed, or it exceeds the maximum number of characters allowed for an +// email address. +// +// * ErrCodeCommitMessageLengthExceededException "CommitMessageLengthExceededException" +// The commit message is too long. Provide a shorter string. +// +// * ErrCodeEncryptionIntegrityChecksFailedException "EncryptionIntegrityChecksFailedException" +// An encryption integrity check failed. +// +// * ErrCodeEncryptionKeyAccessDeniedException "EncryptionKeyAccessDeniedException" +// An encryption key could not be accessed. +// +// * ErrCodeEncryptionKeyDisabledException "EncryptionKeyDisabledException" +// The encryption key is disabled. +// +// * ErrCodeEncryptionKeyNotFoundException "EncryptionKeyNotFoundException" +// No encryption key was found. +// +// * ErrCodeEncryptionKeyUnavailableException "EncryptionKeyUnavailableException" +// The encryption key is not available. +// +// * ErrCodeSameFileContentException "SameFileContentException" +// The file was not added or updated because the content of the file is exactly +// the same as the content of that file in the repository and branch that you +// specified. +// +// * ErrCodeFileNameConflictsWithDirectoryNameException "FileNameConflictsWithDirectoryNameException" +// A file cannot be added to the repository because the specified file name +// has the same name as a directory in this repository. Either provide another +// name for the file, or add the file in a directory that does not match the +// file name. +// +// * ErrCodeDirectoryNameConflictsWithFileNameException "DirectoryNameConflictsWithFileNameException" +// A file cannot be added to the repository because the specified path name +// has the same name as a file that already exists in this repository. Either +// provide a different name for the file, or specify a different path for the +// file. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codecommit-2015-04-13/PutFile +func (c *CodeCommit) PutFile(input *PutFileInput) (*PutFileOutput, error) { + req, out := c.PutFileRequest(input) + return out, req.Send() +} + +// PutFileWithContext is the same as PutFile with the addition of +// the ability to pass a context and additional request options. +// +// See PutFile for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeCommit) PutFileWithContext(ctx aws.Context, input *PutFileInput, opts ...request.Option) (*PutFileOutput, error) { + req, out := c.PutFileRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opPutRepositoryTriggers = "PutRepositoryTriggers" // PutRepositoryTriggersRequest generates a "aws/request.Request" representing the // client's request for the PutRepositoryTriggers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3693,7 +3879,7 @@ const opTestRepositoryTriggers = "TestRepositoryTriggers" // TestRepositoryTriggersRequest generates a "aws/request.Request" representing the // client's request for the TestRepositoryTriggers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3845,7 +4031,7 @@ const opUpdateComment = "UpdateComment" // UpdateCommentRequest generates a "aws/request.Request" representing the // client's request for the UpdateComment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3947,7 +4133,7 @@ const opUpdateDefaultBranch = "UpdateDefaultBranch" // UpdateDefaultBranchRequest generates a "aws/request.Request" representing the // client's request for the UpdateDefaultBranch operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4066,7 +4252,7 @@ const opUpdatePullRequestDescription = "UpdatePullRequestDescription" // UpdatePullRequestDescriptionRequest generates a "aws/request.Request" representing the // client's request for the UpdatePullRequestDescription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4161,7 +4347,7 @@ const opUpdatePullRequestStatus = "UpdatePullRequestStatus" // UpdatePullRequestStatusRequest generates a "aws/request.Request" representing the // client's request for the UpdatePullRequestStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4275,7 +4461,7 @@ const opUpdatePullRequestTitle = "UpdatePullRequestTitle" // UpdatePullRequestTitleRequest generates a "aws/request.Request" representing the // client's request for the UpdatePullRequestTitle operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4373,7 +4559,7 @@ const opUpdateRepositoryDescription = "UpdateRepositoryDescription" // UpdateRepositoryDescriptionRequest generates a "aws/request.Request" representing the // client's request for the UpdateRepositoryDescription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4488,7 +4674,7 @@ const opUpdateRepositoryName = "UpdateRepositoryName" // UpdateRepositoryNameRequest generates a "aws/request.Request" representing the // client's request for the UpdateRepositoryName operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5032,7 +5218,8 @@ type Commit struct { // The commit message associated with the specified commit. Message *string `locationName:"message" type:"string"` - // The parent list for the specified commit. + // A list of parent commits for the specified commit. Each parent commit ID + // is the full commit ID. Parents []*string `locationName:"parents" type:"list"` // Tree information for the specified commit. @@ -8083,6 +8270,198 @@ func (s *PullRequestTarget) SetSourceReference(v string) *PullRequestTarget { return s } +type PutFileInput struct { + _ struct{} `type:"structure"` + + // The name of the branch where you want to add or update the file. + // + // BranchName is a required field + BranchName *string `locationName:"branchName" min:"1" type:"string" required:"true"` + + // A message about why this file was added or updated. While optional, adding + // a message is strongly encouraged in order to provide a more useful commit + // history for your repository. + CommitMessage *string `locationName:"commitMessage" type:"string"` + + // An email address for the person adding or updating the file. + Email *string `locationName:"email" type:"string"` + + // The content of the file, in binary object format. + // + // FileContent is automatically base64 encoded/decoded by the SDK. + // + // FileContent is a required field + FileContent []byte `locationName:"fileContent" type:"blob" required:"true"` + + // The file mode permissions of the blob. Valid file mode permissions are listed + // below. + FileMode *string `locationName:"fileMode" type:"string" enum:"FileModeTypeEnum"` + + // The name of the file you want to add or update, including the relative path + // to the file in the repository. + // + // If the path does not currently exist in the repository, the path will be + // created as part of adding the file. + // + // FilePath is a required field + FilePath *string `locationName:"filePath" type:"string" required:"true"` + + // The name of the person adding or updating the file. While optional, adding + // a name is strongly encouraged in order to provide a more useful commit history + // for your repository. + Name *string `locationName:"name" type:"string"` + + // The full commit ID of the head commit in the branch where you want to add + // or update the file. If the commit ID does not match the ID of the head commit + // at the time of the operation, an error will occur, and the file will not + // be added or updated. + ParentCommitId *string `locationName:"parentCommitId" type:"string"` + + // The name of the repository where you want to add or update the file. + // + // RepositoryName is a required field + RepositoryName *string `locationName:"repositoryName" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s PutFileInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PutFileInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *PutFileInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PutFileInput"} + if s.BranchName == nil { + invalidParams.Add(request.NewErrParamRequired("BranchName")) + } + if s.BranchName != nil && len(*s.BranchName) < 1 { + invalidParams.Add(request.NewErrParamMinLen("BranchName", 1)) + } + if s.FileContent == nil { + invalidParams.Add(request.NewErrParamRequired("FileContent")) + } + if s.FilePath == nil { + invalidParams.Add(request.NewErrParamRequired("FilePath")) + } + if s.RepositoryName == nil { + invalidParams.Add(request.NewErrParamRequired("RepositoryName")) + } + if s.RepositoryName != nil && len(*s.RepositoryName) < 1 { + invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetBranchName sets the BranchName field's value. +func (s *PutFileInput) SetBranchName(v string) *PutFileInput { + s.BranchName = &v + return s +} + +// SetCommitMessage sets the CommitMessage field's value. +func (s *PutFileInput) SetCommitMessage(v string) *PutFileInput { + s.CommitMessage = &v + return s +} + +// SetEmail sets the Email field's value. +func (s *PutFileInput) SetEmail(v string) *PutFileInput { + s.Email = &v + return s +} + +// SetFileContent sets the FileContent field's value. +func (s *PutFileInput) SetFileContent(v []byte) *PutFileInput { + s.FileContent = v + return s +} + +// SetFileMode sets the FileMode field's value. +func (s *PutFileInput) SetFileMode(v string) *PutFileInput { + s.FileMode = &v + return s +} + +// SetFilePath sets the FilePath field's value. +func (s *PutFileInput) SetFilePath(v string) *PutFileInput { + s.FilePath = &v + return s +} + +// SetName sets the Name field's value. +func (s *PutFileInput) SetName(v string) *PutFileInput { + s.Name = &v + return s +} + +// SetParentCommitId sets the ParentCommitId field's value. +func (s *PutFileInput) SetParentCommitId(v string) *PutFileInput { + s.ParentCommitId = &v + return s +} + +// SetRepositoryName sets the RepositoryName field's value. +func (s *PutFileInput) SetRepositoryName(v string) *PutFileInput { + s.RepositoryName = &v + return s +} + +type PutFileOutput struct { + _ struct{} `type:"structure"` + + // The ID of the blob, which is its SHA-1 pointer. + // + // BlobId is a required field + BlobId *string `locationName:"blobId" type:"string" required:"true"` + + // The full SHA of the commit that contains this file change. + // + // CommitId is a required field + CommitId *string `locationName:"commitId" type:"string" required:"true"` + + // Tree information for the commit that contains this file change. + // + // TreeId is a required field + TreeId *string `locationName:"treeId" type:"string" required:"true"` +} + +// String returns the string representation +func (s PutFileOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PutFileOutput) GoString() string { + return s.String() +} + +// SetBlobId sets the BlobId field's value. +func (s *PutFileOutput) SetBlobId(v string) *PutFileOutput { + s.BlobId = &v + return s +} + +// SetCommitId sets the CommitId field's value. +func (s *PutFileOutput) SetCommitId(v string) *PutFileOutput { + s.CommitId = &v + return s +} + +// SetTreeId sets the TreeId field's value. +func (s *PutFileOutput) SetTreeId(v string) *PutFileOutput { + s.TreeId = &v + return s +} + // Represents the input ofa put repository triggers operation. type PutRepositoryTriggersInput struct { _ struct{} `type:"structure"` @@ -9132,7 +9511,8 @@ func (s UpdateRepositoryNameOutput) GoString() string { type UserInfo struct { _ struct{} `type:"structure"` - // The date when the specified commit was pushed to the repository. + // The date when the specified commit was commited, in timestamp format with + // GMT offset. Date *string `locationName:"date" type:"string"` // The email address associated with the user who made the commit, if any. @@ -9181,6 +9561,17 @@ const ( ChangeTypeEnumD = "D" ) +const ( + // FileModeTypeEnumExecutable is a FileModeTypeEnum enum value + FileModeTypeEnumExecutable = "EXECUTABLE" + + // FileModeTypeEnumNormal is a FileModeTypeEnum enum value + FileModeTypeEnumNormal = "NORMAL" + + // FileModeTypeEnumSymlink is a FileModeTypeEnum enum value + FileModeTypeEnumSymlink = "SYMLINK" +) + const ( // MergeOptionTypeEnumFastForwardMerge is a MergeOptionTypeEnum enum value MergeOptionTypeEnumFastForwardMerge = "FAST_FORWARD_MERGE" diff --git a/vendor/github.com/aws/aws-sdk-go/service/codecommit/doc.go b/vendor/github.com/aws/aws-sdk-go/service/codecommit/doc.go index 1b2f75c96470..39c77b1f90dc 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/codecommit/doc.go +++ b/vendor/github.com/aws/aws-sdk-go/service/codecommit/doc.go @@ -43,6 +43,11 @@ // // * UpdateDefaultBranch, which changes the default branch for a repository. // +// Files, by calling the following: +// +// * PutFile, which adds or modifies a file in a specified repository and +// branch. +// // Information about committed code in a repository, by calling the following: // // * GetBlob, which returns the base-64 encoded content of an individual diff --git a/vendor/github.com/aws/aws-sdk-go/service/codecommit/errors.go b/vendor/github.com/aws/aws-sdk-go/service/codecommit/errors.go index 91a6a0e87edb..60c433ac55cf 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/codecommit/errors.go +++ b/vendor/github.com/aws/aws-sdk-go/service/codecommit/errors.go @@ -47,6 +47,14 @@ const ( // The specified branch name already exists. ErrCodeBranchNameExistsException = "BranchNameExistsException" + // ErrCodeBranchNameIsTagNameException for service response error code + // "BranchNameIsTagNameException". + // + // The specified branch name is not valid because it is a tag name. Type the + // name of a current branch in the repository. For a list of valid branch names, + // use ListBranches. + ErrCodeBranchNameIsTagNameException = "BranchNameIsTagNameException" + // ErrCodeBranchNameRequiredException for service response error code // "BranchNameRequiredException". // @@ -122,6 +130,12 @@ const ( // A commit ID was not specified. ErrCodeCommitIdRequiredException = "CommitIdRequiredException" + // ErrCodeCommitMessageLengthExceededException for service response error code + // "CommitMessageLengthExceededException". + // + // The commit message is too long. Provide a shorter string. + ErrCodeCommitMessageLengthExceededException = "CommitMessageLengthExceededException" + // ErrCodeCommitRequiredException for service response error code // "CommitRequiredException". // @@ -136,6 +150,15 @@ const ( // default branch. ErrCodeDefaultBranchCannotBeDeletedException = "DefaultBranchCannotBeDeletedException" + // ErrCodeDirectoryNameConflictsWithFileNameException for service response error code + // "DirectoryNameConflictsWithFileNameException". + // + // A file cannot be added to the repository because the specified path name + // has the same name as a file that already exists in this repository. Either + // provide a different name for the file, or specify a different path for the + // file. + ErrCodeDirectoryNameConflictsWithFileNameException = "DirectoryNameConflictsWithFileNameException" + // ErrCodeEncryptionIntegrityChecksFailedException for service response error code // "EncryptionIntegrityChecksFailedException". // @@ -166,6 +189,30 @@ const ( // The encryption key is not available. ErrCodeEncryptionKeyUnavailableException = "EncryptionKeyUnavailableException" + // ErrCodeFileContentRequiredException for service response error code + // "FileContentRequiredException". + // + // The file cannot be added because it is empty. Empty files cannot be added + // to the repository with this API. + ErrCodeFileContentRequiredException = "FileContentRequiredException" + + // ErrCodeFileContentSizeLimitExceededException for service response error code + // "FileContentSizeLimitExceededException". + // + // The file cannot be added because it is too large. The maximum file size that + // can be added using PutFile is 6 MB. For files larger than 6 MB but smaller + // than 2 GB, add them using a Git client. + ErrCodeFileContentSizeLimitExceededException = "FileContentSizeLimitExceededException" + + // ErrCodeFileNameConflictsWithDirectoryNameException for service response error code + // "FileNameConflictsWithDirectoryNameException". + // + // A file cannot be added to the repository because the specified file name + // has the same name as a directory in this repository. Either provide another + // name for the file, or add the file in a directory that does not match the + // file name. + ErrCodeFileNameConflictsWithDirectoryNameException = "FileNameConflictsWithDirectoryNameException" + // ErrCodeFileTooLargeException for service response error code // "FileTooLargeException". // @@ -253,6 +300,14 @@ const ( // name, tag, or full commit ID. ErrCodeInvalidDestinationCommitSpecifierException = "InvalidDestinationCommitSpecifierException" + // ErrCodeInvalidEmailException for service response error code + // "InvalidEmailException". + // + // The specified email address either contains one or more characters that are + // not allowed, or it exceeds the maximum number of characters allowed for an + // email address. + ErrCodeInvalidEmailException = "InvalidEmailException" + // ErrCodeInvalidFileLocationException for service response error code // "InvalidFileLocationException". // @@ -260,6 +315,13 @@ const ( // of the file as well as the file name. ErrCodeInvalidFileLocationException = "InvalidFileLocationException" + // ErrCodeInvalidFileModeException for service response error code + // "InvalidFileModeException". + // + // The specified file mode permission is not valid. For a list of valid file + // mode permissions, see PutFile. + ErrCodeInvalidFileModeException = "InvalidFileModeException" + // ErrCodeInvalidFilePositionException for service response error code // "InvalidFilePositionException". // @@ -285,6 +347,14 @@ const ( // The specified sort order is not valid. ErrCodeInvalidOrderException = "InvalidOrderException" + // ErrCodeInvalidParentCommitIdException for service response error code + // "InvalidParentCommitIdException". + // + // The parent commit ID is not valid. The commit ID cannot be empty, and must + // match the head commit ID for the branch of the repository where you want + // to add or update a file. + ErrCodeInvalidParentCommitIdException = "InvalidParentCommitIdException" + // ErrCodeInvalidPathException for service response error code // "InvalidPathException". // @@ -476,6 +546,37 @@ const ( // again. ErrCodeMultipleRepositoriesInPullRequestException = "MultipleRepositoriesInPullRequestException" + // ErrCodeNameLengthExceededException for service response error code + // "NameLengthExceededException". + // + // The file name is not valid because it has exceeded the character limit for + // file names. File names, including the path to the file, cannot exceed the + // character limit. + ErrCodeNameLengthExceededException = "NameLengthExceededException" + + // ErrCodeParentCommitDoesNotExistException for service response error code + // "ParentCommitDoesNotExistException". + // + // The parent commit ID is not valid. The specified parent commit ID does not + // exist in the specified branch of the repository. + ErrCodeParentCommitDoesNotExistException = "ParentCommitDoesNotExistException" + + // ErrCodeParentCommitIdOutdatedException for service response error code + // "ParentCommitIdOutdatedException". + // + // The file could not be added because the provided parent commit ID is not + // the current tip of the specified branch. To view the full commit ID of the + // current head of the branch, use GetBranch. + ErrCodeParentCommitIdOutdatedException = "ParentCommitIdOutdatedException" + + // ErrCodeParentCommitIdRequiredException for service response error code + // "ParentCommitIdRequiredException". + // + // A parent commit ID is required. To view the full commit ID of a branch in + // a repository, use GetBranch or a Git command (for example, git pull or git + // log). + ErrCodeParentCommitIdRequiredException = "ParentCommitIdRequiredException" + // ErrCodePathDoesNotExistException for service response error code // "PathDoesNotExistException". // @@ -601,6 +702,14 @@ const ( // The list of triggers for the repository is required but was not specified. ErrCodeRepositoryTriggersListRequiredException = "RepositoryTriggersListRequiredException" + // ErrCodeSameFileContentException for service response error code + // "SameFileContentException". + // + // The file was not added or updated because the content of the file is exactly + // the same as the content of that file in the repository and branch that you + // specified. + ErrCodeSameFileContentException = "SameFileContentException" + // ErrCodeSourceAndDestinationAreSameException for service response error code // "SourceAndDestinationAreSameException". // diff --git a/vendor/github.com/aws/aws-sdk-go/service/codedeploy/api.go b/vendor/github.com/aws/aws-sdk-go/service/codedeploy/api.go index 52ad4bf9f02a..efec20fcffaf 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/codedeploy/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/codedeploy/api.go @@ -16,7 +16,7 @@ const opAddTagsToOnPremisesInstances = "AddTagsToOnPremisesInstances" // AddTagsToOnPremisesInstancesRequest generates a "aws/request.Request" representing the // client's request for the AddTagsToOnPremisesInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -116,7 +116,7 @@ const opBatchGetApplicationRevisions = "BatchGetApplicationRevisions" // BatchGetApplicationRevisionsRequest generates a "aws/request.Request" representing the // client's request for the BatchGetApplicationRevisions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -210,7 +210,7 @@ const opBatchGetApplications = "BatchGetApplications" // BatchGetApplicationsRequest generates a "aws/request.Request" representing the // client's request for the BatchGetApplications operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -298,7 +298,7 @@ const opBatchGetDeploymentGroups = "BatchGetDeploymentGroups" // BatchGetDeploymentGroupsRequest generates a "aws/request.Request" representing the // client's request for the BatchGetDeploymentGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -392,7 +392,7 @@ const opBatchGetDeploymentInstances = "BatchGetDeploymentInstances" // BatchGetDeploymentInstancesRequest generates a "aws/request.Request" representing the // client's request for the BatchGetDeploymentInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -487,7 +487,7 @@ const opBatchGetDeployments = "BatchGetDeployments" // BatchGetDeploymentsRequest generates a "aws/request.Request" representing the // client's request for the BatchGetDeployments operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -572,7 +572,7 @@ const opBatchGetOnPremisesInstances = "BatchGetOnPremisesInstances" // BatchGetOnPremisesInstancesRequest generates a "aws/request.Request" representing the // client's request for the BatchGetOnPremisesInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -657,7 +657,7 @@ const opContinueDeployment = "ContinueDeployment" // ContinueDeploymentRequest generates a "aws/request.Request" representing the // client's request for the ContinueDeployment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -758,7 +758,7 @@ const opCreateApplication = "CreateApplication" // CreateApplicationRequest generates a "aws/request.Request" representing the // client's request for the CreateApplication operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -850,7 +850,7 @@ const opCreateDeployment = "CreateDeployment" // CreateDeploymentRequest generates a "aws/request.Request" representing the // client's request for the CreateDeployment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1012,7 +1012,7 @@ const opCreateDeploymentConfig = "CreateDeploymentConfig" // CreateDeploymentConfigRequest generates a "aws/request.Request" representing the // client's request for the CreateDeploymentConfig operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1111,7 +1111,7 @@ const opCreateDeploymentGroup = "CreateDeploymentGroup" // CreateDeploymentGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateDeploymentGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1291,7 +1291,7 @@ const opDeleteApplication = "DeleteApplication" // DeleteApplicationRequest generates a "aws/request.Request" representing the // client's request for the DeleteApplication operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1375,7 +1375,7 @@ const opDeleteDeploymentConfig = "DeleteDeploymentConfig" // DeleteDeploymentConfigRequest generates a "aws/request.Request" representing the // client's request for the DeleteDeploymentConfig operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1468,7 +1468,7 @@ const opDeleteDeploymentGroup = "DeleteDeploymentGroup" // DeleteDeploymentGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteDeploymentGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1561,7 +1561,7 @@ const opDeleteGitHubAccountToken = "DeleteGitHubAccountToken" // DeleteGitHubAccountTokenRequest generates a "aws/request.Request" representing the // client's request for the DeleteGitHubAccountToken operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1652,7 +1652,7 @@ const opDeregisterOnPremisesInstance = "DeregisterOnPremisesInstance" // DeregisterOnPremisesInstanceRequest generates a "aws/request.Request" representing the // client's request for the DeregisterOnPremisesInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1736,7 +1736,7 @@ const opGetApplication = "GetApplication" // GetApplicationRequest generates a "aws/request.Request" representing the // client's request for the GetApplication operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1821,7 +1821,7 @@ const opGetApplicationRevision = "GetApplicationRevision" // GetApplicationRevisionRequest generates a "aws/request.Request" representing the // client's request for the GetApplicationRevision operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1915,7 +1915,7 @@ const opGetDeployment = "GetDeployment" // GetDeploymentRequest generates a "aws/request.Request" representing the // client's request for the GetDeployment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2000,7 +2000,7 @@ const opGetDeploymentConfig = "GetDeploymentConfig" // GetDeploymentConfigRequest generates a "aws/request.Request" representing the // client's request for the GetDeploymentConfig operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2086,7 +2086,7 @@ const opGetDeploymentGroup = "GetDeploymentGroup" // GetDeploymentGroupRequest generates a "aws/request.Request" representing the // client's request for the GetDeploymentGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2181,7 +2181,7 @@ const opGetDeploymentInstance = "GetDeploymentInstance" // GetDeploymentInstanceRequest generates a "aws/request.Request" representing the // client's request for the GetDeploymentInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2275,7 +2275,7 @@ const opGetOnPremisesInstance = "GetOnPremisesInstance" // GetOnPremisesInstanceRequest generates a "aws/request.Request" representing the // client's request for the GetOnPremisesInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2360,7 +2360,7 @@ const opListApplicationRevisions = "ListApplicationRevisions" // ListApplicationRevisionsRequest generates a "aws/request.Request" representing the // client's request for the ListApplicationRevisions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2523,7 +2523,7 @@ const opListApplications = "ListApplications" // ListApplicationsRequest generates a "aws/request.Request" representing the // client's request for the ListApplications operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2658,7 +2658,7 @@ const opListDeploymentConfigs = "ListDeploymentConfigs" // ListDeploymentConfigsRequest generates a "aws/request.Request" representing the // client's request for the ListDeploymentConfigs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2793,7 +2793,7 @@ const opListDeploymentGroups = "ListDeploymentGroups" // ListDeploymentGroupsRequest generates a "aws/request.Request" representing the // client's request for the ListDeploymentGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2938,7 +2938,7 @@ const opListDeploymentInstances = "ListDeploymentInstances" // ListDeploymentInstancesRequest generates a "aws/request.Request" representing the // client's request for the ListDeploymentInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3098,7 +3098,7 @@ const opListDeployments = "ListDeployments" // ListDeploymentsRequest generates a "aws/request.Request" representing the // client's request for the ListDeployments operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3259,7 +3259,7 @@ const opListGitHubAccountTokenNames = "ListGitHubAccountTokenNames" // ListGitHubAccountTokenNamesRequest generates a "aws/request.Request" representing the // client's request for the ListGitHubAccountTokenNames operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3344,7 +3344,7 @@ const opListOnPremisesInstances = "ListOnPremisesInstances" // ListOnPremisesInstancesRequest generates a "aws/request.Request" representing the // client's request for the ListOnPremisesInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3433,7 +3433,7 @@ const opPutLifecycleEventHookExecutionStatus = "PutLifecycleEventHookExecutionSt // PutLifecycleEventHookExecutionStatusRequest generates a "aws/request.Request" representing the // client's request for the PutLifecycleEventHookExecutionStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3534,7 +3534,7 @@ const opRegisterApplicationRevision = "RegisterApplicationRevision" // RegisterApplicationRevisionRequest generates a "aws/request.Request" representing the // client's request for the RegisterApplicationRevision operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3630,7 +3630,7 @@ const opRegisterOnPremisesInstance = "RegisterOnPremisesInstance" // RegisterOnPremisesInstanceRequest generates a "aws/request.Request" representing the // client's request for the RegisterOnPremisesInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3744,7 +3744,7 @@ const opRemoveTagsFromOnPremisesInstances = "RemoveTagsFromOnPremisesInstances" // RemoveTagsFromOnPremisesInstancesRequest generates a "aws/request.Request" representing the // client's request for the RemoveTagsFromOnPremisesInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3844,7 +3844,7 @@ const opSkipWaitTimeForInstanceTermination = "SkipWaitTimeForInstanceTermination // SkipWaitTimeForInstanceTerminationRequest generates a "aws/request.Request" representing the // client's request for the SkipWaitTimeForInstanceTermination operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3941,7 +3941,7 @@ const opStopDeployment = "StopDeployment" // StopDeploymentRequest generates a "aws/request.Request" representing the // client's request for the StopDeployment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4029,7 +4029,7 @@ const opUpdateApplication = "UpdateApplication" // UpdateApplicationRequest generates a "aws/request.Request" representing the // client's request for the UpdateApplication operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4120,7 +4120,7 @@ const opUpdateDeploymentGroup = "UpdateDeploymentGroup" // UpdateDeploymentGroupRequest generates a "aws/request.Request" representing the // client's request for the UpdateDeploymentGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/codepipeline/api.go b/vendor/github.com/aws/aws-sdk-go/service/codepipeline/api.go index 6d6c4d460cce..9e895f1e1440 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/codepipeline/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/codepipeline/api.go @@ -17,7 +17,7 @@ const opAcknowledgeJob = "AcknowledgeJob" // AcknowledgeJobRequest generates a "aws/request.Request" representing the // client's request for the AcknowledgeJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -103,7 +103,7 @@ const opAcknowledgeThirdPartyJob = "AcknowledgeThirdPartyJob" // AcknowledgeThirdPartyJobRequest generates a "aws/request.Request" representing the // client's request for the AcknowledgeThirdPartyJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -192,7 +192,7 @@ const opCreateCustomActionType = "CreateCustomActionType" // CreateCustomActionTypeRequest generates a "aws/request.Request" representing the // client's request for the CreateCustomActionType operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -276,7 +276,7 @@ const opCreatePipeline = "CreatePipeline" // CreatePipelineRequest generates a "aws/request.Request" representing the // client's request for the CreatePipeline operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -374,7 +374,7 @@ const opDeleteCustomActionType = "DeleteCustomActionType" // DeleteCustomActionTypeRequest generates a "aws/request.Request" representing the // client's request for the DeleteCustomActionType operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -459,7 +459,7 @@ const opDeletePipeline = "DeletePipeline" // DeletePipelineRequest generates a "aws/request.Request" representing the // client's request for the DeletePipeline operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -540,7 +540,7 @@ const opDisableStageTransition = "DisableStageTransition" // DisableStageTransitionRequest generates a "aws/request.Request" representing the // client's request for the DisableStageTransition operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -628,7 +628,7 @@ const opEnableStageTransition = "EnableStageTransition" // EnableStageTransitionRequest generates a "aws/request.Request" representing the // client's request for the EnableStageTransition operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -715,7 +715,7 @@ const opGetJobDetails = "GetJobDetails" // GetJobDetailsRequest generates a "aws/request.Request" representing the // client's request for the GetJobDetails operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -802,7 +802,7 @@ const opGetPipeline = "GetPipeline" // GetPipelineRequest generates a "aws/request.Request" representing the // client's request for the GetPipeline operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -890,7 +890,7 @@ const opGetPipelineExecution = "GetPipelineExecution" // GetPipelineExecutionRequest generates a "aws/request.Request" representing the // client's request for the GetPipelineExecution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -978,7 +978,7 @@ const opGetPipelineState = "GetPipelineState" // GetPipelineStateRequest generates a "aws/request.Request" representing the // client's request for the GetPipelineState operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1061,7 +1061,7 @@ const opGetThirdPartyJobDetails = "GetThirdPartyJobDetails" // GetThirdPartyJobDetailsRequest generates a "aws/request.Request" representing the // client's request for the GetThirdPartyJobDetails operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1155,7 +1155,7 @@ const opListActionTypes = "ListActionTypes" // ListActionTypesRequest generates a "aws/request.Request" representing the // client's request for the ListActionTypes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1239,7 +1239,7 @@ const opListPipelineExecutions = "ListPipelineExecutions" // ListPipelineExecutionsRequest generates a "aws/request.Request" representing the // client's request for the ListPipelineExecutions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1325,7 +1325,7 @@ const opListPipelines = "ListPipelines" // ListPipelinesRequest generates a "aws/request.Request" representing the // client's request for the ListPipelines operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1405,7 +1405,7 @@ const opPollForJobs = "PollForJobs" // PollForJobsRequest generates a "aws/request.Request" representing the // client's request for the PollForJobs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1492,7 +1492,7 @@ const opPollForThirdPartyJobs = "PollForThirdPartyJobs" // PollForThirdPartyJobsRequest generates a "aws/request.Request" representing the // client's request for the PollForThirdPartyJobs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1579,7 +1579,7 @@ const opPutActionRevision = "PutActionRevision" // PutActionRevisionRequest generates a "aws/request.Request" representing the // client's request for the PutActionRevision operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1667,7 +1667,7 @@ const opPutApprovalResult = "PutApprovalResult" // PutApprovalResultRequest generates a "aws/request.Request" representing the // client's request for the PutApprovalResult operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1762,7 +1762,7 @@ const opPutJobFailureResult = "PutJobFailureResult" // PutJobFailureResultRequest generates a "aws/request.Request" representing the // client's request for the PutJobFailureResult operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1850,7 +1850,7 @@ const opPutJobSuccessResult = "PutJobSuccessResult" // PutJobSuccessResultRequest generates a "aws/request.Request" representing the // client's request for the PutJobSuccessResult operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1938,7 +1938,7 @@ const opPutThirdPartyJobFailureResult = "PutThirdPartyJobFailureResult" // PutThirdPartyJobFailureResultRequest generates a "aws/request.Request" representing the // client's request for the PutThirdPartyJobFailureResult operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2029,7 +2029,7 @@ const opPutThirdPartyJobSuccessResult = "PutThirdPartyJobSuccessResult" // PutThirdPartyJobSuccessResultRequest generates a "aws/request.Request" representing the // client's request for the PutThirdPartyJobSuccessResult operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2120,7 +2120,7 @@ const opRetryStageExecution = "RetryStageExecution" // RetryStageExecutionRequest generates a "aws/request.Request" representing the // client's request for the RetryStageExecution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2215,7 +2215,7 @@ const opStartPipelineExecution = "StartPipelineExecution" // StartPipelineExecutionRequest generates a "aws/request.Request" representing the // client's request for the StartPipelineExecution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2298,7 +2298,7 @@ const opUpdatePipeline = "UpdatePipeline" // UpdatePipelineRequest generates a "aws/request.Request" representing the // client's request for the UpdatePipeline operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/cognitoidentity/api.go b/vendor/github.com/aws/aws-sdk-go/service/cognitoidentity/api.go index 399ef91e212a..022ada85fdc8 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/cognitoidentity/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/cognitoidentity/api.go @@ -17,7 +17,7 @@ const opCreateIdentityPool = "CreateIdentityPool" // CreateIdentityPoolRequest generates a "aws/request.Request" representing the // client's request for the CreateIdentityPool operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -126,7 +126,7 @@ const opDeleteIdentities = "DeleteIdentities" // DeleteIdentitiesRequest generates a "aws/request.Request" representing the // client's request for the DeleteIdentities operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -214,7 +214,7 @@ const opDeleteIdentityPool = "DeleteIdentityPool" // DeleteIdentityPoolRequest generates a "aws/request.Request" representing the // client's request for the DeleteIdentityPool operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -311,7 +311,7 @@ const opDescribeIdentity = "DescribeIdentity" // DescribeIdentityRequest generates a "aws/request.Request" representing the // client's request for the DescribeIdentity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -406,7 +406,7 @@ const opDescribeIdentityPool = "DescribeIdentityPool" // DescribeIdentityPoolRequest generates a "aws/request.Request" representing the // client's request for the DescribeIdentityPool operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -501,7 +501,7 @@ const opGetCredentialsForIdentity = "GetCredentialsForIdentity" // GetCredentialsForIdentityRequest generates a "aws/request.Request" representing the // client's request for the GetCredentialsForIdentity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -610,7 +610,7 @@ const opGetId = "GetId" // GetIdRequest generates a "aws/request.Request" representing the // client's request for the GetId operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -716,7 +716,7 @@ const opGetIdentityPoolRoles = "GetIdentityPoolRoles" // GetIdentityPoolRolesRequest generates a "aws/request.Request" representing the // client's request for the GetIdentityPoolRoles operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -814,7 +814,7 @@ const opGetOpenIdToken = "GetOpenIdToken" // GetOpenIdTokenRequest generates a "aws/request.Request" representing the // client's request for the GetOpenIdToken operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -920,7 +920,7 @@ const opGetOpenIdTokenForDeveloperIdentity = "GetOpenIdTokenForDeveloperIdentity // GetOpenIdTokenForDeveloperIdentityRequest generates a "aws/request.Request" representing the // client's request for the GetOpenIdTokenForDeveloperIdentity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1035,7 +1035,7 @@ const opListIdentities = "ListIdentities" // ListIdentitiesRequest generates a "aws/request.Request" representing the // client's request for the ListIdentities operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1129,7 +1129,7 @@ const opListIdentityPools = "ListIdentityPools" // ListIdentityPoolsRequest generates a "aws/request.Request" representing the // client's request for the ListIdentityPools operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1219,7 +1219,7 @@ const opLookupDeveloperIdentity = "LookupDeveloperIdentity" // LookupDeveloperIdentityRequest generates a "aws/request.Request" representing the // client's request for the LookupDeveloperIdentity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1324,7 +1324,7 @@ const opMergeDeveloperIdentities = "MergeDeveloperIdentities" // MergeDeveloperIdentitiesRequest generates a "aws/request.Request" representing the // client's request for the MergeDeveloperIdentities operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1428,7 +1428,7 @@ const opSetIdentityPoolRoles = "SetIdentityPoolRoles" // SetIdentityPoolRolesRequest generates a "aws/request.Request" representing the // client's request for the SetIdentityPoolRoles operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1532,7 +1532,7 @@ const opUnlinkDeveloperIdentity = "UnlinkDeveloperIdentity" // UnlinkDeveloperIdentityRequest generates a "aws/request.Request" representing the // client's request for the UnlinkDeveloperIdentity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1635,7 +1635,7 @@ const opUnlinkIdentity = "UnlinkIdentity" // UnlinkIdentityRequest generates a "aws/request.Request" representing the // client's request for the UnlinkIdentity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1741,7 +1741,7 @@ const opUpdateIdentityPool = "UpdateIdentityPool" // UpdateIdentityPoolRequest generates a "aws/request.Request" representing the // client's request for the UpdateIdentityPool operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/cognitoidentityprovider/api.go b/vendor/github.com/aws/aws-sdk-go/service/cognitoidentityprovider/api.go index 168fe2192dfb..739f5f15a114 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/cognitoidentityprovider/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/cognitoidentityprovider/api.go @@ -18,7 +18,7 @@ const opAddCustomAttributes = "AddCustomAttributes" // AddCustomAttributesRequest generates a "aws/request.Request" representing the // client's request for the AddCustomAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -116,7 +116,7 @@ const opAdminAddUserToGroup = "AdminAddUserToGroup" // AdminAddUserToGroupRequest generates a "aws/request.Request" representing the // client's request for the AdminAddUserToGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -217,7 +217,7 @@ const opAdminConfirmSignUp = "AdminConfirmSignUp" // AdminConfirmSignUpRequest generates a "aws/request.Request" representing the // client's request for the AdminConfirmSignUp operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -337,7 +337,7 @@ const opAdminCreateUser = "AdminCreateUser" // AdminCreateUserRequest generates a "aws/request.Request" representing the // client's request for the AdminCreateUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -488,7 +488,7 @@ const opAdminDeleteUser = "AdminDeleteUser" // AdminDeleteUserRequest generates a "aws/request.Request" representing the // client's request for the AdminDeleteUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -589,7 +589,7 @@ const opAdminDeleteUserAttributes = "AdminDeleteUserAttributes" // AdminDeleteUserAttributesRequest generates a "aws/request.Request" representing the // client's request for the AdminDeleteUserAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -689,7 +689,7 @@ const opAdminDisableProviderForUser = "AdminDisableProviderForUser" // AdminDisableProviderForUserRequest generates a "aws/request.Request" representing the // client's request for the AdminDisableProviderForUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -820,7 +820,7 @@ const opAdminDisableUser = "AdminDisableUser" // AdminDisableUserRequest generates a "aws/request.Request" representing the // client's request for the AdminDisableUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -919,7 +919,7 @@ const opAdminEnableUser = "AdminEnableUser" // AdminEnableUserRequest generates a "aws/request.Request" representing the // client's request for the AdminEnableUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1018,7 +1018,7 @@ const opAdminForgetDevice = "AdminForgetDevice" // AdminForgetDeviceRequest generates a "aws/request.Request" representing the // client's request for the AdminForgetDevice operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1122,7 +1122,7 @@ const opAdminGetDevice = "AdminGetDevice" // AdminGetDeviceRequest generates a "aws/request.Request" representing the // client's request for the AdminGetDevice operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1221,7 +1221,7 @@ const opAdminGetUser = "AdminGetUser" // AdminGetUserRequest generates a "aws/request.Request" representing the // client's request for the AdminGetUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1321,7 +1321,7 @@ const opAdminInitiateAuth = "AdminInitiateAuth" // AdminInitiateAuthRequest generates a "aws/request.Request" representing the // client's request for the AdminInitiateAuth operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1455,7 +1455,7 @@ const opAdminLinkProviderForUser = "AdminLinkProviderForUser" // AdminLinkProviderForUserRequest generates a "aws/request.Request" representing the // client's request for the AdminLinkProviderForUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1576,7 +1576,7 @@ const opAdminListDevices = "AdminListDevices" // AdminListDevicesRequest generates a "aws/request.Request" representing the // client's request for the AdminListDevices operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1675,7 +1675,7 @@ const opAdminListGroupsForUser = "AdminListGroupsForUser" // AdminListGroupsForUserRequest generates a "aws/request.Request" representing the // client's request for the AdminListGroupsForUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1774,7 +1774,7 @@ const opAdminListUserAuthEvents = "AdminListUserAuthEvents" // AdminListUserAuthEventsRequest generates a "aws/request.Request" representing the // client's request for the AdminListUserAuthEvents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1875,7 +1875,7 @@ const opAdminRemoveUserFromGroup = "AdminRemoveUserFromGroup" // AdminRemoveUserFromGroupRequest generates a "aws/request.Request" representing the // client's request for the AdminRemoveUserFromGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1976,7 +1976,7 @@ const opAdminResetUserPassword = "AdminResetUserPassword" // AdminResetUserPasswordRequest generates a "aws/request.Request" representing the // client's request for the AdminResetUserPassword operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2116,7 +2116,7 @@ const opAdminRespondToAuthChallenge = "AdminRespondToAuthChallenge" // AdminRespondToAuthChallengeRequest generates a "aws/request.Request" representing the // client's request for the AdminRespondToAuthChallenge operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2271,7 +2271,7 @@ const opAdminSetUserMFAPreference = "AdminSetUserMFAPreference" // AdminSetUserMFAPreferenceRequest generates a "aws/request.Request" representing the // client's request for the AdminSetUserMFAPreference operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2370,7 +2370,7 @@ const opAdminSetUserSettings = "AdminSetUserSettings" // AdminSetUserSettingsRequest generates a "aws/request.Request" representing the // client's request for the AdminSetUserSettings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2465,7 +2465,7 @@ const opAdminUpdateAuthEventFeedback = "AdminUpdateAuthEventFeedback" // AdminUpdateAuthEventFeedbackRequest generates a "aws/request.Request" representing the // client's request for the AdminUpdateAuthEventFeedback operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2567,7 +2567,7 @@ const opAdminUpdateDeviceStatus = "AdminUpdateDeviceStatus" // AdminUpdateDeviceStatusRequest generates a "aws/request.Request" representing the // client's request for the AdminUpdateDeviceStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2669,7 +2669,7 @@ const opAdminUpdateUserAttributes = "AdminUpdateUserAttributes" // AdminUpdateUserAttributesRequest generates a "aws/request.Request" representing the // client's request for the AdminUpdateUserAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2793,7 +2793,7 @@ const opAdminUserGlobalSignOut = "AdminUserGlobalSignOut" // AdminUserGlobalSignOutRequest generates a "aws/request.Request" representing the // client's request for the AdminUserGlobalSignOut operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2892,7 +2892,7 @@ const opAssociateSoftwareToken = "AssociateSoftwareToken" // AssociateSoftwareTokenRequest generates a "aws/request.Request" representing the // client's request for the AssociateSoftwareToken operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2987,7 +2987,7 @@ const opChangePassword = "ChangePassword" // ChangePasswordRequest generates a "aws/request.Request" representing the // client's request for the ChangePassword operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3099,7 +3099,7 @@ const opConfirmDevice = "ConfirmDevice" // ConfirmDeviceRequest generates a "aws/request.Request" representing the // client's request for the ConfirmDevice operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3218,7 +3218,7 @@ const opConfirmForgotPassword = "ConfirmForgotPassword" // ConfirmForgotPasswordRequest generates a "aws/request.Request" representing the // client's request for the ConfirmForgotPassword operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3350,7 +3350,7 @@ const opConfirmSignUp = "ConfirmSignUp" // ConfirmSignUpRequest generates a "aws/request.Request" representing the // client's request for the ConfirmSignUp operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3482,7 +3482,7 @@ const opCreateGroup = "CreateGroup" // CreateGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3586,7 +3586,7 @@ const opCreateIdentityProvider = "CreateIdentityProvider" // CreateIdentityProviderRequest generates a "aws/request.Request" representing the // client's request for the CreateIdentityProvider operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3688,7 +3688,7 @@ const opCreateResourceServer = "CreateResourceServer" // CreateResourceServerRequest generates a "aws/request.Request" representing the // client's request for the CreateResourceServer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3786,7 +3786,7 @@ const opCreateUserImportJob = "CreateUserImportJob" // CreateUserImportJobRequest generates a "aws/request.Request" representing the // client's request for the CreateUserImportJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3887,7 +3887,7 @@ const opCreateUserPool = "CreateUserPool" // CreateUserPoolRequest generates a "aws/request.Request" representing the // client's request for the CreateUserPool operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3999,7 +3999,7 @@ const opCreateUserPoolClient = "CreateUserPoolClient" // CreateUserPoolClientRequest generates a "aws/request.Request" representing the // client's request for the CreateUserPoolClient operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4103,7 +4103,7 @@ const opCreateUserPoolDomain = "CreateUserPoolDomain" // CreateUserPoolDomainRequest generates a "aws/request.Request" representing the // client's request for the CreateUserPoolDomain operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4193,7 +4193,7 @@ const opDeleteGroup = "DeleteGroup" // DeleteGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4291,7 +4291,7 @@ const opDeleteIdentityProvider = "DeleteIdentityProvider" // DeleteIdentityProviderRequest generates a "aws/request.Request" representing the // client's request for the DeleteIdentityProvider operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4390,7 +4390,7 @@ const opDeleteResourceServer = "DeleteResourceServer" // DeleteResourceServerRequest generates a "aws/request.Request" representing the // client's request for the DeleteResourceServer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4486,7 +4486,7 @@ const opDeleteUser = "DeleteUser" // DeleteUserRequest generates a "aws/request.Request" representing the // client's request for the DeleteUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4592,7 +4592,7 @@ const opDeleteUserAttributes = "DeleteUserAttributes" // DeleteUserAttributesRequest generates a "aws/request.Request" representing the // client's request for the DeleteUserAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4696,7 +4696,7 @@ const opDeleteUserPool = "DeleteUserPool" // DeleteUserPoolRequest generates a "aws/request.Request" representing the // client's request for the DeleteUserPool operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4796,7 +4796,7 @@ const opDeleteUserPoolClient = "DeleteUserPoolClient" // DeleteUserPoolClientRequest generates a "aws/request.Request" representing the // client's request for the DeleteUserPoolClient operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4892,7 +4892,7 @@ const opDeleteUserPoolDomain = "DeleteUserPoolDomain" // DeleteUserPoolDomainRequest generates a "aws/request.Request" representing the // client's request for the DeleteUserPoolDomain operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4982,7 +4982,7 @@ const opDescribeIdentityProvider = "DescribeIdentityProvider" // DescribeIdentityProviderRequest generates a "aws/request.Request" representing the // client's request for the DescribeIdentityProvider operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5076,7 +5076,7 @@ const opDescribeResourceServer = "DescribeResourceServer" // DescribeResourceServerRequest generates a "aws/request.Request" representing the // client's request for the DescribeResourceServer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5170,7 +5170,7 @@ const opDescribeRiskConfiguration = "DescribeRiskConfiguration" // DescribeRiskConfigurationRequest generates a "aws/request.Request" representing the // client's request for the DescribeRiskConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5267,7 +5267,7 @@ const opDescribeUserImportJob = "DescribeUserImportJob" // DescribeUserImportJobRequest generates a "aws/request.Request" representing the // client's request for the DescribeUserImportJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5361,7 +5361,7 @@ const opDescribeUserPool = "DescribeUserPool" // DescribeUserPoolRequest generates a "aws/request.Request" representing the // client's request for the DescribeUserPool operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5459,7 +5459,7 @@ const opDescribeUserPoolClient = "DescribeUserPoolClient" // DescribeUserPoolClientRequest generates a "aws/request.Request" representing the // client's request for the DescribeUserPoolClient operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5554,7 +5554,7 @@ const opDescribeUserPoolDomain = "DescribeUserPoolDomain" // DescribeUserPoolDomainRequest generates a "aws/request.Request" representing the // client's request for the DescribeUserPoolDomain operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5644,7 +5644,7 @@ const opForgetDevice = "ForgetDevice" // ForgetDeviceRequest generates a "aws/request.Request" representing the // client's request for the ForgetDevice operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5752,7 +5752,7 @@ const opForgotPassword = "ForgotPassword" // ForgotPasswordRequest generates a "aws/request.Request" representing the // client's request for the ForgotPassword operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5893,7 +5893,7 @@ const opGetCSVHeader = "GetCSVHeader" // GetCSVHeaderRequest generates a "aws/request.Request" representing the // client's request for the GetCSVHeader operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5988,7 +5988,7 @@ const opGetDevice = "GetDevice" // GetDeviceRequest generates a "aws/request.Request" representing the // client's request for the GetDevice operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6094,7 +6094,7 @@ const opGetGroup = "GetGroup" // GetGroupRequest generates a "aws/request.Request" representing the // client's request for the GetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6190,7 +6190,7 @@ const opGetIdentityProviderByIdentifier = "GetIdentityProviderByIdentifier" // GetIdentityProviderByIdentifierRequest generates a "aws/request.Request" representing the // client's request for the GetIdentityProviderByIdentifier operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6284,7 +6284,7 @@ const opGetSigningCertificate = "GetSigningCertificate" // GetSigningCertificateRequest generates a "aws/request.Request" representing the // client's request for the GetSigningCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6367,7 +6367,7 @@ const opGetUICustomization = "GetUICustomization" // GetUICustomizationRequest generates a "aws/request.Request" representing the // client's request for the GetUICustomization operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6464,7 +6464,7 @@ const opGetUser = "GetUser" // GetUserRequest generates a "aws/request.Request" representing the // client's request for the GetUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6568,7 +6568,7 @@ const opGetUserAttributeVerificationCode = "GetUserAttributeVerificationCode" // GetUserAttributeVerificationCodeRequest generates a "aws/request.Request" representing the // client's request for the GetUserAttributeVerificationCode operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6705,7 +6705,7 @@ const opGetUserPoolMfaConfig = "GetUserPoolMfaConfig" // GetUserPoolMfaConfigRequest generates a "aws/request.Request" representing the // client's request for the GetUserPoolMfaConfig operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6799,7 +6799,7 @@ const opGlobalSignOut = "GlobalSignOut" // GlobalSignOutRequest generates a "aws/request.Request" representing the // client's request for the GlobalSignOut operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6899,7 +6899,7 @@ const opInitiateAuth = "InitiateAuth" // InitiateAuthRequest generates a "aws/request.Request" representing the // client's request for the InitiateAuth operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7017,7 +7017,7 @@ const opListDevices = "ListDevices" // ListDevicesRequest generates a "aws/request.Request" representing the // client's request for the ListDevices operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7123,7 +7123,7 @@ const opListGroups = "ListGroups" // ListGroupsRequest generates a "aws/request.Request" representing the // client's request for the ListGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7219,7 +7219,7 @@ const opListIdentityProviders = "ListIdentityProviders" // ListIdentityProvidersRequest generates a "aws/request.Request" representing the // client's request for the ListIdentityProviders operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7313,7 +7313,7 @@ const opListResourceServers = "ListResourceServers" // ListResourceServersRequest generates a "aws/request.Request" representing the // client's request for the ListResourceServers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7407,7 +7407,7 @@ const opListUserImportJobs = "ListUserImportJobs" // ListUserImportJobsRequest generates a "aws/request.Request" representing the // client's request for the ListUserImportJobs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7501,7 +7501,7 @@ const opListUserPoolClients = "ListUserPoolClients" // ListUserPoolClientsRequest generates a "aws/request.Request" representing the // client's request for the ListUserPoolClients operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7595,7 +7595,7 @@ const opListUserPools = "ListUserPools" // ListUserPoolsRequest generates a "aws/request.Request" representing the // client's request for the ListUserPools operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7685,7 +7685,7 @@ const opListUsers = "ListUsers" // ListUsersRequest generates a "aws/request.Request" representing the // client's request for the ListUsers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7779,7 +7779,7 @@ const opListUsersInGroup = "ListUsersInGroup" // ListUsersInGroupRequest generates a "aws/request.Request" representing the // client's request for the ListUsersInGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7875,7 +7875,7 @@ const opResendConfirmationCode = "ResendConfirmationCode" // ResendConfirmationCodeRequest generates a "aws/request.Request" representing the // client's request for the ResendConfirmationCode operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8007,7 +8007,7 @@ const opRespondToAuthChallenge = "RespondToAuthChallenge" // RespondToAuthChallengeRequest generates a "aws/request.Request" representing the // client's request for the RespondToAuthChallenge operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8160,7 +8160,7 @@ const opSetRiskConfiguration = "SetRiskConfiguration" // SetRiskConfigurationRequest generates a "aws/request.Request" representing the // client's request for the SetRiskConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8270,7 +8270,7 @@ const opSetUICustomization = "SetUICustomization" // SetUICustomizationRequest generates a "aws/request.Request" representing the // client's request for the SetUICustomization operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8375,7 +8375,7 @@ const opSetUserMFAPreference = "SetUserMFAPreference" // SetUserMFAPreferenceRequest generates a "aws/request.Request" representing the // client's request for the SetUserMFAPreference operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8474,7 +8474,7 @@ const opSetUserPoolMfaConfig = "SetUserPoolMfaConfig" // SetUserPoolMfaConfigRequest generates a "aws/request.Request" representing the // client's request for the SetUserPoolMfaConfig operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8578,7 +8578,7 @@ const opSetUserSettings = "SetUserSettings" // SetUserSettingsRequest generates a "aws/request.Request" representing the // client's request for the SetUserSettings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8680,7 +8680,7 @@ const opSignUp = "SignUp" // SignUpRequest generates a "aws/request.Request" representing the // client's request for the SignUp operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8813,7 +8813,7 @@ const opStartUserImportJob = "StartUserImportJob" // StartUserImportJobRequest generates a "aws/request.Request" representing the // client's request for the StartUserImportJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8910,7 +8910,7 @@ const opStopUserImportJob = "StopUserImportJob" // StopUserImportJobRequest generates a "aws/request.Request" representing the // client's request for the StopUserImportJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9007,7 +9007,7 @@ const opUpdateAuthEventFeedback = "UpdateAuthEventFeedback" // UpdateAuthEventFeedbackRequest generates a "aws/request.Request" representing the // client's request for the UpdateAuthEventFeedback operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9109,7 +9109,7 @@ const opUpdateDeviceStatus = "UpdateDeviceStatus" // UpdateDeviceStatusRequest generates a "aws/request.Request" representing the // client's request for the UpdateDeviceStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9215,7 +9215,7 @@ const opUpdateGroup = "UpdateGroup" // UpdateGroupRequest generates a "aws/request.Request" representing the // client's request for the UpdateGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9311,7 +9311,7 @@ const opUpdateIdentityProvider = "UpdateIdentityProvider" // UpdateIdentityProviderRequest generates a "aws/request.Request" representing the // client's request for the UpdateIdentityProvider operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9408,7 +9408,7 @@ const opUpdateResourceServer = "UpdateResourceServer" // UpdateResourceServerRequest generates a "aws/request.Request" representing the // client's request for the UpdateResourceServer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9502,7 +9502,7 @@ const opUpdateUserAttributes = "UpdateUserAttributes" // UpdateUserAttributesRequest generates a "aws/request.Request" representing the // client's request for the UpdateUserAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9648,7 +9648,7 @@ const opUpdateUserPool = "UpdateUserPool" // UpdateUserPoolRequest generates a "aws/request.Request" representing the // client's request for the UpdateUserPool operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9766,7 +9766,7 @@ const opUpdateUserPoolClient = "UpdateUserPoolClient" // UpdateUserPoolClientRequest generates a "aws/request.Request" representing the // client's request for the UpdateUserPoolClient operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9870,7 +9870,7 @@ const opVerifySoftwareToken = "VerifySoftwareToken" // VerifySoftwareTokenRequest generates a "aws/request.Request" representing the // client's request for the VerifySoftwareToken operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9992,7 +9992,7 @@ const opVerifyUserAttribute = "VerifyUserAttribute" // VerifyUserAttributeRequest generates a "aws/request.Request" representing the // client's request for the VerifyUserAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/configservice/api.go b/vendor/github.com/aws/aws-sdk-go/service/configservice/api.go index 8999640f5380..56e5192db707 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/configservice/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/configservice/api.go @@ -13,11 +13,185 @@ import ( "github.com/aws/aws-sdk-go/private/protocol/jsonrpc" ) +const opBatchGetResourceConfig = "BatchGetResourceConfig" + +// BatchGetResourceConfigRequest generates a "aws/request.Request" representing the +// client's request for the BatchGetResourceConfig operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See BatchGetResourceConfig for more information on using the BatchGetResourceConfig +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the BatchGetResourceConfigRequest method. +// req, resp := client.BatchGetResourceConfigRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/BatchGetResourceConfig +func (c *ConfigService) BatchGetResourceConfigRequest(input *BatchGetResourceConfigInput) (req *request.Request, output *BatchGetResourceConfigOutput) { + op := &request.Operation{ + Name: opBatchGetResourceConfig, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &BatchGetResourceConfigInput{} + } + + output = &BatchGetResourceConfigOutput{} + req = c.newRequest(op, input, output) + return +} + +// BatchGetResourceConfig API operation for AWS Config. +// +// Returns the current configuration for one or more requested resources. The +// operation also returns a list of resources that are not processed in the +// current request. If there are no unprocessed resources, the operation returns +// an empty unprocessedResourceKeys list. +// +// The API does not return results for deleted resources. +// +// The API does not return any tags for the requested resources. This information +// is filtered out of the supplementaryConfiguration section of the API response. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Config's +// API operation BatchGetResourceConfig for usage and error information. +// +// Returned Error Codes: +// * ErrCodeValidationException "ValidationException" +// The requested action is not valid. +// +// * ErrCodeNoAvailableConfigurationRecorderException "NoAvailableConfigurationRecorderException" +// There are no configuration recorders available to provide the role needed +// to describe your resources. Create a configuration recorder. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/BatchGetResourceConfig +func (c *ConfigService) BatchGetResourceConfig(input *BatchGetResourceConfigInput) (*BatchGetResourceConfigOutput, error) { + req, out := c.BatchGetResourceConfigRequest(input) + return out, req.Send() +} + +// BatchGetResourceConfigWithContext is the same as BatchGetResourceConfig with the addition of +// the ability to pass a context and additional request options. +// +// See BatchGetResourceConfig for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ConfigService) BatchGetResourceConfigWithContext(ctx aws.Context, input *BatchGetResourceConfigInput, opts ...request.Option) (*BatchGetResourceConfigOutput, error) { + req, out := c.BatchGetResourceConfigRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeleteAggregationAuthorization = "DeleteAggregationAuthorization" + +// DeleteAggregationAuthorizationRequest generates a "aws/request.Request" representing the +// client's request for the DeleteAggregationAuthorization operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteAggregationAuthorization for more information on using the DeleteAggregationAuthorization +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteAggregationAuthorizationRequest method. +// req, resp := client.DeleteAggregationAuthorizationRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DeleteAggregationAuthorization +func (c *ConfigService) DeleteAggregationAuthorizationRequest(input *DeleteAggregationAuthorizationInput) (req *request.Request, output *DeleteAggregationAuthorizationOutput) { + op := &request.Operation{ + Name: opDeleteAggregationAuthorization, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DeleteAggregationAuthorizationInput{} + } + + output = &DeleteAggregationAuthorizationOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeleteAggregationAuthorization API operation for AWS Config. +// +// Deletes the authorization granted to the specified configuration aggregator +// account in a specified region. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Config's +// API operation DeleteAggregationAuthorization for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" +// One or more of the specified parameters are invalid. Verify that your parameters +// are valid and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DeleteAggregationAuthorization +func (c *ConfigService) DeleteAggregationAuthorization(input *DeleteAggregationAuthorizationInput) (*DeleteAggregationAuthorizationOutput, error) { + req, out := c.DeleteAggregationAuthorizationRequest(input) + return out, req.Send() +} + +// DeleteAggregationAuthorizationWithContext is the same as DeleteAggregationAuthorization with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteAggregationAuthorization for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ConfigService) DeleteAggregationAuthorizationWithContext(ctx aws.Context, input *DeleteAggregationAuthorizationInput, opts ...request.Option) (*DeleteAggregationAuthorizationOutput, error) { + req, out := c.DeleteAggregationAuthorizationRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opDeleteConfigRule = "DeleteConfigRule" // DeleteConfigRuleRequest generates a "aws/request.Request" representing the // client's request for the DeleteConfigRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -105,11 +279,93 @@ func (c *ConfigService) DeleteConfigRuleWithContext(ctx aws.Context, input *Dele return out, req.Send() } +const opDeleteConfigurationAggregator = "DeleteConfigurationAggregator" + +// DeleteConfigurationAggregatorRequest generates a "aws/request.Request" representing the +// client's request for the DeleteConfigurationAggregator operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteConfigurationAggregator for more information on using the DeleteConfigurationAggregator +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteConfigurationAggregatorRequest method. +// req, resp := client.DeleteConfigurationAggregatorRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DeleteConfigurationAggregator +func (c *ConfigService) DeleteConfigurationAggregatorRequest(input *DeleteConfigurationAggregatorInput) (req *request.Request, output *DeleteConfigurationAggregatorOutput) { + op := &request.Operation{ + Name: opDeleteConfigurationAggregator, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DeleteConfigurationAggregatorInput{} + } + + output = &DeleteConfigurationAggregatorOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeleteConfigurationAggregator API operation for AWS Config. +// +// Deletes the specified configuration aggregator and the aggregated data associated +// with the aggregator. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Config's +// API operation DeleteConfigurationAggregator for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNoSuchConfigurationAggregatorException "NoSuchConfigurationAggregatorException" +// You have specified a configuration aggregator that does not exist. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DeleteConfigurationAggregator +func (c *ConfigService) DeleteConfigurationAggregator(input *DeleteConfigurationAggregatorInput) (*DeleteConfigurationAggregatorOutput, error) { + req, out := c.DeleteConfigurationAggregatorRequest(input) + return out, req.Send() +} + +// DeleteConfigurationAggregatorWithContext is the same as DeleteConfigurationAggregator with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteConfigurationAggregator for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ConfigService) DeleteConfigurationAggregatorWithContext(ctx aws.Context, input *DeleteConfigurationAggregatorInput, opts ...request.Option) (*DeleteConfigurationAggregatorOutput, error) { + req, out := c.DeleteConfigurationAggregatorRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opDeleteConfigurationRecorder = "DeleteConfigurationRecorder" // DeleteConfigurationRecorderRequest generates a "aws/request.Request" representing the // client's request for the DeleteConfigurationRecorder operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -199,7 +455,7 @@ const opDeleteDeliveryChannel = "DeleteDeliveryChannel" // DeleteDeliveryChannelRequest generates a "aws/request.Request" representing the // client's request for the DeleteDeliveryChannel operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -287,7 +543,7 @@ const opDeleteEvaluationResults = "DeleteEvaluationResults" // DeleteEvaluationResultsRequest generates a "aws/request.Request" representing the // client's request for the DeleteEvaluationResults operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -327,10 +583,10 @@ func (c *ConfigService) DeleteEvaluationResultsRequest(input *DeleteEvaluationRe // DeleteEvaluationResults API operation for AWS Config. // -// Deletes the evaluation results for the specified Config rule. You can specify -// one Config rule per request. After you delete the evaluation results, you -// can call the StartConfigRulesEvaluation API to start evaluating your AWS -// resources against the rule. +// Deletes the evaluation results for the specified AWS Config rule. You can +// specify one AWS Config rule per request. After you delete the evaluation +// results, you can call the StartConfigRulesEvaluation API to start evaluating +// your AWS resources against the rule. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -370,11 +626,94 @@ func (c *ConfigService) DeleteEvaluationResultsWithContext(ctx aws.Context, inpu return out, req.Send() } +const opDeletePendingAggregationRequest = "DeletePendingAggregationRequest" + +// DeletePendingAggregationRequestRequest generates a "aws/request.Request" representing the +// client's request for the DeletePendingAggregationRequest operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeletePendingAggregationRequest for more information on using the DeletePendingAggregationRequest +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeletePendingAggregationRequestRequest method. +// req, resp := client.DeletePendingAggregationRequestRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DeletePendingAggregationRequest +func (c *ConfigService) DeletePendingAggregationRequestRequest(input *DeletePendingAggregationRequestInput) (req *request.Request, output *DeletePendingAggregationRequestOutput) { + op := &request.Operation{ + Name: opDeletePendingAggregationRequest, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DeletePendingAggregationRequestInput{} + } + + output = &DeletePendingAggregationRequestOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeletePendingAggregationRequest API operation for AWS Config. +// +// Deletes pending authorization requests for a specified aggregator account +// in a specified region. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Config's +// API operation DeletePendingAggregationRequest for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" +// One or more of the specified parameters are invalid. Verify that your parameters +// are valid and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DeletePendingAggregationRequest +func (c *ConfigService) DeletePendingAggregationRequest(input *DeletePendingAggregationRequestInput) (*DeletePendingAggregationRequestOutput, error) { + req, out := c.DeletePendingAggregationRequestRequest(input) + return out, req.Send() +} + +// DeletePendingAggregationRequestWithContext is the same as DeletePendingAggregationRequest with the addition of +// the ability to pass a context and additional request options. +// +// See DeletePendingAggregationRequest for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ConfigService) DeletePendingAggregationRequestWithContext(ctx aws.Context, input *DeletePendingAggregationRequestInput, opts ...request.Option) (*DeletePendingAggregationRequestOutput, error) { + req, out := c.DeletePendingAggregationRequestRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opDeliverConfigSnapshot = "DeliverConfigSnapshot" // DeliverConfigSnapshotRequest generates a "aws/request.Request" representing the // client's request for the DeliverConfigSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -416,14 +755,15 @@ func (c *ConfigService) DeliverConfigSnapshotRequest(input *DeliverConfigSnapsho // // Schedules delivery of a configuration snapshot to the Amazon S3 bucket in // the specified delivery channel. After the delivery has started, AWS Config -// sends following notifications using an Amazon SNS topic that you have specified. +// sends the following notifications using an Amazon SNS topic that you have +// specified. // -// * Notification of starting the delivery. +// * Notification of the start of the delivery. // -// * Notification of delivery completed, if the delivery was successfully -// completed. +// * Notification of the completion of the delivery, if the delivery was +// successfully completed. // -// * Notification of delivery failure, if the delivery failed to complete. +// * Notification of delivery failure, if the delivery failed. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -465,58 +805,239 @@ func (c *ConfigService) DeliverConfigSnapshotWithContext(ctx aws.Context, input return out, req.Send() } -const opDescribeComplianceByConfigRule = "DescribeComplianceByConfigRule" +const opDescribeAggregateComplianceByConfigRules = "DescribeAggregateComplianceByConfigRules" -// DescribeComplianceByConfigRuleRequest generates a "aws/request.Request" representing the -// client's request for the DescribeComplianceByConfigRule operation. The "output" return -// value will be populated with the request's response once the request complets +// DescribeAggregateComplianceByConfigRulesRequest generates a "aws/request.Request" representing the +// client's request for the DescribeAggregateComplianceByConfigRules operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See DescribeComplianceByConfigRule for more information on using the DescribeComplianceByConfigRule +// See DescribeAggregateComplianceByConfigRules for more information on using the DescribeAggregateComplianceByConfigRules // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the DescribeComplianceByConfigRuleRequest method. -// req, resp := client.DescribeComplianceByConfigRuleRequest(params) +// // Example sending a request using the DescribeAggregateComplianceByConfigRulesRequest method. +// req, resp := client.DescribeAggregateComplianceByConfigRulesRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeComplianceByConfigRule -func (c *ConfigService) DescribeComplianceByConfigRuleRequest(input *DescribeComplianceByConfigRuleInput) (req *request.Request, output *DescribeComplianceByConfigRuleOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeAggregateComplianceByConfigRules +func (c *ConfigService) DescribeAggregateComplianceByConfigRulesRequest(input *DescribeAggregateComplianceByConfigRulesInput) (req *request.Request, output *DescribeAggregateComplianceByConfigRulesOutput) { op := &request.Operation{ - Name: opDescribeComplianceByConfigRule, + Name: opDescribeAggregateComplianceByConfigRules, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &DescribeComplianceByConfigRuleInput{} + input = &DescribeAggregateComplianceByConfigRulesInput{} } - output = &DescribeComplianceByConfigRuleOutput{} + output = &DescribeAggregateComplianceByConfigRulesOutput{} req = c.newRequest(op, input, output) return } -// DescribeComplianceByConfigRule API operation for AWS Config. +// DescribeAggregateComplianceByConfigRules API operation for AWS Config. // -// Indicates whether the specified AWS Config rules are compliant. If a rule -// is noncompliant, this action returns the number of AWS resources that do -// not comply with the rule. +// Returns a list of compliant and noncompliant rules with the number of resources +// for compliant and noncompliant rules. // -// A rule is compliant if all of the evaluated resources comply with it, and -// it is noncompliant if any of these resources do not comply. +// The results can return an empty result page, but if you have a nextToken, +// the results are displayed on the next page. // -// If AWS Config has no current evaluation results for the rule, it returns +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Config's +// API operation DescribeAggregateComplianceByConfigRules for usage and error information. +// +// Returned Error Codes: +// * ErrCodeValidationException "ValidationException" +// The requested action is not valid. +// +// * ErrCodeInvalidLimitException "InvalidLimitException" +// The specified limit is outside the allowable range. +// +// * ErrCodeInvalidNextTokenException "InvalidNextTokenException" +// The specified next token is invalid. Specify the nextToken string that was +// returned in the previous response to get the next page of results. +// +// * ErrCodeNoSuchConfigurationAggregatorException "NoSuchConfigurationAggregatorException" +// You have specified a configuration aggregator that does not exist. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeAggregateComplianceByConfigRules +func (c *ConfigService) DescribeAggregateComplianceByConfigRules(input *DescribeAggregateComplianceByConfigRulesInput) (*DescribeAggregateComplianceByConfigRulesOutput, error) { + req, out := c.DescribeAggregateComplianceByConfigRulesRequest(input) + return out, req.Send() +} + +// DescribeAggregateComplianceByConfigRulesWithContext is the same as DescribeAggregateComplianceByConfigRules with the addition of +// the ability to pass a context and additional request options. +// +// See DescribeAggregateComplianceByConfigRules for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ConfigService) DescribeAggregateComplianceByConfigRulesWithContext(ctx aws.Context, input *DescribeAggregateComplianceByConfigRulesInput, opts ...request.Option) (*DescribeAggregateComplianceByConfigRulesOutput, error) { + req, out := c.DescribeAggregateComplianceByConfigRulesRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDescribeAggregationAuthorizations = "DescribeAggregationAuthorizations" + +// DescribeAggregationAuthorizationsRequest generates a "aws/request.Request" representing the +// client's request for the DescribeAggregationAuthorizations operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DescribeAggregationAuthorizations for more information on using the DescribeAggregationAuthorizations +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DescribeAggregationAuthorizationsRequest method. +// req, resp := client.DescribeAggregationAuthorizationsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeAggregationAuthorizations +func (c *ConfigService) DescribeAggregationAuthorizationsRequest(input *DescribeAggregationAuthorizationsInput) (req *request.Request, output *DescribeAggregationAuthorizationsOutput) { + op := &request.Operation{ + Name: opDescribeAggregationAuthorizations, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DescribeAggregationAuthorizationsInput{} + } + + output = &DescribeAggregationAuthorizationsOutput{} + req = c.newRequest(op, input, output) + return +} + +// DescribeAggregationAuthorizations API operation for AWS Config. +// +// Returns a list of authorizations granted to various aggregator accounts and +// regions. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Config's +// API operation DescribeAggregationAuthorizations for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" +// One or more of the specified parameters are invalid. Verify that your parameters +// are valid and try again. +// +// * ErrCodeInvalidNextTokenException "InvalidNextTokenException" +// The specified next token is invalid. Specify the nextToken string that was +// returned in the previous response to get the next page of results. +// +// * ErrCodeInvalidLimitException "InvalidLimitException" +// The specified limit is outside the allowable range. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeAggregationAuthorizations +func (c *ConfigService) DescribeAggregationAuthorizations(input *DescribeAggregationAuthorizationsInput) (*DescribeAggregationAuthorizationsOutput, error) { + req, out := c.DescribeAggregationAuthorizationsRequest(input) + return out, req.Send() +} + +// DescribeAggregationAuthorizationsWithContext is the same as DescribeAggregationAuthorizations with the addition of +// the ability to pass a context and additional request options. +// +// See DescribeAggregationAuthorizations for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ConfigService) DescribeAggregationAuthorizationsWithContext(ctx aws.Context, input *DescribeAggregationAuthorizationsInput, opts ...request.Option) (*DescribeAggregationAuthorizationsOutput, error) { + req, out := c.DescribeAggregationAuthorizationsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDescribeComplianceByConfigRule = "DescribeComplianceByConfigRule" + +// DescribeComplianceByConfigRuleRequest generates a "aws/request.Request" representing the +// client's request for the DescribeComplianceByConfigRule operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DescribeComplianceByConfigRule for more information on using the DescribeComplianceByConfigRule +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DescribeComplianceByConfigRuleRequest method. +// req, resp := client.DescribeComplianceByConfigRuleRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeComplianceByConfigRule +func (c *ConfigService) DescribeComplianceByConfigRuleRequest(input *DescribeComplianceByConfigRuleInput) (req *request.Request, output *DescribeComplianceByConfigRuleOutput) { + op := &request.Operation{ + Name: opDescribeComplianceByConfigRule, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DescribeComplianceByConfigRuleInput{} + } + + output = &DescribeComplianceByConfigRuleOutput{} + req = c.newRequest(op, input, output) + return +} + +// DescribeComplianceByConfigRule API operation for AWS Config. +// +// Indicates whether the specified AWS Config rules are compliant. If a rule +// is noncompliant, this action returns the number of AWS resources that do +// not comply with the rule. +// +// A rule is compliant if all of the evaluated resources comply with it. It +// is noncompliant if any of these resources do not comply. +// +// If AWS Config has no current evaluation results for the rule, it returns // INSUFFICIENT_DATA. This result might indicate one of the following conditions: // // * AWS Config has never invoked an evaluation for the rule. To check whether @@ -524,7 +1045,7 @@ func (c *ConfigService) DescribeComplianceByConfigRuleRequest(input *DescribeCom // and LastFailedInvocationTime. // // * The rule's AWS Lambda function is failing to send evaluation results -// to AWS Config. Verify that the role that you assigned to your configuration +// to AWS Config. Verify that the role you assigned to your configuration // recorder includes the config:PutEvaluations permission. If the rule is // a custom rule, verify that the AWS Lambda execution role includes the // config:PutEvaluations permission. @@ -550,7 +1071,7 @@ func (c *ConfigService) DescribeComplianceByConfigRuleRequest(input *DescribeCom // rule names are correct and try again. // // * ErrCodeInvalidNextTokenException "InvalidNextTokenException" -// The specified next token is invalid. Specify the NextToken string that was +// The specified next token is invalid. Specify the nextToken string that was // returned in the previous response to get the next page of results. // // See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeComplianceByConfigRule @@ -579,7 +1100,7 @@ const opDescribeComplianceByResource = "DescribeComplianceByResource" // DescribeComplianceByResourceRequest generates a "aws/request.Request" representing the // client's request for the DescribeComplianceByResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -658,7 +1179,7 @@ func (c *ConfigService) DescribeComplianceByResourceRequest(input *DescribeCompl // are valid and try again. // // * ErrCodeInvalidNextTokenException "InvalidNextTokenException" -// The specified next token is invalid. Specify the NextToken string that was +// The specified next token is invalid. Specify the nextToken string that was // returned in the previous response to get the next page of results. // // See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeComplianceByResource @@ -687,7 +1208,7 @@ const opDescribeConfigRuleEvaluationStatus = "DescribeConfigRuleEvaluationStatus // DescribeConfigRuleEvaluationStatusRequest generates a "aws/request.Request" representing the // client's request for the DescribeConfigRuleEvaluationStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -749,7 +1270,7 @@ func (c *ConfigService) DescribeConfigRuleEvaluationStatusRequest(input *Describ // are valid and try again. // // * ErrCodeInvalidNextTokenException "InvalidNextTokenException" -// The specified next token is invalid. Specify the NextToken string that was +// The specified next token is invalid. Specify the nextToken string that was // returned in the previous response to get the next page of results. // // See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeConfigRuleEvaluationStatus @@ -778,7 +1299,7 @@ const opDescribeConfigRules = "DescribeConfigRules" // DescribeConfigRulesRequest generates a "aws/request.Request" representing the // client's request for the DescribeConfigRules operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -833,7 +1354,7 @@ func (c *ConfigService) DescribeConfigRulesRequest(input *DescribeConfigRulesInp // rule names are correct and try again. // // * ErrCodeInvalidNextTokenException "InvalidNextTokenException" -// The specified next token is invalid. Specify the NextToken string that was +// The specified next token is invalid. Specify the nextToken string that was // returned in the previous response to get the next page of results. // // See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeConfigRules @@ -858,754 +1379,763 @@ func (c *ConfigService) DescribeConfigRulesWithContext(ctx aws.Context, input *D return out, req.Send() } -const opDescribeConfigurationRecorderStatus = "DescribeConfigurationRecorderStatus" +const opDescribeConfigurationAggregatorSourcesStatus = "DescribeConfigurationAggregatorSourcesStatus" -// DescribeConfigurationRecorderStatusRequest generates a "aws/request.Request" representing the -// client's request for the DescribeConfigurationRecorderStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// DescribeConfigurationAggregatorSourcesStatusRequest generates a "aws/request.Request" representing the +// client's request for the DescribeConfigurationAggregatorSourcesStatus operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See DescribeConfigurationRecorderStatus for more information on using the DescribeConfigurationRecorderStatus +// See DescribeConfigurationAggregatorSourcesStatus for more information on using the DescribeConfigurationAggregatorSourcesStatus // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the DescribeConfigurationRecorderStatusRequest method. -// req, resp := client.DescribeConfigurationRecorderStatusRequest(params) +// // Example sending a request using the DescribeConfigurationAggregatorSourcesStatusRequest method. +// req, resp := client.DescribeConfigurationAggregatorSourcesStatusRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeConfigurationRecorderStatus -func (c *ConfigService) DescribeConfigurationRecorderStatusRequest(input *DescribeConfigurationRecorderStatusInput) (req *request.Request, output *DescribeConfigurationRecorderStatusOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeConfigurationAggregatorSourcesStatus +func (c *ConfigService) DescribeConfigurationAggregatorSourcesStatusRequest(input *DescribeConfigurationAggregatorSourcesStatusInput) (req *request.Request, output *DescribeConfigurationAggregatorSourcesStatusOutput) { op := &request.Operation{ - Name: opDescribeConfigurationRecorderStatus, + Name: opDescribeConfigurationAggregatorSourcesStatus, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &DescribeConfigurationRecorderStatusInput{} + input = &DescribeConfigurationAggregatorSourcesStatusInput{} } - output = &DescribeConfigurationRecorderStatusOutput{} + output = &DescribeConfigurationAggregatorSourcesStatusOutput{} req = c.newRequest(op, input, output) return } -// DescribeConfigurationRecorderStatus API operation for AWS Config. -// -// Returns the current status of the specified configuration recorder. If a -// configuration recorder is not specified, this action returns the status of -// all configuration recorder associated with the account. +// DescribeConfigurationAggregatorSourcesStatus API operation for AWS Config. // -// Currently, you can specify only one configuration recorder per region in -// your account. +// Returns status information for sources within an aggregator. The status includes +// information about the last time AWS Config aggregated data from source accounts +// or AWS Config failed to aggregate data from source accounts with the related +// error code or message. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Config's -// API operation DescribeConfigurationRecorderStatus for usage and error information. +// API operation DescribeConfigurationAggregatorSourcesStatus for usage and error information. // // Returned Error Codes: -// * ErrCodeNoSuchConfigurationRecorderException "NoSuchConfigurationRecorderException" -// You have specified a configuration recorder that does not exist. +// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" +// One or more of the specified parameters are invalid. Verify that your parameters +// are valid and try again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeConfigurationRecorderStatus -func (c *ConfigService) DescribeConfigurationRecorderStatus(input *DescribeConfigurationRecorderStatusInput) (*DescribeConfigurationRecorderStatusOutput, error) { - req, out := c.DescribeConfigurationRecorderStatusRequest(input) +// * ErrCodeNoSuchConfigurationAggregatorException "NoSuchConfigurationAggregatorException" +// You have specified a configuration aggregator that does not exist. +// +// * ErrCodeInvalidNextTokenException "InvalidNextTokenException" +// The specified next token is invalid. Specify the nextToken string that was +// returned in the previous response to get the next page of results. +// +// * ErrCodeInvalidLimitException "InvalidLimitException" +// The specified limit is outside the allowable range. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeConfigurationAggregatorSourcesStatus +func (c *ConfigService) DescribeConfigurationAggregatorSourcesStatus(input *DescribeConfigurationAggregatorSourcesStatusInput) (*DescribeConfigurationAggregatorSourcesStatusOutput, error) { + req, out := c.DescribeConfigurationAggregatorSourcesStatusRequest(input) return out, req.Send() } -// DescribeConfigurationRecorderStatusWithContext is the same as DescribeConfigurationRecorderStatus with the addition of +// DescribeConfigurationAggregatorSourcesStatusWithContext is the same as DescribeConfigurationAggregatorSourcesStatus with the addition of // the ability to pass a context and additional request options. // -// See DescribeConfigurationRecorderStatus for details on how to use this API operation. +// See DescribeConfigurationAggregatorSourcesStatus for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *ConfigService) DescribeConfigurationRecorderStatusWithContext(ctx aws.Context, input *DescribeConfigurationRecorderStatusInput, opts ...request.Option) (*DescribeConfigurationRecorderStatusOutput, error) { - req, out := c.DescribeConfigurationRecorderStatusRequest(input) +func (c *ConfigService) DescribeConfigurationAggregatorSourcesStatusWithContext(ctx aws.Context, input *DescribeConfigurationAggregatorSourcesStatusInput, opts ...request.Option) (*DescribeConfigurationAggregatorSourcesStatusOutput, error) { + req, out := c.DescribeConfigurationAggregatorSourcesStatusRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opDescribeConfigurationRecorders = "DescribeConfigurationRecorders" +const opDescribeConfigurationAggregators = "DescribeConfigurationAggregators" -// DescribeConfigurationRecordersRequest generates a "aws/request.Request" representing the -// client's request for the DescribeConfigurationRecorders operation. The "output" return -// value will be populated with the request's response once the request complets +// DescribeConfigurationAggregatorsRequest generates a "aws/request.Request" representing the +// client's request for the DescribeConfigurationAggregators operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See DescribeConfigurationRecorders for more information on using the DescribeConfigurationRecorders +// See DescribeConfigurationAggregators for more information on using the DescribeConfigurationAggregators // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the DescribeConfigurationRecordersRequest method. -// req, resp := client.DescribeConfigurationRecordersRequest(params) +// // Example sending a request using the DescribeConfigurationAggregatorsRequest method. +// req, resp := client.DescribeConfigurationAggregatorsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeConfigurationRecorders -func (c *ConfigService) DescribeConfigurationRecordersRequest(input *DescribeConfigurationRecordersInput) (req *request.Request, output *DescribeConfigurationRecordersOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeConfigurationAggregators +func (c *ConfigService) DescribeConfigurationAggregatorsRequest(input *DescribeConfigurationAggregatorsInput) (req *request.Request, output *DescribeConfigurationAggregatorsOutput) { op := &request.Operation{ - Name: opDescribeConfigurationRecorders, + Name: opDescribeConfigurationAggregators, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &DescribeConfigurationRecordersInput{} + input = &DescribeConfigurationAggregatorsInput{} } - output = &DescribeConfigurationRecordersOutput{} + output = &DescribeConfigurationAggregatorsOutput{} req = c.newRequest(op, input, output) return } -// DescribeConfigurationRecorders API operation for AWS Config. -// -// Returns the details for the specified configuration recorders. If the configuration -// recorder is not specified, this action returns the details for all configuration -// recorders associated with the account. +// DescribeConfigurationAggregators API operation for AWS Config. // -// Currently, you can specify only one configuration recorder per region in -// your account. +// Returns the details of one or more configuration aggregators. If the configuration +// aggregator is not specified, this action returns the details for all the +// configuration aggregators associated with the account. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Config's -// API operation DescribeConfigurationRecorders for usage and error information. +// API operation DescribeConfigurationAggregators for usage and error information. // // Returned Error Codes: -// * ErrCodeNoSuchConfigurationRecorderException "NoSuchConfigurationRecorderException" -// You have specified a configuration recorder that does not exist. +// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" +// One or more of the specified parameters are invalid. Verify that your parameters +// are valid and try again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeConfigurationRecorders -func (c *ConfigService) DescribeConfigurationRecorders(input *DescribeConfigurationRecordersInput) (*DescribeConfigurationRecordersOutput, error) { - req, out := c.DescribeConfigurationRecordersRequest(input) +// * ErrCodeNoSuchConfigurationAggregatorException "NoSuchConfigurationAggregatorException" +// You have specified a configuration aggregator that does not exist. +// +// * ErrCodeInvalidNextTokenException "InvalidNextTokenException" +// The specified next token is invalid. Specify the nextToken string that was +// returned in the previous response to get the next page of results. +// +// * ErrCodeInvalidLimitException "InvalidLimitException" +// The specified limit is outside the allowable range. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeConfigurationAggregators +func (c *ConfigService) DescribeConfigurationAggregators(input *DescribeConfigurationAggregatorsInput) (*DescribeConfigurationAggregatorsOutput, error) { + req, out := c.DescribeConfigurationAggregatorsRequest(input) return out, req.Send() } -// DescribeConfigurationRecordersWithContext is the same as DescribeConfigurationRecorders with the addition of +// DescribeConfigurationAggregatorsWithContext is the same as DescribeConfigurationAggregators with the addition of // the ability to pass a context and additional request options. // -// See DescribeConfigurationRecorders for details on how to use this API operation. +// See DescribeConfigurationAggregators for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *ConfigService) DescribeConfigurationRecordersWithContext(ctx aws.Context, input *DescribeConfigurationRecordersInput, opts ...request.Option) (*DescribeConfigurationRecordersOutput, error) { - req, out := c.DescribeConfigurationRecordersRequest(input) +func (c *ConfigService) DescribeConfigurationAggregatorsWithContext(ctx aws.Context, input *DescribeConfigurationAggregatorsInput, opts ...request.Option) (*DescribeConfigurationAggregatorsOutput, error) { + req, out := c.DescribeConfigurationAggregatorsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opDescribeDeliveryChannelStatus = "DescribeDeliveryChannelStatus" +const opDescribeConfigurationRecorderStatus = "DescribeConfigurationRecorderStatus" -// DescribeDeliveryChannelStatusRequest generates a "aws/request.Request" representing the -// client's request for the DescribeDeliveryChannelStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// DescribeConfigurationRecorderStatusRequest generates a "aws/request.Request" representing the +// client's request for the DescribeConfigurationRecorderStatus operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See DescribeDeliveryChannelStatus for more information on using the DescribeDeliveryChannelStatus +// See DescribeConfigurationRecorderStatus for more information on using the DescribeConfigurationRecorderStatus // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the DescribeDeliveryChannelStatusRequest method. -// req, resp := client.DescribeDeliveryChannelStatusRequest(params) +// // Example sending a request using the DescribeConfigurationRecorderStatusRequest method. +// req, resp := client.DescribeConfigurationRecorderStatusRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeDeliveryChannelStatus -func (c *ConfigService) DescribeDeliveryChannelStatusRequest(input *DescribeDeliveryChannelStatusInput) (req *request.Request, output *DescribeDeliveryChannelStatusOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeConfigurationRecorderStatus +func (c *ConfigService) DescribeConfigurationRecorderStatusRequest(input *DescribeConfigurationRecorderStatusInput) (req *request.Request, output *DescribeConfigurationRecorderStatusOutput) { op := &request.Operation{ - Name: opDescribeDeliveryChannelStatus, + Name: opDescribeConfigurationRecorderStatus, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &DescribeDeliveryChannelStatusInput{} + input = &DescribeConfigurationRecorderStatusInput{} } - output = &DescribeDeliveryChannelStatusOutput{} + output = &DescribeConfigurationRecorderStatusOutput{} req = c.newRequest(op, input, output) return } -// DescribeDeliveryChannelStatus API operation for AWS Config. +// DescribeConfigurationRecorderStatus API operation for AWS Config. // -// Returns the current status of the specified delivery channel. If a delivery -// channel is not specified, this action returns the current status of all delivery -// channels associated with the account. +// Returns the current status of the specified configuration recorder. If a +// configuration recorder is not specified, this action returns the status of +// all configuration recorders associated with the account. // -// Currently, you can specify only one delivery channel per region in your account. +// Currently, you can specify only one configuration recorder per region in +// your account. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Config's -// API operation DescribeDeliveryChannelStatus for usage and error information. +// API operation DescribeConfigurationRecorderStatus for usage and error information. // // Returned Error Codes: -// * ErrCodeNoSuchDeliveryChannelException "NoSuchDeliveryChannelException" -// You have specified a delivery channel that does not exist. +// * ErrCodeNoSuchConfigurationRecorderException "NoSuchConfigurationRecorderException" +// You have specified a configuration recorder that does not exist. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeDeliveryChannelStatus -func (c *ConfigService) DescribeDeliveryChannelStatus(input *DescribeDeliveryChannelStatusInput) (*DescribeDeliveryChannelStatusOutput, error) { - req, out := c.DescribeDeliveryChannelStatusRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeConfigurationRecorderStatus +func (c *ConfigService) DescribeConfigurationRecorderStatus(input *DescribeConfigurationRecorderStatusInput) (*DescribeConfigurationRecorderStatusOutput, error) { + req, out := c.DescribeConfigurationRecorderStatusRequest(input) return out, req.Send() } -// DescribeDeliveryChannelStatusWithContext is the same as DescribeDeliveryChannelStatus with the addition of +// DescribeConfigurationRecorderStatusWithContext is the same as DescribeConfigurationRecorderStatus with the addition of // the ability to pass a context and additional request options. // -// See DescribeDeliveryChannelStatus for details on how to use this API operation. +// See DescribeConfigurationRecorderStatus for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *ConfigService) DescribeDeliveryChannelStatusWithContext(ctx aws.Context, input *DescribeDeliveryChannelStatusInput, opts ...request.Option) (*DescribeDeliveryChannelStatusOutput, error) { - req, out := c.DescribeDeliveryChannelStatusRequest(input) +func (c *ConfigService) DescribeConfigurationRecorderStatusWithContext(ctx aws.Context, input *DescribeConfigurationRecorderStatusInput, opts ...request.Option) (*DescribeConfigurationRecorderStatusOutput, error) { + req, out := c.DescribeConfigurationRecorderStatusRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opDescribeDeliveryChannels = "DescribeDeliveryChannels" +const opDescribeConfigurationRecorders = "DescribeConfigurationRecorders" -// DescribeDeliveryChannelsRequest generates a "aws/request.Request" representing the -// client's request for the DescribeDeliveryChannels operation. The "output" return -// value will be populated with the request's response once the request complets +// DescribeConfigurationRecordersRequest generates a "aws/request.Request" representing the +// client's request for the DescribeConfigurationRecorders operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See DescribeDeliveryChannels for more information on using the DescribeDeliveryChannels +// See DescribeConfigurationRecorders for more information on using the DescribeConfigurationRecorders // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the DescribeDeliveryChannelsRequest method. -// req, resp := client.DescribeDeliveryChannelsRequest(params) +// // Example sending a request using the DescribeConfigurationRecordersRequest method. +// req, resp := client.DescribeConfigurationRecordersRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeDeliveryChannels -func (c *ConfigService) DescribeDeliveryChannelsRequest(input *DescribeDeliveryChannelsInput) (req *request.Request, output *DescribeDeliveryChannelsOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeConfigurationRecorders +func (c *ConfigService) DescribeConfigurationRecordersRequest(input *DescribeConfigurationRecordersInput) (req *request.Request, output *DescribeConfigurationRecordersOutput) { op := &request.Operation{ - Name: opDescribeDeliveryChannels, + Name: opDescribeConfigurationRecorders, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &DescribeDeliveryChannelsInput{} + input = &DescribeConfigurationRecordersInput{} } - output = &DescribeDeliveryChannelsOutput{} + output = &DescribeConfigurationRecordersOutput{} req = c.newRequest(op, input, output) return } -// DescribeDeliveryChannels API operation for AWS Config. +// DescribeConfigurationRecorders API operation for AWS Config. // -// Returns details about the specified delivery channel. If a delivery channel -// is not specified, this action returns the details of all delivery channels -// associated with the account. +// Returns the details for the specified configuration recorders. If the configuration +// recorder is not specified, this action returns the details for all configuration +// recorders associated with the account. // -// Currently, you can specify only one delivery channel per region in your account. +// Currently, you can specify only one configuration recorder per region in +// your account. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Config's -// API operation DescribeDeliveryChannels for usage and error information. +// API operation DescribeConfigurationRecorders for usage and error information. // // Returned Error Codes: -// * ErrCodeNoSuchDeliveryChannelException "NoSuchDeliveryChannelException" -// You have specified a delivery channel that does not exist. +// * ErrCodeNoSuchConfigurationRecorderException "NoSuchConfigurationRecorderException" +// You have specified a configuration recorder that does not exist. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeDeliveryChannels -func (c *ConfigService) DescribeDeliveryChannels(input *DescribeDeliveryChannelsInput) (*DescribeDeliveryChannelsOutput, error) { - req, out := c.DescribeDeliveryChannelsRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeConfigurationRecorders +func (c *ConfigService) DescribeConfigurationRecorders(input *DescribeConfigurationRecordersInput) (*DescribeConfigurationRecordersOutput, error) { + req, out := c.DescribeConfigurationRecordersRequest(input) return out, req.Send() } -// DescribeDeliveryChannelsWithContext is the same as DescribeDeliveryChannels with the addition of +// DescribeConfigurationRecordersWithContext is the same as DescribeConfigurationRecorders with the addition of // the ability to pass a context and additional request options. // -// See DescribeDeliveryChannels for details on how to use this API operation. +// See DescribeConfigurationRecorders for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *ConfigService) DescribeDeliveryChannelsWithContext(ctx aws.Context, input *DescribeDeliveryChannelsInput, opts ...request.Option) (*DescribeDeliveryChannelsOutput, error) { - req, out := c.DescribeDeliveryChannelsRequest(input) +func (c *ConfigService) DescribeConfigurationRecordersWithContext(ctx aws.Context, input *DescribeConfigurationRecordersInput, opts ...request.Option) (*DescribeConfigurationRecordersOutput, error) { + req, out := c.DescribeConfigurationRecordersRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opGetComplianceDetailsByConfigRule = "GetComplianceDetailsByConfigRule" +const opDescribeDeliveryChannelStatus = "DescribeDeliveryChannelStatus" -// GetComplianceDetailsByConfigRuleRequest generates a "aws/request.Request" representing the -// client's request for the GetComplianceDetailsByConfigRule operation. The "output" return -// value will be populated with the request's response once the request complets +// DescribeDeliveryChannelStatusRequest generates a "aws/request.Request" representing the +// client's request for the DescribeDeliveryChannelStatus operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetComplianceDetailsByConfigRule for more information on using the GetComplianceDetailsByConfigRule +// See DescribeDeliveryChannelStatus for more information on using the DescribeDeliveryChannelStatus // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the GetComplianceDetailsByConfigRuleRequest method. -// req, resp := client.GetComplianceDetailsByConfigRuleRequest(params) +// // Example sending a request using the DescribeDeliveryChannelStatusRequest method. +// req, resp := client.DescribeDeliveryChannelStatusRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetComplianceDetailsByConfigRule -func (c *ConfigService) GetComplianceDetailsByConfigRuleRequest(input *GetComplianceDetailsByConfigRuleInput) (req *request.Request, output *GetComplianceDetailsByConfigRuleOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeDeliveryChannelStatus +func (c *ConfigService) DescribeDeliveryChannelStatusRequest(input *DescribeDeliveryChannelStatusInput) (req *request.Request, output *DescribeDeliveryChannelStatusOutput) { op := &request.Operation{ - Name: opGetComplianceDetailsByConfigRule, + Name: opDescribeDeliveryChannelStatus, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &GetComplianceDetailsByConfigRuleInput{} + input = &DescribeDeliveryChannelStatusInput{} } - output = &GetComplianceDetailsByConfigRuleOutput{} + output = &DescribeDeliveryChannelStatusOutput{} req = c.newRequest(op, input, output) return } -// GetComplianceDetailsByConfigRule API operation for AWS Config. +// DescribeDeliveryChannelStatus API operation for AWS Config. // -// Returns the evaluation results for the specified AWS Config rule. The results -// indicate which AWS resources were evaluated by the rule, when each resource -// was last evaluated, and whether each resource complies with the rule. +// Returns the current status of the specified delivery channel. If a delivery +// channel is not specified, this action returns the current status of all delivery +// channels associated with the account. +// +// Currently, you can specify only one delivery channel per region in your account. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Config's -// API operation GetComplianceDetailsByConfigRule for usage and error information. +// API operation DescribeDeliveryChannelStatus for usage and error information. // // Returned Error Codes: -// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" -// One or more of the specified parameters are invalid. Verify that your parameters -// are valid and try again. -// -// * ErrCodeInvalidNextTokenException "InvalidNextTokenException" -// The specified next token is invalid. Specify the NextToken string that was -// returned in the previous response to get the next page of results. -// -// * ErrCodeNoSuchConfigRuleException "NoSuchConfigRuleException" -// One or more AWS Config rules in the request are invalid. Verify that the -// rule names are correct and try again. +// * ErrCodeNoSuchDeliveryChannelException "NoSuchDeliveryChannelException" +// You have specified a delivery channel that does not exist. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetComplianceDetailsByConfigRule -func (c *ConfigService) GetComplianceDetailsByConfigRule(input *GetComplianceDetailsByConfigRuleInput) (*GetComplianceDetailsByConfigRuleOutput, error) { - req, out := c.GetComplianceDetailsByConfigRuleRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeDeliveryChannelStatus +func (c *ConfigService) DescribeDeliveryChannelStatus(input *DescribeDeliveryChannelStatusInput) (*DescribeDeliveryChannelStatusOutput, error) { + req, out := c.DescribeDeliveryChannelStatusRequest(input) return out, req.Send() } -// GetComplianceDetailsByConfigRuleWithContext is the same as GetComplianceDetailsByConfigRule with the addition of +// DescribeDeliveryChannelStatusWithContext is the same as DescribeDeliveryChannelStatus with the addition of // the ability to pass a context and additional request options. // -// See GetComplianceDetailsByConfigRule for details on how to use this API operation. +// See DescribeDeliveryChannelStatus for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *ConfigService) GetComplianceDetailsByConfigRuleWithContext(ctx aws.Context, input *GetComplianceDetailsByConfigRuleInput, opts ...request.Option) (*GetComplianceDetailsByConfigRuleOutput, error) { - req, out := c.GetComplianceDetailsByConfigRuleRequest(input) +func (c *ConfigService) DescribeDeliveryChannelStatusWithContext(ctx aws.Context, input *DescribeDeliveryChannelStatusInput, opts ...request.Option) (*DescribeDeliveryChannelStatusOutput, error) { + req, out := c.DescribeDeliveryChannelStatusRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opGetComplianceDetailsByResource = "GetComplianceDetailsByResource" +const opDescribeDeliveryChannels = "DescribeDeliveryChannels" -// GetComplianceDetailsByResourceRequest generates a "aws/request.Request" representing the -// client's request for the GetComplianceDetailsByResource operation. The "output" return -// value will be populated with the request's response once the request complets +// DescribeDeliveryChannelsRequest generates a "aws/request.Request" representing the +// client's request for the DescribeDeliveryChannels operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetComplianceDetailsByResource for more information on using the GetComplianceDetailsByResource +// See DescribeDeliveryChannels for more information on using the DescribeDeliveryChannels // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the GetComplianceDetailsByResourceRequest method. -// req, resp := client.GetComplianceDetailsByResourceRequest(params) +// // Example sending a request using the DescribeDeliveryChannelsRequest method. +// req, resp := client.DescribeDeliveryChannelsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetComplianceDetailsByResource -func (c *ConfigService) GetComplianceDetailsByResourceRequest(input *GetComplianceDetailsByResourceInput) (req *request.Request, output *GetComplianceDetailsByResourceOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeDeliveryChannels +func (c *ConfigService) DescribeDeliveryChannelsRequest(input *DescribeDeliveryChannelsInput) (req *request.Request, output *DescribeDeliveryChannelsOutput) { op := &request.Operation{ - Name: opGetComplianceDetailsByResource, + Name: opDescribeDeliveryChannels, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &GetComplianceDetailsByResourceInput{} + input = &DescribeDeliveryChannelsInput{} } - output = &GetComplianceDetailsByResourceOutput{} + output = &DescribeDeliveryChannelsOutput{} req = c.newRequest(op, input, output) return } -// GetComplianceDetailsByResource API operation for AWS Config. +// DescribeDeliveryChannels API operation for AWS Config. // -// Returns the evaluation results for the specified AWS resource. The results -// indicate which AWS Config rules were used to evaluate the resource, when -// each rule was last used, and whether the resource complies with each rule. +// Returns details about the specified delivery channel. If a delivery channel +// is not specified, this action returns the details of all delivery channels +// associated with the account. +// +// Currently, you can specify only one delivery channel per region in your account. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Config's -// API operation GetComplianceDetailsByResource for usage and error information. +// API operation DescribeDeliveryChannels for usage and error information. // // Returned Error Codes: -// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" -// One or more of the specified parameters are invalid. Verify that your parameters -// are valid and try again. +// * ErrCodeNoSuchDeliveryChannelException "NoSuchDeliveryChannelException" +// You have specified a delivery channel that does not exist. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetComplianceDetailsByResource -func (c *ConfigService) GetComplianceDetailsByResource(input *GetComplianceDetailsByResourceInput) (*GetComplianceDetailsByResourceOutput, error) { - req, out := c.GetComplianceDetailsByResourceRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribeDeliveryChannels +func (c *ConfigService) DescribeDeliveryChannels(input *DescribeDeliveryChannelsInput) (*DescribeDeliveryChannelsOutput, error) { + req, out := c.DescribeDeliveryChannelsRequest(input) return out, req.Send() } -// GetComplianceDetailsByResourceWithContext is the same as GetComplianceDetailsByResource with the addition of +// DescribeDeliveryChannelsWithContext is the same as DescribeDeliveryChannels with the addition of // the ability to pass a context and additional request options. // -// See GetComplianceDetailsByResource for details on how to use this API operation. +// See DescribeDeliveryChannels for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *ConfigService) GetComplianceDetailsByResourceWithContext(ctx aws.Context, input *GetComplianceDetailsByResourceInput, opts ...request.Option) (*GetComplianceDetailsByResourceOutput, error) { - req, out := c.GetComplianceDetailsByResourceRequest(input) +func (c *ConfigService) DescribeDeliveryChannelsWithContext(ctx aws.Context, input *DescribeDeliveryChannelsInput, opts ...request.Option) (*DescribeDeliveryChannelsOutput, error) { + req, out := c.DescribeDeliveryChannelsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opGetComplianceSummaryByConfigRule = "GetComplianceSummaryByConfigRule" +const opDescribePendingAggregationRequests = "DescribePendingAggregationRequests" -// GetComplianceSummaryByConfigRuleRequest generates a "aws/request.Request" representing the -// client's request for the GetComplianceSummaryByConfigRule operation. The "output" return -// value will be populated with the request's response once the request complets +// DescribePendingAggregationRequestsRequest generates a "aws/request.Request" representing the +// client's request for the DescribePendingAggregationRequests operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetComplianceSummaryByConfigRule for more information on using the GetComplianceSummaryByConfigRule +// See DescribePendingAggregationRequests for more information on using the DescribePendingAggregationRequests // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the GetComplianceSummaryByConfigRuleRequest method. -// req, resp := client.GetComplianceSummaryByConfigRuleRequest(params) +// // Example sending a request using the DescribePendingAggregationRequestsRequest method. +// req, resp := client.DescribePendingAggregationRequestsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetComplianceSummaryByConfigRule -func (c *ConfigService) GetComplianceSummaryByConfigRuleRequest(input *GetComplianceSummaryByConfigRuleInput) (req *request.Request, output *GetComplianceSummaryByConfigRuleOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribePendingAggregationRequests +func (c *ConfigService) DescribePendingAggregationRequestsRequest(input *DescribePendingAggregationRequestsInput) (req *request.Request, output *DescribePendingAggregationRequestsOutput) { op := &request.Operation{ - Name: opGetComplianceSummaryByConfigRule, + Name: opDescribePendingAggregationRequests, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &GetComplianceSummaryByConfigRuleInput{} + input = &DescribePendingAggregationRequestsInput{} } - output = &GetComplianceSummaryByConfigRuleOutput{} + output = &DescribePendingAggregationRequestsOutput{} req = c.newRequest(op, input, output) return } -// GetComplianceSummaryByConfigRule API operation for AWS Config. +// DescribePendingAggregationRequests API operation for AWS Config. // -// Returns the number of AWS Config rules that are compliant and noncompliant, -// up to a maximum of 25 for each. +// Returns a list of all pending aggregation requests. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Config's -// API operation GetComplianceSummaryByConfigRule for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetComplianceSummaryByConfigRule -func (c *ConfigService) GetComplianceSummaryByConfigRule(input *GetComplianceSummaryByConfigRuleInput) (*GetComplianceSummaryByConfigRuleOutput, error) { - req, out := c.GetComplianceSummaryByConfigRuleRequest(input) +// API operation DescribePendingAggregationRequests for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" +// One or more of the specified parameters are invalid. Verify that your parameters +// are valid and try again. +// +// * ErrCodeInvalidNextTokenException "InvalidNextTokenException" +// The specified next token is invalid. Specify the nextToken string that was +// returned in the previous response to get the next page of results. +// +// * ErrCodeInvalidLimitException "InvalidLimitException" +// The specified limit is outside the allowable range. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/DescribePendingAggregationRequests +func (c *ConfigService) DescribePendingAggregationRequests(input *DescribePendingAggregationRequestsInput) (*DescribePendingAggregationRequestsOutput, error) { + req, out := c.DescribePendingAggregationRequestsRequest(input) return out, req.Send() } -// GetComplianceSummaryByConfigRuleWithContext is the same as GetComplianceSummaryByConfigRule with the addition of +// DescribePendingAggregationRequestsWithContext is the same as DescribePendingAggregationRequests with the addition of // the ability to pass a context and additional request options. // -// See GetComplianceSummaryByConfigRule for details on how to use this API operation. +// See DescribePendingAggregationRequests for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *ConfigService) GetComplianceSummaryByConfigRuleWithContext(ctx aws.Context, input *GetComplianceSummaryByConfigRuleInput, opts ...request.Option) (*GetComplianceSummaryByConfigRuleOutput, error) { - req, out := c.GetComplianceSummaryByConfigRuleRequest(input) +func (c *ConfigService) DescribePendingAggregationRequestsWithContext(ctx aws.Context, input *DescribePendingAggregationRequestsInput, opts ...request.Option) (*DescribePendingAggregationRequestsOutput, error) { + req, out := c.DescribePendingAggregationRequestsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opGetComplianceSummaryByResourceType = "GetComplianceSummaryByResourceType" +const opGetAggregateComplianceDetailsByConfigRule = "GetAggregateComplianceDetailsByConfigRule" -// GetComplianceSummaryByResourceTypeRequest generates a "aws/request.Request" representing the -// client's request for the GetComplianceSummaryByResourceType operation. The "output" return -// value will be populated with the request's response once the request complets +// GetAggregateComplianceDetailsByConfigRuleRequest generates a "aws/request.Request" representing the +// client's request for the GetAggregateComplianceDetailsByConfigRule operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetComplianceSummaryByResourceType for more information on using the GetComplianceSummaryByResourceType +// See GetAggregateComplianceDetailsByConfigRule for more information on using the GetAggregateComplianceDetailsByConfigRule // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the GetComplianceSummaryByResourceTypeRequest method. -// req, resp := client.GetComplianceSummaryByResourceTypeRequest(params) +// // Example sending a request using the GetAggregateComplianceDetailsByConfigRuleRequest method. +// req, resp := client.GetAggregateComplianceDetailsByConfigRuleRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetComplianceSummaryByResourceType -func (c *ConfigService) GetComplianceSummaryByResourceTypeRequest(input *GetComplianceSummaryByResourceTypeInput) (req *request.Request, output *GetComplianceSummaryByResourceTypeOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetAggregateComplianceDetailsByConfigRule +func (c *ConfigService) GetAggregateComplianceDetailsByConfigRuleRequest(input *GetAggregateComplianceDetailsByConfigRuleInput) (req *request.Request, output *GetAggregateComplianceDetailsByConfigRuleOutput) { op := &request.Operation{ - Name: opGetComplianceSummaryByResourceType, + Name: opGetAggregateComplianceDetailsByConfigRule, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &GetComplianceSummaryByResourceTypeInput{} + input = &GetAggregateComplianceDetailsByConfigRuleInput{} } - output = &GetComplianceSummaryByResourceTypeOutput{} + output = &GetAggregateComplianceDetailsByConfigRuleOutput{} req = c.newRequest(op, input, output) return } -// GetComplianceSummaryByResourceType API operation for AWS Config. +// GetAggregateComplianceDetailsByConfigRule API operation for AWS Config. // -// Returns the number of resources that are compliant and the number that are -// noncompliant. You can specify one or more resource types to get these numbers -// for each resource type. The maximum number returned is 100. +// Returns the evaluation results for the specified AWS Config rule for a specific +// resource in a rule. The results indicate which AWS resources were evaluated +// by the rule, when each resource was last evaluated, and whether each resource +// complies with the rule. +// +// The results can return an empty result page. But if you have a nextToken, +// the results are displayed on the next page. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Config's -// API operation GetComplianceSummaryByResourceType for usage and error information. +// API operation GetAggregateComplianceDetailsByConfigRule for usage and error information. // // Returned Error Codes: -// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" -// One or more of the specified parameters are invalid. Verify that your parameters -// are valid and try again. +// * ErrCodeValidationException "ValidationException" +// The requested action is not valid. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetComplianceSummaryByResourceType -func (c *ConfigService) GetComplianceSummaryByResourceType(input *GetComplianceSummaryByResourceTypeInput) (*GetComplianceSummaryByResourceTypeOutput, error) { - req, out := c.GetComplianceSummaryByResourceTypeRequest(input) +// * ErrCodeInvalidLimitException "InvalidLimitException" +// The specified limit is outside the allowable range. +// +// * ErrCodeInvalidNextTokenException "InvalidNextTokenException" +// The specified next token is invalid. Specify the nextToken string that was +// returned in the previous response to get the next page of results. +// +// * ErrCodeNoSuchConfigurationAggregatorException "NoSuchConfigurationAggregatorException" +// You have specified a configuration aggregator that does not exist. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetAggregateComplianceDetailsByConfigRule +func (c *ConfigService) GetAggregateComplianceDetailsByConfigRule(input *GetAggregateComplianceDetailsByConfigRuleInput) (*GetAggregateComplianceDetailsByConfigRuleOutput, error) { + req, out := c.GetAggregateComplianceDetailsByConfigRuleRequest(input) return out, req.Send() } -// GetComplianceSummaryByResourceTypeWithContext is the same as GetComplianceSummaryByResourceType with the addition of +// GetAggregateComplianceDetailsByConfigRuleWithContext is the same as GetAggregateComplianceDetailsByConfigRule with the addition of // the ability to pass a context and additional request options. // -// See GetComplianceSummaryByResourceType for details on how to use this API operation. +// See GetAggregateComplianceDetailsByConfigRule for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *ConfigService) GetComplianceSummaryByResourceTypeWithContext(ctx aws.Context, input *GetComplianceSummaryByResourceTypeInput, opts ...request.Option) (*GetComplianceSummaryByResourceTypeOutput, error) { - req, out := c.GetComplianceSummaryByResourceTypeRequest(input) +func (c *ConfigService) GetAggregateComplianceDetailsByConfigRuleWithContext(ctx aws.Context, input *GetAggregateComplianceDetailsByConfigRuleInput, opts ...request.Option) (*GetAggregateComplianceDetailsByConfigRuleOutput, error) { + req, out := c.GetAggregateComplianceDetailsByConfigRuleRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opGetDiscoveredResourceCounts = "GetDiscoveredResourceCounts" +const opGetAggregateConfigRuleComplianceSummary = "GetAggregateConfigRuleComplianceSummary" -// GetDiscoveredResourceCountsRequest generates a "aws/request.Request" representing the -// client's request for the GetDiscoveredResourceCounts operation. The "output" return -// value will be populated with the request's response once the request complets +// GetAggregateConfigRuleComplianceSummaryRequest generates a "aws/request.Request" representing the +// client's request for the GetAggregateConfigRuleComplianceSummary operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetDiscoveredResourceCounts for more information on using the GetDiscoveredResourceCounts +// See GetAggregateConfigRuleComplianceSummary for more information on using the GetAggregateConfigRuleComplianceSummary // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the GetDiscoveredResourceCountsRequest method. -// req, resp := client.GetDiscoveredResourceCountsRequest(params) +// // Example sending a request using the GetAggregateConfigRuleComplianceSummaryRequest method. +// req, resp := client.GetAggregateConfigRuleComplianceSummaryRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetDiscoveredResourceCounts -func (c *ConfigService) GetDiscoveredResourceCountsRequest(input *GetDiscoveredResourceCountsInput) (req *request.Request, output *GetDiscoveredResourceCountsOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetAggregateConfigRuleComplianceSummary +func (c *ConfigService) GetAggregateConfigRuleComplianceSummaryRequest(input *GetAggregateConfigRuleComplianceSummaryInput) (req *request.Request, output *GetAggregateConfigRuleComplianceSummaryOutput) { op := &request.Operation{ - Name: opGetDiscoveredResourceCounts, + Name: opGetAggregateConfigRuleComplianceSummary, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &GetDiscoveredResourceCountsInput{} + input = &GetAggregateConfigRuleComplianceSummaryInput{} } - output = &GetDiscoveredResourceCountsOutput{} + output = &GetAggregateConfigRuleComplianceSummaryOutput{} req = c.newRequest(op, input, output) return } -// GetDiscoveredResourceCounts API operation for AWS Config. -// -// Returns the resource types, the number of each resource type, and the total -// number of resources that AWS Config is recording in this region for your -// AWS account. -// -// Example -// -// AWS Config is recording three resource types in the US East (Ohio) Region -// for your account: 25 EC2 instances, 20 IAM users, and 15 S3 buckets. -// -// You make a call to the GetDiscoveredResourceCounts action and specify that -// you want all resource types. -// -// AWS Config returns the following: -// -// The resource types (EC2 instances, IAM users, and S3 buckets) -// -// The number of each resource type (25, 20, and 15) -// -// The total number of all resources (60) -// -// The response is paginated. By default, AWS Config lists 100 ResourceCount -// objects on each page. You can customize this number with the limit parameter. -// The response includes a nextToken string. To get the next page of results, -// run the request again and specify the string for the nextToken parameter. -// -// If you make a call to the GetDiscoveredResourceCounts action, you may not -// immediately receive resource counts in the following situations: -// -// You are a new AWS Config customer +// GetAggregateConfigRuleComplianceSummary API operation for AWS Config. // -// You just enabled resource recording +// Returns the number of compliant and noncompliant rules for one or more accounts +// and regions in an aggregator. // -// It may take a few minutes for AWS Config to record and count your resources. -// Wait a few minutes and then retry the GetDiscoveredResourceCounts action. +// The results can return an empty result page, but if you have a nextToken, +// the results are displayed on the next page. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Config's -// API operation GetDiscoveredResourceCounts for usage and error information. +// API operation GetAggregateConfigRuleComplianceSummary for usage and error information. // // Returned Error Codes: // * ErrCodeValidationException "ValidationException" @@ -1615,1028 +2145,2268 @@ func (c *ConfigService) GetDiscoveredResourceCountsRequest(input *GetDiscoveredR // The specified limit is outside the allowable range. // // * ErrCodeInvalidNextTokenException "InvalidNextTokenException" -// The specified next token is invalid. Specify the NextToken string that was +// The specified next token is invalid. Specify the nextToken string that was // returned in the previous response to get the next page of results. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetDiscoveredResourceCounts -func (c *ConfigService) GetDiscoveredResourceCounts(input *GetDiscoveredResourceCountsInput) (*GetDiscoveredResourceCountsOutput, error) { - req, out := c.GetDiscoveredResourceCountsRequest(input) +// * ErrCodeNoSuchConfigurationAggregatorException "NoSuchConfigurationAggregatorException" +// You have specified a configuration aggregator that does not exist. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetAggregateConfigRuleComplianceSummary +func (c *ConfigService) GetAggregateConfigRuleComplianceSummary(input *GetAggregateConfigRuleComplianceSummaryInput) (*GetAggregateConfigRuleComplianceSummaryOutput, error) { + req, out := c.GetAggregateConfigRuleComplianceSummaryRequest(input) return out, req.Send() } -// GetDiscoveredResourceCountsWithContext is the same as GetDiscoveredResourceCounts with the addition of +// GetAggregateConfigRuleComplianceSummaryWithContext is the same as GetAggregateConfigRuleComplianceSummary with the addition of // the ability to pass a context and additional request options. // -// See GetDiscoveredResourceCounts for details on how to use this API operation. +// See GetAggregateConfigRuleComplianceSummary for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *ConfigService) GetDiscoveredResourceCountsWithContext(ctx aws.Context, input *GetDiscoveredResourceCountsInput, opts ...request.Option) (*GetDiscoveredResourceCountsOutput, error) { - req, out := c.GetDiscoveredResourceCountsRequest(input) +func (c *ConfigService) GetAggregateConfigRuleComplianceSummaryWithContext(ctx aws.Context, input *GetAggregateConfigRuleComplianceSummaryInput, opts ...request.Option) (*GetAggregateConfigRuleComplianceSummaryOutput, error) { + req, out := c.GetAggregateConfigRuleComplianceSummaryRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opGetResourceConfigHistory = "GetResourceConfigHistory" +const opGetComplianceDetailsByConfigRule = "GetComplianceDetailsByConfigRule" -// GetResourceConfigHistoryRequest generates a "aws/request.Request" representing the -// client's request for the GetResourceConfigHistory operation. The "output" return -// value will be populated with the request's response once the request complets +// GetComplianceDetailsByConfigRuleRequest generates a "aws/request.Request" representing the +// client's request for the GetComplianceDetailsByConfigRule operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetResourceConfigHistory for more information on using the GetResourceConfigHistory +// See GetComplianceDetailsByConfigRule for more information on using the GetComplianceDetailsByConfigRule // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the GetResourceConfigHistoryRequest method. -// req, resp := client.GetResourceConfigHistoryRequest(params) +// // Example sending a request using the GetComplianceDetailsByConfigRuleRequest method. +// req, resp := client.GetComplianceDetailsByConfigRuleRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetResourceConfigHistory -func (c *ConfigService) GetResourceConfigHistoryRequest(input *GetResourceConfigHistoryInput) (req *request.Request, output *GetResourceConfigHistoryOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetComplianceDetailsByConfigRule +func (c *ConfigService) GetComplianceDetailsByConfigRuleRequest(input *GetComplianceDetailsByConfigRuleInput) (req *request.Request, output *GetComplianceDetailsByConfigRuleOutput) { op := &request.Operation{ - Name: opGetResourceConfigHistory, + Name: opGetComplianceDetailsByConfigRule, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"nextToken"}, - OutputTokens: []string{"nextToken"}, - LimitToken: "limit", - TruncationToken: "", - }, } if input == nil { - input = &GetResourceConfigHistoryInput{} + input = &GetComplianceDetailsByConfigRuleInput{} } - output = &GetResourceConfigHistoryOutput{} + output = &GetComplianceDetailsByConfigRuleOutput{} req = c.newRequest(op, input, output) return } -// GetResourceConfigHistory API operation for AWS Config. -// -// Returns a list of configuration items for the specified resource. The list -// contains details about each state of the resource during the specified time -// interval. -// -// The response is paginated. By default, AWS Config returns a limit of 10 configuration -// items per page. You can customize this number with the limit parameter. The -// response includes a nextToken string. To get the next page of results, run -// the request again and specify the string for the nextToken parameter. +// GetComplianceDetailsByConfigRule API operation for AWS Config. // -// Each call to the API is limited to span a duration of seven days. It is likely -// that the number of records returned is smaller than the specified limit. -// In such cases, you can make another call, using the nextToken. +// Returns the evaluation results for the specified AWS Config rule. The results +// indicate which AWS resources were evaluated by the rule, when each resource +// was last evaluated, and whether each resource complies with the rule. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Config's -// API operation GetResourceConfigHistory for usage and error information. +// API operation GetComplianceDetailsByConfigRule for usage and error information. // // Returned Error Codes: -// * ErrCodeValidationException "ValidationException" -// The requested action is not valid. -// -// * ErrCodeInvalidTimeRangeException "InvalidTimeRangeException" -// The specified time range is not valid. The earlier time is not chronologically -// before the later time. -// -// * ErrCodeInvalidLimitException "InvalidLimitException" -// The specified limit is outside the allowable range. +// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" +// One or more of the specified parameters are invalid. Verify that your parameters +// are valid and try again. // // * ErrCodeInvalidNextTokenException "InvalidNextTokenException" -// The specified next token is invalid. Specify the NextToken string that was +// The specified next token is invalid. Specify the nextToken string that was // returned in the previous response to get the next page of results. // -// * ErrCodeNoAvailableConfigurationRecorderException "NoAvailableConfigurationRecorderException" -// There are no configuration recorders available to provide the role needed -// to describe your resources. Create a configuration recorder. -// -// * ErrCodeResourceNotDiscoveredException "ResourceNotDiscoveredException" -// You have specified a resource that is either unknown or has not been discovered. +// * ErrCodeNoSuchConfigRuleException "NoSuchConfigRuleException" +// One or more AWS Config rules in the request are invalid. Verify that the +// rule names are correct and try again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetResourceConfigHistory -func (c *ConfigService) GetResourceConfigHistory(input *GetResourceConfigHistoryInput) (*GetResourceConfigHistoryOutput, error) { - req, out := c.GetResourceConfigHistoryRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetComplianceDetailsByConfigRule +func (c *ConfigService) GetComplianceDetailsByConfigRule(input *GetComplianceDetailsByConfigRuleInput) (*GetComplianceDetailsByConfigRuleOutput, error) { + req, out := c.GetComplianceDetailsByConfigRuleRequest(input) return out, req.Send() } -// GetResourceConfigHistoryWithContext is the same as GetResourceConfigHistory with the addition of +// GetComplianceDetailsByConfigRuleWithContext is the same as GetComplianceDetailsByConfigRule with the addition of // the ability to pass a context and additional request options. // -// See GetResourceConfigHistory for details on how to use this API operation. +// See GetComplianceDetailsByConfigRule for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *ConfigService) GetResourceConfigHistoryWithContext(ctx aws.Context, input *GetResourceConfigHistoryInput, opts ...request.Option) (*GetResourceConfigHistoryOutput, error) { - req, out := c.GetResourceConfigHistoryRequest(input) +func (c *ConfigService) GetComplianceDetailsByConfigRuleWithContext(ctx aws.Context, input *GetComplianceDetailsByConfigRuleInput, opts ...request.Option) (*GetComplianceDetailsByConfigRuleOutput, error) { + req, out := c.GetComplianceDetailsByConfigRuleRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// GetResourceConfigHistoryPages iterates over the pages of a GetResourceConfigHistory operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See GetResourceConfigHistory method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a GetResourceConfigHistory operation. -// pageNum := 0 -// err := client.GetResourceConfigHistoryPages(params, -// func(page *GetResourceConfigHistoryOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *ConfigService) GetResourceConfigHistoryPages(input *GetResourceConfigHistoryInput, fn func(*GetResourceConfigHistoryOutput, bool) bool) error { - return c.GetResourceConfigHistoryPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// GetResourceConfigHistoryPagesWithContext same as GetResourceConfigHistoryPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ConfigService) GetResourceConfigHistoryPagesWithContext(ctx aws.Context, input *GetResourceConfigHistoryInput, fn func(*GetResourceConfigHistoryOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *GetResourceConfigHistoryInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.GetResourceConfigHistoryRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*GetResourceConfigHistoryOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opListDiscoveredResources = "ListDiscoveredResources" +const opGetComplianceDetailsByResource = "GetComplianceDetailsByResource" -// ListDiscoveredResourcesRequest generates a "aws/request.Request" representing the -// client's request for the ListDiscoveredResources operation. The "output" return -// value will be populated with the request's response once the request complets +// GetComplianceDetailsByResourceRequest generates a "aws/request.Request" representing the +// client's request for the GetComplianceDetailsByResource operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListDiscoveredResources for more information on using the ListDiscoveredResources +// See GetComplianceDetailsByResource for more information on using the GetComplianceDetailsByResource // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the ListDiscoveredResourcesRequest method. -// req, resp := client.ListDiscoveredResourcesRequest(params) +// // Example sending a request using the GetComplianceDetailsByResourceRequest method. +// req, resp := client.GetComplianceDetailsByResourceRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/ListDiscoveredResources -func (c *ConfigService) ListDiscoveredResourcesRequest(input *ListDiscoveredResourcesInput) (req *request.Request, output *ListDiscoveredResourcesOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetComplianceDetailsByResource +func (c *ConfigService) GetComplianceDetailsByResourceRequest(input *GetComplianceDetailsByResourceInput) (req *request.Request, output *GetComplianceDetailsByResourceOutput) { op := &request.Operation{ - Name: opListDiscoveredResources, + Name: opGetComplianceDetailsByResource, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &ListDiscoveredResourcesInput{} + input = &GetComplianceDetailsByResourceInput{} } - output = &ListDiscoveredResourcesOutput{} + output = &GetComplianceDetailsByResourceOutput{} req = c.newRequest(op, input, output) return } -// ListDiscoveredResources API operation for AWS Config. -// -// Accepts a resource type and returns a list of resource identifiers for the -// resources of that type. A resource identifier includes the resource type, -// ID, and (if available) the custom resource name. The results consist of resources -// that AWS Config has discovered, including those that AWS Config is not currently -// recording. You can narrow the results to include only resources that have -// specific resource IDs or a resource name. -// -// You can specify either resource IDs or a resource name but not both in the -// same request. +// GetComplianceDetailsByResource API operation for AWS Config. // -// The response is paginated. By default, AWS Config lists 100 resource identifiers -// on each page. You can customize this number with the limit parameter. The -// response includes a nextToken string. To get the next page of results, run -// the request again and specify the string for the nextToken parameter. +// Returns the evaluation results for the specified AWS resource. The results +// indicate which AWS Config rules were used to evaluate the resource, when +// each rule was last used, and whether the resource complies with each rule. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Config's -// API operation ListDiscoveredResources for usage and error information. +// API operation GetComplianceDetailsByResource for usage and error information. // // Returned Error Codes: -// * ErrCodeValidationException "ValidationException" -// The requested action is not valid. -// -// * ErrCodeInvalidLimitException "InvalidLimitException" -// The specified limit is outside the allowable range. -// -// * ErrCodeInvalidNextTokenException "InvalidNextTokenException" -// The specified next token is invalid. Specify the NextToken string that was -// returned in the previous response to get the next page of results. -// -// * ErrCodeNoAvailableConfigurationRecorderException "NoAvailableConfigurationRecorderException" -// There are no configuration recorders available to provide the role needed -// to describe your resources. Create a configuration recorder. +// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" +// One or more of the specified parameters are invalid. Verify that your parameters +// are valid and try again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/ListDiscoveredResources -func (c *ConfigService) ListDiscoveredResources(input *ListDiscoveredResourcesInput) (*ListDiscoveredResourcesOutput, error) { - req, out := c.ListDiscoveredResourcesRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetComplianceDetailsByResource +func (c *ConfigService) GetComplianceDetailsByResource(input *GetComplianceDetailsByResourceInput) (*GetComplianceDetailsByResourceOutput, error) { + req, out := c.GetComplianceDetailsByResourceRequest(input) return out, req.Send() } -// ListDiscoveredResourcesWithContext is the same as ListDiscoveredResources with the addition of +// GetComplianceDetailsByResourceWithContext is the same as GetComplianceDetailsByResource with the addition of // the ability to pass a context and additional request options. // -// See ListDiscoveredResources for details on how to use this API operation. +// See GetComplianceDetailsByResource for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *ConfigService) ListDiscoveredResourcesWithContext(ctx aws.Context, input *ListDiscoveredResourcesInput, opts ...request.Option) (*ListDiscoveredResourcesOutput, error) { - req, out := c.ListDiscoveredResourcesRequest(input) +func (c *ConfigService) GetComplianceDetailsByResourceWithContext(ctx aws.Context, input *GetComplianceDetailsByResourceInput, opts ...request.Option) (*GetComplianceDetailsByResourceOutput, error) { + req, out := c.GetComplianceDetailsByResourceRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opPutConfigRule = "PutConfigRule" +const opGetComplianceSummaryByConfigRule = "GetComplianceSummaryByConfigRule" -// PutConfigRuleRequest generates a "aws/request.Request" representing the -// client's request for the PutConfigRule operation. The "output" return -// value will be populated with the request's response once the request complets +// GetComplianceSummaryByConfigRuleRequest generates a "aws/request.Request" representing the +// client's request for the GetComplianceSummaryByConfigRule operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See PutConfigRule for more information on using the PutConfigRule +// See GetComplianceSummaryByConfigRule for more information on using the GetComplianceSummaryByConfigRule // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the PutConfigRuleRequest method. -// req, resp := client.PutConfigRuleRequest(params) +// // Example sending a request using the GetComplianceSummaryByConfigRuleRequest method. +// req, resp := client.GetComplianceSummaryByConfigRuleRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutConfigRule -func (c *ConfigService) PutConfigRuleRequest(input *PutConfigRuleInput) (req *request.Request, output *PutConfigRuleOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetComplianceSummaryByConfigRule +func (c *ConfigService) GetComplianceSummaryByConfigRuleRequest(input *GetComplianceSummaryByConfigRuleInput) (req *request.Request, output *GetComplianceSummaryByConfigRuleOutput) { op := &request.Operation{ - Name: opPutConfigRule, + Name: opGetComplianceSummaryByConfigRule, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &PutConfigRuleInput{} + input = &GetComplianceSummaryByConfigRuleInput{} } - output = &PutConfigRuleOutput{} + output = &GetComplianceSummaryByConfigRuleOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) - req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } -// PutConfigRule API operation for AWS Config. -// -// Adds or updates an AWS Config rule for evaluating whether your AWS resources -// comply with your desired configurations. -// -// You can use this action for custom Config rules and AWS managed Config rules. -// A custom Config rule is a rule that you develop and maintain. An AWS managed -// Config rule is a customizable, predefined rule that AWS Config provides. -// -// If you are adding a new custom Config rule, you must first create the AWS -// Lambda function that the rule invokes to evaluate your resources. When you -// use the PutConfigRule action to add the rule to AWS Config, you must specify -// the Amazon Resource Name (ARN) that AWS Lambda assigns to the function. Specify -// the ARN for the SourceIdentifier key. This key is part of the Source object, -// which is part of the ConfigRule object. -// -// If you are adding an AWS managed Config rule, specify the rule's identifier -// for the SourceIdentifier key. To reference AWS managed Config rule identifiers, -// see About AWS Managed Config Rules (http://docs.aws.amazon.com/config/latest/developerguide/evaluate-config_use-managed-rules.html). -// -// For any new rule that you add, specify the ConfigRuleName in the ConfigRule -// object. Do not specify the ConfigRuleArn or the ConfigRuleId. These values -// are generated by AWS Config for new rules. -// -// If you are updating a rule that you added previously, you can specify the -// rule by ConfigRuleName, ConfigRuleId, or ConfigRuleArn in the ConfigRule -// data type that you use in this request. -// -// The maximum number of rules that AWS Config supports is 50. -// -// For more information about requesting a rule limit increase, see AWS Config -// Limits (http://docs.aws.amazon.com/general/latest/gr/aws_service_limits.html#limits_config) -// in the AWS General Reference Guide. +// GetComplianceSummaryByConfigRule API operation for AWS Config. // -// For more information about developing and using AWS Config rules, see Evaluating -// AWS Resource Configurations with AWS Config (http://docs.aws.amazon.com/config/latest/developerguide/evaluate-config.html) -// in the AWS Config Developer Guide. +// Returns the number of AWS Config rules that are compliant and noncompliant, +// up to a maximum of 25 for each. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Config's -// API operation PutConfigRule for usage and error information. -// -// Returned Error Codes: -// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" -// One or more of the specified parameters are invalid. Verify that your parameters -// are valid and try again. -// -// * ErrCodeMaxNumberOfConfigRulesExceededException "MaxNumberOfConfigRulesExceededException" -// Failed to add the AWS Config rule because the account already contains the -// maximum number of 50 rules. Consider deleting any deactivated rules before -// adding new rules. -// -// * ErrCodeResourceInUseException "ResourceInUseException" -// The rule is currently being deleted or the rule is deleting your evaluation -// results. Try your request again later. -// -// * ErrCodeInsufficientPermissionsException "InsufficientPermissionsException" -// Indicates one of the following errors: -// -// * The rule cannot be created because the IAM role assigned to AWS Config -// lacks permissions to perform the config:Put* action. -// -// * The AWS Lambda function cannot be invoked. Check the function ARN, and -// check the function's permissions. -// -// * ErrCodeNoAvailableConfigurationRecorderException "NoAvailableConfigurationRecorderException" -// There are no configuration recorders available to provide the role needed -// to describe your resources. Create a configuration recorder. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutConfigRule -func (c *ConfigService) PutConfigRule(input *PutConfigRuleInput) (*PutConfigRuleOutput, error) { - req, out := c.PutConfigRuleRequest(input) +// API operation GetComplianceSummaryByConfigRule for usage and error information. +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetComplianceSummaryByConfigRule +func (c *ConfigService) GetComplianceSummaryByConfigRule(input *GetComplianceSummaryByConfigRuleInput) (*GetComplianceSummaryByConfigRuleOutput, error) { + req, out := c.GetComplianceSummaryByConfigRuleRequest(input) return out, req.Send() } -// PutConfigRuleWithContext is the same as PutConfigRule with the addition of +// GetComplianceSummaryByConfigRuleWithContext is the same as GetComplianceSummaryByConfigRule with the addition of // the ability to pass a context and additional request options. // -// See PutConfigRule for details on how to use this API operation. +// See GetComplianceSummaryByConfigRule for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *ConfigService) PutConfigRuleWithContext(ctx aws.Context, input *PutConfigRuleInput, opts ...request.Option) (*PutConfigRuleOutput, error) { - req, out := c.PutConfigRuleRequest(input) +func (c *ConfigService) GetComplianceSummaryByConfigRuleWithContext(ctx aws.Context, input *GetComplianceSummaryByConfigRuleInput, opts ...request.Option) (*GetComplianceSummaryByConfigRuleOutput, error) { + req, out := c.GetComplianceSummaryByConfigRuleRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opPutConfigurationRecorder = "PutConfigurationRecorder" +const opGetComplianceSummaryByResourceType = "GetComplianceSummaryByResourceType" -// PutConfigurationRecorderRequest generates a "aws/request.Request" representing the -// client's request for the PutConfigurationRecorder operation. The "output" return -// value will be populated with the request's response once the request complets +// GetComplianceSummaryByResourceTypeRequest generates a "aws/request.Request" representing the +// client's request for the GetComplianceSummaryByResourceType operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See PutConfigurationRecorder for more information on using the PutConfigurationRecorder +// See GetComplianceSummaryByResourceType for more information on using the GetComplianceSummaryByResourceType // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the PutConfigurationRecorderRequest method. -// req, resp := client.PutConfigurationRecorderRequest(params) +// // Example sending a request using the GetComplianceSummaryByResourceTypeRequest method. +// req, resp := client.GetComplianceSummaryByResourceTypeRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutConfigurationRecorder -func (c *ConfigService) PutConfigurationRecorderRequest(input *PutConfigurationRecorderInput) (req *request.Request, output *PutConfigurationRecorderOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetComplianceSummaryByResourceType +func (c *ConfigService) GetComplianceSummaryByResourceTypeRequest(input *GetComplianceSummaryByResourceTypeInput) (req *request.Request, output *GetComplianceSummaryByResourceTypeOutput) { op := &request.Operation{ - Name: opPutConfigurationRecorder, + Name: opGetComplianceSummaryByResourceType, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &PutConfigurationRecorderInput{} + input = &GetComplianceSummaryByResourceTypeInput{} } - output = &PutConfigurationRecorderOutput{} + output = &GetComplianceSummaryByResourceTypeOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) - req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } -// PutConfigurationRecorder API operation for AWS Config. -// -// Creates a new configuration recorder to record the selected resource configurations. -// -// You can use this action to change the role roleARN and/or the recordingGroup -// of an existing recorder. To change the role, call the action on the existing -// configuration recorder and specify a role. -// -// Currently, you can specify only one configuration recorder per region in -// your account. +// GetComplianceSummaryByResourceType API operation for AWS Config. // -// If ConfigurationRecorder does not have the recordingGroup parameter specified, -// the default is to record all supported resource types. +// Returns the number of resources that are compliant and the number that are +// noncompliant. You can specify one or more resource types to get these numbers +// for each resource type. The maximum number returned is 100. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Config's -// API operation PutConfigurationRecorder for usage and error information. +// API operation GetComplianceSummaryByResourceType for usage and error information. // // Returned Error Codes: -// * ErrCodeMaxNumberOfConfigurationRecordersExceededException "MaxNumberOfConfigurationRecordersExceededException" -// You have reached the limit on the number of recorders you can create. -// -// * ErrCodeInvalidConfigurationRecorderNameException "InvalidConfigurationRecorderNameException" -// You have provided a configuration recorder name that is not valid. -// -// * ErrCodeInvalidRoleException "InvalidRoleException" -// You have provided a null or empty role ARN. -// -// * ErrCodeInvalidRecordingGroupException "InvalidRecordingGroupException" -// AWS Config throws an exception if the recording group does not contain a -// valid list of resource types. Invalid values could also be incorrectly formatted. +// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" +// One or more of the specified parameters are invalid. Verify that your parameters +// are valid and try again. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutConfigurationRecorder -func (c *ConfigService) PutConfigurationRecorder(input *PutConfigurationRecorderInput) (*PutConfigurationRecorderOutput, error) { - req, out := c.PutConfigurationRecorderRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetComplianceSummaryByResourceType +func (c *ConfigService) GetComplianceSummaryByResourceType(input *GetComplianceSummaryByResourceTypeInput) (*GetComplianceSummaryByResourceTypeOutput, error) { + req, out := c.GetComplianceSummaryByResourceTypeRequest(input) return out, req.Send() } -// PutConfigurationRecorderWithContext is the same as PutConfigurationRecorder with the addition of +// GetComplianceSummaryByResourceTypeWithContext is the same as GetComplianceSummaryByResourceType with the addition of // the ability to pass a context and additional request options. // -// See PutConfigurationRecorder for details on how to use this API operation. +// See GetComplianceSummaryByResourceType for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *ConfigService) PutConfigurationRecorderWithContext(ctx aws.Context, input *PutConfigurationRecorderInput, opts ...request.Option) (*PutConfigurationRecorderOutput, error) { - req, out := c.PutConfigurationRecorderRequest(input) +func (c *ConfigService) GetComplianceSummaryByResourceTypeWithContext(ctx aws.Context, input *GetComplianceSummaryByResourceTypeInput, opts ...request.Option) (*GetComplianceSummaryByResourceTypeOutput, error) { + req, out := c.GetComplianceSummaryByResourceTypeRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opPutDeliveryChannel = "PutDeliveryChannel" +const opGetDiscoveredResourceCounts = "GetDiscoveredResourceCounts" -// PutDeliveryChannelRequest generates a "aws/request.Request" representing the -// client's request for the PutDeliveryChannel operation. The "output" return -// value will be populated with the request's response once the request complets +// GetDiscoveredResourceCountsRequest generates a "aws/request.Request" representing the +// client's request for the GetDiscoveredResourceCounts operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See PutDeliveryChannel for more information on using the PutDeliveryChannel +// See GetDiscoveredResourceCounts for more information on using the GetDiscoveredResourceCounts // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the PutDeliveryChannelRequest method. -// req, resp := client.PutDeliveryChannelRequest(params) +// // Example sending a request using the GetDiscoveredResourceCountsRequest method. +// req, resp := client.GetDiscoveredResourceCountsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutDeliveryChannel -func (c *ConfigService) PutDeliveryChannelRequest(input *PutDeliveryChannelInput) (req *request.Request, output *PutDeliveryChannelOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetDiscoveredResourceCounts +func (c *ConfigService) GetDiscoveredResourceCountsRequest(input *GetDiscoveredResourceCountsInput) (req *request.Request, output *GetDiscoveredResourceCountsOutput) { op := &request.Operation{ - Name: opPutDeliveryChannel, + Name: opGetDiscoveredResourceCounts, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &PutDeliveryChannelInput{} + input = &GetDiscoveredResourceCountsInput{} } - output = &PutDeliveryChannelOutput{} + output = &GetDiscoveredResourceCountsOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) - req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } -// PutDeliveryChannel API operation for AWS Config. +// GetDiscoveredResourceCounts API operation for AWS Config. // -// Creates a delivery channel object to deliver configuration information to -// an Amazon S3 bucket and Amazon SNS topic. +// Returns the resource types, the number of each resource type, and the total +// number of resources that AWS Config is recording in this region for your +// AWS account. // -// Before you can create a delivery channel, you must create a configuration -// recorder. +// Example // -// You can use this action to change the Amazon S3 bucket or an Amazon SNS topic -// of the existing delivery channel. To change the Amazon S3 bucket or an Amazon -// SNS topic, call this action and specify the changed values for the S3 bucket -// and the SNS topic. If you specify a different value for either the S3 bucket -// or the SNS topic, this action will keep the existing value for the parameter -// that is not changed. +// AWS Config is recording three resource types in the US East (Ohio) Region +// for your account: 25 EC2 instances, 20 IAM users, and 15 S3 buckets. // -// You can have only one delivery channel per region in your account. +// You make a call to the GetDiscoveredResourceCounts action and specify that +// you want all resource types. +// +// AWS Config returns the following: +// +// The resource types (EC2 instances, IAM users, and S3 buckets). +// +// The number of each resource type (25, 20, and 15). +// +// The total number of all resources (60). +// +// The response is paginated. By default, AWS Config lists 100 ResourceCount +// objects on each page. You can customize this number with the limit parameter. +// The response includes a nextToken string. To get the next page of results, +// run the request again and specify the string for the nextToken parameter. +// +// If you make a call to the GetDiscoveredResourceCounts action, you might not +// immediately receive resource counts in the following situations: +// +// You are a new AWS Config customer. +// +// You just enabled resource recording. +// +// It might take a few minutes for AWS Config to record and count your resources. +// Wait a few minutes and then retry the GetDiscoveredResourceCounts action. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Config's -// API operation PutDeliveryChannel for usage and error information. +// API operation GetDiscoveredResourceCounts for usage and error information. // // Returned Error Codes: -// * ErrCodeMaxNumberOfDeliveryChannelsExceededException "MaxNumberOfDeliveryChannelsExceededException" -// You have reached the limit on the number of delivery channels you can create. -// -// * ErrCodeNoAvailableConfigurationRecorderException "NoAvailableConfigurationRecorderException" -// There are no configuration recorders available to provide the role needed -// to describe your resources. Create a configuration recorder. -// -// * ErrCodeInvalidDeliveryChannelNameException "InvalidDeliveryChannelNameException" -// The specified delivery channel name is not valid. -// -// * ErrCodeNoSuchBucketException "NoSuchBucketException" -// The specified Amazon S3 bucket does not exist. -// -// * ErrCodeInvalidS3KeyPrefixException "InvalidS3KeyPrefixException" -// The specified Amazon S3 key prefix is not valid. +// * ErrCodeValidationException "ValidationException" +// The requested action is not valid. // -// * ErrCodeInvalidSNSTopicARNException "InvalidSNSTopicARNException" -// The specified Amazon SNS topic does not exist. +// * ErrCodeInvalidLimitException "InvalidLimitException" +// The specified limit is outside the allowable range. // -// * ErrCodeInsufficientDeliveryPolicyException "InsufficientDeliveryPolicyException" -// Your Amazon S3 bucket policy does not permit AWS Config to write to it. +// * ErrCodeInvalidNextTokenException "InvalidNextTokenException" +// The specified next token is invalid. Specify the nextToken string that was +// returned in the previous response to get the next page of results. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutDeliveryChannel -func (c *ConfigService) PutDeliveryChannel(input *PutDeliveryChannelInput) (*PutDeliveryChannelOutput, error) { - req, out := c.PutDeliveryChannelRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetDiscoveredResourceCounts +func (c *ConfigService) GetDiscoveredResourceCounts(input *GetDiscoveredResourceCountsInput) (*GetDiscoveredResourceCountsOutput, error) { + req, out := c.GetDiscoveredResourceCountsRequest(input) return out, req.Send() } -// PutDeliveryChannelWithContext is the same as PutDeliveryChannel with the addition of +// GetDiscoveredResourceCountsWithContext is the same as GetDiscoveredResourceCounts with the addition of // the ability to pass a context and additional request options. // -// See PutDeliveryChannel for details on how to use this API operation. +// See GetDiscoveredResourceCounts for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *ConfigService) PutDeliveryChannelWithContext(ctx aws.Context, input *PutDeliveryChannelInput, opts ...request.Option) (*PutDeliveryChannelOutput, error) { - req, out := c.PutDeliveryChannelRequest(input) +func (c *ConfigService) GetDiscoveredResourceCountsWithContext(ctx aws.Context, input *GetDiscoveredResourceCountsInput, opts ...request.Option) (*GetDiscoveredResourceCountsOutput, error) { + req, out := c.GetDiscoveredResourceCountsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opPutEvaluations = "PutEvaluations" +const opGetResourceConfigHistory = "GetResourceConfigHistory" -// PutEvaluationsRequest generates a "aws/request.Request" representing the -// client's request for the PutEvaluations operation. The "output" return -// value will be populated with the request's response once the request complets +// GetResourceConfigHistoryRequest generates a "aws/request.Request" representing the +// client's request for the GetResourceConfigHistory operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See PutEvaluations for more information on using the PutEvaluations +// See GetResourceConfigHistory for more information on using the GetResourceConfigHistory // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the PutEvaluationsRequest method. -// req, resp := client.PutEvaluationsRequest(params) +// // Example sending a request using the GetResourceConfigHistoryRequest method. +// req, resp := client.GetResourceConfigHistoryRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutEvaluations -func (c *ConfigService) PutEvaluationsRequest(input *PutEvaluationsInput) (req *request.Request, output *PutEvaluationsOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetResourceConfigHistory +func (c *ConfigService) GetResourceConfigHistoryRequest(input *GetResourceConfigHistoryInput) (req *request.Request, output *GetResourceConfigHistoryOutput) { op := &request.Operation{ - Name: opPutEvaluations, + Name: opGetResourceConfigHistory, HTTPMethod: "POST", HTTPPath: "/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "limit", + TruncationToken: "", + }, } if input == nil { - input = &PutEvaluationsInput{} + input = &GetResourceConfigHistoryInput{} } - output = &PutEvaluationsOutput{} + output = &GetResourceConfigHistoryOutput{} req = c.newRequest(op, input, output) return } -// PutEvaluations API operation for AWS Config. +// GetResourceConfigHistory API operation for AWS Config. // -// Used by an AWS Lambda function to deliver evaluation results to AWS Config. -// This action is required in every AWS Lambda function that is invoked by an -// AWS Config rule. +// Returns a list of configuration items for the specified resource. The list +// contains details about each state of the resource during the specified time +// interval. +// +// The response is paginated. By default, AWS Config returns a limit of 10 configuration +// items per page. You can customize this number with the limit parameter. The +// response includes a nextToken string. To get the next page of results, run +// the request again and specify the string for the nextToken parameter. +// +// Each call to the API is limited to span a duration of seven days. It is likely +// that the number of records returned is smaller than the specified limit. +// In such cases, you can make another call, using the nextToken. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Config's -// API operation PutEvaluations for usage and error information. +// API operation GetResourceConfigHistory for usage and error information. // // Returned Error Codes: -// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" -// One or more of the specified parameters are invalid. Verify that your parameters -// are valid and try again. +// * ErrCodeValidationException "ValidationException" +// The requested action is not valid. // -// * ErrCodeInvalidResultTokenException "InvalidResultTokenException" -// The specified ResultToken is invalid. +// * ErrCodeInvalidTimeRangeException "InvalidTimeRangeException" +// The specified time range is not valid. The earlier time is not chronologically +// before the later time. // -// * ErrCodeNoSuchConfigRuleException "NoSuchConfigRuleException" -// One or more AWS Config rules in the request are invalid. Verify that the -// rule names are correct and try again. +// * ErrCodeInvalidLimitException "InvalidLimitException" +// The specified limit is outside the allowable range. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutEvaluations -func (c *ConfigService) PutEvaluations(input *PutEvaluationsInput) (*PutEvaluationsOutput, error) { - req, out := c.PutEvaluationsRequest(input) +// * ErrCodeInvalidNextTokenException "InvalidNextTokenException" +// The specified next token is invalid. Specify the nextToken string that was +// returned in the previous response to get the next page of results. +// +// * ErrCodeNoAvailableConfigurationRecorderException "NoAvailableConfigurationRecorderException" +// There are no configuration recorders available to provide the role needed +// to describe your resources. Create a configuration recorder. +// +// * ErrCodeResourceNotDiscoveredException "ResourceNotDiscoveredException" +// You have specified a resource that is either unknown or has not been discovered. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/GetResourceConfigHistory +func (c *ConfigService) GetResourceConfigHistory(input *GetResourceConfigHistoryInput) (*GetResourceConfigHistoryOutput, error) { + req, out := c.GetResourceConfigHistoryRequest(input) return out, req.Send() } -// PutEvaluationsWithContext is the same as PutEvaluations with the addition of +// GetResourceConfigHistoryWithContext is the same as GetResourceConfigHistory with the addition of // the ability to pass a context and additional request options. // -// See PutEvaluations for details on how to use this API operation. +// See GetResourceConfigHistory for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *ConfigService) PutEvaluationsWithContext(ctx aws.Context, input *PutEvaluationsInput, opts ...request.Option) (*PutEvaluationsOutput, error) { - req, out := c.PutEvaluationsRequest(input) +func (c *ConfigService) GetResourceConfigHistoryWithContext(ctx aws.Context, input *GetResourceConfigHistoryInput, opts ...request.Option) (*GetResourceConfigHistoryOutput, error) { + req, out := c.GetResourceConfigHistoryRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opStartConfigRulesEvaluation = "StartConfigRulesEvaluation" +// GetResourceConfigHistoryPages iterates over the pages of a GetResourceConfigHistory operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See GetResourceConfigHistory method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a GetResourceConfigHistory operation. +// pageNum := 0 +// err := client.GetResourceConfigHistoryPages(params, +// func(page *GetResourceConfigHistoryOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *ConfigService) GetResourceConfigHistoryPages(input *GetResourceConfigHistoryInput, fn func(*GetResourceConfigHistoryOutput, bool) bool) error { + return c.GetResourceConfigHistoryPagesWithContext(aws.BackgroundContext(), input, fn) +} -// StartConfigRulesEvaluationRequest generates a "aws/request.Request" representing the -// client's request for the StartConfigRulesEvaluation operation. The "output" return -// value will be populated with the request's response once the request complets +// GetResourceConfigHistoryPagesWithContext same as GetResourceConfigHistoryPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ConfigService) GetResourceConfigHistoryPagesWithContext(ctx aws.Context, input *GetResourceConfigHistoryInput, fn func(*GetResourceConfigHistoryOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *GetResourceConfigHistoryInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.GetResourceConfigHistoryRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*GetResourceConfigHistoryOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListDiscoveredResources = "ListDiscoveredResources" + +// ListDiscoveredResourcesRequest generates a "aws/request.Request" representing the +// client's request for the ListDiscoveredResources operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See StartConfigRulesEvaluation for more information on using the StartConfigRulesEvaluation +// See ListDiscoveredResources for more information on using the ListDiscoveredResources // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the StartConfigRulesEvaluationRequest method. -// req, resp := client.StartConfigRulesEvaluationRequest(params) +// // Example sending a request using the ListDiscoveredResourcesRequest method. +// req, resp := client.ListDiscoveredResourcesRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/StartConfigRulesEvaluation -func (c *ConfigService) StartConfigRulesEvaluationRequest(input *StartConfigRulesEvaluationInput) (req *request.Request, output *StartConfigRulesEvaluationOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/ListDiscoveredResources +func (c *ConfigService) ListDiscoveredResourcesRequest(input *ListDiscoveredResourcesInput) (req *request.Request, output *ListDiscoveredResourcesOutput) { op := &request.Operation{ - Name: opStartConfigRulesEvaluation, + Name: opListDiscoveredResources, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &StartConfigRulesEvaluationInput{} + input = &ListDiscoveredResourcesInput{} } - output = &StartConfigRulesEvaluationOutput{} + output = &ListDiscoveredResourcesOutput{} req = c.newRequest(op, input, output) return } -// StartConfigRulesEvaluation API operation for AWS Config. -// -// Runs an on-demand evaluation for the specified Config rules against the last -// known configuration state of the resources. Use StartConfigRulesEvaluation -// when you want to test a rule that you updated is working as expected. StartConfigRulesEvaluation -// does not re-record the latest configuration state for your resources; it -// re-runs an evaluation against the last known state of your resources. -// -// You can specify up to 25 Config rules per request. -// -// An existing StartConfigRulesEvaluation call must complete for the specified -// rules before you can call the API again. If you chose to have AWS Config -// stream to an Amazon SNS topic, you will receive a ConfigRuleEvaluationStarted -// notification when the evaluation starts. -// -// You don't need to call the StartConfigRulesEvaluation API to run an evaluation -// for a new rule. When you create a new rule, AWS Config automatically evaluates -// your resources against the rule. -// -// The StartConfigRulesEvaluation API is useful if you want to run on-demand -// evaluations, such as the following example: -// -// You have a custom rule that evaluates your IAM resources every 24 hours. -// -// You update your Lambda function to add additional conditions to your rule. +// ListDiscoveredResources API operation for AWS Config. // -// Instead of waiting for the next periodic evaluation, you call the StartConfigRulesEvaluation -// API. +// Accepts a resource type and returns a list of resource identifiers for the +// resources of that type. A resource identifier includes the resource type, +// ID, and (if available) the custom resource name. The results consist of resources +// that AWS Config has discovered, including those that AWS Config is not currently +// recording. You can narrow the results to include only resources that have +// specific resource IDs or a resource name. // -// AWS Config invokes your Lambda function and evaluates your IAM resources. +// You can specify either resource IDs or a resource name, but not both, in +// the same request. // -// Your custom rule will still run periodic evaluations every 24 hours. +// The response is paginated. By default, AWS Config lists 100 resource identifiers +// on each page. You can customize this number with the limit parameter. The +// response includes a nextToken string. To get the next page of results, run +// the request again and specify the string for the nextToken parameter. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Config's -// API operation StartConfigRulesEvaluation for usage and error information. +// API operation ListDiscoveredResources for usage and error information. // // Returned Error Codes: -// * ErrCodeNoSuchConfigRuleException "NoSuchConfigRuleException" -// One or more AWS Config rules in the request are invalid. Verify that the -// rule names are correct and try again. +// * ErrCodeValidationException "ValidationException" +// The requested action is not valid. // -// * ErrCodeLimitExceededException "LimitExceededException" -// This exception is thrown if an evaluation is in progress or if you call the -// StartConfigRulesEvaluation API more than once per minute. +// * ErrCodeInvalidLimitException "InvalidLimitException" +// The specified limit is outside the allowable range. // -// * ErrCodeResourceInUseException "ResourceInUseException" -// The rule is currently being deleted or the rule is deleting your evaluation -// results. Try your request again later. +// * ErrCodeInvalidNextTokenException "InvalidNextTokenException" +// The specified next token is invalid. Specify the nextToken string that was +// returned in the previous response to get the next page of results. // -// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" -// One or more of the specified parameters are invalid. Verify that your parameters -// are valid and try again. +// * ErrCodeNoAvailableConfigurationRecorderException "NoAvailableConfigurationRecorderException" +// There are no configuration recorders available to provide the role needed +// to describe your resources. Create a configuration recorder. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/StartConfigRulesEvaluation -func (c *ConfigService) StartConfigRulesEvaluation(input *StartConfigRulesEvaluationInput) (*StartConfigRulesEvaluationOutput, error) { - req, out := c.StartConfigRulesEvaluationRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/ListDiscoveredResources +func (c *ConfigService) ListDiscoveredResources(input *ListDiscoveredResourcesInput) (*ListDiscoveredResourcesOutput, error) { + req, out := c.ListDiscoveredResourcesRequest(input) return out, req.Send() } -// StartConfigRulesEvaluationWithContext is the same as StartConfigRulesEvaluation with the addition of +// ListDiscoveredResourcesWithContext is the same as ListDiscoveredResources with the addition of // the ability to pass a context and additional request options. // -// See StartConfigRulesEvaluation for details on how to use this API operation. +// See ListDiscoveredResources for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *ConfigService) StartConfigRulesEvaluationWithContext(ctx aws.Context, input *StartConfigRulesEvaluationInput, opts ...request.Option) (*StartConfigRulesEvaluationOutput, error) { - req, out := c.StartConfigRulesEvaluationRequest(input) +func (c *ConfigService) ListDiscoveredResourcesWithContext(ctx aws.Context, input *ListDiscoveredResourcesInput, opts ...request.Option) (*ListDiscoveredResourcesOutput, error) { + req, out := c.ListDiscoveredResourcesRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opStartConfigurationRecorder = "StartConfigurationRecorder" +const opPutAggregationAuthorization = "PutAggregationAuthorization" -// StartConfigurationRecorderRequest generates a "aws/request.Request" representing the -// client's request for the StartConfigurationRecorder operation. The "output" return -// value will be populated with the request's response once the request complets +// PutAggregationAuthorizationRequest generates a "aws/request.Request" representing the +// client's request for the PutAggregationAuthorization operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See StartConfigurationRecorder for more information on using the StartConfigurationRecorder +// See PutAggregationAuthorization for more information on using the PutAggregationAuthorization // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the StartConfigurationRecorderRequest method. -// req, resp := client.StartConfigurationRecorderRequest(params) +// // Example sending a request using the PutAggregationAuthorizationRequest method. +// req, resp := client.PutAggregationAuthorizationRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/StartConfigurationRecorder -func (c *ConfigService) StartConfigurationRecorderRequest(input *StartConfigurationRecorderInput) (req *request.Request, output *StartConfigurationRecorderOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutAggregationAuthorization +func (c *ConfigService) PutAggregationAuthorizationRequest(input *PutAggregationAuthorizationInput) (req *request.Request, output *PutAggregationAuthorizationOutput) { op := &request.Operation{ - Name: opStartConfigurationRecorder, + Name: opPutAggregationAuthorization, HTTPMethod: "POST", HTTPPath: "/", } - if input == nil { - input = &StartConfigurationRecorderInput{} + if input == nil { + input = &PutAggregationAuthorizationInput{} + } + + output = &PutAggregationAuthorizationOutput{} + req = c.newRequest(op, input, output) + return +} + +// PutAggregationAuthorization API operation for AWS Config. +// +// Authorizes the aggregator account and region to collect data from the source +// account and region. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Config's +// API operation PutAggregationAuthorization for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" +// One or more of the specified parameters are invalid. Verify that your parameters +// are valid and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutAggregationAuthorization +func (c *ConfigService) PutAggregationAuthorization(input *PutAggregationAuthorizationInput) (*PutAggregationAuthorizationOutput, error) { + req, out := c.PutAggregationAuthorizationRequest(input) + return out, req.Send() +} + +// PutAggregationAuthorizationWithContext is the same as PutAggregationAuthorization with the addition of +// the ability to pass a context and additional request options. +// +// See PutAggregationAuthorization for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ConfigService) PutAggregationAuthorizationWithContext(ctx aws.Context, input *PutAggregationAuthorizationInput, opts ...request.Option) (*PutAggregationAuthorizationOutput, error) { + req, out := c.PutAggregationAuthorizationRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opPutConfigRule = "PutConfigRule" + +// PutConfigRuleRequest generates a "aws/request.Request" representing the +// client's request for the PutConfigRule operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See PutConfigRule for more information on using the PutConfigRule +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the PutConfigRuleRequest method. +// req, resp := client.PutConfigRuleRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutConfigRule +func (c *ConfigService) PutConfigRuleRequest(input *PutConfigRuleInput) (req *request.Request, output *PutConfigRuleOutput) { + op := &request.Operation{ + Name: opPutConfigRule, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &PutConfigRuleInput{} + } + + output = &PutConfigRuleOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// PutConfigRule API operation for AWS Config. +// +// Adds or updates an AWS Config rule for evaluating whether your AWS resources +// comply with your desired configurations. +// +// You can use this action for custom AWS Config rules and AWS managed Config +// rules. A custom AWS Config rule is a rule that you develop and maintain. +// An AWS managed Config rule is a customizable, predefined rule that AWS Config +// provides. +// +// If you are adding a new custom AWS Config rule, you must first create the +// AWS Lambda function that the rule invokes to evaluate your resources. When +// you use the PutConfigRule action to add the rule to AWS Config, you must +// specify the Amazon Resource Name (ARN) that AWS Lambda assigns to the function. +// Specify the ARN for the SourceIdentifier key. This key is part of the Source +// object, which is part of the ConfigRule object. +// +// If you are adding an AWS managed Config rule, specify the rule's identifier +// for the SourceIdentifier key. To reference AWS managed Config rule identifiers, +// see About AWS Managed Config Rules (http://docs.aws.amazon.com/config/latest/developerguide/evaluate-config_use-managed-rules.html). +// +// For any new rule that you add, specify the ConfigRuleName in the ConfigRule +// object. Do not specify the ConfigRuleArn or the ConfigRuleId. These values +// are generated by AWS Config for new rules. +// +// If you are updating a rule that you added previously, you can specify the +// rule by ConfigRuleName, ConfigRuleId, or ConfigRuleArn in the ConfigRule +// data type that you use in this request. +// +// The maximum number of rules that AWS Config supports is 50. +// +// For information about requesting a rule limit increase, see AWS Config Limits +// (http://docs.aws.amazon.com/general/latest/gr/aws_service_limits.html#limits_config) +// in the AWS General Reference Guide. +// +// For more information about developing and using AWS Config rules, see Evaluating +// AWS Resource Configurations with AWS Config (http://docs.aws.amazon.com/config/latest/developerguide/evaluate-config.html) +// in the AWS Config Developer Guide. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Config's +// API operation PutConfigRule for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" +// One or more of the specified parameters are invalid. Verify that your parameters +// are valid and try again. +// +// * ErrCodeMaxNumberOfConfigRulesExceededException "MaxNumberOfConfigRulesExceededException" +// Failed to add the AWS Config rule because the account already contains the +// maximum number of 50 rules. Consider deleting any deactivated rules before +// you add new rules. +// +// * ErrCodeResourceInUseException "ResourceInUseException" +// The rule is currently being deleted or the rule is deleting your evaluation +// results. Try your request again later. +// +// * ErrCodeInsufficientPermissionsException "InsufficientPermissionsException" +// Indicates one of the following errors: +// +// * The rule cannot be created because the IAM role assigned to AWS Config +// lacks permissions to perform the config:Put* action. +// +// * The AWS Lambda function cannot be invoked. Check the function ARN, and +// check the function's permissions. +// +// * ErrCodeNoAvailableConfigurationRecorderException "NoAvailableConfigurationRecorderException" +// There are no configuration recorders available to provide the role needed +// to describe your resources. Create a configuration recorder. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutConfigRule +func (c *ConfigService) PutConfigRule(input *PutConfigRuleInput) (*PutConfigRuleOutput, error) { + req, out := c.PutConfigRuleRequest(input) + return out, req.Send() +} + +// PutConfigRuleWithContext is the same as PutConfigRule with the addition of +// the ability to pass a context and additional request options. +// +// See PutConfigRule for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ConfigService) PutConfigRuleWithContext(ctx aws.Context, input *PutConfigRuleInput, opts ...request.Option) (*PutConfigRuleOutput, error) { + req, out := c.PutConfigRuleRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opPutConfigurationAggregator = "PutConfigurationAggregator" + +// PutConfigurationAggregatorRequest generates a "aws/request.Request" representing the +// client's request for the PutConfigurationAggregator operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See PutConfigurationAggregator for more information on using the PutConfigurationAggregator +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the PutConfigurationAggregatorRequest method. +// req, resp := client.PutConfigurationAggregatorRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutConfigurationAggregator +func (c *ConfigService) PutConfigurationAggregatorRequest(input *PutConfigurationAggregatorInput) (req *request.Request, output *PutConfigurationAggregatorOutput) { + op := &request.Operation{ + Name: opPutConfigurationAggregator, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &PutConfigurationAggregatorInput{} + } + + output = &PutConfigurationAggregatorOutput{} + req = c.newRequest(op, input, output) + return +} + +// PutConfigurationAggregator API operation for AWS Config. +// +// Creates and updates the configuration aggregator with the selected source +// accounts and regions. +// +// AWS Config should be enabled in accounts and regions you want to aggreagate. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Config's +// API operation PutConfigurationAggregator for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" +// One or more of the specified parameters are invalid. Verify that your parameters +// are valid and try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// This exception is thrown if an evaluation is in progress or if you call the +// StartConfigRulesEvaluation API more than once per minute. +// +// * ErrCodeInvalidRoleException "InvalidRoleException" +// You have provided a null or empty role ARN. +// +// * ErrCodeOrganizationAccessDeniedException "OrganizationAccessDeniedException" +// No permission to call the EnableAWSServiceAccess API. +// +// * ErrCodeNoAvailableOrganizationException "NoAvailableOrganizationException" +// Organization does is no longer available. +// +// * ErrCodeOrganizationAllFeaturesNotEnabledException "OrganizationAllFeaturesNotEnabledException" +// The configuration aggregator cannot be created because organization does +// not have all features enabled. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutConfigurationAggregator +func (c *ConfigService) PutConfigurationAggregator(input *PutConfigurationAggregatorInput) (*PutConfigurationAggregatorOutput, error) { + req, out := c.PutConfigurationAggregatorRequest(input) + return out, req.Send() +} + +// PutConfigurationAggregatorWithContext is the same as PutConfigurationAggregator with the addition of +// the ability to pass a context and additional request options. +// +// See PutConfigurationAggregator for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ConfigService) PutConfigurationAggregatorWithContext(ctx aws.Context, input *PutConfigurationAggregatorInput, opts ...request.Option) (*PutConfigurationAggregatorOutput, error) { + req, out := c.PutConfigurationAggregatorRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opPutConfigurationRecorder = "PutConfigurationRecorder" + +// PutConfigurationRecorderRequest generates a "aws/request.Request" representing the +// client's request for the PutConfigurationRecorder operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See PutConfigurationRecorder for more information on using the PutConfigurationRecorder +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the PutConfigurationRecorderRequest method. +// req, resp := client.PutConfigurationRecorderRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutConfigurationRecorder +func (c *ConfigService) PutConfigurationRecorderRequest(input *PutConfigurationRecorderInput) (req *request.Request, output *PutConfigurationRecorderOutput) { + op := &request.Operation{ + Name: opPutConfigurationRecorder, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &PutConfigurationRecorderInput{} + } + + output = &PutConfigurationRecorderOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// PutConfigurationRecorder API operation for AWS Config. +// +// Creates a new configuration recorder to record the selected resource configurations. +// +// You can use this action to change the role roleARN or the recordingGroup +// of an existing recorder. To change the role, call the action on the existing +// configuration recorder and specify a role. +// +// Currently, you can specify only one configuration recorder per region in +// your account. +// +// If ConfigurationRecorder does not have the recordingGroup parameter specified, +// the default is to record all supported resource types. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Config's +// API operation PutConfigurationRecorder for usage and error information. +// +// Returned Error Codes: +// * ErrCodeMaxNumberOfConfigurationRecordersExceededException "MaxNumberOfConfigurationRecordersExceededException" +// You have reached the limit of the number of recorders you can create. +// +// * ErrCodeInvalidConfigurationRecorderNameException "InvalidConfigurationRecorderNameException" +// You have provided a configuration recorder name that is not valid. +// +// * ErrCodeInvalidRoleException "InvalidRoleException" +// You have provided a null or empty role ARN. +// +// * ErrCodeInvalidRecordingGroupException "InvalidRecordingGroupException" +// AWS Config throws an exception if the recording group does not contain a +// valid list of resource types. Invalid values might also be incorrectly formatted. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutConfigurationRecorder +func (c *ConfigService) PutConfigurationRecorder(input *PutConfigurationRecorderInput) (*PutConfigurationRecorderOutput, error) { + req, out := c.PutConfigurationRecorderRequest(input) + return out, req.Send() +} + +// PutConfigurationRecorderWithContext is the same as PutConfigurationRecorder with the addition of +// the ability to pass a context and additional request options. +// +// See PutConfigurationRecorder for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ConfigService) PutConfigurationRecorderWithContext(ctx aws.Context, input *PutConfigurationRecorderInput, opts ...request.Option) (*PutConfigurationRecorderOutput, error) { + req, out := c.PutConfigurationRecorderRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opPutDeliveryChannel = "PutDeliveryChannel" + +// PutDeliveryChannelRequest generates a "aws/request.Request" representing the +// client's request for the PutDeliveryChannel operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See PutDeliveryChannel for more information on using the PutDeliveryChannel +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the PutDeliveryChannelRequest method. +// req, resp := client.PutDeliveryChannelRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutDeliveryChannel +func (c *ConfigService) PutDeliveryChannelRequest(input *PutDeliveryChannelInput) (req *request.Request, output *PutDeliveryChannelOutput) { + op := &request.Operation{ + Name: opPutDeliveryChannel, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &PutDeliveryChannelInput{} + } + + output = &PutDeliveryChannelOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// PutDeliveryChannel API operation for AWS Config. +// +// Creates a delivery channel object to deliver configuration information to +// an Amazon S3 bucket and Amazon SNS topic. +// +// Before you can create a delivery channel, you must create a configuration +// recorder. +// +// You can use this action to change the Amazon S3 bucket or an Amazon SNS topic +// of the existing delivery channel. To change the Amazon S3 bucket or an Amazon +// SNS topic, call this action and specify the changed values for the S3 bucket +// and the SNS topic. If you specify a different value for either the S3 bucket +// or the SNS topic, this action will keep the existing value for the parameter +// that is not changed. +// +// You can have only one delivery channel per region in your account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Config's +// API operation PutDeliveryChannel for usage and error information. +// +// Returned Error Codes: +// * ErrCodeMaxNumberOfDeliveryChannelsExceededException "MaxNumberOfDeliveryChannelsExceededException" +// You have reached the limit of the number of delivery channels you can create. +// +// * ErrCodeNoAvailableConfigurationRecorderException "NoAvailableConfigurationRecorderException" +// There are no configuration recorders available to provide the role needed +// to describe your resources. Create a configuration recorder. +// +// * ErrCodeInvalidDeliveryChannelNameException "InvalidDeliveryChannelNameException" +// The specified delivery channel name is not valid. +// +// * ErrCodeNoSuchBucketException "NoSuchBucketException" +// The specified Amazon S3 bucket does not exist. +// +// * ErrCodeInvalidS3KeyPrefixException "InvalidS3KeyPrefixException" +// The specified Amazon S3 key prefix is not valid. +// +// * ErrCodeInvalidSNSTopicARNException "InvalidSNSTopicARNException" +// The specified Amazon SNS topic does not exist. +// +// * ErrCodeInsufficientDeliveryPolicyException "InsufficientDeliveryPolicyException" +// Your Amazon S3 bucket policy does not permit AWS Config to write to it. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutDeliveryChannel +func (c *ConfigService) PutDeliveryChannel(input *PutDeliveryChannelInput) (*PutDeliveryChannelOutput, error) { + req, out := c.PutDeliveryChannelRequest(input) + return out, req.Send() +} + +// PutDeliveryChannelWithContext is the same as PutDeliveryChannel with the addition of +// the ability to pass a context and additional request options. +// +// See PutDeliveryChannel for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ConfigService) PutDeliveryChannelWithContext(ctx aws.Context, input *PutDeliveryChannelInput, opts ...request.Option) (*PutDeliveryChannelOutput, error) { + req, out := c.PutDeliveryChannelRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opPutEvaluations = "PutEvaluations" + +// PutEvaluationsRequest generates a "aws/request.Request" representing the +// client's request for the PutEvaluations operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See PutEvaluations for more information on using the PutEvaluations +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the PutEvaluationsRequest method. +// req, resp := client.PutEvaluationsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutEvaluations +func (c *ConfigService) PutEvaluationsRequest(input *PutEvaluationsInput) (req *request.Request, output *PutEvaluationsOutput) { + op := &request.Operation{ + Name: opPutEvaluations, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &PutEvaluationsInput{} + } + + output = &PutEvaluationsOutput{} + req = c.newRequest(op, input, output) + return +} + +// PutEvaluations API operation for AWS Config. +// +// Used by an AWS Lambda function to deliver evaluation results to AWS Config. +// This action is required in every AWS Lambda function that is invoked by an +// AWS Config rule. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Config's +// API operation PutEvaluations for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" +// One or more of the specified parameters are invalid. Verify that your parameters +// are valid and try again. +// +// * ErrCodeInvalidResultTokenException "InvalidResultTokenException" +// The specified ResultToken is invalid. +// +// * ErrCodeNoSuchConfigRuleException "NoSuchConfigRuleException" +// One or more AWS Config rules in the request are invalid. Verify that the +// rule names are correct and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/PutEvaluations +func (c *ConfigService) PutEvaluations(input *PutEvaluationsInput) (*PutEvaluationsOutput, error) { + req, out := c.PutEvaluationsRequest(input) + return out, req.Send() +} + +// PutEvaluationsWithContext is the same as PutEvaluations with the addition of +// the ability to pass a context and additional request options. +// +// See PutEvaluations for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ConfigService) PutEvaluationsWithContext(ctx aws.Context, input *PutEvaluationsInput, opts ...request.Option) (*PutEvaluationsOutput, error) { + req, out := c.PutEvaluationsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opStartConfigRulesEvaluation = "StartConfigRulesEvaluation" + +// StartConfigRulesEvaluationRequest generates a "aws/request.Request" representing the +// client's request for the StartConfigRulesEvaluation operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See StartConfigRulesEvaluation for more information on using the StartConfigRulesEvaluation +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the StartConfigRulesEvaluationRequest method. +// req, resp := client.StartConfigRulesEvaluationRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/StartConfigRulesEvaluation +func (c *ConfigService) StartConfigRulesEvaluationRequest(input *StartConfigRulesEvaluationInput) (req *request.Request, output *StartConfigRulesEvaluationOutput) { + op := &request.Operation{ + Name: opStartConfigRulesEvaluation, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &StartConfigRulesEvaluationInput{} + } + + output = &StartConfigRulesEvaluationOutput{} + req = c.newRequest(op, input, output) + return +} + +// StartConfigRulesEvaluation API operation for AWS Config. +// +// Runs an on-demand evaluation for the specified AWS Config rules against the +// last known configuration state of the resources. Use StartConfigRulesEvaluation +// when you want to test that a rule you updated is working as expected. StartConfigRulesEvaluation +// does not re-record the latest configuration state for your resources. It +// re-runs an evaluation against the last known state of your resources. +// +// You can specify up to 25 AWS Config rules per request. +// +// An existing StartConfigRulesEvaluation call for the specified rules must +// complete before you can call the API again. If you chose to have AWS Config +// stream to an Amazon SNS topic, you will receive a ConfigRuleEvaluationStarted +// notification when the evaluation starts. +// +// You don't need to call the StartConfigRulesEvaluation API to run an evaluation +// for a new rule. When you create a rule, AWS Config evaluates your resources +// against the rule automatically. +// +// The StartConfigRulesEvaluation API is useful if you want to run on-demand +// evaluations, such as the following example: +// +// You have a custom rule that evaluates your IAM resources every 24 hours. +// +// You update your Lambda function to add additional conditions to your rule. +// +// Instead of waiting for the next periodic evaluation, you call the StartConfigRulesEvaluation +// API. +// +// AWS Config invokes your Lambda function and evaluates your IAM resources. +// +// Your custom rule will still run periodic evaluations every 24 hours. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Config's +// API operation StartConfigRulesEvaluation for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNoSuchConfigRuleException "NoSuchConfigRuleException" +// One or more AWS Config rules in the request are invalid. Verify that the +// rule names are correct and try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// This exception is thrown if an evaluation is in progress or if you call the +// StartConfigRulesEvaluation API more than once per minute. +// +// * ErrCodeResourceInUseException "ResourceInUseException" +// The rule is currently being deleted or the rule is deleting your evaluation +// results. Try your request again later. +// +// * ErrCodeInvalidParameterValueException "InvalidParameterValueException" +// One or more of the specified parameters are invalid. Verify that your parameters +// are valid and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/StartConfigRulesEvaluation +func (c *ConfigService) StartConfigRulesEvaluation(input *StartConfigRulesEvaluationInput) (*StartConfigRulesEvaluationOutput, error) { + req, out := c.StartConfigRulesEvaluationRequest(input) + return out, req.Send() +} + +// StartConfigRulesEvaluationWithContext is the same as StartConfigRulesEvaluation with the addition of +// the ability to pass a context and additional request options. +// +// See StartConfigRulesEvaluation for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ConfigService) StartConfigRulesEvaluationWithContext(ctx aws.Context, input *StartConfigRulesEvaluationInput, opts ...request.Option) (*StartConfigRulesEvaluationOutput, error) { + req, out := c.StartConfigRulesEvaluationRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opStartConfigurationRecorder = "StartConfigurationRecorder" + +// StartConfigurationRecorderRequest generates a "aws/request.Request" representing the +// client's request for the StartConfigurationRecorder operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See StartConfigurationRecorder for more information on using the StartConfigurationRecorder +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the StartConfigurationRecorderRequest method. +// req, resp := client.StartConfigurationRecorderRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/StartConfigurationRecorder +func (c *ConfigService) StartConfigurationRecorderRequest(input *StartConfigurationRecorderInput) (req *request.Request, output *StartConfigurationRecorderOutput) { + op := &request.Operation{ + Name: opStartConfigurationRecorder, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &StartConfigurationRecorderInput{} + } + + output = &StartConfigurationRecorderOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// StartConfigurationRecorder API operation for AWS Config. +// +// Starts recording configurations of the AWS resources you have selected to +// record in your AWS account. +// +// You must have created at least one delivery channel to successfully start +// the configuration recorder. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Config's +// API operation StartConfigurationRecorder for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNoSuchConfigurationRecorderException "NoSuchConfigurationRecorderException" +// You have specified a configuration recorder that does not exist. +// +// * ErrCodeNoAvailableDeliveryChannelException "NoAvailableDeliveryChannelException" +// There is no delivery channel available to record configurations. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/StartConfigurationRecorder +func (c *ConfigService) StartConfigurationRecorder(input *StartConfigurationRecorderInput) (*StartConfigurationRecorderOutput, error) { + req, out := c.StartConfigurationRecorderRequest(input) + return out, req.Send() +} + +// StartConfigurationRecorderWithContext is the same as StartConfigurationRecorder with the addition of +// the ability to pass a context and additional request options. +// +// See StartConfigurationRecorder for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ConfigService) StartConfigurationRecorderWithContext(ctx aws.Context, input *StartConfigurationRecorderInput, opts ...request.Option) (*StartConfigurationRecorderOutput, error) { + req, out := c.StartConfigurationRecorderRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opStopConfigurationRecorder = "StopConfigurationRecorder" + +// StopConfigurationRecorderRequest generates a "aws/request.Request" representing the +// client's request for the StopConfigurationRecorder operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See StopConfigurationRecorder for more information on using the StopConfigurationRecorder +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the StopConfigurationRecorderRequest method. +// req, resp := client.StopConfigurationRecorderRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/StopConfigurationRecorder +func (c *ConfigService) StopConfigurationRecorderRequest(input *StopConfigurationRecorderInput) (req *request.Request, output *StopConfigurationRecorderOutput) { + op := &request.Operation{ + Name: opStopConfigurationRecorder, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &StopConfigurationRecorderInput{} + } + + output = &StopConfigurationRecorderOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// StopConfigurationRecorder API operation for AWS Config. +// +// Stops recording configurations of the AWS resources you have selected to +// record in your AWS account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Config's +// API operation StopConfigurationRecorder for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNoSuchConfigurationRecorderException "NoSuchConfigurationRecorderException" +// You have specified a configuration recorder that does not exist. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/StopConfigurationRecorder +func (c *ConfigService) StopConfigurationRecorder(input *StopConfigurationRecorderInput) (*StopConfigurationRecorderOutput, error) { + req, out := c.StopConfigurationRecorderRequest(input) + return out, req.Send() +} + +// StopConfigurationRecorderWithContext is the same as StopConfigurationRecorder with the addition of +// the ability to pass a context and additional request options. +// +// See StopConfigurationRecorder for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ConfigService) StopConfigurationRecorderWithContext(ctx aws.Context, input *StopConfigurationRecorderInput, opts ...request.Option) (*StopConfigurationRecorderOutput, error) { + req, out := c.StopConfigurationRecorderRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// A collection of accounts and regions. +type AccountAggregationSource struct { + _ struct{} `type:"structure"` + + // The 12-digit account ID of the account being aggregated. + // + // AccountIds is a required field + AccountIds []*string `min:"1" type:"list" required:"true"` + + // If true, aggreagate existing AWS Config regions and future regions. + AllAwsRegions *bool `type:"boolean"` + + // The source regions being aggregated. + AwsRegions []*string `min:"1" type:"list"` +} + +// String returns the string representation +func (s AccountAggregationSource) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s AccountAggregationSource) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *AccountAggregationSource) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "AccountAggregationSource"} + if s.AccountIds == nil { + invalidParams.Add(request.NewErrParamRequired("AccountIds")) + } + if s.AccountIds != nil && len(s.AccountIds) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AccountIds", 1)) + } + if s.AwsRegions != nil && len(s.AwsRegions) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AwsRegions", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAccountIds sets the AccountIds field's value. +func (s *AccountAggregationSource) SetAccountIds(v []*string) *AccountAggregationSource { + s.AccountIds = v + return s +} + +// SetAllAwsRegions sets the AllAwsRegions field's value. +func (s *AccountAggregationSource) SetAllAwsRegions(v bool) *AccountAggregationSource { + s.AllAwsRegions = &v + return s +} + +// SetAwsRegions sets the AwsRegions field's value. +func (s *AccountAggregationSource) SetAwsRegions(v []*string) *AccountAggregationSource { + s.AwsRegions = v + return s +} + +// Indicates whether an AWS Config rule is compliant based on account ID, region, +// compliance, and rule name. +// +// A rule is compliant if all of the resources that the rule evaluated comply +// with it. It is noncompliant if any of these resources do not comply. +type AggregateComplianceByConfigRule struct { + _ struct{} `type:"structure"` + + // The 12-digit account ID of the source account. + AccountId *string `type:"string"` + + // The source region from where the data is aggregated. + AwsRegion *string `min:"1" type:"string"` + + // Indicates whether an AWS resource or AWS Config rule is compliant and provides + // the number of contributors that affect the compliance. + Compliance *Compliance `type:"structure"` + + // The name of the AWS Config rule. + ConfigRuleName *string `min:"1" type:"string"` +} + +// String returns the string representation +func (s AggregateComplianceByConfigRule) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s AggregateComplianceByConfigRule) GoString() string { + return s.String() +} + +// SetAccountId sets the AccountId field's value. +func (s *AggregateComplianceByConfigRule) SetAccountId(v string) *AggregateComplianceByConfigRule { + s.AccountId = &v + return s +} + +// SetAwsRegion sets the AwsRegion field's value. +func (s *AggregateComplianceByConfigRule) SetAwsRegion(v string) *AggregateComplianceByConfigRule { + s.AwsRegion = &v + return s +} + +// SetCompliance sets the Compliance field's value. +func (s *AggregateComplianceByConfigRule) SetCompliance(v *Compliance) *AggregateComplianceByConfigRule { + s.Compliance = v + return s +} + +// SetConfigRuleName sets the ConfigRuleName field's value. +func (s *AggregateComplianceByConfigRule) SetConfigRuleName(v string) *AggregateComplianceByConfigRule { + s.ConfigRuleName = &v + return s +} + +// Returns the number of compliant and noncompliant rules for one or more accounts +// and regions in an aggregator. +type AggregateComplianceCount struct { + _ struct{} `type:"structure"` + + // The number of compliant and noncompliant AWS Config rules. + ComplianceSummary *ComplianceSummary `type:"structure"` + + // The 12-digit account ID or region based on the GroupByKey value. + GroupName *string `min:"1" type:"string"` +} + +// String returns the string representation +func (s AggregateComplianceCount) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s AggregateComplianceCount) GoString() string { + return s.String() +} + +// SetComplianceSummary sets the ComplianceSummary field's value. +func (s *AggregateComplianceCount) SetComplianceSummary(v *ComplianceSummary) *AggregateComplianceCount { + s.ComplianceSummary = v + return s +} + +// SetGroupName sets the GroupName field's value. +func (s *AggregateComplianceCount) SetGroupName(v string) *AggregateComplianceCount { + s.GroupName = &v + return s +} + +// The details of an AWS Config evaluation for an account ID and region in an +// aggregator. Provides the AWS resource that was evaluated, the compliance +// of the resource, related time stamps, and supplementary information. +type AggregateEvaluationResult struct { + _ struct{} `type:"structure"` + + // The 12-digit account ID of the source account. + AccountId *string `type:"string"` + + // Supplementary information about how the agrregate evaluation determined the + // compliance. + Annotation *string `min:"1" type:"string"` + + // The source region from where the data is aggregated. + AwsRegion *string `min:"1" type:"string"` + + // The resource compliance status. + // + // For the AggregationEvaluationResult data type, AWS Config supports only the + // COMPLIANT and NON_COMPLIANT. AWS Config does not support the NOT_APPLICABLE + // and INSUFFICIENT_DATA value. + ComplianceType *string `type:"string" enum:"ComplianceType"` + + // The time when the AWS Config rule evaluated the AWS resource. + ConfigRuleInvokedTime *time.Time `type:"timestamp" timestampFormat:"unix"` + + // Uniquely identifies the evaluation result. + EvaluationResultIdentifier *EvaluationResultIdentifier `type:"structure"` + + // The time when AWS Config recorded the aggregate evaluation result. + ResultRecordedTime *time.Time `type:"timestamp" timestampFormat:"unix"` +} + +// String returns the string representation +func (s AggregateEvaluationResult) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s AggregateEvaluationResult) GoString() string { + return s.String() +} + +// SetAccountId sets the AccountId field's value. +func (s *AggregateEvaluationResult) SetAccountId(v string) *AggregateEvaluationResult { + s.AccountId = &v + return s +} + +// SetAnnotation sets the Annotation field's value. +func (s *AggregateEvaluationResult) SetAnnotation(v string) *AggregateEvaluationResult { + s.Annotation = &v + return s +} + +// SetAwsRegion sets the AwsRegion field's value. +func (s *AggregateEvaluationResult) SetAwsRegion(v string) *AggregateEvaluationResult { + s.AwsRegion = &v + return s +} + +// SetComplianceType sets the ComplianceType field's value. +func (s *AggregateEvaluationResult) SetComplianceType(v string) *AggregateEvaluationResult { + s.ComplianceType = &v + return s +} + +// SetConfigRuleInvokedTime sets the ConfigRuleInvokedTime field's value. +func (s *AggregateEvaluationResult) SetConfigRuleInvokedTime(v time.Time) *AggregateEvaluationResult { + s.ConfigRuleInvokedTime = &v + return s +} + +// SetEvaluationResultIdentifier sets the EvaluationResultIdentifier field's value. +func (s *AggregateEvaluationResult) SetEvaluationResultIdentifier(v *EvaluationResultIdentifier) *AggregateEvaluationResult { + s.EvaluationResultIdentifier = v + return s +} + +// SetResultRecordedTime sets the ResultRecordedTime field's value. +func (s *AggregateEvaluationResult) SetResultRecordedTime(v time.Time) *AggregateEvaluationResult { + s.ResultRecordedTime = &v + return s +} + +// The current sync status between the source and the aggregator account. +type AggregatedSourceStatus struct { + _ struct{} `type:"structure"` + + // The region authorized to collect aggregated data. + AwsRegion *string `min:"1" type:"string"` + + // The error code that AWS Config returned when the source account aggregation + // last failed. + LastErrorCode *string `type:"string"` + + // The message indicating that the source account aggregation failed due to + // an error. + LastErrorMessage *string `type:"string"` + + // Filters the last updated status type. + // + // * Valid value FAILED indicates errors while moving data. + // + // * Valid value SUCCEEDED indicates the data was successfully moved. + // + // * Valid value OUTDATED indicates the data is not the most recent. + LastUpdateStatus *string `type:"string" enum:"AggregatedSourceStatusType"` + + // The time of the last update. + LastUpdateTime *time.Time `type:"timestamp" timestampFormat:"unix"` + + // The source account ID or an organization. + SourceId *string `type:"string"` + + // The source account or an organization. + SourceType *string `type:"string" enum:"AggregatedSourceType"` +} + +// String returns the string representation +func (s AggregatedSourceStatus) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s AggregatedSourceStatus) GoString() string { + return s.String() +} + +// SetAwsRegion sets the AwsRegion field's value. +func (s *AggregatedSourceStatus) SetAwsRegion(v string) *AggregatedSourceStatus { + s.AwsRegion = &v + return s +} + +// SetLastErrorCode sets the LastErrorCode field's value. +func (s *AggregatedSourceStatus) SetLastErrorCode(v string) *AggregatedSourceStatus { + s.LastErrorCode = &v + return s +} + +// SetLastErrorMessage sets the LastErrorMessage field's value. +func (s *AggregatedSourceStatus) SetLastErrorMessage(v string) *AggregatedSourceStatus { + s.LastErrorMessage = &v + return s +} + +// SetLastUpdateStatus sets the LastUpdateStatus field's value. +func (s *AggregatedSourceStatus) SetLastUpdateStatus(v string) *AggregatedSourceStatus { + s.LastUpdateStatus = &v + return s +} + +// SetLastUpdateTime sets the LastUpdateTime field's value. +func (s *AggregatedSourceStatus) SetLastUpdateTime(v time.Time) *AggregatedSourceStatus { + s.LastUpdateTime = &v + return s +} + +// SetSourceId sets the SourceId field's value. +func (s *AggregatedSourceStatus) SetSourceId(v string) *AggregatedSourceStatus { + s.SourceId = &v + return s +} + +// SetSourceType sets the SourceType field's value. +func (s *AggregatedSourceStatus) SetSourceType(v string) *AggregatedSourceStatus { + s.SourceType = &v + return s +} + +// An object that represents the authorizations granted to aggregator accounts +// and regions. +type AggregationAuthorization struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the aggregation object. + AggregationAuthorizationArn *string `type:"string"` + + // The 12-digit account ID of the account authorized to aggregate data. + AuthorizedAccountId *string `type:"string"` + + // The region authorized to collect aggregated data. + AuthorizedAwsRegion *string `min:"1" type:"string"` + + // The time stamp when the aggregation authorization was created. + CreationTime *time.Time `type:"timestamp" timestampFormat:"unix"` +} + +// String returns the string representation +func (s AggregationAuthorization) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s AggregationAuthorization) GoString() string { + return s.String() +} + +// SetAggregationAuthorizationArn sets the AggregationAuthorizationArn field's value. +func (s *AggregationAuthorization) SetAggregationAuthorizationArn(v string) *AggregationAuthorization { + s.AggregationAuthorizationArn = &v + return s +} + +// SetAuthorizedAccountId sets the AuthorizedAccountId field's value. +func (s *AggregationAuthorization) SetAuthorizedAccountId(v string) *AggregationAuthorization { + s.AuthorizedAccountId = &v + return s +} + +// SetAuthorizedAwsRegion sets the AuthorizedAwsRegion field's value. +func (s *AggregationAuthorization) SetAuthorizedAwsRegion(v string) *AggregationAuthorization { + s.AuthorizedAwsRegion = &v + return s +} + +// SetCreationTime sets the CreationTime field's value. +func (s *AggregationAuthorization) SetCreationTime(v time.Time) *AggregationAuthorization { + s.CreationTime = &v + return s +} + +// The detailed configuration of a specified resource. +type BaseConfigurationItem struct { + _ struct{} `type:"structure"` + + // The 12 digit AWS account ID associated with the resource. + AccountId *string `locationName:"accountId" type:"string"` + + // The Amazon Resource Name (ARN) of the resource. + Arn *string `locationName:"arn" type:"string"` + + // The Availability Zone associated with the resource. + AvailabilityZone *string `locationName:"availabilityZone" type:"string"` + + // The region where the resource resides. + AwsRegion *string `locationName:"awsRegion" min:"1" type:"string"` + + // The description of the resource configuration. + Configuration *string `locationName:"configuration" type:"string"` + + // The time when the configuration recording was initiated. + ConfigurationItemCaptureTime *time.Time `locationName:"configurationItemCaptureTime" type:"timestamp" timestampFormat:"unix"` + + // The configuration item status. + ConfigurationItemStatus *string `locationName:"configurationItemStatus" type:"string" enum:"ConfigurationItemStatus"` + + // An identifier that indicates the ordering of the configuration items of a + // resource. + ConfigurationStateId *string `locationName:"configurationStateId" type:"string"` + + // The time stamp when the resource was created. + ResourceCreationTime *time.Time `locationName:"resourceCreationTime" type:"timestamp" timestampFormat:"unix"` + + // The ID of the resource (for example., sg-xxxxxx). + ResourceId *string `locationName:"resourceId" type:"string"` + + // The custom name of the resource, if available. + ResourceName *string `locationName:"resourceName" type:"string"` + + // The type of AWS resource. + ResourceType *string `locationName:"resourceType" type:"string" enum:"ResourceType"` + + // Configuration attributes that AWS Config returns for certain resource types + // to supplement the information returned for the configuration parameter. + SupplementaryConfiguration map[string]*string `locationName:"supplementaryConfiguration" type:"map"` + + // The version number of the resource configuration. + Version *string `locationName:"version" type:"string"` +} + +// String returns the string representation +func (s BaseConfigurationItem) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s BaseConfigurationItem) GoString() string { + return s.String() +} + +// SetAccountId sets the AccountId field's value. +func (s *BaseConfigurationItem) SetAccountId(v string) *BaseConfigurationItem { + s.AccountId = &v + return s +} + +// SetArn sets the Arn field's value. +func (s *BaseConfigurationItem) SetArn(v string) *BaseConfigurationItem { + s.Arn = &v + return s +} + +// SetAvailabilityZone sets the AvailabilityZone field's value. +func (s *BaseConfigurationItem) SetAvailabilityZone(v string) *BaseConfigurationItem { + s.AvailabilityZone = &v + return s +} + +// SetAwsRegion sets the AwsRegion field's value. +func (s *BaseConfigurationItem) SetAwsRegion(v string) *BaseConfigurationItem { + s.AwsRegion = &v + return s +} + +// SetConfiguration sets the Configuration field's value. +func (s *BaseConfigurationItem) SetConfiguration(v string) *BaseConfigurationItem { + s.Configuration = &v + return s +} + +// SetConfigurationItemCaptureTime sets the ConfigurationItemCaptureTime field's value. +func (s *BaseConfigurationItem) SetConfigurationItemCaptureTime(v time.Time) *BaseConfigurationItem { + s.ConfigurationItemCaptureTime = &v + return s +} + +// SetConfigurationItemStatus sets the ConfigurationItemStatus field's value. +func (s *BaseConfigurationItem) SetConfigurationItemStatus(v string) *BaseConfigurationItem { + s.ConfigurationItemStatus = &v + return s +} + +// SetConfigurationStateId sets the ConfigurationStateId field's value. +func (s *BaseConfigurationItem) SetConfigurationStateId(v string) *BaseConfigurationItem { + s.ConfigurationStateId = &v + return s +} + +// SetResourceCreationTime sets the ResourceCreationTime field's value. +func (s *BaseConfigurationItem) SetResourceCreationTime(v time.Time) *BaseConfigurationItem { + s.ResourceCreationTime = &v + return s +} + +// SetResourceId sets the ResourceId field's value. +func (s *BaseConfigurationItem) SetResourceId(v string) *BaseConfigurationItem { + s.ResourceId = &v + return s +} + +// SetResourceName sets the ResourceName field's value. +func (s *BaseConfigurationItem) SetResourceName(v string) *BaseConfigurationItem { + s.ResourceName = &v + return s +} + +// SetResourceType sets the ResourceType field's value. +func (s *BaseConfigurationItem) SetResourceType(v string) *BaseConfigurationItem { + s.ResourceType = &v + return s +} + +// SetSupplementaryConfiguration sets the SupplementaryConfiguration field's value. +func (s *BaseConfigurationItem) SetSupplementaryConfiguration(v map[string]*string) *BaseConfigurationItem { + s.SupplementaryConfiguration = v + return s +} + +// SetVersion sets the Version field's value. +func (s *BaseConfigurationItem) SetVersion(v string) *BaseConfigurationItem { + s.Version = &v + return s +} + +type BatchGetResourceConfigInput struct { + _ struct{} `type:"structure"` + + // A list of resource keys to be processed with the current request. Each element + // in the list consists of the resource type and resource ID. + // + // ResourceKeys is a required field + ResourceKeys []*ResourceKey `locationName:"resourceKeys" min:"1" type:"list" required:"true"` +} + +// String returns the string representation +func (s BatchGetResourceConfigInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s BatchGetResourceConfigInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *BatchGetResourceConfigInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "BatchGetResourceConfigInput"} + if s.ResourceKeys == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceKeys")) + } + if s.ResourceKeys != nil && len(s.ResourceKeys) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ResourceKeys", 1)) + } + if s.ResourceKeys != nil { + for i, v := range s.ResourceKeys { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ResourceKeys", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams } - - output = &StartConfigurationRecorderOutput{} - req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) - req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) - return + return nil } -// StartConfigurationRecorder API operation for AWS Config. -// -// Starts recording configurations of the AWS resources you have selected to -// record in your AWS account. -// -// You must have created at least one delivery channel to successfully start -// the configuration recorder. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Config's -// API operation StartConfigurationRecorder for usage and error information. -// -// Returned Error Codes: -// * ErrCodeNoSuchConfigurationRecorderException "NoSuchConfigurationRecorderException" -// You have specified a configuration recorder that does not exist. -// -// * ErrCodeNoAvailableDeliveryChannelException "NoAvailableDeliveryChannelException" -// There is no delivery channel available to record configurations. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/StartConfigurationRecorder -func (c *ConfigService) StartConfigurationRecorder(input *StartConfigurationRecorderInput) (*StartConfigurationRecorderOutput, error) { - req, out := c.StartConfigurationRecorderRequest(input) - return out, req.Send() +// SetResourceKeys sets the ResourceKeys field's value. +func (s *BatchGetResourceConfigInput) SetResourceKeys(v []*ResourceKey) *BatchGetResourceConfigInput { + s.ResourceKeys = v + return s } -// StartConfigurationRecorderWithContext is the same as StartConfigurationRecorder with the addition of -// the ability to pass a context and additional request options. -// -// See StartConfigurationRecorder for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ConfigService) StartConfigurationRecorderWithContext(ctx aws.Context, input *StartConfigurationRecorderInput, opts ...request.Option) (*StartConfigurationRecorderOutput, error) { - req, out := c.StartConfigurationRecorderRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} +type BatchGetResourceConfigOutput struct { + _ struct{} `type:"structure"` -const opStopConfigurationRecorder = "StopConfigurationRecorder" + // A list that contains the current configuration of one or more resources. + BaseConfigurationItems []*BaseConfigurationItem `locationName:"baseConfigurationItems" type:"list"` -// StopConfigurationRecorderRequest generates a "aws/request.Request" representing the -// client's request for the StopConfigurationRecorder operation. The "output" return -// value will be populated with the request's response once the request complets -// successfuly. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See StopConfigurationRecorder for more information on using the StopConfigurationRecorder -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the StopConfigurationRecorderRequest method. -// req, resp := client.StopConfigurationRecorderRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/StopConfigurationRecorder -func (c *ConfigService) StopConfigurationRecorderRequest(input *StopConfigurationRecorderInput) (req *request.Request, output *StopConfigurationRecorderOutput) { - op := &request.Operation{ - Name: opStopConfigurationRecorder, - HTTPMethod: "POST", - HTTPPath: "/", - } + // A list of resource keys that were not processed with the current response. + // The unprocessesResourceKeys value is in the same form as ResourceKeys, so + // the value can be directly provided to a subsequent BatchGetResourceConfig + // operation. If there are no unprocessed resource keys, the response contains + // an empty unprocessedResourceKeys list. + UnprocessedResourceKeys []*ResourceKey `locationName:"unprocessedResourceKeys" min:"1" type:"list"` +} - if input == nil { - input = &StopConfigurationRecorderInput{} - } +// String returns the string representation +func (s BatchGetResourceConfigOutput) String() string { + return awsutil.Prettify(s) +} - output = &StopConfigurationRecorderOutput{} - req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) - req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) - return +// GoString returns the string representation +func (s BatchGetResourceConfigOutput) GoString() string { + return s.String() } -// StopConfigurationRecorder API operation for AWS Config. -// -// Stops recording configurations of the AWS resources you have selected to -// record in your AWS account. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Config's -// API operation StopConfigurationRecorder for usage and error information. -// -// Returned Error Codes: -// * ErrCodeNoSuchConfigurationRecorderException "NoSuchConfigurationRecorderException" -// You have specified a configuration recorder that does not exist. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12/StopConfigurationRecorder -func (c *ConfigService) StopConfigurationRecorder(input *StopConfigurationRecorderInput) (*StopConfigurationRecorderOutput, error) { - req, out := c.StopConfigurationRecorderRequest(input) - return out, req.Send() +// SetBaseConfigurationItems sets the BaseConfigurationItems field's value. +func (s *BatchGetResourceConfigOutput) SetBaseConfigurationItems(v []*BaseConfigurationItem) *BatchGetResourceConfigOutput { + s.BaseConfigurationItems = v + return s } -// StopConfigurationRecorderWithContext is the same as StopConfigurationRecorder with the addition of -// the ability to pass a context and additional request options. -// -// See StopConfigurationRecorder for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ConfigService) StopConfigurationRecorderWithContext(ctx aws.Context, input *StopConfigurationRecorderInput, opts ...request.Option) (*StopConfigurationRecorderOutput, error) { - req, out := c.StopConfigurationRecorderRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() +// SetUnprocessedResourceKeys sets the UnprocessedResourceKeys field's value. +func (s *BatchGetResourceConfigOutput) SetUnprocessedResourceKeys(v []*ResourceKey) *BatchGetResourceConfigOutput { + s.UnprocessedResourceKeys = v + return s } // Indicates whether an AWS resource or AWS Config rule is compliant and provides @@ -2651,14 +4421,14 @@ type Compliance struct { // Indicates whether an AWS resource or AWS Config rule is compliant. // // A resource is compliant if it complies with all of the AWS Config rules that - // evaluate it, and it is noncompliant if it does not comply with one or more - // of these rules. + // evaluate it. A resource is noncompliant if it does not comply with one or + // more of these rules. // // A rule is compliant if all of the resources that the rule evaluates comply - // with it, and it is noncompliant if any of these resources do not comply. + // with it. A rule is noncompliant if any of these resources do not comply. // // AWS Config returns the INSUFFICIENT_DATA value when no evaluation results - // are available for the AWS resource or Config rule. + // are available for the AWS resource or AWS Config rule. // // For the Compliance data type, AWS Config supports only COMPLIANT, NON_COMPLIANT, // and INSUFFICIENT_DATA values. AWS Config does not support the NOT_APPLICABLE @@ -2689,7 +4459,7 @@ func (s *Compliance) SetComplianceType(v string) *Compliance { } // Indicates whether an AWS Config rule is compliant. A rule is compliant if -// all of the resources that the rule evaluated comply with it, and it is noncompliant +// all of the resources that the rule evaluated comply with it. A rule is noncompliant // if any of these resources do not comply. type ComplianceByConfigRule struct { _ struct{} `type:"structure"` @@ -2725,8 +4495,8 @@ func (s *ComplianceByConfigRule) SetConfigRuleName(v string) *ComplianceByConfig // Indicates whether an AWS resource that is evaluated according to one or more // AWS Config rules is compliant. A resource is compliant if it complies with -// all of the rules that evaluate it, and it is noncompliant if it does not -// comply with one or more of these rules. +// all of the rules that evaluate it. A resource is noncompliant if it does +// not comply with one or more of these rules. type ComplianceByResource struct { _ struct{} `type:"structure"` @@ -2849,12 +4619,12 @@ func (s *ComplianceSummary) SetNonCompliantResourceCount(v *ComplianceContributo } // The number of AWS resources of a specific type that are compliant or noncompliant, -// up to a maximum of 100 for each compliance. +// up to a maximum of 100 for each. type ComplianceSummaryByResourceType struct { _ struct{} `type:"structure"` // The number of AWS resources that are compliant or noncompliant, up to a maximum - // of 100 for each compliance. + // of 100 for each. ComplianceSummary *ComplianceSummary `type:"structure"` // The type of AWS resource. @@ -2982,18 +4752,18 @@ type ConfigRule struct { ConfigRuleName *string `min:"1" type:"string"` // Indicates whether the AWS Config rule is active or is currently being deleted - // by AWS Config. It can also indicate the evaluation status for the Config + // by AWS Config. It can also indicate the evaluation status for the AWS Config // rule. // // AWS Config sets the state of the rule to EVALUATING temporarily after you // use the StartConfigRulesEvaluation request to evaluate your resources against - // the Config rule. + // the AWS Config rule. // // AWS Config sets the state of the rule to DELETING_RESULTS temporarily after // you use the DeleteEvaluationResults request to delete the current evaluation - // results for the Config rule. + // results for the AWS Config rule. // - // AWS Config sets the state of a rule to DELETING temporarily after you use + // AWS Config temporarily sets the state of a rule to DELETING after you use // the DeleteConfigRule request to delete the rule. After AWS Config deletes // the rule, the rule and all of its evaluations are erased and are no longer // available. @@ -3002,7 +4772,7 @@ type ConfigRule struct { // The description that you provide for the AWS Config rule. Description *string `type:"string"` - // A string in JSON format that is passed to the AWS Config rule Lambda function. + // A string, in JSON format, that is passed to the AWS Config rule Lambda function. InputParameters *string `min:"1" type:"string"` // The maximum frequency with which AWS Config runs evaluations for a rule. @@ -3126,11 +4896,129 @@ func (s *ConfigRule) SetSource(v *Source) *ConfigRule { return s } +// Filters the compliance results based on account ID, region, compliance type, +// and rule name. +type ConfigRuleComplianceFilters struct { + _ struct{} `type:"structure"` + + // The 12-digit account ID of the source account. + AccountId *string `type:"string"` + + // The source region where the data is aggregated. + AwsRegion *string `min:"1" type:"string"` + + // The rule compliance status. + // + // For the ConfigRuleComplianceFilters data type, AWS Config supports only COMPLIANT + // and NON_COMPLIANT. AWS Config does not support the NOT_APPLICABLE and the + // INSUFFICIENT_DATA values. + ComplianceType *string `type:"string" enum:"ComplianceType"` + + // The name of the AWS Config rule. + ConfigRuleName *string `min:"1" type:"string"` +} + +// String returns the string representation +func (s ConfigRuleComplianceFilters) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ConfigRuleComplianceFilters) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ConfigRuleComplianceFilters) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ConfigRuleComplianceFilters"} + if s.AwsRegion != nil && len(*s.AwsRegion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AwsRegion", 1)) + } + if s.ConfigRuleName != nil && len(*s.ConfigRuleName) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ConfigRuleName", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAccountId sets the AccountId field's value. +func (s *ConfigRuleComplianceFilters) SetAccountId(v string) *ConfigRuleComplianceFilters { + s.AccountId = &v + return s +} + +// SetAwsRegion sets the AwsRegion field's value. +func (s *ConfigRuleComplianceFilters) SetAwsRegion(v string) *ConfigRuleComplianceFilters { + s.AwsRegion = &v + return s +} + +// SetComplianceType sets the ComplianceType field's value. +func (s *ConfigRuleComplianceFilters) SetComplianceType(v string) *ConfigRuleComplianceFilters { + s.ComplianceType = &v + return s +} + +// SetConfigRuleName sets the ConfigRuleName field's value. +func (s *ConfigRuleComplianceFilters) SetConfigRuleName(v string) *ConfigRuleComplianceFilters { + s.ConfigRuleName = &v + return s +} + +// Filters the results based on the account IDs and regions. +type ConfigRuleComplianceSummaryFilters struct { + _ struct{} `type:"structure"` + + // The 12-digit account ID of the source account. + AccountId *string `type:"string"` + + // The source region where the data is aggregated. + AwsRegion *string `min:"1" type:"string"` +} + +// String returns the string representation +func (s ConfigRuleComplianceSummaryFilters) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ConfigRuleComplianceSummaryFilters) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ConfigRuleComplianceSummaryFilters) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ConfigRuleComplianceSummaryFilters"} + if s.AwsRegion != nil && len(*s.AwsRegion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AwsRegion", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAccountId sets the AccountId field's value. +func (s *ConfigRuleComplianceSummaryFilters) SetAccountId(v string) *ConfigRuleComplianceSummaryFilters { + s.AccountId = &v + return s +} + +// SetAwsRegion sets the AwsRegion field's value. +func (s *ConfigRuleComplianceSummaryFilters) SetAwsRegion(v string) *ConfigRuleComplianceSummaryFilters { + s.AwsRegion = &v + return s +} + // Status information for your AWS managed Config rules. The status includes // information such as the last time the rule ran, the last time it failed, // and the related error for the last failure. // -// This action does not return status information about custom Config rules. +// This action does not return status information about custom AWS Config rules. type ConfigRuleEvaluationStatus struct { _ struct{} `type:"structure"` @@ -3268,7 +5156,7 @@ func (s *ConfigRuleEvaluationStatus) SetLastSuccessfulInvocationTime(v time.Time // * The value for the deliveryFrequency parameter within the delivery channel // configuration, which sets how often AWS Config delivers configuration // snapshots. This value also sets how often AWS Config invokes evaluations -// for Config rules. +// for AWS Config rules. // // * The value for the MaximumExecutionFrequency parameter, which sets the // maximum frequency with which AWS Config invokes evaluations for the rule. @@ -3373,11 +5261,81 @@ func (s *ConfigStreamDeliveryInfo) SetLastStatusChangeTime(v time.Time) *ConfigS return s } +// The details about the configuration aggregator, including information about +// source accounts, regions, and metadata of the aggregator. +type ConfigurationAggregator struct { + _ struct{} `type:"structure"` + + // Provides a list of source accounts and regions to be aggregated. + AccountAggregationSources []*AccountAggregationSource `type:"list"` + + // The Amazon Resource Name (ARN) of the aggregator. + ConfigurationAggregatorArn *string `type:"string"` + + // The name of the aggregator. + ConfigurationAggregatorName *string `min:"1" type:"string"` + + // The time stamp when the configuration aggregator was created. + CreationTime *time.Time `type:"timestamp" timestampFormat:"unix"` + + // The time of the last update. + LastUpdatedTime *time.Time `type:"timestamp" timestampFormat:"unix"` + + // Provides an organization and list of regions to be aggregated. + OrganizationAggregationSource *OrganizationAggregationSource `type:"structure"` +} + +// String returns the string representation +func (s ConfigurationAggregator) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ConfigurationAggregator) GoString() string { + return s.String() +} + +// SetAccountAggregationSources sets the AccountAggregationSources field's value. +func (s *ConfigurationAggregator) SetAccountAggregationSources(v []*AccountAggregationSource) *ConfigurationAggregator { + s.AccountAggregationSources = v + return s +} + +// SetConfigurationAggregatorArn sets the ConfigurationAggregatorArn field's value. +func (s *ConfigurationAggregator) SetConfigurationAggregatorArn(v string) *ConfigurationAggregator { + s.ConfigurationAggregatorArn = &v + return s +} + +// SetConfigurationAggregatorName sets the ConfigurationAggregatorName field's value. +func (s *ConfigurationAggregator) SetConfigurationAggregatorName(v string) *ConfigurationAggregator { + s.ConfigurationAggregatorName = &v + return s +} + +// SetCreationTime sets the CreationTime field's value. +func (s *ConfigurationAggregator) SetCreationTime(v time.Time) *ConfigurationAggregator { + s.CreationTime = &v + return s +} + +// SetLastUpdatedTime sets the LastUpdatedTime field's value. +func (s *ConfigurationAggregator) SetLastUpdatedTime(v time.Time) *ConfigurationAggregator { + s.LastUpdatedTime = &v + return s +} + +// SetOrganizationAggregationSource sets the OrganizationAggregationSource field's value. +func (s *ConfigurationAggregator) SetOrganizationAggregationSource(v *OrganizationAggregationSource) *ConfigurationAggregator { + s.OrganizationAggregationSource = v + return s +} + // A list that contains detailed configurations of a specified resource. type ConfigurationItem struct { _ struct{} `type:"structure"` - // The 12 digit AWS account ID associated with the resource. + // The 12-digit AWS account ID associated with the resource. AccountId *string `locationName:"accountId" type:"string"` // The Amazon Resource Name (ARN) of the resource. @@ -3387,7 +5345,7 @@ type ConfigurationItem struct { AvailabilityZone *string `locationName:"availabilityZone" type:"string"` // The region where the resource resides. - AwsRegion *string `locationName:"awsRegion" type:"string"` + AwsRegion *string `locationName:"awsRegion" min:"1" type:"string"` // The description of the resource configuration. Configuration *string `locationName:"configuration" type:"string"` @@ -3412,7 +5370,7 @@ type ConfigurationItem struct { // // A populated field indicates that the current configuration was initiated // by the events recorded in the CloudTrail log. For more information about - // CloudTrail, see What is AWS CloudTrail? (http://docs.aws.amazon.com/awscloudtrail/latest/userguide/what_is_cloud_trail_top_level.html). + // CloudTrail, see What Is AWS CloudTrail (http://docs.aws.amazon.com/awscloudtrail/latest/userguide/what_is_cloud_trail_top_level.html). // // An empty field indicates that the current configuration was not initiated // by any event. @@ -3424,7 +5382,7 @@ type ConfigurationItem struct { // The time stamp when the resource was created. ResourceCreationTime *time.Time `locationName:"resourceCreationTime" type:"timestamp" timestampFormat:"unix"` - // The ID of the resource (for example., sg-xxxxxx). + // The ID of the resource (for example, sg-xxxxxx). ResourceId *string `locationName:"resourceId" type:"string"` // The custom name of the resource, if available. @@ -3572,7 +5530,7 @@ type ConfigurationRecorder struct { // the assigned name. Name *string `locationName:"name" min:"1" type:"string"` - // Specifies the types of AWS resource for which AWS Config records configuration + // Specifies the types of AWS resources for which AWS Config records configuration // changes. RecordingGroup *RecordingGroup `locationName:"recordingGroup" type:"structure"` @@ -3647,7 +5605,7 @@ type ConfigurationRecorderStatus struct { // The name of the configuration recorder. Name *string `locationName:"name" type:"string"` - // Specifies whether the recorder is currently recording or not. + // Specifies whether or not the recorder is currently recording. Recording *bool `locationName:"recording" type:"boolean"` } @@ -3709,6 +5667,75 @@ func (s *ConfigurationRecorderStatus) SetRecording(v bool) *ConfigurationRecorde return s } +type DeleteAggregationAuthorizationInput struct { + _ struct{} `type:"structure"` + + // The 12-digit account ID of the account authorized to aggregate data. + // + // AuthorizedAccountId is a required field + AuthorizedAccountId *string `type:"string" required:"true"` + + // The region authorized to collect aggregated data. + // + // AuthorizedAwsRegion is a required field + AuthorizedAwsRegion *string `min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s DeleteAggregationAuthorizationInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteAggregationAuthorizationInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteAggregationAuthorizationInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteAggregationAuthorizationInput"} + if s.AuthorizedAccountId == nil { + invalidParams.Add(request.NewErrParamRequired("AuthorizedAccountId")) + } + if s.AuthorizedAwsRegion == nil { + invalidParams.Add(request.NewErrParamRequired("AuthorizedAwsRegion")) + } + if s.AuthorizedAwsRegion != nil && len(*s.AuthorizedAwsRegion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AuthorizedAwsRegion", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAuthorizedAccountId sets the AuthorizedAccountId field's value. +func (s *DeleteAggregationAuthorizationInput) SetAuthorizedAccountId(v string) *DeleteAggregationAuthorizationInput { + s.AuthorizedAccountId = &v + return s +} + +// SetAuthorizedAwsRegion sets the AuthorizedAwsRegion field's value. +func (s *DeleteAggregationAuthorizationInput) SetAuthorizedAwsRegion(v string) *DeleteAggregationAuthorizationInput { + s.AuthorizedAwsRegion = &v + return s +} + +type DeleteAggregationAuthorizationOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteAggregationAuthorizationOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteAggregationAuthorizationOutput) GoString() string { + return s.String() +} + type DeleteConfigRuleInput struct { _ struct{} `type:"structure"` @@ -3764,6 +5791,61 @@ func (s DeleteConfigRuleOutput) GoString() string { return s.String() } +type DeleteConfigurationAggregatorInput struct { + _ struct{} `type:"structure"` + + // The name of the configuration aggregator. + // + // ConfigurationAggregatorName is a required field + ConfigurationAggregatorName *string `min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s DeleteConfigurationAggregatorInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteConfigurationAggregatorInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteConfigurationAggregatorInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteConfigurationAggregatorInput"} + if s.ConfigurationAggregatorName == nil { + invalidParams.Add(request.NewErrParamRequired("ConfigurationAggregatorName")) + } + if s.ConfigurationAggregatorName != nil && len(*s.ConfigurationAggregatorName) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ConfigurationAggregatorName", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetConfigurationAggregatorName sets the ConfigurationAggregatorName field's value. +func (s *DeleteConfigurationAggregatorInput) SetConfigurationAggregatorName(v string) *DeleteConfigurationAggregatorInput { + s.ConfigurationAggregatorName = &v + return s +} + +type DeleteConfigurationAggregatorOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteConfigurationAggregatorOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteConfigurationAggregatorOutput) GoString() string { + return s.String() +} + // The request object for the DeleteConfigurationRecorder action. type DeleteConfigurationRecorderInput struct { _ struct{} `type:"structure"` @@ -3823,7 +5905,7 @@ func (s DeleteConfigurationRecorderOutput) GoString() string { } // The input for the DeleteDeliveryChannel action. The action accepts the following -// data in JSON format. +// data, in JSON format. type DeleteDeliveryChannelInput struct { _ struct{} `type:"structure"` @@ -3882,7 +5964,8 @@ func (s DeleteDeliveryChannelOutput) GoString() string { type DeleteEvaluationResultsInput struct { _ struct{} `type:"structure"` - // The name of the Config rule for which you want to delete the evaluation results. + // The name of the AWS Config rule for which you want to delete the evaluation + // results. // // ConfigRuleName is a required field ConfigRuleName *string `min:"1" type:"string" required:"true"` @@ -3920,7 +6003,7 @@ func (s *DeleteEvaluationResultsInput) SetConfigRuleName(v string) *DeleteEvalua return s } -// The output when you delete the evaluation results for the specified Config +// The output when you delete the evaluation results for the specified AWS Config // rule. type DeleteEvaluationResultsOutput struct { _ struct{} `type:"structure"` @@ -3936,6 +6019,75 @@ func (s DeleteEvaluationResultsOutput) GoString() string { return s.String() } +type DeletePendingAggregationRequestInput struct { + _ struct{} `type:"structure"` + + // The 12-digit account ID of the account requesting to aggregate data. + // + // RequesterAccountId is a required field + RequesterAccountId *string `type:"string" required:"true"` + + // The region requesting to aggregate data. + // + // RequesterAwsRegion is a required field + RequesterAwsRegion *string `min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s DeletePendingAggregationRequestInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeletePendingAggregationRequestInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeletePendingAggregationRequestInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeletePendingAggregationRequestInput"} + if s.RequesterAccountId == nil { + invalidParams.Add(request.NewErrParamRequired("RequesterAccountId")) + } + if s.RequesterAwsRegion == nil { + invalidParams.Add(request.NewErrParamRequired("RequesterAwsRegion")) + } + if s.RequesterAwsRegion != nil && len(*s.RequesterAwsRegion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("RequesterAwsRegion", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetRequesterAccountId sets the RequesterAccountId field's value. +func (s *DeletePendingAggregationRequestInput) SetRequesterAccountId(v string) *DeletePendingAggregationRequestInput { + s.RequesterAccountId = &v + return s +} + +// SetRequesterAwsRegion sets the RequesterAwsRegion field's value. +func (s *DeletePendingAggregationRequestInput) SetRequesterAwsRegion(v string) *DeletePendingAggregationRequestInput { + s.RequesterAwsRegion = &v + return s +} + +type DeletePendingAggregationRequestOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeletePendingAggregationRequestOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeletePendingAggregationRequestOutput) GoString() string { + return s.String() +} + // The input for the DeliverConfigSnapshot action. type DeliverConfigSnapshotInput struct { _ struct{} `type:"structure"` @@ -3978,7 +6130,7 @@ func (s *DeliverConfigSnapshotInput) SetDeliveryChannelName(v string) *DeliverCo return s } -// The output for the DeliverConfigSnapshot action in JSON format. +// The output for the DeliverConfigSnapshot action, in JSON format. type DeliverConfigSnapshotOutput struct { _ struct{} `type:"structure"` @@ -4075,77 +6227,253 @@ func (s *DeliveryChannel) SetName(v string) *DeliveryChannel { return s } -// SetS3BucketName sets the S3BucketName field's value. -func (s *DeliveryChannel) SetS3BucketName(v string) *DeliveryChannel { - s.S3BucketName = &v - return s +// SetS3BucketName sets the S3BucketName field's value. +func (s *DeliveryChannel) SetS3BucketName(v string) *DeliveryChannel { + s.S3BucketName = &v + return s +} + +// SetS3KeyPrefix sets the S3KeyPrefix field's value. +func (s *DeliveryChannel) SetS3KeyPrefix(v string) *DeliveryChannel { + s.S3KeyPrefix = &v + return s +} + +// SetSnsTopicARN sets the SnsTopicARN field's value. +func (s *DeliveryChannel) SetSnsTopicARN(v string) *DeliveryChannel { + s.SnsTopicARN = &v + return s +} + +// The status of a specified delivery channel. +// +// Valid values: Success | Failure +type DeliveryChannelStatus struct { + _ struct{} `type:"structure"` + + // A list that contains the status of the delivery of the configuration history + // to the specified Amazon S3 bucket. + ConfigHistoryDeliveryInfo *ConfigExportDeliveryInfo `locationName:"configHistoryDeliveryInfo" type:"structure"` + + // A list containing the status of the delivery of the snapshot to the specified + // Amazon S3 bucket. + ConfigSnapshotDeliveryInfo *ConfigExportDeliveryInfo `locationName:"configSnapshotDeliveryInfo" type:"structure"` + + // A list containing the status of the delivery of the configuration stream + // notification to the specified Amazon SNS topic. + ConfigStreamDeliveryInfo *ConfigStreamDeliveryInfo `locationName:"configStreamDeliveryInfo" type:"structure"` + + // The name of the delivery channel. + Name *string `locationName:"name" type:"string"` +} + +// String returns the string representation +func (s DeliveryChannelStatus) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeliveryChannelStatus) GoString() string { + return s.String() +} + +// SetConfigHistoryDeliveryInfo sets the ConfigHistoryDeliveryInfo field's value. +func (s *DeliveryChannelStatus) SetConfigHistoryDeliveryInfo(v *ConfigExportDeliveryInfo) *DeliveryChannelStatus { + s.ConfigHistoryDeliveryInfo = v + return s +} + +// SetConfigSnapshotDeliveryInfo sets the ConfigSnapshotDeliveryInfo field's value. +func (s *DeliveryChannelStatus) SetConfigSnapshotDeliveryInfo(v *ConfigExportDeliveryInfo) *DeliveryChannelStatus { + s.ConfigSnapshotDeliveryInfo = v + return s +} + +// SetConfigStreamDeliveryInfo sets the ConfigStreamDeliveryInfo field's value. +func (s *DeliveryChannelStatus) SetConfigStreamDeliveryInfo(v *ConfigStreamDeliveryInfo) *DeliveryChannelStatus { + s.ConfigStreamDeliveryInfo = v + return s +} + +// SetName sets the Name field's value. +func (s *DeliveryChannelStatus) SetName(v string) *DeliveryChannelStatus { + s.Name = &v + return s +} + +type DescribeAggregateComplianceByConfigRulesInput struct { + _ struct{} `type:"structure"` + + // The name of the configuration aggregator. + // + // ConfigurationAggregatorName is a required field + ConfigurationAggregatorName *string `min:"1" type:"string" required:"true"` + + // Filters the results by ConfigRuleComplianceFilters object. + Filters *ConfigRuleComplianceFilters `type:"structure"` + + // The maximum number of evaluation results returned on each page. The default + // is maximum. If you specify 0, AWS Config uses the default. + Limit *int64 `type:"integer"` + + // The nextToken string returned on a previous page that you use to get the + // next page of results in a paginated response. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s DescribeAggregateComplianceByConfigRulesInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeAggregateComplianceByConfigRulesInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DescribeAggregateComplianceByConfigRulesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DescribeAggregateComplianceByConfigRulesInput"} + if s.ConfigurationAggregatorName == nil { + invalidParams.Add(request.NewErrParamRequired("ConfigurationAggregatorName")) + } + if s.ConfigurationAggregatorName != nil && len(*s.ConfigurationAggregatorName) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ConfigurationAggregatorName", 1)) + } + if s.Filters != nil { + if err := s.Filters.Validate(); err != nil { + invalidParams.AddNested("Filters", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetConfigurationAggregatorName sets the ConfigurationAggregatorName field's value. +func (s *DescribeAggregateComplianceByConfigRulesInput) SetConfigurationAggregatorName(v string) *DescribeAggregateComplianceByConfigRulesInput { + s.ConfigurationAggregatorName = &v + return s +} + +// SetFilters sets the Filters field's value. +func (s *DescribeAggregateComplianceByConfigRulesInput) SetFilters(v *ConfigRuleComplianceFilters) *DescribeAggregateComplianceByConfigRulesInput { + s.Filters = v + return s +} + +// SetLimit sets the Limit field's value. +func (s *DescribeAggregateComplianceByConfigRulesInput) SetLimit(v int64) *DescribeAggregateComplianceByConfigRulesInput { + s.Limit = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *DescribeAggregateComplianceByConfigRulesInput) SetNextToken(v string) *DescribeAggregateComplianceByConfigRulesInput { + s.NextToken = &v + return s +} + +type DescribeAggregateComplianceByConfigRulesOutput struct { + _ struct{} `type:"structure"` + + // Returns a list of AggregateComplianceByConfigRule object. + AggregateComplianceByConfigRules []*AggregateComplianceByConfigRule `type:"list"` + + // The nextToken string returned on a previous page that you use to get the + // next page of results in a paginated response. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s DescribeAggregateComplianceByConfigRulesOutput) String() string { + return awsutil.Prettify(s) } -// SetS3KeyPrefix sets the S3KeyPrefix field's value. -func (s *DeliveryChannel) SetS3KeyPrefix(v string) *DeliveryChannel { - s.S3KeyPrefix = &v +// GoString returns the string representation +func (s DescribeAggregateComplianceByConfigRulesOutput) GoString() string { + return s.String() +} + +// SetAggregateComplianceByConfigRules sets the AggregateComplianceByConfigRules field's value. +func (s *DescribeAggregateComplianceByConfigRulesOutput) SetAggregateComplianceByConfigRules(v []*AggregateComplianceByConfigRule) *DescribeAggregateComplianceByConfigRulesOutput { + s.AggregateComplianceByConfigRules = v return s } -// SetSnsTopicARN sets the SnsTopicARN field's value. -func (s *DeliveryChannel) SetSnsTopicARN(v string) *DeliveryChannel { - s.SnsTopicARN = &v +// SetNextToken sets the NextToken field's value. +func (s *DescribeAggregateComplianceByConfigRulesOutput) SetNextToken(v string) *DescribeAggregateComplianceByConfigRulesOutput { + s.NextToken = &v return s } -// The status of a specified delivery channel. -// -// Valid values: Success | Failure -type DeliveryChannelStatus struct { +type DescribeAggregationAuthorizationsInput struct { _ struct{} `type:"structure"` - // A list that contains the status of the delivery of the configuration history - // to the specified Amazon S3 bucket. - ConfigHistoryDeliveryInfo *ConfigExportDeliveryInfo `locationName:"configHistoryDeliveryInfo" type:"structure"` - - // A list containing the status of the delivery of the snapshot to the specified - // Amazon S3 bucket. - ConfigSnapshotDeliveryInfo *ConfigExportDeliveryInfo `locationName:"configSnapshotDeliveryInfo" type:"structure"` - - // A list containing the status of the delivery of the configuration stream - // notification to the specified Amazon SNS topic. - ConfigStreamDeliveryInfo *ConfigStreamDeliveryInfo `locationName:"configStreamDeliveryInfo" type:"structure"` + // The maximum number of AggregationAuthorizations returned on each page. The + // default is maximum. If you specify 0, AWS Config uses the default. + Limit *int64 `type:"integer"` - // The name of the delivery channel. - Name *string `locationName:"name" type:"string"` + // The nextToken string returned on a previous page that you use to get the + // next page of results in a paginated response. + NextToken *string `type:"string"` } // String returns the string representation -func (s DeliveryChannelStatus) String() string { +func (s DescribeAggregationAuthorizationsInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s DeliveryChannelStatus) GoString() string { +func (s DescribeAggregationAuthorizationsInput) GoString() string { return s.String() } -// SetConfigHistoryDeliveryInfo sets the ConfigHistoryDeliveryInfo field's value. -func (s *DeliveryChannelStatus) SetConfigHistoryDeliveryInfo(v *ConfigExportDeliveryInfo) *DeliveryChannelStatus { - s.ConfigHistoryDeliveryInfo = v +// SetLimit sets the Limit field's value. +func (s *DescribeAggregationAuthorizationsInput) SetLimit(v int64) *DescribeAggregationAuthorizationsInput { + s.Limit = &v return s } -// SetConfigSnapshotDeliveryInfo sets the ConfigSnapshotDeliveryInfo field's value. -func (s *DeliveryChannelStatus) SetConfigSnapshotDeliveryInfo(v *ConfigExportDeliveryInfo) *DeliveryChannelStatus { - s.ConfigSnapshotDeliveryInfo = v +// SetNextToken sets the NextToken field's value. +func (s *DescribeAggregationAuthorizationsInput) SetNextToken(v string) *DescribeAggregationAuthorizationsInput { + s.NextToken = &v return s } -// SetConfigStreamDeliveryInfo sets the ConfigStreamDeliveryInfo field's value. -func (s *DeliveryChannelStatus) SetConfigStreamDeliveryInfo(v *ConfigStreamDeliveryInfo) *DeliveryChannelStatus { - s.ConfigStreamDeliveryInfo = v +type DescribeAggregationAuthorizationsOutput struct { + _ struct{} `type:"structure"` + + // Returns a list of authorizations granted to various aggregator accounts and + // regions. + AggregationAuthorizations []*AggregationAuthorization `type:"list"` + + // The nextToken string returned on a previous page that you use to get the + // next page of results in a paginated response. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s DescribeAggregationAuthorizationsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeAggregationAuthorizationsOutput) GoString() string { + return s.String() +} + +// SetAggregationAuthorizations sets the AggregationAuthorizations field's value. +func (s *DescribeAggregationAuthorizationsOutput) SetAggregationAuthorizations(v []*AggregationAuthorization) *DescribeAggregationAuthorizationsOutput { + s.AggregationAuthorizations = v return s } -// SetName sets the Name field's value. -func (s *DeliveryChannelStatus) SetName(v string) *DeliveryChannelStatus { - s.Name = &v +// SetNextToken sets the NextToken field's value. +func (s *DescribeAggregationAuthorizationsOutput) SetNextToken(v string) *DescribeAggregationAuthorizationsOutput { + s.NextToken = &v return s } @@ -4160,7 +6488,7 @@ type DescribeComplianceByConfigRuleInput struct { // Specify one or more AWS Config rule names to filter the results by rule. ConfigRuleNames []*string `type:"list"` - // The NextToken string returned on a previous page that you use to get the + // The nextToken string returned on a previous page that you use to get the // next page of results in a paginated response. NextToken *string `type:"string"` } @@ -4231,15 +6559,15 @@ type DescribeComplianceByResourceInput struct { // Filters the results by compliance. // - // The allowed values are COMPLIANT, NON_COMPLIANT, and INSUFFICIENT_DATA. + // The allowed values are COMPLIANT and NON_COMPLIANT. ComplianceTypes []*string `type:"list"` // The maximum number of evaluation results returned on each page. The default - // is 10. You cannot specify a limit greater than 100. If you specify 0, AWS + // is 10. You cannot specify a number greater than 100. If you specify 0, AWS // Config uses the default. Limit *int64 `type:"integer"` - // The NextToken string returned on a previous page that you use to get the + // The nextToken string returned on a previous page that you use to get the // next page of results in a paginated response. NextToken *string `type:"string"` @@ -4248,8 +6576,8 @@ type DescribeComplianceByResourceInput struct { // also specify a type for ResourceType. ResourceId *string `min:"1" type:"string"` - // The types of AWS resources for which you want compliance information; for - // example, AWS::EC2::Instance. For this action, you can specify that the resource + // The types of AWS resources for which you want compliance information (for + // example, AWS::EC2::Instance). For this action, you can specify that the resource // type is an AWS account by specifying AWS::::Account. ResourceType *string `min:"1" type:"string"` } @@ -4357,12 +6685,12 @@ type DescribeConfigRuleEvaluationStatusInput struct { // This parameter is required if the rule limit for your account is more than // the default of 50 rules. // - // For more information about requesting a rule limit increase, see AWS Config - // Limits (http://docs.aws.amazon.com/general/latest/gr/aws_service_limits.html#limits_config) + // For information about requesting a rule limit increase, see AWS Config Limits + // (http://docs.aws.amazon.com/general/latest/gr/aws_service_limits.html#limits_config) // in the AWS General Reference Guide. Limit *int64 `type:"integer"` - // The NextToken string returned on a previous page that you use to get the + // The nextToken string returned on a previous page that you use to get the // next page of results in a paginated response. NextToken *string `type:"string"` } @@ -4435,7 +6763,7 @@ type DescribeConfigRulesInput struct { // specify any names, AWS Config returns details for all your rules. ConfigRuleNames []*string `type:"list"` - // The NextToken string returned on a previous page that you use to get the + // The nextToken string returned on a previous page that you use to get the // next page of results in a paginated response. NextToken *string `type:"string"` } @@ -4495,6 +6823,194 @@ func (s *DescribeConfigRulesOutput) SetNextToken(v string) *DescribeConfigRulesO return s } +type DescribeConfigurationAggregatorSourcesStatusInput struct { + _ struct{} `type:"structure"` + + // The name of the configuration aggregator. + // + // ConfigurationAggregatorName is a required field + ConfigurationAggregatorName *string `min:"1" type:"string" required:"true"` + + // The maximum number of AggregatorSourceStatus returned on each page. The default + // is maximum. If you specify 0, AWS Config uses the default. + Limit *int64 `type:"integer"` + + // The nextToken string returned on a previous page that you use to get the + // next page of results in a paginated response. + NextToken *string `type:"string"` + + // Filters the status type. + // + // * Valid value FAILED indicates errors while moving data. + // + // * Valid value SUCCEEDED indicates the data was successfully moved. + // + // * Valid value OUTDATED indicates the data is not the most recent. + UpdateStatus []*string `min:"1" type:"list"` +} + +// String returns the string representation +func (s DescribeConfigurationAggregatorSourcesStatusInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeConfigurationAggregatorSourcesStatusInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DescribeConfigurationAggregatorSourcesStatusInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DescribeConfigurationAggregatorSourcesStatusInput"} + if s.ConfigurationAggregatorName == nil { + invalidParams.Add(request.NewErrParamRequired("ConfigurationAggregatorName")) + } + if s.ConfigurationAggregatorName != nil && len(*s.ConfigurationAggregatorName) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ConfigurationAggregatorName", 1)) + } + if s.UpdateStatus != nil && len(s.UpdateStatus) < 1 { + invalidParams.Add(request.NewErrParamMinLen("UpdateStatus", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetConfigurationAggregatorName sets the ConfigurationAggregatorName field's value. +func (s *DescribeConfigurationAggregatorSourcesStatusInput) SetConfigurationAggregatorName(v string) *DescribeConfigurationAggregatorSourcesStatusInput { + s.ConfigurationAggregatorName = &v + return s +} + +// SetLimit sets the Limit field's value. +func (s *DescribeConfigurationAggregatorSourcesStatusInput) SetLimit(v int64) *DescribeConfigurationAggregatorSourcesStatusInput { + s.Limit = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *DescribeConfigurationAggregatorSourcesStatusInput) SetNextToken(v string) *DescribeConfigurationAggregatorSourcesStatusInput { + s.NextToken = &v + return s +} + +// SetUpdateStatus sets the UpdateStatus field's value. +func (s *DescribeConfigurationAggregatorSourcesStatusInput) SetUpdateStatus(v []*string) *DescribeConfigurationAggregatorSourcesStatusInput { + s.UpdateStatus = v + return s +} + +type DescribeConfigurationAggregatorSourcesStatusOutput struct { + _ struct{} `type:"structure"` + + // Retuns an AggregatedSourceStatus object. + AggregatedSourceStatusList []*AggregatedSourceStatus `type:"list"` + + // The nextToken string returned on a previous page that you use to get the + // next page of results in a paginated response. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s DescribeConfigurationAggregatorSourcesStatusOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeConfigurationAggregatorSourcesStatusOutput) GoString() string { + return s.String() +} + +// SetAggregatedSourceStatusList sets the AggregatedSourceStatusList field's value. +func (s *DescribeConfigurationAggregatorSourcesStatusOutput) SetAggregatedSourceStatusList(v []*AggregatedSourceStatus) *DescribeConfigurationAggregatorSourcesStatusOutput { + s.AggregatedSourceStatusList = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *DescribeConfigurationAggregatorSourcesStatusOutput) SetNextToken(v string) *DescribeConfigurationAggregatorSourcesStatusOutput { + s.NextToken = &v + return s +} + +type DescribeConfigurationAggregatorsInput struct { + _ struct{} `type:"structure"` + + // The name of the configuration aggregators. + ConfigurationAggregatorNames []*string `type:"list"` + + // The maximum number of configuration aggregators returned on each page. The + // default is maximum. If you specify 0, AWS Config uses the default. + Limit *int64 `type:"integer"` + + // The nextToken string returned on a previous page that you use to get the + // next page of results in a paginated response. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s DescribeConfigurationAggregatorsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeConfigurationAggregatorsInput) GoString() string { + return s.String() +} + +// SetConfigurationAggregatorNames sets the ConfigurationAggregatorNames field's value. +func (s *DescribeConfigurationAggregatorsInput) SetConfigurationAggregatorNames(v []*string) *DescribeConfigurationAggregatorsInput { + s.ConfigurationAggregatorNames = v + return s +} + +// SetLimit sets the Limit field's value. +func (s *DescribeConfigurationAggregatorsInput) SetLimit(v int64) *DescribeConfigurationAggregatorsInput { + s.Limit = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *DescribeConfigurationAggregatorsInput) SetNextToken(v string) *DescribeConfigurationAggregatorsInput { + s.NextToken = &v + return s +} + +type DescribeConfigurationAggregatorsOutput struct { + _ struct{} `type:"structure"` + + // Returns a ConfigurationAggregators object. + ConfigurationAggregators []*ConfigurationAggregator `type:"list"` + + // The nextToken string returned on a previous page that you use to get the + // next page of results in a paginated response. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s DescribeConfigurationAggregatorsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeConfigurationAggregatorsOutput) GoString() string { + return s.String() +} + +// SetConfigurationAggregators sets the ConfigurationAggregators field's value. +func (s *DescribeConfigurationAggregatorsOutput) SetConfigurationAggregators(v []*ConfigurationAggregator) *DescribeConfigurationAggregatorsOutput { + s.ConfigurationAggregators = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *DescribeConfigurationAggregatorsOutput) SetNextToken(v string) *DescribeConfigurationAggregatorsOutput { + s.NextToken = &v + return s +} + // The input for the DescribeConfigurationRecorderStatus action. type DescribeConfigurationRecorderStatusInput struct { _ struct{} `type:"structure"` @@ -4521,7 +7037,7 @@ func (s *DescribeConfigurationRecorderStatusInput) SetConfigurationRecorderNames return s } -// The output for the DescribeConfigurationRecorderStatus action in JSON format. +// The output for the DescribeConfigurationRecorderStatus action, in JSON format. type DescribeConfigurationRecorderStatusOutput struct { _ struct{} `type:"structure"` @@ -4631,61 +7147,128 @@ func (s DescribeDeliveryChannelStatusOutput) String() string { } // GoString returns the string representation -func (s DescribeDeliveryChannelStatusOutput) GoString() string { +func (s DescribeDeliveryChannelStatusOutput) GoString() string { + return s.String() +} + +// SetDeliveryChannelsStatus sets the DeliveryChannelsStatus field's value. +func (s *DescribeDeliveryChannelStatusOutput) SetDeliveryChannelsStatus(v []*DeliveryChannelStatus) *DescribeDeliveryChannelStatusOutput { + s.DeliveryChannelsStatus = v + return s +} + +// The input for the DescribeDeliveryChannels action. +type DescribeDeliveryChannelsInput struct { + _ struct{} `type:"structure"` + + // A list of delivery channel names. + DeliveryChannelNames []*string `type:"list"` +} + +// String returns the string representation +func (s DescribeDeliveryChannelsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeDeliveryChannelsInput) GoString() string { + return s.String() +} + +// SetDeliveryChannelNames sets the DeliveryChannelNames field's value. +func (s *DescribeDeliveryChannelsInput) SetDeliveryChannelNames(v []*string) *DescribeDeliveryChannelsInput { + s.DeliveryChannelNames = v + return s +} + +// The output for the DescribeDeliveryChannels action. +type DescribeDeliveryChannelsOutput struct { + _ struct{} `type:"structure"` + + // A list that contains the descriptions of the specified delivery channel. + DeliveryChannels []*DeliveryChannel `type:"list"` +} + +// String returns the string representation +func (s DescribeDeliveryChannelsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeDeliveryChannelsOutput) GoString() string { return s.String() } -// SetDeliveryChannelsStatus sets the DeliveryChannelsStatus field's value. -func (s *DescribeDeliveryChannelStatusOutput) SetDeliveryChannelsStatus(v []*DeliveryChannelStatus) *DescribeDeliveryChannelStatusOutput { - s.DeliveryChannelsStatus = v +// SetDeliveryChannels sets the DeliveryChannels field's value. +func (s *DescribeDeliveryChannelsOutput) SetDeliveryChannels(v []*DeliveryChannel) *DescribeDeliveryChannelsOutput { + s.DeliveryChannels = v return s } -// The input for the DescribeDeliveryChannels action. -type DescribeDeliveryChannelsInput struct { +type DescribePendingAggregationRequestsInput struct { _ struct{} `type:"structure"` - // A list of delivery channel names. - DeliveryChannelNames []*string `type:"list"` + // The maximum number of evaluation results returned on each page. The default + // is maximum. If you specify 0, AWS Config uses the default. + Limit *int64 `type:"integer"` + + // The nextToken string returned on a previous page that you use to get the + // next page of results in a paginated response. + NextToken *string `type:"string"` } // String returns the string representation -func (s DescribeDeliveryChannelsInput) String() string { +func (s DescribePendingAggregationRequestsInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s DescribeDeliveryChannelsInput) GoString() string { +func (s DescribePendingAggregationRequestsInput) GoString() string { return s.String() } -// SetDeliveryChannelNames sets the DeliveryChannelNames field's value. -func (s *DescribeDeliveryChannelsInput) SetDeliveryChannelNames(v []*string) *DescribeDeliveryChannelsInput { - s.DeliveryChannelNames = v +// SetLimit sets the Limit field's value. +func (s *DescribePendingAggregationRequestsInput) SetLimit(v int64) *DescribePendingAggregationRequestsInput { + s.Limit = &v return s } -// The output for the DescribeDeliveryChannels action. -type DescribeDeliveryChannelsOutput struct { +// SetNextToken sets the NextToken field's value. +func (s *DescribePendingAggregationRequestsInput) SetNextToken(v string) *DescribePendingAggregationRequestsInput { + s.NextToken = &v + return s +} + +type DescribePendingAggregationRequestsOutput struct { _ struct{} `type:"structure"` - // A list that contains the descriptions of the specified delivery channel. - DeliveryChannels []*DeliveryChannel `type:"list"` + // The nextToken string returned on a previous page that you use to get the + // next page of results in a paginated response. + NextToken *string `type:"string"` + + // Returns a PendingAggregationRequests object. + PendingAggregationRequests []*PendingAggregationRequest `type:"list"` } // String returns the string representation -func (s DescribeDeliveryChannelsOutput) String() string { +func (s DescribePendingAggregationRequestsOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s DescribeDeliveryChannelsOutput) GoString() string { +func (s DescribePendingAggregationRequestsOutput) GoString() string { return s.String() } -// SetDeliveryChannels sets the DeliveryChannels field's value. -func (s *DescribeDeliveryChannelsOutput) SetDeliveryChannels(v []*DeliveryChannel) *DescribeDeliveryChannelsOutput { - s.DeliveryChannels = v +// SetNextToken sets the NextToken field's value. +func (s *DescribePendingAggregationRequestsOutput) SetNextToken(v string) *DescribePendingAggregationRequestsOutput { + s.NextToken = &v + return s +} + +// SetPendingAggregationRequests sets the PendingAggregationRequests field's value. +func (s *DescribePendingAggregationRequestsOutput) SetPendingAggregationRequests(v []*PendingAggregationRequest) *DescribePendingAggregationRequestsOutput { + s.PendingAggregationRequests = v return s } @@ -4716,7 +7299,7 @@ type Evaluation struct { // // Similarly, AWS Config does not accept INSUFFICIENT_DATA as the value for // ComplianceType from a PutEvaluations request. For example, an AWS Lambda - // function for a custom Config rule cannot pass an INSUFFICIENT_DATA value + // function for a custom AWS Config rule cannot pass an INSUFFICIENT_DATA value // to AWS Config. // // ComplianceType is a required field @@ -4804,7 +7387,7 @@ func (s *Evaluation) SetOrderingTimestamp(v time.Time) *Evaluation { } // The details of an AWS Config evaluation. Provides the AWS resource that was -// evaluated, the compliance of the resource, related timestamps, and supplementary +// evaluated, the compliance of the resource, related time stamps, and supplementary // information. type EvaluationResult struct { _ struct{} `type:"structure"` @@ -4906,58 +7489,341 @@ func (s EvaluationResultIdentifier) GoString() string { return s.String() } -// SetEvaluationResultQualifier sets the EvaluationResultQualifier field's value. -func (s *EvaluationResultIdentifier) SetEvaluationResultQualifier(v *EvaluationResultQualifier) *EvaluationResultIdentifier { - s.EvaluationResultQualifier = v +// SetEvaluationResultQualifier sets the EvaluationResultQualifier field's value. +func (s *EvaluationResultIdentifier) SetEvaluationResultQualifier(v *EvaluationResultQualifier) *EvaluationResultIdentifier { + s.EvaluationResultQualifier = v + return s +} + +// SetOrderingTimestamp sets the OrderingTimestamp field's value. +func (s *EvaluationResultIdentifier) SetOrderingTimestamp(v time.Time) *EvaluationResultIdentifier { + s.OrderingTimestamp = &v + return s +} + +// Identifies an AWS Config rule that evaluated an AWS resource, and provides +// the type and ID of the resource that the rule evaluated. +type EvaluationResultQualifier struct { + _ struct{} `type:"structure"` + + // The name of the AWS Config rule that was used in the evaluation. + ConfigRuleName *string `min:"1" type:"string"` + + // The ID of the evaluated AWS resource. + ResourceId *string `min:"1" type:"string"` + + // The type of AWS resource that was evaluated. + ResourceType *string `min:"1" type:"string"` +} + +// String returns the string representation +func (s EvaluationResultQualifier) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s EvaluationResultQualifier) GoString() string { + return s.String() +} + +// SetConfigRuleName sets the ConfigRuleName field's value. +func (s *EvaluationResultQualifier) SetConfigRuleName(v string) *EvaluationResultQualifier { + s.ConfigRuleName = &v + return s +} + +// SetResourceId sets the ResourceId field's value. +func (s *EvaluationResultQualifier) SetResourceId(v string) *EvaluationResultQualifier { + s.ResourceId = &v + return s +} + +// SetResourceType sets the ResourceType field's value. +func (s *EvaluationResultQualifier) SetResourceType(v string) *EvaluationResultQualifier { + s.ResourceType = &v + return s +} + +type GetAggregateComplianceDetailsByConfigRuleInput struct { + _ struct{} `type:"structure"` + + // The 12-digit account ID of the source account. + // + // AccountId is a required field + AccountId *string `type:"string" required:"true"` + + // The source region from where the data is aggregated. + // + // AwsRegion is a required field + AwsRegion *string `min:"1" type:"string" required:"true"` + + // The resource compliance status. + // + // For the GetAggregateComplianceDetailsByConfigRuleRequest data type, AWS Config + // supports only the COMPLIANT and NON_COMPLIANT. AWS Config does not support + // the NOT_APPLICABLE and INSUFFICIENT_DATA values. + ComplianceType *string `type:"string" enum:"ComplianceType"` + + // The name of the AWS Config rule for which you want compliance information. + // + // ConfigRuleName is a required field + ConfigRuleName *string `min:"1" type:"string" required:"true"` + + // The name of the configuration aggregator. + // + // ConfigurationAggregatorName is a required field + ConfigurationAggregatorName *string `min:"1" type:"string" required:"true"` + + // The maximum number of evaluation results returned on each page. The default + // is 50. You cannot specify a number greater than 100. If you specify 0, AWS + // Config uses the default. + Limit *int64 `type:"integer"` + + // The nextToken string returned on a previous page that you use to get the + // next page of results in a paginated response. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s GetAggregateComplianceDetailsByConfigRuleInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetAggregateComplianceDetailsByConfigRuleInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetAggregateComplianceDetailsByConfigRuleInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetAggregateComplianceDetailsByConfigRuleInput"} + if s.AccountId == nil { + invalidParams.Add(request.NewErrParamRequired("AccountId")) + } + if s.AwsRegion == nil { + invalidParams.Add(request.NewErrParamRequired("AwsRegion")) + } + if s.AwsRegion != nil && len(*s.AwsRegion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AwsRegion", 1)) + } + if s.ConfigRuleName == nil { + invalidParams.Add(request.NewErrParamRequired("ConfigRuleName")) + } + if s.ConfigRuleName != nil && len(*s.ConfigRuleName) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ConfigRuleName", 1)) + } + if s.ConfigurationAggregatorName == nil { + invalidParams.Add(request.NewErrParamRequired("ConfigurationAggregatorName")) + } + if s.ConfigurationAggregatorName != nil && len(*s.ConfigurationAggregatorName) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ConfigurationAggregatorName", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAccountId sets the AccountId field's value. +func (s *GetAggregateComplianceDetailsByConfigRuleInput) SetAccountId(v string) *GetAggregateComplianceDetailsByConfigRuleInput { + s.AccountId = &v + return s +} + +// SetAwsRegion sets the AwsRegion field's value. +func (s *GetAggregateComplianceDetailsByConfigRuleInput) SetAwsRegion(v string) *GetAggregateComplianceDetailsByConfigRuleInput { + s.AwsRegion = &v + return s +} + +// SetComplianceType sets the ComplianceType field's value. +func (s *GetAggregateComplianceDetailsByConfigRuleInput) SetComplianceType(v string) *GetAggregateComplianceDetailsByConfigRuleInput { + s.ComplianceType = &v + return s +} + +// SetConfigRuleName sets the ConfigRuleName field's value. +func (s *GetAggregateComplianceDetailsByConfigRuleInput) SetConfigRuleName(v string) *GetAggregateComplianceDetailsByConfigRuleInput { + s.ConfigRuleName = &v + return s +} + +// SetConfigurationAggregatorName sets the ConfigurationAggregatorName field's value. +func (s *GetAggregateComplianceDetailsByConfigRuleInput) SetConfigurationAggregatorName(v string) *GetAggregateComplianceDetailsByConfigRuleInput { + s.ConfigurationAggregatorName = &v + return s +} + +// SetLimit sets the Limit field's value. +func (s *GetAggregateComplianceDetailsByConfigRuleInput) SetLimit(v int64) *GetAggregateComplianceDetailsByConfigRuleInput { + s.Limit = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetAggregateComplianceDetailsByConfigRuleInput) SetNextToken(v string) *GetAggregateComplianceDetailsByConfigRuleInput { + s.NextToken = &v + return s +} + +type GetAggregateComplianceDetailsByConfigRuleOutput struct { + _ struct{} `type:"structure"` + + // Returns an AggregateEvaluationResults object. + AggregateEvaluationResults []*AggregateEvaluationResult `type:"list"` + + // The nextToken string returned on a previous page that you use to get the + // next page of results in a paginated response. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s GetAggregateComplianceDetailsByConfigRuleOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetAggregateComplianceDetailsByConfigRuleOutput) GoString() string { + return s.String() +} + +// SetAggregateEvaluationResults sets the AggregateEvaluationResults field's value. +func (s *GetAggregateComplianceDetailsByConfigRuleOutput) SetAggregateEvaluationResults(v []*AggregateEvaluationResult) *GetAggregateComplianceDetailsByConfigRuleOutput { + s.AggregateEvaluationResults = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetAggregateComplianceDetailsByConfigRuleOutput) SetNextToken(v string) *GetAggregateComplianceDetailsByConfigRuleOutput { + s.NextToken = &v + return s +} + +type GetAggregateConfigRuleComplianceSummaryInput struct { + _ struct{} `type:"structure"` + + // The name of the configuration aggregator. + // + // ConfigurationAggregatorName is a required field + ConfigurationAggregatorName *string `min:"1" type:"string" required:"true"` + + // Filters the results based on the ConfigRuleComplianceSummaryFilters object. + Filters *ConfigRuleComplianceSummaryFilters `type:"structure"` + + // Groups the result based on ACCOUNT_ID or AWS_REGION. + GroupByKey *string `type:"string" enum:"ConfigRuleComplianceSummaryGroupKey"` + + // The maximum number of evaluation results returned on each page. The default + // is 1000. You cannot specify a number greater than 1000. If you specify 0, + // AWS Config uses the default. + Limit *int64 `type:"integer"` + + // The nextToken string returned on a previous page that you use to get the + // next page of results in a paginated response. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s GetAggregateConfigRuleComplianceSummaryInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetAggregateConfigRuleComplianceSummaryInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetAggregateConfigRuleComplianceSummaryInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetAggregateConfigRuleComplianceSummaryInput"} + if s.ConfigurationAggregatorName == nil { + invalidParams.Add(request.NewErrParamRequired("ConfigurationAggregatorName")) + } + if s.ConfigurationAggregatorName != nil && len(*s.ConfigurationAggregatorName) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ConfigurationAggregatorName", 1)) + } + if s.Filters != nil { + if err := s.Filters.Validate(); err != nil { + invalidParams.AddNested("Filters", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetConfigurationAggregatorName sets the ConfigurationAggregatorName field's value. +func (s *GetAggregateConfigRuleComplianceSummaryInput) SetConfigurationAggregatorName(v string) *GetAggregateConfigRuleComplianceSummaryInput { + s.ConfigurationAggregatorName = &v + return s +} + +// SetFilters sets the Filters field's value. +func (s *GetAggregateConfigRuleComplianceSummaryInput) SetFilters(v *ConfigRuleComplianceSummaryFilters) *GetAggregateConfigRuleComplianceSummaryInput { + s.Filters = v + return s +} + +// SetGroupByKey sets the GroupByKey field's value. +func (s *GetAggregateConfigRuleComplianceSummaryInput) SetGroupByKey(v string) *GetAggregateConfigRuleComplianceSummaryInput { + s.GroupByKey = &v + return s +} + +// SetLimit sets the Limit field's value. +func (s *GetAggregateConfigRuleComplianceSummaryInput) SetLimit(v int64) *GetAggregateConfigRuleComplianceSummaryInput { + s.Limit = &v return s } -// SetOrderingTimestamp sets the OrderingTimestamp field's value. -func (s *EvaluationResultIdentifier) SetOrderingTimestamp(v time.Time) *EvaluationResultIdentifier { - s.OrderingTimestamp = &v +// SetNextToken sets the NextToken field's value. +func (s *GetAggregateConfigRuleComplianceSummaryInput) SetNextToken(v string) *GetAggregateConfigRuleComplianceSummaryInput { + s.NextToken = &v return s } -// Identifies an AWS Config rule that evaluated an AWS resource, and provides -// the type and ID of the resource that the rule evaluated. -type EvaluationResultQualifier struct { +type GetAggregateConfigRuleComplianceSummaryOutput struct { _ struct{} `type:"structure"` - // The name of the AWS Config rule that was used in the evaluation. - ConfigRuleName *string `min:"1" type:"string"` + // Returns a list of AggregateComplianceCounts object. + AggregateComplianceCounts []*AggregateComplianceCount `type:"list"` - // The ID of the evaluated AWS resource. - ResourceId *string `min:"1" type:"string"` + // Groups the result based on ACCOUNT_ID or AWS_REGION. + GroupByKey *string `min:"1" type:"string"` - // The type of AWS resource that was evaluated. - ResourceType *string `min:"1" type:"string"` + // The nextToken string returned on a previous page that you use to get the + // next page of results in a paginated response. + NextToken *string `type:"string"` } // String returns the string representation -func (s EvaluationResultQualifier) String() string { +func (s GetAggregateConfigRuleComplianceSummaryOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s EvaluationResultQualifier) GoString() string { +func (s GetAggregateConfigRuleComplianceSummaryOutput) GoString() string { return s.String() } -// SetConfigRuleName sets the ConfigRuleName field's value. -func (s *EvaluationResultQualifier) SetConfigRuleName(v string) *EvaluationResultQualifier { - s.ConfigRuleName = &v +// SetAggregateComplianceCounts sets the AggregateComplianceCounts field's value. +func (s *GetAggregateConfigRuleComplianceSummaryOutput) SetAggregateComplianceCounts(v []*AggregateComplianceCount) *GetAggregateConfigRuleComplianceSummaryOutput { + s.AggregateComplianceCounts = v return s } -// SetResourceId sets the ResourceId field's value. -func (s *EvaluationResultQualifier) SetResourceId(v string) *EvaluationResultQualifier { - s.ResourceId = &v +// SetGroupByKey sets the GroupByKey field's value. +func (s *GetAggregateConfigRuleComplianceSummaryOutput) SetGroupByKey(v string) *GetAggregateConfigRuleComplianceSummaryOutput { + s.GroupByKey = &v return s } -// SetResourceType sets the ResourceType field's value. -func (s *EvaluationResultQualifier) SetResourceType(v string) *EvaluationResultQualifier { - s.ResourceType = &v +// SetNextToken sets the NextToken field's value. +func (s *GetAggregateConfigRuleComplianceSummaryOutput) SetNextToken(v string) *GetAggregateConfigRuleComplianceSummaryOutput { + s.NextToken = &v return s } @@ -4975,11 +7841,11 @@ type GetComplianceDetailsByConfigRuleInput struct { ConfigRuleName *string `min:"1" type:"string" required:"true"` // The maximum number of evaluation results returned on each page. The default - // is 10. You cannot specify a limit greater than 100. If you specify 0, AWS + // is 10. You cannot specify a number greater than 100. If you specify 0, AWS // Config uses the default. Limit *int64 `type:"integer"` - // The NextToken string returned on a previous page that you use to get the + // The nextToken string returned on a previous page that you use to get the // next page of results in a paginated response. NextToken *string `type:"string"` } @@ -5076,7 +7942,7 @@ type GetComplianceDetailsByResourceInput struct { // The allowed values are COMPLIANT, NON_COMPLIANT, and NOT_APPLICABLE. ComplianceTypes []*string `type:"list"` - // The NextToken string returned on a previous page that you use to get the + // The nextToken string returned on a previous page that you use to get the // next page of results in a paginated response. NextToken *string `type:"string"` @@ -5224,9 +8090,8 @@ type GetComplianceSummaryByResourceTypeInput struct { // Specify one or more resource types to get the number of resources that are // compliant and the number that are noncompliant for each resource type. // - // For this request, you can specify an AWS resource type such as AWS::EC2::Instance, - // and you can specify that the resource type is an AWS account by specifying - // AWS::::Account. + // For this request, you can specify an AWS resource type such as AWS::EC2::Instance. + // You can specify that the resource type is an AWS account by specifying AWS::::Account. ResourceTypes []*string `type:"list"` } @@ -5275,7 +8140,7 @@ type GetDiscoveredResourceCountsInput struct { _ struct{} `type:"structure"` // The maximum number of ResourceCount objects returned on each page. The default - // is 100. You cannot specify a limit greater than 100. If you specify 0, AWS + // is 100. You cannot specify a number greater than 100. If you specify 0, AWS // Config uses the default. Limit *int64 `locationName:"limit" type:"integer"` @@ -5284,7 +8149,7 @@ type GetDiscoveredResourceCountsInput struct { NextToken *string `locationName:"nextToken" type:"string"` // The comma-separated list that specifies the resource types that you want - // the AWS Config to return. For example, ("AWS::EC2::Instance", "AWS::IAM::User"). + // AWS Config to return (for example, "AWS::EC2::Instance", "AWS::IAM::User"). // // If a value for resourceTypes is not specified, AWS Config returns all resource // types that AWS Config is recording in the region for your account. @@ -5346,7 +8211,7 @@ type GetDiscoveredResourceCountsOutput struct { // a total of 60 resources. // // You make a call to the GetDiscoveredResourceCounts action and specify the - // resource type, "AWS::EC2::Instances" in the request. + // resource type, "AWS::EC2::Instances", in the request. // // AWS Config returns 25 for totalDiscoveredResources. TotalDiscoveredResources *int64 `locationName:"totalDiscoveredResources" type:"long"` @@ -5384,13 +8249,13 @@ func (s *GetDiscoveredResourceCountsOutput) SetTotalDiscoveredResources(v int64) type GetResourceConfigHistoryInput struct { _ struct{} `type:"structure"` - // The chronological order for configuration items listed. By default the results + // The chronological order for configuration items listed. By default, the results // are listed in reverse chronological order. ChronologicalOrder *string `locationName:"chronologicalOrder" type:"string" enum:"ChronologicalOrder"` // The time stamp that indicates an earlier time. If not specified, the action - // returns paginated results that contain configuration items that start from - // when the first configuration item was recorded. + // returns paginated results that contain configuration items that start when + // the first configuration item was recorded. EarlierTime *time.Time `locationName:"earlierTime" type:"timestamp" timestampFormat:"unix"` // The time stamp that indicates a later time. If not specified, current time @@ -5398,7 +8263,7 @@ type GetResourceConfigHistoryInput struct { LaterTime *time.Time `locationName:"laterTime" type:"timestamp" timestampFormat:"unix"` // The maximum number of configuration items returned on each page. The default - // is 10. You cannot specify a limit greater than 100. If you specify 0, AWS + // is 10. You cannot specify a number greater than 100. If you specify 0, AWS // Config uses the default. Limit *int64 `locationName:"limit" type:"integer"` @@ -5527,7 +8392,7 @@ type ListDiscoveredResourcesInput struct { IncludeDeletedResources *bool `locationName:"includeDeletedResources" type:"boolean"` // The maximum number of resource identifiers returned on each page. The default - // is 100. You cannot specify a limit greater than 100. If you specify 0, AWS + // is 100. You cannot specify a number greater than 100. If you specify 0, AWS // Config uses the default. Limit *int64 `locationName:"limit" type:"integer"` @@ -5644,6 +8509,180 @@ func (s *ListDiscoveredResourcesOutput) SetResourceIdentifiers(v []*ResourceIden return s } +// This object contains regions to setup the aggregator and an IAM role to retrieve +// organization details. +type OrganizationAggregationSource struct { + _ struct{} `type:"structure"` + + // If true, aggreagate existing AWS Config regions and future regions. + AllAwsRegions *bool `type:"boolean"` + + // The source regions being aggregated. + AwsRegions []*string `min:"1" type:"list"` + + // ARN of the IAM role used to retreive AWS Organization details associated + // with the aggregator account. + // + // RoleArn is a required field + RoleArn *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s OrganizationAggregationSource) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s OrganizationAggregationSource) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *OrganizationAggregationSource) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "OrganizationAggregationSource"} + if s.AwsRegions != nil && len(s.AwsRegions) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AwsRegions", 1)) + } + if s.RoleArn == nil { + invalidParams.Add(request.NewErrParamRequired("RoleArn")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAllAwsRegions sets the AllAwsRegions field's value. +func (s *OrganizationAggregationSource) SetAllAwsRegions(v bool) *OrganizationAggregationSource { + s.AllAwsRegions = &v + return s +} + +// SetAwsRegions sets the AwsRegions field's value. +func (s *OrganizationAggregationSource) SetAwsRegions(v []*string) *OrganizationAggregationSource { + s.AwsRegions = v + return s +} + +// SetRoleArn sets the RoleArn field's value. +func (s *OrganizationAggregationSource) SetRoleArn(v string) *OrganizationAggregationSource { + s.RoleArn = &v + return s +} + +// An object that represents the account ID and region of an aggregator account +// that is requesting authorization but is not yet authorized. +type PendingAggregationRequest struct { + _ struct{} `type:"structure"` + + // The 12-digit account ID of the account requesting to aggregate data. + RequesterAccountId *string `type:"string"` + + // The region requesting to aggregate data. + RequesterAwsRegion *string `min:"1" type:"string"` +} + +// String returns the string representation +func (s PendingAggregationRequest) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PendingAggregationRequest) GoString() string { + return s.String() +} + +// SetRequesterAccountId sets the RequesterAccountId field's value. +func (s *PendingAggregationRequest) SetRequesterAccountId(v string) *PendingAggregationRequest { + s.RequesterAccountId = &v + return s +} + +// SetRequesterAwsRegion sets the RequesterAwsRegion field's value. +func (s *PendingAggregationRequest) SetRequesterAwsRegion(v string) *PendingAggregationRequest { + s.RequesterAwsRegion = &v + return s +} + +type PutAggregationAuthorizationInput struct { + _ struct{} `type:"structure"` + + // The 12-digit account ID of the account authorized to aggregate data. + // + // AuthorizedAccountId is a required field + AuthorizedAccountId *string `type:"string" required:"true"` + + // The region authorized to collect aggregated data. + // + // AuthorizedAwsRegion is a required field + AuthorizedAwsRegion *string `min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s PutAggregationAuthorizationInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PutAggregationAuthorizationInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *PutAggregationAuthorizationInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PutAggregationAuthorizationInput"} + if s.AuthorizedAccountId == nil { + invalidParams.Add(request.NewErrParamRequired("AuthorizedAccountId")) + } + if s.AuthorizedAwsRegion == nil { + invalidParams.Add(request.NewErrParamRequired("AuthorizedAwsRegion")) + } + if s.AuthorizedAwsRegion != nil && len(*s.AuthorizedAwsRegion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AuthorizedAwsRegion", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAuthorizedAccountId sets the AuthorizedAccountId field's value. +func (s *PutAggregationAuthorizationInput) SetAuthorizedAccountId(v string) *PutAggregationAuthorizationInput { + s.AuthorizedAccountId = &v + return s +} + +// SetAuthorizedAwsRegion sets the AuthorizedAwsRegion field's value. +func (s *PutAggregationAuthorizationInput) SetAuthorizedAwsRegion(v string) *PutAggregationAuthorizationInput { + s.AuthorizedAwsRegion = &v + return s +} + +type PutAggregationAuthorizationOutput struct { + _ struct{} `type:"structure"` + + // Returns an AggregationAuthorization object. + AggregationAuthorization *AggregationAuthorization `type:"structure"` +} + +// String returns the string representation +func (s PutAggregationAuthorizationOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PutAggregationAuthorizationOutput) GoString() string { + return s.String() +} + +// SetAggregationAuthorization sets the AggregationAuthorization field's value. +func (s *PutAggregationAuthorizationOutput) SetAggregationAuthorization(v *AggregationAuthorization) *PutAggregationAuthorizationOutput { + s.AggregationAuthorization = v + return s +} + type PutConfigRuleInput struct { _ struct{} `type:"structure"` @@ -5701,6 +8740,103 @@ func (s PutConfigRuleOutput) GoString() string { return s.String() } +type PutConfigurationAggregatorInput struct { + _ struct{} `type:"structure"` + + // A list of AccountAggregationSource object. + AccountAggregationSources []*AccountAggregationSource `type:"list"` + + // The name of the configuration aggregator. + // + // ConfigurationAggregatorName is a required field + ConfigurationAggregatorName *string `min:"1" type:"string" required:"true"` + + // An OrganizationAggregationSource object. + OrganizationAggregationSource *OrganizationAggregationSource `type:"structure"` +} + +// String returns the string representation +func (s PutConfigurationAggregatorInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PutConfigurationAggregatorInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *PutConfigurationAggregatorInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PutConfigurationAggregatorInput"} + if s.ConfigurationAggregatorName == nil { + invalidParams.Add(request.NewErrParamRequired("ConfigurationAggregatorName")) + } + if s.ConfigurationAggregatorName != nil && len(*s.ConfigurationAggregatorName) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ConfigurationAggregatorName", 1)) + } + if s.AccountAggregationSources != nil { + for i, v := range s.AccountAggregationSources { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "AccountAggregationSources", i), err.(request.ErrInvalidParams)) + } + } + } + if s.OrganizationAggregationSource != nil { + if err := s.OrganizationAggregationSource.Validate(); err != nil { + invalidParams.AddNested("OrganizationAggregationSource", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAccountAggregationSources sets the AccountAggregationSources field's value. +func (s *PutConfigurationAggregatorInput) SetAccountAggregationSources(v []*AccountAggregationSource) *PutConfigurationAggregatorInput { + s.AccountAggregationSources = v + return s +} + +// SetConfigurationAggregatorName sets the ConfigurationAggregatorName field's value. +func (s *PutConfigurationAggregatorInput) SetConfigurationAggregatorName(v string) *PutConfigurationAggregatorInput { + s.ConfigurationAggregatorName = &v + return s +} + +// SetOrganizationAggregationSource sets the OrganizationAggregationSource field's value. +func (s *PutConfigurationAggregatorInput) SetOrganizationAggregationSource(v *OrganizationAggregationSource) *PutConfigurationAggregatorInput { + s.OrganizationAggregationSource = v + return s +} + +type PutConfigurationAggregatorOutput struct { + _ struct{} `type:"structure"` + + // Returns a ConfigurationAggregator object. + ConfigurationAggregator *ConfigurationAggregator `type:"structure"` +} + +// String returns the string representation +func (s PutConfigurationAggregatorOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PutConfigurationAggregatorOutput) GoString() string { + return s.String() +} + +// SetConfigurationAggregator sets the ConfigurationAggregator field's value. +func (s *PutConfigurationAggregatorOutput) SetConfigurationAggregator(v *ConfigurationAggregator) *PutConfigurationAggregatorOutput { + s.ConfigurationAggregator = v + return s +} + // The input for the PutConfigurationRecorder action. type PutConfigurationRecorderInput struct { _ struct{} `type:"structure"` @@ -5765,7 +8901,7 @@ type PutDeliveryChannelInput struct { _ struct{} `type:"structure"` // The configuration delivery channel object that delivers the configuration - // information to an Amazon S3 bucket, and to an Amazon SNS topic. + // information to an Amazon S3 bucket and to an Amazon SNS topic. // // DeliveryChannel is a required field DeliveryChannel *DeliveryChannel `type:"structure" required:"true"` @@ -5828,7 +8964,7 @@ type PutEvaluationsInput struct { Evaluations []*Evaluation `type:"list"` // An encrypted token that associates an evaluation with an AWS Config rule. - // Identifies the rule and the event that triggered the evaluation + // Identifies the rule and the event that triggered the evaluation. // // ResultToken is a required field ResultToken *string `type:"string" required:"true"` @@ -5944,7 +9080,7 @@ func (s *PutEvaluationsOutput) SetFailedEvaluations(v []*Evaluation) *PutEvaluat // If you don't want AWS Config to record all resources, you can specify which // types of resources it will record with the resourceTypes parameter. // -// For a list of supported resource types, see Supported resource types (http://docs.aws.amazon.com/config/latest/developerguide/resource-config-reference.html#supported-resources). +// For a list of supported resource types, see Supported Resource Types (http://docs.aws.amazon.com/config/latest/developerguide/resource-config-reference.html#supported-resources). // // For more information, see Selecting Which Resources AWS Config Records (http://docs.aws.amazon.com/config/latest/developerguide/select-resources.html). type RecordingGroup struct { @@ -5954,8 +9090,7 @@ type RecordingGroup struct { // type of regional resource. // // If you set this option to true, when AWS Config adds support for a new type - // of regional resource, it automatically starts recording resources of that - // type. + // of regional resource, it starts recording resources of that type automatically. // // If you set this option to true, you cannot enumerate a list of resourceTypes. AllSupported *bool `locationName:"allSupported" type:"boolean"` @@ -5967,7 +9102,7 @@ type RecordingGroup struct { // to true. // // If you set this option to true, when AWS Config adds support for a new type - // of global resource, it automatically starts recording resources of that type. + // of global resource, it starts recording resources of that type automatically. // // The configuration details for any global resource are the same in all regions. // To prevent duplicate configuration items, you should consider customizing @@ -6076,7 +9211,7 @@ type ResourceCount struct { // The number of resources. Count *int64 `locationName:"count" type:"long"` - // The resource type, for example "AWS::EC2::Instance". + // The resource type (for example, "AWS::EC2::Instance"). ResourceType *string `locationName:"resourceType" type:"string" enum:"ResourceType"` } @@ -6110,7 +9245,7 @@ type ResourceIdentifier struct { // The time that the resource was deleted. ResourceDeletionTime *time.Time `locationName:"resourceDeletionTime" type:"timestamp" timestampFormat:"unix"` - // The ID of the resource (for example., sg-xxxxxx). + // The ID of the resource (for example, sg-xxxxxx). ResourceId *string `locationName:"resourceId" type:"string"` // The custom name of the resource (if available). @@ -6154,6 +9289,60 @@ func (s *ResourceIdentifier) SetResourceType(v string) *ResourceIdentifier { return s } +// The details that identify a resource within AWS Config, including the resource +// type and resource ID. +type ResourceKey struct { + _ struct{} `type:"structure"` + + // The ID of the resource (for example., sg-xxxxxx). + // + // ResourceId is a required field + ResourceId *string `locationName:"resourceId" type:"string" required:"true"` + + // The resource type. + // + // ResourceType is a required field + ResourceType *string `locationName:"resourceType" type:"string" required:"true" enum:"ResourceType"` +} + +// String returns the string representation +func (s ResourceKey) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ResourceKey) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ResourceKey) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ResourceKey"} + if s.ResourceId == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceId")) + } + if s.ResourceType == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceType")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetResourceId sets the ResourceId field's value. +func (s *ResourceKey) SetResourceId(v string) *ResourceKey { + s.ResourceId = &v + return s +} + +// SetResourceType sets the ResourceType field's value. +func (s *ResourceKey) SetResourceType(v string) *ResourceKey { + s.ResourceType = &v + return s +} + // Defines which resources trigger an evaluation for an AWS Config rule. The // scope can include one or more resource types, a combination of a tag key // and value, or a combination of one resource type and one resource ID. Specify @@ -6163,7 +9352,7 @@ func (s *ResourceIdentifier) SetResourceType(v string) *ResourceIdentifier { type Scope struct { _ struct{} `type:"structure"` - // The IDs of the only AWS resource that you want to trigger an evaluation for + // The ID of the only AWS resource that you want to trigger an evaluation for // the rule. If you specify a resource ID, you must specify one resource type // for ComplianceResourceTypes. ComplianceResourceId *string `min:"1" type:"string"` @@ -6320,13 +9509,18 @@ type SourceDetail struct { // to evaluate your AWS resources. EventSource *string `type:"string" enum:"EventSource"` - // The frequency that you want AWS Config to run evaluations for a custom rule - // with a periodic trigger. If you specify a value for MaximumExecutionFrequency, + // The frequency at which you want AWS Config to run evaluations for a custom + // rule with a periodic trigger. If you specify a value for MaximumExecutionFrequency, // then MessageType must use the ScheduledNotification value. // // By default, rules with a periodic trigger are evaluated every 24 hours. To // change the frequency, specify a valid value for the MaximumExecutionFrequency // parameter. + // + // Based on the valid value you choose, AWS Config runs evaluations once for + // each valid value. For example, if you choose Three_Hours, AWS Config runs + // evaluations once every three hours. In this case, Three_Hours is the frequency + // of this rule. MaximumExecutionFrequency *string `type:"string" enum:"MaximumExecutionFrequency"` // The type of notification that triggers AWS Config to run an evaluation for @@ -6382,7 +9576,7 @@ func (s *SourceDetail) SetMessageType(v string) *SourceDetail { type StartConfigRulesEvaluationInput struct { _ struct{} `type:"structure"` - // The list of names of Config rules that you want to run evaluations for. + // The list of names of AWS Config rules that you want to run evaluations for. ConfigRuleNames []*string `min:"1" type:"list"` } @@ -6415,7 +9609,7 @@ func (s *StartConfigRulesEvaluationInput) SetConfigRuleNames(v []*string) *Start return s } -// The output when you start the evaluation for the specified Config rule. +// The output when you start the evaluation for the specified AWS Config rule. type StartConfigRulesEvaluationOutput struct { _ struct{} `type:"structure"` } @@ -6544,6 +9738,25 @@ func (s StopConfigurationRecorderOutput) GoString() string { return s.String() } +const ( + // AggregatedSourceStatusTypeFailed is a AggregatedSourceStatusType enum value + AggregatedSourceStatusTypeFailed = "FAILED" + + // AggregatedSourceStatusTypeSucceeded is a AggregatedSourceStatusType enum value + AggregatedSourceStatusTypeSucceeded = "SUCCEEDED" + + // AggregatedSourceStatusTypeOutdated is a AggregatedSourceStatusType enum value + AggregatedSourceStatusTypeOutdated = "OUTDATED" +) + +const ( + // AggregatedSourceTypeAccount is a AggregatedSourceType enum value + AggregatedSourceTypeAccount = "ACCOUNT" + + // AggregatedSourceTypeOrganization is a AggregatedSourceType enum value + AggregatedSourceTypeOrganization = "ORGANIZATION" +) + const ( // ChronologicalOrderReverse is a ChronologicalOrder enum value ChronologicalOrderReverse = "Reverse" @@ -6566,6 +9779,14 @@ const ( ComplianceTypeInsufficientData = "INSUFFICIENT_DATA" ) +const ( + // ConfigRuleComplianceSummaryGroupKeyAccountId is a ConfigRuleComplianceSummaryGroupKey enum value + ConfigRuleComplianceSummaryGroupKeyAccountId = "ACCOUNT_ID" + + // ConfigRuleComplianceSummaryGroupKeyAwsRegion is a ConfigRuleComplianceSummaryGroupKey enum value + ConfigRuleComplianceSummaryGroupKeyAwsRegion = "AWS_REGION" +) + const ( // ConfigRuleStateActive is a ConfigRuleState enum value ConfigRuleStateActive = "ACTIVE" @@ -6582,16 +9803,19 @@ const ( const ( // ConfigurationItemStatusOk is a ConfigurationItemStatus enum value - ConfigurationItemStatusOk = "Ok" + ConfigurationItemStatusOk = "OK" + + // ConfigurationItemStatusResourceDiscovered is a ConfigurationItemStatus enum value + ConfigurationItemStatusResourceDiscovered = "ResourceDiscovered" - // ConfigurationItemStatusFailed is a ConfigurationItemStatus enum value - ConfigurationItemStatusFailed = "Failed" + // ConfigurationItemStatusResourceNotRecorded is a ConfigurationItemStatus enum value + ConfigurationItemStatusResourceNotRecorded = "ResourceNotRecorded" - // ConfigurationItemStatusDiscovered is a ConfigurationItemStatus enum value - ConfigurationItemStatusDiscovered = "Discovered" + // ConfigurationItemStatusResourceDeleted is a ConfigurationItemStatus enum value + ConfigurationItemStatusResourceDeleted = "ResourceDeleted" - // ConfigurationItemStatusDeleted is a ConfigurationItemStatus enum value - ConfigurationItemStatusDeleted = "Deleted" + // ConfigurationItemStatusResourceDeletedNotRecorded is a ConfigurationItemStatus enum value + ConfigurationItemStatusResourceDeletedNotRecorded = "ResourceDeletedNotRecorded" ) const ( diff --git a/vendor/github.com/aws/aws-sdk-go/service/configservice/doc.go b/vendor/github.com/aws/aws-sdk-go/service/configservice/doc.go index 39b2880e12d3..853be2267323 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/configservice/doc.go +++ b/vendor/github.com/aws/aws-sdk-go/service/configservice/doc.go @@ -8,24 +8,20 @@ // get the current and historical configurations of each AWS resource and also // to get information about the relationship between the resources. An AWS resource // can be an Amazon Compute Cloud (Amazon EC2) instance, an Elastic Block Store -// (EBS) volume, an Elastic network Interface (ENI), or a security group. For +// (EBS) volume, an elastic network Interface (ENI), or a security group. For // a complete list of resources currently supported by AWS Config, see Supported // AWS Resources (http://docs.aws.amazon.com/config/latest/developerguide/resource-config-reference.html#supported-resources). // // You can access and manage AWS Config through the AWS Management Console, // the AWS Command Line Interface (AWS CLI), the AWS Config API, or the AWS -// SDKs for AWS Config -// -// This reference guide contains documentation for the AWS Config API and the -// AWS CLI commands that you can use to manage AWS Config. -// +// SDKs for AWS Config. This reference guide contains documentation for the +// AWS Config API and the AWS CLI commands that you can use to manage AWS Config. // The AWS Config API uses the Signature Version 4 protocol for signing requests. // For more information about how to sign a request with this protocol, see // Signature Version 4 Signing Process (http://docs.aws.amazon.com/general/latest/gr/signature-version-4.html). -// // For detailed information about AWS Config features and their associated actions // or commands, as well as how to work with AWS Management Console, see What -// Is AWS Config? (http://docs.aws.amazon.com/config/latest/developerguide/WhatIsConfig.html) +// Is AWS Config (http://docs.aws.amazon.com/config/latest/developerguide/WhatIsConfig.html) // in the AWS Config Developer Guide. // // See https://docs.aws.amazon.com/goto/WebAPI/config-2014-11-12 for more information on this service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/configservice/errors.go b/vendor/github.com/aws/aws-sdk-go/service/configservice/errors.go index cc1554087ec0..433f766a8ed2 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/configservice/errors.go +++ b/vendor/github.com/aws/aws-sdk-go/service/configservice/errors.go @@ -43,7 +43,7 @@ const ( // ErrCodeInvalidNextTokenException for service response error code // "InvalidNextTokenException". // - // The specified next token is invalid. Specify the NextToken string that was + // The specified next token is invalid. Specify the nextToken string that was // returned in the previous response to get the next page of results. ErrCodeInvalidNextTokenException = "InvalidNextTokenException" @@ -58,7 +58,7 @@ const ( // "InvalidRecordingGroupException". // // AWS Config throws an exception if the recording group does not contain a - // valid list of resource types. Invalid values could also be incorrectly formatted. + // valid list of resource types. Invalid values might also be incorrectly formatted. ErrCodeInvalidRecordingGroupException = "InvalidRecordingGroupException" // ErrCodeInvalidResultTokenException for service response error code @@ -111,19 +111,19 @@ const ( // // Failed to add the AWS Config rule because the account already contains the // maximum number of 50 rules. Consider deleting any deactivated rules before - // adding new rules. + // you add new rules. ErrCodeMaxNumberOfConfigRulesExceededException = "MaxNumberOfConfigRulesExceededException" // ErrCodeMaxNumberOfConfigurationRecordersExceededException for service response error code // "MaxNumberOfConfigurationRecordersExceededException". // - // You have reached the limit on the number of recorders you can create. + // You have reached the limit of the number of recorders you can create. ErrCodeMaxNumberOfConfigurationRecordersExceededException = "MaxNumberOfConfigurationRecordersExceededException" // ErrCodeMaxNumberOfDeliveryChannelsExceededException for service response error code // "MaxNumberOfDeliveryChannelsExceededException". // - // You have reached the limit on the number of delivery channels you can create. + // You have reached the limit of the number of delivery channels you can create. ErrCodeMaxNumberOfDeliveryChannelsExceededException = "MaxNumberOfDeliveryChannelsExceededException" // ErrCodeNoAvailableConfigurationRecorderException for service response error code @@ -139,6 +139,12 @@ const ( // There is no delivery channel available to record configurations. ErrCodeNoAvailableDeliveryChannelException = "NoAvailableDeliveryChannelException" + // ErrCodeNoAvailableOrganizationException for service response error code + // "NoAvailableOrganizationException". + // + // Organization does is no longer available. + ErrCodeNoAvailableOrganizationException = "NoAvailableOrganizationException" + // ErrCodeNoRunningConfigurationRecorderException for service response error code // "NoRunningConfigurationRecorderException". // @@ -158,6 +164,12 @@ const ( // rule names are correct and try again. ErrCodeNoSuchConfigRuleException = "NoSuchConfigRuleException" + // ErrCodeNoSuchConfigurationAggregatorException for service response error code + // "NoSuchConfigurationAggregatorException". + // + // You have specified a configuration aggregator that does not exist. + ErrCodeNoSuchConfigurationAggregatorException = "NoSuchConfigurationAggregatorException" + // ErrCodeNoSuchConfigurationRecorderException for service response error code // "NoSuchConfigurationRecorderException". // @@ -170,6 +182,19 @@ const ( // You have specified a delivery channel that does not exist. ErrCodeNoSuchDeliveryChannelException = "NoSuchDeliveryChannelException" + // ErrCodeOrganizationAccessDeniedException for service response error code + // "OrganizationAccessDeniedException". + // + // No permission to call the EnableAWSServiceAccess API. + ErrCodeOrganizationAccessDeniedException = "OrganizationAccessDeniedException" + + // ErrCodeOrganizationAllFeaturesNotEnabledException for service response error code + // "OrganizationAllFeaturesNotEnabledException". + // + // The configuration aggregator cannot be created because organization does + // not have all features enabled. + ErrCodeOrganizationAllFeaturesNotEnabledException = "OrganizationAllFeaturesNotEnabledException" + // ErrCodeResourceInUseException for service response error code // "ResourceInUseException". // diff --git a/vendor/github.com/aws/aws-sdk-go/service/databasemigrationservice/api.go b/vendor/github.com/aws/aws-sdk-go/service/databasemigrationservice/api.go index 22bb4d1aaef3..64dbf708445e 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/databasemigrationservice/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/databasemigrationservice/api.go @@ -15,7 +15,7 @@ const opAddTagsToResource = "AddTagsToResource" // AddTagsToResourceRequest generates a "aws/request.Request" representing the // client's request for the AddTagsToResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -97,7 +97,7 @@ const opCreateEndpoint = "CreateEndpoint" // CreateEndpointRequest generates a "aws/request.Request" representing the // client's request for the CreateEndpoint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -192,7 +192,7 @@ const opCreateEventSubscription = "CreateEventSubscription" // CreateEventSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the CreateEventSubscription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -299,7 +299,7 @@ const opCreateReplicationInstance = "CreateReplicationInstance" // CreateReplicationInstanceRequest generates a "aws/request.Request" representing the // client's request for the CreateReplicationInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -407,7 +407,7 @@ const opCreateReplicationSubnetGroup = "CreateReplicationSubnetGroup" // CreateReplicationSubnetGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateReplicationSubnetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -502,7 +502,7 @@ const opCreateReplicationTask = "CreateReplicationTask" // CreateReplicationTaskRequest generates a "aws/request.Request" representing the // client's request for the CreateReplicationTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -597,7 +597,7 @@ const opDeleteCertificate = "DeleteCertificate" // DeleteCertificateRequest generates a "aws/request.Request" representing the // client's request for the DeleteCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -680,7 +680,7 @@ const opDeleteEndpoint = "DeleteEndpoint" // DeleteEndpointRequest generates a "aws/request.Request" representing the // client's request for the DeleteEndpoint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -766,7 +766,7 @@ const opDeleteEventSubscription = "DeleteEventSubscription" // DeleteEventSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the DeleteEventSubscription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -849,7 +849,7 @@ const opDeleteReplicationInstance = "DeleteReplicationInstance" // DeleteReplicationInstanceRequest generates a "aws/request.Request" representing the // client's request for the DeleteReplicationInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -935,7 +935,7 @@ const opDeleteReplicationSubnetGroup = "DeleteReplicationSubnetGroup" // DeleteReplicationSubnetGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteReplicationSubnetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1018,7 +1018,7 @@ const opDeleteReplicationTask = "DeleteReplicationTask" // DeleteReplicationTaskRequest generates a "aws/request.Request" representing the // client's request for the DeleteReplicationTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1101,7 +1101,7 @@ const opDescribeAccountAttributes = "DescribeAccountAttributes" // DescribeAccountAttributesRequest generates a "aws/request.Request" representing the // client's request for the DescribeAccountAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1180,7 +1180,7 @@ const opDescribeCertificates = "DescribeCertificates" // DescribeCertificatesRequest generates a "aws/request.Request" representing the // client's request for the DescribeCertificates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1315,7 +1315,7 @@ const opDescribeConnections = "DescribeConnections" // DescribeConnectionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeConnections operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1451,7 +1451,7 @@ const opDescribeEndpointTypes = "DescribeEndpointTypes" // DescribeEndpointTypesRequest generates a "aws/request.Request" representing the // client's request for the DescribeEndpointTypes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1581,7 +1581,7 @@ const opDescribeEndpoints = "DescribeEndpoints" // DescribeEndpointsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEndpoints operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1716,7 +1716,7 @@ const opDescribeEventCategories = "DescribeEventCategories" // DescribeEventCategoriesRequest generates a "aws/request.Request" representing the // client's request for the DescribeEventCategories operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1793,7 +1793,7 @@ const opDescribeEventSubscriptions = "DescribeEventSubscriptions" // DescribeEventSubscriptionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEventSubscriptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1933,7 +1933,7 @@ const opDescribeEvents = "DescribeEvents" // DescribeEventsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEvents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2065,7 +2065,7 @@ const opDescribeOrderableReplicationInstances = "DescribeOrderableReplicationIns // DescribeOrderableReplicationInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeOrderableReplicationInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2196,7 +2196,7 @@ const opDescribeRefreshSchemasStatus = "DescribeRefreshSchemasStatus" // DescribeRefreshSchemasStatusRequest generates a "aws/request.Request" representing the // client's request for the DescribeRefreshSchemasStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2279,7 +2279,7 @@ const opDescribeReplicationInstanceTaskLogs = "DescribeReplicationInstanceTaskLo // DescribeReplicationInstanceTaskLogsRequest generates a "aws/request.Request" representing the // client's request for the DescribeReplicationInstanceTaskLogs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2418,7 +2418,7 @@ const opDescribeReplicationInstances = "DescribeReplicationInstances" // DescribeReplicationInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeReplicationInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2554,7 +2554,7 @@ const opDescribeReplicationSubnetGroups = "DescribeReplicationSubnetGroups" // DescribeReplicationSubnetGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeReplicationSubnetGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2689,7 +2689,7 @@ const opDescribeReplicationTaskAssessmentResults = "DescribeReplicationTaskAsses // DescribeReplicationTaskAssessmentResultsRequest generates a "aws/request.Request" representing the // client's request for the DescribeReplicationTaskAssessmentResults operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2825,7 +2825,7 @@ const opDescribeReplicationTasks = "DescribeReplicationTasks" // DescribeReplicationTasksRequest generates a "aws/request.Request" representing the // client's request for the DescribeReplicationTasks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2961,7 +2961,7 @@ const opDescribeSchemas = "DescribeSchemas" // DescribeSchemasRequest generates a "aws/request.Request" representing the // client's request for the DescribeSchemas operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3100,7 +3100,7 @@ const opDescribeTableStatistics = "DescribeTableStatistics" // DescribeTableStatisticsRequest generates a "aws/request.Request" representing the // client's request for the DescribeTableStatistics operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3244,7 +3244,7 @@ const opImportCertificate = "ImportCertificate" // ImportCertificateRequest generates a "aws/request.Request" representing the // client's request for the ImportCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3329,7 +3329,7 @@ const opListTagsForResource = "ListTagsForResource" // ListTagsForResourceRequest generates a "aws/request.Request" representing the // client's request for the ListTagsForResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3408,7 +3408,7 @@ const opModifyEndpoint = "ModifyEndpoint" // ModifyEndpointRequest generates a "aws/request.Request" representing the // client's request for the ModifyEndpoint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3500,7 +3500,7 @@ const opModifyEventSubscription = "ModifyEventSubscription" // ModifyEventSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the ModifyEventSubscription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3588,7 +3588,7 @@ const opModifyReplicationInstance = "ModifyReplicationInstance" // ModifyReplicationInstanceRequest generates a "aws/request.Request" representing the // client's request for the ModifyReplicationInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3687,7 +3687,7 @@ const opModifyReplicationSubnetGroup = "ModifyReplicationSubnetGroup" // ModifyReplicationSubnetGroupRequest generates a "aws/request.Request" representing the // client's request for the ModifyReplicationSubnetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3782,7 +3782,7 @@ const opModifyReplicationTask = "ModifyReplicationTask" // ModifyReplicationTaskRequest generates a "aws/request.Request" representing the // client's request for the ModifyReplicationTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3877,7 +3877,7 @@ const opRebootReplicationInstance = "RebootReplicationInstance" // RebootReplicationInstanceRequest generates a "aws/request.Request" representing the // client's request for the RebootReplicationInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3961,7 +3961,7 @@ const opRefreshSchemas = "RefreshSchemas" // RefreshSchemasRequest generates a "aws/request.Request" representing the // client's request for the RefreshSchemas operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4052,7 +4052,7 @@ const opReloadTables = "ReloadTables" // ReloadTablesRequest generates a "aws/request.Request" representing the // client's request for the ReloadTables operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4135,7 +4135,7 @@ const opRemoveTagsFromResource = "RemoveTagsFromResource" // RemoveTagsFromResourceRequest generates a "aws/request.Request" representing the // client's request for the RemoveTagsFromResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4214,7 +4214,7 @@ const opStartReplicationTask = "StartReplicationTask" // StartReplicationTaskRequest generates a "aws/request.Request" representing the // client's request for the StartReplicationTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4300,7 +4300,7 @@ const opStartReplicationTaskAssessment = "StartReplicationTaskAssessment" // StartReplicationTaskAssessmentRequest generates a "aws/request.Request" representing the // client's request for the StartReplicationTaskAssessment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4384,7 +4384,7 @@ const opStopReplicationTask = "StopReplicationTask" // StopReplicationTaskRequest generates a "aws/request.Request" representing the // client's request for the StopReplicationTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4467,7 +4467,7 @@ const opTestConnection = "TestConnection" // TestConnectionRequest generates a "aws/request.Request" representing the // client's request for the TestConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/dax/api.go b/vendor/github.com/aws/aws-sdk-go/service/dax/api.go index 99c044f7a5c6..558bb610ed86 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/dax/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/dax/api.go @@ -14,7 +14,7 @@ const opCreateCluster = "CreateCluster" // CreateClusterRequest generates a "aws/request.Request" representing the // client's request for the CreateCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -132,7 +132,7 @@ const opCreateParameterGroup = "CreateParameterGroup" // CreateParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -224,7 +224,7 @@ const opCreateSubnetGroup = "CreateSubnetGroup" // CreateSubnetGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateSubnetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -314,7 +314,7 @@ const opDecreaseReplicationFactor = "DecreaseReplicationFactor" // DecreaseReplicationFactorRequest generates a "aws/request.Request" representing the // client's request for the DecreaseReplicationFactor operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -408,7 +408,7 @@ const opDeleteCluster = "DeleteCluster" // DeleteClusterRequest generates a "aws/request.Request" representing the // client's request for the DeleteCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -499,7 +499,7 @@ const opDeleteParameterGroup = "DeleteParameterGroup" // DeleteParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -588,7 +588,7 @@ const opDeleteSubnetGroup = "DeleteSubnetGroup" // DeleteSubnetGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteSubnetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -672,7 +672,7 @@ const opDescribeClusters = "DescribeClusters" // DescribeClustersRequest generates a "aws/request.Request" representing the // client's request for the DescribeClusters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -773,7 +773,7 @@ const opDescribeDefaultParameters = "DescribeDefaultParameters" // DescribeDefaultParametersRequest generates a "aws/request.Request" representing the // client's request for the DescribeDefaultParameters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -855,7 +855,7 @@ const opDescribeEvents = "DescribeEvents" // DescribeEventsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEvents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -942,7 +942,7 @@ const opDescribeParameterGroups = "DescribeParameterGroups" // DescribeParameterGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeParameterGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1028,7 +1028,7 @@ const opDescribeParameters = "DescribeParameters" // DescribeParametersRequest generates a "aws/request.Request" representing the // client's request for the DescribeParameters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1113,7 +1113,7 @@ const opDescribeSubnetGroups = "DescribeSubnetGroups" // DescribeSubnetGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeSubnetGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1193,7 +1193,7 @@ const opIncreaseReplicationFactor = "IncreaseReplicationFactor" // IncreaseReplicationFactorRequest generates a "aws/request.Request" representing the // client's request for the IncreaseReplicationFactor operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1294,7 +1294,7 @@ const opListTags = "ListTags" // ListTagsRequest generates a "aws/request.Request" representing the // client's request for the ListTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1386,7 +1386,7 @@ const opRebootNode = "RebootNode" // RebootNodeRequest generates a "aws/request.Request" representing the // client's request for the RebootNode operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1478,7 +1478,7 @@ const opTagResource = "TagResource" // TagResourceRequest generates a "aws/request.Request" representing the // client's request for the TagResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1573,7 +1573,7 @@ const opUntagResource = "UntagResource" // UntagResourceRequest generates a "aws/request.Request" representing the // client's request for the UntagResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1668,7 +1668,7 @@ const opUpdateCluster = "UpdateCluster" // UpdateClusterRequest generates a "aws/request.Request" representing the // client's request for the UpdateCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1764,7 +1764,7 @@ const opUpdateParameterGroup = "UpdateParameterGroup" // UpdateParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the UpdateParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1853,7 +1853,7 @@ const opUpdateSubnetGroup = "UpdateSubnetGroup" // UpdateSubnetGroupRequest generates a "aws/request.Request" representing the // client's request for the UpdateSubnetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/devicefarm/api.go b/vendor/github.com/aws/aws-sdk-go/service/devicefarm/api.go index 31a9a3328aba..aeffc22fa3e8 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/devicefarm/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/devicefarm/api.go @@ -14,7 +14,7 @@ const opCreateDevicePool = "CreateDevicePool" // CreateDevicePoolRequest generates a "aws/request.Request" representing the // client's request for the CreateDevicePool operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -98,11 +98,100 @@ func (c *DeviceFarm) CreateDevicePoolWithContext(ctx aws.Context, input *CreateD return out, req.Send() } +const opCreateInstanceProfile = "CreateInstanceProfile" + +// CreateInstanceProfileRequest generates a "aws/request.Request" representing the +// client's request for the CreateInstanceProfile operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See CreateInstanceProfile for more information on using the CreateInstanceProfile +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the CreateInstanceProfileRequest method. +// req, resp := client.CreateInstanceProfileRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/CreateInstanceProfile +func (c *DeviceFarm) CreateInstanceProfileRequest(input *CreateInstanceProfileInput) (req *request.Request, output *CreateInstanceProfileOutput) { + op := &request.Operation{ + Name: opCreateInstanceProfile, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &CreateInstanceProfileInput{} + } + + output = &CreateInstanceProfileOutput{} + req = c.newRequest(op, input, output) + return +} + +// CreateInstanceProfile API operation for AWS Device Farm. +// +// Creates a profile that can be applied to one or more private fleet device +// instances. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Device Farm's +// API operation CreateInstanceProfile for usage and error information. +// +// Returned Error Codes: +// * ErrCodeArgumentException "ArgumentException" +// An invalid argument was specified. +// +// * ErrCodeNotFoundException "NotFoundException" +// The specified entity was not found. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// A limit was exceeded. +// +// * ErrCodeServiceAccountException "ServiceAccountException" +// There was a problem with the service account. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/CreateInstanceProfile +func (c *DeviceFarm) CreateInstanceProfile(input *CreateInstanceProfileInput) (*CreateInstanceProfileOutput, error) { + req, out := c.CreateInstanceProfileRequest(input) + return out, req.Send() +} + +// CreateInstanceProfileWithContext is the same as CreateInstanceProfile with the addition of +// the ability to pass a context and additional request options. +// +// See CreateInstanceProfile for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *DeviceFarm) CreateInstanceProfileWithContext(ctx aws.Context, input *CreateInstanceProfileInput, opts ...request.Option) (*CreateInstanceProfileOutput, error) { + req, out := c.CreateInstanceProfileRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opCreateNetworkProfile = "CreateNetworkProfile" // CreateNetworkProfileRequest generates a "aws/request.Request" representing the // client's request for the CreateNetworkProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -190,7 +279,7 @@ const opCreateProject = "CreateProject" // CreateProjectRequest generates a "aws/request.Request" representing the // client's request for the CreateProject operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -278,7 +367,7 @@ const opCreateRemoteAccessSession = "CreateRemoteAccessSession" // CreateRemoteAccessSessionRequest generates a "aws/request.Request" representing the // client's request for the CreateRemoteAccessSession operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -366,7 +455,7 @@ const opCreateUpload = "CreateUpload" // CreateUploadRequest generates a "aws/request.Request" representing the // client's request for the CreateUpload operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -454,7 +543,7 @@ const opDeleteDevicePool = "DeleteDevicePool" // DeleteDevicePoolRequest generates a "aws/request.Request" representing the // client's request for the DeleteDevicePool operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -539,11 +628,99 @@ func (c *DeviceFarm) DeleteDevicePoolWithContext(ctx aws.Context, input *DeleteD return out, req.Send() } +const opDeleteInstanceProfile = "DeleteInstanceProfile" + +// DeleteInstanceProfileRequest generates a "aws/request.Request" representing the +// client's request for the DeleteInstanceProfile operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteInstanceProfile for more information on using the DeleteInstanceProfile +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteInstanceProfileRequest method. +// req, resp := client.DeleteInstanceProfileRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/DeleteInstanceProfile +func (c *DeviceFarm) DeleteInstanceProfileRequest(input *DeleteInstanceProfileInput) (req *request.Request, output *DeleteInstanceProfileOutput) { + op := &request.Operation{ + Name: opDeleteInstanceProfile, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DeleteInstanceProfileInput{} + } + + output = &DeleteInstanceProfileOutput{} + req = c.newRequest(op, input, output) + return +} + +// DeleteInstanceProfile API operation for AWS Device Farm. +// +// Deletes a profile that can be applied to one or more private device instances. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Device Farm's +// API operation DeleteInstanceProfile for usage and error information. +// +// Returned Error Codes: +// * ErrCodeArgumentException "ArgumentException" +// An invalid argument was specified. +// +// * ErrCodeNotFoundException "NotFoundException" +// The specified entity was not found. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// A limit was exceeded. +// +// * ErrCodeServiceAccountException "ServiceAccountException" +// There was a problem with the service account. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/DeleteInstanceProfile +func (c *DeviceFarm) DeleteInstanceProfile(input *DeleteInstanceProfileInput) (*DeleteInstanceProfileOutput, error) { + req, out := c.DeleteInstanceProfileRequest(input) + return out, req.Send() +} + +// DeleteInstanceProfileWithContext is the same as DeleteInstanceProfile with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteInstanceProfile for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *DeviceFarm) DeleteInstanceProfileWithContext(ctx aws.Context, input *DeleteInstanceProfileInput, opts ...request.Option) (*DeleteInstanceProfileOutput, error) { + req, out := c.DeleteInstanceProfileRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opDeleteNetworkProfile = "DeleteNetworkProfile" // DeleteNetworkProfileRequest generates a "aws/request.Request" representing the // client's request for the DeleteNetworkProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -631,7 +808,7 @@ const opDeleteProject = "DeleteProject" // DeleteProjectRequest generates a "aws/request.Request" representing the // client's request for the DeleteProject operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -721,7 +898,7 @@ const opDeleteRemoteAccessSession = "DeleteRemoteAccessSession" // DeleteRemoteAccessSessionRequest generates a "aws/request.Request" representing the // client's request for the DeleteRemoteAccessSession operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -809,7 +986,7 @@ const opDeleteRun = "DeleteRun" // DeleteRunRequest generates a "aws/request.Request" representing the // client's request for the DeleteRun operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -899,7 +1076,7 @@ const opDeleteUpload = "DeleteUpload" // DeleteUploadRequest generates a "aws/request.Request" representing the // client's request for the DeleteUpload operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -987,7 +1164,7 @@ const opGetAccountSettings = "GetAccountSettings" // GetAccountSettingsRequest generates a "aws/request.Request" representing the // client's request for the GetAccountSettings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1076,7 +1253,7 @@ const opGetDevice = "GetDevice" // GetDeviceRequest generates a "aws/request.Request" representing the // client's request for the GetDevice operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1160,11 +1337,100 @@ func (c *DeviceFarm) GetDeviceWithContext(ctx aws.Context, input *GetDeviceInput return out, req.Send() } +const opGetDeviceInstance = "GetDeviceInstance" + +// GetDeviceInstanceRequest generates a "aws/request.Request" representing the +// client's request for the GetDeviceInstance operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetDeviceInstance for more information on using the GetDeviceInstance +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetDeviceInstanceRequest method. +// req, resp := client.GetDeviceInstanceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/GetDeviceInstance +func (c *DeviceFarm) GetDeviceInstanceRequest(input *GetDeviceInstanceInput) (req *request.Request, output *GetDeviceInstanceOutput) { + op := &request.Operation{ + Name: opGetDeviceInstance, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &GetDeviceInstanceInput{} + } + + output = &GetDeviceInstanceOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetDeviceInstance API operation for AWS Device Farm. +// +// Returns information about a device instance belonging to a private device +// fleet. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Device Farm's +// API operation GetDeviceInstance for usage and error information. +// +// Returned Error Codes: +// * ErrCodeArgumentException "ArgumentException" +// An invalid argument was specified. +// +// * ErrCodeNotFoundException "NotFoundException" +// The specified entity was not found. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// A limit was exceeded. +// +// * ErrCodeServiceAccountException "ServiceAccountException" +// There was a problem with the service account. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/GetDeviceInstance +func (c *DeviceFarm) GetDeviceInstance(input *GetDeviceInstanceInput) (*GetDeviceInstanceOutput, error) { + req, out := c.GetDeviceInstanceRequest(input) + return out, req.Send() +} + +// GetDeviceInstanceWithContext is the same as GetDeviceInstance with the addition of +// the ability to pass a context and additional request options. +// +// See GetDeviceInstance for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *DeviceFarm) GetDeviceInstanceWithContext(ctx aws.Context, input *GetDeviceInstanceInput, opts ...request.Option) (*GetDeviceInstanceOutput, error) { + req, out := c.GetDeviceInstanceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opGetDevicePool = "GetDevicePool" // GetDevicePoolRequest generates a "aws/request.Request" representing the // client's request for the GetDevicePool operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1252,7 +1518,7 @@ const opGetDevicePoolCompatibility = "GetDevicePoolCompatibility" // GetDevicePoolCompatibilityRequest generates a "aws/request.Request" representing the // client's request for the GetDevicePoolCompatibility operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1336,11 +1602,99 @@ func (c *DeviceFarm) GetDevicePoolCompatibilityWithContext(ctx aws.Context, inpu return out, req.Send() } +const opGetInstanceProfile = "GetInstanceProfile" + +// GetInstanceProfileRequest generates a "aws/request.Request" representing the +// client's request for the GetInstanceProfile operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetInstanceProfile for more information on using the GetInstanceProfile +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetInstanceProfileRequest method. +// req, resp := client.GetInstanceProfileRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/GetInstanceProfile +func (c *DeviceFarm) GetInstanceProfileRequest(input *GetInstanceProfileInput) (req *request.Request, output *GetInstanceProfileOutput) { + op := &request.Operation{ + Name: opGetInstanceProfile, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &GetInstanceProfileInput{} + } + + output = &GetInstanceProfileOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetInstanceProfile API operation for AWS Device Farm. +// +// Returns information about the specified instance profile. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Device Farm's +// API operation GetInstanceProfile for usage and error information. +// +// Returned Error Codes: +// * ErrCodeArgumentException "ArgumentException" +// An invalid argument was specified. +// +// * ErrCodeNotFoundException "NotFoundException" +// The specified entity was not found. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// A limit was exceeded. +// +// * ErrCodeServiceAccountException "ServiceAccountException" +// There was a problem with the service account. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/GetInstanceProfile +func (c *DeviceFarm) GetInstanceProfile(input *GetInstanceProfileInput) (*GetInstanceProfileOutput, error) { + req, out := c.GetInstanceProfileRequest(input) + return out, req.Send() +} + +// GetInstanceProfileWithContext is the same as GetInstanceProfile with the addition of +// the ability to pass a context and additional request options. +// +// See GetInstanceProfile for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *DeviceFarm) GetInstanceProfileWithContext(ctx aws.Context, input *GetInstanceProfileInput, opts ...request.Option) (*GetInstanceProfileOutput, error) { + req, out := c.GetInstanceProfileRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opGetJob = "GetJob" // GetJobRequest generates a "aws/request.Request" representing the // client's request for the GetJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1428,7 +1782,7 @@ const opGetNetworkProfile = "GetNetworkProfile" // GetNetworkProfileRequest generates a "aws/request.Request" representing the // client's request for the GetNetworkProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1516,7 +1870,7 @@ const opGetOfferingStatus = "GetOfferingStatus" // GetOfferingStatusRequest generates a "aws/request.Request" representing the // client's request for the GetOfferingStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1669,7 +2023,7 @@ const opGetProject = "GetProject" // GetProjectRequest generates a "aws/request.Request" representing the // client's request for the GetProject operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1757,7 +2111,7 @@ const opGetRemoteAccessSession = "GetRemoteAccessSession" // GetRemoteAccessSessionRequest generates a "aws/request.Request" representing the // client's request for the GetRemoteAccessSession operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1845,7 +2199,7 @@ const opGetRun = "GetRun" // GetRunRequest generates a "aws/request.Request" representing the // client's request for the GetRun operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1933,7 +2287,7 @@ const opGetSuite = "GetSuite" // GetSuiteRequest generates a "aws/request.Request" representing the // client's request for the GetSuite operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2021,7 +2375,7 @@ const opGetTest = "GetTest" // GetTestRequest generates a "aws/request.Request" representing the // client's request for the GetTest operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2109,7 +2463,7 @@ const opGetUpload = "GetUpload" // GetUploadRequest generates a "aws/request.Request" representing the // client's request for the GetUpload operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2197,7 +2551,7 @@ const opInstallToRemoteAccessSession = "InstallToRemoteAccessSession" // InstallToRemoteAccessSessionRequest generates a "aws/request.Request" representing the // client's request for the InstallToRemoteAccessSession operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2287,7 +2641,7 @@ const opListArtifacts = "ListArtifacts" // ListArtifactsRequest generates a "aws/request.Request" representing the // client's request for the ListArtifacts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2398,40 +2752,129 @@ func (c *DeviceFarm) ListArtifactsPages(input *ListArtifactsInput, fn func(*List return c.ListArtifactsPagesWithContext(aws.BackgroundContext(), input, fn) } -// ListArtifactsPagesWithContext same as ListArtifactsPages except -// it takes a Context and allows setting request options on the pages. +// ListArtifactsPagesWithContext same as ListArtifactsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *DeviceFarm) ListArtifactsPagesWithContext(ctx aws.Context, input *ListArtifactsInput, fn func(*ListArtifactsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListArtifactsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListArtifactsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListArtifactsOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListDeviceInstances = "ListDeviceInstances" + +// ListDeviceInstancesRequest generates a "aws/request.Request" representing the +// client's request for the ListDeviceInstances operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListDeviceInstances for more information on using the ListDeviceInstances +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListDeviceInstancesRequest method. +// req, resp := client.ListDeviceInstancesRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/ListDeviceInstances +func (c *DeviceFarm) ListDeviceInstancesRequest(input *ListDeviceInstancesInput) (req *request.Request, output *ListDeviceInstancesOutput) { + op := &request.Operation{ + Name: opListDeviceInstances, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &ListDeviceInstancesInput{} + } + + output = &ListDeviceInstancesOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListDeviceInstances API operation for AWS Device Farm. +// +// Returns information about the private device instances associated with one +// or more AWS accounts. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Device Farm's +// API operation ListDeviceInstances for usage and error information. +// +// Returned Error Codes: +// * ErrCodeArgumentException "ArgumentException" +// An invalid argument was specified. +// +// * ErrCodeNotFoundException "NotFoundException" +// The specified entity was not found. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// A limit was exceeded. +// +// * ErrCodeServiceAccountException "ServiceAccountException" +// There was a problem with the service account. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/ListDeviceInstances +func (c *DeviceFarm) ListDeviceInstances(input *ListDeviceInstancesInput) (*ListDeviceInstancesOutput, error) { + req, out := c.ListDeviceInstancesRequest(input) + return out, req.Send() +} + +// ListDeviceInstancesWithContext is the same as ListDeviceInstances with the addition of +// the ability to pass a context and additional request options. +// +// See ListDeviceInstances for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *DeviceFarm) ListArtifactsPagesWithContext(ctx aws.Context, input *ListArtifactsInput, fn func(*ListArtifactsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListArtifactsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListArtifactsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*ListArtifactsOutput), !p.HasNextPage()) - } - return p.Err() +func (c *DeviceFarm) ListDeviceInstancesWithContext(ctx aws.Context, input *ListDeviceInstancesInput, opts ...request.Option) (*ListDeviceInstancesOutput, error) { + req, out := c.ListDeviceInstancesRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() } const opListDevicePools = "ListDevicePools" // ListDevicePoolsRequest generates a "aws/request.Request" representing the // client's request for the ListDevicePools operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2575,7 +3018,7 @@ const opListDevices = "ListDevices" // ListDevicesRequest generates a "aws/request.Request" representing the // client's request for the ListDevices operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2715,11 +3158,99 @@ func (c *DeviceFarm) ListDevicesPagesWithContext(ctx aws.Context, input *ListDev return p.Err() } +const opListInstanceProfiles = "ListInstanceProfiles" + +// ListInstanceProfilesRequest generates a "aws/request.Request" representing the +// client's request for the ListInstanceProfiles operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListInstanceProfiles for more information on using the ListInstanceProfiles +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListInstanceProfilesRequest method. +// req, resp := client.ListInstanceProfilesRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/ListInstanceProfiles +func (c *DeviceFarm) ListInstanceProfilesRequest(input *ListInstanceProfilesInput) (req *request.Request, output *ListInstanceProfilesOutput) { + op := &request.Operation{ + Name: opListInstanceProfiles, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &ListInstanceProfilesInput{} + } + + output = &ListInstanceProfilesOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListInstanceProfiles API operation for AWS Device Farm. +// +// Returns information about all the instance profiles in an AWS account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Device Farm's +// API operation ListInstanceProfiles for usage and error information. +// +// Returned Error Codes: +// * ErrCodeArgumentException "ArgumentException" +// An invalid argument was specified. +// +// * ErrCodeNotFoundException "NotFoundException" +// The specified entity was not found. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// A limit was exceeded. +// +// * ErrCodeServiceAccountException "ServiceAccountException" +// There was a problem with the service account. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/ListInstanceProfiles +func (c *DeviceFarm) ListInstanceProfiles(input *ListInstanceProfilesInput) (*ListInstanceProfilesOutput, error) { + req, out := c.ListInstanceProfilesRequest(input) + return out, req.Send() +} + +// ListInstanceProfilesWithContext is the same as ListInstanceProfiles with the addition of +// the ability to pass a context and additional request options. +// +// See ListInstanceProfiles for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *DeviceFarm) ListInstanceProfilesWithContext(ctx aws.Context, input *ListInstanceProfilesInput, opts ...request.Option) (*ListInstanceProfilesOutput, error) { + req, out := c.ListInstanceProfilesRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opListJobs = "ListJobs" // ListJobsRequest generates a "aws/request.Request" representing the // client's request for the ListJobs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2863,7 +3394,7 @@ const opListNetworkProfiles = "ListNetworkProfiles" // ListNetworkProfilesRequest generates a "aws/request.Request" representing the // client's request for the ListNetworkProfiles operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2951,7 +3482,7 @@ const opListOfferingPromotions = "ListOfferingPromotions" // ListOfferingPromotionsRequest generates a "aws/request.Request" representing the // client's request for the ListOfferingPromotions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3047,7 +3578,7 @@ const opListOfferingTransactions = "ListOfferingTransactions" // ListOfferingTransactionsRequest generates a "aws/request.Request" representing the // client's request for the ListOfferingTransactions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3200,7 +3731,7 @@ const opListOfferings = "ListOfferings" // ListOfferingsRequest generates a "aws/request.Request" representing the // client's request for the ListOfferings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3353,7 +3884,7 @@ const opListProjects = "ListProjects" // ListProjectsRequest generates a "aws/request.Request" representing the // client's request for the ListProjects operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3497,7 +4028,7 @@ const opListRemoteAccessSessions = "ListRemoteAccessSessions" // ListRemoteAccessSessionsRequest generates a "aws/request.Request" representing the // client's request for the ListRemoteAccessSessions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3585,7 +4116,7 @@ const opListRuns = "ListRuns" // ListRunsRequest generates a "aws/request.Request" representing the // client's request for the ListRuns operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3729,7 +4260,7 @@ const opListSamples = "ListSamples" // ListSamplesRequest generates a "aws/request.Request" representing the // client's request for the ListSamples operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3873,7 +4404,7 @@ const opListSuites = "ListSuites" // ListSuitesRequest generates a "aws/request.Request" representing the // client's request for the ListSuites operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4017,7 +4548,7 @@ const opListTests = "ListTests" // ListTestsRequest generates a "aws/request.Request" representing the // client's request for the ListTests operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4161,7 +4692,7 @@ const opListUniqueProblems = "ListUniqueProblems" // ListUniqueProblemsRequest generates a "aws/request.Request" representing the // client's request for the ListUniqueProblems operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4305,7 +4836,7 @@ const opListUploads = "ListUploads" // ListUploadsRequest generates a "aws/request.Request" representing the // client's request for the ListUploads operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4449,7 +4980,7 @@ const opPurchaseOffering = "PurchaseOffering" // PurchaseOfferingRequest generates a "aws/request.Request" representing the // client's request for the PurchaseOffering operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4546,7 +5077,7 @@ const opRenewOffering = "RenewOffering" // RenewOfferingRequest generates a "aws/request.Request" representing the // client's request for the RenewOffering operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4642,7 +5173,7 @@ const opScheduleRun = "ScheduleRun" // ScheduleRunRequest generates a "aws/request.Request" representing the // client's request for the ScheduleRun operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4733,7 +5264,7 @@ const opStopRemoteAccessSession = "StopRemoteAccessSession" // StopRemoteAccessSessionRequest generates a "aws/request.Request" representing the // client's request for the StopRemoteAccessSession operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4804,76 +5335,254 @@ func (c *DeviceFarm) StopRemoteAccessSession(input *StopRemoteAccessSessionInput // StopRemoteAccessSessionWithContext is the same as StopRemoteAccessSession with the addition of // the ability to pass a context and additional request options. // -// See StopRemoteAccessSession for details on how to use this API operation. +// See StopRemoteAccessSession for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *DeviceFarm) StopRemoteAccessSessionWithContext(ctx aws.Context, input *StopRemoteAccessSessionInput, opts ...request.Option) (*StopRemoteAccessSessionOutput, error) { + req, out := c.StopRemoteAccessSessionRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opStopRun = "StopRun" + +// StopRunRequest generates a "aws/request.Request" representing the +// client's request for the StopRun operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See StopRun for more information on using the StopRun +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the StopRunRequest method. +// req, resp := client.StopRunRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/StopRun +func (c *DeviceFarm) StopRunRequest(input *StopRunInput) (req *request.Request, output *StopRunOutput) { + op := &request.Operation{ + Name: opStopRun, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &StopRunInput{} + } + + output = &StopRunOutput{} + req = c.newRequest(op, input, output) + return +} + +// StopRun API operation for AWS Device Farm. +// +// Initiates a stop request for the current test run. AWS Device Farm will immediately +// stop the run on devices where tests have not started executing, and you will +// not be billed for these devices. On devices where tests have started executing, +// Setup Suite and Teardown Suite tests will run to completion before stopping +// execution on those devices. You will be billed for Setup, Teardown, and any +// tests that were in progress or already completed. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Device Farm's +// API operation StopRun for usage and error information. +// +// Returned Error Codes: +// * ErrCodeArgumentException "ArgumentException" +// An invalid argument was specified. +// +// * ErrCodeNotFoundException "NotFoundException" +// The specified entity was not found. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// A limit was exceeded. +// +// * ErrCodeServiceAccountException "ServiceAccountException" +// There was a problem with the service account. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/StopRun +func (c *DeviceFarm) StopRun(input *StopRunInput) (*StopRunOutput, error) { + req, out := c.StopRunRequest(input) + return out, req.Send() +} + +// StopRunWithContext is the same as StopRun with the addition of +// the ability to pass a context and additional request options. +// +// See StopRun for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *DeviceFarm) StopRunWithContext(ctx aws.Context, input *StopRunInput, opts ...request.Option) (*StopRunOutput, error) { + req, out := c.StopRunRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateDeviceInstance = "UpdateDeviceInstance" + +// UpdateDeviceInstanceRequest generates a "aws/request.Request" representing the +// client's request for the UpdateDeviceInstance operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateDeviceInstance for more information on using the UpdateDeviceInstance +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the UpdateDeviceInstanceRequest method. +// req, resp := client.UpdateDeviceInstanceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/UpdateDeviceInstance +func (c *DeviceFarm) UpdateDeviceInstanceRequest(input *UpdateDeviceInstanceInput) (req *request.Request, output *UpdateDeviceInstanceOutput) { + op := &request.Operation{ + Name: opUpdateDeviceInstance, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &UpdateDeviceInstanceInput{} + } + + output = &UpdateDeviceInstanceOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateDeviceInstance API operation for AWS Device Farm. +// +// Updates information about an existing private device instance. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Device Farm's +// API operation UpdateDeviceInstance for usage and error information. +// +// Returned Error Codes: +// * ErrCodeArgumentException "ArgumentException" +// An invalid argument was specified. +// +// * ErrCodeNotFoundException "NotFoundException" +// The specified entity was not found. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// A limit was exceeded. +// +// * ErrCodeServiceAccountException "ServiceAccountException" +// There was a problem with the service account. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/UpdateDeviceInstance +func (c *DeviceFarm) UpdateDeviceInstance(input *UpdateDeviceInstanceInput) (*UpdateDeviceInstanceOutput, error) { + req, out := c.UpdateDeviceInstanceRequest(input) + return out, req.Send() +} + +// UpdateDeviceInstanceWithContext is the same as UpdateDeviceInstance with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateDeviceInstance for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *DeviceFarm) StopRemoteAccessSessionWithContext(ctx aws.Context, input *StopRemoteAccessSessionInput, opts ...request.Option) (*StopRemoteAccessSessionOutput, error) { - req, out := c.StopRemoteAccessSessionRequest(input) +func (c *DeviceFarm) UpdateDeviceInstanceWithContext(ctx aws.Context, input *UpdateDeviceInstanceInput, opts ...request.Option) (*UpdateDeviceInstanceOutput, error) { + req, out := c.UpdateDeviceInstanceRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opStopRun = "StopRun" +const opUpdateDevicePool = "UpdateDevicePool" -// StopRunRequest generates a "aws/request.Request" representing the -// client's request for the StopRun operation. The "output" return -// value will be populated with the request's response once the request complets +// UpdateDevicePoolRequest generates a "aws/request.Request" representing the +// client's request for the UpdateDevicePool operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See StopRun for more information on using the StopRun +// See UpdateDevicePool for more information on using the UpdateDevicePool // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the StopRunRequest method. -// req, resp := client.StopRunRequest(params) +// // Example sending a request using the UpdateDevicePoolRequest method. +// req, resp := client.UpdateDevicePoolRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/StopRun -func (c *DeviceFarm) StopRunRequest(input *StopRunInput) (req *request.Request, output *StopRunOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/UpdateDevicePool +func (c *DeviceFarm) UpdateDevicePoolRequest(input *UpdateDevicePoolInput) (req *request.Request, output *UpdateDevicePoolOutput) { op := &request.Operation{ - Name: opStopRun, + Name: opUpdateDevicePool, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &StopRunInput{} + input = &UpdateDevicePoolInput{} } - output = &StopRunOutput{} + output = &UpdateDevicePoolOutput{} req = c.newRequest(op, input, output) return } -// StopRun API operation for AWS Device Farm. +// UpdateDevicePool API operation for AWS Device Farm. // -// Initiates a stop request for the current test run. AWS Device Farm will immediately -// stop the run on devices where tests have not started executing, and you will -// not be billed for these devices. On devices where tests have started executing, -// Setup Suite and Teardown Suite tests will run to completion before stopping -// execution on those devices. You will be billed for Setup, Teardown, and any -// tests that were in progress or already completed. +// Modifies the name, description, and rules in a device pool given the attributes +// and the pool ARN. Rule updates are all-or-nothing, meaning they can only +// be updated as a whole (or not at all). // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Device Farm's -// API operation StopRun for usage and error information. +// API operation UpdateDevicePool for usage and error information. // // Returned Error Codes: // * ErrCodeArgumentException "ArgumentException" @@ -4888,82 +5597,80 @@ func (c *DeviceFarm) StopRunRequest(input *StopRunInput) (req *request.Request, // * ErrCodeServiceAccountException "ServiceAccountException" // There was a problem with the service account. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/StopRun -func (c *DeviceFarm) StopRun(input *StopRunInput) (*StopRunOutput, error) { - req, out := c.StopRunRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/UpdateDevicePool +func (c *DeviceFarm) UpdateDevicePool(input *UpdateDevicePoolInput) (*UpdateDevicePoolOutput, error) { + req, out := c.UpdateDevicePoolRequest(input) return out, req.Send() } -// StopRunWithContext is the same as StopRun with the addition of +// UpdateDevicePoolWithContext is the same as UpdateDevicePool with the addition of // the ability to pass a context and additional request options. // -// See StopRun for details on how to use this API operation. +// See UpdateDevicePool for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *DeviceFarm) StopRunWithContext(ctx aws.Context, input *StopRunInput, opts ...request.Option) (*StopRunOutput, error) { - req, out := c.StopRunRequest(input) +func (c *DeviceFarm) UpdateDevicePoolWithContext(ctx aws.Context, input *UpdateDevicePoolInput, opts ...request.Option) (*UpdateDevicePoolOutput, error) { + req, out := c.UpdateDevicePoolRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opUpdateDevicePool = "UpdateDevicePool" +const opUpdateInstanceProfile = "UpdateInstanceProfile" -// UpdateDevicePoolRequest generates a "aws/request.Request" representing the -// client's request for the UpdateDevicePool operation. The "output" return -// value will be populated with the request's response once the request complets +// UpdateInstanceProfileRequest generates a "aws/request.Request" representing the +// client's request for the UpdateInstanceProfile operation. The "output" return +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See UpdateDevicePool for more information on using the UpdateDevicePool +// See UpdateInstanceProfile for more information on using the UpdateInstanceProfile // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // // -// // Example sending a request using the UpdateDevicePoolRequest method. -// req, resp := client.UpdateDevicePoolRequest(params) +// // Example sending a request using the UpdateInstanceProfileRequest method. +// req, resp := client.UpdateInstanceProfileRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/UpdateDevicePool -func (c *DeviceFarm) UpdateDevicePoolRequest(input *UpdateDevicePoolInput) (req *request.Request, output *UpdateDevicePoolOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/UpdateInstanceProfile +func (c *DeviceFarm) UpdateInstanceProfileRequest(input *UpdateInstanceProfileInput) (req *request.Request, output *UpdateInstanceProfileOutput) { op := &request.Operation{ - Name: opUpdateDevicePool, + Name: opUpdateInstanceProfile, HTTPMethod: "POST", HTTPPath: "/", } if input == nil { - input = &UpdateDevicePoolInput{} + input = &UpdateInstanceProfileInput{} } - output = &UpdateDevicePoolOutput{} + output = &UpdateInstanceProfileOutput{} req = c.newRequest(op, input, output) return } -// UpdateDevicePool API operation for AWS Device Farm. +// UpdateInstanceProfile API operation for AWS Device Farm. // -// Modifies the name, description, and rules in a device pool given the attributes -// and the pool ARN. Rule updates are all-or-nothing, meaning they can only -// be updated as a whole (or not at all). +// Updates information about an existing private device instance profile. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for AWS Device Farm's -// API operation UpdateDevicePool for usage and error information. +// API operation UpdateInstanceProfile for usage and error information. // // Returned Error Codes: // * ErrCodeArgumentException "ArgumentException" @@ -4978,23 +5685,23 @@ func (c *DeviceFarm) UpdateDevicePoolRequest(input *UpdateDevicePoolInput) (req // * ErrCodeServiceAccountException "ServiceAccountException" // There was a problem with the service account. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/UpdateDevicePool -func (c *DeviceFarm) UpdateDevicePool(input *UpdateDevicePoolInput) (*UpdateDevicePoolOutput, error) { - req, out := c.UpdateDevicePoolRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/UpdateInstanceProfile +func (c *DeviceFarm) UpdateInstanceProfile(input *UpdateInstanceProfileInput) (*UpdateInstanceProfileOutput, error) { + req, out := c.UpdateInstanceProfileRequest(input) return out, req.Send() } -// UpdateDevicePoolWithContext is the same as UpdateDevicePool with the addition of +// UpdateInstanceProfileWithContext is the same as UpdateInstanceProfile with the addition of // the ability to pass a context and additional request options. // -// See UpdateDevicePool for details on how to use this API operation. +// See UpdateInstanceProfile for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *DeviceFarm) UpdateDevicePoolWithContext(ctx aws.Context, input *UpdateDevicePoolInput, opts ...request.Option) (*UpdateDevicePoolOutput, error) { - req, out := c.UpdateDevicePoolRequest(input) +func (c *DeviceFarm) UpdateInstanceProfileWithContext(ctx aws.Context, input *UpdateInstanceProfileInput, opts ...request.Option) (*UpdateInstanceProfileOutput, error) { + req, out := c.UpdateInstanceProfileRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() @@ -5004,7 +5711,7 @@ const opUpdateNetworkProfile = "UpdateNetworkProfile" // UpdateNetworkProfileRequest generates a "aws/request.Request" representing the // client's request for the UpdateNetworkProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5092,7 +5799,7 @@ const opUpdateProject = "UpdateProject" // UpdateProjectRequest generates a "aws/request.Request" representing the // client's request for the UpdateProject operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5195,6 +5902,15 @@ type AccountSettings struct { // represents one of the IDs returned by the ListOfferings command. MaxSlots map[string]*int64 `locationName:"maxSlots" type:"map"` + // When set to true, for private devices, Device Farm will not sign your app + // again. For public devices, Device Farm always signs your apps again and this + // parameter has no effect. + // + // For more information about how Device Farm re-signs your app(s), see Do you + // modify my app? (https://aws.amazon.com/device-farm/faq/) in the AWS Device + // Farm FAQs. + SkipAppResign *bool `locationName:"skipAppResign" type:"boolean"` + // Information about an AWS account's usage of free trial device minutes. TrialMinutes *TrialMinutes `locationName:"trialMinutes" type:"structure"` @@ -5240,6 +5956,12 @@ func (s *AccountSettings) SetMaxSlots(v map[string]*int64) *AccountSettings { return s } +// SetSkipAppResign sets the SkipAppResign field's value. +func (s *AccountSettings) SetSkipAppResign(v bool) *AccountSettings { + s.SkipAppResign = &v + return s +} + // SetTrialMinutes sets the TrialMinutes field's value. func (s *AccountSettings) SetTrialMinutes(v *TrialMinutes) *AccountSettings { s.TrialMinutes = v @@ -5594,6 +6316,108 @@ func (s *CreateDevicePoolOutput) SetDevicePool(v *DevicePool) *CreateDevicePoolO return s } +type CreateInstanceProfileInput struct { + _ struct{} `type:"structure"` + + // The description of your instance profile. + Description *string `locationName:"description" type:"string"` + + // An array of strings specifying the list of app packages that should not be + // cleaned up from the device after a test run is over. + // + // The list of packages is only considered if you set packageCleanup to true. + ExcludeAppPackagesFromCleanup []*string `locationName:"excludeAppPackagesFromCleanup" type:"list"` + + // The name of your instance profile. + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` + + // When set to true, Device Farm will remove app packages after a test run. + // The default value is false for private devices. + PackageCleanup *bool `locationName:"packageCleanup" type:"boolean"` + + // When set to true, Device Farm will reboot the instance after a test run. + // The default value is true. + RebootAfterUse *bool `locationName:"rebootAfterUse" type:"boolean"` +} + +// String returns the string representation +func (s CreateInstanceProfileInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateInstanceProfileInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateInstanceProfileInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateInstanceProfileInput"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDescription sets the Description field's value. +func (s *CreateInstanceProfileInput) SetDescription(v string) *CreateInstanceProfileInput { + s.Description = &v + return s +} + +// SetExcludeAppPackagesFromCleanup sets the ExcludeAppPackagesFromCleanup field's value. +func (s *CreateInstanceProfileInput) SetExcludeAppPackagesFromCleanup(v []*string) *CreateInstanceProfileInput { + s.ExcludeAppPackagesFromCleanup = v + return s +} + +// SetName sets the Name field's value. +func (s *CreateInstanceProfileInput) SetName(v string) *CreateInstanceProfileInput { + s.Name = &v + return s +} + +// SetPackageCleanup sets the PackageCleanup field's value. +func (s *CreateInstanceProfileInput) SetPackageCleanup(v bool) *CreateInstanceProfileInput { + s.PackageCleanup = &v + return s +} + +// SetRebootAfterUse sets the RebootAfterUse field's value. +func (s *CreateInstanceProfileInput) SetRebootAfterUse(v bool) *CreateInstanceProfileInput { + s.RebootAfterUse = &v + return s +} + +type CreateInstanceProfileOutput struct { + _ struct{} `type:"structure"` + + // An object containing information about your instance profile. + InstanceProfile *InstanceProfile `locationName:"instanceProfile" type:"structure"` +} + +// String returns the string representation +func (s CreateInstanceProfileOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateInstanceProfileOutput) GoString() string { + return s.String() +} + +// SetInstanceProfile sets the InstanceProfile field's value. +func (s *CreateInstanceProfileOutput) SetInstanceProfile(v *InstanceProfile) *CreateInstanceProfileOutput { + s.InstanceProfile = v + return s +} + type CreateNetworkProfileInput struct { _ struct{} `type:"structure"` @@ -5841,12 +6665,11 @@ func (s *CreateProjectOutput) SetProject(v *Project) *CreateProjectOutput { return s } -// Creates the configuration settings for a remote access session, including -// the device model and type. +// Configuration settings for a remote access session, including billing method. type CreateRemoteAccessSessionConfiguration struct { _ struct{} `type:"structure"` - // Returns the billing method for purposes of configuring a remote access session. + // The billing method for the remote access session. BillingMethod *string `locationName:"billingMethod" type:"string" enum:"BillingMethod"` } @@ -5885,6 +6708,10 @@ type CreateRemoteAccessSessionInput struct { // DeviceArn is a required field DeviceArn *string `locationName:"deviceArn" min:"32" type:"string" required:"true"` + // The Amazon Resource Name (ARN) of the device instance for which you want + // to create a remote access session. + InstanceArn *string `locationName:"instanceArn" min:"32" type:"string"` + // The interaction mode of the remote access session. Valid values are: // // * INTERACTIVE: You can interact with the iOS device by viewing, touching, @@ -5919,6 +6746,15 @@ type CreateRemoteAccessSessionInput struct { // Set to true to enable remote recording for the remote access session. RemoteRecordEnabled *bool `locationName:"remoteRecordEnabled" type:"boolean"` + // When set to true, for private devices, Device Farm will not sign your app + // again. For public devices, Device Farm always signs your apps again and this + // parameter has no effect. + // + // For more information about how Device Farm re-signs your app(s), see Do you + // modify my app? (https://aws.amazon.com/device-farm/faq/) in the AWS Device + // Farm FAQs. + SkipAppResign *bool `locationName:"skipAppResign" type:"boolean"` + // The public key of the ssh key pair you want to use for connecting to remote // devices in your remote debugging session. This is only required if remoteDebugEnabled // is set to true. @@ -5944,6 +6780,9 @@ func (s *CreateRemoteAccessSessionInput) Validate() error { if s.DeviceArn != nil && len(*s.DeviceArn) < 32 { invalidParams.Add(request.NewErrParamMinLen("DeviceArn", 32)) } + if s.InstanceArn != nil && len(*s.InstanceArn) < 32 { + invalidParams.Add(request.NewErrParamMinLen("InstanceArn", 32)) + } if s.ProjectArn == nil { invalidParams.Add(request.NewErrParamRequired("ProjectArn")) } @@ -5978,6 +6817,12 @@ func (s *CreateRemoteAccessSessionInput) SetDeviceArn(v string) *CreateRemoteAcc return s } +// SetInstanceArn sets the InstanceArn field's value. +func (s *CreateRemoteAccessSessionInput) SetInstanceArn(v string) *CreateRemoteAccessSessionInput { + s.InstanceArn = &v + return s +} + // SetInteractionMode sets the InteractionMode field's value. func (s *CreateRemoteAccessSessionInput) SetInteractionMode(v string) *CreateRemoteAccessSessionInput { s.InteractionMode = &v @@ -6014,6 +6859,12 @@ func (s *CreateRemoteAccessSessionInput) SetRemoteRecordEnabled(v bool) *CreateR return s } +// SetSkipAppResign sets the SkipAppResign field's value. +func (s *CreateRemoteAccessSessionInput) SetSkipAppResign(v bool) *CreateRemoteAccessSessionInput { + s.SkipAppResign = &v + return s +} + // SetSshPublicKey sets the SshPublicKey field's value. func (s *CreateRemoteAccessSessionInput) SetSshPublicKey(v string) *CreateRemoteAccessSessionInput { s.SshPublicKey = &v @@ -6299,6 +7150,62 @@ func (s DeleteDevicePoolOutput) GoString() string { return s.String() } +type DeleteInstanceProfileInput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the instance profile you are requesting + // to delete. + // + // Arn is a required field + Arn *string `locationName:"arn" min:"32" type:"string" required:"true"` +} + +// String returns the string representation +func (s DeleteInstanceProfileInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteInstanceProfileInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteInstanceProfileInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteInstanceProfileInput"} + if s.Arn == nil { + invalidParams.Add(request.NewErrParamRequired("Arn")) + } + if s.Arn != nil && len(*s.Arn) < 32 { + invalidParams.Add(request.NewErrParamMinLen("Arn", 32)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetArn sets the Arn field's value. +func (s *DeleteInstanceProfileInput) SetArn(v string) *DeleteInstanceProfileInput { + s.Arn = &v + return s +} + +type DeleteInstanceProfileOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteInstanceProfileOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteInstanceProfileOutput) GoString() string { + return s.String() +} + type DeleteNetworkProfileInput struct { _ struct{} `type:"structure"` @@ -6621,6 +7528,9 @@ type Device struct { // The device's image name. Image *string `locationName:"image" type:"string"` + // The instances belonging to this device. + Instances []*DeviceInstance `locationName:"instances" type:"list"` + // The device's manufacturer name. Manufacturer *string `locationName:"manufacturer" type:"string"` @@ -6719,6 +7629,12 @@ func (s *Device) SetImage(v string) *Device { return s } +// SetInstances sets the Instances field's value. +func (s *Device) SetInstances(v []*DeviceInstance) *Device { + s.Instances = v + return s +} + // SetManufacturer sets the Manufacturer field's value. func (s *Device) SetManufacturer(v string) *Device { s.Manufacturer = &v @@ -6761,27 +7677,96 @@ func (s *Device) SetPlatform(v string) *Device { return s } -// SetRadio sets the Radio field's value. -func (s *Device) SetRadio(v string) *Device { - s.Radio = &v +// SetRadio sets the Radio field's value. +func (s *Device) SetRadio(v string) *Device { + s.Radio = &v + return s +} + +// SetRemoteAccessEnabled sets the RemoteAccessEnabled field's value. +func (s *Device) SetRemoteAccessEnabled(v bool) *Device { + s.RemoteAccessEnabled = &v + return s +} + +// SetRemoteDebugEnabled sets the RemoteDebugEnabled field's value. +func (s *Device) SetRemoteDebugEnabled(v bool) *Device { + s.RemoteDebugEnabled = &v + return s +} + +// SetResolution sets the Resolution field's value. +func (s *Device) SetResolution(v *Resolution) *Device { + s.Resolution = v + return s +} + +// Represents the device instance. +type DeviceInstance struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the device instance. + Arn *string `locationName:"arn" min:"32" type:"string"` + + // The Amazon Resource Name (ARN) of the device. + DeviceArn *string `locationName:"deviceArn" min:"32" type:"string"` + + // A object containing information about the instance profile. + InstanceProfile *InstanceProfile `locationName:"instanceProfile" type:"structure"` + + // An array of strings describing the device instance. + Labels []*string `locationName:"labels" type:"list"` + + // The status of the device instance. Valid values are listed below. + Status *string `locationName:"status" type:"string" enum:"InstanceStatus"` + + // Unique device identifier for the device instance. + Udid *string `locationName:"udid" type:"string"` +} + +// String returns the string representation +func (s DeviceInstance) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeviceInstance) GoString() string { + return s.String() +} + +// SetArn sets the Arn field's value. +func (s *DeviceInstance) SetArn(v string) *DeviceInstance { + s.Arn = &v + return s +} + +// SetDeviceArn sets the DeviceArn field's value. +func (s *DeviceInstance) SetDeviceArn(v string) *DeviceInstance { + s.DeviceArn = &v + return s +} + +// SetInstanceProfile sets the InstanceProfile field's value. +func (s *DeviceInstance) SetInstanceProfile(v *InstanceProfile) *DeviceInstance { + s.InstanceProfile = v return s } -// SetRemoteAccessEnabled sets the RemoteAccessEnabled field's value. -func (s *Device) SetRemoteAccessEnabled(v bool) *Device { - s.RemoteAccessEnabled = &v +// SetLabels sets the Labels field's value. +func (s *DeviceInstance) SetLabels(v []*string) *DeviceInstance { + s.Labels = v return s } -// SetRemoteDebugEnabled sets the RemoteDebugEnabled field's value. -func (s *Device) SetRemoteDebugEnabled(v bool) *Device { - s.RemoteDebugEnabled = &v +// SetStatus sets the Status field's value. +func (s *DeviceInstance) SetStatus(v string) *DeviceInstance { + s.Status = &v return s } -// SetResolution sets the Resolution field's value. -func (s *Device) SetResolution(v *Resolution) *Device { - s.Resolution = v +// SetUdid sets the Udid field's value. +func (s *DeviceInstance) SetUdid(v string) *DeviceInstance { + s.Udid = &v return s } @@ -6955,6 +7940,15 @@ type ExecutionConfiguration struct { // The number of minutes a test run will execute before it times out. JobTimeoutMinutes *int64 `locationName:"jobTimeoutMinutes" type:"integer"` + + // When set to true, for private devices, Device Farm will not sign your app + // again. For public devices, Device Farm always signs your apps again and this + // parameter has no effect. + // + // For more information about how Device Farm re-signs your app(s), see Do you + // modify my app? (https://aws.amazon.com/device-farm/faq/) in the AWS Device + // Farm FAQs. + SkipAppResign *bool `locationName:"skipAppResign" type:"boolean"` } // String returns the string representation @@ -6985,6 +7979,12 @@ func (s *ExecutionConfiguration) SetJobTimeoutMinutes(v int64) *ExecutionConfigu return s } +// SetSkipAppResign sets the SkipAppResign field's value. +func (s *ExecutionConfiguration) SetSkipAppResign(v bool) *ExecutionConfiguration { + s.SkipAppResign = &v + return s +} + // Represents the request sent to retrieve the account settings. type GetAccountSettingsInput struct { _ struct{} `type:"structure"` @@ -7067,6 +8067,71 @@ func (s *GetDeviceInput) SetArn(v string) *GetDeviceInput { return s } +type GetDeviceInstanceInput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the instance you're requesting information + // about. + // + // Arn is a required field + Arn *string `locationName:"arn" min:"32" type:"string" required:"true"` +} + +// String returns the string representation +func (s GetDeviceInstanceInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetDeviceInstanceInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetDeviceInstanceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetDeviceInstanceInput"} + if s.Arn == nil { + invalidParams.Add(request.NewErrParamRequired("Arn")) + } + if s.Arn != nil && len(*s.Arn) < 32 { + invalidParams.Add(request.NewErrParamMinLen("Arn", 32)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetArn sets the Arn field's value. +func (s *GetDeviceInstanceInput) SetArn(v string) *GetDeviceInstanceInput { + s.Arn = &v + return s +} + +type GetDeviceInstanceOutput struct { + _ struct{} `type:"structure"` + + // An object containing information about your device instance. + DeviceInstance *DeviceInstance `locationName:"deviceInstance" type:"structure"` +} + +// String returns the string representation +func (s GetDeviceInstanceOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetDeviceInstanceOutput) GoString() string { + return s.String() +} + +// SetDeviceInstance sets the DeviceInstance field's value. +func (s *GetDeviceInstanceOutput) SetDeviceInstance(v *DeviceInstance) *GetDeviceInstanceOutput { + s.DeviceInstance = v + return s +} + // Represents the result of a get device request. type GetDeviceOutput struct { _ struct{} `type:"structure"` @@ -7299,6 +8364,70 @@ func (s *GetDevicePoolOutput) SetDevicePool(v *DevicePool) *GetDevicePoolOutput return s } +type GetInstanceProfileInput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of your instance profile. + // + // Arn is a required field + Arn *string `locationName:"arn" min:"32" type:"string" required:"true"` +} + +// String returns the string representation +func (s GetInstanceProfileInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetInstanceProfileInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetInstanceProfileInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetInstanceProfileInput"} + if s.Arn == nil { + invalidParams.Add(request.NewErrParamRequired("Arn")) + } + if s.Arn != nil && len(*s.Arn) < 32 { + invalidParams.Add(request.NewErrParamMinLen("Arn", 32)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetArn sets the Arn field's value. +func (s *GetInstanceProfileInput) SetArn(v string) *GetInstanceProfileInput { + s.Arn = &v + return s +} + +type GetInstanceProfileOutput struct { + _ struct{} `type:"structure"` + + // An object containing information about your instance profile. + InstanceProfile *InstanceProfile `locationName:"instanceProfile" type:"structure"` +} + +// String returns the string representation +func (s GetInstanceProfileOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetInstanceProfileOutput) GoString() string { + return s.String() +} + +// SetInstanceProfile sets the InstanceProfile field's value. +func (s *GetInstanceProfileOutput) SetInstanceProfile(v *InstanceProfile) *GetInstanceProfileOutput { + s.InstanceProfile = v + return s +} + // Represents a request to the get job operation. type GetJobInput struct { _ struct{} `type:"structure"` @@ -8045,6 +9174,80 @@ func (s *InstallToRemoteAccessSessionOutput) SetAppUpload(v *Upload) *InstallToR return s } +// Represents the instance profile. +type InstanceProfile struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the instance profile. + Arn *string `locationName:"arn" min:"32" type:"string"` + + // The description of the instance profile. + Description *string `locationName:"description" type:"string"` + + // An array of strings specifying the list of app packages that should not be + // cleaned up from the device after a test run is over. + // + // The list of packages is only considered if you set packageCleanup to true. + ExcludeAppPackagesFromCleanup []*string `locationName:"excludeAppPackagesFromCleanup" type:"list"` + + // The name of the instance profile. + Name *string `locationName:"name" type:"string"` + + // When set to true, Device Farm will remove app packages after a test run. + // The default value is false for private devices. + PackageCleanup *bool `locationName:"packageCleanup" type:"boolean"` + + // When set to true, Device Farm will reboot the instance after a test run. + // The default value is true. + RebootAfterUse *bool `locationName:"rebootAfterUse" type:"boolean"` +} + +// String returns the string representation +func (s InstanceProfile) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s InstanceProfile) GoString() string { + return s.String() +} + +// SetArn sets the Arn field's value. +func (s *InstanceProfile) SetArn(v string) *InstanceProfile { + s.Arn = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *InstanceProfile) SetDescription(v string) *InstanceProfile { + s.Description = &v + return s +} + +// SetExcludeAppPackagesFromCleanup sets the ExcludeAppPackagesFromCleanup field's value. +func (s *InstanceProfile) SetExcludeAppPackagesFromCleanup(v []*string) *InstanceProfile { + s.ExcludeAppPackagesFromCleanup = v + return s +} + +// SetName sets the Name field's value. +func (s *InstanceProfile) SetName(v string) *InstanceProfile { + s.Name = &v + return s +} + +// SetPackageCleanup sets the PackageCleanup field's value. +func (s *InstanceProfile) SetPackageCleanup(v bool) *InstanceProfile { + s.PackageCleanup = &v + return s +} + +// SetRebootAfterUse sets the RebootAfterUse field's value. +func (s *InstanceProfile) SetRebootAfterUse(v bool) *InstanceProfile { + s.RebootAfterUse = &v + return s +} + // Represents a device. type Job struct { _ struct{} `type:"structure"` @@ -8064,6 +9267,9 @@ type Job struct { // Represents the total (metered or unmetered) minutes used by the job. DeviceMinutes *DeviceMinutes `locationName:"deviceMinutes" type:"structure"` + // The Amazon Resource Name (ARN) of the instance. + InstanceArn *string `locationName:"instanceArn" min:"32" type:"string"` + // A message about the job's result. Message *string `locationName:"message" type:"string"` @@ -8194,6 +9400,12 @@ func (s *Job) SetDeviceMinutes(v *DeviceMinutes) *Job { return s } +// SetInstanceArn sets the InstanceArn field's value. +func (s *Job) SetInstanceArn(v string) *Job { + s.InstanceArn = &v + return s +} + // SetMessage sets the Message field's value. func (s *Job) SetMessage(v string) *Job { s.Message = &v @@ -8264,30 +9476,118 @@ type ListArtifactsInput struct { } // String returns the string representation -func (s ListArtifactsInput) String() string { +func (s ListArtifactsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListArtifactsInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListArtifactsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListArtifactsInput"} + if s.Arn == nil { + invalidParams.Add(request.NewErrParamRequired("Arn")) + } + if s.Arn != nil && len(*s.Arn) < 32 { + invalidParams.Add(request.NewErrParamMinLen("Arn", 32)) + } + if s.NextToken != nil && len(*s.NextToken) < 4 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 4)) + } + if s.Type == nil { + invalidParams.Add(request.NewErrParamRequired("Type")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetArn sets the Arn field's value. +func (s *ListArtifactsInput) SetArn(v string) *ListArtifactsInput { + s.Arn = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListArtifactsInput) SetNextToken(v string) *ListArtifactsInput { + s.NextToken = &v + return s +} + +// SetType sets the Type field's value. +func (s *ListArtifactsInput) SetType(v string) *ListArtifactsInput { + s.Type = &v + return s +} + +// Represents the result of a list artifacts operation. +type ListArtifactsOutput struct { + _ struct{} `type:"structure"` + + // Information about the artifacts. + Artifacts []*Artifact `locationName:"artifacts" type:"list"` + + // If the number of items that are returned is significantly large, this is + // an identifier that is also returned, which can be used in a subsequent call + // to this operation to return the next set of items in the list. + NextToken *string `locationName:"nextToken" min:"4" type:"string"` +} + +// String returns the string representation +func (s ListArtifactsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListArtifactsOutput) GoString() string { + return s.String() +} + +// SetArtifacts sets the Artifacts field's value. +func (s *ListArtifactsOutput) SetArtifacts(v []*Artifact) *ListArtifactsOutput { + s.Artifacts = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListArtifactsOutput) SetNextToken(v string) *ListArtifactsOutput { + s.NextToken = &v + return s +} + +type ListDeviceInstancesInput struct { + _ struct{} `type:"structure"` + + // An integer specifying the maximum number of items you want to return in the + // API response. + MaxResults *int64 `locationName:"maxResults" type:"integer"` + + // An identifier that was returned from the previous call to this operation, + // which can be used to return the next set of items in the list. + NextToken *string `locationName:"nextToken" min:"4" type:"string"` +} + +// String returns the string representation +func (s ListDeviceInstancesInput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s ListArtifactsInput) GoString() string { +func (s ListDeviceInstancesInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListArtifactsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListArtifactsInput"} - if s.Arn == nil { - invalidParams.Add(request.NewErrParamRequired("Arn")) - } - if s.Arn != nil && len(*s.Arn) < 32 { - invalidParams.Add(request.NewErrParamMinLen("Arn", 32)) - } +func (s *ListDeviceInstancesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListDeviceInstancesInput"} if s.NextToken != nil && len(*s.NextToken) < 4 { invalidParams.Add(request.NewErrParamMinLen("NextToken", 4)) } - if s.Type == nil { - invalidParams.Add(request.NewErrParamRequired("Type")) - } if invalidParams.Len() > 0 { return invalidParams @@ -8295,55 +9595,47 @@ func (s *ListArtifactsInput) Validate() error { return nil } -// SetArn sets the Arn field's value. -func (s *ListArtifactsInput) SetArn(v string) *ListArtifactsInput { - s.Arn = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListDeviceInstancesInput) SetMaxResults(v int64) *ListDeviceInstancesInput { + s.MaxResults = &v return s } // SetNextToken sets the NextToken field's value. -func (s *ListArtifactsInput) SetNextToken(v string) *ListArtifactsInput { +func (s *ListDeviceInstancesInput) SetNextToken(v string) *ListDeviceInstancesInput { s.NextToken = &v return s } -// SetType sets the Type field's value. -func (s *ListArtifactsInput) SetType(v string) *ListArtifactsInput { - s.Type = &v - return s -} - -// Represents the result of a list artifacts operation. -type ListArtifactsOutput struct { +type ListDeviceInstancesOutput struct { _ struct{} `type:"structure"` - // Information about the artifacts. - Artifacts []*Artifact `locationName:"artifacts" type:"list"` + // An object containing information about your device instances. + DeviceInstances []*DeviceInstance `locationName:"deviceInstances" type:"list"` - // If the number of items that are returned is significantly large, this is - // an identifier that is also returned, which can be used in a subsequent call - // to this operation to return the next set of items in the list. + // An identifier that can be used in the next call to this operation to return + // the next set of items in the list. NextToken *string `locationName:"nextToken" min:"4" type:"string"` } // String returns the string representation -func (s ListArtifactsOutput) String() string { +func (s ListDeviceInstancesOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation -func (s ListArtifactsOutput) GoString() string { +func (s ListDeviceInstancesOutput) GoString() string { return s.String() } -// SetArtifacts sets the Artifacts field's value. -func (s *ListArtifactsOutput) SetArtifacts(v []*Artifact) *ListArtifactsOutput { - s.Artifacts = v +// SetDeviceInstances sets the DeviceInstances field's value. +func (s *ListDeviceInstancesOutput) SetDeviceInstances(v []*DeviceInstance) *ListDeviceInstancesOutput { + s.DeviceInstances = v return s } // SetNextToken sets the NextToken field's value. -func (s *ListArtifactsOutput) SetNextToken(v string) *ListArtifactsOutput { +func (s *ListDeviceInstancesOutput) SetNextToken(v string) *ListDeviceInstancesOutput { s.NextToken = &v return s } @@ -8539,6 +9831,86 @@ func (s *ListDevicesOutput) SetNextToken(v string) *ListDevicesOutput { return s } +type ListInstanceProfilesInput struct { + _ struct{} `type:"structure"` + + // An integer specifying the maximum number of items you want to return in the + // API response. + MaxResults *int64 `locationName:"maxResults" type:"integer"` + + // An identifier that was returned from the previous call to this operation, + // which can be used to return the next set of items in the list. + NextToken *string `locationName:"nextToken" min:"4" type:"string"` +} + +// String returns the string representation +func (s ListInstanceProfilesInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListInstanceProfilesInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListInstanceProfilesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListInstanceProfilesInput"} + if s.NextToken != nil && len(*s.NextToken) < 4 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 4)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMaxResults sets the MaxResults field's value. +func (s *ListInstanceProfilesInput) SetMaxResults(v int64) *ListInstanceProfilesInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListInstanceProfilesInput) SetNextToken(v string) *ListInstanceProfilesInput { + s.NextToken = &v + return s +} + +type ListInstanceProfilesOutput struct { + _ struct{} `type:"structure"` + + // An object containing information about your instance profiles. + InstanceProfiles []*InstanceProfile `locationName:"instanceProfiles" type:"list"` + + // An identifier that can be used in the next call to this operation to return + // the next set of items in the list. + NextToken *string `locationName:"nextToken" min:"4" type:"string"` +} + +// String returns the string representation +func (s ListInstanceProfilesOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListInstanceProfilesOutput) GoString() string { + return s.String() +} + +// SetInstanceProfiles sets the InstanceProfiles field's value. +func (s *ListInstanceProfilesOutput) SetInstanceProfiles(v []*InstanceProfile) *ListInstanceProfilesOutput { + s.InstanceProfiles = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListInstanceProfilesOutput) SetNextToken(v string) *ListInstanceProfilesOutput { + s.NextToken = &v + return s +} + // Represents a request to the list jobs operation. type ListJobsInput struct { _ struct{} `type:"structure"` @@ -10484,6 +11856,9 @@ type RemoteAccessSession struct { // Only returned if remote debugging is enabled for the remote access session. HostAddress *string `locationName:"hostAddress" type:"string"` + // The Amazon Resource Name (ARN) of the instance. + InstanceArn *string `locationName:"instanceArn" min:"32" type:"string"` + // The interaction mode of the remote access session. Valid values are: // // * INTERACTIVE: You can interact with the iOS device by viewing, touching, @@ -10533,6 +11908,15 @@ type RemoteAccessSession struct { // * STOPPED: A stopped condition. Result *string `locationName:"result" type:"string" enum:"ExecutionResult"` + // When set to true, for private devices, Device Farm will not sign your app + // again. For public devices, Device Farm always signs your apps again and this + // parameter has no effect. + // + // For more information about how Device Farm re-signs your app(s), see Do you + // modify my app? (https://aws.amazon.com/device-farm/faq/) in the AWS Device + // Farm FAQs. + SkipAppResign *bool `locationName:"skipAppResign" type:"boolean"` + // The date and time the remote access session was started. Started *time.Time `locationName:"started" type:"timestamp" timestampFormat:"unix"` @@ -10625,6 +12009,12 @@ func (s *RemoteAccessSession) SetHostAddress(v string) *RemoteAccessSession { return s } +// SetInstanceArn sets the InstanceArn field's value. +func (s *RemoteAccessSession) SetInstanceArn(v string) *RemoteAccessSession { + s.InstanceArn = &v + return s +} + // SetInteractionMode sets the InteractionMode field's value. func (s *RemoteAccessSession) SetInteractionMode(v string) *RemoteAccessSession { s.InteractionMode = &v @@ -10667,6 +12057,12 @@ func (s *RemoteAccessSession) SetResult(v string) *RemoteAccessSession { return s } +// SetSkipAppResign sets the SkipAppResign field's value. +func (s *RemoteAccessSession) SetSkipAppResign(v bool) *RemoteAccessSession { + s.SkipAppResign = &v + return s +} + // SetStarted sets the Started field's value. func (s *RemoteAccessSession) SetStarted(v time.Time) *RemoteAccessSession { s.Started = &v @@ -10808,6 +12204,10 @@ type Rule struct { // * REMOTE_ACCESS_ENABLED: Whether the device is enabled for remote access. // // * APPIUM_VERSION: The Appium version for the test. + // + // * INSTANCE_ARN: The Amazon Resource Name (ARN) of the device instance. + // + // * INSTANCE_LABELS: The label of the device instance. Attribute *string `locationName:"attribute" type:"string" enum:"DeviceAttribute"` // The rule's operator. @@ -10956,6 +12356,15 @@ type Run struct { // the same seed value between tests ensures identical event sequences. Seed *int64 `locationName:"seed" type:"integer"` + // When set to true, for private devices, Device Farm will not sign your app + // again. For public devices, Device Farm always signs your apps again and this + // parameter has no effect. + // + // For more information about how Device Farm re-signs your app(s), see Do you + // modify my app? (https://aws.amazon.com/device-farm/faq/) in the AWS Device + // Farm FAQs. + SkipAppResign *bool `locationName:"skipAppResign" type:"boolean"` + // The run's start time. Started *time.Time `locationName:"started" type:"timestamp" timestampFormat:"unix"` @@ -11023,8 +12432,7 @@ type Run struct { // * XCTEST_UI: The XCode UI test type. Type *string `locationName:"type" type:"string" enum:"TestType"` - // A pre-signed Amazon S3 URL that can be used with a corresponding GET request - // to download the symbol file for the run. + // The Device Farm console URL for the recording of the run. WebUrl *string `locationName:"webUrl" type:"string"` } @@ -11170,6 +12578,12 @@ func (s *Run) SetSeed(v int64) *Run { return s } +// SetSkipAppResign sets the SkipAppResign field's value. +func (s *Run) SetSkipAppResign(v bool) *Run { + s.SkipAppResign = &v + return s +} + // SetStarted sets the Started field's value. func (s *Run) SetStarted(v time.Time) *Run { s.Started = &v @@ -12287,6 +13701,92 @@ func (s *UniqueProblem) SetProblems(v []*Problem) *UniqueProblem { return s } +type UpdateDeviceInstanceInput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the device instance. + // + // Arn is a required field + Arn *string `locationName:"arn" min:"32" type:"string" required:"true"` + + // An array of strings that you want to associate with the device instance. + Labels []*string `locationName:"labels" type:"list"` + + // The Amazon Resource Name (ARN) of the profile that you want to associate + // with the device instance. + ProfileArn *string `locationName:"profileArn" min:"32" type:"string"` +} + +// String returns the string representation +func (s UpdateDeviceInstanceInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateDeviceInstanceInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *UpdateDeviceInstanceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateDeviceInstanceInput"} + if s.Arn == nil { + invalidParams.Add(request.NewErrParamRequired("Arn")) + } + if s.Arn != nil && len(*s.Arn) < 32 { + invalidParams.Add(request.NewErrParamMinLen("Arn", 32)) + } + if s.ProfileArn != nil && len(*s.ProfileArn) < 32 { + invalidParams.Add(request.NewErrParamMinLen("ProfileArn", 32)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetArn sets the Arn field's value. +func (s *UpdateDeviceInstanceInput) SetArn(v string) *UpdateDeviceInstanceInput { + s.Arn = &v + return s +} + +// SetLabels sets the Labels field's value. +func (s *UpdateDeviceInstanceInput) SetLabels(v []*string) *UpdateDeviceInstanceInput { + s.Labels = v + return s +} + +// SetProfileArn sets the ProfileArn field's value. +func (s *UpdateDeviceInstanceInput) SetProfileArn(v string) *UpdateDeviceInstanceInput { + s.ProfileArn = &v + return s +} + +type UpdateDeviceInstanceOutput struct { + _ struct{} `type:"structure"` + + // An object containing information about your device instance. + DeviceInstance *DeviceInstance `locationName:"deviceInstance" type:"structure"` +} + +// String returns the string representation +func (s UpdateDeviceInstanceOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateDeviceInstanceOutput) GoString() string { + return s.String() +} + +// SetDeviceInstance sets the DeviceInstance field's value. +func (s *UpdateDeviceInstanceOutput) SetDeviceInstance(v *DeviceInstance) *UpdateDeviceInstanceOutput { + s.DeviceInstance = v + return s +} + // Represents a request to the update device pool operation. type UpdateDevicePoolInput struct { _ struct{} `type:"structure"` @@ -12383,6 +13883,120 @@ func (s *UpdateDevicePoolOutput) SetDevicePool(v *DevicePool) *UpdateDevicePoolO return s } +type UpdateInstanceProfileInput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the instance profile. + // + // Arn is a required field + Arn *string `locationName:"arn" min:"32" type:"string" required:"true"` + + // The updated description for your instance profile. + Description *string `locationName:"description" type:"string"` + + // An array of strings specifying the list of app packages that should not be + // cleaned up from the device after a test run is over. + // + // The list of packages is only considered if you set packageCleanup to true. + ExcludeAppPackagesFromCleanup []*string `locationName:"excludeAppPackagesFromCleanup" type:"list"` + + // The updated name for your instance profile. + Name *string `locationName:"name" type:"string"` + + // The updated choice for whether you want to specify package cleanup. The default + // value is false for private devices. + PackageCleanup *bool `locationName:"packageCleanup" type:"boolean"` + + // The updated choice for whether you want to reboot the device after use. The + // default value is true. + RebootAfterUse *bool `locationName:"rebootAfterUse" type:"boolean"` +} + +// String returns the string representation +func (s UpdateInstanceProfileInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateInstanceProfileInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *UpdateInstanceProfileInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateInstanceProfileInput"} + if s.Arn == nil { + invalidParams.Add(request.NewErrParamRequired("Arn")) + } + if s.Arn != nil && len(*s.Arn) < 32 { + invalidParams.Add(request.NewErrParamMinLen("Arn", 32)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetArn sets the Arn field's value. +func (s *UpdateInstanceProfileInput) SetArn(v string) *UpdateInstanceProfileInput { + s.Arn = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *UpdateInstanceProfileInput) SetDescription(v string) *UpdateInstanceProfileInput { + s.Description = &v + return s +} + +// SetExcludeAppPackagesFromCleanup sets the ExcludeAppPackagesFromCleanup field's value. +func (s *UpdateInstanceProfileInput) SetExcludeAppPackagesFromCleanup(v []*string) *UpdateInstanceProfileInput { + s.ExcludeAppPackagesFromCleanup = v + return s +} + +// SetName sets the Name field's value. +func (s *UpdateInstanceProfileInput) SetName(v string) *UpdateInstanceProfileInput { + s.Name = &v + return s +} + +// SetPackageCleanup sets the PackageCleanup field's value. +func (s *UpdateInstanceProfileInput) SetPackageCleanup(v bool) *UpdateInstanceProfileInput { + s.PackageCleanup = &v + return s +} + +// SetRebootAfterUse sets the RebootAfterUse field's value. +func (s *UpdateInstanceProfileInput) SetRebootAfterUse(v bool) *UpdateInstanceProfileInput { + s.RebootAfterUse = &v + return s +} + +type UpdateInstanceProfileOutput struct { + _ struct{} `type:"structure"` + + // An object containing information about your instance profile. + InstanceProfile *InstanceProfile `locationName:"instanceProfile" type:"structure"` +} + +// String returns the string representation +func (s UpdateInstanceProfileOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateInstanceProfileOutput) GoString() string { + return s.String() +} + +// SetInstanceProfile sets the InstanceProfile field's value. +func (s *UpdateInstanceProfileOutput) SetInstanceProfile(v *InstanceProfile) *UpdateInstanceProfileOutput { + s.InstanceProfile = v + return s +} + type UpdateNetworkProfileInput struct { _ struct{} `type:"structure"` @@ -12911,6 +14525,12 @@ const ( // DeviceAttributeAppiumVersion is a DeviceAttribute enum value DeviceAttributeAppiumVersion = "APPIUM_VERSION" + + // DeviceAttributeInstanceArn is a DeviceAttribute enum value + DeviceAttributeInstanceArn = "INSTANCE_ARN" + + // DeviceAttributeInstanceLabels is a DeviceAttribute enum value + DeviceAttributeInstanceLabels = "INSTANCE_LABELS" ) const ( @@ -12994,6 +14614,20 @@ const ( ExecutionStatusStopping = "STOPPING" ) +const ( + // InstanceStatusInUse is a InstanceStatus enum value + InstanceStatusInUse = "IN_USE" + + // InstanceStatusPreparing is a InstanceStatus enum value + InstanceStatusPreparing = "PREPARING" + + // InstanceStatusAvailable is a InstanceStatus enum value + InstanceStatusAvailable = "AVAILABLE" + + // InstanceStatusNotAvailable is a InstanceStatus enum value + InstanceStatusNotAvailable = "NOT_AVAILABLE" +) + const ( // InteractionModeInteractive is a InteractionMode enum value InteractionModeInteractive = "INTERACTIVE" diff --git a/vendor/github.com/aws/aws-sdk-go/service/directconnect/api.go b/vendor/github.com/aws/aws-sdk-go/service/directconnect/api.go index a48438708573..6ad8c8e30241 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/directconnect/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/directconnect/api.go @@ -15,7 +15,7 @@ const opAllocateConnectionOnInterconnect = "AllocateConnectionOnInterconnect" // AllocateConnectionOnInterconnectRequest generates a "aws/request.Request" representing the // client's request for the AllocateConnectionOnInterconnect operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -109,7 +109,7 @@ const opAllocateHostedConnection = "AllocateHostedConnection" // AllocateHostedConnectionRequest generates a "aws/request.Request" representing the // client's request for the AllocateHostedConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -199,7 +199,7 @@ const opAllocatePrivateVirtualInterface = "AllocatePrivateVirtualInterface" // AllocatePrivateVirtualInterfaceRequest generates a "aws/request.Request" representing the // client's request for the AllocatePrivateVirtualInterface operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -288,7 +288,7 @@ const opAllocatePublicVirtualInterface = "AllocatePublicVirtualInterface" // AllocatePublicVirtualInterfaceRequest generates a "aws/request.Request" representing the // client's request for the AllocatePublicVirtualInterface operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -384,7 +384,7 @@ const opAssociateConnectionWithLag = "AssociateConnectionWithLag" // AssociateConnectionWithLagRequest generates a "aws/request.Request" representing the // client's request for the AssociateConnectionWithLag operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -484,7 +484,7 @@ const opAssociateHostedConnection = "AssociateHostedConnection" // AssociateHostedConnectionRequest generates a "aws/request.Request" representing the // client's request for the AssociateHostedConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -574,7 +574,7 @@ const opAssociateVirtualInterface = "AssociateVirtualInterface" // AssociateVirtualInterfaceRequest generates a "aws/request.Request" representing the // client's request for the AssociateVirtualInterface operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -672,7 +672,7 @@ const opConfirmConnection = "ConfirmConnection" // ConfirmConnectionRequest generates a "aws/request.Request" representing the // client's request for the ConfirmConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -760,7 +760,7 @@ const opConfirmPrivateVirtualInterface = "ConfirmPrivateVirtualInterface" // ConfirmPrivateVirtualInterfaceRequest generates a "aws/request.Request" representing the // client's request for the ConfirmPrivateVirtualInterface operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -848,7 +848,7 @@ const opConfirmPublicVirtualInterface = "ConfirmPublicVirtualInterface" // ConfirmPublicVirtualInterfaceRequest generates a "aws/request.Request" representing the // client's request for the ConfirmPublicVirtualInterface operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -935,7 +935,7 @@ const opCreateBGPPeer = "CreateBGPPeer" // CreateBGPPeerRequest generates a "aws/request.Request" representing the // client's request for the CreateBGPPeer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1031,7 +1031,7 @@ const opCreateConnection = "CreateConnection" // CreateConnectionRequest generates a "aws/request.Request" representing the // client's request for the CreateConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1132,7 +1132,7 @@ const opCreateDirectConnectGateway = "CreateDirectConnectGateway" // CreateDirectConnectGatewayRequest generates a "aws/request.Request" representing the // client's request for the CreateDirectConnectGateway operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1223,7 +1223,7 @@ const opCreateDirectConnectGatewayAssociation = "CreateDirectConnectGatewayAssoc // CreateDirectConnectGatewayAssociationRequest generates a "aws/request.Request" representing the // client's request for the CreateDirectConnectGatewayAssociation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1309,7 +1309,7 @@ const opCreateInterconnect = "CreateInterconnect" // CreateInterconnectRequest generates a "aws/request.Request" representing the // client's request for the CreateInterconnect operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1416,7 +1416,7 @@ const opCreateLag = "CreateLag" // CreateLagRequest generates a "aws/request.Request" representing the // client's request for the CreateLag operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1524,7 +1524,7 @@ const opCreatePrivateVirtualInterface = "CreatePrivateVirtualInterface" // CreatePrivateVirtualInterfaceRequest generates a "aws/request.Request" representing the // client's request for the CreatePrivateVirtualInterface operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1610,7 +1610,7 @@ const opCreatePublicVirtualInterface = "CreatePublicVirtualInterface" // CreatePublicVirtualInterfaceRequest generates a "aws/request.Request" representing the // client's request for the CreatePublicVirtualInterface operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1701,7 +1701,7 @@ const opDeleteBGPPeer = "DeleteBGPPeer" // DeleteBGPPeerRequest generates a "aws/request.Request" representing the // client's request for the DeleteBGPPeer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1787,7 +1787,7 @@ const opDeleteConnection = "DeleteConnection" // DeleteConnectionRequest generates a "aws/request.Request" representing the // client's request for the DeleteConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1876,7 +1876,7 @@ const opDeleteDirectConnectGateway = "DeleteDirectConnectGateway" // DeleteDirectConnectGatewayRequest generates a "aws/request.Request" representing the // client's request for the DeleteDirectConnectGateway operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1962,7 +1962,7 @@ const opDeleteDirectConnectGatewayAssociation = "DeleteDirectConnectGatewayAssoc // DeleteDirectConnectGatewayAssociationRequest generates a "aws/request.Request" representing the // client's request for the DeleteDirectConnectGatewayAssociation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2047,7 +2047,7 @@ const opDeleteInterconnect = "DeleteInterconnect" // DeleteInterconnectRequest generates a "aws/request.Request" representing the // client's request for the DeleteInterconnect operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2133,7 +2133,7 @@ const opDeleteLag = "DeleteLag" // DeleteLagRequest generates a "aws/request.Request" representing the // client's request for the DeleteLag operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2218,7 +2218,7 @@ const opDeleteVirtualInterface = "DeleteVirtualInterface" // DeleteVirtualInterfaceRequest generates a "aws/request.Request" representing the // client's request for the DeleteVirtualInterface operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2302,7 +2302,7 @@ const opDescribeConnectionLoa = "DescribeConnectionLoa" // DescribeConnectionLoaRequest generates a "aws/request.Request" representing the // client's request for the DescribeConnectionLoa operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2397,7 +2397,7 @@ const opDescribeConnections = "DescribeConnections" // DescribeConnectionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeConnections operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2483,7 +2483,7 @@ const opDescribeConnectionsOnInterconnect = "DescribeConnectionsOnInterconnect" // DescribeConnectionsOnInterconnectRequest generates a "aws/request.Request" representing the // client's request for the DescribeConnectionsOnInterconnect operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2574,7 +2574,7 @@ const opDescribeDirectConnectGatewayAssociations = "DescribeDirectConnectGateway // DescribeDirectConnectGatewayAssociationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeDirectConnectGatewayAssociations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2664,7 +2664,7 @@ const opDescribeDirectConnectGatewayAttachments = "DescribeDirectConnectGatewayA // DescribeDirectConnectGatewayAttachmentsRequest generates a "aws/request.Request" representing the // client's request for the DescribeDirectConnectGatewayAttachments operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2754,7 +2754,7 @@ const opDescribeDirectConnectGateways = "DescribeDirectConnectGateways" // DescribeDirectConnectGatewaysRequest generates a "aws/request.Request" representing the // client's request for the DescribeDirectConnectGateways operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2842,7 +2842,7 @@ const opDescribeHostedConnections = "DescribeHostedConnections" // DescribeHostedConnectionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeHostedConnections operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2929,7 +2929,7 @@ const opDescribeInterconnectLoa = "DescribeInterconnectLoa" // DescribeInterconnectLoaRequest generates a "aws/request.Request" representing the // client's request for the DescribeInterconnectLoa operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3024,7 +3024,7 @@ const opDescribeInterconnects = "DescribeInterconnects" // DescribeInterconnectsRequest generates a "aws/request.Request" representing the // client's request for the DescribeInterconnects operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3110,7 +3110,7 @@ const opDescribeLags = "DescribeLags" // DescribeLagsRequest generates a "aws/request.Request" representing the // client's request for the DescribeLags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3196,7 +3196,7 @@ const opDescribeLoa = "DescribeLoa" // DescribeLoaRequest generates a "aws/request.Request" representing the // client's request for the DescribeLoa operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3287,7 +3287,7 @@ const opDescribeLocations = "DescribeLocations" // DescribeLocationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeLocations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3373,7 +3373,7 @@ const opDescribeTags = "DescribeTags" // DescribeTagsRequest generates a "aws/request.Request" representing the // client's request for the DescribeTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3457,7 +3457,7 @@ const opDescribeVirtualGateways = "DescribeVirtualGateways" // DescribeVirtualGatewaysRequest generates a "aws/request.Request" representing the // client's request for the DescribeVirtualGateways operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3547,7 +3547,7 @@ const opDescribeVirtualInterfaces = "DescribeVirtualInterfaces" // DescribeVirtualInterfacesRequest generates a "aws/request.Request" representing the // client's request for the DescribeVirtualInterfaces operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3638,7 +3638,7 @@ const opDisassociateConnectionFromLag = "DisassociateConnectionFromLag" // DisassociateConnectionFromLagRequest generates a "aws/request.Request" representing the // client's request for the DisassociateConnectionFromLag operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3732,7 +3732,7 @@ const opTagResource = "TagResource" // TagResourceRequest generates a "aws/request.Request" representing the // client's request for the TagResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3828,7 +3828,7 @@ const opUntagResource = "UntagResource" // UntagResourceRequest generates a "aws/request.Request" representing the // client's request for the UntagResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3912,7 +3912,7 @@ const opUpdateLag = "UpdateLag" // UpdateLagRequest generates a "aws/request.Request" representing the // client's request for the UpdateLag operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/directoryservice/api.go b/vendor/github.com/aws/aws-sdk-go/service/directoryservice/api.go index 9040732ca3d9..fc3674146856 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/directoryservice/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/directoryservice/api.go @@ -15,7 +15,7 @@ const opAddIpRoutes = "AddIpRoutes" // AddIpRoutesRequest generates a "aws/request.Request" representing the // client's request for the AddIpRoutes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -122,7 +122,7 @@ const opAddTagsToResource = "AddTagsToResource" // AddTagsToResourceRequest generates a "aws/request.Request" representing the // client's request for the AddTagsToResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -215,7 +215,7 @@ const opCancelSchemaExtension = "CancelSchemaExtension" // CancelSchemaExtensionRequest generates a "aws/request.Request" representing the // client's request for the CancelSchemaExtension operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -303,7 +303,7 @@ const opConnectDirectory = "ConnectDirectory" // ConnectDirectoryRequest generates a "aws/request.Request" representing the // client's request for the ConnectDirectory operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -398,7 +398,7 @@ const opCreateAlias = "CreateAlias" // CreateAliasRequest generates a "aws/request.Request" representing the // client's request for the CreateAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -494,7 +494,7 @@ const opCreateComputer = "CreateComputer" // CreateComputerRequest generates a "aws/request.Request" representing the // client's request for the CreateComputer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -595,7 +595,7 @@ const opCreateConditionalForwarder = "CreateConditionalForwarder" // CreateConditionalForwarderRequest generates a "aws/request.Request" representing the // client's request for the CreateConditionalForwarder operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -694,7 +694,7 @@ const opCreateDirectory = "CreateDirectory" // CreateDirectoryRequest generates a "aws/request.Request" representing the // client's request for the CreateDirectory operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -789,7 +789,7 @@ const opCreateMicrosoftAD = "CreateMicrosoftAD" // CreateMicrosoftADRequest generates a "aws/request.Request" representing the // client's request for the CreateMicrosoftAD operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -887,7 +887,7 @@ const opCreateSnapshot = "CreateSnapshot" // CreateSnapshotRequest generates a "aws/request.Request" representing the // client's request for the CreateSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -982,7 +982,7 @@ const opCreateTrust = "CreateTrust" // CreateTrustRequest generates a "aws/request.Request" representing the // client's request for the CreateTrust operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1083,7 +1083,7 @@ const opDeleteConditionalForwarder = "DeleteConditionalForwarder" // DeleteConditionalForwarderRequest generates a "aws/request.Request" representing the // client's request for the DeleteConditionalForwarder operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1177,7 +1177,7 @@ const opDeleteDirectory = "DeleteDirectory" // DeleteDirectoryRequest generates a "aws/request.Request" representing the // client's request for the DeleteDirectory operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1267,7 +1267,7 @@ const opDeleteSnapshot = "DeleteSnapshot" // DeleteSnapshotRequest generates a "aws/request.Request" representing the // client's request for the DeleteSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1355,7 +1355,7 @@ const opDeleteTrust = "DeleteTrust" // DeleteTrustRequest generates a "aws/request.Request" representing the // client's request for the DeleteTrust operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1447,7 +1447,7 @@ const opDeregisterEventTopic = "DeregisterEventTopic" // DeregisterEventTopicRequest generates a "aws/request.Request" representing the // client's request for the DeregisterEventTopic operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1535,7 +1535,7 @@ const opDescribeConditionalForwarders = "DescribeConditionalForwarders" // DescribeConditionalForwardersRequest generates a "aws/request.Request" representing the // client's request for the DescribeConditionalForwarders operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1632,7 +1632,7 @@ const opDescribeDirectories = "DescribeDirectories" // DescribeDirectoriesRequest generates a "aws/request.Request" representing the // client's request for the DescribeDirectories operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1734,7 +1734,7 @@ const opDescribeDomainControllers = "DescribeDomainControllers" // DescribeDomainControllersRequest generates a "aws/request.Request" representing the // client's request for the DescribeDomainControllers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1884,7 +1884,7 @@ const opDescribeEventTopics = "DescribeEventTopics" // DescribeEventTopicsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEventTopics operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1976,7 +1976,7 @@ const opDescribeSnapshots = "DescribeSnapshots" // DescribeSnapshotsRequest generates a "aws/request.Request" representing the // client's request for the DescribeSnapshots operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2074,7 +2074,7 @@ const opDescribeTrusts = "DescribeTrusts" // DescribeTrustsRequest generates a "aws/request.Request" representing the // client's request for the DescribeTrusts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2171,7 +2171,7 @@ const opDisableRadius = "DisableRadius" // DisableRadiusRequest generates a "aws/request.Request" representing the // client's request for the DisableRadius operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2257,7 +2257,7 @@ const opDisableSso = "DisableSso" // DisableSsoRequest generates a "aws/request.Request" representing the // client's request for the DisableSso operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2348,7 +2348,7 @@ const opEnableRadius = "EnableRadius" // EnableRadiusRequest generates a "aws/request.Request" representing the // client's request for the EnableRadius operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2440,7 +2440,7 @@ const opEnableSso = "EnableSso" // EnableSsoRequest generates a "aws/request.Request" representing the // client's request for the EnableSso operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2531,7 +2531,7 @@ const opGetDirectoryLimits = "GetDirectoryLimits" // GetDirectoryLimitsRequest generates a "aws/request.Request" representing the // client's request for the GetDirectoryLimits operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2616,7 +2616,7 @@ const opGetSnapshotLimits = "GetSnapshotLimits" // GetSnapshotLimitsRequest generates a "aws/request.Request" representing the // client's request for the GetSnapshotLimits operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2701,7 +2701,7 @@ const opListIpRoutes = "ListIpRoutes" // ListIpRoutesRequest generates a "aws/request.Request" representing the // client's request for the ListIpRoutes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2792,7 +2792,7 @@ const opListSchemaExtensions = "ListSchemaExtensions" // ListSchemaExtensionsRequest generates a "aws/request.Request" representing the // client's request for the ListSchemaExtensions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2880,7 +2880,7 @@ const opListTagsForResource = "ListTagsForResource" // ListTagsForResourceRequest generates a "aws/request.Request" representing the // client's request for the ListTagsForResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2971,7 +2971,7 @@ const opRegisterEventTopic = "RegisterEventTopic" // RegisterEventTopicRequest generates a "aws/request.Request" representing the // client's request for the RegisterEventTopic operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3064,7 +3064,7 @@ const opRemoveIpRoutes = "RemoveIpRoutes" // RemoveIpRoutesRequest generates a "aws/request.Request" representing the // client's request for the RemoveIpRoutes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3155,7 +3155,7 @@ const opRemoveTagsFromResource = "RemoveTagsFromResource" // RemoveTagsFromResourceRequest generates a "aws/request.Request" representing the // client's request for the RemoveTagsFromResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3243,7 +3243,7 @@ const opRestoreFromSnapshot = "RestoreFromSnapshot" // RestoreFromSnapshotRequest generates a "aws/request.Request" representing the // client's request for the RestoreFromSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3339,7 +3339,7 @@ const opStartSchemaExtension = "StartSchemaExtension" // StartSchemaExtensionRequest generates a "aws/request.Request" representing the // client's request for the StartSchemaExtension operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3435,7 +3435,7 @@ const opUpdateConditionalForwarder = "UpdateConditionalForwarder" // UpdateConditionalForwarderRequest generates a "aws/request.Request" representing the // client's request for the UpdateConditionalForwarder operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3529,7 +3529,7 @@ const opUpdateNumberOfDomainControllers = "UpdateNumberOfDomainControllers" // UpdateNumberOfDomainControllersRequest generates a "aws/request.Request" representing the // client's request for the UpdateNumberOfDomainControllers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3632,7 +3632,7 @@ const opUpdateRadius = "UpdateRadius" // UpdateRadiusRequest generates a "aws/request.Request" representing the // client's request for the UpdateRadius operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3721,7 +3721,7 @@ const opVerifyTrust = "VerifyTrust" // VerifyTrustRequest generates a "aws/request.Request" representing the // client's request for the VerifyTrust operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/dynamodb/api.go b/vendor/github.com/aws/aws-sdk-go/service/dynamodb/api.go index 43abb412355a..fb9dc14927a6 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/dynamodb/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/dynamodb/api.go @@ -17,7 +17,7 @@ const opBatchGetItem = "BatchGetItem" // BatchGetItemRequest generates a "aws/request.Request" representing the // client's request for the BatchGetItem operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -212,7 +212,7 @@ const opBatchWriteItem = "BatchWriteItem" // BatchWriteItemRequest generates a "aws/request.Request" representing the // client's request for the BatchWriteItem operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -316,6 +316,9 @@ func (c *DynamoDB) BatchWriteItemRequest(input *BatchWriteItemInput) (req *reque // BatchWriteItem request. For example, you cannot put and delete the same // item in the same BatchWriteItem request. // +// * Your request contains at least two items with identical hash and range +// keys (which essentially is two put operations). +// // * There are more than 25 requests in the batch. // // * Any individual item in a batch exceeds 400 KB. @@ -375,7 +378,7 @@ const opCreateBackup = "CreateBackup" // CreateBackupRequest generates a "aws/request.Request" representing the // client's request for the CreateBackup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -455,11 +458,11 @@ func (c *DynamoDB) CreateBackupRequest(input *CreateBackupInput) (req *request.R // // Returned Error Codes: // * ErrCodeTableNotFoundException "TableNotFoundException" -// A table with the name TableName does not currently exist within the subscriber's -// account. +// A source table with the name TableName does not currently exist within the +// subscriber's account. // // * ErrCodeTableInUseException "TableInUseException" -// A table by that name is either being created or deleted. +// A target table with the specified name is either being created or deleted. // // * ErrCodeContinuousBackupsUnavailableException "ContinuousBackupsUnavailableException" // Backups have not yet been enabled for this table. @@ -473,13 +476,8 @@ func (c *DynamoDB) CreateBackupRequest(input *CreateBackupInput) (req *request.R // is no limit to the number of daily on-demand backups that can be taken. // // Up to 10 simultaneous table operations are allowed per account. These operations -// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, and RestoreTableFromBackup. -// -// For tables with secondary indexes, only one of those tables can be in the -// CREATING state at any point in time. Do not attempt to create more than one -// such table simultaneously. -// -// The total limit of tables in the ACTIVE state is 250. +// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, RestoreTableFromBackup, +// and RestoreTableToPointInTime. // // For tables with secondary indexes, only one of those tables can be in the // CREATING state at any point in time. Do not attempt to create more than one @@ -516,7 +514,7 @@ const opCreateGlobalTable = "CreateGlobalTable" // CreateGlobalTableRequest generates a "aws/request.Request" representing the // client's request for the CreateGlobalTable operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -584,13 +582,8 @@ func (c *DynamoDB) CreateGlobalTableRequest(input *CreateGlobalTableInput) (req // is no limit to the number of daily on-demand backups that can be taken. // // Up to 10 simultaneous table operations are allowed per account. These operations -// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, and RestoreTableFromBackup. -// -// For tables with secondary indexes, only one of those tables can be in the -// CREATING state at any point in time. Do not attempt to create more than one -// such table simultaneously. -// -// The total limit of tables in the ACTIVE state is 250. +// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, RestoreTableFromBackup, +// and RestoreTableToPointInTime. // // For tables with secondary indexes, only one of those tables can be in the // CREATING state at any point in time. Do not attempt to create more than one @@ -605,8 +598,8 @@ func (c *DynamoDB) CreateGlobalTableRequest(input *CreateGlobalTableInput) (req // The specified global table already exists. // // * ErrCodeTableNotFoundException "TableNotFoundException" -// A table with the name TableName does not currently exist within the subscriber's -// account. +// A source table with the name TableName does not currently exist within the +// subscriber's account. // // See also, https://docs.aws.amazon.com/goto/WebAPI/dynamodb-2012-08-10/CreateGlobalTable func (c *DynamoDB) CreateGlobalTable(input *CreateGlobalTableInput) (*CreateGlobalTableOutput, error) { @@ -634,7 +627,7 @@ const opCreateTable = "CreateTable" // CreateTableRequest generates a "aws/request.Request" representing the // client's request for the CreateTable operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -708,13 +701,8 @@ func (c *DynamoDB) CreateTableRequest(input *CreateTableInput) (req *request.Req // is no limit to the number of daily on-demand backups that can be taken. // // Up to 10 simultaneous table operations are allowed per account. These operations -// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, and RestoreTableFromBackup. -// -// For tables with secondary indexes, only one of those tables can be in the -// CREATING state at any point in time. Do not attempt to create more than one -// such table simultaneously. -// -// The total limit of tables in the ACTIVE state is 250. +// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, RestoreTableFromBackup, +// and RestoreTableToPointInTime. // // For tables with secondary indexes, only one of those tables can be in the // CREATING state at any point in time. Do not attempt to create more than one @@ -751,7 +739,7 @@ const opDeleteBackup = "DeleteBackup" // DeleteBackupRequest generates a "aws/request.Request" representing the // client's request for the DeleteBackup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -815,13 +803,8 @@ func (c *DynamoDB) DeleteBackupRequest(input *DeleteBackupInput) (req *request.R // is no limit to the number of daily on-demand backups that can be taken. // // Up to 10 simultaneous table operations are allowed per account. These operations -// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, and RestoreTableFromBackup. -// -// For tables with secondary indexes, only one of those tables can be in the -// CREATING state at any point in time. Do not attempt to create more than one -// such table simultaneously. -// -// The total limit of tables in the ACTIVE state is 250. +// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, RestoreTableFromBackup, +// and RestoreTableToPointInTime. // // For tables with secondary indexes, only one of those tables can be in the // CREATING state at any point in time. Do not attempt to create more than one @@ -858,7 +841,7 @@ const opDeleteItem = "DeleteItem" // DeleteItemRequest generates a "aws/request.Request" representing the // client's request for the DeleteItem operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -969,7 +952,7 @@ const opDeleteTable = "DeleteTable" // DeleteTableRequest generates a "aws/request.Request" representing the // client's request for the DeleteTable operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1050,13 +1033,8 @@ func (c *DynamoDB) DeleteTableRequest(input *DeleteTableInput) (req *request.Req // is no limit to the number of daily on-demand backups that can be taken. // // Up to 10 simultaneous table operations are allowed per account. These operations -// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, and RestoreTableFromBackup. -// -// For tables with secondary indexes, only one of those tables can be in the -// CREATING state at any point in time. Do not attempt to create more than one -// such table simultaneously. -// -// The total limit of tables in the ACTIVE state is 250. +// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, RestoreTableFromBackup, +// and RestoreTableToPointInTime. // // For tables with secondary indexes, only one of those tables can be in the // CREATING state at any point in time. Do not attempt to create more than one @@ -1093,7 +1071,7 @@ const opDescribeBackup = "DescribeBackup" // DescribeBackupRequest generates a "aws/request.Request" representing the // client's request for the DescribeBackup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1177,7 +1155,7 @@ const opDescribeContinuousBackups = "DescribeContinuousBackups" // DescribeContinuousBackupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeContinuousBackups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1217,8 +1195,17 @@ func (c *DynamoDB) DescribeContinuousBackupsRequest(input *DescribeContinuousBac // DescribeContinuousBackups API operation for Amazon DynamoDB. // -// Checks the status of the backup restore settings on the specified table. -// If backups are enabled, ContinuousBackupsStatus will bet set to ENABLED. +// Checks the status of continuous backups and point in time recovery on the +// specified table. Continuous backups are ENABLED on all tables at table creation. +// If point in time recovery is enabled, PointInTimeRecoveryStatus will be set +// to ENABLED. +// +// Once continuous backups and point in time recovery are enabled, you can restore +// to any point in time within EarliestRestorableDateTime and LatestRestorableDateTime. +// +// LatestRestorableDateTime is typically 5 minutes before the current time. +// You can restore your table to any point in time during the last 35 days with +// a 1-minute granularity. // // You can call DescribeContinuousBackups at a maximum rate of 10 times per // second. @@ -1232,8 +1219,8 @@ func (c *DynamoDB) DescribeContinuousBackupsRequest(input *DescribeContinuousBac // // Returned Error Codes: // * ErrCodeTableNotFoundException "TableNotFoundException" -// A table with the name TableName does not currently exist within the subscriber's -// account. +// A source table with the name TableName does not currently exist within the +// subscriber's account. // // * ErrCodeInternalServerError "InternalServerError" // An error occurred on the server side. @@ -1264,7 +1251,7 @@ const opDescribeGlobalTable = "DescribeGlobalTable" // DescribeGlobalTableRequest generates a "aws/request.Request" representing the // client's request for the DescribeGlobalTable operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1346,7 +1333,7 @@ const opDescribeLimits = "DescribeLimits" // DescribeLimitsRequest generates a "aws/request.Request" representing the // client's request for the DescribeLimits operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1481,7 +1468,7 @@ const opDescribeTable = "DescribeTable" // DescribeTableRequest generates a "aws/request.Request" representing the // client's request for the DescribeTable operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1572,7 +1559,7 @@ const opDescribeTimeToLive = "DescribeTimeToLive" // DescribeTimeToLiveRequest generates a "aws/request.Request" representing the // client's request for the DescribeTimeToLive operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1655,7 +1642,7 @@ const opGetItem = "GetItem" // GetItemRequest generates a "aws/request.Request" representing the // client's request for the GetItem operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1753,7 +1740,7 @@ const opListBackups = "ListBackups" // ListBackupsRequest generates a "aws/request.Request" representing the // client's request for the ListBackups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1840,7 +1827,7 @@ const opListGlobalTables = "ListGlobalTables" // ListGlobalTablesRequest generates a "aws/request.Request" representing the // client's request for the ListGlobalTables operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1919,7 +1906,7 @@ const opListTables = "ListTables" // ListTablesRequest generates a "aws/request.Request" representing the // client's request for the ListTables operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2056,7 +2043,7 @@ const opListTagsOfResource = "ListTagsOfResource" // ListTagsOfResourceRequest generates a "aws/request.Request" representing the // client's request for the ListTagsOfResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2143,7 +2130,7 @@ const opPutItem = "PutItem" // PutItemRequest generates a "aws/request.Request" representing the // client's request for the PutItem operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2284,7 +2271,7 @@ const opQuery = "Query" // QueryRequest generates a "aws/request.Request" representing the // client's request for the Query operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2478,7 +2465,7 @@ const opRestoreTableFromBackup = "RestoreTableFromBackup" // RestoreTableFromBackupRequest generates a "aws/request.Request" representing the // client's request for the RestoreTableFromBackup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2519,7 +2506,7 @@ func (c *DynamoDB) RestoreTableFromBackupRequest(input *RestoreTableFromBackupIn // RestoreTableFromBackup API operation for Amazon DynamoDB. // // Creates a new table from an existing backup. Any number of users can execute -// up to 10 concurrent restores in a given account. +// up to 4 concurrent restores (any type of restore) in a given account. // // You can call RestoreTableFromBackup at a maximum rate of 10 times per second. // @@ -2546,10 +2533,10 @@ func (c *DynamoDB) RestoreTableFromBackupRequest(input *RestoreTableFromBackupIn // // Returned Error Codes: // * ErrCodeTableAlreadyExistsException "TableAlreadyExistsException" -// A table with the name already exists. +// A target table with the specified name already exists. // // * ErrCodeTableInUseException "TableInUseException" -// A table by that name is either being created or deleted. +// A target table with the specified name is either being created or deleted. // // * ErrCodeBackupNotFoundException "BackupNotFoundException" // Backup not found for the given BackupARN. @@ -2563,13 +2550,8 @@ func (c *DynamoDB) RestoreTableFromBackupRequest(input *RestoreTableFromBackupIn // is no limit to the number of daily on-demand backups that can be taken. // // Up to 10 simultaneous table operations are allowed per account. These operations -// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, and RestoreTableFromBackup. -// -// For tables with secondary indexes, only one of those tables can be in the -// CREATING state at any point in time. Do not attempt to create more than one -// such table simultaneously. -// -// The total limit of tables in the ACTIVE state is 250. +// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, RestoreTableFromBackup, +// and RestoreTableToPointInTime. // // For tables with secondary indexes, only one of those tables can be in the // CREATING state at any point in time. Do not attempt to create more than one @@ -2602,11 +2584,141 @@ func (c *DynamoDB) RestoreTableFromBackupWithContext(ctx aws.Context, input *Res return out, req.Send() } +const opRestoreTableToPointInTime = "RestoreTableToPointInTime" + +// RestoreTableToPointInTimeRequest generates a "aws/request.Request" representing the +// client's request for the RestoreTableToPointInTime operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See RestoreTableToPointInTime for more information on using the RestoreTableToPointInTime +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the RestoreTableToPointInTimeRequest method. +// req, resp := client.RestoreTableToPointInTimeRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/dynamodb-2012-08-10/RestoreTableToPointInTime +func (c *DynamoDB) RestoreTableToPointInTimeRequest(input *RestoreTableToPointInTimeInput) (req *request.Request, output *RestoreTableToPointInTimeOutput) { + op := &request.Operation{ + Name: opRestoreTableToPointInTime, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &RestoreTableToPointInTimeInput{} + } + + output = &RestoreTableToPointInTimeOutput{} + req = c.newRequest(op, input, output) + return +} + +// RestoreTableToPointInTime API operation for Amazon DynamoDB. +// +// Restores the specified table to the specified point in time within EarliestRestorableDateTime +// and LatestRestorableDateTime. You can restore your table to any point in +// time during the last 35 days with a 1-minute granularity. Any number of users +// can execute up to 4 concurrent restores (any type of restore) in a given +// account. +// +// You must manually set up the following on the restored table: +// +// * Auto scaling policies +// +// * IAM policies +// +// * Cloudwatch metrics and alarms +// +// * Tags +// +// * Stream settings +// +// * Time to Live (TTL) settings +// +// * Point in time recovery settings +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon DynamoDB's +// API operation RestoreTableToPointInTime for usage and error information. +// +// Returned Error Codes: +// * ErrCodeTableAlreadyExistsException "TableAlreadyExistsException" +// A target table with the specified name already exists. +// +// * ErrCodeTableNotFoundException "TableNotFoundException" +// A source table with the name TableName does not currently exist within the +// subscriber's account. +// +// * ErrCodeTableInUseException "TableInUseException" +// A target table with the specified name is either being created or deleted. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// Up to 50 CreateBackup operations are allowed per second, per account. There +// is no limit to the number of daily on-demand backups that can be taken. +// +// Up to 10 simultaneous table operations are allowed per account. These operations +// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, RestoreTableFromBackup, +// and RestoreTableToPointInTime. +// +// For tables with secondary indexes, only one of those tables can be in the +// CREATING state at any point in time. Do not attempt to create more than one +// such table simultaneously. +// +// The total limit of tables in the ACTIVE state is 250. +// +// * ErrCodeInvalidRestoreTimeException "InvalidRestoreTimeException" +// An invalid restore time was specified. RestoreDateTime must be between EarliestRestorableDateTime +// and LatestRestorableDateTime. +// +// * ErrCodePointInTimeRecoveryUnavailableException "PointInTimeRecoveryUnavailableException" +// Point in time recovery has not yet been enabled for this source table. +// +// * ErrCodeInternalServerError "InternalServerError" +// An error occurred on the server side. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/dynamodb-2012-08-10/RestoreTableToPointInTime +func (c *DynamoDB) RestoreTableToPointInTime(input *RestoreTableToPointInTimeInput) (*RestoreTableToPointInTimeOutput, error) { + req, out := c.RestoreTableToPointInTimeRequest(input) + return out, req.Send() +} + +// RestoreTableToPointInTimeWithContext is the same as RestoreTableToPointInTime with the addition of +// the ability to pass a context and additional request options. +// +// See RestoreTableToPointInTime for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *DynamoDB) RestoreTableToPointInTimeWithContext(ctx aws.Context, input *RestoreTableToPointInTimeInput, opts ...request.Option) (*RestoreTableToPointInTimeOutput, error) { + req, out := c.RestoreTableToPointInTimeRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opScan = "Scan" // ScanRequest generates a "aws/request.Request" representing the // client's request for the Scan operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2780,7 +2892,7 @@ const opTagResource = "TagResource" // TagResourceRequest generates a "aws/request.Request" representing the // client's request for the TagResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2843,13 +2955,8 @@ func (c *DynamoDB) TagResourceRequest(input *TagResourceInput) (req *request.Req // is no limit to the number of daily on-demand backups that can be taken. // // Up to 10 simultaneous table operations are allowed per account. These operations -// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, and RestoreTableFromBackup. -// -// For tables with secondary indexes, only one of those tables can be in the -// CREATING state at any point in time. Do not attempt to create more than one -// such table simultaneously. -// -// The total limit of tables in the ACTIVE state is 250. +// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, RestoreTableFromBackup, +// and RestoreTableToPointInTime. // // For tables with secondary indexes, only one of those tables can be in the // CREATING state at any point in time. Do not attempt to create more than one @@ -2895,7 +3002,7 @@ const opUntagResource = "UntagResource" // UntagResourceRequest generates a "aws/request.Request" representing the // client's request for the UntagResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2956,13 +3063,8 @@ func (c *DynamoDB) UntagResourceRequest(input *UntagResourceInput) (req *request // is no limit to the number of daily on-demand backups that can be taken. // // Up to 10 simultaneous table operations are allowed per account. These operations -// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, and RestoreTableFromBackup. -// -// For tables with secondary indexes, only one of those tables can be in the -// CREATING state at any point in time. Do not attempt to create more than one -// such table simultaneously. -// -// The total limit of tables in the ACTIVE state is 250. +// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, RestoreTableFromBackup, +// and RestoreTableToPointInTime. // // For tables with secondary indexes, only one of those tables can be in the // CREATING state at any point in time. Do not attempt to create more than one @@ -3004,11 +3106,108 @@ func (c *DynamoDB) UntagResourceWithContext(ctx aws.Context, input *UntagResourc return out, req.Send() } +const opUpdateContinuousBackups = "UpdateContinuousBackups" + +// UpdateContinuousBackupsRequest generates a "aws/request.Request" representing the +// client's request for the UpdateContinuousBackups operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateContinuousBackups for more information on using the UpdateContinuousBackups +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the UpdateContinuousBackupsRequest method. +// req, resp := client.UpdateContinuousBackupsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/dynamodb-2012-08-10/UpdateContinuousBackups +func (c *DynamoDB) UpdateContinuousBackupsRequest(input *UpdateContinuousBackupsInput) (req *request.Request, output *UpdateContinuousBackupsOutput) { + op := &request.Operation{ + Name: opUpdateContinuousBackups, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &UpdateContinuousBackupsInput{} + } + + output = &UpdateContinuousBackupsOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateContinuousBackups API operation for Amazon DynamoDB. +// +// UpdateContinuousBackups enables or disables point in time recovery for the +// specified table. A successful UpdateContinuousBackups call returns the current +// ContinuousBackupsDescription. Continuous backups are ENABLED on all tables +// at table creation. If point in time recovery is enabled, PointInTimeRecoveryStatus +// will be set to ENABLED. +// +// Once continuous backups and point in time recovery are enabled, you can restore +// to any point in time within EarliestRestorableDateTime and LatestRestorableDateTime. +// +// LatestRestorableDateTime is typically 5 minutes before the current time. +// You can restore your table to any point in time during the last 35 days with +// a 1-minute granularity. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon DynamoDB's +// API operation UpdateContinuousBackups for usage and error information. +// +// Returned Error Codes: +// * ErrCodeTableNotFoundException "TableNotFoundException" +// A source table with the name TableName does not currently exist within the +// subscriber's account. +// +// * ErrCodeContinuousBackupsUnavailableException "ContinuousBackupsUnavailableException" +// Backups have not yet been enabled for this table. +// +// * ErrCodeInternalServerError "InternalServerError" +// An error occurred on the server side. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/dynamodb-2012-08-10/UpdateContinuousBackups +func (c *DynamoDB) UpdateContinuousBackups(input *UpdateContinuousBackupsInput) (*UpdateContinuousBackupsOutput, error) { + req, out := c.UpdateContinuousBackupsRequest(input) + return out, req.Send() +} + +// UpdateContinuousBackupsWithContext is the same as UpdateContinuousBackups with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateContinuousBackups for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *DynamoDB) UpdateContinuousBackupsWithContext(ctx aws.Context, input *UpdateContinuousBackupsInput, opts ...request.Option) (*UpdateContinuousBackupsOutput, error) { + req, out := c.UpdateContinuousBackupsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opUpdateGlobalTable = "UpdateGlobalTable" // UpdateGlobalTableRequest generates a "aws/request.Request" representing the // client's request for the UpdateGlobalTable operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3051,8 +3250,7 @@ func (c *DynamoDB) UpdateGlobalTableRequest(input *UpdateGlobalTableInput) (req // Adds or removes replicas in the specified global table. The global table // must already exist to be able to use this operation. Any replica to be added // must be empty, must have the same name as the global table, must have the -// same key schema, must have DynamoDB Streams enabled, and cannot have any -// local secondary indexes (LSIs). +// same key schema, and must have DynamoDB Streams enabled. // // Although you can use UpdateGlobalTable to add replicas and remove replicas // in a single request, for simplicity we recommend that you issue separate @@ -3079,8 +3277,8 @@ func (c *DynamoDB) UpdateGlobalTableRequest(input *UpdateGlobalTableInput) (req // The specified replica is no longer part of the global table. // // * ErrCodeTableNotFoundException "TableNotFoundException" -// A table with the name TableName does not currently exist within the subscriber's -// account. +// A source table with the name TableName does not currently exist within the +// subscriber's account. // // See also, https://docs.aws.amazon.com/goto/WebAPI/dynamodb-2012-08-10/UpdateGlobalTable func (c *DynamoDB) UpdateGlobalTable(input *UpdateGlobalTableInput) (*UpdateGlobalTableOutput, error) { @@ -3108,7 +3306,7 @@ const opUpdateItem = "UpdateItem" // UpdateItemRequest generates a "aws/request.Request" representing the // client's request for the UpdateItem operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3213,7 +3411,7 @@ const opUpdateTable = "UpdateTable" // UpdateTableRequest generates a "aws/request.Request" representing the // client's request for the UpdateTable operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3294,13 +3492,8 @@ func (c *DynamoDB) UpdateTableRequest(input *UpdateTableInput) (req *request.Req // is no limit to the number of daily on-demand backups that can be taken. // // Up to 10 simultaneous table operations are allowed per account. These operations -// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, and RestoreTableFromBackup. -// -// For tables with secondary indexes, only one of those tables can be in the -// CREATING state at any point in time. Do not attempt to create more than one -// such table simultaneously. -// -// The total limit of tables in the ACTIVE state is 250. +// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, RestoreTableFromBackup, +// and RestoreTableToPointInTime. // // For tables with secondary indexes, only one of those tables can be in the // CREATING state at any point in time. Do not attempt to create more than one @@ -3337,7 +3530,7 @@ const opUpdateTimeToLive = "UpdateTimeToLive" // UpdateTimeToLiveRequest generates a "aws/request.Request" representing the // client's request for the UpdateTimeToLive operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3428,13 +3621,8 @@ func (c *DynamoDB) UpdateTimeToLiveRequest(input *UpdateTimeToLiveInput) (req *r // is no limit to the number of daily on-demand backups that can be taken. // // Up to 10 simultaneous table operations are allowed per account. These operations -// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, and RestoreTableFromBackup. -// -// For tables with secondary indexes, only one of those tables can be in the -// CREATING state at any point in time. Do not attempt to create more than one -// such table simultaneously. -// -// The total limit of tables in the ACTIVE state is 250. +// include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, RestoreTableFromBackup, +// and RestoreTableToPointInTime. // // For tables with secondary indexes, only one of those tables can be in the // CREATING state at any point in time. Do not attempt to create more than one @@ -4584,8 +4772,8 @@ func (s *ConsumedCapacity) SetTableName(v string) *ConsumedCapacity { return s } -// Represents the backup and restore settings on the table when the backup was -// created. +// Represents the continuous backups and point in time recovery settings on +// the table. type ContinuousBackupsDescription struct { _ struct{} `type:"structure"` @@ -4593,6 +4781,9 @@ type ContinuousBackupsDescription struct { // // ContinuousBackupsStatus is a required field ContinuousBackupsStatus *string `type:"string" required:"true" enum:"ContinuousBackupsStatus"` + + // The description of the point in time recovery settings applied to the table. + PointInTimeRecoveryDescription *PointInTimeRecoveryDescription `type:"structure"` } // String returns the string representation @@ -4611,6 +4802,12 @@ func (s *ContinuousBackupsDescription) SetContinuousBackupsStatus(v string) *Con return s } +// SetPointInTimeRecoveryDescription sets the PointInTimeRecoveryDescription field's value. +func (s *ContinuousBackupsDescription) SetPointInTimeRecoveryDescription(v *PointInTimeRecoveryDescription) *ContinuousBackupsDescription { + s.PointInTimeRecoveryDescription = v + return s +} + type CreateBackupInput struct { _ struct{} `type:"structure"` @@ -5842,8 +6039,8 @@ func (s *DescribeBackupOutput) SetBackupDescription(v *BackupDescription) *Descr type DescribeContinuousBackupsInput struct { _ struct{} `type:"structure"` - // Name of the table for which the customer wants to check the backup and restore - // settings. + // Name of the table for which the customer wants to check the continuous backups + // and point in time recovery settings. // // TableName is a required field TableName *string `min:"3" type:"string" required:"true"` @@ -7943,6 +8140,97 @@ func (s *LocalSecondaryIndexInfo) SetProjection(v *Projection) *LocalSecondaryIn return s } +// The description of the point in time settings applied to the table. +type PointInTimeRecoveryDescription struct { + _ struct{} `type:"structure"` + + // Specifies the earliest point in time you can restore your table to. It is + // equal to the maximum of point in time recovery enabled time and CurrentTime + // - PointInTimeRecoveryPeriod. + EarliestRestorableDateTime *time.Time `type:"timestamp" timestampFormat:"unix"` + + // LatestRestorableDateTime is 5 minutes from now and there is a +/- 1 minute + // fuzziness on the restore times. + LatestRestorableDateTime *time.Time `type:"timestamp" timestampFormat:"unix"` + + // The current state of point in time recovery: + // + // * ENABLING - Point in time recovery is being enabled. + // + // * ENABLED - Point in time recovery is enabled. + // + // * DISABLED - Point in time recovery is disabled. + PointInTimeRecoveryStatus *string `type:"string" enum:"PointInTimeRecoveryStatus"` +} + +// String returns the string representation +func (s PointInTimeRecoveryDescription) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PointInTimeRecoveryDescription) GoString() string { + return s.String() +} + +// SetEarliestRestorableDateTime sets the EarliestRestorableDateTime field's value. +func (s *PointInTimeRecoveryDescription) SetEarliestRestorableDateTime(v time.Time) *PointInTimeRecoveryDescription { + s.EarliestRestorableDateTime = &v + return s +} + +// SetLatestRestorableDateTime sets the LatestRestorableDateTime field's value. +func (s *PointInTimeRecoveryDescription) SetLatestRestorableDateTime(v time.Time) *PointInTimeRecoveryDescription { + s.LatestRestorableDateTime = &v + return s +} + +// SetPointInTimeRecoveryStatus sets the PointInTimeRecoveryStatus field's value. +func (s *PointInTimeRecoveryDescription) SetPointInTimeRecoveryStatus(v string) *PointInTimeRecoveryDescription { + s.PointInTimeRecoveryStatus = &v + return s +} + +// Represents the settings used to enable point in time recovery. +type PointInTimeRecoverySpecification struct { + _ struct{} `type:"structure"` + + // Indicates whether point in time recovery is enabled (true) or disabled (false) + // on the table. + // + // PointInTimeRecoveryEnabled is a required field + PointInTimeRecoveryEnabled *bool `type:"boolean" required:"true"` +} + +// String returns the string representation +func (s PointInTimeRecoverySpecification) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PointInTimeRecoverySpecification) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *PointInTimeRecoverySpecification) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PointInTimeRecoverySpecification"} + if s.PointInTimeRecoveryEnabled == nil { + invalidParams.Add(request.NewErrParamRequired("PointInTimeRecoveryEnabled")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetPointInTimeRecoveryEnabled sets the PointInTimeRecoveryEnabled field's value. +func (s *PointInTimeRecoverySpecification) SetPointInTimeRecoveryEnabled(v bool) *PointInTimeRecoverySpecification { + s.PointInTimeRecoveryEnabled = &v + return s +} + // Represents attributes that are copied (projected) from the table into an // index. These are in addition to the primary key attributes and index key // attributes, which are automatically projected. @@ -8717,9 +9005,8 @@ type QueryInput struct { // // Items with the same partition key value are stored in sorted order by sort // key. If the sort key data type is Number, the results are stored in numeric - // order. For type String, the results are stored in order of ASCII character - // code values. For type Binary, DynamoDB treats each byte of the binary data - // as unsigned. + // order. For type String, the results are stored in order of UTF-8 bytes. For + // type Binary, DynamoDB treats each byte of the binary data as unsigned. // // If ScanIndexForward is true, DynamoDB returns the results in the order in // which they are stored (by sort key value). This is the default behavior. @@ -9267,6 +9554,106 @@ func (s *RestoreTableFromBackupOutput) SetTableDescription(v *TableDescription) return s } +type RestoreTableToPointInTimeInput struct { + _ struct{} `type:"structure"` + + // Time in the past to restore the table to. + RestoreDateTime *time.Time `type:"timestamp" timestampFormat:"unix"` + + // Name of the source table that is being restored. + // + // SourceTableName is a required field + SourceTableName *string `min:"3" type:"string" required:"true"` + + // The name of the new table to which it must be restored to. + // + // TargetTableName is a required field + TargetTableName *string `min:"3" type:"string" required:"true"` + + // Restore the table to the latest possible time. LatestRestorableDateTime is + // typically 5 minutes before the current time. + UseLatestRestorableTime *bool `type:"boolean"` +} + +// String returns the string representation +func (s RestoreTableToPointInTimeInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s RestoreTableToPointInTimeInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *RestoreTableToPointInTimeInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "RestoreTableToPointInTimeInput"} + if s.SourceTableName == nil { + invalidParams.Add(request.NewErrParamRequired("SourceTableName")) + } + if s.SourceTableName != nil && len(*s.SourceTableName) < 3 { + invalidParams.Add(request.NewErrParamMinLen("SourceTableName", 3)) + } + if s.TargetTableName == nil { + invalidParams.Add(request.NewErrParamRequired("TargetTableName")) + } + if s.TargetTableName != nil && len(*s.TargetTableName) < 3 { + invalidParams.Add(request.NewErrParamMinLen("TargetTableName", 3)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetRestoreDateTime sets the RestoreDateTime field's value. +func (s *RestoreTableToPointInTimeInput) SetRestoreDateTime(v time.Time) *RestoreTableToPointInTimeInput { + s.RestoreDateTime = &v + return s +} + +// SetSourceTableName sets the SourceTableName field's value. +func (s *RestoreTableToPointInTimeInput) SetSourceTableName(v string) *RestoreTableToPointInTimeInput { + s.SourceTableName = &v + return s +} + +// SetTargetTableName sets the TargetTableName field's value. +func (s *RestoreTableToPointInTimeInput) SetTargetTableName(v string) *RestoreTableToPointInTimeInput { + s.TargetTableName = &v + return s +} + +// SetUseLatestRestorableTime sets the UseLatestRestorableTime field's value. +func (s *RestoreTableToPointInTimeInput) SetUseLatestRestorableTime(v bool) *RestoreTableToPointInTimeInput { + s.UseLatestRestorableTime = &v + return s +} + +type RestoreTableToPointInTimeOutput struct { + _ struct{} `type:"structure"` + + // Represents the properties of a table. + TableDescription *TableDescription `type:"structure"` +} + +// String returns the string representation +func (s RestoreTableToPointInTimeOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s RestoreTableToPointInTimeOutput) GoString() string { + return s.String() +} + +// SetTableDescription sets the TableDescription field's value. +func (s *RestoreTableToPointInTimeOutput) SetTableDescription(v *TableDescription) *RestoreTableToPointInTimeOutput { + s.TableDescription = v + return s +} + // The description of the server-side encryption status on the specified table. type SSEDescription struct { _ struct{} `type:"structure"` @@ -10656,6 +11043,90 @@ func (s UntagResourceOutput) GoString() string { return s.String() } +type UpdateContinuousBackupsInput struct { + _ struct{} `type:"structure"` + + // Represents the settings used to enable point in time recovery. + // + // PointInTimeRecoverySpecification is a required field + PointInTimeRecoverySpecification *PointInTimeRecoverySpecification `type:"structure" required:"true"` + + // The name of the table. + // + // TableName is a required field + TableName *string `min:"3" type:"string" required:"true"` +} + +// String returns the string representation +func (s UpdateContinuousBackupsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateContinuousBackupsInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *UpdateContinuousBackupsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateContinuousBackupsInput"} + if s.PointInTimeRecoverySpecification == nil { + invalidParams.Add(request.NewErrParamRequired("PointInTimeRecoverySpecification")) + } + if s.TableName == nil { + invalidParams.Add(request.NewErrParamRequired("TableName")) + } + if s.TableName != nil && len(*s.TableName) < 3 { + invalidParams.Add(request.NewErrParamMinLen("TableName", 3)) + } + if s.PointInTimeRecoverySpecification != nil { + if err := s.PointInTimeRecoverySpecification.Validate(); err != nil { + invalidParams.AddNested("PointInTimeRecoverySpecification", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetPointInTimeRecoverySpecification sets the PointInTimeRecoverySpecification field's value. +func (s *UpdateContinuousBackupsInput) SetPointInTimeRecoverySpecification(v *PointInTimeRecoverySpecification) *UpdateContinuousBackupsInput { + s.PointInTimeRecoverySpecification = v + return s +} + +// SetTableName sets the TableName field's value. +func (s *UpdateContinuousBackupsInput) SetTableName(v string) *UpdateContinuousBackupsInput { + s.TableName = &v + return s +} + +type UpdateContinuousBackupsOutput struct { + _ struct{} `type:"structure"` + + // Represents the continuous backups and point in time recovery settings on + // the table. + ContinuousBackupsDescription *ContinuousBackupsDescription `type:"structure"` +} + +// String returns the string representation +func (s UpdateContinuousBackupsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateContinuousBackupsOutput) GoString() string { + return s.String() +} + +// SetContinuousBackupsDescription sets the ContinuousBackupsDescription field's value. +func (s *UpdateContinuousBackupsOutput) SetContinuousBackupsDescription(v *ContinuousBackupsDescription) *UpdateContinuousBackupsOutput { + s.ContinuousBackupsDescription = v + return s +} + // Represents the new provisioned throughput settings to be applied to a global // secondary index. type UpdateGlobalSecondaryIndexAction struct { @@ -11597,6 +12068,14 @@ const ( KeyTypeRange = "RANGE" ) +const ( + // PointInTimeRecoveryStatusEnabled is a PointInTimeRecoveryStatus enum value + PointInTimeRecoveryStatusEnabled = "ENABLED" + + // PointInTimeRecoveryStatusDisabled is a PointInTimeRecoveryStatus enum value + PointInTimeRecoveryStatusDisabled = "DISABLED" +) + const ( // ProjectionTypeAll is a ProjectionType enum value ProjectionTypeAll = "ALL" diff --git a/vendor/github.com/aws/aws-sdk-go/service/dynamodb/errors.go b/vendor/github.com/aws/aws-sdk-go/service/dynamodb/errors.go index 4f898d967371..05b8470d2eed 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/dynamodb/errors.go +++ b/vendor/github.com/aws/aws-sdk-go/service/dynamodb/errors.go @@ -47,6 +47,13 @@ const ( // An error occurred on the server side. ErrCodeInternalServerError = "InternalServerError" + // ErrCodeInvalidRestoreTimeException for service response error code + // "InvalidRestoreTimeException". + // + // An invalid restore time was specified. RestoreDateTime must be between EarliestRestorableDateTime + // and LatestRestorableDateTime. + ErrCodeInvalidRestoreTimeException = "InvalidRestoreTimeException" + // ErrCodeItemCollectionSizeLimitExceededException for service response error code // "ItemCollectionSizeLimitExceededException". // @@ -61,13 +68,8 @@ const ( // is no limit to the number of daily on-demand backups that can be taken. // // Up to 10 simultaneous table operations are allowed per account. These operations - // include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, and RestoreTableFromBackup. - // - // For tables with secondary indexes, only one of those tables can be in the - // CREATING state at any point in time. Do not attempt to create more than one - // such table simultaneously. - // - // The total limit of tables in the ACTIVE state is 250. + // include CreateTable, UpdateTable, DeleteTable,UpdateTimeToLive, RestoreTableFromBackup, + // and RestoreTableToPointInTime. // // For tables with secondary indexes, only one of those tables can be in the // CREATING state at any point in time. Do not attempt to create more than one @@ -76,6 +78,12 @@ const ( // The total limit of tables in the ACTIVE state is 250. ErrCodeLimitExceededException = "LimitExceededException" + // ErrCodePointInTimeRecoveryUnavailableException for service response error code + // "PointInTimeRecoveryUnavailableException". + // + // Point in time recovery has not yet been enabled for this source table. + ErrCodePointInTimeRecoveryUnavailableException = "PointInTimeRecoveryUnavailableException" + // ErrCodeProvisionedThroughputExceededException for service response error code // "ProvisionedThroughputExceededException". // @@ -117,19 +125,19 @@ const ( // ErrCodeTableAlreadyExistsException for service response error code // "TableAlreadyExistsException". // - // A table with the name already exists. + // A target table with the specified name already exists. ErrCodeTableAlreadyExistsException = "TableAlreadyExistsException" // ErrCodeTableInUseException for service response error code // "TableInUseException". // - // A table by that name is either being created or deleted. + // A target table with the specified name is either being created or deleted. ErrCodeTableInUseException = "TableInUseException" // ErrCodeTableNotFoundException for service response error code // "TableNotFoundException". // - // A table with the name TableName does not currently exist within the subscriber's - // account. + // A source table with the name TableName does not currently exist within the + // subscriber's account. ErrCodeTableNotFoundException = "TableNotFoundException" ) diff --git a/vendor/github.com/aws/aws-sdk-go/service/ec2/api.go b/vendor/github.com/aws/aws-sdk-go/service/ec2/api.go index 5c4982a7f588..28f434bbfff3 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/ec2/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/ec2/api.go @@ -17,7 +17,7 @@ const opAcceptReservedInstancesExchangeQuote = "AcceptReservedInstancesExchangeQ // AcceptReservedInstancesExchangeQuoteRequest generates a "aws/request.Request" representing the // client's request for the AcceptReservedInstancesExchangeQuote operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -92,7 +92,7 @@ const opAcceptVpcEndpointConnections = "AcceptVpcEndpointConnections" // AcceptVpcEndpointConnectionsRequest generates a "aws/request.Request" representing the // client's request for the AcceptVpcEndpointConnections operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -167,7 +167,7 @@ const opAcceptVpcPeeringConnection = "AcceptVpcPeeringConnection" // AcceptVpcPeeringConnectionRequest generates a "aws/request.Request" representing the // client's request for the AcceptVpcPeeringConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -247,7 +247,7 @@ const opAllocateAddress = "AllocateAddress" // AllocateAddressRequest generates a "aws/request.Request" representing the // client's request for the AllocateAddress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -333,7 +333,7 @@ const opAllocateHosts = "AllocateHosts" // AllocateHostsRequest generates a "aws/request.Request" representing the // client's request for the AllocateHosts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -409,7 +409,7 @@ const opAssignIpv6Addresses = "AssignIpv6Addresses" // AssignIpv6AddressesRequest generates a "aws/request.Request" representing the // client's request for the AssignIpv6Addresses operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -490,7 +490,7 @@ const opAssignPrivateIpAddresses = "AssignPrivateIpAddresses" // AssignPrivateIpAddressesRequest generates a "aws/request.Request" representing the // client's request for the AssignPrivateIpAddresses operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -576,7 +576,7 @@ const opAssociateAddress = "AssociateAddress" // AssociateAddressRequest generates a "aws/request.Request" representing the // client's request for the AssociateAddress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -673,7 +673,7 @@ const opAssociateDhcpOptions = "AssociateDhcpOptions" // AssociateDhcpOptionsRequest generates a "aws/request.Request" representing the // client's request for the AssociateDhcpOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -760,7 +760,7 @@ const opAssociateIamInstanceProfile = "AssociateIamInstanceProfile" // AssociateIamInstanceProfileRequest generates a "aws/request.Request" representing the // client's request for the AssociateIamInstanceProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -835,7 +835,7 @@ const opAssociateRouteTable = "AssociateRouteTable" // AssociateRouteTableRequest generates a "aws/request.Request" representing the // client's request for the AssociateRouteTable operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -916,7 +916,7 @@ const opAssociateSubnetCidrBlock = "AssociateSubnetCidrBlock" // AssociateSubnetCidrBlockRequest generates a "aws/request.Request" representing the // client's request for the AssociateSubnetCidrBlock operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -992,7 +992,7 @@ const opAssociateVpcCidrBlock = "AssociateVpcCidrBlock" // AssociateVpcCidrBlockRequest generates a "aws/request.Request" representing the // client's request for the AssociateVpcCidrBlock operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1072,7 +1072,7 @@ const opAttachClassicLinkVpc = "AttachClassicLinkVpc" // AttachClassicLinkVpcRequest generates a "aws/request.Request" representing the // client's request for the AttachClassicLinkVpc operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1157,7 +1157,7 @@ const opAttachInternetGateway = "AttachInternetGateway" // AttachInternetGatewayRequest generates a "aws/request.Request" representing the // client's request for the AttachInternetGateway operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1235,7 +1235,7 @@ const opAttachNetworkInterface = "AttachNetworkInterface" // AttachNetworkInterfaceRequest generates a "aws/request.Request" representing the // client's request for the AttachNetworkInterface operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1309,7 +1309,7 @@ const opAttachVolume = "AttachVolume" // AttachVolumeRequest generates a "aws/request.Request" representing the // client's request for the AttachVolume operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1412,7 +1412,7 @@ const opAttachVpnGateway = "AttachVpnGateway" // AttachVpnGatewayRequest generates a "aws/request.Request" representing the // client's request for the AttachVpnGateway operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1490,7 +1490,7 @@ const opAuthorizeSecurityGroupEgress = "AuthorizeSecurityGroupEgress" // AuthorizeSecurityGroupEgressRequest generates a "aws/request.Request" representing the // client's request for the AuthorizeSecurityGroupEgress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1583,7 +1583,7 @@ const opAuthorizeSecurityGroupIngress = "AuthorizeSecurityGroupIngress" // AuthorizeSecurityGroupIngressRequest generates a "aws/request.Request" representing the // client's request for the AuthorizeSecurityGroupIngress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1677,7 +1677,7 @@ const opBundleInstance = "BundleInstance" // BundleInstanceRequest generates a "aws/request.Request" representing the // client's request for the BundleInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1759,7 +1759,7 @@ const opCancelBundleTask = "CancelBundleTask" // CancelBundleTaskRequest generates a "aws/request.Request" representing the // client's request for the CancelBundleTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1833,7 +1833,7 @@ const opCancelConversionTask = "CancelConversionTask" // CancelConversionTaskRequest generates a "aws/request.Request" representing the // client's request for the CancelConversionTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1916,7 +1916,7 @@ const opCancelExportTask = "CancelExportTask" // CancelExportTaskRequest generates a "aws/request.Request" representing the // client's request for the CancelExportTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1995,7 +1995,7 @@ const opCancelImportTask = "CancelImportTask" // CancelImportTaskRequest generates a "aws/request.Request" representing the // client's request for the CancelImportTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2069,7 +2069,7 @@ const opCancelReservedInstancesListing = "CancelReservedInstancesListing" // CancelReservedInstancesListingRequest generates a "aws/request.Request" representing the // client's request for the CancelReservedInstancesListing operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2147,7 +2147,7 @@ const opCancelSpotFleetRequests = "CancelSpotFleetRequests" // CancelSpotFleetRequestsRequest generates a "aws/request.Request" representing the // client's request for the CancelSpotFleetRequests operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2228,7 +2228,7 @@ const opCancelSpotInstanceRequests = "CancelSpotInstanceRequests" // CancelSpotInstanceRequestsRequest generates a "aws/request.Request" representing the // client's request for the CancelSpotInstanceRequests operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2309,7 +2309,7 @@ const opConfirmProductInstance = "ConfirmProductInstance" // ConfirmProductInstanceRequest generates a "aws/request.Request" representing the // client's request for the ConfirmProductInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2385,7 +2385,7 @@ const opCopyFpgaImage = "CopyFpgaImage" // CopyFpgaImageRequest generates a "aws/request.Request" representing the // client's request for the CopyFpgaImage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2459,7 +2459,7 @@ const opCopyImage = "CopyImage" // CopyImageRequest generates a "aws/request.Request" representing the // client's request for the CopyImage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2539,7 +2539,7 @@ const opCopySnapshot = "CopySnapshot" // CopySnapshotRequest generates a "aws/request.Request" representing the // client's request for the CopySnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2632,7 +2632,7 @@ const opCreateCustomerGateway = "CreateCustomerGateway" // CreateCustomerGatewayRequest generates a "aws/request.Request" representing the // client's request for the CreateCustomerGateway operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2730,7 +2730,7 @@ const opCreateDefaultSubnet = "CreateDefaultSubnet" // CreateDefaultSubnetRequest generates a "aws/request.Request" representing the // client's request for the CreateDefaultSubnet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2808,7 +2808,7 @@ const opCreateDefaultVpc = "CreateDefaultVpc" // CreateDefaultVpcRequest generates a "aws/request.Request" representing the // client's request for the CreateDefaultVpc operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2894,7 +2894,7 @@ const opCreateDhcpOptions = "CreateDhcpOptions" // CreateDhcpOptionsRequest generates a "aws/request.Request" representing the // client's request for the CreateDhcpOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3007,7 +3007,7 @@ const opCreateEgressOnlyInternetGateway = "CreateEgressOnlyInternetGateway" // CreateEgressOnlyInternetGatewayRequest generates a "aws/request.Request" representing the // client's request for the CreateEgressOnlyInternetGateway operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3084,7 +3084,7 @@ const opCreateFlowLogs = "CreateFlowLogs" // CreateFlowLogsRequest generates a "aws/request.Request" representing the // client's request for the CreateFlowLogs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3135,6 +3135,9 @@ func (c *EC2) CreateFlowLogsRequest(input *CreateFlowLogsInput) (req *request.Re // In your request, you must also specify an IAM role that has permission to // publish logs to CloudWatch Logs. // +// For more information, see VPC Flow Logs (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/flow-logs.html) +// in the Amazon Virtual Private Cloud User Guide. +// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -3167,7 +3170,7 @@ const opCreateFpgaImage = "CreateFpgaImage" // CreateFpgaImageRequest generates a "aws/request.Request" representing the // client's request for the CreateFpgaImage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3248,7 +3251,7 @@ const opCreateImage = "CreateImage" // CreateImageRequest generates a "aws/request.Request" representing the // client's request for the CreateImage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3331,7 +3334,7 @@ const opCreateInstanceExportTask = "CreateInstanceExportTask" // CreateInstanceExportTaskRequest generates a "aws/request.Request" representing the // client's request for the CreateInstanceExportTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3410,7 +3413,7 @@ const opCreateInternetGateway = "CreateInternetGateway" // CreateInternetGatewayRequest generates a "aws/request.Request" representing the // client's request for the CreateInternetGateway operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3488,7 +3491,7 @@ const opCreateKeyPair = "CreateKeyPair" // CreateKeyPairRequest generates a "aws/request.Request" representing the // client's request for the CreateKeyPair operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3574,7 +3577,7 @@ const opCreateLaunchTemplate = "CreateLaunchTemplate" // CreateLaunchTemplateRequest generates a "aws/request.Request" representing the // client's request for the CreateLaunchTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3650,7 +3653,7 @@ const opCreateLaunchTemplateVersion = "CreateLaunchTemplateVersion" // CreateLaunchTemplateVersionRequest generates a "aws/request.Request" representing the // client's request for the CreateLaunchTemplateVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3728,7 +3731,7 @@ const opCreateNatGateway = "CreateNatGateway" // CreateNatGatewayRequest generates a "aws/request.Request" representing the // client's request for the CreateNatGateway operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3807,7 +3810,7 @@ const opCreateNetworkAcl = "CreateNetworkAcl" // CreateNetworkAclRequest generates a "aws/request.Request" representing the // client's request for the CreateNetworkAcl operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3885,7 +3888,7 @@ const opCreateNetworkAclEntry = "CreateNetworkAclEntry" // CreateNetworkAclEntryRequest generates a "aws/request.Request" representing the // client's request for the CreateNetworkAclEntry operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3977,7 +3980,7 @@ const opCreateNetworkInterface = "CreateNetworkInterface" // CreateNetworkInterfaceRequest generates a "aws/request.Request" representing the // client's request for the CreateNetworkInterface operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4055,7 +4058,7 @@ const opCreateNetworkInterfacePermission = "CreateNetworkInterfacePermission" // CreateNetworkInterfacePermissionRequest generates a "aws/request.Request" representing the // client's request for the CreateNetworkInterfacePermission operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4133,7 +4136,7 @@ const opCreatePlacementGroup = "CreatePlacementGroup" // CreatePlacementGroupRequest generates a "aws/request.Request" representing the // client's request for the CreatePlacementGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4217,7 +4220,7 @@ const opCreateReservedInstancesListing = "CreateReservedInstancesListing" // CreateReservedInstancesListingRequest generates a "aws/request.Request" representing the // client's request for the CreateReservedInstancesListing operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4314,7 +4317,7 @@ const opCreateRoute = "CreateRoute" // CreateRouteRequest generates a "aws/request.Request" representing the // client's request for the CreateRoute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4407,7 +4410,7 @@ const opCreateRouteTable = "CreateRouteTable" // CreateRouteTableRequest generates a "aws/request.Request" representing the // client's request for the CreateRouteTable operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4485,7 +4488,7 @@ const opCreateSecurityGroup = "CreateSecurityGroup" // CreateSecurityGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateSecurityGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4585,7 +4588,7 @@ const opCreateSnapshot = "CreateSnapshot" // CreateSnapshotRequest generates a "aws/request.Request" representing the // client's request for the CreateSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4650,6 +4653,9 @@ func (c *EC2) CreateSnapshotRequest(input *CreateSnapshotInput) (req *request.Re // encrypted. Your encrypted volumes and any associated snapshots always remain // protected. // +// You can tag your snapshots during creation. For more information, see Tagging +// Your Amazon EC2 Resources (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html). +// // For more information, see Amazon Elastic Block Store (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/AmazonEBS.html) // and Amazon EBS Encryption (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) // in the Amazon Elastic Compute Cloud User Guide. @@ -4686,7 +4692,7 @@ const opCreateSpotDatafeedSubscription = "CreateSpotDatafeedSubscription" // CreateSpotDatafeedSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the CreateSpotDatafeedSubscription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4763,7 +4769,7 @@ const opCreateSubnet = "CreateSubnet" // CreateSubnetRequest generates a "aws/request.Request" representing the // client's request for the CreateSubnet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4863,7 +4869,7 @@ const opCreateTags = "CreateTags" // CreateTagsRequest generates a "aws/request.Request" representing the // client's request for the CreateTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4947,7 +4953,7 @@ const opCreateVolume = "CreateVolume" // CreateVolumeRequest generates a "aws/request.Request" representing the // client's request for the CreateVolume operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5039,7 +5045,7 @@ const opCreateVpc = "CreateVpc" // CreateVpcRequest generates a "aws/request.Request" representing the // client's request for the CreateVpc operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5131,7 +5137,7 @@ const opCreateVpcEndpoint = "CreateVpcEndpoint" // CreateVpcEndpointRequest generates a "aws/request.Request" representing the // client's request for the CreateVpcEndpoint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5221,7 +5227,7 @@ const opCreateVpcEndpointConnectionNotification = "CreateVpcEndpointConnectionNo // CreateVpcEndpointConnectionNotificationRequest generates a "aws/request.Request" representing the // client's request for the CreateVpcEndpointConnectionNotification operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5301,7 +5307,7 @@ const opCreateVpcEndpointServiceConfiguration = "CreateVpcEndpointServiceConfigu // CreateVpcEndpointServiceConfigurationRequest generates a "aws/request.Request" representing the // client's request for the CreateVpcEndpointServiceConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5382,7 +5388,7 @@ const opCreateVpcPeeringConnection = "CreateVpcPeeringConnection" // CreateVpcPeeringConnectionRequest generates a "aws/request.Request" representing the // client's request for the CreateVpcPeeringConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5471,7 +5477,7 @@ const opCreateVpnConnection = "CreateVpnConnection" // CreateVpnConnectionRequest generates a "aws/request.Request" representing the // client's request for the CreateVpnConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5563,7 +5569,7 @@ const opCreateVpnConnectionRoute = "CreateVpnConnectionRoute" // CreateVpnConnectionRouteRequest generates a "aws/request.Request" representing the // client's request for the CreateVpnConnectionRoute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5646,7 +5652,7 @@ const opCreateVpnGateway = "CreateVpnGateway" // CreateVpnGatewayRequest generates a "aws/request.Request" representing the // client's request for the CreateVpnGateway operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5726,7 +5732,7 @@ const opDeleteCustomerGateway = "DeleteCustomerGateway" // DeleteCustomerGatewayRequest generates a "aws/request.Request" representing the // client's request for the DeleteCustomerGateway operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5803,7 +5809,7 @@ const opDeleteDhcpOptions = "DeleteDhcpOptions" // DeleteDhcpOptionsRequest generates a "aws/request.Request" representing the // client's request for the DeleteDhcpOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5882,7 +5888,7 @@ const opDeleteEgressOnlyInternetGateway = "DeleteEgressOnlyInternetGateway" // DeleteEgressOnlyInternetGatewayRequest generates a "aws/request.Request" representing the // client's request for the DeleteEgressOnlyInternetGateway operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5956,7 +5962,7 @@ const opDeleteFlowLogs = "DeleteFlowLogs" // DeleteFlowLogsRequest generates a "aws/request.Request" representing the // client's request for the DeleteFlowLogs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6030,7 +6036,7 @@ const opDeleteFpgaImage = "DeleteFpgaImage" // DeleteFpgaImageRequest generates a "aws/request.Request" representing the // client's request for the DeleteFpgaImage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6104,7 +6110,7 @@ const opDeleteInternetGateway = "DeleteInternetGateway" // DeleteInternetGatewayRequest generates a "aws/request.Request" representing the // client's request for the DeleteInternetGateway operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6181,7 +6187,7 @@ const opDeleteKeyPair = "DeleteKeyPair" // DeleteKeyPairRequest generates a "aws/request.Request" representing the // client's request for the DeleteKeyPair operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6257,7 +6263,7 @@ const opDeleteLaunchTemplate = "DeleteLaunchTemplate" // DeleteLaunchTemplateRequest generates a "aws/request.Request" representing the // client's request for the DeleteLaunchTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6332,7 +6338,7 @@ const opDeleteLaunchTemplateVersions = "DeleteLaunchTemplateVersions" // DeleteLaunchTemplateVersionsRequest generates a "aws/request.Request" representing the // client's request for the DeleteLaunchTemplateVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6409,7 +6415,7 @@ const opDeleteNatGateway = "DeleteNatGateway" // DeleteNatGatewayRequest generates a "aws/request.Request" representing the // client's request for the DeleteNatGateway operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6485,7 +6491,7 @@ const opDeleteNetworkAcl = "DeleteNetworkAcl" // DeleteNetworkAclRequest generates a "aws/request.Request" representing the // client's request for the DeleteNetworkAcl operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6562,7 +6568,7 @@ const opDeleteNetworkAclEntry = "DeleteNetworkAclEntry" // DeleteNetworkAclEntryRequest generates a "aws/request.Request" representing the // client's request for the DeleteNetworkAclEntry operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6639,7 +6645,7 @@ const opDeleteNetworkInterface = "DeleteNetworkInterface" // DeleteNetworkInterfaceRequest generates a "aws/request.Request" representing the // client's request for the DeleteNetworkInterface operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6716,7 +6722,7 @@ const opDeleteNetworkInterfacePermission = "DeleteNetworkInterfacePermission" // DeleteNetworkInterfacePermissionRequest generates a "aws/request.Request" representing the // client's request for the DeleteNetworkInterfacePermission operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6793,7 +6799,7 @@ const opDeletePlacementGroup = "DeletePlacementGroup" // DeletePlacementGroupRequest generates a "aws/request.Request" representing the // client's request for the DeletePlacementGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6872,7 +6878,7 @@ const opDeleteRoute = "DeleteRoute" // DeleteRouteRequest generates a "aws/request.Request" representing the // client's request for the DeleteRoute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6948,7 +6954,7 @@ const opDeleteRouteTable = "DeleteRouteTable" // DeleteRouteTableRequest generates a "aws/request.Request" representing the // client's request for the DeleteRouteTable operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7026,7 +7032,7 @@ const opDeleteSecurityGroup = "DeleteSecurityGroup" // DeleteSecurityGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteSecurityGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7106,7 +7112,7 @@ const opDeleteSnapshot = "DeleteSnapshot" // DeleteSnapshotRequest generates a "aws/request.Request" representing the // client's request for the DeleteSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7196,7 +7202,7 @@ const opDeleteSpotDatafeedSubscription = "DeleteSpotDatafeedSubscription" // DeleteSpotDatafeedSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the DeleteSpotDatafeedSubscription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7272,7 +7278,7 @@ const opDeleteSubnet = "DeleteSubnet" // DeleteSubnetRequest generates a "aws/request.Request" representing the // client's request for the DeleteSubnet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7349,7 +7355,7 @@ const opDeleteTags = "DeleteTags" // DeleteTagsRequest generates a "aws/request.Request" representing the // client's request for the DeleteTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7429,7 +7435,7 @@ const opDeleteVolume = "DeleteVolume" // DeleteVolumeRequest generates a "aws/request.Request" representing the // client's request for the DeleteVolume operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7511,7 +7517,7 @@ const opDeleteVpc = "DeleteVpc" // DeleteVpcRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpc operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7591,7 +7597,7 @@ const opDeleteVpcEndpointConnectionNotifications = "DeleteVpcEndpointConnectionN // DeleteVpcEndpointConnectionNotificationsRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpcEndpointConnectionNotifications operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7665,7 +7671,7 @@ const opDeleteVpcEndpointServiceConfigurations = "DeleteVpcEndpointServiceConfig // DeleteVpcEndpointServiceConfigurationsRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpcEndpointServiceConfigurations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7742,7 +7748,7 @@ const opDeleteVpcEndpoints = "DeleteVpcEndpoints" // DeleteVpcEndpointsRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpcEndpoints operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7819,7 +7825,7 @@ const opDeleteVpcPeeringConnection = "DeleteVpcPeeringConnection" // DeleteVpcPeeringConnectionRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpcPeeringConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7862,7 +7868,8 @@ func (c *EC2) DeleteVpcPeeringConnectionRequest(input *DeleteVpcPeeringConnectio // Deletes a VPC peering connection. Either the owner of the requester VPC or // the owner of the accepter VPC can delete the VPC peering connection if it's // in the active state. The owner of the requester VPC can delete a VPC peering -// connection in the pending-acceptance state. +// connection in the pending-acceptance state. You cannot delete a VPC peering +// connection that's in the failed state. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -7896,7 +7903,7 @@ const opDeleteVpnConnection = "DeleteVpnConnection" // DeleteVpnConnectionRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpnConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7981,7 +7988,7 @@ const opDeleteVpnConnectionRoute = "DeleteVpnConnectionRoute" // DeleteVpnConnectionRouteRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpnConnectionRoute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8060,7 +8067,7 @@ const opDeleteVpnGateway = "DeleteVpnGateway" // DeleteVpnGatewayRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpnGateway operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8140,7 +8147,7 @@ const opDeregisterImage = "DeregisterImage" // DeregisterImageRequest generates a "aws/request.Request" representing the // client's request for the DeregisterImage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8224,7 +8231,7 @@ const opDescribeAccountAttributes = "DescribeAccountAttributes" // DescribeAccountAttributesRequest generates a "aws/request.Request" representing the // client's request for the DescribeAccountAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8316,7 +8323,7 @@ const opDescribeAddresses = "DescribeAddresses" // DescribeAddressesRequest generates a "aws/request.Request" representing the // client's request for the DescribeAddresses operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8394,7 +8401,7 @@ const opDescribeAggregateIdFormat = "DescribeAggregateIdFormat" // DescribeAggregateIdFormatRequest generates a "aws/request.Request" representing the // client's request for the DescribeAggregateIdFormat operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8443,12 +8450,12 @@ func (c *EC2) DescribeAggregateIdFormatRequest(input *DescribeAggregateIdFormatI // IDs. // // The following resource types support longer IDs: bundle | conversion-task -// | dhcp-options | elastic-ip-allocation | elastic-ip-association | export-task -// | flow-log | image | import-task | instance | internet-gateway | network-acl -// | network-acl-association | network-interface | network-interface-attachment +// | customer-gateway | dhcp-options | elastic-ip-allocation | elastic-ip-association +// | export-task | flow-log | image | import-task | instance | internet-gateway +// | network-acl | network-acl-association | network-interface | network-interface-attachment // | prefix-list | reservation | route-table | route-table-association | security-group // | snapshot | subnet | subnet-cidr-block-association | volume | vpc | vpc-cidr-block-association -// | vpc-peering-connection. +// | vpc-endpoint | vpc-peering-connection | vpn-connection | vpn-gateway. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -8482,7 +8489,7 @@ const opDescribeAvailabilityZones = "DescribeAvailabilityZones" // DescribeAvailabilityZonesRequest generates a "aws/request.Request" representing the // client's request for the DescribeAvailabilityZones operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8562,7 +8569,7 @@ const opDescribeBundleTasks = "DescribeBundleTasks" // DescribeBundleTasksRequest generates a "aws/request.Request" representing the // client's request for the DescribeBundleTasks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8641,7 +8648,7 @@ const opDescribeClassicLinkInstances = "DescribeClassicLinkInstances" // DescribeClassicLinkInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeClassicLinkInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8718,7 +8725,7 @@ const opDescribeConversionTasks = "DescribeConversionTasks" // DescribeConversionTasksRequest generates a "aws/request.Request" representing the // client's request for the DescribeConversionTasks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8796,7 +8803,7 @@ const opDescribeCustomerGateways = "DescribeCustomerGateways" // DescribeCustomerGatewaysRequest generates a "aws/request.Request" representing the // client's request for the DescribeCustomerGateways operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8874,7 +8881,7 @@ const opDescribeDhcpOptions = "DescribeDhcpOptions" // DescribeDhcpOptionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeDhcpOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8951,7 +8958,7 @@ const opDescribeEgressOnlyInternetGateways = "DescribeEgressOnlyInternetGateways // DescribeEgressOnlyInternetGatewaysRequest generates a "aws/request.Request" representing the // client's request for the DescribeEgressOnlyInternetGateways operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9025,7 +9032,7 @@ const opDescribeElasticGpus = "DescribeElasticGpus" // DescribeElasticGpusRequest generates a "aws/request.Request" representing the // client's request for the DescribeElasticGpus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9100,7 +9107,7 @@ const opDescribeExportTasks = "DescribeExportTasks" // DescribeExportTasksRequest generates a "aws/request.Request" representing the // client's request for the DescribeExportTasks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9174,7 +9181,7 @@ const opDescribeFlowLogs = "DescribeFlowLogs" // DescribeFlowLogsRequest generates a "aws/request.Request" representing the // client's request for the DescribeFlowLogs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9250,7 +9257,7 @@ const opDescribeFpgaImageAttribute = "DescribeFpgaImageAttribute" // DescribeFpgaImageAttributeRequest generates a "aws/request.Request" representing the // client's request for the DescribeFpgaImageAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9324,7 +9331,7 @@ const opDescribeFpgaImages = "DescribeFpgaImages" // DescribeFpgaImagesRequest generates a "aws/request.Request" representing the // client's request for the DescribeFpgaImages operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9400,7 +9407,7 @@ const opDescribeHostReservationOfferings = "DescribeHostReservationOfferings" // DescribeHostReservationOfferingsRequest generates a "aws/request.Request" representing the // client's request for the DescribeHostReservationOfferings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9482,7 +9489,7 @@ const opDescribeHostReservations = "DescribeHostReservations" // DescribeHostReservationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeHostReservations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9557,7 +9564,7 @@ const opDescribeHosts = "DescribeHosts" // DescribeHostsRequest generates a "aws/request.Request" representing the // client's request for the DescribeHosts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9635,7 +9642,7 @@ const opDescribeIamInstanceProfileAssociations = "DescribeIamInstanceProfileAsso // DescribeIamInstanceProfileAssociationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeIamInstanceProfileAssociations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9709,7 +9716,7 @@ const opDescribeIdFormat = "DescribeIdFormat" // DescribeIdFormatRequest generates a "aws/request.Request" representing the // client's request for the DescribeIdFormat operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9755,12 +9762,12 @@ func (c *EC2) DescribeIdFormatRequest(input *DescribeIdFormatInput) (req *reques // be modified; it does not return information about other resource types. // // The following resource types support longer IDs: bundle | conversion-task -// | dhcp-options | elastic-ip-allocation | elastic-ip-association | export-task -// | flow-log | image | import-task | instance | internet-gateway | network-acl -// | network-acl-association | network-interface | network-interface-attachment +// | customer-gateway | dhcp-options | elastic-ip-allocation | elastic-ip-association +// | export-task | flow-log | image | import-task | instance | internet-gateway +// | network-acl | network-acl-association | network-interface | network-interface-attachment // | prefix-list | reservation | route-table | route-table-association | security-group // | snapshot | subnet | subnet-cidr-block-association | volume | vpc | vpc-cidr-block-association -// | vpc-peering-connection. +// | vpc-endpoint | vpc-peering-connection | vpn-connection | vpn-gateway. // // These settings apply to the IAM user who makes the request; they do not apply // to the entire AWS account. By default, an IAM user defaults to the same settings @@ -9801,7 +9808,7 @@ const opDescribeIdentityIdFormat = "DescribeIdentityIdFormat" // DescribeIdentityIdFormatRequest generates a "aws/request.Request" representing the // client's request for the DescribeIdentityIdFormat operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9849,12 +9856,12 @@ func (c *EC2) DescribeIdentityIdFormatRequest(input *DescribeIdentityIdFormatInp // in the Amazon Elastic Compute Cloud User Guide. // // The following resource types support longer IDs: bundle | conversion-task -// | dhcp-options | elastic-ip-allocation | elastic-ip-association | export-task -// | flow-log | image | import-task | instance | internet-gateway | network-acl -// | network-acl-association | network-interface | network-interface-attachment +// | customer-gateway | dhcp-options | elastic-ip-allocation | elastic-ip-association +// | export-task | flow-log | image | import-task | instance | internet-gateway +// | network-acl | network-acl-association | network-interface | network-interface-attachment // | prefix-list | reservation | route-table | route-table-association | security-group // | snapshot | subnet | subnet-cidr-block-association | volume | vpc | vpc-cidr-block-association -// | vpc-peering-connection. +// | vpc-endpoint | vpc-peering-connection | vpn-connection | vpn-gateway. // // These settings apply to the principal specified in the request. They do not // apply to the principal that makes the request. @@ -9891,7 +9898,7 @@ const opDescribeImageAttribute = "DescribeImageAttribute" // DescribeImageAttributeRequest generates a "aws/request.Request" representing the // client's request for the DescribeImageAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9966,7 +9973,7 @@ const opDescribeImages = "DescribeImages" // DescribeImagesRequest generates a "aws/request.Request" representing the // client's request for the DescribeImages operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10046,7 +10053,7 @@ const opDescribeImportImageTasks = "DescribeImportImageTasks" // DescribeImportImageTasksRequest generates a "aws/request.Request" representing the // client's request for the DescribeImportImageTasks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10121,7 +10128,7 @@ const opDescribeImportSnapshotTasks = "DescribeImportSnapshotTasks" // DescribeImportSnapshotTasksRequest generates a "aws/request.Request" representing the // client's request for the DescribeImportSnapshotTasks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10195,7 +10202,7 @@ const opDescribeInstanceAttribute = "DescribeInstanceAttribute" // DescribeInstanceAttributeRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstanceAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10273,7 +10280,7 @@ const opDescribeInstanceCreditSpecifications = "DescribeInstanceCreditSpecificat // DescribeInstanceCreditSpecificationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstanceCreditSpecifications operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10365,7 +10372,7 @@ const opDescribeInstanceStatus = "DescribeInstanceStatus" // DescribeInstanceStatusRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstanceStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10516,7 +10523,7 @@ const opDescribeInstances = "DescribeInstances" // DescribeInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10661,7 +10668,7 @@ const opDescribeInternetGateways = "DescribeInternetGateways" // DescribeInternetGatewaysRequest generates a "aws/request.Request" representing the // client's request for the DescribeInternetGateways operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10735,7 +10742,7 @@ const opDescribeKeyPairs = "DescribeKeyPairs" // DescribeKeyPairsRequest generates a "aws/request.Request" representing the // client's request for the DescribeKeyPairs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10812,7 +10819,7 @@ const opDescribeLaunchTemplateVersions = "DescribeLaunchTemplateVersions" // DescribeLaunchTemplateVersionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeLaunchTemplateVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10887,7 +10894,7 @@ const opDescribeLaunchTemplates = "DescribeLaunchTemplates" // DescribeLaunchTemplatesRequest generates a "aws/request.Request" representing the // client's request for the DescribeLaunchTemplates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10961,7 +10968,7 @@ const opDescribeMovingAddresses = "DescribeMovingAddresses" // DescribeMovingAddressesRequest generates a "aws/request.Request" representing the // client's request for the DescribeMovingAddresses operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11037,7 +11044,7 @@ const opDescribeNatGateways = "DescribeNatGateways" // DescribeNatGatewaysRequest generates a "aws/request.Request" representing the // client's request for the DescribeNatGateways operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11167,7 +11174,7 @@ const opDescribeNetworkAcls = "DescribeNetworkAcls" // DescribeNetworkAclsRequest generates a "aws/request.Request" representing the // client's request for the DescribeNetworkAcls operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11244,7 +11251,7 @@ const opDescribeNetworkInterfaceAttribute = "DescribeNetworkInterfaceAttribute" // DescribeNetworkInterfaceAttributeRequest generates a "aws/request.Request" representing the // client's request for the DescribeNetworkInterfaceAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11319,7 +11326,7 @@ const opDescribeNetworkInterfacePermissions = "DescribeNetworkInterfacePermissio // DescribeNetworkInterfacePermissionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeNetworkInterfacePermissions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11393,7 +11400,7 @@ const opDescribeNetworkInterfaces = "DescribeNetworkInterfaces" // DescribeNetworkInterfacesRequest generates a "aws/request.Request" representing the // client's request for the DescribeNetworkInterfaces operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11467,7 +11474,7 @@ const opDescribePlacementGroups = "DescribePlacementGroups" // DescribePlacementGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribePlacementGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11543,7 +11550,7 @@ const opDescribePrefixLists = "DescribePrefixLists" // DescribePrefixListsRequest generates a "aws/request.Request" representing the // client's request for the DescribePrefixLists operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11621,7 +11628,7 @@ const opDescribePrincipalIdFormat = "DescribePrincipalIdFormat" // DescribePrincipalIdFormatRequest generates a "aws/request.Request" representing the // client's request for the DescribePrincipalIdFormat operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11670,12 +11677,12 @@ func (c *EC2) DescribePrincipalIdFormatRequest(input *DescribePrincipalIdFormatI // the default ID settings. // // The following resource types support longer IDs: bundle | conversion-task -// | dhcp-options | elastic-ip-allocation | elastic-ip-association | export-task -// | flow-log | image | import-task | instance | internet-gateway | network-acl -// | network-acl-association | network-interface | network-interface-attachment +// | customer-gateway | dhcp-options | elastic-ip-allocation | elastic-ip-association +// | export-task | flow-log | image | import-task | instance | internet-gateway +// | network-acl | network-acl-association | network-interface | network-interface-attachment // | prefix-list | reservation | route-table | route-table-association | security-group // | snapshot | subnet | subnet-cidr-block-association | volume | vpc | vpc-cidr-block-association -// | vpc-peering-connection. +// | vpc-endpoint | vpc-peering-connection | vpn-connection | vpn-gateway. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -11709,7 +11716,7 @@ const opDescribeRegions = "DescribeRegions" // DescribeRegionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeRegions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11786,7 +11793,7 @@ const opDescribeReservedInstances = "DescribeReservedInstances" // DescribeReservedInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeReservedInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11863,7 +11870,7 @@ const opDescribeReservedInstancesListings = "DescribeReservedInstancesListings" // DescribeReservedInstancesListingsRequest generates a "aws/request.Request" representing the // client's request for the DescribeReservedInstancesListings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11958,7 +11965,7 @@ const opDescribeReservedInstancesModifications = "DescribeReservedInstancesModif // DescribeReservedInstancesModificationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeReservedInstancesModifications operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12094,7 +12101,7 @@ const opDescribeReservedInstancesOfferings = "DescribeReservedInstancesOfferings // DescribeReservedInstancesOfferingsRequest generates a "aws/request.Request" representing the // client's request for the DescribeReservedInstancesOfferings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12235,7 +12242,7 @@ const opDescribeRouteTables = "DescribeRouteTables" // DescribeRouteTablesRequest generates a "aws/request.Request" representing the // client's request for the DescribeRouteTables operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12317,7 +12324,7 @@ const opDescribeScheduledInstanceAvailability = "DescribeScheduledInstanceAvaila // DescribeScheduledInstanceAvailabilityRequest generates a "aws/request.Request" representing the // client's request for the DescribeScheduledInstanceAvailability operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12399,7 +12406,7 @@ const opDescribeScheduledInstances = "DescribeScheduledInstances" // DescribeScheduledInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeScheduledInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12473,7 +12480,7 @@ const opDescribeSecurityGroupReferences = "DescribeSecurityGroupReferences" // DescribeSecurityGroupReferencesRequest generates a "aws/request.Request" representing the // client's request for the DescribeSecurityGroupReferences operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12548,7 +12555,7 @@ const opDescribeSecurityGroups = "DescribeSecurityGroups" // DescribeSecurityGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeSecurityGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12629,7 +12636,7 @@ const opDescribeSnapshotAttribute = "DescribeSnapshotAttribute" // DescribeSnapshotAttributeRequest generates a "aws/request.Request" representing the // client's request for the DescribeSnapshotAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12707,7 +12714,7 @@ const opDescribeSnapshots = "DescribeSnapshots" // DescribeSnapshotsRequest generates a "aws/request.Request" representing the // client's request for the DescribeSnapshots operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12882,7 +12889,7 @@ const opDescribeSpotDatafeedSubscription = "DescribeSpotDatafeedSubscription" // DescribeSpotDatafeedSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the DescribeSpotDatafeedSubscription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12958,7 +12965,7 @@ const opDescribeSpotFleetInstances = "DescribeSpotFleetInstances" // DescribeSpotFleetInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeSpotFleetInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -13032,7 +13039,7 @@ const opDescribeSpotFleetRequestHistory = "DescribeSpotFleetRequestHistory" // DescribeSpotFleetRequestHistoryRequest generates a "aws/request.Request" representing the // client's request for the DescribeSpotFleetRequestHistory operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -13111,7 +13118,7 @@ const opDescribeSpotFleetRequests = "DescribeSpotFleetRequests" // DescribeSpotFleetRequestsRequest generates a "aws/request.Request" representing the // client's request for the DescribeSpotFleetRequests operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -13244,7 +13251,7 @@ const opDescribeSpotInstanceRequests = "DescribeSpotInstanceRequests" // DescribeSpotInstanceRequestsRequest generates a "aws/request.Request" representing the // client's request for the DescribeSpotInstanceRequests operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -13331,7 +13338,7 @@ const opDescribeSpotPriceHistory = "DescribeSpotPriceHistory" // DescribeSpotPriceHistoryRequest generates a "aws/request.Request" representing the // client's request for the DescribeSpotPriceHistory operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -13468,7 +13475,7 @@ const opDescribeStaleSecurityGroups = "DescribeStaleSecurityGroups" // DescribeStaleSecurityGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeStaleSecurityGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -13545,7 +13552,7 @@ const opDescribeSubnets = "DescribeSubnets" // DescribeSubnetsRequest generates a "aws/request.Request" representing the // client's request for the DescribeSubnets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -13622,7 +13629,7 @@ const opDescribeTags = "DescribeTags" // DescribeTagsRequest generates a "aws/request.Request" representing the // client's request for the DescribeTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -13755,7 +13762,7 @@ const opDescribeVolumeAttribute = "DescribeVolumeAttribute" // DescribeVolumeAttributeRequest generates a "aws/request.Request" representing the // client's request for the DescribeVolumeAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -13833,7 +13840,7 @@ const opDescribeVolumeStatus = "DescribeVolumeStatus" // DescribeVolumeStatusRequest generates a "aws/request.Request" representing the // client's request for the DescribeVolumeStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -13997,7 +14004,7 @@ const opDescribeVolumes = "DescribeVolumes" // DescribeVolumesRequest generates a "aws/request.Request" representing the // client's request for the DescribeVolumes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -14137,7 +14144,7 @@ const opDescribeVolumesModifications = "DescribeVolumesModifications" // DescribeVolumesModificationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVolumesModifications operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -14223,7 +14230,7 @@ const opDescribeVpcAttribute = "DescribeVpcAttribute" // DescribeVpcAttributeRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -14298,7 +14305,7 @@ const opDescribeVpcClassicLink = "DescribeVpcClassicLink" // DescribeVpcClassicLinkRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcClassicLink operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -14372,7 +14379,7 @@ const opDescribeVpcClassicLinkDnsSupport = "DescribeVpcClassicLinkDnsSupport" // DescribeVpcClassicLinkDnsSupportRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcClassicLinkDnsSupport operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -14452,7 +14459,7 @@ const opDescribeVpcEndpointConnectionNotifications = "DescribeVpcEndpointConnect // DescribeVpcEndpointConnectionNotificationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcEndpointConnectionNotifications operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -14527,7 +14534,7 @@ const opDescribeVpcEndpointConnections = "DescribeVpcEndpointConnections" // DescribeVpcEndpointConnectionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcEndpointConnections operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -14602,7 +14609,7 @@ const opDescribeVpcEndpointServiceConfigurations = "DescribeVpcEndpointServiceCo // DescribeVpcEndpointServiceConfigurationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcEndpointServiceConfigurations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -14676,7 +14683,7 @@ const opDescribeVpcEndpointServicePermissions = "DescribeVpcEndpointServicePermi // DescribeVpcEndpointServicePermissionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcEndpointServicePermissions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -14751,7 +14758,7 @@ const opDescribeVpcEndpointServices = "DescribeVpcEndpointServices" // DescribeVpcEndpointServicesRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcEndpointServices operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -14825,7 +14832,7 @@ const opDescribeVpcEndpoints = "DescribeVpcEndpoints" // DescribeVpcEndpointsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcEndpoints operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -14899,7 +14906,7 @@ const opDescribeVpcPeeringConnections = "DescribeVpcPeeringConnections" // DescribeVpcPeeringConnectionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcPeeringConnections operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -14973,7 +14980,7 @@ const opDescribeVpcs = "DescribeVpcs" // DescribeVpcsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -15047,7 +15054,7 @@ const opDescribeVpnConnections = "DescribeVpnConnections" // DescribeVpnConnectionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpnConnections operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -15125,7 +15132,7 @@ const opDescribeVpnGateways = "DescribeVpnGateways" // DescribeVpnGatewaysRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpnGateways operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -15203,7 +15210,7 @@ const opDetachClassicLinkVpc = "DetachClassicLinkVpc" // DetachClassicLinkVpcRequest generates a "aws/request.Request" representing the // client's request for the DetachClassicLinkVpc operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -15279,7 +15286,7 @@ const opDetachInternetGateway = "DetachInternetGateway" // DetachInternetGatewayRequest generates a "aws/request.Request" representing the // client's request for the DetachInternetGateway operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -15357,7 +15364,7 @@ const opDetachNetworkInterface = "DetachNetworkInterface" // DetachNetworkInterfaceRequest generates a "aws/request.Request" representing the // client's request for the DetachNetworkInterface operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -15433,7 +15440,7 @@ const opDetachVolume = "DetachVolume" // DetachVolumeRequest generates a "aws/request.Request" representing the // client's request for the DetachVolume operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -15520,7 +15527,7 @@ const opDetachVpnGateway = "DetachVpnGateway" // DetachVpnGatewayRequest generates a "aws/request.Request" representing the // client's request for the DetachVpnGateway operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -15603,7 +15610,7 @@ const opDisableVgwRoutePropagation = "DisableVgwRoutePropagation" // DisableVgwRoutePropagationRequest generates a "aws/request.Request" representing the // client's request for the DisableVgwRoutePropagation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -15680,7 +15687,7 @@ const opDisableVpcClassicLink = "DisableVpcClassicLink" // DisableVpcClassicLinkRequest generates a "aws/request.Request" representing the // client's request for the DisableVpcClassicLink operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -15755,7 +15762,7 @@ const opDisableVpcClassicLinkDnsSupport = "DisableVpcClassicLinkDnsSupport" // DisableVpcClassicLinkDnsSupportRequest generates a "aws/request.Request" representing the // client's request for the DisableVpcClassicLinkDnsSupport operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -15833,7 +15840,7 @@ const opDisassociateAddress = "DisassociateAddress" // DisassociateAddressRequest generates a "aws/request.Request" representing the // client's request for the DisassociateAddress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -15917,7 +15924,7 @@ const opDisassociateIamInstanceProfile = "DisassociateIamInstanceProfile" // DisassociateIamInstanceProfileRequest generates a "aws/request.Request" representing the // client's request for the DisassociateIamInstanceProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -15993,7 +16000,7 @@ const opDisassociateRouteTable = "DisassociateRouteTable" // DisassociateRouteTableRequest generates a "aws/request.Request" representing the // client's request for the DisassociateRouteTable operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -16074,7 +16081,7 @@ const opDisassociateSubnetCidrBlock = "DisassociateSubnetCidrBlock" // DisassociateSubnetCidrBlockRequest generates a "aws/request.Request" representing the // client's request for the DisassociateSubnetCidrBlock operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -16150,7 +16157,7 @@ const opDisassociateVpcCidrBlock = "DisassociateVpcCidrBlock" // DisassociateVpcCidrBlockRequest generates a "aws/request.Request" representing the // client's request for the DisassociateVpcCidrBlock operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -16230,7 +16237,7 @@ const opEnableVgwRoutePropagation = "EnableVgwRoutePropagation" // EnableVgwRoutePropagationRequest generates a "aws/request.Request" representing the // client's request for the EnableVgwRoutePropagation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -16307,7 +16314,7 @@ const opEnableVolumeIO = "EnableVolumeIO" // EnableVolumeIORequest generates a "aws/request.Request" representing the // client's request for the EnableVolumeIO operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -16384,7 +16391,7 @@ const opEnableVpcClassicLink = "EnableVpcClassicLink" // EnableVpcClassicLinkRequest generates a "aws/request.Request" representing the // client's request for the EnableVpcClassicLink operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -16464,7 +16471,7 @@ const opEnableVpcClassicLinkDnsSupport = "EnableVpcClassicLinkDnsSupport" // EnableVpcClassicLinkDnsSupportRequest generates a "aws/request.Request" representing the // client's request for the EnableVpcClassicLinkDnsSupport operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -16544,7 +16551,7 @@ const opGetConsoleOutput = "GetConsoleOutput" // GetConsoleOutputRequest generates a "aws/request.Request" representing the // client's request for the GetConsoleOutput operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -16635,7 +16642,7 @@ const opGetConsoleScreenshot = "GetConsoleScreenshot" // GetConsoleScreenshotRequest generates a "aws/request.Request" representing the // client's request for the GetConsoleScreenshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -16711,7 +16718,7 @@ const opGetHostReservationPurchasePreview = "GetHostReservationPurchasePreview" // GetHostReservationPurchasePreviewRequest generates a "aws/request.Request" representing the // client's request for the GetHostReservationPurchasePreview operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -16790,7 +16797,7 @@ const opGetLaunchTemplateData = "GetLaunchTemplateData" // GetLaunchTemplateDataRequest generates a "aws/request.Request" representing the // client's request for the GetLaunchTemplateData operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -16865,7 +16872,7 @@ const opGetPasswordData = "GetPasswordData" // GetPasswordDataRequest generates a "aws/request.Request" representing the // client's request for the GetPasswordData operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -16956,7 +16963,7 @@ const opGetReservedInstancesExchangeQuote = "GetReservedInstancesExchangeQuote" // GetReservedInstancesExchangeQuoteRequest generates a "aws/request.Request" representing the // client's request for the GetReservedInstancesExchangeQuote operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -17033,7 +17040,7 @@ const opImportImage = "ImportImage" // ImportImageRequest generates a "aws/request.Request" representing the // client's request for the ImportImage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -17110,7 +17117,7 @@ const opImportInstance = "ImportInstance" // ImportInstanceRequest generates a "aws/request.Request" representing the // client's request for the ImportInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -17190,7 +17197,7 @@ const opImportKeyPair = "ImportKeyPair" // ImportKeyPairRequest generates a "aws/request.Request" representing the // client's request for the ImportKeyPair operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -17271,7 +17278,7 @@ const opImportSnapshot = "ImportSnapshot" // ImportSnapshotRequest generates a "aws/request.Request" representing the // client's request for the ImportSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -17345,7 +17352,7 @@ const opImportVolume = "ImportVolume" // ImportVolumeRequest generates a "aws/request.Request" representing the // client's request for the ImportVolume operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -17423,7 +17430,7 @@ const opModifyFpgaImageAttribute = "ModifyFpgaImageAttribute" // ModifyFpgaImageAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifyFpgaImageAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -17497,7 +17504,7 @@ const opModifyHosts = "ModifyHosts" // ModifyHostsRequest generates a "aws/request.Request" representing the // client's request for the ModifyHosts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -17577,7 +17584,7 @@ const opModifyIdFormat = "ModifyIdFormat" // ModifyIdFormatRequest generates a "aws/request.Request" representing the // client's request for the ModifyIdFormat operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -17625,12 +17632,12 @@ func (c *EC2) ModifyIdFormatRequest(input *ModifyIdFormatInput) (req *request.Re // // This request can only be used to modify longer ID settings for resource types // that are within the opt-in period. Resources currently in their opt-in period -// include: bundle | conversion-task | dhcp-options | elastic-ip-allocation +// include: bundle | conversion-task | customer-gateway | dhcp-options | elastic-ip-allocation // | elastic-ip-association | export-task | flow-log | image | import-task | // internet-gateway | network-acl | network-acl-association | network-interface // | network-interface-attachment | prefix-list | route-table | route-table-association // | security-group | subnet | subnet-cidr-block-association | vpc | vpc-cidr-block-association -// | vpc-peering-connection. +// | vpc-endpoint | vpc-peering-connection | vpn-connection | vpn-gateway. // // This setting applies to the IAM user who makes the request; it does not apply // to the entire AWS account. By default, an IAM user defaults to the same settings @@ -17675,7 +17682,7 @@ const opModifyIdentityIdFormat = "ModifyIdentityIdFormat" // ModifyIdentityIdFormatRequest generates a "aws/request.Request" representing the // client's request for the ModifyIdentityIdFormat operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -17724,12 +17731,12 @@ func (c *EC2) ModifyIdentityIdFormatRequest(input *ModifyIdentityIdFormatInput) // // This request can only be used to modify longer ID settings for resource types // that are within the opt-in period. Resources currently in their opt-in period -// include: bundle | conversion-task | dhcp-options | elastic-ip-allocation +// include: bundle | conversion-task | customer-gateway | dhcp-options | elastic-ip-allocation // | elastic-ip-association | export-task | flow-log | image | import-task | // internet-gateway | network-acl | network-acl-association | network-interface // | network-interface-attachment | prefix-list | route-table | route-table-association // | security-group | subnet | subnet-cidr-block-association | vpc | vpc-cidr-block-association -// | vpc-peering-connection.. +// | vpc-endpoint | vpc-peering-connection | vpn-connection | vpn-gateway. // // For more information, see Resource IDs (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/resource-ids.html) // in the Amazon Elastic Compute Cloud User Guide. @@ -17773,7 +17780,7 @@ const opModifyImageAttribute = "ModifyImageAttribute" // ModifyImageAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifyImageAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -17858,7 +17865,7 @@ const opModifyInstanceAttribute = "ModifyInstanceAttribute" // ModifyInstanceAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifyInstanceAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -17939,7 +17946,7 @@ const opModifyInstanceCreditSpecification = "ModifyInstanceCreditSpecification" // ModifyInstanceCreditSpecificationRequest generates a "aws/request.Request" representing the // client's request for the ModifyInstanceCreditSpecification operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -18017,7 +18024,7 @@ const opModifyInstancePlacement = "ModifyInstancePlacement" // ModifyInstancePlacementRequest generates a "aws/request.Request" representing the // client's request for the ModifyInstancePlacement operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -18057,25 +18064,28 @@ func (c *EC2) ModifyInstancePlacementRequest(input *ModifyInstancePlacementInput // ModifyInstancePlacement API operation for Amazon Elastic Compute Cloud. // -// Set the instance affinity value for a specific stopped instance and modify -// the instance tenancy setting. +// Modifies the placement attributes for a specified instance. You can do the +// following: // -// Instance affinity is disabled by default. When instance affinity is host -// and it is not associated with a specific Dedicated Host, the next time it -// is launched it will automatically be associated with the host it lands on. -// This relationship will persist if the instance is stopped/started, or rebooted. +// * Modify the affinity between an instance and a Dedicated Host (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/dedicated-hosts-overview.html). +// When affinity is set to host and the instance is not associated with a +// specific Dedicated Host, the next time the instance is launched, it is +// automatically associated with the host on which it lands. If the instance +// is restarted or rebooted, this relationship persists. // -// You can modify the host ID associated with a stopped instance. If a stopped -// instance has a new host ID association, the instance will target that host -// when restarted. +// * Change the Dedicated Host with which an instance is associated. // -// You can modify the tenancy of a stopped instance with a tenancy of host or -// dedicated. +// * Change the instance tenancy of an instance from host to dedicated, or +// from dedicated to host. // -// Affinity, hostID, and tenancy are not required parameters, but at least one -// of them must be specified in the request. Affinity and tenancy can be modified -// in the same request, but tenancy can only be modified on instances that are -// stopped. +// * Move an instance to or from a placement group (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html). +// +// At least one attribute for affinity, host ID, tenancy, or placement group +// name must be specified in the request. Affinity and tenancy can be modified +// in the same request. +// +// To modify the host ID, tenancy, or placement group for an instance, the instance +// must be in the stopped state. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -18109,7 +18119,7 @@ const opModifyLaunchTemplate = "ModifyLaunchTemplate" // ModifyLaunchTemplateRequest generates a "aws/request.Request" representing the // client's request for the ModifyLaunchTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -18185,7 +18195,7 @@ const opModifyNetworkInterfaceAttribute = "ModifyNetworkInterfaceAttribute" // ModifyNetworkInterfaceAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifyNetworkInterfaceAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -18262,7 +18272,7 @@ const opModifyReservedInstances = "ModifyReservedInstances" // ModifyReservedInstancesRequest generates a "aws/request.Request" representing the // client's request for the ModifyReservedInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -18342,7 +18352,7 @@ const opModifySnapshotAttribute = "ModifySnapshotAttribute" // ModifySnapshotAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifySnapshotAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -18430,7 +18440,7 @@ const opModifySpotFleetRequest = "ModifySpotFleetRequest" // ModifySpotFleetRequestRequest generates a "aws/request.Request" representing the // client's request for the ModifySpotFleetRequest operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -18526,7 +18536,7 @@ const opModifySubnetAttribute = "ModifySubnetAttribute" // ModifySubnetAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifySubnetAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -18602,7 +18612,7 @@ const opModifyVolume = "ModifyVolume" // ModifyVolumeRequest generates a "aws/request.Request" representing the // client's request for the ModifyVolume operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -18708,7 +18718,7 @@ const opModifyVolumeAttribute = "ModifyVolumeAttribute" // ModifyVolumeAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifyVolumeAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -18793,7 +18803,7 @@ const opModifyVpcAttribute = "ModifyVpcAttribute" // ModifyVpcAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifyVpcAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -18869,7 +18879,7 @@ const opModifyVpcEndpoint = "ModifyVpcEndpoint" // ModifyVpcEndpointRequest generates a "aws/request.Request" representing the // client's request for the ModifyVpcEndpoint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -18946,7 +18956,7 @@ const opModifyVpcEndpointConnectionNotification = "ModifyVpcEndpointConnectionNo // ModifyVpcEndpointConnectionNotificationRequest generates a "aws/request.Request" representing the // client's request for the ModifyVpcEndpointConnectionNotification operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -19022,7 +19032,7 @@ const opModifyVpcEndpointServiceConfiguration = "ModifyVpcEndpointServiceConfigu // ModifyVpcEndpointServiceConfigurationRequest generates a "aws/request.Request" representing the // client's request for the ModifyVpcEndpointServiceConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -19099,7 +19109,7 @@ const opModifyVpcEndpointServicePermissions = "ModifyVpcEndpointServicePermissio // ModifyVpcEndpointServicePermissionsRequest generates a "aws/request.Request" representing the // client's request for the ModifyVpcEndpointServicePermissions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -19175,7 +19185,7 @@ const opModifyVpcPeeringConnectionOptions = "ModifyVpcPeeringConnectionOptions" // ModifyVpcPeeringConnectionOptionsRequest generates a "aws/request.Request" representing the // client's request for the ModifyVpcPeeringConnectionOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -19225,7 +19235,7 @@ func (c *EC2) ModifyVpcPeeringConnectionOptionsRequest(input *ModifyVpcPeeringCo // * Enable/disable communication over the peering connection between instances // in your VPC and an EC2-Classic instance that's linked to the peer VPC. // -// * Enable/disable a local VPC to resolve public DNS hostnames to private +// * Enable/disable the ability to resolve public DNS hostnames to private // IP addresses when queried from instances in the peer VPC. // // If the peered VPCs are in different accounts, each owner must initiate a @@ -19268,7 +19278,7 @@ const opModifyVpcTenancy = "ModifyVpcTenancy" // ModifyVpcTenancyRequest generates a "aws/request.Request" representing the // client's request for the ModifyVpcTenancy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -19351,7 +19361,7 @@ const opMonitorInstances = "MonitorInstances" // MonitorInstancesRequest generates a "aws/request.Request" representing the // client's request for the MonitorInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -19430,7 +19440,7 @@ const opMoveAddressToVpc = "MoveAddressToVpc" // MoveAddressToVpcRequest generates a "aws/request.Request" representing the // client's request for the MoveAddressToVpc operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -19510,7 +19520,7 @@ const opPurchaseHostReservation = "PurchaseHostReservation" // PurchaseHostReservationRequest generates a "aws/request.Request" representing the // client's request for the PurchaseHostReservation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -19587,7 +19597,7 @@ const opPurchaseReservedInstancesOffering = "PurchaseReservedInstancesOffering" // PurchaseReservedInstancesOfferingRequest generates a "aws/request.Request" representing the // client's request for the PurchaseReservedInstancesOffering operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -19670,7 +19680,7 @@ const opPurchaseScheduledInstances = "PurchaseScheduledInstances" // PurchaseScheduledInstancesRequest generates a "aws/request.Request" representing the // client's request for the PurchaseScheduledInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -19753,7 +19763,7 @@ const opRebootInstances = "RebootInstances" // RebootInstancesRequest generates a "aws/request.Request" representing the // client's request for the RebootInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -19839,7 +19849,7 @@ const opRegisterImage = "RegisterImage" // RegisterImageRequest generates a "aws/request.Request" representing the // client's request for the RegisterImage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -19941,7 +19951,7 @@ const opRejectVpcEndpointConnections = "RejectVpcEndpointConnections" // RejectVpcEndpointConnectionsRequest generates a "aws/request.Request" representing the // client's request for the RejectVpcEndpointConnections operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -20016,7 +20026,7 @@ const opRejectVpcPeeringConnection = "RejectVpcPeeringConnection" // RejectVpcPeeringConnectionRequest generates a "aws/request.Request" representing the // client's request for the RejectVpcPeeringConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -20094,7 +20104,7 @@ const opReleaseAddress = "ReleaseAddress" // ReleaseAddressRequest generates a "aws/request.Request" representing the // client's request for the ReleaseAddress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -20187,7 +20197,7 @@ const opReleaseHosts = "ReleaseHosts" // ReleaseHostsRequest generates a "aws/request.Request" representing the // client's request for the ReleaseHosts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -20272,7 +20282,7 @@ const opReplaceIamInstanceProfileAssociation = "ReplaceIamInstanceProfileAssocia // ReplaceIamInstanceProfileAssociationRequest generates a "aws/request.Request" representing the // client's request for the ReplaceIamInstanceProfileAssociation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -20351,7 +20361,7 @@ const opReplaceNetworkAclAssociation = "ReplaceNetworkAclAssociation" // ReplaceNetworkAclAssociationRequest generates a "aws/request.Request" representing the // client's request for the ReplaceNetworkAclAssociation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -20430,7 +20440,7 @@ const opReplaceNetworkAclEntry = "ReplaceNetworkAclEntry" // ReplaceNetworkAclEntryRequest generates a "aws/request.Request" representing the // client's request for the ReplaceNetworkAclEntry operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -20508,7 +20518,7 @@ const opReplaceRoute = "ReplaceRoute" // ReplaceRouteRequest generates a "aws/request.Request" representing the // client's request for the ReplaceRoute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -20590,7 +20600,7 @@ const opReplaceRouteTableAssociation = "ReplaceRouteTableAssociation" // ReplaceRouteTableAssociationRequest generates a "aws/request.Request" representing the // client's request for the ReplaceRouteTableAssociation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -20672,7 +20682,7 @@ const opReportInstanceStatus = "ReportInstanceStatus" // ReportInstanceStatusRequest generates a "aws/request.Request" representing the // client's request for the ReportInstanceStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -20754,7 +20764,7 @@ const opRequestSpotFleet = "RequestSpotFleet" // RequestSpotFleetRequest generates a "aws/request.Request" representing the // client's request for the RequestSpotFleet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -20847,7 +20857,7 @@ const opRequestSpotInstances = "RequestSpotInstances" // RequestSpotInstancesRequest generates a "aws/request.Request" representing the // client's request for the RequestSpotInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -20924,7 +20934,7 @@ const opResetFpgaImageAttribute = "ResetFpgaImageAttribute" // ResetFpgaImageAttributeRequest generates a "aws/request.Request" representing the // client's request for the ResetFpgaImageAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -20999,7 +21009,7 @@ const opResetImageAttribute = "ResetImageAttribute" // ResetImageAttributeRequest generates a "aws/request.Request" representing the // client's request for the ResetImageAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -21077,7 +21087,7 @@ const opResetInstanceAttribute = "ResetInstanceAttribute" // ResetInstanceAttributeRequest generates a "aws/request.Request" representing the // client's request for the ResetInstanceAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -21161,7 +21171,7 @@ const opResetNetworkInterfaceAttribute = "ResetNetworkInterfaceAttribute" // ResetNetworkInterfaceAttributeRequest generates a "aws/request.Request" representing the // client's request for the ResetNetworkInterfaceAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -21238,7 +21248,7 @@ const opResetSnapshotAttribute = "ResetSnapshotAttribute" // ResetSnapshotAttributeRequest generates a "aws/request.Request" representing the // client's request for the ResetSnapshotAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -21318,7 +21328,7 @@ const opRestoreAddressToClassic = "RestoreAddressToClassic" // RestoreAddressToClassicRequest generates a "aws/request.Request" representing the // client's request for the RestoreAddressToClassic operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -21395,7 +21405,7 @@ const opRevokeSecurityGroupEgress = "RevokeSecurityGroupEgress" // RevokeSecurityGroupEgressRequest generates a "aws/request.Request" representing the // client's request for the RevokeSecurityGroupEgress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -21483,7 +21493,7 @@ const opRevokeSecurityGroupIngress = "RevokeSecurityGroupIngress" // RevokeSecurityGroupIngressRequest generates a "aws/request.Request" representing the // client's request for the RevokeSecurityGroupIngress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -21574,7 +21584,7 @@ const opRunInstances = "RunInstances" // RunInstancesRequest generates a "aws/request.Request" representing the // client's request for the RunInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -21701,7 +21711,7 @@ const opRunScheduledInstances = "RunScheduledInstances" // RunScheduledInstancesRequest generates a "aws/request.Request" representing the // client's request for the RunScheduledInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -21785,7 +21795,7 @@ const opStartInstances = "StartInstances" // StartInstancesRequest generates a "aws/request.Request" representing the // client's request for the StartInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -21881,7 +21891,7 @@ const opStopInstances = "StopInstances" // StopInstancesRequest generates a "aws/request.Request" representing the // client's request for the StopInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -21987,7 +21997,7 @@ const opTerminateInstances = "TerminateInstances" // TerminateInstancesRequest generates a "aws/request.Request" representing the // client's request for the TerminateInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -22085,7 +22095,7 @@ const opUnassignIpv6Addresses = "UnassignIpv6Addresses" // UnassignIpv6AddressesRequest generates a "aws/request.Request" representing the // client's request for the UnassignIpv6Addresses operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -22159,7 +22169,7 @@ const opUnassignPrivateIpAddresses = "UnassignPrivateIpAddresses" // UnassignPrivateIpAddressesRequest generates a "aws/request.Request" representing the // client's request for the UnassignPrivateIpAddresses operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -22235,7 +22245,7 @@ const opUnmonitorInstances = "UnmonitorInstances" // UnmonitorInstancesRequest generates a "aws/request.Request" representing the // client's request for the UnmonitorInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -22311,7 +22321,7 @@ const opUpdateSecurityGroupRuleDescriptionsEgress = "UpdateSecurityGroupRuleDesc // UpdateSecurityGroupRuleDescriptionsEgressRequest generates a "aws/request.Request" representing the // client's request for the UpdateSecurityGroupRuleDescriptionsEgress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -22391,7 +22401,7 @@ const opUpdateSecurityGroupRuleDescriptionsIngress = "UpdateSecurityGroupRuleDes // UpdateSecurityGroupRuleDescriptionsIngressRequest generates a "aws/request.Request" representing the // client's request for the UpdateSecurityGroupRuleDescriptionsIngress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -26422,7 +26432,7 @@ type CopyImageInput struct { // // * Key ID // - // * Key alias + // * Key alias, in the form alias/ExampleAlias // // * ARN using key ID. The ID ARN contains the arn:aws:kms namespace, followed // by the region of the CMK, the AWS account ID of the CMK owner, the key @@ -26618,15 +26628,16 @@ type CopySnapshotInput struct { // will eventually fail. KmsKeyId *string `locationName:"kmsKeyId" type:"string"` - // The pre-signed URL that facilitates copying an encrypted snapshot. This parameter - // is only required when copying an encrypted snapshot with the Amazon EC2 Query - // API; it is available as an optional parameter in all other cases. The PresignedUrl - // should use the snapshot source endpoint, the CopySnapshot action, and include - // the SourceRegion, SourceSnapshotId, and DestinationRegion parameters. The - // PresignedUrl must be signed using AWS Signature Version 4. Because EBS snapshots - // are stored in Amazon S3, the signing algorithm for this parameter uses the - // same logic that is described in Authenticating Requests by Using Query Parameters - // (AWS Signature Version 4) (http://docs.aws.amazon.com/AmazonS3/latest/API/sigv4-query-string-auth.html) + // The pre-signed URL parameter is required when copying an encrypted snapshot + // with the Amazon EC2 Query API; it is available as an optional parameter in + // all other cases. For more information, see Query Requests (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Query-Requests.html). + // + // The PresignedUrl should use the snapshot source endpoint, the CopySnapshot + // action, and include the SourceRegion, SourceSnapshotId, and DestinationRegion + // parameters. The PresignedUrl must be signed using AWS Signature Version 4. + // Because EBS snapshots are stored in Amazon S3, the signing algorithm for + // this parameter uses the same logic that is described in Authenticating Requests + // by Using Query Parameters (AWS Signature Version 4) (http://docs.aws.amazon.com/AmazonS3/latest/API/sigv4-query-string-auth.html) // in the Amazon Simple Storage Service API Reference. An invalid or improperly // signed PresignedUrl will cause the copy operation to fail asynchronously, // and the snapshot will move to an error state. @@ -29174,6 +29185,9 @@ type CreateSnapshotInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` + // The tags to apply to the snapshot during creation. + TagSpecifications []*TagSpecification `locationName:"TagSpecification" locationNameList:"item" type:"list"` + // The ID of the EBS volume. // // VolumeId is a required field @@ -29215,6 +29229,12 @@ func (s *CreateSnapshotInput) SetDryRun(v bool) *CreateSnapshotInput { return s } +// SetTagSpecifications sets the TagSpecifications field's value. +func (s *CreateSnapshotInput) SetTagSpecifications(v []*TagSpecification) *CreateSnapshotInput { + s.TagSpecifications = v + return s +} + // SetVolumeId sets the VolumeId field's value. func (s *CreateSnapshotInput) SetVolumeId(v string) *CreateSnapshotInput { s.VolumeId = &v @@ -32330,12 +32350,14 @@ type DeleteTagsInput struct { // Resources is a required field Resources []*string `locationName:"resourceId" type:"list" required:"true"` - // One or more tags to delete. If you omit this parameter, we delete all tags - // for the specified resources. Specify a tag key and an optional tag value - // to delete specific tags. If you specify a tag key without a tag value, we - // delete any tag with this key regardless of its value. If you specify a tag - // key with an empty string as the tag value, we delete the tag only if its - // value is an empty string. + // One or more tags to delete. Specify a tag key and an optional tag value to + // delete specific tags. If you specify a tag key without a tag value, we delete + // any tag with this key regardless of its value. If you specify a tag key with + // an empty string as the tag value, we delete the tag only if its value is + // an empty string. + // + // If you omit this parameter, we delete all user-defined tags for the specified + // resources. We do not delete AWS-generated tags (tags that have the aws: prefix). Tags []*Tag `locationName:"tag" locationNameList:"item" type:"list"` } @@ -34885,12 +34907,13 @@ func (s *DescribeIamInstanceProfileAssociationsOutput) SetNextToken(v string) *D type DescribeIdFormatInput struct { _ struct{} `type:"structure"` - // The type of resource: bundle | conversion-task | dhcp-options | elastic-ip-allocation - // | elastic-ip-association | export-task | flow-log | image | import-task | - // instance | internet-gateway | network-acl | network-acl-association | network-interface - // | network-interface-attachment | prefix-list | reservation | route-table - // | route-table-association | security-group | snapshot | subnet | subnet-cidr-block-association - // | volume | vpc | vpc-cidr-block-association | vpc-peering-connection + // The type of resource: bundle | conversion-task | customer-gateway | dhcp-options + // | elastic-ip-allocation | elastic-ip-association | export-task | flow-log + // | image | import-task | instance | internet-gateway | network-acl | network-acl-association + // | network-interface | network-interface-attachment | prefix-list | reservation + // | route-table | route-table-association | security-group | snapshot | subnet + // | subnet-cidr-block-association | volume | vpc | vpc-cidr-block-association + // | vpc-endpoint | vpc-peering-connection | vpn-connection | vpn-gateway Resource *string `type:"string"` } @@ -34944,12 +34967,13 @@ type DescribeIdentityIdFormatInput struct { // PrincipalArn is a required field PrincipalArn *string `locationName:"principalArn" type:"string" required:"true"` - // The type of resource: bundle | conversion-task | dhcp-options | elastic-ip-allocation - // | elastic-ip-association | export-task | flow-log | image | import-task | - // instance | internet-gateway | network-acl | network-acl-association | network-interface - // | network-interface-attachment | prefix-list | reservation | route-table - // | route-table-association | security-group | snapshot | subnet | subnet-cidr-block-association - // | volume | vpc | vpc-cidr-block-association | vpc-peering-connection + // The type of resource: bundle | conversion-task | customer-gateway | dhcp-options + // | elastic-ip-allocation | elastic-ip-association | export-task | flow-log + // | image | import-task | instance | internet-gateway | network-acl | network-acl-association + // | network-interface | network-interface-attachment | prefix-list | reservation + // | route-table | route-table-association | security-group | snapshot | subnet + // | subnet-cidr-block-association | volume | vpc | vpc-cidr-block-association + // | vpc-endpoint | vpc-peering-connection | vpn-connection | vpn-gateway Resource *string `locationName:"resource" type:"string"` } @@ -37761,12 +37785,13 @@ type DescribePrincipalIdFormatInput struct { // The token to request the next page of results. NextToken *string `type:"string"` - // The type of resource: bundle | conversion-task | dhcp-options | elastic-ip-allocation - // | elastic-ip-association | export-task | flow-log | image | import-task | - // instance | internet-gateway | network-acl | network-acl-association | network-interface - // | network-interface-attachment | prefix-list | reservation | route-table - // | route-table-association | security-group | snapshot | subnet | subnet-cidr-block-association - // | volume | vpc | vpc-cidr-block-association | vpc-peering-connection + // The type of resource: bundle | conversion-task | customer-gateway | dhcp-options + // | elastic-ip-allocation | elastic-ip-association | export-task | flow-log + // | image | import-task | instance | internet-gateway | network-acl | network-acl-association + // | network-interface | network-interface-attachment | prefix-list | reservation + // | route-table | route-table-association | security-group | snapshot | subnet + // | subnet-cidr-block-association | volume | vpc | vpc-cidr-block-association + // | vpc-endpoint | vpc-peering-connection | vpn-connection | vpn-gateway Resources []*string `locationName:"Resource" locationNameList:"item" type:"list"` } @@ -40160,8 +40185,8 @@ func (s *DescribeSpotPriceHistoryInput) SetStartTime(v time.Time) *DescribeSpotP type DescribeSpotPriceHistoryOutput struct { _ struct{} `type:"structure"` - // The token required to retrieve the next set of results. This value is an - // empty string when there are no more results to return. + // The token required to retrieve the next set of results. This value is null + // or an empty string when there are no more results to return. NextToken *string `locationName:"nextToken" type:"string"` // The historical Spot prices. @@ -51735,12 +51760,13 @@ func (s *ModifyHostsOutput) SetUnsuccessful(v []*UnsuccessfulItem) *ModifyHostsO type ModifyIdFormatInput struct { _ struct{} `type:"structure"` - // The type of resource: bundle | conversion-task | dhcp-options | elastic-ip-allocation - // | elastic-ip-association | export-task | flow-log | image | import-task | - // internet-gateway | network-acl | network-acl-association | network-interface - // | network-interface-attachment | prefix-list | route-table | route-table-association - // | security-group | subnet | subnet-cidr-block-association | vpc | vpc-cidr-block-association - // | vpc-peering-connection. + // The type of resource: bundle | conversion-task | customer-gateway | dhcp-options + // | elastic-ip-allocation | elastic-ip-association | export-task | flow-log + // | image | import-task | internet-gateway | network-acl | network-acl-association + // | network-interface | network-interface-attachment | prefix-list | route-table + // | route-table-association | security-group | subnet | subnet-cidr-block-association + // | vpc | vpc-cidr-block-association | vpc-endpoint | vpc-peering-connection + // | vpn-connection | vpn-gateway. // // Alternatively, use the all-current option to include all resource types that // are currently within their opt-in period for longer IDs. @@ -51817,12 +51843,13 @@ type ModifyIdentityIdFormatInput struct { // PrincipalArn is a required field PrincipalArn *string `locationName:"principalArn" type:"string" required:"true"` - // The type of resource: bundle | conversion-task | dhcp-options | elastic-ip-allocation - // | elastic-ip-association | export-task | flow-log | image | import-task | - // internet-gateway | network-acl | network-acl-association | network-interface - // | network-interface-attachment | prefix-list | route-table | route-table-association - // | security-group | subnet | subnet-cidr-block-association | vpc | vpc-cidr-block-association - // | vpc-peering-connection. + // The type of resource: bundle | conversion-task | customer-gateway | dhcp-options + // | elastic-ip-allocation | elastic-ip-association | export-task | flow-log + // | image | import-task | internet-gateway | network-acl | network-acl-association + // | network-interface | network-interface-attachment | prefix-list | route-table + // | route-table-association | security-group | subnet | subnet-cidr-block-association + // | vpc | vpc-cidr-block-association | vpc-endpoint | vpc-peering-connection + // | vpn-connection | vpn-gateway. // // Alternatively, use the all-current option to include all resource types that // are currently within their opt-in period for longer IDs. @@ -52369,10 +52396,17 @@ func (s *ModifyInstanceCreditSpecificationOutput) SetUnsuccessfulInstanceCreditS type ModifyInstancePlacementInput struct { _ struct{} `type:"structure"` - // The new affinity setting for the instance. + // The affinity setting for the instance. Affinity *string `locationName:"affinity" type:"string" enum:"Affinity"` - // The ID of the Dedicated Host that the instance will have affinity with. + // The name of the placement group in which to place the instance. For spread + // placement groups, the instance must have a tenancy of default. For cluster + // placement groups, the instance must have a tenancy of default or dedicated. + // + // To remove an instance from a placement group, specify an empty string (""). + GroupName *string `type:"string"` + + // The ID of the Dedicated Host with which to associate the instance. HostId *string `locationName:"hostId" type:"string"` // The ID of the instance that you are modifying. @@ -52380,7 +52414,7 @@ type ModifyInstancePlacementInput struct { // InstanceId is a required field InstanceId *string `locationName:"instanceId" type:"string" required:"true"` - // The tenancy of the instance that you are modifying. + // The tenancy for the instance. Tenancy *string `locationName:"tenancy" type:"string" enum:"HostTenancy"` } @@ -52413,6 +52447,12 @@ func (s *ModifyInstancePlacementInput) SetAffinity(v string) *ModifyInstancePlac return s } +// SetGroupName sets the GroupName field's value. +func (s *ModifyInstancePlacementInput) SetGroupName(v string) *ModifyInstancePlacementInput { + s.GroupName = &v + return s +} + // SetHostId sets the HostId field's value. func (s *ModifyInstancePlacementInput) SetHostId(v string) *ModifyInstancePlacementInput { s.HostId = &v @@ -53128,6 +53168,8 @@ type ModifyVolumeInput struct { // Default: If no size is specified, the existing size is retained. Size *int64 `type:"integer"` + // The ID of the volume. + // // VolumeId is a required field VolumeId *string `type:"string" required:"true"` @@ -55192,8 +55234,8 @@ func (s *PciId) SetVendorId(v string) *PciId { type PeeringConnectionOptions struct { _ struct{} `type:"structure"` - // If true, enables a local VPC to resolve public DNS hostnames to private IP - // addresses when queried from instances in the peer VPC. + // If true, the public DNS hostnames of instances in the specified VPC resolve + // to private IP addresses when queried from instances in the peer VPC. AllowDnsResolutionFromRemoteVpc *bool `locationName:"allowDnsResolutionFromRemoteVpc" type:"boolean"` // If true, enables outbound communication from an EC2-Classic instance that's diff --git a/vendor/github.com/aws/aws-sdk-go/service/ec2/customizations.go b/vendor/github.com/aws/aws-sdk-go/service/ec2/customizations.go index 36b69ff28146..7b42719d6533 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/ec2/customizations.go +++ b/vendor/github.com/aws/aws-sdk-go/service/ec2/customizations.go @@ -5,11 +5,64 @@ import ( "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awsutil" + "github.com/aws/aws-sdk-go/aws/client" "github.com/aws/aws-sdk-go/aws/endpoints" "github.com/aws/aws-sdk-go/aws/request" + "github.com/aws/aws-sdk-go/internal/sdkrand" ) +type retryer struct { + client.DefaultRetryer +} + +func (d retryer) RetryRules(r *request.Request) time.Duration { + switch r.Operation.Name { + case opModifyNetworkInterfaceAttribute: + fallthrough + case opAssignPrivateIpAddresses: + return customRetryRule(r) + default: + return d.DefaultRetryer.RetryRules(r) + } +} + +func customRetryRule(r *request.Request) time.Duration { + retryTimes := []time.Duration{ + time.Second, + 3 * time.Second, + 5 * time.Second, + } + + count := r.RetryCount + if count >= len(retryTimes) { + count = len(retryTimes) - 1 + } + + minTime := int(retryTimes[count]) + return time.Duration(sdkrand.SeededRand.Intn(minTime) + minTime) +} + +func setCustomRetryer(c *client.Client) { + maxRetries := aws.IntValue(c.Config.MaxRetries) + if c.Config.MaxRetries == nil || maxRetries == aws.UseServiceDefaultRetries { + maxRetries = 3 + } + + c.Retryer = retryer{ + DefaultRetryer: client.DefaultRetryer{ + NumMaxRetries: maxRetries, + }, + } +} + func init() { + initClient = func(c *client.Client) { + if c.Config.Retryer == nil { + // Only override the retryer with a custom one if the config + // does not already contain a retryer + setCustomRetryer(c) + } + } initRequest = func(r *request.Request) { if r.Operation.Name == opCopySnapshot { // fill the PresignedURL parameter r.Handlers.Build.PushFront(fillPresignedURL) diff --git a/vendor/github.com/aws/aws-sdk-go/service/ecr/api.go b/vendor/github.com/aws/aws-sdk-go/service/ecr/api.go index bf9630e4cb1a..d9bcf883b756 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/ecr/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/ecr/api.go @@ -14,7 +14,7 @@ const opBatchCheckLayerAvailability = "BatchCheckLayerAvailability" // BatchCheckLayerAvailabilityRequest generates a "aws/request.Request" representing the // client's request for the BatchCheckLayerAvailability operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -106,7 +106,7 @@ const opBatchDeleteImage = "BatchDeleteImage" // BatchDeleteImageRequest generates a "aws/request.Request" representing the // client's request for the BatchDeleteImage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -201,7 +201,7 @@ const opBatchGetImage = "BatchGetImage" // BatchGetImageRequest generates a "aws/request.Request" representing the // client's request for the BatchGetImage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -289,7 +289,7 @@ const opCompleteLayerUpload = "CompleteLayerUpload" // CompleteLayerUploadRequest generates a "aws/request.Request" representing the // client's request for the CompleteLayerUpload operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -399,7 +399,7 @@ const opCreateRepository = "CreateRepository" // CreateRepositoryRequest generates a "aws/request.Request" representing the // client's request for the CreateRepository operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -463,7 +463,7 @@ func (c *ECR) CreateRepositoryRequest(input *CreateRepositoryInput) (req *reques // The operation did not succeed because it would have exceeded a service limit // for your account. For more information, see Amazon ECR Default Service Limits // (http://docs.aws.amazon.com/AmazonECR/latest/userguide/service_limits.html) -// in the Amazon EC2 Container Registry User Guide. +// in the Amazon Elastic Container Registry User Guide. // // See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/CreateRepository func (c *ECR) CreateRepository(input *CreateRepositoryInput) (*CreateRepositoryOutput, error) { @@ -491,7 +491,7 @@ const opDeleteLifecyclePolicy = "DeleteLifecyclePolicy" // DeleteLifecyclePolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteLifecyclePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -581,7 +581,7 @@ const opDeleteRepository = "DeleteRepository" // DeleteRepositoryRequest generates a "aws/request.Request" representing the // client's request for the DeleteRepository operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -673,7 +673,7 @@ const opDeleteRepositoryPolicy = "DeleteRepositoryPolicy" // DeleteRepositoryPolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteRepositoryPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -764,7 +764,7 @@ const opDescribeImages = "DescribeImages" // DescribeImagesRequest generates a "aws/request.Request" representing the // client's request for the DescribeImages operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -916,7 +916,7 @@ const opDescribeRepositories = "DescribeRepositories" // DescribeRepositoriesRequest generates a "aws/request.Request" representing the // client's request for the DescribeRepositories operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1059,7 +1059,7 @@ const opGetAuthorizationToken = "GetAuthorizationToken" // GetAuthorizationTokenRequest generates a "aws/request.Request" representing the // client's request for the GetAuthorizationToken operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1149,7 +1149,7 @@ const opGetDownloadUrlForLayer = "GetDownloadUrlForLayer" // GetDownloadUrlForLayerRequest generates a "aws/request.Request" representing the // client's request for the GetDownloadUrlForLayer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1249,7 +1249,7 @@ const opGetLifecyclePolicy = "GetLifecyclePolicy" // GetLifecyclePolicyRequest generates a "aws/request.Request" representing the // client's request for the GetLifecyclePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1339,7 +1339,7 @@ const opGetLifecyclePolicyPreview = "GetLifecyclePolicyPreview" // GetLifecyclePolicyPreviewRequest generates a "aws/request.Request" representing the // client's request for the GetLifecyclePolicyPreview operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1429,7 +1429,7 @@ const opGetRepositoryPolicy = "GetRepositoryPolicy" // GetRepositoryPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetRepositoryPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1520,7 +1520,7 @@ const opInitiateLayerUpload = "InitiateLayerUpload" // InitiateLayerUploadRequest generates a "aws/request.Request" representing the // client's request for the InitiateLayerUpload operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1611,7 +1611,7 @@ const opListImages = "ListImages" // ListImagesRequest generates a "aws/request.Request" representing the // client's request for the ListImages operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1760,7 +1760,7 @@ const opPutImage = "PutImage" // PutImageRequest generates a "aws/request.Request" representing the // client's request for the PutImage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1837,7 +1837,7 @@ func (c *ECR) PutImageRequest(input *PutImageInput) (req *request.Request, outpu // The operation did not succeed because it would have exceeded a service limit // for your account. For more information, see Amazon ECR Default Service Limits // (http://docs.aws.amazon.com/AmazonECR/latest/userguide/service_limits.html) -// in the Amazon EC2 Container Registry User Guide. +// in the Amazon Elastic Container Registry User Guide. // // See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/PutImage func (c *ECR) PutImage(input *PutImageInput) (*PutImageOutput, error) { @@ -1865,7 +1865,7 @@ const opPutLifecyclePolicy = "PutLifecyclePolicy" // PutLifecyclePolicyRequest generates a "aws/request.Request" representing the // client's request for the PutLifecyclePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1905,7 +1905,8 @@ func (c *ECR) PutLifecyclePolicyRequest(input *PutLifecyclePolicyInput) (req *re // PutLifecyclePolicy API operation for Amazon EC2 Container Registry. // -// Creates or updates a lifecycle policy. +// Creates or updates a lifecycle policy. For information about lifecycle policy +// syntax, see Lifecycle Policy Template (http://docs.aws.amazon.com/AmazonECR/latest/userguide/LifecyclePolicies.html). // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -1952,7 +1953,7 @@ const opSetRepositoryPolicy = "SetRepositoryPolicy" // SetRepositoryPolicyRequest generates a "aws/request.Request" representing the // client's request for the SetRepositoryPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2039,7 +2040,7 @@ const opStartLifecyclePolicyPreview = "StartLifecyclePolicyPreview" // StartLifecyclePolicyPreviewRequest generates a "aws/request.Request" representing the // client's request for the StartLifecyclePolicyPreview operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2134,7 +2135,7 @@ const opUploadLayerPart = "UploadLayerPart" // UploadLayerPartRequest generates a "aws/request.Request" representing the // client's request for the UploadLayerPart operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2211,7 +2212,7 @@ func (c *ECR) UploadLayerPartRequest(input *UploadLayerPartInput) (req *request. // The operation did not succeed because it would have exceeded a service limit // for your account. For more information, see Amazon ECR Default Service Limits // (http://docs.aws.amazon.com/AmazonECR/latest/userguide/service_limits.html) -// in the Amazon EC2 Container Registry User Guide. +// in the Amazon Elastic Container Registry User Guide. // // See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/UploadLayerPart func (c *ECR) UploadLayerPart(input *UploadLayerPartInput) (*UploadLayerPartOutput, error) { @@ -2808,8 +2809,7 @@ type DeleteLifecyclePolicyInput struct { // If you do not specify a registry, the default registry is assumed. RegistryId *string `locationName:"registryId" type:"string"` - // The name of the repository that is associated with the repository policy - // to
 delete. + // The name of the repository. // // RepositoryName is a required field RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"` @@ -2859,7 +2859,7 @@ type DeleteLifecyclePolicyOutput struct { // The time stamp of the last time that the lifecycle policy was run. LastEvaluatedAt *time.Time `locationName:"lastEvaluatedAt" type:"timestamp" timestampFormat:"unix"` - // The JSON repository policy text. + // The JSON lifecycle policy text. LifecyclePolicyText *string `locationName:"lifecyclePolicyText" min:"100" type:"string"` // The registry ID associated with the request. @@ -3120,13 +3120,15 @@ type DescribeImagesInput struct { // results of the initial request can be seen by sending another DescribeImages // request with the returned nextToken value. This value can be between 1 and // 100. If this parameter is not used, then DescribeImages returns up to 100 - // results and a nextToken value, if applicable. + // results and a nextToken value, if applicable. This option cannot be used + // when you specify images with imageIds. MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` // The nextToken value returned from a previous paginated DescribeImages request // where maxResults was used and the results exceeded the value of that parameter. // Pagination continues from the end of the previous results that returned the // nextToken value. This value is null when there are no more results to return. + // This option cannot be used when you specify images with imageIds. NextToken *string `locationName:"nextToken" type:"string"` // The AWS account ID associated with the registry that contains the repository @@ -3253,14 +3255,16 @@ type DescribeRepositoriesInput struct { // element. The remaining results of the initial request can be seen by sending // another DescribeRepositories request with the returned nextToken value. This // value can be between 1 and 100. If this parameter is not used, then DescribeRepositories - // returns up to 100 results and a nextToken value, if applicable. + // returns up to 100 results and a nextToken value, if applicable. This option + // cannot be used when you specify repositories with repositoryNames. MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` // The nextToken value returned from a previous paginated DescribeRepositories // request where maxResults was used and the results exceeded the value of that // parameter. Pagination continues from the end of the previous results that // returned the nextToken value. This value is null when there are no more results - // to return. + // to return. This option cannot be used when you specify repositories with + // repositoryNames. // // This token should be treated as an opaque identifier that is only used to // retrieve the next items in a list and not for other programmatic purposes. @@ -3527,7 +3531,7 @@ type GetLifecyclePolicyInput struct { // If you do not specify a registry, the default registry is assumed. RegistryId *string `locationName:"registryId" type:"string"` - // The name of the repository with the policy to retrieve. + // The name of the repository. // // RepositoryName is a required field RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"` @@ -3577,7 +3581,7 @@ type GetLifecyclePolicyOutput struct { // The time stamp of the last time that the lifecycle policy was run. LastEvaluatedAt *time.Time `locationName:"lastEvaluatedAt" type:"timestamp" timestampFormat:"unix"` - // The JSON repository policy text. + // The JSON lifecycle policy text. LifecyclePolicyText *string `locationName:"lifecyclePolicyText" min:"100" type:"string"` // The registry ID associated with the request. @@ -3638,21 +3642,23 @@ type GetLifecyclePolicyPreviewInput struct { // by sending
 another GetLifecyclePolicyPreviewRequest request with the returned // nextToken
 value. This value can be between 1 and 100. If this
 parameter // is not used, then GetLifecyclePolicyPreviewRequest returns up to
 100 results - // and a nextToken value, if
 applicable. + // and a nextToken value, if
 applicable. This option cannot be used when you + // specify images with imageIds. MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` // The nextToken value returned from a previous paginated
 GetLifecyclePolicyPreviewRequest // request where maxResults was used and the
 results exceeded the value of // that parameter. Pagination continues from the end of the
 previous results // that returned the nextToken value. This value is
 null when there are no - // more results to return. + // more results to return. This option cannot be used when you specify images + // with imageIds. NextToken *string `locationName:"nextToken" type:"string"` // The AWS account ID associated with the registry that contains the repository. // If you do not specify a registry, the default registry is assumed. RegistryId *string `locationName:"registryId" type:"string"` - // The name of the repository with the policy to retrieve. + // The name of the repository. // // RepositoryName is a required field RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"` @@ -3729,7 +3735,7 @@ func (s *GetLifecyclePolicyPreviewInput) SetRepositoryName(v string) *GetLifecyc type GetLifecyclePolicyPreviewOutput struct { _ struct{} `type:"structure"` - // The JSON repository policy text. + // The JSON lifecycle policy text. LifecyclePolicyText *string `locationName:"lifecyclePolicyText" min:"100" type:"string"` // The nextToken value to include in a future GetLifecyclePolicyPreview request. diff --git a/vendor/github.com/aws/aws-sdk-go/service/ecr/doc.go b/vendor/github.com/aws/aws-sdk-go/service/ecr/doc.go index a2aea0f6ea1c..d970974bcda6 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/ecr/doc.go +++ b/vendor/github.com/aws/aws-sdk-go/service/ecr/doc.go @@ -3,11 +3,11 @@ // Package ecr provides the client and types for making API // requests to Amazon EC2 Container Registry. // -// Amazon EC2 Container Registry (Amazon ECR) is a managed Docker registry service. -// Customers can use the familiar Docker CLI to push, pull, and manage images. -// Amazon ECR provides a secure, scalable, and reliable registry. Amazon ECR -// supports private Docker repositories with resource-based permissions using -// IAM so that specific users or Amazon EC2 instances can access repositories +// Amazon Elastic Container Registry (Amazon ECR) is a managed Docker registry +// service. Customers can use the familiar Docker CLI to push, pull, and manage +// images. Amazon ECR provides a secure, scalable, and reliable registry. Amazon +// ECR supports private Docker repositories with resource-based permissions +// using IAM so that specific users or Amazon EC2 instances can access repositories // and images. Developers can use the Docker CLI to author and manage images. // // See https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21 for more information on this service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/ecr/errors.go b/vendor/github.com/aws/aws-sdk-go/service/ecr/errors.go index 2a2caaeddc44..09e0595de718 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/ecr/errors.go +++ b/vendor/github.com/aws/aws-sdk-go/service/ecr/errors.go @@ -95,7 +95,7 @@ const ( // The operation did not succeed because it would have exceeded a service limit // for your account. For more information, see Amazon ECR Default Service Limits // (http://docs.aws.amazon.com/AmazonECR/latest/userguide/service_limits.html) - // in the Amazon EC2 Container Registry User Guide. + // in the Amazon Elastic Container Registry User Guide. ErrCodeLimitExceededException = "LimitExceededException" // ErrCodeRepositoryAlreadyExistsException for service response error code diff --git a/vendor/github.com/aws/aws-sdk-go/service/ecs/api.go b/vendor/github.com/aws/aws-sdk-go/service/ecs/api.go index 7a7b33abb06a..f6e48bfd7689 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/ecs/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/ecs/api.go @@ -15,7 +15,7 @@ const opCreateCluster = "CreateCluster" // CreateClusterRequest generates a "aws/request.Request" representing the // client's request for the CreateCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -113,7 +113,7 @@ const opCreateService = "CreateService" // CreateServiceRequest generates a "aws/request.Request" representing the // client's request for the CreateService operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -276,7 +276,7 @@ const opDeleteAttributes = "DeleteAttributes" // DeleteAttributesRequest generates a "aws/request.Request" representing the // client's request for the DeleteAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -365,7 +365,7 @@ const opDeleteCluster = "DeleteCluster" // DeleteClusterRequest generates a "aws/request.Request" representing the // client's request for the DeleteCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -472,7 +472,7 @@ const opDeleteService = "DeleteService" // DeleteServiceRequest generates a "aws/request.Request" representing the // client's request for the DeleteService operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -581,7 +581,7 @@ const opDeregisterContainerInstance = "DeregisterContainerInstance" // DeregisterContainerInstanceRequest generates a "aws/request.Request" representing the // client's request for the DeregisterContainerInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -687,7 +687,7 @@ const opDeregisterTaskDefinition = "DeregisterTaskDefinition" // DeregisterTaskDefinitionRequest generates a "aws/request.Request" representing the // client's request for the DeregisterTaskDefinition operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -789,7 +789,7 @@ const opDescribeClusters = "DescribeClusters" // DescribeClustersRequest generates a "aws/request.Request" representing the // client's request for the DescribeClusters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -877,7 +877,7 @@ const opDescribeContainerInstances = "DescribeContainerInstances" // DescribeContainerInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeContainerInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -970,7 +970,7 @@ const opDescribeServices = "DescribeServices" // DescribeServicesRequest generates a "aws/request.Request" representing the // client's request for the DescribeServices operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1062,7 +1062,7 @@ const opDescribeTaskDefinition = "DescribeTaskDefinition" // DescribeTaskDefinitionRequest generates a "aws/request.Request" representing the // client's request for the DescribeTaskDefinition operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1155,7 +1155,7 @@ const opDescribeTasks = "DescribeTasks" // DescribeTasksRequest generates a "aws/request.Request" representing the // client's request for the DescribeTasks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1247,7 +1247,7 @@ const opDiscoverPollEndpoint = "DiscoverPollEndpoint" // DiscoverPollEndpointRequest generates a "aws/request.Request" representing the // client's request for the DiscoverPollEndpoint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1334,7 +1334,7 @@ const opListAttributes = "ListAttributes" // ListAttributesRequest generates a "aws/request.Request" representing the // client's request for the ListAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1424,7 +1424,7 @@ const opListClusters = "ListClusters" // ListClustersRequest generates a "aws/request.Request" representing the // client's request for the ListClusters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1568,7 +1568,7 @@ const opListContainerInstances = "ListContainerInstances" // ListContainerInstancesRequest generates a "aws/request.Request" representing the // client's request for the ListContainerInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1720,7 +1720,7 @@ const opListServices = "ListServices" // ListServicesRequest generates a "aws/request.Request" representing the // client's request for the ListServices operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1868,7 +1868,7 @@ const opListTaskDefinitionFamilies = "ListTaskDefinitionFamilies" // ListTaskDefinitionFamiliesRequest generates a "aws/request.Request" representing the // client's request for the ListTaskDefinitionFamilies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2018,7 +2018,7 @@ const opListTaskDefinitions = "ListTaskDefinitions" // ListTaskDefinitionsRequest generates a "aws/request.Request" representing the // client's request for the ListTaskDefinitions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2164,7 +2164,7 @@ const opListTasks = "ListTasks" // ListTasksRequest generates a "aws/request.Request" representing the // client's request for the ListTasks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2321,7 +2321,7 @@ const opPutAttributes = "PutAttributes" // PutAttributesRequest generates a "aws/request.Request" representing the // client's request for the PutAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2419,7 +2419,7 @@ const opRegisterContainerInstance = "RegisterContainerInstance" // RegisterContainerInstanceRequest generates a "aws/request.Request" representing the // client's request for the RegisterContainerInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2511,7 +2511,7 @@ const opRegisterTaskDefinition = "RegisterTaskDefinition" // RegisterTaskDefinitionRequest generates a "aws/request.Request" representing the // client's request for the RegisterTaskDefinition operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2619,7 +2619,7 @@ const opRunTask = "RunTask" // RunTaskRequest generates a "aws/request.Request" representing the // client's request for the RunTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2728,7 +2728,7 @@ func (c *ECS) RunTaskRequest(input *RunTaskInput) (req *request.Request, output // You do not have authorization to perform the requested action. // // * ErrCodeBlockedException "BlockedException" -// Your AWS account has been blocked. Contact AWS Customer Support (http://aws.amazon.com/contact-us/) +// Your AWS account has been blocked. Contact AWS Support (http://aws.amazon.com/contact-us/) // for more information. // // See also, https://docs.aws.amazon.com/goto/WebAPI/ecs-2014-11-13/RunTask @@ -2757,7 +2757,7 @@ const opStartTask = "StartTask" // StartTaskRequest generates a "aws/request.Request" representing the // client's request for the StartTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2854,7 +2854,7 @@ const opStopTask = "StopTask" // StopTaskRequest generates a "aws/request.Request" representing the // client's request for the StopTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2957,7 +2957,7 @@ const opSubmitContainerStateChange = "SubmitContainerStateChange" // SubmitContainerStateChangeRequest generates a "aws/request.Request" representing the // client's request for the SubmitContainerStateChange operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3047,7 +3047,7 @@ const opSubmitTaskStateChange = "SubmitTaskStateChange" // SubmitTaskStateChangeRequest generates a "aws/request.Request" representing the // client's request for the SubmitTaskStateChange operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3137,7 +3137,7 @@ const opUpdateContainerAgent = "UpdateContainerAgent" // UpdateContainerAgentRequest generates a "aws/request.Request" representing the // client's request for the UpdateContainerAgent operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3257,7 +3257,7 @@ const opUpdateContainerInstancesState = "UpdateContainerInstancesState" // UpdateContainerInstancesStateRequest generates a "aws/request.Request" representing the // client's request for the UpdateContainerInstancesState operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3392,7 +3392,7 @@ const opUpdateService = "UpdateService" // UpdateServiceRequest generates a "aws/request.Request" representing the // client's request for the UpdateService operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3439,8 +3439,17 @@ func (c *ECS) UpdateServiceRequest(input *UpdateServiceInput) (req *request.Requ // in a service by specifying the cluster that the service is running in and // a new desiredCount parameter. // -// You can use UpdateService to modify your task definition and deploy a new -// version of your service. +// If you have updated the Docker image of your application, you can create +// a new task definition with that image and deploy it to your service. The +// service scheduler uses the minimum healthy percent and maximum percent parameters +// (in the service's deployment configuration) to determine the deployment strategy. +// +// If your updated Docker image uses the same tag as what is in the existing +// task definition for your service (for example, my_image:latest), you do not +// need to create a new revision of your task definition. You can update the +// service using the forceNewDeployment option. The new tasks launched by the +// deployment pull the current image/tag combination from your repository when +// they start. // // You can also update the deployment configuration of a service. When a deployment // is triggered by updating the task definition of a service, the service scheduler @@ -3580,7 +3589,7 @@ type Attachment struct { // ATTACHED, DETACHING, DETACHED, and DELETED. Status *string `locationName:"status" type:"string"` - // The type of the attachment, such as an ElasticNetworkInterface. + // The type of the attachment, such as ElasticNetworkInterface. Type *string `locationName:"type" type:"string"` } @@ -3750,15 +3759,16 @@ func (s *Attribute) SetValue(v string) *Attribute { type AwsVpcConfiguration struct { _ struct{} `type:"structure"` - // Specifies whether or not the task's elastic network interface receives a - // public IP address. + // Whether the task's elastic network interface receives a public IP address. AssignPublicIp *string `locationName:"assignPublicIp" type:"string" enum:"AssignPublicIp"` // The security groups associated with the task or service. If you do not specify - // a security group, the default security group for the VPC is used. + // a security group, the default security group for the VPC is used. There is + // a limit of 5 security groups able to be specified per AwsVpcConfiguration. SecurityGroups []*string `locationName:"securityGroups" type:"list"` - // The subnets associated with the task or service. + // The subnets associated with the task or service. There is a limit of 10 subnets + // able to be specified per AwsVpcConfiguration. // // Subnets is a required field Subnets []*string `locationName:"subnets" type:"list" required:"true"` @@ -3928,6 +3938,10 @@ type Container struct { // The exit code returned from the container. ExitCode *int64 `locationName:"exitCode" type:"integer"` + // The health status of the container. If health checks are not configured for + // this container in its task definition, then it reports health status as UNKNOWN. + HealthStatus *string `locationName:"healthStatus" type:"string" enum:"HealthStatus"` + // The last known status of the container. LastStatus *string `locationName:"lastStatus" type:"string"` @@ -3970,6 +3984,12 @@ func (s *Container) SetExitCode(v int64) *Container { return s } +// SetHealthStatus sets the HealthStatus field's value. +func (s *Container) SetHealthStatus(v string) *Container { + s.HealthStatus = &v + return s +} + // SetLastStatus sets the LastStatus field's value. func (s *Container) SetLastStatus(v string) *Container { s.LastStatus = &v @@ -4057,9 +4077,9 @@ type ContainerDefinition struct { // uses the CPU value to calculate the relative CPU share ratios for running // containers. For more information, see CPU share constraint (https://docs.docker.com/engine/reference/run/#cpu-share-constraint) // in the Docker documentation. The minimum valid CPU share value that the Linux - // kernel will allow is 2; however, the CPU parameter is not required, and you - // can use CPU values below 2 in your container definitions. For CPU values - // below 2 (including null), the behavior varies based on your Amazon ECS container + // kernel allows is 2; however, the CPU parameter is not required, and you can + // use CPU values below 2 in your container definitions. For CPU values below + // 2 (including null), the behavior varies based on your Amazon ECS container // agent version: // // * Agent versions less than or equal to 1.1.0: Null and zero CPU values @@ -4171,6 +4191,12 @@ type ContainerDefinition struct { // This parameter is not supported for Windows containers. ExtraHosts []*HostEntry `locationName:"extraHosts" type:"list"` + // The health check command and associated configuration parameters for the + // container. This parameter maps to HealthCheck in the Create a container (https://docs.docker.com/engine/reference/api/docker_remote_api_v1.27/#create-a-container) + // section of the Docker Remote API (https://docs.docker.com/engine/reference/api/docker_remote_api_v1.27/) + // and the HEALTHCHECK parameter of docker run (https://docs.docker.com/engine/reference/run/). + HealthCheck *HealthCheck `locationName:"healthCheck" type:"structure"` + // The hostname to use for your container. This parameter maps to Hostname in // the Create a container (https://docs.docker.com/engine/reference/api/docker_remote_api_v1.27/#create-a-container) // section of the Docker Remote API (https://docs.docker.com/engine/reference/api/docker_remote_api_v1.27/) @@ -4187,6 +4213,11 @@ type ContainerDefinition struct { // section of the Docker Remote API (https://docs.docker.com/engine/reference/api/docker_remote_api_v1.27/) // and the IMAGE parameter of docker run (https://docs.docker.com/engine/reference/run/). // + // * When a new task starts, the Amazon ECS container agent pulls the latest + // version of the specified image and tag for the container to use. However, + // subsequent updates to a repository image are not propagated to already + // running tasks. + // // * Images in Amazon ECR repositories can be specified by either using the // full registry/repository:tag or registry/repository@digest. For example, // 012345678910.dkr.ecr..amazonaws.com/:latest @@ -4225,8 +4256,7 @@ type ContainerDefinition struct { // Linux-specific modifications that are applied to the container, such as Linux // KernelCapabilities. // - // This parameter is not supported for Windows containers or tasks using the - // Fargate launch type. + // This parameter is not supported for Windows containers. LinuxParameters *LinuxParameters `locationName:"linuxParameters" type:"structure"` // The log configuration specification for the container. @@ -4268,13 +4298,12 @@ type ContainerDefinition struct { // section of the Docker Remote API (https://docs.docker.com/engine/reference/api/docker_remote_api_v1.27/) // and the --memory option to docker run (https://docs.docker.com/engine/reference/run/). // - // If your containers will be part of a task using the Fargate launch type, - // this field is optional and the only requirement is that the total amount - // of memory reserved for all containers within a task be lower than the task - // memory value. + // If your containers are part of a task using the Fargate launch type, this + // field is optional and the only requirement is that the total amount of memory + // reserved for all containers within a task be lower than the task memory value. // - // For containers that will be part of a task using the EC2 launch type, you - // must specify a non-zero integer for one or both of memory or memoryReservation + // For containers that are part of a task using the EC2 launch type, you must + // specify a non-zero integer for one or both of memory or memoryReservation // in container definitions. If you specify both, memory must be greater than // memoryReservation. If you specify memoryReservation, then that value is subtracted // from the available memory resources for the container instance on which the @@ -4432,6 +4461,11 @@ func (s *ContainerDefinition) Validate() error { } } } + if s.HealthCheck != nil { + if err := s.HealthCheck.Validate(); err != nil { + invalidParams.AddNested("HealthCheck", err.(request.ErrInvalidParams)) + } + } if s.LinuxParameters != nil { if err := s.LinuxParameters.Validate(); err != nil { invalidParams.AddNested("LinuxParameters", err.(request.ErrInvalidParams)) @@ -4525,6 +4559,12 @@ func (s *ContainerDefinition) SetExtraHosts(v []*HostEntry) *ContainerDefinition return s } +// SetHealthCheck sets the HealthCheck field's value. +func (s *ContainerDefinition) SetHealthCheck(v *HealthCheck) *ContainerDefinition { + s.HealthCheck = v + return s +} + // SetHostname sets the Hostname field's value. func (s *ContainerDefinition) SetHostname(v string) *ContainerDefinition { s.Hostname = &v @@ -4657,18 +4697,22 @@ type ContainerInstance struct { // The Unix time stamp for when the container instance was registered. RegisteredAt *time.Time `locationName:"registeredAt" type:"timestamp" timestampFormat:"unix"` - // For most resource types, this parameter describes the registered resources - // on the container instance that are in use by current tasks. For port resource - // types, this parameter describes the ports that were reserved by the Amazon - // ECS container agent when it registered the container instance with Amazon - // ECS. + // For CPU and memory resource types, this parameter describes the amount of + // each resource that was available on the container instance when the container + // agent registered it with Amazon ECS; this value represents the total amount + // of CPU and memory that can be allocated on this container instance to tasks. + // For port resource types, this parameter describes the ports that were reserved + // by the Amazon ECS container agent when it registered the container instance + // with Amazon ECS. RegisteredResources []*Resource `locationName:"registeredResources" type:"list"` - // For most resource types, this parameter describes the remaining resources - // of the container instance that are available for new tasks. For port resource - // types, this parameter describes the ports that are reserved by the Amazon - // ECS container agent and any containers that have reserved port mappings; - // any port that is not specified here is available for new tasks. + // For CPU and memory resource types, this parameter describes the remaining + // CPU and memory on the that has not already been allocated to tasks (and is + // therefore available for new tasks). For port resource types, this parameter + // describes the ports that were reserved by the Amazon ECS container agent + // (at instance registration time) and any task containers that have reserved + // port mappings on the host (with the host or bridge network mode). Any port + // that is not specified here is available for new tasks. RemainingResources []*Resource `locationName:"remainingResources" type:"list"` // The number of tasks on the container instance that are in the RUNNING status. @@ -5006,11 +5050,11 @@ type CreateServiceInput struct { // ignore unhealthy Elastic Load Balancing target health checks after a task // has first started. This is only valid if your service is configured to use // a load balancer. If your service's tasks take a while to start and respond - // to ELB health checks, you can specify a health check grace period of up to - // 1,800 seconds during which the ECS service scheduler will ignore ELB health - // check status. This grace period can prevent the ECS service scheduler from - // marking tasks as unhealthy and stopping them before they have time to come - // up. + // to Elastic Load Balancing health checks, you can specify a health check grace + // period of up to 1,800 seconds during which the ECS service scheduler ignores + // health check status. This grace period can prevent the ECS service scheduler + // from marking tasks as unhealthy and stopping them before they have time to + // come up. HealthCheckGracePeriodSeconds *int64 `locationName:"healthCheckGracePeriodSeconds" type:"integer"` // The launch type on which to run your service. @@ -5085,6 +5129,10 @@ type CreateServiceInput struct { // ServiceName is a required field ServiceName *string `locationName:"serviceName" type:"string" required:"true"` + // The details of the service discovery registries you want to assign to this + // service. For more information, see Service Discovery (http://docs.aws.amazon.com/AmazonECS/latest/developerguideservice-discovery.html). + ServiceRegistries []*ServiceRegistry `locationName:"serviceRegistries" type:"list"` + // The family and revision (family:revision) or full ARN of the task definition // to run in your service. If a revision is not specified, the latest ACTIVE // revision is used. @@ -5205,6 +5253,12 @@ func (s *CreateServiceInput) SetServiceName(v string) *CreateServiceInput { return s } +// SetServiceRegistries sets the ServiceRegistries field's value. +func (s *CreateServiceInput) SetServiceRegistries(v []*ServiceRegistry) *CreateServiceInput { + s.ServiceRegistries = v + return s +} + // SetTaskDefinition sets the TaskDefinition field's value. func (s *CreateServiceInput) SetTaskDefinition(v string) *CreateServiceInput { s.TaskDefinition = &v @@ -6318,6 +6372,105 @@ func (s *Failure) SetReason(v string) *Failure { return s } +// An object representing a container health check. Health check parameters +// that are specified in a container definition override any Docker health checks +// that exist in the container image (such as those specified in a parent image +// or from the image's Dockerfile). +type HealthCheck struct { + _ struct{} `type:"structure"` + + // A string array representing the command that the container runs to determine + // if it is healthy. The string array must start with CMD to execute the command + // arguments directly, or CMD-SHELL to run the command with the container's + // default shell. For example: + // + // [ "CMD-SHELL", "curl -f http://localhost/ || exit 1" ] + // + // An exit code of 0 indicates success, and non-zero exit code indicates failure. + // For more information, see HealthCheck in the Create a container (https://docs.docker.com/engine/reference/api/docker_remote_api_v1.27/#create-a-container) + // section of the Docker Remote API (https://docs.docker.com/engine/reference/api/docker_remote_api_v1.27/). + // + // Command is a required field + Command []*string `locationName:"command" type:"list" required:"true"` + + // The time period in seconds between each health check execution. You may specify + // between 5 and 300 seconds. The default value is 30 seconds. + Interval *int64 `locationName:"interval" type:"integer"` + + // The number of times to retry a failed health check before the container is + // considered unhealthy. You may specify between 1 and 10 retries. The default + // value is 3 retries. + Retries *int64 `locationName:"retries" type:"integer"` + + // The optional grace period within which to provide containers time to bootstrap + // before failed health checks count towards the maximum number of retries. + // You may specify between 0 and 300 seconds. The startPeriod is disabled by + // default. + // + // If a health check succeeds within the startPeriod, then the container is + // considered healthy and any subsequent failures count toward the maximum number + // of retries. + StartPeriod *int64 `locationName:"startPeriod" type:"integer"` + + // The time period in seconds to wait for a health check to succeed before it + // is considered a failure. You may specify between 2 and 60 seconds. The default + // value is 5 seconds. + Timeout *int64 `locationName:"timeout" type:"integer"` +} + +// String returns the string representation +func (s HealthCheck) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s HealthCheck) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *HealthCheck) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "HealthCheck"} + if s.Command == nil { + invalidParams.Add(request.NewErrParamRequired("Command")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetCommand sets the Command field's value. +func (s *HealthCheck) SetCommand(v []*string) *HealthCheck { + s.Command = v + return s +} + +// SetInterval sets the Interval field's value. +func (s *HealthCheck) SetInterval(v int64) *HealthCheck { + s.Interval = &v + return s +} + +// SetRetries sets the Retries field's value. +func (s *HealthCheck) SetRetries(v int64) *HealthCheck { + s.Retries = &v + return s +} + +// SetStartPeriod sets the StartPeriod field's value. +func (s *HealthCheck) SetStartPeriod(v int64) *HealthCheck { + s.StartPeriod = &v + return s +} + +// SetTimeout sets the Timeout field's value. +func (s *HealthCheck) SetTimeout(v int64) *HealthCheck { + s.Timeout = &v + return s +} + // Hostnames and IP address entries that are added to the /etc/hosts file of // a container via the extraHosts parameter of its ContainerDefinition. type HostEntry struct { @@ -6421,6 +6574,9 @@ type KernelCapabilities struct { // section of the Docker Remote API (https://docs.docker.com/engine/reference/api/docker_remote_api_v1.27/) // and the --cap-add option to docker run (https://docs.docker.com/engine/reference/run/). // + // If you are using tasks that use the Fargate launch type, the add parameter + // is not supported. + // // Valid values: "ALL" | "AUDIT_CONTROL" | "AUDIT_WRITE" | "BLOCK_SUSPEND" | // "CHOWN" | "DAC_OVERRIDE" | "DAC_READ_SEARCH" | "FOWNER" | "FSETID" | "IPC_LOCK" // | "IPC_OWNER" | "KILL" | "LEASE" | "LINUX_IMMUTABLE" | "MAC_ADMIN" | "MAC_OVERRIDE" @@ -6511,12 +6667,18 @@ type LinuxParameters struct { // The Linux capabilities for the container that are added to or dropped from // the default configuration provided by Docker. + // + // If you are using tasks that use the Fargate launch type, capabilities is + // supported but the add parameter is not supported. Capabilities *KernelCapabilities `locationName:"capabilities" type:"structure"` // Any host devices to expose to the container. This parameter maps to Devices // in the Create a container (https://docs.docker.com/engine/reference/api/docker_remote_api_v1.27/#create-a-container) // section of the Docker Remote API (https://docs.docker.com/engine/reference/api/docker_remote_api_v1.27/) // and the --device option to docker run (https://docs.docker.com/engine/reference/run/). + // + // If you are using tasks that use the Fargate launch type, the devices parameter + // is not supported. Devices []*Device `locationName:"devices" type:"list"` // Run an init process inside the container that forwards signals and reaps @@ -6526,6 +6688,14 @@ type LinuxParameters struct { // container instance, log in to your container instance and run the following // command: sudo docker version | grep "Server API version" InitProcessEnabled *bool `locationName:"initProcessEnabled" type:"boolean"` + + // The value for the size of the /dev/shm volume. This parameter maps to the + // --shm-size option to docker run (https://docs.docker.com/engine/reference/run/). + SharedMemorySize *int64 `locationName:"sharedMemorySize" type:"integer"` + + // The container path, mount options, and size of the tmpfs mount. This parameter + // maps to the --tmpfs option to docker run (https://docs.docker.com/engine/reference/run/). + Tmpfs []*Tmpfs `locationName:"tmpfs" type:"list"` } // String returns the string representation @@ -6551,6 +6721,16 @@ func (s *LinuxParameters) Validate() error { } } } + if s.Tmpfs != nil { + for i, v := range s.Tmpfs { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tmpfs", i), err.(request.ErrInvalidParams)) + } + } + } if invalidParams.Len() > 0 { return invalidParams @@ -6576,6 +6756,18 @@ func (s *LinuxParameters) SetInitProcessEnabled(v bool) *LinuxParameters { return s } +// SetSharedMemorySize sets the SharedMemorySize field's value. +func (s *LinuxParameters) SetSharedMemorySize(v int64) *LinuxParameters { + s.SharedMemorySize = &v + return s +} + +// SetTmpfs sets the Tmpfs field's value. +func (s *LinuxParameters) SetTmpfs(v []*Tmpfs) *LinuxParameters { + s.Tmpfs = v + return s +} + type ListAttributesInput struct { _ struct{} `type:"structure"` @@ -7810,7 +8002,7 @@ type PortMapping struct { // The port number on the container instance to reserve for your container. // // If using containers in a task with the awsvpc or host network mode, the hostPort - // can either be left blank or needs to be the same value as the containerPort. + // can either be left blank or set to the same value as the containerPort. // // If using containers in a task with the bridge network mode, you can specify // a non-reserved host port for your container port mapping, or you can omit @@ -8090,28 +8282,35 @@ type RegisterTaskDefinitionInput struct { // ContainerDefinitions is a required field ContainerDefinitions []*ContainerDefinition `locationName:"containerDefinitions" type:"list" required:"true"` - // The number of cpu units used by the task. If using the EC2 launch type, this - // field is optional and any value can be used. + // The number of CPU units used by the task. It can be expressed as an integer + // using CPU units, for example 1024, or as a string using vCPUs, for example + // 1 vCPU or 1 vcpu, in a task definition but will be converted to an integer + // indicating the CPU units when the task definition is registered. // // Task-level CPU and memory parameters are ignored for Windows containers. // We recommend specifying container-level resources for Windows containers. // - // If you are using the Fargate launch type, this field is required and you - // must use one of the following values, which determines your range of valid - // values for the memory parameter: + // If using the EC2 launch type, this field is optional. Supported values are + // between 128 CPU units (0.125 vCPUs) and 10240 CPU units (10 vCPUs). + // + // If using the Fargate launch type, this field is required and you must use + // one of the following values, which determines your range of supported values + // for the memory parameter: // - // * 256 (.25 vCPU) - Available memory values: 0.5GB, 1GB, 2GB + // * 256 (.25 vCPU) - Available memory values: 512 (0.5 GB), 1024 (1 GB), + // 2048 (2 GB) // - // * 512 (.5 vCPU) - Available memory values: 1GB, 2GB, 3GB, 4GB + // * 512 (.5 vCPU) - Available memory values: 1024 (1 GB), 2048 (2 GB), 3072 + // (3 GB), 4096 (4 GB) // - // * 1024 (1 vCPU) - Available memory values: 2GB, 3GB, 4GB, 5GB, 6GB, 7GB, - // 8GB + // * 1024 (1 vCPU) - Available memory values: 2048 (2 GB), 3072 (3 GB), 4096 + // (4 GB), 5120 (5 GB), 6144 (6 GB), 7168 (7 GB), 8192 (8 GB) // - // * 2048 (2 vCPU) - Available memory values: Between 4GB and 16GB in 1GB - // increments + // * 2048 (2 vCPU) - Available memory values: Between 4096 (4 GB) and 16384 + // (16 GB) in increments of 1024 (1 GB) // - // * 4096 (4 vCPU) - Available memory values: Between 8GB and 30GB in 1GB - // increments + // * 4096 (4 vCPU) - Available memory values: Between 8192 (8 GB) and 30720 + // (30 GB) in increments of 1024 (1 GB) Cpu *string `locationName:"cpu" type:"string"` // The Amazon Resource Name (ARN) of the task execution role that the Amazon @@ -8126,27 +8325,34 @@ type RegisterTaskDefinitionInput struct { // Family is a required field Family *string `locationName:"family" type:"string" required:"true"` - // The amount (in MiB) of memory used by the task. If using the EC2 launch type, - // this field is optional and any value can be used. + // The amount of memory (in MiB) used by the task. It can be expressed as an + // integer using MiB, for example 1024, or as a string using GB, for example + // 1GB or 1 GB, in a task definition but will be converted to an integer indicating + // the MiB when the task definition is registered. // // Task-level CPU and memory parameters are ignored for Windows containers. // We recommend specifying container-level resources for Windows containers. // - // If you are using the Fargate launch type, this field is required and you - // must use one of the following values, which determines your range of valid - // values for the cpu parameter: + // If using the EC2 launch type, this field is optional. + // + // If using the Fargate launch type, this field is required and you must use + // one of the following values, which determines your range of supported values + // for the cpu parameter: // - // * 0.5GB, 1GB, 2GB - Available cpu values: 256 (.25 vCPU) + // * 512 (0.5 GB), 1024 (1 GB), 2048 (2 GB) - Available cpu values: 256 (.25 + // vCPU) // - // * 1GB, 2GB, 3GB, 4GB - Available cpu values: 512 (.5 vCPU) + // * 1024 (1 GB), 2048 (2 GB), 3072 (3 GB), 4096 (4 GB) - Available cpu values: + // 512 (.5 vCPU) // - // * 2GB, 3GB, 4GB, 5GB, 6GB, 7GB, 8GB - Available cpu values: 1024 (1 vCPU) + // * 2048 (2 GB), 3072 (3 GB), 4096 (4 GB), 5120 (5 GB), 6144 (6 GB), 7168 + // (7 GB), 8192 (8 GB) - Available cpu values: 1024 (1 vCPU) // - // * Between 4GB and 16GB in 1GB increments - Available cpu values: 2048 - // (2 vCPU) + // * Between 4096 (4 GB) and 16384 (16 GB) in increments of 1024 (1 GB) - + // Available cpu values: 2048 (2 vCPU) // - // * Between 8GB and 30GB in 1GB increments - Available cpu values: 4096 - // (4 vCPU) + // * Between 8192 (8 GB) and 30720 (30 GB) in increments of 1024 (1 GB) - + // Available cpu values: 4096 (4 vCPU) Memory *string `locationName:"memory" type:"string"` // The Docker networking mode to use for the containers in the task. The valid @@ -8665,6 +8871,8 @@ type Service struct { // within a region or across multiple regions. ServiceName *string `locationName:"serviceName" type:"string"` + ServiceRegistries []*ServiceRegistry `locationName:"serviceRegistries" type:"list"` + // The status of the service. The valid values are ACTIVE, DRAINING, or INACTIVE. Status *string `locationName:"status" type:"string"` @@ -8792,6 +9000,12 @@ func (s *Service) SetServiceName(v string) *Service { return s } +// SetServiceRegistries sets the ServiceRegistries field's value. +func (s *Service) SetServiceRegistries(v []*ServiceRegistry) *Service { + s.ServiceRegistries = v + return s +} + // SetStatus sets the Status field's value. func (s *Service) SetStatus(v string) *Service { s.Status = &v @@ -8846,6 +9060,41 @@ func (s *ServiceEvent) SetMessage(v string) *ServiceEvent { return s } +// Details of the service registry. +type ServiceRegistry struct { + _ struct{} `type:"structure"` + + // The port value used if your Service Discovery service specified an SRV record. + Port *int64 `locationName:"port" type:"integer"` + + // The Amazon Resource Name (ARN) of the Service Registry. The currently supported + // service registry is Amazon Route 53 Auto Naming Service. For more information, + // see Service (https://docs.aws.amazon.com/Route53/latest/APIReference/API_autonaming_Service.html). + RegistryArn *string `locationName:"registryArn" type:"string"` +} + +// String returns the string representation +func (s ServiceRegistry) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ServiceRegistry) GoString() string { + return s.String() +} + +// SetPort sets the Port field's value. +func (s *ServiceRegistry) SetPort(v int64) *ServiceRegistry { + s.Port = &v + return s +} + +// SetRegistryArn sets the RegistryArn field's value. +func (s *ServiceRegistry) SetRegistryArn(v string) *ServiceRegistry { + s.RegistryArn = &v + return s +} + type StartTaskInput struct { _ struct{} `type:"structure"` @@ -9203,7 +9452,7 @@ type SubmitTaskStateChangeInput struct { // Any containers associated with the state change request. Containers []*ContainerStateChange `locationName:"containers" type:"list"` - // The Unix timestamp for when the task execution stopped. + // The Unix time stamp for when the task execution stopped. ExecutionStoppedAt *time.Time `locationName:"executionStoppedAt" type:"timestamp" timestampFormat:"unix"` // The Unix time stamp for when the container image pull began. @@ -9352,23 +9601,32 @@ type Task struct { // The containers associated with the task. Containers []*Container `locationName:"containers" type:"list"` - // The number of cpu units used by the task. If using the EC2 launch type, this - // field is optional and any value can be used. If using the Fargate launch - // type, this field is required and you must use one of the following values, - // which determines your range of valid values for the memory parameter: + // The number of CPU units used by the task. It can be expressed as an integer + // using CPU units, for example 1024, or as a string using vCPUs, for example + // 1 vCPU or 1 vcpu, in a task definition but is converted to an integer indicating + // the CPU units when the task definition is registered. + // + // If using the EC2 launch type, this field is optional. Supported values are + // between 128 CPU units (0.125 vCPUs) and 10240 CPU units (10 vCPUs). + // + // If using the Fargate launch type, this field is required and you must use + // one of the following values, which determines your range of supported values + // for the memory parameter: // - // * 256 (.25 vCPU) - Available memory values: 0.5GB, 1GB, 2GB + // * 256 (.25 vCPU) - Available memory values: 512 (0.5 GB), 1024 (1 GB), + // 2048 (2 GB) // - // * 512 (.5 vCPU) - Available memory values: 1GB, 2GB, 3GB, 4GB + // * 512 (.5 vCPU) - Available memory values: 1024 (1 GB), 2048 (2 GB), 3072 + // (3 GB), 4096 (4 GB) // - // * 1024 (1 vCPU) - Available memory values: 2GB, 3GB, 4GB, 5GB, 6GB, 7GB, - // 8GB + // * 1024 (1 vCPU) - Available memory values: 2048 (2 GB), 3072 (3 GB), 4096 + // (4 GB), 5120 (5 GB), 6144 (6 GB), 7168 (7 GB), 8192 (8 GB) // - // * 2048 (2 vCPU) - Available memory values: Between 4GB and 16GB in 1GB - // increments + // * 2048 (2 vCPU) - Available memory values: Between 4096 (4 GB) and 16384 + // (16 GB) in increments of 1024 (1 GB) // - // * 4096 (4 vCPU) - Available memory values: Between 8GB and 30GB in 1GB - // increments + // * 4096 (4 vCPU) - Available memory values: Between 8192 (8 GB) and 30720 + // (30 GB) in increments of 1024 (1 GB) Cpu *string `locationName:"cpu" type:"string"` // The Unix time stamp for when the task was created (the task entered the PENDING @@ -9378,34 +9636,56 @@ type Task struct { // The desired status of the task. DesiredStatus *string `locationName:"desiredStatus" type:"string"` - // The Unix timestamp for when the task execution stopped. + // The Unix time stamp for when the task execution stopped. ExecutionStoppedAt *time.Time `locationName:"executionStoppedAt" type:"timestamp" timestampFormat:"unix"` // The name of the task group associated with the task. Group *string `locationName:"group" type:"string"` + // The health status for the task, which is determined by the health of the + // essential containers in the task. If all essential containers in the task + // are reporting as HEALTHY, then the task status also reports as HEALTHY. If + // any essential containers in the task are reporting as UNHEALTHY or UNKNOWN, + // then the task status also reports as UNHEALTHY or UNKNOWN, accordingly. + // + // The Amazon ECS container agent does not monitor or report on Docker health + // checks that are embedded in a container image (such as those specified in + // a parent image or from the image's Dockerfile) and not specified in the container + // definition. Health check parameters that are specified in a container definition + // override any Docker health checks that exist in the container image. + HealthStatus *string `locationName:"healthStatus" type:"string" enum:"HealthStatus"` + // The last known status of the task. LastStatus *string `locationName:"lastStatus" type:"string"` // The launch type on which your task is running. LaunchType *string `locationName:"launchType" type:"string" enum:"LaunchType"` - // The amount (in MiB) of memory used by the task. If using the EC2 launch type, - // this field is optional and any value can be used. If using the Fargate launch - // type, this field is required and you must use one of the following values, - // which determines your range of valid values for the cpu parameter: + // The amount of memory (in MiB) used by the task. It can be expressed as an + // integer using MiB, for example 1024, or as a string using GB, for example + // 1GB or 1 GB, in a task definition but is converted to an integer indicating + // the MiB when the task definition is registered. + // + // If using the EC2 launch type, this field is optional. + // + // If using the Fargate launch type, this field is required and you must use + // one of the following values, which determines your range of supported values + // for the cpu parameter: // - // * 0.5GB, 1GB, 2GB - Available cpu values: 256 (.25 vCPU) + // * 512 (0.5 GB), 1024 (1 GB), 2048 (2 GB) - Available cpu values: 256 (.25 + // vCPU) // - // * 1GB, 2GB, 3GB, 4GB - Available cpu values: 512 (.5 vCPU) + // * 1024 (1 GB), 2048 (2 GB), 3072 (3 GB), 4096 (4 GB) - Available cpu values: + // 512 (.5 vCPU) // - // * 2GB, 3GB, 4GB, 5GB, 6GB, 7GB, 8GB - Available cpu values: 1024 (1 vCPU) + // * 2048 (2 GB), 3072 (3 GB), 4096 (4 GB), 5120 (5 GB), 6144 (6 GB), 7168 + // (7 GB), 8192 (8 GB) - Available cpu values: 1024 (1 vCPU) // - // * Between 4GB and 16GB in 1GB increments - Available cpu values: 2048 - // (2 vCPU) + // * Between 4096 (4 GB) and 16384 (16 GB) in increments of 1024 (1 GB) - + // Available cpu values: 2048 (2 vCPU) // - // * Between 8GB and 30GB in 1GB increments - Available cpu values: 4096 - // (4 vCPU) + // * Between 8192 (8 GB) and 30720 (30 GB) in increments of 1024 (1 GB) - + // Available cpu values: 4096 (4 vCPU) Memory *string `locationName:"memory" type:"string"` // One or more container overrides. @@ -9438,8 +9718,8 @@ type Task struct { // The reason the task was stopped. StoppedReason *string `locationName:"stoppedReason" type:"string"` - // The Unix time stamp for when the task will stop (the task transitioned from - // the RUNNING state to the STOPPED state). + // The Unix time stamp for when the task will stop (transitions from the RUNNING + // state to STOPPED). StoppingAt *time.Time `locationName:"stoppingAt" type:"timestamp" timestampFormat:"unix"` // The Amazon Resource Name (ARN) of the task. @@ -9533,6 +9813,12 @@ func (s *Task) SetGroup(v string) *Task { return s } +// SetHealthStatus sets the HealthStatus field's value. +func (s *Task) SetHealthStatus(v string) *Task { + s.HealthStatus = &v + return s +} + // SetLastStatus sets the LastStatus field's value. func (s *Task) SetLastStatus(v string) *Task { s.LastStatus = &v @@ -9643,18 +9929,20 @@ type TaskDefinition struct { // type, this field is required and you must use one of the following values, // which determines your range of valid values for the memory parameter: // - // * 256 (.25 vCPU) - Available memory values: 0.5GB, 1GB, 2GB + // * 256 (.25 vCPU) - Available memory values: 512 (0.5 GB), 1024 (1 GB), + // 2048 (2 GB) // - // * 512 (.5 vCPU) - Available memory values: 1GB, 2GB, 3GB, 4GB + // * 512 (.5 vCPU) - Available memory values: 1024 (1 GB), 2048 (2 GB), 3072 + // (3 GB), 4096 (4 GB) // - // * 1024 (1 vCPU) - Available memory values: 2GB, 3GB, 4GB, 5GB, 6GB, 7GB, - // 8GB + // * 1024 (1 vCPU) - Available memory values: 2048 (2 GB), 3072 (3 GB), 4096 + // (4 GB), 5120 (5 GB), 6144 (6 GB), 7168 (7 GB), 8192 (8 GB) // - // * 2048 (2 vCPU) - Available memory values: Between 4GB and 16GB in 1GB - // increments + // * 2048 (2 vCPU) - Available memory values: Between 4096 (4 GB) and 16384 + // (16 GB) in increments of 1024 (1 GB) // - // * 4096 (4 vCPU) - Available memory values: Between 8GB and 30GB in 1GB - // increments + // * 4096 (4 vCPU) - Available memory values: Between 8192 (8 GB) and 30720 + // (30 GB) in increments of 1024 (1 GB) Cpu *string `locationName:"cpu" type:"string"` // The Amazon Resource Name (ARN) of the task execution role that the Amazon @@ -9669,17 +9957,20 @@ type TaskDefinition struct { // type, this field is required and you must use one of the following values, // which determines your range of valid values for the cpu parameter: // - // * 0.5GB, 1GB, 2GB - Available cpu values: 256 (.25 vCPU) + // * 512 (0.5 GB), 1024 (1 GB), 2048 (2 GB) - Available cpu values: 256 (.25 + // vCPU) // - // * 1GB, 2GB, 3GB, 4GB - Available cpu values: 512 (.5 vCPU) + // * 1024 (1 GB), 2048 (2 GB), 3072 (3 GB), 4096 (4 GB) - Available cpu values: + // 512 (.5 vCPU) // - // * 2GB, 3GB, 4GB, 5GB, 6GB, 7GB, 8GB - Available cpu values: 1024 (1 vCPU) + // * 2048 (2 GB), 3072 (3 GB), 4096 (4 GB), 5120 (5 GB), 6144 (6 GB), 7168 + // (7 GB), 8192 (8 GB) - Available cpu values: 1024 (1 vCPU) // - // * Between 4GB and 16GB in 1GB increments - Available cpu values: 2048 - // (2 vCPU) + // * Between 4096 (4 GB) and 16384 (16 GB) in increments of 1024 (1 GB) - + // Available cpu values: 2048 (2 vCPU) // - // * Between 8GB and 30GB in 1GB increments - Available cpu values: 4096 - // (4 vCPU) + // * Between 8192 (8 GB) and 30720 (30 GB) in increments of 1024 (1 GB) - + // Available cpu values: 4096 (4 vCPU) Memory *string `locationName:"memory" type:"string"` // The Docker networking mode to use for the containers in the task. The valid @@ -9866,8 +10157,8 @@ func (s *TaskDefinition) SetVolumes(v []*Volume) *TaskDefinition { // An object representing a constraint on task placement in the task definition. // -// If you are using the Fargate launch type, task placement contraints are not -// supported. +// If you are using the Fargate launch type, task placement constraints are +// not supported. // // For more information, see Task Placement Constraints (http://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-placement-constraints.html) // in the Amazon Elastic Container Service Developer Guide. @@ -9952,6 +10243,74 @@ func (s *TaskOverride) SetTaskRoleArn(v string) *TaskOverride { return s } +// The container path, mount options, and size of the tmpfs mount. +type Tmpfs struct { + _ struct{} `type:"structure"` + + // The absolute file path where the tmpfs volume will be mounted. + // + // ContainerPath is a required field + ContainerPath *string `locationName:"containerPath" type:"string" required:"true"` + + // The list of tmpfs volume mount options. + // + // Valid values: "defaults" | "ro" | "rw" | "suid" | "nosuid" | "dev" | "nodev" + // | "exec" | "noexec" | "sync" | "async" | "dirsync" | "remount" | "mand" | + // "nomand" | "atime" | "noatime" | "diratime" | "nodiratime" | "bind" | "rbind" + // | "unbindable" | "runbindable" | "private" | "rprivate" | "shared" | "rshared" + // | "slave" | "rslave" | "relatime" | "norelatime" | "strictatime" | "nostrictatime" + MountOptions []*string `locationName:"mountOptions" type:"list"` + + // The size of the tmpfs volume. + // + // Size is a required field + Size *int64 `locationName:"size" type:"integer" required:"true"` +} + +// String returns the string representation +func (s Tmpfs) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s Tmpfs) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *Tmpfs) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "Tmpfs"} + if s.ContainerPath == nil { + invalidParams.Add(request.NewErrParamRequired("ContainerPath")) + } + if s.Size == nil { + invalidParams.Add(request.NewErrParamRequired("Size")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetContainerPath sets the ContainerPath field's value. +func (s *Tmpfs) SetContainerPath(v string) *Tmpfs { + s.ContainerPath = &v + return s +} + +// SetMountOptions sets the MountOptions field's value. +func (s *Tmpfs) SetMountOptions(v []*string) *Tmpfs { + s.MountOptions = v + return s +} + +// SetSize sets the Size field's value. +func (s *Tmpfs) SetSize(v int64) *Tmpfs { + s.Size = &v + return s +} + // The ulimit settings to pass to the container. type Ulimit struct { _ struct{} `type:"structure"` @@ -10203,23 +10562,27 @@ type UpdateServiceInput struct { // service. DesiredCount *int64 `locationName:"desiredCount" type:"integer"` - // Whether or not to force a new deployment of the service. + // Whether to force a new deployment of the service. Deployments are not forced + // by default. You can use this option to trigger a new deployment with no service + // definition changes. For example, you can update a service's tasks to use + // a newer Docker image with the same image/tag combination (my_image:latest) + // or to roll Fargate tasks onto a newer platform version. ForceNewDeployment *bool `locationName:"forceNewDeployment" type:"boolean"` // The period of time, in seconds, that the Amazon ECS service scheduler should // ignore unhealthy Elastic Load Balancing target health checks after a task // has first started. This is only valid if your service is configured to use // a load balancer. If your service's tasks take a while to start and respond - // to ELB health checks, you can specify a health check grace period of up to - // 1,800 seconds during which the ECS service scheduler will ignore ELB health - // check status. This grace period can prevent the ECS service scheduler from - // marking tasks as unhealthy and stopping them before they have time to come - // up. + // to Elastic Load Balancing health checks, you can specify a health check grace + // period of up to 1,800 seconds during which the ECS service scheduler ignores + // the Elastic Load Balancing health check status. This grace period can prevent + // the ECS service scheduler from marking tasks as unhealthy and stopping them + // before they have time to come up. HealthCheckGracePeriodSeconds *int64 `locationName:"healthCheckGracePeriodSeconds" type:"integer"` // The network configuration for the service. This parameter is required for - // task definitions that use the awsvpc network mode to receive their own Elastic - // Network Interface, and it is not supported for other network modes. For more + // task definitions that use the awsvpc network mode to receive their own elastic + // network interface, and it is not supported for other network modes. For more // information, see Task Networking (http://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-networking.html) // in the Amazon Elastic Container Service Developer Guide. // @@ -10553,6 +10916,17 @@ const ( DeviceCgroupPermissionMknod = "mknod" ) +const ( + // HealthStatusHealthy is a HealthStatus enum value + HealthStatusHealthy = "HEALTHY" + + // HealthStatusUnhealthy is a HealthStatus enum value + HealthStatusUnhealthy = "UNHEALTHY" + + // HealthStatusUnknown is a HealthStatus enum value + HealthStatusUnknown = "UNKNOWN" +) + const ( // LaunchTypeEc2 is a LaunchType enum value LaunchTypeEc2 = "EC2" diff --git a/vendor/github.com/aws/aws-sdk-go/service/ecs/errors.go b/vendor/github.com/aws/aws-sdk-go/service/ecs/errors.go index d4caaeb629ab..619efc778fe1 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/ecs/errors.go +++ b/vendor/github.com/aws/aws-sdk-go/service/ecs/errors.go @@ -21,7 +21,7 @@ const ( // ErrCodeBlockedException for service response error code // "BlockedException". // - // Your AWS account has been blocked. Contact AWS Customer Support (http://aws.amazon.com/contact-us/) + // Your AWS account has been blocked. Contact AWS Support (http://aws.amazon.com/contact-us/) // for more information. ErrCodeBlockedException = "BlockedException" diff --git a/vendor/github.com/aws/aws-sdk-go/service/efs/api.go b/vendor/github.com/aws/aws-sdk-go/service/efs/api.go index 413b0b2c6756..129093458231 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/efs/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/efs/api.go @@ -17,7 +17,7 @@ const opCreateFileSystem = "CreateFileSystem" // CreateFileSystemRequest generates a "aws/request.Request" representing the // client's request for the CreateFileSystem operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -153,7 +153,7 @@ const opCreateMountTarget = "CreateMountTarget" // CreateMountTargetRequest generates a "aws/request.Request" representing the // client's request for the CreateMountTarget operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -369,7 +369,7 @@ const opCreateTags = "CreateTags" // CreateTagsRequest generates a "aws/request.Request" representing the // client's request for the CreateTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -464,7 +464,7 @@ const opDeleteFileSystem = "DeleteFileSystem" // DeleteFileSystemRequest generates a "aws/request.Request" representing the // client's request for the DeleteFileSystem operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -571,7 +571,7 @@ const opDeleteMountTarget = "DeleteMountTarget" // DeleteMountTargetRequest generates a "aws/request.Request" representing the // client's request for the DeleteMountTarget operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -688,7 +688,7 @@ const opDeleteTags = "DeleteTags" // DeleteTagsRequest generates a "aws/request.Request" representing the // client's request for the DeleteTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -784,7 +784,7 @@ const opDescribeFileSystems = "DescribeFileSystems" // DescribeFileSystemsRequest generates a "aws/request.Request" representing the // client's request for the DescribeFileSystems operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -896,7 +896,7 @@ const opDescribeMountTargetSecurityGroups = "DescribeMountTargetSecurityGroups" // DescribeMountTargetSecurityGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeMountTargetSecurityGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -996,7 +996,7 @@ const opDescribeMountTargets = "DescribeMountTargets" // DescribeMountTargetsRequest generates a "aws/request.Request" representing the // client's request for the DescribeMountTargets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1093,7 +1093,7 @@ const opDescribeTags = "DescribeTags" // DescribeTagsRequest generates a "aws/request.Request" representing the // client's request for the DescribeTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1185,7 +1185,7 @@ const opModifyMountTargetSecurityGroups = "ModifyMountTargetSecurityGroups" // ModifyMountTargetSecurityGroupsRequest generates a "aws/request.Request" representing the // client's request for the ModifyMountTargetSecurityGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/elasticache/api.go b/vendor/github.com/aws/aws-sdk-go/service/elasticache/api.go index a1ad3a61b36f..96ab771ef0b3 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/elasticache/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/elasticache/api.go @@ -16,7 +16,7 @@ const opAddTagsToResource = "AddTagsToResource" // AddTagsToResourceRequest generates a "aws/request.Request" representing the // client's request for the AddTagsToResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -116,7 +116,7 @@ const opAuthorizeCacheSecurityGroupIngress = "AuthorizeCacheSecurityGroupIngress // AuthorizeCacheSecurityGroupIngressRequest generates a "aws/request.Request" representing the // client's request for the AuthorizeCacheSecurityGroupIngress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -214,7 +214,7 @@ const opCopySnapshot = "CopySnapshot" // CopySnapshotRequest generates a "aws/request.Request" representing the // client's request for the CopySnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -374,7 +374,7 @@ const opCreateCacheCluster = "CreateCacheCluster" // CreateCacheClusterRequest generates a "aws/request.Request" representing the // client's request for the CreateCacheCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -506,7 +506,7 @@ const opCreateCacheParameterGroup = "CreateCacheParameterGroup" // CreateCacheParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateCacheParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -612,7 +612,7 @@ const opCreateCacheSecurityGroup = "CreateCacheSecurityGroup" // CreateCacheSecurityGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateCacheSecurityGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -707,7 +707,7 @@ const opCreateCacheSubnetGroup = "CreateCacheSubnetGroup" // CreateCacheSubnetGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateCacheSubnetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -801,7 +801,7 @@ const opCreateReplicationGroup = "CreateReplicationGroup" // CreateReplicationGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateReplicationGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -955,7 +955,7 @@ const opCreateSnapshot = "CreateSnapshot" // CreateSnapshotRequest generates a "aws/request.Request" representing the // client's request for the CreateSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1070,7 +1070,7 @@ const opDeleteCacheCluster = "DeleteCacheCluster" // DeleteCacheClusterRequest generates a "aws/request.Request" representing the // client's request for the DeleteCacheCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1187,7 +1187,7 @@ const opDeleteCacheParameterGroup = "DeleteCacheParameterGroup" // DeleteCacheParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteCacheParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1280,7 +1280,7 @@ const opDeleteCacheSecurityGroup = "DeleteCacheSecurityGroup" // DeleteCacheSecurityGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteCacheSecurityGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1373,7 +1373,7 @@ const opDeleteCacheSubnetGroup = "DeleteCacheSubnetGroup" // DeleteCacheSubnetGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteCacheSubnetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1460,7 +1460,7 @@ const opDeleteReplicationGroup = "DeleteReplicationGroup" // DeleteReplicationGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteReplicationGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1576,7 +1576,7 @@ const opDeleteSnapshot = "DeleteSnapshot" // DeleteSnapshotRequest generates a "aws/request.Request" representing the // client's request for the DeleteSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1669,7 +1669,7 @@ const opDescribeCacheClusters = "DescribeCacheClusters" // DescribeCacheClustersRequest generates a "aws/request.Request" representing the // client's request for the DescribeCacheClusters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1831,7 +1831,7 @@ const opDescribeCacheEngineVersions = "DescribeCacheEngineVersions" // DescribeCacheEngineVersionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeCacheEngineVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1961,7 +1961,7 @@ const opDescribeCacheParameterGroups = "DescribeCacheParameterGroups" // DescribeCacheParameterGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeCacheParameterGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2105,7 +2105,7 @@ const opDescribeCacheParameters = "DescribeCacheParameters" // DescribeCacheParametersRequest generates a "aws/request.Request" representing the // client's request for the DescribeCacheParameters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2247,7 +2247,7 @@ const opDescribeCacheSecurityGroups = "DescribeCacheSecurityGroups" // DescribeCacheSecurityGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeCacheSecurityGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2390,7 +2390,7 @@ const opDescribeCacheSubnetGroups = "DescribeCacheSubnetGroups" // DescribeCacheSubnetGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeCacheSubnetGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2527,7 +2527,7 @@ const opDescribeEngineDefaultParameters = "DescribeEngineDefaultParameters" // DescribeEngineDefaultParametersRequest generates a "aws/request.Request" representing the // client's request for the DescribeEngineDefaultParameters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2666,7 +2666,7 @@ const opDescribeEvents = "DescribeEvents" // DescribeEventsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEvents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2809,7 +2809,7 @@ const opDescribeReplicationGroups = "DescribeReplicationGroups" // DescribeReplicationGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeReplicationGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2954,7 +2954,7 @@ const opDescribeReservedCacheNodes = "DescribeReservedCacheNodes" // DescribeReservedCacheNodesRequest generates a "aws/request.Request" representing the // client's request for the DescribeReservedCacheNodes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3096,7 +3096,7 @@ const opDescribeReservedCacheNodesOfferings = "DescribeReservedCacheNodesOfferin // DescribeReservedCacheNodesOfferingsRequest generates a "aws/request.Request" representing the // client's request for the DescribeReservedCacheNodesOfferings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3237,7 +3237,7 @@ const opDescribeSnapshots = "DescribeSnapshots" // DescribeSnapshotsRequest generates a "aws/request.Request" representing the // client's request for the DescribeSnapshots operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3386,7 +3386,7 @@ const opListAllowedNodeTypeModifications = "ListAllowedNodeTypeModifications" // ListAllowedNodeTypeModificationsRequest generates a "aws/request.Request" representing the // client's request for the ListAllowedNodeTypeModifications operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3479,7 +3479,7 @@ const opListTagsForResource = "ListTagsForResource" // ListTagsForResourceRequest generates a "aws/request.Request" representing the // client's request for the ListTagsForResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3571,7 +3571,7 @@ const opModifyCacheCluster = "ModifyCacheCluster" // ModifyCacheClusterRequest generates a "aws/request.Request" representing the // client's request for the ModifyCacheCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3687,7 +3687,7 @@ const opModifyCacheParameterGroup = "ModifyCacheParameterGroup" // ModifyCacheParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the ModifyCacheParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3779,7 +3779,7 @@ const opModifyCacheSubnetGroup = "ModifyCacheSubnetGroup" // ModifyCacheSubnetGroupRequest generates a "aws/request.Request" representing the // client's request for the ModifyCacheSubnetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3869,7 +3869,7 @@ const opModifyReplicationGroup = "ModifyReplicationGroup" // ModifyReplicationGroupRequest generates a "aws/request.Request" representing the // client's request for the ModifyReplicationGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3995,7 +3995,7 @@ const opModifyReplicationGroupShardConfiguration = "ModifyReplicationGroupShardC // ModifyReplicationGroupShardConfigurationRequest generates a "aws/request.Request" representing the // client's request for the ModifyReplicationGroupShardConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4109,7 +4109,7 @@ const opPurchaseReservedCacheNodesOffering = "PurchaseReservedCacheNodesOffering // PurchaseReservedCacheNodesOfferingRequest generates a "aws/request.Request" representing the // client's request for the PurchaseReservedCacheNodesOffering operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4201,7 +4201,7 @@ const opRebootCacheCluster = "RebootCacheCluster" // RebootCacheClusterRequest generates a "aws/request.Request" representing the // client's request for the RebootCacheCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4299,7 +4299,7 @@ const opRemoveTagsFromResource = "RemoveTagsFromResource" // RemoveTagsFromResourceRequest generates a "aws/request.Request" representing the // client's request for the RemoveTagsFromResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4387,7 +4387,7 @@ const opResetCacheParameterGroup = "ResetCacheParameterGroup" // ResetCacheParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the ResetCacheParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4480,7 +4480,7 @@ const opRevokeCacheSecurityGroupIngress = "RevokeCacheSecurityGroupIngress" // RevokeCacheSecurityGroupIngressRequest generates a "aws/request.Request" representing the // client's request for the RevokeCacheSecurityGroupIngress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4574,7 +4574,7 @@ const opTestFailover = "TestFailover" // TestFailoverRequest generates a "aws/request.Request" representing the // client's request for the TestFailover operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/elasticbeanstalk/api.go b/vendor/github.com/aws/aws-sdk-go/service/elasticbeanstalk/api.go index 14f972572a50..178bb2a3abdf 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/elasticbeanstalk/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/elasticbeanstalk/api.go @@ -17,7 +17,7 @@ const opAbortEnvironmentUpdate = "AbortEnvironmentUpdate" // AbortEnvironmentUpdateRequest generates a "aws/request.Request" representing the // client's request for the AbortEnvironmentUpdate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -71,7 +71,7 @@ func (c *ElasticBeanstalk) AbortEnvironmentUpdateRequest(input *AbortEnvironment // // Returned Error Codes: // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // See also, https://docs.aws.amazon.com/goto/WebAPI/elasticbeanstalk-2010-12-01/AbortEnvironmentUpdate @@ -100,7 +100,7 @@ const opApplyEnvironmentManagedAction = "ApplyEnvironmentManagedAction" // ApplyEnvironmentManagedActionRequest generates a "aws/request.Request" representing the // client's request for the ApplyEnvironmentManagedAction operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -184,7 +184,7 @@ const opCheckDNSAvailability = "CheckDNSAvailability" // CheckDNSAvailabilityRequest generates a "aws/request.Request" representing the // client's request for the CheckDNSAvailability operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -258,7 +258,7 @@ const opComposeEnvironments = "ComposeEnvironments" // ComposeEnvironmentsRequest generates a "aws/request.Request" representing the // client's request for the ComposeEnvironments operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -318,7 +318,7 @@ func (c *ElasticBeanstalk) ComposeEnvironmentsRequest(input *ComposeEnvironments // The specified account has reached its limit of environments. // // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // See also, https://docs.aws.amazon.com/goto/WebAPI/elasticbeanstalk-2010-12-01/ComposeEnvironments @@ -347,7 +347,7 @@ const opCreateApplication = "CreateApplication" // CreateApplicationRequest generates a "aws/request.Request" representing the // client's request for the CreateApplication operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -427,7 +427,7 @@ const opCreateApplicationVersion = "CreateApplicationVersion" // CreateApplicationVersionRequest generates a "aws/request.Request" representing the // client's request for the CreateApplicationVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -500,7 +500,7 @@ func (c *ElasticBeanstalk) CreateApplicationVersionRequest(input *CreateApplicat // The specified account has reached its limit of application versions. // // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // * ErrCodeS3LocationNotInServiceRegionException "S3LocationNotInServiceRegionException" @@ -542,7 +542,7 @@ const opCreateConfigurationTemplate = "CreateConfigurationTemplate" // CreateConfigurationTemplateRequest generates a "aws/request.Request" representing the // client's request for the CreateConfigurationTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -603,7 +603,7 @@ func (c *ElasticBeanstalk) CreateConfigurationTemplateRequest(input *CreateConfi // // Returned Error Codes: // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // * ErrCodeTooManyBucketsException "TooManyBucketsException" @@ -638,7 +638,7 @@ const opCreateEnvironment = "CreateEnvironment" // CreateEnvironmentRequest generates a "aws/request.Request" representing the // client's request for the CreateEnvironment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -693,7 +693,7 @@ func (c *ElasticBeanstalk) CreateEnvironmentRequest(input *CreateEnvironmentInpu // The specified account has reached its limit of environments. // // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // See also, https://docs.aws.amazon.com/goto/WebAPI/elasticbeanstalk-2010-12-01/CreateEnvironment @@ -722,7 +722,7 @@ const opCreatePlatformVersion = "CreatePlatformVersion" // CreatePlatformVersionRequest generates a "aws/request.Request" representing the // client's request for the CreatePlatformVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -773,7 +773,7 @@ func (c *ElasticBeanstalk) CreatePlatformVersionRequest(input *CreatePlatformVer // // Returned Error Codes: // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // * ErrCodeServiceException "ServiceException" @@ -809,7 +809,7 @@ const opCreateStorageLocation = "CreateStorageLocation" // CreateStorageLocationRequest generates a "aws/request.Request" representing the // client's request for the CreateStorageLocation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -870,7 +870,7 @@ func (c *ElasticBeanstalk) CreateStorageLocationRequest(input *CreateStorageLoca // The specified account does not have a subscription to Amazon S3. // // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // See also, https://docs.aws.amazon.com/goto/WebAPI/elasticbeanstalk-2010-12-01/CreateStorageLocation @@ -899,7 +899,7 @@ const opDeleteApplication = "DeleteApplication" // DeleteApplicationRequest generates a "aws/request.Request" representing the // client's request for the DeleteApplication operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -985,7 +985,7 @@ const opDeleteApplicationVersion = "DeleteApplicationVersion" // DeleteApplicationVersionRequest generates a "aws/request.Request" representing the // client's request for the DeleteApplicationVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1045,7 +1045,7 @@ func (c *ElasticBeanstalk) DeleteApplicationVersionRequest(input *DeleteApplicat // version. The application version was deleted successfully. // // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // * ErrCodeOperationInProgressException "OperationInProgressFailure" @@ -1088,7 +1088,7 @@ const opDeleteConfigurationTemplate = "DeleteConfigurationTemplate" // DeleteConfigurationTemplateRequest generates a "aws/request.Request" representing the // client's request for the DeleteConfigurationTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1174,7 +1174,7 @@ const opDeleteEnvironmentConfiguration = "DeleteEnvironmentConfiguration" // DeleteEnvironmentConfigurationRequest generates a "aws/request.Request" representing the // client's request for the DeleteEnvironmentConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1257,7 +1257,7 @@ const opDeletePlatformVersion = "DeletePlatformVersion" // DeletePlatformVersionRequest generates a "aws/request.Request" representing the // client's request for the DeletePlatformVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1312,7 +1312,7 @@ func (c *ElasticBeanstalk) DeletePlatformVersionRequest(input *DeletePlatformVer // effects an element in this activity is already in progress. // // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // * ErrCodeServiceException "ServiceException" @@ -1344,11 +1344,94 @@ func (c *ElasticBeanstalk) DeletePlatformVersionWithContext(ctx aws.Context, inp return out, req.Send() } +const opDescribeAccountAttributes = "DescribeAccountAttributes" + +// DescribeAccountAttributesRequest generates a "aws/request.Request" representing the +// client's request for the DescribeAccountAttributes operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DescribeAccountAttributes for more information on using the DescribeAccountAttributes +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DescribeAccountAttributesRequest method. +// req, resp := client.DescribeAccountAttributesRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticbeanstalk-2010-12-01/DescribeAccountAttributes +func (c *ElasticBeanstalk) DescribeAccountAttributesRequest(input *DescribeAccountAttributesInput) (req *request.Request, output *DescribeAccountAttributesOutput) { + op := &request.Operation{ + Name: opDescribeAccountAttributes, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DescribeAccountAttributesInput{} + } + + output = &DescribeAccountAttributesOutput{} + req = c.newRequest(op, input, output) + return +} + +// DescribeAccountAttributes API operation for AWS Elastic Beanstalk. +// +// Returns attributes related to AWS Elastic Beanstalk that are associated with +// the calling AWS account. +// +// The result currently has one set of attributes—resource quotas. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Elastic Beanstalk's +// API operation DescribeAccountAttributes for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" +// The specified account does not have sufficient privileges for one or more +// AWS services. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticbeanstalk-2010-12-01/DescribeAccountAttributes +func (c *ElasticBeanstalk) DescribeAccountAttributes(input *DescribeAccountAttributesInput) (*DescribeAccountAttributesOutput, error) { + req, out := c.DescribeAccountAttributesRequest(input) + return out, req.Send() +} + +// DescribeAccountAttributesWithContext is the same as DescribeAccountAttributes with the addition of +// the ability to pass a context and additional request options. +// +// See DescribeAccountAttributes for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ElasticBeanstalk) DescribeAccountAttributesWithContext(ctx aws.Context, input *DescribeAccountAttributesInput, opts ...request.Option) (*DescribeAccountAttributesOutput, error) { + req, out := c.DescribeAccountAttributesRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opDescribeApplicationVersions = "DescribeApplicationVersions" // DescribeApplicationVersionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeApplicationVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1422,7 +1505,7 @@ const opDescribeApplications = "DescribeApplications" // DescribeApplicationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeApplications operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1496,7 +1579,7 @@ const opDescribeConfigurationOptions = "DescribeConfigurationOptions" // DescribeConfigurationOptionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeConfigurationOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1579,7 +1662,7 @@ const opDescribeConfigurationSettings = "DescribeConfigurationSettings" // DescribeConfigurationSettingsRequest generates a "aws/request.Request" representing the // client's request for the DescribeConfigurationSettings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1670,7 +1753,7 @@ const opDescribeEnvironmentHealth = "DescribeEnvironmentHealth" // DescribeEnvironmentHealthRequest generates a "aws/request.Request" representing the // client's request for the DescribeEnvironmentHealth operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1755,7 +1838,7 @@ const opDescribeEnvironmentManagedActionHistory = "DescribeEnvironmentManagedAct // DescribeEnvironmentManagedActionHistoryRequest generates a "aws/request.Request" representing the // client's request for the DescribeEnvironmentManagedActionHistory operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1834,7 +1917,7 @@ const opDescribeEnvironmentManagedActions = "DescribeEnvironmentManagedActions" // DescribeEnvironmentManagedActionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEnvironmentManagedActions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1913,7 +1996,7 @@ const opDescribeEnvironmentResources = "DescribeEnvironmentResources" // DescribeEnvironmentResourcesRequest generates a "aws/request.Request" representing the // client's request for the DescribeEnvironmentResources operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1964,7 +2047,7 @@ func (c *ElasticBeanstalk) DescribeEnvironmentResourcesRequest(input *DescribeEn // // Returned Error Codes: // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // See also, https://docs.aws.amazon.com/goto/WebAPI/elasticbeanstalk-2010-12-01/DescribeEnvironmentResources @@ -1993,7 +2076,7 @@ const opDescribeEnvironments = "DescribeEnvironments" // DescribeEnvironmentsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEnvironments operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2067,7 +2150,7 @@ const opDescribeEvents = "DescribeEvents" // DescribeEventsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEvents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2199,7 +2282,7 @@ const opDescribeInstancesHealth = "DescribeInstancesHealth" // DescribeInstancesHealthRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstancesHealth operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2283,7 +2366,7 @@ const opDescribePlatformVersion = "DescribePlatformVersion" // DescribePlatformVersionRequest generates a "aws/request.Request" representing the // client's request for the DescribePlatformVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2334,7 +2417,7 @@ func (c *ElasticBeanstalk) DescribePlatformVersionRequest(input *DescribePlatfor // // Returned Error Codes: // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // * ErrCodeServiceException "ServiceException" @@ -2366,7 +2449,7 @@ const opListAvailableSolutionStacks = "ListAvailableSolutionStacks" // ListAvailableSolutionStacksRequest generates a "aws/request.Request" representing the // client's request for the ListAvailableSolutionStacks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2441,7 +2524,7 @@ const opListPlatformVersions = "ListPlatformVersions" // ListPlatformVersionsRequest generates a "aws/request.Request" representing the // client's request for the ListPlatformVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2492,7 +2575,7 @@ func (c *ElasticBeanstalk) ListPlatformVersionsRequest(input *ListPlatformVersio // // Returned Error Codes: // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // * ErrCodeServiceException "ServiceException" @@ -2524,7 +2607,7 @@ const opListTagsForResource = "ListTagsForResource" // ListTagsForResourceRequest generates a "aws/request.Request" representing the // client's request for the ListTagsForResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2580,7 +2663,7 @@ func (c *ElasticBeanstalk) ListTagsForResourceRequest(input *ListTagsForResource // // Returned Error Codes: // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // * ErrCodeResourceNotFoundException "ResourceNotFoundException" @@ -2616,7 +2699,7 @@ const opRebuildEnvironment = "RebuildEnvironment" // RebuildEnvironmentRequest generates a "aws/request.Request" representing the // client's request for the RebuildEnvironment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2670,7 +2753,7 @@ func (c *ElasticBeanstalk) RebuildEnvironmentRequest(input *RebuildEnvironmentIn // // Returned Error Codes: // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // See also, https://docs.aws.amazon.com/goto/WebAPI/elasticbeanstalk-2010-12-01/RebuildEnvironment @@ -2699,7 +2782,7 @@ const opRequestEnvironmentInfo = "RequestEnvironmentInfo" // RequestEnvironmentInfoRequest generates a "aws/request.Request" representing the // client's request for the RequestEnvironmentInfo operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2789,7 +2872,7 @@ const opRestartAppServer = "RestartAppServer" // RestartAppServerRequest generates a "aws/request.Request" representing the // client's request for the RestartAppServer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2866,7 +2949,7 @@ const opRetrieveEnvironmentInfo = "RetrieveEnvironmentInfo" // RetrieveEnvironmentInfoRequest generates a "aws/request.Request" representing the // client's request for the RetrieveEnvironmentInfo operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2944,7 +3027,7 @@ const opSwapEnvironmentCNAMEs = "SwapEnvironmentCNAMEs" // SwapEnvironmentCNAMEsRequest generates a "aws/request.Request" representing the // client's request for the SwapEnvironmentCNAMEs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3020,7 +3103,7 @@ const opTerminateEnvironment = "TerminateEnvironment" // TerminateEnvironmentRequest generates a "aws/request.Request" representing the // client's request for the TerminateEnvironment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3071,7 +3154,7 @@ func (c *ElasticBeanstalk) TerminateEnvironmentRequest(input *TerminateEnvironme // // Returned Error Codes: // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // See also, https://docs.aws.amazon.com/goto/WebAPI/elasticbeanstalk-2010-12-01/TerminateEnvironment @@ -3100,7 +3183,7 @@ const opUpdateApplication = "UpdateApplication" // UpdateApplicationRequest generates a "aws/request.Request" representing the // client's request for the UpdateApplication operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3177,7 +3260,7 @@ const opUpdateApplicationResourceLifecycle = "UpdateApplicationResourceLifecycle // UpdateApplicationResourceLifecycleRequest generates a "aws/request.Request" representing the // client's request for the UpdateApplicationResourceLifecycle operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3228,7 +3311,7 @@ func (c *ElasticBeanstalk) UpdateApplicationResourceLifecycleRequest(input *Upda // // Returned Error Codes: // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // See also, https://docs.aws.amazon.com/goto/WebAPI/elasticbeanstalk-2010-12-01/UpdateApplicationResourceLifecycle @@ -3257,7 +3340,7 @@ const opUpdateApplicationVersion = "UpdateApplicationVersion" // UpdateApplicationVersionRequest generates a "aws/request.Request" representing the // client's request for the UpdateApplicationVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3334,7 +3417,7 @@ const opUpdateConfigurationTemplate = "UpdateConfigurationTemplate" // UpdateConfigurationTemplateRequest generates a "aws/request.Request" representing the // client's request for the UpdateConfigurationTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3393,7 +3476,7 @@ func (c *ElasticBeanstalk) UpdateConfigurationTemplateRequest(input *UpdateConfi // // Returned Error Codes: // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // * ErrCodeTooManyBucketsException "TooManyBucketsException" @@ -3425,7 +3508,7 @@ const opUpdateEnvironment = "UpdateEnvironment" // UpdateEnvironmentRequest generates a "aws/request.Request" representing the // client's request for the UpdateEnvironment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3486,7 +3569,7 @@ func (c *ElasticBeanstalk) UpdateEnvironmentRequest(input *UpdateEnvironmentInpu // // Returned Error Codes: // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // * ErrCodeTooManyBucketsException "TooManyBucketsException" @@ -3518,7 +3601,7 @@ const opUpdateTagsForResource = "UpdateTagsForResource" // UpdateTagsForResourceRequest generates a "aws/request.Request" representing the // client's request for the UpdateTagsForResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3589,7 +3672,7 @@ func (c *ElasticBeanstalk) UpdateTagsForResourceRequest(input *UpdateTagsForReso // // Returned Error Codes: // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // * ErrCodeOperationInProgressException "OperationInProgressFailure" @@ -3636,7 +3719,7 @@ const opValidateConfigurationSettings = "ValidateConfigurationSettings" // ValidateConfigurationSettingsRequest generates a "aws/request.Request" representing the // client's request for the ValidateConfigurationSettings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3691,7 +3774,7 @@ func (c *ElasticBeanstalk) ValidateConfigurationSettingsRequest(input *ValidateC // // Returned Error Codes: // * ErrCodeInsufficientPrivilegesException "InsufficientPrivilegesException" -// The specified account does not have sufficient privileges for one of more +// The specified account does not have sufficient privileges for one or more // AWS services. // // * ErrCodeTooManyBucketsException "TooManyBucketsException" @@ -6192,6 +6275,43 @@ func (s *Deployment) SetVersionLabel(v string) *Deployment { return s } +type DescribeAccountAttributesInput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DescribeAccountAttributesInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeAccountAttributesInput) GoString() string { + return s.String() +} + +type DescribeAccountAttributesOutput struct { + _ struct{} `type:"structure"` + + // The Elastic Beanstalk resource quotas associated with the calling AWS account. + ResourceQuotas *ResourceQuotas `type:"structure"` +} + +// String returns the string representation +func (s DescribeAccountAttributesOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeAccountAttributesOutput) GoString() string { + return s.String() +} + +// SetResourceQuotas sets the ResourceQuotas field's value. +func (s *DescribeAccountAttributesOutput) SetResourceQuotas(v *ResourceQuotas) *DescribeAccountAttributesOutput { + s.ResourceQuotas = v + return s +} + // Request to describe application versions. type DescribeApplicationVersionsInput struct { _ struct{} `type:"structure"` @@ -9527,6 +9647,93 @@ func (s RequestEnvironmentInfoOutput) GoString() string { return s.String() } +// The AWS Elastic Beanstalk quota information for a single resource type in +// an AWS account. It reflects the resource's limits for this account. +type ResourceQuota struct { + _ struct{} `type:"structure"` + + // The maximum number of instances of this Elastic Beanstalk resource type that + // an AWS account can use. + Maximum *int64 `type:"integer"` +} + +// String returns the string representation +func (s ResourceQuota) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ResourceQuota) GoString() string { + return s.String() +} + +// SetMaximum sets the Maximum field's value. +func (s *ResourceQuota) SetMaximum(v int64) *ResourceQuota { + s.Maximum = &v + return s +} + +// A set of per-resource AWS Elastic Beanstalk quotas associated with an AWS +// account. They reflect Elastic Beanstalk resource limits for this account. +type ResourceQuotas struct { + _ struct{} `type:"structure"` + + // The quota for applications in the AWS account. + ApplicationQuota *ResourceQuota `type:"structure"` + + // The quota for application versions in the AWS account. + ApplicationVersionQuota *ResourceQuota `type:"structure"` + + // The quota for configuration templates in the AWS account. + ConfigurationTemplateQuota *ResourceQuota `type:"structure"` + + // The quota for custom platforms in the AWS account. + CustomPlatformQuota *ResourceQuota `type:"structure"` + + // The quota for environments in the AWS account. + EnvironmentQuota *ResourceQuota `type:"structure"` +} + +// String returns the string representation +func (s ResourceQuotas) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ResourceQuotas) GoString() string { + return s.String() +} + +// SetApplicationQuota sets the ApplicationQuota field's value. +func (s *ResourceQuotas) SetApplicationQuota(v *ResourceQuota) *ResourceQuotas { + s.ApplicationQuota = v + return s +} + +// SetApplicationVersionQuota sets the ApplicationVersionQuota field's value. +func (s *ResourceQuotas) SetApplicationVersionQuota(v *ResourceQuota) *ResourceQuotas { + s.ApplicationVersionQuota = v + return s +} + +// SetConfigurationTemplateQuota sets the ConfigurationTemplateQuota field's value. +func (s *ResourceQuotas) SetConfigurationTemplateQuota(v *ResourceQuota) *ResourceQuotas { + s.ConfigurationTemplateQuota = v + return s +} + +// SetCustomPlatformQuota sets the CustomPlatformQuota field's value. +func (s *ResourceQuotas) SetCustomPlatformQuota(v *ResourceQuota) *ResourceQuotas { + s.CustomPlatformQuota = v + return s +} + +// SetEnvironmentQuota sets the EnvironmentQuota field's value. +func (s *ResourceQuotas) SetEnvironmentQuota(v *ResourceQuota) *ResourceQuotas { + s.EnvironmentQuota = v + return s +} + type RestartAppServerInput struct { _ struct{} `type:"structure"` diff --git a/vendor/github.com/aws/aws-sdk-go/service/elasticbeanstalk/errors.go b/vendor/github.com/aws/aws-sdk-go/service/elasticbeanstalk/errors.go index 6373e870ae77..adb0f27e3dd0 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/elasticbeanstalk/errors.go +++ b/vendor/github.com/aws/aws-sdk-go/service/elasticbeanstalk/errors.go @@ -13,7 +13,7 @@ const ( // ErrCodeInsufficientPrivilegesException for service response error code // "InsufficientPrivilegesException". // - // The specified account does not have sufficient privileges for one of more + // The specified account does not have sufficient privileges for one or more // AWS services. ErrCodeInsufficientPrivilegesException = "InsufficientPrivilegesException" diff --git a/vendor/github.com/aws/aws-sdk-go/service/elasticsearchservice/api.go b/vendor/github.com/aws/aws-sdk-go/service/elasticsearchservice/api.go index dc5672d021bb..0784f815ec05 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/elasticsearchservice/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/elasticsearchservice/api.go @@ -17,7 +17,7 @@ const opAddTags = "AddTags" // AddTagsRequest generates a "aws/request.Request" representing the // client's request for the AddTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -110,7 +110,7 @@ const opCreateElasticsearchDomain = "CreateElasticsearchDomain" // CreateElasticsearchDomainRequest generates a "aws/request.Request" representing the // client's request for the CreateElasticsearchDomain operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -213,7 +213,7 @@ const opDeleteElasticsearchDomain = "DeleteElasticsearchDomain" // DeleteElasticsearchDomainRequest generates a "aws/request.Request" representing the // client's request for the DeleteElasticsearchDomain operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -303,7 +303,7 @@ const opDeleteElasticsearchServiceRole = "DeleteElasticsearchServiceRole" // DeleteElasticsearchServiceRoleRequest generates a "aws/request.Request" representing the // client's request for the DeleteElasticsearchServiceRole operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -394,7 +394,7 @@ const opDescribeElasticsearchDomain = "DescribeElasticsearchDomain" // DescribeElasticsearchDomainRequest generates a "aws/request.Request" representing the // client's request for the DescribeElasticsearchDomain operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -484,7 +484,7 @@ const opDescribeElasticsearchDomainConfig = "DescribeElasticsearchDomainConfig" // DescribeElasticsearchDomainConfigRequest generates a "aws/request.Request" representing the // client's request for the DescribeElasticsearchDomainConfig operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -575,7 +575,7 @@ const opDescribeElasticsearchDomains = "DescribeElasticsearchDomains" // DescribeElasticsearchDomainsRequest generates a "aws/request.Request" representing the // client's request for the DescribeElasticsearchDomains operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -661,7 +661,7 @@ const opDescribeElasticsearchInstanceTypeLimits = "DescribeElasticsearchInstance // DescribeElasticsearchInstanceTypeLimitsRequest generates a "aws/request.Request" representing the // client's request for the DescribeElasticsearchInstanceTypeLimits operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -760,7 +760,7 @@ const opListDomainNames = "ListDomainNames" // ListDomainNamesRequest generates a "aws/request.Request" representing the // client's request for the ListDomainNames operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -841,7 +841,7 @@ const opListElasticsearchInstanceTypes = "ListElasticsearchInstanceTypes" // ListElasticsearchInstanceTypesRequest generates a "aws/request.Request" representing the // client's request for the ListElasticsearchInstanceTypes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -986,7 +986,7 @@ const opListElasticsearchVersions = "ListElasticsearchVersions" // ListElasticsearchVersionsRequest generates a "aws/request.Request" representing the // client's request for the ListElasticsearchVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1131,7 +1131,7 @@ const opListTags = "ListTags" // ListTagsRequest generates a "aws/request.Request" representing the // client's request for the ListTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1220,7 +1220,7 @@ const opRemoveTags = "RemoveTags" // RemoveTagsRequest generates a "aws/request.Request" representing the // client's request for the RemoveTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1307,7 +1307,7 @@ const opUpdateElasticsearchDomainConfig = "UpdateElasticsearchDomainConfig" // UpdateElasticsearchDomainConfigRequest generates a "aws/request.Request" representing the // client's request for the UpdateElasticsearchDomainConfig operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1608,6 +1608,116 @@ func (s *AdvancedOptionsStatus) SetStatus(v *OptionStatus) *AdvancedOptionsStatu return s } +// Options to specify the Cognito user and identity pools for Kibana authentication. +// For more information, see Amazon Cognito Authentication for Kibana (http://docs.aws.amazon.com/elasticsearch-service/latest/developerguide/es-cognito-auth.html). +type CognitoOptions struct { + _ struct{} `type:"structure"` + + // Specifies the option to enable Cognito for Kibana authentication. + Enabled *bool `type:"boolean"` + + // Specifies the Cognito identity pool ID for Kibana authentication. + IdentityPoolId *string `min:"1" type:"string"` + + // Specifies the role ARN that provides Elasticsearch permissions for accessing + // Cognito resources. + RoleArn *string `min:"20" type:"string"` + + // Specifies the Cognito user pool ID for Kibana authentication. + UserPoolId *string `min:"1" type:"string"` +} + +// String returns the string representation +func (s CognitoOptions) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CognitoOptions) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CognitoOptions) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CognitoOptions"} + if s.IdentityPoolId != nil && len(*s.IdentityPoolId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("IdentityPoolId", 1)) + } + if s.RoleArn != nil && len(*s.RoleArn) < 20 { + invalidParams.Add(request.NewErrParamMinLen("RoleArn", 20)) + } + if s.UserPoolId != nil && len(*s.UserPoolId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("UserPoolId", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetEnabled sets the Enabled field's value. +func (s *CognitoOptions) SetEnabled(v bool) *CognitoOptions { + s.Enabled = &v + return s +} + +// SetIdentityPoolId sets the IdentityPoolId field's value. +func (s *CognitoOptions) SetIdentityPoolId(v string) *CognitoOptions { + s.IdentityPoolId = &v + return s +} + +// SetRoleArn sets the RoleArn field's value. +func (s *CognitoOptions) SetRoleArn(v string) *CognitoOptions { + s.RoleArn = &v + return s +} + +// SetUserPoolId sets the UserPoolId field's value. +func (s *CognitoOptions) SetUserPoolId(v string) *CognitoOptions { + s.UserPoolId = &v + return s +} + +// Status of the Cognito options for the specified Elasticsearch domain. +type CognitoOptionsStatus struct { + _ struct{} `type:"structure"` + + // Specifies the Cognito options for the specified Elasticsearch domain. + // + // Options is a required field + Options *CognitoOptions `type:"structure" required:"true"` + + // Specifies the status of the Cognito options for the specified Elasticsearch + // domain. + // + // Status is a required field + Status *OptionStatus `type:"structure" required:"true"` +} + +// String returns the string representation +func (s CognitoOptionsStatus) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CognitoOptionsStatus) GoString() string { + return s.String() +} + +// SetOptions sets the Options field's value. +func (s *CognitoOptionsStatus) SetOptions(v *CognitoOptions) *CognitoOptionsStatus { + s.Options = v + return s +} + +// SetStatus sets the Status field's value. +func (s *CognitoOptionsStatus) SetStatus(v *OptionStatus) *CognitoOptionsStatus { + s.Status = v + return s +} + type CreateElasticsearchDomainInput struct { _ struct{} `type:"structure"` @@ -1620,6 +1730,10 @@ type CreateElasticsearchDomainInput struct { // for more information. AdvancedOptions map[string]*string `type:"map"` + // Options to specify the Cognito user and identity pools for Kibana authentication. + // For more information, see Amazon Cognito Authentication for Kibana (http://docs.aws.amazon.com/elasticsearch-service/latest/developerguide/es-cognito-auth.html). + CognitoOptions *CognitoOptions `type:"structure"` + // The name of the Elasticsearch domain that you are creating. Domain names // are unique across the domains owned by an account within an AWS region. Domain // names must start with a letter or number and can contain the following characters: @@ -1677,6 +1791,11 @@ func (s *CreateElasticsearchDomainInput) Validate() error { if s.DomainName != nil && len(*s.DomainName) < 3 { invalidParams.Add(request.NewErrParamMinLen("DomainName", 3)) } + if s.CognitoOptions != nil { + if err := s.CognitoOptions.Validate(); err != nil { + invalidParams.AddNested("CognitoOptions", err.(request.ErrInvalidParams)) + } + } if s.EncryptionAtRestOptions != nil { if err := s.EncryptionAtRestOptions.Validate(); err != nil { invalidParams.AddNested("EncryptionAtRestOptions", err.(request.ErrInvalidParams)) @@ -1701,6 +1820,12 @@ func (s *CreateElasticsearchDomainInput) SetAdvancedOptions(v map[string]*string return s } +// SetCognitoOptions sets the CognitoOptions field's value. +func (s *CreateElasticsearchDomainInput) SetCognitoOptions(v *CognitoOptions) *CreateElasticsearchDomainInput { + s.CognitoOptions = v + return s +} + // SetDomainName sets the DomainName field's value. func (s *CreateElasticsearchDomainInput) SetDomainName(v string) *CreateElasticsearchDomainInput { s.DomainName = &v @@ -2410,6 +2535,10 @@ type ElasticsearchDomainConfig struct { // for more information. AdvancedOptions *AdvancedOptionsStatus `type:"structure"` + // The CognitoOptions for the specified domain. For more information, see Amazon + // Cognito Authentication for Kibana (http://docs.aws.amazon.com/elasticsearch-service/latest/developerguide/es-cognito-auth.html). + CognitoOptions *CognitoOptionsStatus `type:"structure"` + // Specifies the EBSOptions for the Elasticsearch domain. EBSOptions *EBSOptionsStatus `type:"structure"` @@ -2455,6 +2584,12 @@ func (s *ElasticsearchDomainConfig) SetAdvancedOptions(v *AdvancedOptionsStatus) return s } +// SetCognitoOptions sets the CognitoOptions field's value. +func (s *ElasticsearchDomainConfig) SetCognitoOptions(v *CognitoOptionsStatus) *ElasticsearchDomainConfig { + s.CognitoOptions = v + return s +} + // SetEBSOptions sets the EBSOptions field's value. func (s *ElasticsearchDomainConfig) SetEBSOptions(v *EBSOptionsStatus) *ElasticsearchDomainConfig { s.EBSOptions = v @@ -2514,6 +2649,10 @@ type ElasticsearchDomainStatus struct { // Specifies the status of the AdvancedOptions AdvancedOptions map[string]*string `type:"map"` + // The CognitoOptions for the specified domain. For more information, see Amazon + // Cognito Authentication for Kibana (http://docs.aws.amazon.com/elasticsearch-service/latest/developerguide/es-cognito-auth.html). + CognitoOptions *CognitoOptions `type:"structure"` + // The domain creation status. True if the creation of an Elasticsearch domain // is complete. False if domain creation is still in progress. Created *bool `type:"boolean"` @@ -2604,6 +2743,12 @@ func (s *ElasticsearchDomainStatus) SetAdvancedOptions(v map[string]*string) *El return s } +// SetCognitoOptions sets the CognitoOptions field's value. +func (s *ElasticsearchDomainStatus) SetCognitoOptions(v *CognitoOptions) *ElasticsearchDomainStatus { + s.CognitoOptions = v + return s +} + // SetCreated sets the Created field's value. func (s *ElasticsearchDomainStatus) SetCreated(v bool) *ElasticsearchDomainStatus { s.Created = &v @@ -3646,6 +3791,10 @@ type UpdateElasticsearchDomainConfigInput struct { // for more information. AdvancedOptions map[string]*string `type:"map"` + // Options to specify the Cognito user and identity pools for Kibana authentication. + // For more information, see Amazon Cognito Authentication for Kibana (http://docs.aws.amazon.com/elasticsearch-service/latest/developerguide/es-cognito-auth.html). + CognitoOptions *CognitoOptions `type:"structure"` + // The name of the Elasticsearch domain that you are updating. // // DomainName is a required field @@ -3690,6 +3839,11 @@ func (s *UpdateElasticsearchDomainConfigInput) Validate() error { if s.DomainName != nil && len(*s.DomainName) < 3 { invalidParams.Add(request.NewErrParamMinLen("DomainName", 3)) } + if s.CognitoOptions != nil { + if err := s.CognitoOptions.Validate(); err != nil { + invalidParams.AddNested("CognitoOptions", err.(request.ErrInvalidParams)) + } + } if invalidParams.Len() > 0 { return invalidParams @@ -3709,6 +3863,12 @@ func (s *UpdateElasticsearchDomainConfigInput) SetAdvancedOptions(v map[string]* return s } +// SetCognitoOptions sets the CognitoOptions field's value. +func (s *UpdateElasticsearchDomainConfigInput) SetCognitoOptions(v *CognitoOptions) *UpdateElasticsearchDomainConfigInput { + s.CognitoOptions = v + return s +} + // SetDomainName sets the DomainName field's value. func (s *UpdateElasticsearchDomainConfigInput) SetDomainName(v string) *UpdateElasticsearchDomainConfigInput { s.DomainName = &v diff --git a/vendor/github.com/aws/aws-sdk-go/service/elastictranscoder/api.go b/vendor/github.com/aws/aws-sdk-go/service/elastictranscoder/api.go index 96ca242ffb44..9ba387e93ebb 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/elastictranscoder/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/elastictranscoder/api.go @@ -14,7 +14,7 @@ const opCancelJob = "CancelJob" // CancelJobRequest generates a "aws/request.Request" representing the // client's request for the CancelJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -112,7 +112,7 @@ const opCreateJob = "CreateJob" // CreateJobRequest generates a "aws/request.Request" representing the // client's request for the CreateJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -212,7 +212,7 @@ const opCreatePipeline = "CreatePipeline" // CreatePipelineRequest generates a "aws/request.Request" representing the // client's request for the CreatePipeline operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -306,7 +306,7 @@ const opCreatePreset = "CreatePreset" // CreatePresetRequest generates a "aws/request.Request" representing the // client's request for the CreatePreset operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -409,7 +409,7 @@ const opDeletePipeline = "DeletePipeline" // DeletePipelineRequest generates a "aws/request.Request" representing the // client's request for the DeletePipeline operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -507,7 +507,7 @@ const opDeletePreset = "DeletePreset" // DeletePresetRequest generates a "aws/request.Request" representing the // client's request for the DeletePreset operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -599,7 +599,7 @@ const opListJobsByPipeline = "ListJobsByPipeline" // ListJobsByPipelineRequest generates a "aws/request.Request" representing the // client's request for the ListJobsByPipeline operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -749,7 +749,7 @@ const opListJobsByStatus = "ListJobsByStatus" // ListJobsByStatusRequest generates a "aws/request.Request" representing the // client's request for the ListJobsByStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -897,7 +897,7 @@ const opListPipelines = "ListPipelines" // ListPipelinesRequest generates a "aws/request.Request" representing the // client's request for the ListPipelines operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1039,7 +1039,7 @@ const opListPresets = "ListPresets" // ListPresetsRequest generates a "aws/request.Request" representing the // client's request for the ListPresets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1181,7 +1181,7 @@ const opReadJob = "ReadJob" // ReadJobRequest generates a "aws/request.Request" representing the // client's request for the ReadJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1271,7 +1271,7 @@ const opReadPipeline = "ReadPipeline" // ReadPipelineRequest generates a "aws/request.Request" representing the // client's request for the ReadPipeline operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1361,7 +1361,7 @@ const opReadPreset = "ReadPreset" // ReadPresetRequest generates a "aws/request.Request" representing the // client's request for the ReadPreset operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1451,7 +1451,7 @@ const opTestRole = "TestRole" // TestRoleRequest generates a "aws/request.Request" representing the // client's request for the TestRole operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1550,7 +1550,7 @@ const opUpdatePipeline = "UpdatePipeline" // UpdatePipelineRequest generates a "aws/request.Request" representing the // client's request for the UpdatePipeline operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1649,7 +1649,7 @@ const opUpdatePipelineNotifications = "UpdatePipelineNotifications" // UpdatePipelineNotificationsRequest generates a "aws/request.Request" representing the // client's request for the UpdatePipelineNotifications operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1747,7 +1747,7 @@ const opUpdatePipelineStatus = "UpdatePipelineStatus" // UpdatePipelineStatusRequest generates a "aws/request.Request" representing the // client's request for the UpdatePipelineStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/elb/api.go b/vendor/github.com/aws/aws-sdk-go/service/elb/api.go index 66658a1a68d4..26720a34204f 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/elb/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/elb/api.go @@ -15,7 +15,7 @@ const opAddTags = "AddTags" // AddTagsRequest generates a "aws/request.Request" representing the // client's request for the AddTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -108,7 +108,7 @@ const opApplySecurityGroupsToLoadBalancer = "ApplySecurityGroupsToLoadBalancer" // ApplySecurityGroupsToLoadBalancerRequest generates a "aws/request.Request" representing the // client's request for the ApplySecurityGroupsToLoadBalancer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -198,7 +198,7 @@ const opAttachLoadBalancerToSubnets = "AttachLoadBalancerToSubnets" // AttachLoadBalancerToSubnetsRequest generates a "aws/request.Request" representing the // client's request for the AttachLoadBalancerToSubnets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -292,7 +292,7 @@ const opConfigureHealthCheck = "ConfigureHealthCheck" // ConfigureHealthCheckRequest generates a "aws/request.Request" representing the // client's request for the ConfigureHealthCheck operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -376,7 +376,7 @@ const opCreateAppCookieStickinessPolicy = "CreateAppCookieStickinessPolicy" // CreateAppCookieStickinessPolicyRequest generates a "aws/request.Request" representing the // client's request for the CreateAppCookieStickinessPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -478,7 +478,7 @@ const opCreateLBCookieStickinessPolicy = "CreateLBCookieStickinessPolicy" // CreateLBCookieStickinessPolicyRequest generates a "aws/request.Request" representing the // client's request for the CreateLBCookieStickinessPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -582,7 +582,7 @@ const opCreateLoadBalancer = "CreateLoadBalancer" // CreateLoadBalancerRequest generates a "aws/request.Request" representing the // client's request for the CreateLoadBalancer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -711,7 +711,7 @@ const opCreateLoadBalancerListeners = "CreateLoadBalancerListeners" // CreateLoadBalancerListenersRequest generates a "aws/request.Request" representing the // client's request for the CreateLoadBalancerListeners operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -812,7 +812,7 @@ const opCreateLoadBalancerPolicy = "CreateLoadBalancerPolicy" // CreateLoadBalancerPolicyRequest generates a "aws/request.Request" representing the // client's request for the CreateLoadBalancerPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -907,7 +907,7 @@ const opDeleteLoadBalancer = "DeleteLoadBalancer" // DeleteLoadBalancerRequest generates a "aws/request.Request" representing the // client's request for the DeleteLoadBalancer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -990,7 +990,7 @@ const opDeleteLoadBalancerListeners = "DeleteLoadBalancerListeners" // DeleteLoadBalancerListenersRequest generates a "aws/request.Request" representing the // client's request for the DeleteLoadBalancerListeners operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1069,7 +1069,7 @@ const opDeleteLoadBalancerPolicy = "DeleteLoadBalancerPolicy" // DeleteLoadBalancerPolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteLoadBalancerPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1152,7 +1152,7 @@ const opDeregisterInstancesFromLoadBalancer = "DeregisterInstancesFromLoadBalanc // DeregisterInstancesFromLoadBalancerRequest generates a "aws/request.Request" representing the // client's request for the DeregisterInstancesFromLoadBalancer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1242,7 +1242,7 @@ const opDescribeAccountLimits = "DescribeAccountLimits" // DescribeAccountLimitsRequest generates a "aws/request.Request" representing the // client's request for the DescribeAccountLimits operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1320,7 +1320,7 @@ const opDescribeInstanceHealth = "DescribeInstanceHealth" // DescribeInstanceHealthRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstanceHealth operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1407,7 +1407,7 @@ const opDescribeLoadBalancerAttributes = "DescribeLoadBalancerAttributes" // DescribeLoadBalancerAttributesRequest generates a "aws/request.Request" representing the // client's request for the DescribeLoadBalancerAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1489,7 +1489,7 @@ const opDescribeLoadBalancerPolicies = "DescribeLoadBalancerPolicies" // DescribeLoadBalancerPoliciesRequest generates a "aws/request.Request" representing the // client's request for the DescribeLoadBalancerPolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1578,7 +1578,7 @@ const opDescribeLoadBalancerPolicyTypes = "DescribeLoadBalancerPolicyTypes" // DescribeLoadBalancerPolicyTypesRequest generates a "aws/request.Request" representing the // client's request for the DescribeLoadBalancerPolicyTypes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1668,7 +1668,7 @@ const opDescribeLoadBalancers = "DescribeLoadBalancers" // DescribeLoadBalancersRequest generates a "aws/request.Request" representing the // client's request for the DescribeLoadBalancers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1806,7 +1806,7 @@ const opDescribeTags = "DescribeTags" // DescribeTagsRequest generates a "aws/request.Request" representing the // client's request for the DescribeTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1885,7 +1885,7 @@ const opDetachLoadBalancerFromSubnets = "DetachLoadBalancerFromSubnets" // DetachLoadBalancerFromSubnetsRequest generates a "aws/request.Request" representing the // client's request for the DetachLoadBalancerFromSubnets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1972,7 +1972,7 @@ const opDisableAvailabilityZonesForLoadBalancer = "DisableAvailabilityZonesForLo // DisableAvailabilityZonesForLoadBalancerRequest generates a "aws/request.Request" representing the // client's request for the DisableAvailabilityZonesForLoadBalancer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2064,7 +2064,7 @@ const opEnableAvailabilityZonesForLoadBalancer = "EnableAvailabilityZonesForLoad // EnableAvailabilityZonesForLoadBalancerRequest generates a "aws/request.Request" representing the // client's request for the EnableAvailabilityZonesForLoadBalancer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2150,7 +2150,7 @@ const opModifyLoadBalancerAttributes = "ModifyLoadBalancerAttributes" // ModifyLoadBalancerAttributesRequest generates a "aws/request.Request" representing the // client's request for the ModifyLoadBalancerAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2250,7 +2250,7 @@ const opRegisterInstancesWithLoadBalancer = "RegisterInstancesWithLoadBalancer" // RegisterInstancesWithLoadBalancerRequest generates a "aws/request.Request" representing the // client's request for the RegisterInstancesWithLoadBalancer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2354,7 +2354,7 @@ const opRemoveTags = "RemoveTags" // RemoveTagsRequest generates a "aws/request.Request" representing the // client's request for the RemoveTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2433,7 +2433,7 @@ const opSetLoadBalancerListenerSSLCertificate = "SetLoadBalancerListenerSSLCerti // SetLoadBalancerListenerSSLCertificateRequest generates a "aws/request.Request" representing the // client's request for the SetLoadBalancerListenerSSLCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2533,7 +2533,7 @@ const opSetLoadBalancerPoliciesForBackendServer = "SetLoadBalancerPoliciesForBac // SetLoadBalancerPoliciesForBackendServerRequest generates a "aws/request.Request" representing the // client's request for the SetLoadBalancerPoliciesForBackendServer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2633,7 +2633,7 @@ const opSetLoadBalancerPoliciesOfListener = "SetLoadBalancerPoliciesOfListener" // SetLoadBalancerPoliciesOfListenerRequest generates a "aws/request.Request" representing the // client's request for the SetLoadBalancerPoliciesOfListener operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/elbv2/api.go b/vendor/github.com/aws/aws-sdk-go/service/elbv2/api.go index 359bc6c45273..5a60ca656ea1 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/elbv2/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/elbv2/api.go @@ -15,7 +15,7 @@ const opAddListenerCertificates = "AddListenerCertificates" // AddListenerCertificatesRequest generates a "aws/request.Request" representing the // client's request for the AddListenerCertificates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -106,7 +106,7 @@ const opAddTags = "AddTags" // AddTagsRequest generates a "aws/request.Request" representing the // client's request for the AddTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -202,7 +202,7 @@ const opCreateListener = "CreateListener" // CreateListenerRequest generates a "aws/request.Request" representing the // client's request for the CreateListener operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -245,12 +245,14 @@ func (c *ELBV2) CreateListenerRequest(input *CreateListenerInput) (req *request. // Creates a listener for the specified Application Load Balancer or Network // Load Balancer. // -// You can create up to 10 listeners per load balancer. -// // To update a listener, use ModifyListener. When you are finished with a listener, // you can delete it using DeleteListener. If you are finished with both the // listener and the load balancer, you can delete them both using DeleteLoadBalancer. // +// This operation is idempotent, which means that it completes at most one time. +// If you attempt to create multiple listeners with the same settings, each +// call succeeds. +// // For more information, see Listeners for Your Application Load Balancers (http://docs.aws.amazon.com/elasticloadbalancing/latest/application/load-balancer-listeners.html) // in the Application Load Balancers Guide and Listeners for Your Network Load // Balancers (http://docs.aws.amazon.com/elasticloadbalancing/latest/network/load-balancer-listeners.html) @@ -330,7 +332,7 @@ const opCreateLoadBalancer = "CreateLoadBalancer" // CreateLoadBalancerRequest generates a "aws/request.Request" representing the // client's request for the CreateLoadBalancer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -372,21 +374,23 @@ func (c *ELBV2) CreateLoadBalancerRequest(input *CreateLoadBalancerInput) (req * // // Creates an Application Load Balancer or a Network Load Balancer. // -// When you create a load balancer, you can specify security groups, subnets, -// IP address type, and tags. Otherwise, you could do so later using SetSecurityGroups, -// SetSubnets, SetIpAddressType, and AddTags. +// When you create a load balancer, you can specify security groups, public +// subnets, IP address type, and tags. Otherwise, you could do so later using +// SetSecurityGroups, SetSubnets, SetIpAddressType, and AddTags. // // To create listeners for your load balancer, use CreateListener. To describe // your current load balancers, see DescribeLoadBalancers. When you are finished // with a load balancer, you can delete it using DeleteLoadBalancer. // -// You can create up to 20 load balancers per region per account. You can request -// an increase for the number of load balancers for your account. For more information, -// see Limits for Your Application Load Balancer (http://docs.aws.amazon.com/elasticloadbalancing/latest/application/load-balancer-limits.html) +// For limit information, see Limits for Your Application Load Balancer (http://docs.aws.amazon.com/elasticloadbalancing/latest/application/load-balancer-limits.html) // in the Application Load Balancers Guide and Limits for Your Network Load // Balancer (http://docs.aws.amazon.com/elasticloadbalancing/latest/network/load-balancer-limits.html) // in the Network Load Balancers Guide. // +// This operation is idempotent, which means that it completes at most one time. +// If you attempt to create multiple load balancers with the same settings, +// each call succeeds. +// // For more information, see Application Load Balancers (http://docs.aws.amazon.com/elasticloadbalancing/latest/application/application-load-balancers.html) // in the Application Load Balancers Guide and Network Load Balancers (http://docs.aws.amazon.com/elasticloadbalancing/latest/network/network-load-balancers.html) // in the Network Load Balancers Guide. @@ -464,7 +468,7 @@ const opCreateRule = "CreateRule" // CreateRuleRequest generates a "aws/request.Request" representing the // client's request for the CreateRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -582,7 +586,7 @@ const opCreateTargetGroup = "CreateTargetGroup" // CreateTargetGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateTargetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -633,6 +637,10 @@ func (c *ELBV2) CreateTargetGroupRequest(input *CreateTargetGroupInput) (req *re // // To delete a target group, use DeleteTargetGroup. // +// This operation is idempotent, which means that it completes at most one time. +// If you attempt to create multiple target groups with the same settings, each +// call succeeds. +// // For more information, see Target Groups for Your Application Load Balancers // (http://docs.aws.amazon.com/elasticloadbalancing/latest/application/load-balancer-target-groups.html) // in the Application Load Balancers Guide or Target Groups for Your Network @@ -682,7 +690,7 @@ const opDeleteListener = "DeleteListener" // DeleteListenerRequest generates a "aws/request.Request" representing the // client's request for the DeleteListener operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -764,7 +772,7 @@ const opDeleteLoadBalancer = "DeleteLoadBalancer" // DeleteLoadBalancerRequest generates a "aws/request.Request" representing the // client's request for the DeleteLoadBalancer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -858,7 +866,7 @@ const opDeleteRule = "DeleteRule" // DeleteRuleRequest generates a "aws/request.Request" representing the // client's request for the DeleteRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -940,7 +948,7 @@ const opDeleteTargetGroup = "DeleteTargetGroup" // DeleteTargetGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteTargetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1022,7 +1030,7 @@ const opDeregisterTargets = "DeregisterTargets" // DeregisterTargetsRequest generates a "aws/request.Request" representing the // client's request for the DeregisterTargets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1078,8 +1086,8 @@ func (c *ELBV2) DeregisterTargetsRequest(input *DeregisterTargetsInput) (req *re // The specified target group does not exist. // // * ErrCodeInvalidTargetException "InvalidTarget" -// The specified target does not exist or is not in the same VPC as the target -// group. +// The specified target does not exist, is not in the same VPC as the target +// group, or has an unsupported instance type. // // See also, https://docs.aws.amazon.com/goto/WebAPI/elasticloadbalancingv2-2015-12-01/DeregisterTargets func (c *ELBV2) DeregisterTargets(input *DeregisterTargetsInput) (*DeregisterTargetsOutput, error) { @@ -1107,7 +1115,7 @@ const opDescribeAccountLimits = "DescribeAccountLimits" // DescribeAccountLimitsRequest generates a "aws/request.Request" representing the // client's request for the DescribeAccountLimits operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1187,7 +1195,7 @@ const opDescribeListenerCertificates = "DescribeListenerCertificates" // DescribeListenerCertificatesRequest generates a "aws/request.Request" representing the // client's request for the DescribeListenerCertificates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1266,7 +1274,7 @@ const opDescribeListeners = "DescribeListeners" // DescribeListenersRequest generates a "aws/request.Request" representing the // client's request for the DescribeListeners operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1406,7 +1414,7 @@ const opDescribeLoadBalancerAttributes = "DescribeLoadBalancerAttributes" // DescribeLoadBalancerAttributesRequest generates a "aws/request.Request" representing the // client's request for the DescribeLoadBalancerAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1486,7 +1494,7 @@ const opDescribeLoadBalancers = "DescribeLoadBalancers" // DescribeLoadBalancersRequest generates a "aws/request.Request" representing the // client's request for the DescribeLoadBalancers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1624,7 +1632,7 @@ const opDescribeRules = "DescribeRules" // DescribeRulesRequest generates a "aws/request.Request" representing the // client's request for the DescribeRules operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1707,7 +1715,7 @@ const opDescribeSSLPolicies = "DescribeSSLPolicies" // DescribeSSLPoliciesRequest generates a "aws/request.Request" representing the // client's request for the DescribeSSLPolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1789,7 +1797,7 @@ const opDescribeTags = "DescribeTags" // DescribeTagsRequest generates a "aws/request.Request" representing the // client's request for the DescribeTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1879,7 +1887,7 @@ const opDescribeTargetGroupAttributes = "DescribeTargetGroupAttributes" // DescribeTargetGroupAttributesRequest generates a "aws/request.Request" representing the // client's request for the DescribeTargetGroupAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1958,7 +1966,7 @@ const opDescribeTargetGroups = "DescribeTargetGroups" // DescribeTargetGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeTargetGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2102,7 +2110,7 @@ const opDescribeTargetHealth = "DescribeTargetHealth" // DescribeTargetHealthRequest generates a "aws/request.Request" representing the // client's request for the DescribeTargetHealth operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2153,8 +2161,8 @@ func (c *ELBV2) DescribeTargetHealthRequest(input *DescribeTargetHealthInput) (r // // Returned Error Codes: // * ErrCodeInvalidTargetException "InvalidTarget" -// The specified target does not exist or is not in the same VPC as the target -// group. +// The specified target does not exist, is not in the same VPC as the target +// group, or has an unsupported instance type. // // * ErrCodeTargetGroupNotFoundException "TargetGroupNotFound" // The specified target group does not exist. @@ -2189,7 +2197,7 @@ const opModifyListener = "ModifyListener" // ModifyListenerRequest generates a "aws/request.Request" representing the // client's request for the ModifyListener operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2310,7 +2318,7 @@ const opModifyLoadBalancerAttributes = "ModifyLoadBalancerAttributes" // ModifyLoadBalancerAttributesRequest generates a "aws/request.Request" representing the // client's request for the ModifyLoadBalancerAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2397,7 +2405,7 @@ const opModifyRule = "ModifyRule" // ModifyRuleRequest generates a "aws/request.Request" representing the // client's request for the ModifyRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2499,7 +2507,7 @@ const opModifyTargetGroup = "ModifyTargetGroup" // ModifyTargetGroupRequest generates a "aws/request.Request" representing the // client's request for the ModifyTargetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2584,7 +2592,7 @@ const opModifyTargetGroupAttributes = "ModifyTargetGroupAttributes" // ModifyTargetGroupAttributesRequest generates a "aws/request.Request" representing the // client's request for the ModifyTargetGroupAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2666,7 +2674,7 @@ const opRegisterTargets = "RegisterTargets" // RegisterTargetsRequest generates a "aws/request.Request" representing the // client's request for the RegisterTargets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2738,8 +2746,8 @@ func (c *ELBV2) RegisterTargetsRequest(input *RegisterTargetsInput) (req *reques // You've reached the limit on the number of targets. // // * ErrCodeInvalidTargetException "InvalidTarget" -// The specified target does not exist or is not in the same VPC as the target -// group. +// The specified target does not exist, is not in the same VPC as the target +// group, or has an unsupported instance type. // // * ErrCodeTooManyRegistrationsForTargetIdException "TooManyRegistrationsForTargetId" // You've reached the limit on the number of times a target can be registered @@ -2771,7 +2779,7 @@ const opRemoveListenerCertificates = "RemoveListenerCertificates" // RemoveListenerCertificatesRequest generates a "aws/request.Request" representing the // client's request for the RemoveListenerCertificates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2858,7 +2866,7 @@ const opRemoveTags = "RemoveTags" // RemoveTagsRequest generates a "aws/request.Request" representing the // client's request for the RemoveTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2951,7 +2959,7 @@ const opSetIpAddressType = "SetIpAddressType" // SetIpAddressTypeRequest generates a "aws/request.Request" representing the // client's request for the SetIpAddressType operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3039,7 +3047,7 @@ const opSetRulePriorities = "SetRulePriorities" // SetRulePrioritiesRequest generates a "aws/request.Request" representing the // client's request for the SetRulePriorities operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3128,7 +3136,7 @@ const opSetSecurityGroups = "SetSecurityGroups" // SetSecurityGroupsRequest generates a "aws/request.Request" representing the // client's request for the SetSecurityGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3217,7 +3225,7 @@ const opSetSubnets = "SetSubnets" // SetSubnetsRequest generates a "aws/request.Request" representing the // client's request for the SetSubnets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3257,7 +3265,7 @@ func (c *ELBV2) SetSubnetsRequest(input *SetSubnetsInput) (req *request.Request, // SetSubnets API operation for Elastic Load Balancing. // -// Enables the Availability Zone for the specified subnets for the specified +// Enables the Availability Zone for the specified public subnets for the specified // Application Load Balancer. The specified subnets replace the previously enabled // subnets. // @@ -3797,32 +3805,34 @@ type CreateLoadBalancerInput struct { // The default is an Internet-facing load balancer. Scheme *string `type:"string" enum:"LoadBalancerSchemeEnum"` - // [Application Load Balancers] The IDs of the security groups to assign to - // the load balancer. + // [Application Load Balancers] The IDs of the security groups for the load + // balancer. SecurityGroups []*string `type:"list"` - // The IDs of the subnets to attach to the load balancer. You can specify only - // one subnet per Availability Zone. You must specify either subnets or subnet - // mappings. + // The IDs of the public subnets. You can specify only one subnet per Availability + // Zone. You must specify either subnets or subnet mappings. // - // [Network Load Balancers] You can specify one Elastic IP address per subnet. + // [Application Load Balancers] You must specify subnets from at least two Availability + // Zones. You cannot specify Elastic IP addresses for your subnets. // - // [Application Load Balancers] You cannot specify Elastic IP addresses for - // your subnets. + // [Network Load Balancers] You can specify subnets from one or more Availability + // Zones. You can specify one Elastic IP address per subnet. SubnetMappings []*SubnetMapping `type:"list"` - // The IDs of the subnets to attach to the load balancer. You can specify only - // one subnet per Availability Zone. You must specify either subnets or subnet - // mappings. + // The IDs of the public subnets. You can specify only one subnet per Availability + // Zone. You must specify either subnets or subnet mappings. // // [Application Load Balancers] You must specify subnets from at least two Availability // Zones. + // + // [Network Load Balancers] You can specify subnets from one or more Availability + // Zones. Subnets []*string `type:"list"` // One or more tags to assign to the load balancer. Tags []*Tag `min:"1" type:"list"` - // The type of load balancer to create. The default is application. + // The type of load balancer. The default is application. Type *string `type:"string" enum:"LoadBalancerTypeEnum"` } @@ -5548,6 +5558,10 @@ type Limit struct { // * target-groups // // * targets-per-application-load-balancer + // + // * targets-per-availability-zone-per-network-load-balancer + // + // * targets-per-network-load-balancer Name *string `type:"string"` } @@ -5844,6 +5858,13 @@ type LoadBalancerAttribute struct { // * idle_timeout.timeout_seconds - [Application Load Balancers] The idle // timeout value, in seconds. The valid range is 1-4000. The default is 60 // seconds. + // + // * load_balancing.cross_zone.enabled - [Network Load Balancers] Indicates + // whether cross-zone load balancing is enabled. The value is true or false. + // The default is false. + // + // * routing.http2.enabled - [Application Load Balancers] Indicates whether + // HTTP/2 is enabled. The value is true or false. The default is true. Key *string `type:"string"` // The value of the attribute. @@ -7085,17 +7106,16 @@ type SetSubnetsInput struct { // LoadBalancerArn is a required field LoadBalancerArn *string `type:"string" required:"true"` - // The IDs of the subnets. You must specify subnets from at least two Availability - // Zones. You can specify only one subnet per Availability Zone. You must specify - // either subnets or subnet mappings. + // The IDs of the public subnets. You must specify subnets from at least two + // Availability Zones. You can specify only one subnet per Availability Zone. + // You must specify either subnets or subnet mappings. // - // The load balancer is allocated one static IP address per subnet. You cannot - // specify your own Elastic IP addresses. + // You cannot specify Elastic IP addresses for your subnets. SubnetMappings []*SubnetMapping `type:"list"` - // The IDs of the subnets. You must specify subnets from at least two Availability - // Zones. You can specify only one subnet per Availability Zone. You must specify - // either subnets or subnet mappings. + // The IDs of the public subnets. You must specify subnets from at least two + // Availability Zones. You can specify only one subnet per Availability Zone. + // You must specify either subnets or subnet mappings. // // Subnets is a required field Subnets []*string `type:"list" required:"true"` @@ -7566,6 +7586,9 @@ type TargetGroupAttribute struct { // from draining to unused. The range is 0-3600 seconds. The default value // is 300 seconds. // + // * proxy_protocol_v2.enabled - [Network Load Balancers] Indicates whether + // Proxy Protocol version 2 is enabled. + // // * stickiness.enabled - [Application Load Balancers] Indicates whether // sticky sessions are enabled. The value is true or false. // diff --git a/vendor/github.com/aws/aws-sdk-go/service/elbv2/errors.go b/vendor/github.com/aws/aws-sdk-go/service/elbv2/errors.go index 4571d645db28..88edc02e9cb1 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/elbv2/errors.go +++ b/vendor/github.com/aws/aws-sdk-go/service/elbv2/errors.go @@ -86,8 +86,8 @@ const ( // ErrCodeInvalidTargetException for service response error code // "InvalidTarget". // - // The specified target does not exist or is not in the same VPC as the target - // group. + // The specified target does not exist, is not in the same VPC as the target + // group, or has an unsupported instance type. ErrCodeInvalidTargetException = "InvalidTarget" // ErrCodeListenerNotFoundException for service response error code diff --git a/vendor/github.com/aws/aws-sdk-go/service/emr/api.go b/vendor/github.com/aws/aws-sdk-go/service/emr/api.go index b9b47e6e6c4d..09c135c9750b 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/emr/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/emr/api.go @@ -17,7 +17,7 @@ const opAddInstanceFleet = "AddInstanceFleet" // AddInstanceFleetRequest generates a "aws/request.Request" representing the // client's request for the AddInstanceFleet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -102,7 +102,7 @@ const opAddInstanceGroups = "AddInstanceGroups" // AddInstanceGroupsRequest generates a "aws/request.Request" representing the // client's request for the AddInstanceGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -182,7 +182,7 @@ const opAddJobFlowSteps = "AddJobFlowSteps" // AddJobFlowStepsRequest generates a "aws/request.Request" representing the // client's request for the AddJobFlowSteps operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -284,7 +284,7 @@ const opAddTags = "AddTags" // AddTagsRequest generates a "aws/request.Request" representing the // client's request for the AddTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -368,7 +368,7 @@ const opCancelSteps = "CancelSteps" // CancelStepsRequest generates a "aws/request.Request" representing the // client's request for the CancelSteps operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -455,7 +455,7 @@ const opCreateSecurityConfiguration = "CreateSecurityConfiguration" // CreateSecurityConfigurationRequest generates a "aws/request.Request" representing the // client's request for the CreateSecurityConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -538,7 +538,7 @@ const opDeleteSecurityConfiguration = "DeleteSecurityConfiguration" // DeleteSecurityConfigurationRequest generates a "aws/request.Request" representing the // client's request for the DeleteSecurityConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -620,7 +620,7 @@ const opDescribeCluster = "DescribeCluster" // DescribeClusterRequest generates a "aws/request.Request" representing the // client's request for the DescribeCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -703,7 +703,7 @@ const opDescribeJobFlows = "DescribeJobFlows" // DescribeJobFlowsRequest generates a "aws/request.Request" representing the // client's request for the DescribeJobFlows operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -805,7 +805,7 @@ const opDescribeSecurityConfiguration = "DescribeSecurityConfiguration" // DescribeSecurityConfigurationRequest generates a "aws/request.Request" representing the // client's request for the DescribeSecurityConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -888,7 +888,7 @@ const opDescribeStep = "DescribeStep" // DescribeStepRequest generates a "aws/request.Request" representing the // client's request for the DescribeStep operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -970,7 +970,7 @@ const opListBootstrapActions = "ListBootstrapActions" // ListBootstrapActionsRequest generates a "aws/request.Request" representing the // client's request for the ListBootstrapActions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1108,7 +1108,7 @@ const opListClusters = "ListClusters" // ListClustersRequest generates a "aws/request.Request" representing the // client's request for the ListClusters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1250,7 +1250,7 @@ const opListInstanceFleets = "ListInstanceFleets" // ListInstanceFleetsRequest generates a "aws/request.Request" representing the // client's request for the ListInstanceFleets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1391,7 +1391,7 @@ const opListInstanceGroups = "ListInstanceGroups" // ListInstanceGroupsRequest generates a "aws/request.Request" representing the // client's request for the ListInstanceGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1529,7 +1529,7 @@ const opListInstances = "ListInstances" // ListInstancesRequest generates a "aws/request.Request" representing the // client's request for the ListInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1670,7 +1670,7 @@ const opListSecurityConfigurations = "ListSecurityConfigurations" // ListSecurityConfigurationsRequest generates a "aws/request.Request" representing the // client's request for the ListSecurityConfigurations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1755,7 +1755,7 @@ const opListSteps = "ListSteps" // ListStepsRequest generates a "aws/request.Request" representing the // client's request for the ListSteps operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1894,7 +1894,7 @@ const opModifyInstanceFleet = "ModifyInstanceFleet" // ModifyInstanceFleetRequest generates a "aws/request.Request" representing the // client's request for the ModifyInstanceFleet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1983,7 +1983,7 @@ const opModifyInstanceGroups = "ModifyInstanceGroups" // ModifyInstanceGroupsRequest generates a "aws/request.Request" representing the // client's request for the ModifyInstanceGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2068,7 +2068,7 @@ const opPutAutoScalingPolicy = "PutAutoScalingPolicy" // PutAutoScalingPolicyRequest generates a "aws/request.Request" representing the // client's request for the PutAutoScalingPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2145,7 +2145,7 @@ const opRemoveAutoScalingPolicy = "RemoveAutoScalingPolicy" // RemoveAutoScalingPolicyRequest generates a "aws/request.Request" representing the // client's request for the RemoveAutoScalingPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2220,7 +2220,7 @@ const opRemoveTags = "RemoveTags" // RemoveTagsRequest generates a "aws/request.Request" representing the // client's request for the RemoveTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2306,7 +2306,7 @@ const opRunJobFlow = "RunJobFlow" // RunJobFlowRequest generates a "aws/request.Request" representing the // client's request for the RunJobFlow operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2412,7 +2412,7 @@ const opSetTerminationProtection = "SetTerminationProtection" // SetTerminationProtectionRequest generates a "aws/request.Request" representing the // client's request for the SetTerminationProtection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2510,7 +2510,7 @@ const opSetVisibleToAllUsers = "SetVisibleToAllUsers" // SetVisibleToAllUsersRequest generates a "aws/request.Request" representing the // client's request for the SetVisibleToAllUsers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2597,7 +2597,7 @@ const opTerminateJobFlows = "TerminateJobFlows" // TerminateJobFlowsRequest generates a "aws/request.Request" representing the // client's request for the TerminateJobFlows operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/firehose/api.go b/vendor/github.com/aws/aws-sdk-go/service/firehose/api.go index c4f0a8add5fb..a7d3333ffe7d 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/firehose/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/firehose/api.go @@ -15,7 +15,7 @@ const opCreateDeliveryStream = "CreateDeliveryStream" // CreateDeliveryStreamRequest generates a "aws/request.Request" representing the // client's request for the CreateDeliveryStream operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -151,7 +151,7 @@ const opDeleteDeliveryStream = "DeleteDeliveryStream" // DeleteDeliveryStreamRequest generates a "aws/request.Request" representing the // client's request for the DeleteDeliveryStream operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -244,7 +244,7 @@ const opDescribeDeliveryStream = "DescribeDeliveryStream" // DescribeDeliveryStreamRequest generates a "aws/request.Request" representing the // client's request for the DescribeDeliveryStream operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -326,7 +326,7 @@ const opListDeliveryStreams = "ListDeliveryStreams" // ListDeliveryStreamsRequest generates a "aws/request.Request" representing the // client's request for the ListDeliveryStreams operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -408,7 +408,7 @@ const opPutRecord = "PutRecord" // PutRecordRequest generates a "aws/request.Request" representing the // client's request for the PutRecord operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -528,7 +528,7 @@ const opPutRecordBatch = "PutRecordBatch" // PutRecordBatchRequest generates a "aws/request.Request" representing the // client's request for the PutRecordBatch operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -673,7 +673,7 @@ const opUpdateDestination = "UpdateDestination" // UpdateDestinationRequest generates a "aws/request.Request" representing the // client's request for the UpdateDestination operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/gamelift/api.go b/vendor/github.com/aws/aws-sdk-go/service/gamelift/api.go index 0e7ff5fbebc9..7be8756207b5 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/gamelift/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/gamelift/api.go @@ -17,7 +17,7 @@ const opAcceptMatch = "AcceptMatch" // AcceptMatchRequest generates a "aws/request.Request" representing the // client's request for the AcceptMatch operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -90,6 +90,8 @@ func (c *GameLift) AcceptMatchRequest(input *AcceptMatchInput) (req *request.Req // // * AcceptMatch // +// * StartMatchBackfill +// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -140,7 +142,7 @@ const opCreateAlias = "CreateAlias" // CreateAliasRequest generates a "aws/request.Request" representing the // client's request for the CreateAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -269,7 +271,7 @@ const opCreateBuild = "CreateBuild" // CreateBuildRequest generates a "aws/request.Request" representing the // client's request for the CreateBuild operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -410,7 +412,7 @@ const opCreateFleet = "CreateFleet" // CreateFleetRequest generates a "aws/request.Request" representing the // client's request for the CreateFleet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -452,17 +454,15 @@ func (c *GameLift) CreateFleetRequest(input *CreateFleetInput) (req *request.Req // // Creates a new fleet to run your game servers. A fleet is a set of Amazon // Elastic Compute Cloud (Amazon EC2) instances, each of which can run multiple -// server processes to host game sessions. You configure a fleet to create instances +// server processes to host game sessions. You set up a fleet to use instances // with certain hardware specifications (see Amazon EC2 Instance Types (http://aws.amazon.com/ec2/instance-types/) -// for more information), and deploy a specified game build to each instance. -// A newly created fleet passes through several statuses; once it reaches the -// ACTIVE status, it can begin hosting game sessions. +// for more information), and deploy your game build to run on each instance. // -// To create a new fleet, you must specify the following: (1) fleet name, (2) -// build ID of an uploaded game build, (3) an EC2 instance type, and (4) a run-time -// configuration that describes which server processes to run on each instance -// in the fleet. (Although the run-time configuration is not a required parameter, -// the fleet cannot be successfully activated without it.) +// To create a new fleet, you must specify the following: (1) a fleet name, +// (2) the build ID of a successfully uploaded game build, (3) an EC2 instance +// type, and (4) a run-time configuration, which describes the server processes +// to run on each instance in the fleet. If you don't specify a fleet type (on-demand +// or spot), the new fleet uses on-demand instances by default. // // You can also configure the new fleet with the following settings: // @@ -472,34 +472,36 @@ func (c *GameLift) CreateFleetRequest(input *CreateFleetInput) (req *request.Req // // * Fleet-wide game session protection // -// * Resource creation limit +// * Resource usage limits // -// If you use Amazon CloudWatch for metrics, you can add the new fleet to a -// metric group. This allows you to view aggregated metrics for a set of fleets. -// Once you specify a metric group, the new fleet's metrics are included in -// the metric group's data. +// * VPC peering connection (see VPC Peering with Amazon GameLift Fleets +// (http://docs.aws.amazon.com/gamelift/latest/developerguide/vpc-peering.html)) // -// You have the option of creating a VPC peering connection with the new fleet. -// For more information, see VPC Peering with Amazon GameLift Fleets (http://docs.aws.amazon.com/gamelift/latest/developerguide/vpc-peering.html). +// If you use Amazon CloudWatch for metrics, you can add the new fleet to a +// metric group. By adding multiple fleets to a metric group, you can view aggregated +// metrics for all the fleets in the group. // // If the CreateFleet call is successful, Amazon GameLift performs the following -// tasks: +// tasks. You can track the process of a fleet by checking the fleet status +// or by monitoring fleet creation events: // -// * Creates a fleet record and sets the status to NEW (followed by other -// statuses as the fleet is activated). +// * Creates a fleet record. Status: NEW. // -// * Sets the fleet's target capacity to 1 (desired instances), which causes +// * Begins writing events to the fleet event log, which can be accessed +// in the Amazon GameLift console. +// +// Sets the fleet's target capacity to 1 (desired instances), which triggers // Amazon GameLift to start one new EC2 instance. // +// * Downloads the game build to the new instance and installs it. Statuses: +// DOWNLOADING, VALIDATING, BUILDING. +// // * Starts launching server processes on the instance. If the fleet is configured // to run multiple server processes per instance, Amazon GameLift staggers -// each launch by a few seconds. +// each launch by a few seconds. Status: ACTIVATING. // -// * Begins writing events to the fleet event log, which can be accessed -// in the Amazon GameLift console. -// -// * Sets the fleet's status to ACTIVE as soon as one server process in the -// fleet is ready to host a game session. +// * Sets the fleet's status to ACTIVE as soon as one server process is ready +// to host a game session. // // Fleet-related operations include: // @@ -604,7 +606,7 @@ const opCreateGameSession = "CreateGameSession" // CreateGameSessionRequest generates a "aws/request.Request" representing the // client's request for the CreateGameSession operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -776,7 +778,7 @@ const opCreateGameSessionQueue = "CreateGameSessionQueue" // CreateGameSessionQueueRequest generates a "aws/request.Request" representing the // client's request for the CreateGameSessionQueue operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -907,7 +909,7 @@ const opCreateMatchmakingConfiguration = "CreateMatchmakingConfiguration" // CreateMatchmakingConfigurationRequest generates a "aws/request.Request" representing the // client's request for the CreateMatchmakingConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -950,9 +952,9 @@ func (c *GameLift) CreateMatchmakingConfigurationRequest(input *CreateMatchmakin // Defines a new matchmaking configuration for use with FlexMatch. A matchmaking // configuration sets out guidelines for matching players and getting the matches // into games. You can set up multiple matchmaking configurations to handle -// the scenarios needed for your game. Each matchmaking request (StartMatchmaking) -// specifies a configuration for the match and provides player attributes to -// support the configuration being used. +// the scenarios needed for your game. Each matchmaking ticket (StartMatchmaking +// or StartMatchBackfill) specifies a configuration for the match and provides +// player attributes to support the configuration being used. // // To create a matchmaking configuration, at a minimum you must specify the // following: configuration name; a rule set that governs how to evaluate players @@ -1046,7 +1048,7 @@ const opCreateMatchmakingRuleSet = "CreateMatchmakingRuleSet" // CreateMatchmakingRuleSetRequest generates a "aws/request.Request" representing the // client's request for the CreateMatchmakingRuleSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1099,7 +1101,7 @@ func (c *GameLift) CreateMatchmakingRuleSetRequest(input *CreateMatchmakingRuleS // Game (http://docs.aws.amazon.com/gamelift/latest/developerguide/match-intro.html). // // Once created, matchmaking rule sets cannot be changed or deleted, so we recommend -// checking the rule set syntax using ValidateMatchmakingRuleSetbefore creating +// checking the rule set syntax using ValidateMatchmakingRuleSet before creating // the rule set. // // To create a matchmaking rule set, provide the set of rules and a unique name. @@ -1170,7 +1172,7 @@ const opCreatePlayerSession = "CreatePlayerSession" // CreatePlayerSessionRequest generates a "aws/request.Request" representing the // client's request for the CreatePlayerSession operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1303,7 +1305,7 @@ const opCreatePlayerSessions = "CreatePlayerSessions" // CreatePlayerSessionsRequest generates a "aws/request.Request" representing the // client's request for the CreatePlayerSessions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1437,7 +1439,7 @@ const opCreateVpcPeeringAuthorization = "CreateVpcPeeringAuthorization" // CreateVpcPeeringAuthorizationRequest generates a "aws/request.Request" representing the // client's request for the CreateVpcPeeringAuthorization operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1570,7 +1572,7 @@ const opCreateVpcPeeringConnection = "CreateVpcPeeringConnection" // CreateVpcPeeringConnectionRequest generates a "aws/request.Request" representing the // client's request for the CreateVpcPeeringConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1698,7 +1700,7 @@ const opDeleteAlias = "DeleteAlias" // DeleteAliasRequest generates a "aws/request.Request" representing the // client's request for the DeleteAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1808,7 +1810,7 @@ const opDeleteBuild = "DeleteBuild" // DeleteBuildRequest generates a "aws/request.Request" representing the // client's request for the DeleteBuild operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1919,7 +1921,7 @@ const opDeleteFleet = "DeleteFleet" // DeleteFleetRequest generates a "aws/request.Request" representing the // client's request for the DeleteFleet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2066,7 +2068,7 @@ const opDeleteGameSessionQueue = "DeleteGameSessionQueue" // DeleteGameSessionQueueRequest generates a "aws/request.Request" representing the // client's request for the DeleteGameSessionQueue operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2170,7 +2172,7 @@ const opDeleteMatchmakingConfiguration = "DeleteMatchmakingConfiguration" // DeleteMatchmakingConfigurationRequest generates a "aws/request.Request" representing the // client's request for the DeleteMatchmakingConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2280,7 +2282,7 @@ const opDeleteScalingPolicy = "DeleteScalingPolicy" // DeleteScalingPolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteScalingPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2420,7 +2422,7 @@ const opDeleteVpcPeeringAuthorization = "DeleteVpcPeeringAuthorization" // DeleteVpcPeeringAuthorizationRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpcPeeringAuthorization operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2528,7 +2530,7 @@ const opDeleteVpcPeeringConnection = "DeleteVpcPeeringConnection" // DeleteVpcPeeringConnectionRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpcPeeringConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2642,7 +2644,7 @@ const opDescribeAlias = "DescribeAlias" // DescribeAliasRequest generates a "aws/request.Request" representing the // client's request for the DescribeAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2752,7 +2754,7 @@ const opDescribeBuild = "DescribeBuild" // DescribeBuildRequest generates a "aws/request.Request" representing the // client's request for the DescribeBuild operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2857,7 +2859,7 @@ const opDescribeEC2InstanceLimits = "DescribeEC2InstanceLimits" // DescribeEC2InstanceLimitsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEC2InstanceLimits operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2997,7 +2999,7 @@ const opDescribeFleetAttributes = "DescribeFleetAttributes" // DescribeFleetAttributesRequest generates a "aws/request.Request" representing the // client's request for the DescribeFleetAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3143,7 +3145,7 @@ const opDescribeFleetCapacity = "DescribeFleetCapacity" // DescribeFleetCapacityRequest generates a "aws/request.Request" representing the // client's request for the DescribeFleetCapacity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3290,7 +3292,7 @@ const opDescribeFleetEvents = "DescribeFleetEvents" // DescribeFleetEventsRequest generates a "aws/request.Request" representing the // client's request for the DescribeFleetEvents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3429,7 +3431,7 @@ const opDescribeFleetPortSettings = "DescribeFleetPortSettings" // DescribeFleetPortSettingsRequest generates a "aws/request.Request" representing the // client's request for the DescribeFleetPortSettings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3570,7 +3572,7 @@ const opDescribeFleetUtilization = "DescribeFleetUtilization" // DescribeFleetUtilizationRequest generates a "aws/request.Request" representing the // client's request for the DescribeFleetUtilization operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3715,7 +3717,7 @@ const opDescribeGameSessionDetails = "DescribeGameSessionDetails" // DescribeGameSessionDetailsRequest generates a "aws/request.Request" representing the // client's request for the DescribeGameSessionDetails operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3846,7 +3848,7 @@ const opDescribeGameSessionPlacement = "DescribeGameSessionPlacement" // DescribeGameSessionPlacementRequest generates a "aws/request.Request" representing the // client's request for the DescribeGameSessionPlacement operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3962,7 +3964,7 @@ const opDescribeGameSessionQueues = "DescribeGameSessionQueues" // DescribeGameSessionQueuesRequest generates a "aws/request.Request" representing the // client's request for the DescribeGameSessionQueues operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4068,7 +4070,7 @@ const opDescribeGameSessions = "DescribeGameSessions" // DescribeGameSessionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeGameSessions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4200,7 +4202,7 @@ const opDescribeInstances = "DescribeInstances" // DescribeInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4299,7 +4301,7 @@ const opDescribeMatchmaking = "DescribeMatchmaking" // DescribeMatchmakingRequest generates a "aws/request.Request" representing the // client's request for the DescribeMatchmaking operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4362,6 +4364,8 @@ func (c *GameLift) DescribeMatchmakingRequest(input *DescribeMatchmakingInput) ( // // * AcceptMatch // +// * StartMatchBackfill +// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -4408,7 +4412,7 @@ const opDescribeMatchmakingConfigurations = "DescribeMatchmakingConfigurations" // DescribeMatchmakingConfigurationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeMatchmakingConfigurations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4519,7 +4523,7 @@ const opDescribeMatchmakingRuleSets = "DescribeMatchmakingRuleSets" // DescribeMatchmakingRuleSetsRequest generates a "aws/request.Request" representing the // client's request for the DescribeMatchmakingRuleSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4631,7 +4635,7 @@ const opDescribePlayerSessions = "DescribePlayerSessions" // DescribePlayerSessionsRequest generates a "aws/request.Request" representing the // client's request for the DescribePlayerSessions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4751,7 +4755,7 @@ const opDescribeRuntimeConfiguration = "DescribeRuntimeConfiguration" // DescribeRuntimeConfigurationRequest generates a "aws/request.Request" representing the // client's request for the DescribeRuntimeConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4889,7 +4893,7 @@ const opDescribeScalingPolicies = "DescribeScalingPolicies" // DescribeScalingPoliciesRequest generates a "aws/request.Request" representing the // client's request for the DescribeScalingPolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5030,7 +5034,7 @@ const opDescribeVpcPeeringAuthorizations = "DescribeVpcPeeringAuthorizations" // DescribeVpcPeeringAuthorizationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcPeeringAuthorizations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5134,7 +5138,7 @@ const opDescribeVpcPeeringConnections = "DescribeVpcPeeringConnections" // DescribeVpcPeeringConnectionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcPeeringConnections operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5247,7 +5251,7 @@ const opGetGameSessionLogUrl = "GetGameSessionLogUrl" // GetGameSessionLogUrlRequest generates a "aws/request.Request" representing the // client's request for the GetGameSessionLogUrl operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5368,7 +5372,7 @@ const opGetInstanceAccess = "GetInstanceAccess" // GetInstanceAccessRequest generates a "aws/request.Request" representing the // client's request for the GetInstanceAccess operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5475,7 +5479,7 @@ const opListAliases = "ListAliases" // ListAliasesRequest generates a "aws/request.Request" representing the // client's request for the ListAliases operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5581,7 +5585,7 @@ const opListBuilds = "ListBuilds" // ListBuildsRequest generates a "aws/request.Request" representing the // client's request for the ListBuilds operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5686,7 +5690,7 @@ const opListFleets = "ListFleets" // ListFleetsRequest generates a "aws/request.Request" representing the // client's request for the ListFleets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5826,7 +5830,7 @@ const opPutScalingPolicy = "PutScalingPolicy" // PutScalingPolicyRequest generates a "aws/request.Request" representing the // client's request for the PutScalingPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5983,7 +5987,7 @@ const opRequestUploadCredentials = "RequestUploadCredentials" // RequestUploadCredentialsRequest generates a "aws/request.Request" representing the // client's request for the RequestUploadCredentials operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6081,7 +6085,7 @@ const opResolveAlias = "ResolveAlias" // ResolveAliasRequest generates a "aws/request.Request" representing the // client's request for the ResolveAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6194,7 +6198,7 @@ const opSearchGameSessions = "SearchGameSessions" // SearchGameSessionsRequest generates a "aws/request.Request" representing the // client's request for the SearchGameSessions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6363,7 +6367,7 @@ const opStartGameSessionPlacement = "StartGameSessionPlacement" // StartGameSessionPlacementRequest generates a "aws/request.Request" representing the // client's request for the StartGameSessionPlacement operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6517,7 +6521,7 @@ const opStartMatchBackfill = "StartMatchBackfill" // StartMatchBackfillRequest generates a "aws/request.Request" representing the // client's request for the StartMatchBackfill operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6570,8 +6574,8 @@ func (c *GameLift) StartMatchBackfillRequest(input *StartMatchBackfillInput) (re // all current players in the game session. If successful, a match backfill // ticket is created and returned with status set to QUEUED. The ticket is placed // in the matchmaker's ticket pool and processed. Track the status of the ticket -// to respond as needed. For more detail how to set up backfilling, see Set -// up Match Backfilling (http://docs.aws.amazon.com/gamelift/latest/developerguide/match-backfill.html). +// to respond as needed. For more detail how to set up backfilling, see Backfill +// Existing Games with FlexMatch (http://docs.aws.amazon.com/gamelift/latest/developerguide/match-backfill.html). // // The process of finding backfill matches is essentially identical to the initial // matchmaking process. The matchmaker searches the pool and groups tickets @@ -6593,6 +6597,8 @@ func (c *GameLift) StartMatchBackfillRequest(input *StartMatchBackfillInput) (re // // * AcceptMatch // +// * StartMatchBackfill +// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -6643,7 +6649,7 @@ const opStartMatchmaking = "StartMatchmaking" // StartMatchmakingRequest generates a "aws/request.Request" representing the // client's request for the StartMatchmaking operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6755,6 +6761,8 @@ func (c *GameLift) StartMatchmakingRequest(input *StartMatchmakingInput) (req *r // // * AcceptMatch // +// * StartMatchBackfill +// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -6805,7 +6813,7 @@ const opStopGameSessionPlacement = "StopGameSessionPlacement" // StopGameSessionPlacementRequest generates a "aws/request.Request" representing the // client's request for the StopGameSessionPlacement operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6921,7 +6929,7 @@ const opStopMatchmaking = "StopMatchmaking" // StopMatchmakingRequest generates a "aws/request.Request" representing the // client's request for the StopMatchmaking operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6975,6 +6983,8 @@ func (c *GameLift) StopMatchmakingRequest(input *StopMatchmakingInput) (req *req // // * AcceptMatch // +// * StartMatchBackfill +// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -7025,7 +7035,7 @@ const opUpdateAlias = "UpdateAlias" // UpdateAliasRequest generates a "aws/request.Request" representing the // client's request for the UpdateAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7134,7 +7144,7 @@ const opUpdateBuild = "UpdateBuild" // UpdateBuildRequest generates a "aws/request.Request" representing the // client's request for the UpdateBuild operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7241,7 +7251,7 @@ const opUpdateFleetAttributes = "UpdateFleetAttributes" // UpdateFleetAttributesRequest generates a "aws/request.Request" representing the // client's request for the UpdateFleetAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7393,7 +7403,7 @@ const opUpdateFleetCapacity = "UpdateFleetCapacity" // UpdateFleetCapacityRequest generates a "aws/request.Request" representing the // client's request for the UpdateFleetCapacity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7557,7 +7567,7 @@ const opUpdateFleetPortSettings = "UpdateFleetPortSettings" // UpdateFleetPortSettingsRequest generates a "aws/request.Request" representing the // client's request for the UpdateFleetPortSettings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7712,7 +7722,7 @@ const opUpdateGameSession = "UpdateGameSession" // UpdateGameSessionRequest generates a "aws/request.Request" representing the // client's request for the UpdateGameSession operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7842,7 +7852,7 @@ const opUpdateGameSessionQueue = "UpdateGameSessionQueue" // UpdateGameSessionQueueRequest generates a "aws/request.Request" representing the // client's request for the UpdateGameSessionQueue operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7947,7 +7957,7 @@ const opUpdateMatchmakingConfiguration = "UpdateMatchmakingConfiguration" // UpdateMatchmakingConfigurationRequest generates a "aws/request.Request" representing the // client's request for the UpdateMatchmakingConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8056,7 +8066,7 @@ const opUpdateRuntimeConfiguration = "UpdateRuntimeConfiguration" // UpdateRuntimeConfigurationRequest generates a "aws/request.Request" representing the // client's request for the UpdateRuntimeConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8212,7 +8222,7 @@ const opValidateMatchmakingRuleSet = "ValidateMatchmakingRuleSet" // ValidateMatchmakingRuleSetRequest generates a "aws/request.Request" representing the // client's request for the ValidateMatchmakingRuleSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8970,6 +8980,16 @@ type CreateFleetInput struct { // EC2InstanceType is a required field EC2InstanceType *string `type:"string" required:"true" enum:"EC2InstanceType"` + // Indicates whether to use on-demand instances or spot instances for this fleet. + // If empty, the default is ON_DEMAND. Both categories of instances use identical + // hardware and configurations, based on the instance type selected for this + // fleet. You can acquire on-demand instances at any time for a fixed price + // and keep them as long as you need them. Spot instances have lower prices, + // but spot pricing is variable, and while in use they can be interrupted (with + // a two-minute notification). Learn more about Amazon GameLift spot instances + // with at Choose Computing Resources (http://docs.aws.amazon.com/gamelift/latest/developerguide/gamelift-ec2-instances.html). + FleetType *string `type:"string" enum:"FleetType"` + // This parameter is no longer used. Instead, to specify where Amazon GameLift // should store log files once a server process shuts down, use the Amazon GameLift // server API ProcessReady() and specify one or more directory paths in logParameters. @@ -9128,6 +9148,12 @@ func (s *CreateFleetInput) SetEC2InstanceType(v string) *CreateFleetInput { return s } +// SetFleetType sets the FleetType field's value. +func (s *CreateFleetInput) SetFleetType(v string) *CreateFleetInput { + s.FleetType = &v + return s +} + // SetLogPaths sets the LogPaths field's value. func (s *CreateFleetInput) SetLogPaths(v []*string) *CreateFleetInput { s.LogPaths = v @@ -12848,10 +12874,6 @@ type Event struct { // Type of event being logged. The following events are currently in use: // - // General events: - // - // * GENERIC_EVENT -- An unspecified event has occurred. - // // Fleet creation events: // // * FLEET_CREATED -- A fleet record was successfully created with a status @@ -12927,6 +12949,11 @@ type Event struct { // * FLEET_VPC_PEERING_DELETED -- A VPC peering connection has been successfully // deleted. // + // Spot instance events: + // + // * INSTANCE_INTERRUPTED -- A spot instance was interrupted by EC2 with + // a two-minute notification. + // // Other fleet events: // // * FLEET_SCALING_EVENT -- A change was made to the fleet's capacity settings @@ -12938,6 +12965,8 @@ type Event struct { // includes both the old and new policy setting. // // * FLEET_DELETED -- A request to delete a fleet was initiated. + // + // * GENERIC_EVENT -- An unspecified event has occurred. EventCode *string `type:"string" enum:"EventCode"` // Unique identifier for a fleet event. @@ -13069,6 +13098,16 @@ type FleetAttributes struct { // Unique identifier for a fleet. FleetId *string `type:"string"` + // Indicates whether the fleet uses on-demand or spot instances. A spot instance + // in use may be interrupted with a two-minute notification. + FleetType *string `type:"string" enum:"FleetType"` + + // EC2 instance type indicating the computing resources of each instance in + // the fleet, including CPU, memory, storage, and networking capacity. See Amazon + // EC2 Instance Types (http://aws.amazon.com/ec2/instance-types/) for detailed + // descriptions. + InstanceType *string `type:"string" enum:"EC2InstanceType"` + // Location of default log files. When a server process is shut down, Amazon // GameLift captures and stores any log files in this location. These logs are // in addition to game session logs; see more on game session logs in the Amazon @@ -13184,6 +13223,18 @@ func (s *FleetAttributes) SetFleetId(v string) *FleetAttributes { return s } +// SetFleetType sets the FleetType field's value. +func (s *FleetAttributes) SetFleetType(v string) *FleetAttributes { + s.FleetType = &v + return s +} + +// SetInstanceType sets the InstanceType field's value. +func (s *FleetAttributes) SetInstanceType(v string) *FleetAttributes { + s.InstanceType = &v + return s +} + // SetLogPaths sets the LogPaths field's value. func (s *FleetAttributes) SetLogPaths(v []*string) *FleetAttributes { s.LogPaths = v @@ -13601,6 +13652,11 @@ type GameSession struct { // to have player sessions. Status *string `type:"string" enum:"GameSessionStatus"` + // Provides additional information about game session status. INTERRUPTED indicates + // that the game session was hosted on a spot instance that was reclaimed, causing + // the active game session to be terminated. + StatusReason *string `type:"string" enum:"GameSessionStatusReason"` + // Time stamp indicating when this data object was terminated. Format is a number // expressed in Unix time as milliseconds (for example "1469498468.057"). TerminationTime *time.Time `type:"timestamp" timestampFormat:"unix"` @@ -13700,6 +13756,12 @@ func (s *GameSession) SetStatus(v string) *GameSession { return s } +// SetStatusReason sets the StatusReason field's value. +func (s *GameSession) SetStatusReason(v string) *GameSession { + s.StatusReason = &v + return s +} + // SetTerminationTime sets the TerminationTime field's value. func (s *GameSession) SetTerminationTime(v time.Time) *GameSession { s.TerminationTime = &v @@ -13865,8 +13927,7 @@ type GameSessionPlacement struct { // formated as a string. It identifies the matchmaking configuration used to // create the match, and contains data on all players assigned to the match, // including player attributes and team assignments. For more details on matchmaker - // data, see http://docs.aws.amazon.com/gamelift/latest/developerguide/match-server.html#match-server-data - // (http://docs.aws.amazon.com/gamelift/latest/developerguide/match-server.html#match-server-data). + // data, see Match Data (http://docs.aws.amazon.com/gamelift/latest/developerguide/match-server.html#match-server-data). MatchmakerData *string `min:"1" type:"string"` // Maximum number of players that can be connected simultaneously to the game @@ -15223,9 +15284,9 @@ type MatchmakingTicket struct { // game session is created for the match. ConfigurationName *string `min:"1" type:"string"` - // Time stamp indicating when the matchmaking request stopped being processed - // due to successful completion, timeout, or cancellation. Format is a number - // expressed in Unix time as milliseconds (for example "1469498468.057"). + // Time stamp indicating when this matchmaking request stopped being processed + // due to success, failure, or cancellation. Format is a number expressed in + // Unix time as milliseconds (for example "1469498468.057"). EndTime *time.Time `type:"timestamp" timestampFormat:"unix"` // Average amount of time (in seconds) that players are currently waiting for @@ -17121,13 +17182,14 @@ type StartMatchBackfillInput struct { // session. This information is used by the matchmaker to find new players and // add them to the existing game. // - // * PlayerID, PlayerAttributes, Team -- This information is maintained in - // the GameSession object, MatchmakerData property, for all players who are - // currently assigned to the game session. The matchmaker data is in JSON - // syntax, formatted as a string. For more details, see Match Data (http://docs.aws.amazon.com/gamelift/latest/developerguide/match-server.html#match-server-data). + // * PlayerID, PlayerAttributes, Team -\\- This information is maintained + // in the GameSession object, MatchmakerData property, for all players who + // are currently assigned to the game session. The matchmaker data is in + // JSON syntax, formatted as a string. For more details, see Match Data + // (http://docs.aws.amazon.com/gamelift/latest/developerguide/match-server.html#match-server-data). // // - // * LatencyInMs -- If the matchmaker uses player latency, include a latency + // * LatencyInMs -\\- If the matchmaker uses player latency, include a latency // value, in milliseconds, for the region that the game session is currently // in. Do not include latency values for any other region. // @@ -19023,6 +19085,9 @@ const ( // EventCodeFleetVpcPeeringDeleted is a EventCode enum value EventCodeFleetVpcPeeringDeleted = "FLEET_VPC_PEERING_DELETED" + + // EventCodeInstanceInterrupted is a EventCode enum value + EventCodeInstanceInterrupted = "INSTANCE_INTERRUPTED" ) const ( @@ -19054,6 +19119,14 @@ const ( FleetStatusTerminated = "TERMINATED" ) +const ( + // FleetTypeOnDemand is a FleetType enum value + FleetTypeOnDemand = "ON_DEMAND" + + // FleetTypeSpot is a FleetType enum value + FleetTypeSpot = "SPOT" +) + const ( // GameSessionPlacementStatePending is a GameSessionPlacementState enum value GameSessionPlacementStatePending = "PENDING" @@ -19085,6 +19158,11 @@ const ( GameSessionStatusError = "ERROR" ) +const ( + // GameSessionStatusReasonInterrupted is a GameSessionStatusReason enum value + GameSessionStatusReasonInterrupted = "INTERRUPTED" +) + const ( // InstanceStatusPending is a InstanceStatus enum value InstanceStatusPending = "PENDING" diff --git a/vendor/github.com/aws/aws-sdk-go/service/gamelift/doc.go b/vendor/github.com/aws/aws-sdk-go/service/gamelift/doc.go index 2f8437e32ca8..0e2d3bdaafdf 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/gamelift/doc.go +++ b/vendor/github.com/aws/aws-sdk-go/service/gamelift/doc.go @@ -94,19 +94,19 @@ // CreateGameSession -- Start a new game session on a specific fleet. Available // in Amazon GameLift Local. // -// * Start new game sessions with FlexMatch matchmaking +// * Match players to game sessions with FlexMatch matchmaking // // StartMatchmaking -- Request matchmaking for one players or a group who want // to play together. // +// StartMatchBackfill - Request additional player matches to fill empty slots +// in an existing game session. +// // DescribeMatchmaking -- Get details on a matchmaking request, including status. // // AcceptMatch -- Register that a player accepts a proposed match, for matches // that require player acceptance. // -// StartMatchBackfill - Request additional player matches to fill empty slots -// in an existing game session. -// // StopMatchmaking -- Cancel a matchmaking request. // // * Manage game session data diff --git a/vendor/github.com/aws/aws-sdk-go/service/glacier/api.go b/vendor/github.com/aws/aws-sdk-go/service/glacier/api.go index 1d9f40dd7000..177764b646de 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/glacier/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/glacier/api.go @@ -17,7 +17,7 @@ const opAbortMultipartUpload = "AbortMultipartUpload" // AbortMultipartUploadRequest generates a "aws/request.Request" representing the // client's request for the AbortMultipartUpload operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -124,7 +124,7 @@ const opAbortVaultLock = "AbortVaultLock" // AbortVaultLockRequest generates a "aws/request.Request" representing the // client's request for the AbortVaultLock operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -227,7 +227,7 @@ const opAddTagsToVault = "AddTagsToVault" // AddTagsToVaultRequest generates a "aws/request.Request" representing the // client's request for the AddTagsToVault operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -323,7 +323,7 @@ const opCompleteMultipartUpload = "CompleteMultipartUpload" // CompleteMultipartUploadRequest generates a "aws/request.Request" representing the // client's request for the CompleteMultipartUpload operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -452,7 +452,7 @@ const opCompleteVaultLock = "CompleteVaultLock" // CompleteVaultLockRequest generates a "aws/request.Request" representing the // client's request for the CompleteVaultLock operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -554,7 +554,7 @@ const opCreateVault = "CreateVault" // CreateVaultRequest generates a "aws/request.Request" representing the // client's request for the CreateVault operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -662,7 +662,7 @@ const opDeleteArchive = "DeleteArchive" // DeleteArchiveRequest generates a "aws/request.Request" representing the // client's request for the DeleteArchive operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -774,7 +774,7 @@ const opDeleteVault = "DeleteVault" // DeleteVaultRequest generates a "aws/request.Request" representing the // client's request for the DeleteVault operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -884,7 +884,7 @@ const opDeleteVaultAccessPolicy = "DeleteVaultAccessPolicy" // DeleteVaultAccessPolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteVaultAccessPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -981,7 +981,7 @@ const opDeleteVaultNotifications = "DeleteVaultNotifications" // DeleteVaultNotificationsRequest generates a "aws/request.Request" representing the // client's request for the DeleteVaultNotifications operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1083,7 +1083,7 @@ const opDescribeJob = "DescribeJob" // DescribeJobRequest generates a "aws/request.Request" representing the // client's request for the DescribeJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1190,7 +1190,7 @@ const opDescribeVault = "DescribeVault" // DescribeVaultRequest generates a "aws/request.Request" representing the // client's request for the DescribeVault operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1295,7 +1295,7 @@ const opGetDataRetrievalPolicy = "GetDataRetrievalPolicy" // GetDataRetrievalPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetDataRetrievalPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1379,7 +1379,7 @@ const opGetJobOutput = "GetJobOutput" // GetJobOutputRequest generates a "aws/request.Request" representing the // client's request for the GetJobOutput operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1508,7 +1508,7 @@ const opGetVaultAccessPolicy = "GetVaultAccessPolicy" // GetVaultAccessPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetVaultAccessPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1599,7 +1599,7 @@ const opGetVaultLock = "GetVaultLock" // GetVaultLockRequest generates a "aws/request.Request" representing the // client's request for the GetVaultLock operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1704,7 +1704,7 @@ const opGetVaultNotifications = "GetVaultNotifications" // GetVaultNotificationsRequest generates a "aws/request.Request" representing the // client's request for the GetVaultNotifications operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1808,7 +1808,7 @@ const opInitiateJob = "InitiateJob" // InitiateJobRequest generates a "aws/request.Request" representing the // client's request for the InitiateJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1906,7 +1906,7 @@ const opInitiateMultipartUpload = "InitiateMultipartUpload" // InitiateMultipartUploadRequest generates a "aws/request.Request" representing the // client's request for the InitiateMultipartUpload operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2026,7 +2026,7 @@ const opInitiateVaultLock = "InitiateVaultLock" // InitiateVaultLockRequest generates a "aws/request.Request" representing the // client's request for the InitiateVaultLock operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2140,7 +2140,7 @@ const opListJobs = "ListJobs" // ListJobsRequest generates a "aws/request.Request" representing the // client's request for the ListJobs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2317,7 +2317,7 @@ const opListMultipartUploads = "ListMultipartUploads" // ListMultipartUploadsRequest generates a "aws/request.Request" representing the // client's request for the ListMultipartUploads operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2488,7 +2488,7 @@ const opListParts = "ListParts" // ListPartsRequest generates a "aws/request.Request" representing the // client's request for the ListParts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2653,7 +2653,7 @@ const opListProvisionedCapacity = "ListProvisionedCapacity" // ListProvisionedCapacityRequest generates a "aws/request.Request" representing the // client's request for the ListProvisionedCapacity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2736,7 +2736,7 @@ const opListTagsForVault = "ListTagsForVault" // ListTagsForVaultRequest generates a "aws/request.Request" representing the // client's request for the ListTagsForVault operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2824,7 +2824,7 @@ const opListVaults = "ListVaults" // ListVaultsRequest generates a "aws/request.Request" representing the // client's request for the ListVaults operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2986,7 +2986,7 @@ const opPurchaseProvisionedCapacity = "PurchaseProvisionedCapacity" // PurchaseProvisionedCapacityRequest generates a "aws/request.Request" representing the // client's request for the PurchaseProvisionedCapacity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3071,7 +3071,7 @@ const opRemoveTagsFromVault = "RemoveTagsFromVault" // RemoveTagsFromVaultRequest generates a "aws/request.Request" representing the // client's request for the RemoveTagsFromVault operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3163,7 +3163,7 @@ const opSetDataRetrievalPolicy = "SetDataRetrievalPolicy" // SetDataRetrievalPolicyRequest generates a "aws/request.Request" representing the // client's request for the SetDataRetrievalPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3253,7 +3253,7 @@ const opSetVaultAccessPolicy = "SetVaultAccessPolicy" // SetVaultAccessPolicyRequest generates a "aws/request.Request" representing the // client's request for the SetVaultAccessPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3347,7 +3347,7 @@ const opSetVaultNotifications = "SetVaultNotifications" // SetVaultNotificationsRequest generates a "aws/request.Request" representing the // client's request for the SetVaultNotifications operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3466,7 +3466,7 @@ const opUploadArchive = "UploadArchive" // UploadArchiveRequest generates a "aws/request.Request" representing the // client's request for the UploadArchive operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3591,7 +3591,7 @@ const opUploadMultipartPart = "UploadMultipartPart" // UploadMultipartPartRequest generates a "aws/request.Request" representing the // client's request for the UploadMultipartPart operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4988,7 +4988,7 @@ type Encryption struct { EncryptionType *string `type:"string" enum:"EncryptionType"` // Optional. If the encryption type is aws:kms, you can use this value to specify - // the encryption context for the restore results. + // the encryption context for the job results. KMSContext *string `type:"string"` // The AWS KMS key ID to use for object encryption. All GET and PUT requests @@ -6256,7 +6256,7 @@ type JobDescription struct { // An Amazon SNS topic that receives notification. SNSTopic *string `type:"string"` - // Contains the parameters that define a select job. + // Contains the parameters used for a select. SelectParameters *SelectParameters `type:"structure"` // The status code can be InProgress, Succeeded, or Failed, and indicates the @@ -6266,7 +6266,7 @@ type JobDescription struct { // A friendly message that describes the job status. StatusMessage *string `type:"string"` - // The retrieval option to use for the archive retrieval. Valid values are Expedited, + // The tier to use for a select or an archive retrieval. Valid values are Expedited, // Standard, or Bulk. Standard is the default. Tier *string `type:"string"` @@ -6458,8 +6458,8 @@ type JobParameters struct { // Contains the parameters that define a job. SelectParameters *SelectParameters `type:"structure"` - // The retrieval option to use for a select or archive retrieval job. Valid - // values are Expedited, Standard, or Bulk. Standard is the default. + // The tier to use for a select or an archive retrieval job. Valid values are + // Expedited, Standard, or Bulk. Standard is the default. Tier *string `type:"string"` // The job type. You can initiate a job to perform a select query on an archive, @@ -7235,7 +7235,7 @@ func (s *ListVaultsOutput) SetVaultList(v []*DescribeVaultOutput) *ListVaultsOut type OutputLocation struct { _ struct{} `type:"structure"` - // Describes an S3 location that will receive the results of the restore request. + // Describes an S3 location that will receive the results of the job request. S3 *S3Location `type:"structure"` } @@ -7525,26 +7525,26 @@ type S3Location struct { // A list of grants that control access to the staged results. AccessControlList []*Grant `type:"list"` - // The name of the bucket where the restore results are stored. + // The name of the Amazon S3 bucket where the job results are stored. BucketName *string `type:"string"` - // The canned ACL to apply to the restore results. + // The canned access control list (ACL) to apply to the job results. CannedACL *string `type:"string" enum:"CannedACL"` // Contains information about the encryption used to store the job results in // Amazon S3. Encryption *Encryption `type:"structure"` - // The prefix that is prepended to the restore results for this request. + // The prefix that is prepended to the results for this request. Prefix *string `type:"string"` - // The storage class used to store the restore results. + // The storage class used to store the job results. StorageClass *string `type:"string" enum:"StorageClass"` - // The tag-set that is applied to the restore results. + // The tag-set that is applied to the job results. Tagging map[string]*string `type:"map"` - // A map of metadata to store with the restore results in Amazon S3. + // A map of metadata to store with the job results in Amazon S3. UserMetadata map[string]*string `type:"map"` } diff --git a/vendor/github.com/aws/aws-sdk-go/service/glacier/treehash.go b/vendor/github.com/aws/aws-sdk-go/service/glacier/treehash.go index e1ee0aa5b7b0..1d7534fbde88 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/glacier/treehash.go +++ b/vendor/github.com/aws/aws-sdk-go/service/glacier/treehash.go @@ -3,6 +3,8 @@ package glacier import ( "crypto/sha256" "io" + + "github.com/aws/aws-sdk-go/internal/sdkio" ) const bufsize = 1024 * 1024 @@ -18,8 +20,8 @@ type Hash struct { // // See http://docs.aws.amazon.com/amazonglacier/latest/dev/checksum-calculations.html for more information. func ComputeHashes(r io.ReadSeeker) Hash { - r.Seek(0, 0) // Read the whole stream - defer r.Seek(0, 0) // Rewind stream at end + start, _ := r.Seek(0, sdkio.SeekCurrent) // Read the whole stream + defer r.Seek(start, sdkio.SeekStart) // Rewind stream at end buf := make([]byte, bufsize) hashes := [][]byte{} diff --git a/vendor/github.com/aws/aws-sdk-go/service/glue/api.go b/vendor/github.com/aws/aws-sdk-go/service/glue/api.go index 3e172586c27f..ba489115a4b2 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/glue/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/glue/api.go @@ -15,7 +15,7 @@ const opBatchCreatePartition = "BatchCreatePartition" // BatchCreatePartitionRequest generates a "aws/request.Request" representing the // client's request for the BatchCreatePartition operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -109,7 +109,7 @@ const opBatchDeleteConnection = "BatchDeleteConnection" // BatchDeleteConnectionRequest generates a "aws/request.Request" representing the // client's request for the BatchDeleteConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -191,7 +191,7 @@ const opBatchDeletePartition = "BatchDeletePartition" // BatchDeletePartitionRequest generates a "aws/request.Request" representing the // client's request for the BatchDeletePartition operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -279,7 +279,7 @@ const opBatchDeleteTable = "BatchDeleteTable" // BatchDeleteTableRequest generates a "aws/request.Request" representing the // client's request for the BatchDeleteTable operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -367,7 +367,7 @@ const opBatchDeleteTableVersion = "BatchDeleteTableVersion" // BatchDeleteTableVersionRequest generates a "aws/request.Request" representing the // client's request for the BatchDeleteTableVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -455,7 +455,7 @@ const opBatchGetPartition = "BatchGetPartition" // BatchGetPartitionRequest generates a "aws/request.Request" representing the // client's request for the BatchGetPartition operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -543,7 +543,7 @@ const opBatchStopJobRun = "BatchStopJobRun" // BatchStopJobRunRequest generates a "aws/request.Request" representing the // client's request for the BatchStopJobRun operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -628,7 +628,7 @@ const opCreateClassifier = "CreateClassifier" // CreateClassifierRequest generates a "aws/request.Request" representing the // client's request for the CreateClassifier operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -715,7 +715,7 @@ const opCreateConnection = "CreateConnection" // CreateConnectionRequest generates a "aws/request.Request" representing the // client's request for the CreateConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -803,7 +803,7 @@ const opCreateCrawler = "CreateCrawler" // CreateCrawlerRequest generates a "aws/request.Request" representing the // client's request for the CreateCrawler operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -893,7 +893,7 @@ const opCreateDatabase = "CreateDatabase" // CreateDatabaseRequest generates a "aws/request.Request" representing the // client's request for the CreateDatabase operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -984,7 +984,7 @@ const opCreateDevEndpoint = "CreateDevEndpoint" // CreateDevEndpointRequest generates a "aws/request.Request" representing the // client's request for the CreateDevEndpoint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1084,7 +1084,7 @@ const opCreateJob = "CreateJob" // CreateJobRequest generates a "aws/request.Request" representing the // client's request for the CreateJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1181,7 +1181,7 @@ const opCreatePartition = "CreatePartition" // CreatePartitionRequest generates a "aws/request.Request" representing the // client's request for the CreatePartition operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1275,7 +1275,7 @@ const opCreateScript = "CreateScript" // CreateScriptRequest generates a "aws/request.Request" representing the // client's request for the CreateScript operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1360,7 +1360,7 @@ const opCreateTable = "CreateTable" // CreateTableRequest generates a "aws/request.Request" representing the // client's request for the CreateTable operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1454,7 +1454,7 @@ const opCreateTrigger = "CreateTrigger" // CreateTriggerRequest generates a "aws/request.Request" representing the // client's request for the CreateTrigger operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1551,7 +1551,7 @@ const opCreateUserDefinedFunction = "CreateUserDefinedFunction" // CreateUserDefinedFunctionRequest generates a "aws/request.Request" representing the // client's request for the CreateUserDefinedFunction operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1645,7 +1645,7 @@ const opDeleteClassifier = "DeleteClassifier" // DeleteClassifierRequest generates a "aws/request.Request" representing the // client's request for the DeleteClassifier operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1727,7 +1727,7 @@ const opDeleteConnection = "DeleteConnection" // DeleteConnectionRequest generates a "aws/request.Request" representing the // client's request for the DeleteConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1809,7 +1809,7 @@ const opDeleteCrawler = "DeleteCrawler" // DeleteCrawlerRequest generates a "aws/request.Request" representing the // client's request for the DeleteCrawler operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1898,7 +1898,7 @@ const opDeleteDatabase = "DeleteDatabase" // DeleteDatabaseRequest generates a "aws/request.Request" representing the // client's request for the DeleteDatabase operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1986,7 +1986,7 @@ const opDeleteDevEndpoint = "DeleteDevEndpoint" // DeleteDevEndpointRequest generates a "aws/request.Request" representing the // client's request for the DeleteDevEndpoint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2074,7 +2074,7 @@ const opDeleteJob = "DeleteJob" // DeleteJobRequest generates a "aws/request.Request" representing the // client's request for the DeleteJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2159,7 +2159,7 @@ const opDeletePartition = "DeletePartition" // DeletePartitionRequest generates a "aws/request.Request" representing the // client's request for the DeletePartition operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2247,7 +2247,7 @@ const opDeleteTable = "DeleteTable" // DeleteTableRequest generates a "aws/request.Request" representing the // client's request for the DeleteTable operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2335,7 +2335,7 @@ const opDeleteTableVersion = "DeleteTableVersion" // DeleteTableVersionRequest generates a "aws/request.Request" representing the // client's request for the DeleteTableVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2423,7 +2423,7 @@ const opDeleteTrigger = "DeleteTrigger" // DeleteTriggerRequest generates a "aws/request.Request" representing the // client's request for the DeleteTrigger operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2512,7 +2512,7 @@ const opDeleteUserDefinedFunction = "DeleteUserDefinedFunction" // DeleteUserDefinedFunctionRequest generates a "aws/request.Request" representing the // client's request for the DeleteUserDefinedFunction operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2600,7 +2600,7 @@ const opGetCatalogImportStatus = "GetCatalogImportStatus" // GetCatalogImportStatusRequest generates a "aws/request.Request" representing the // client's request for the GetCatalogImportStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2682,7 +2682,7 @@ const opGetClassifier = "GetClassifier" // GetClassifierRequest generates a "aws/request.Request" representing the // client's request for the GetClassifier operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2764,7 +2764,7 @@ const opGetClassifiers = "GetClassifiers" // GetClassifiersRequest generates a "aws/request.Request" representing the // client's request for the GetClassifiers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2899,7 +2899,7 @@ const opGetConnection = "GetConnection" // GetConnectionRequest generates a "aws/request.Request" representing the // client's request for the GetConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2981,7 +2981,7 @@ const opGetConnections = "GetConnections" // GetConnectionsRequest generates a "aws/request.Request" representing the // client's request for the GetConnections operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3119,7 +3119,7 @@ const opGetCrawler = "GetCrawler" // GetCrawlerRequest generates a "aws/request.Request" representing the // client's request for the GetCrawler operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3201,7 +3201,7 @@ const opGetCrawlerMetrics = "GetCrawlerMetrics" // GetCrawlerMetricsRequest generates a "aws/request.Request" representing the // client's request for the GetCrawlerMetrics operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3336,7 +3336,7 @@ const opGetCrawlers = "GetCrawlers" // GetCrawlersRequest generates a "aws/request.Request" representing the // client's request for the GetCrawlers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3471,7 +3471,7 @@ const opGetDatabase = "GetDatabase" // GetDatabaseRequest generates a "aws/request.Request" representing the // client's request for the GetDatabase operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3559,7 +3559,7 @@ const opGetDatabases = "GetDatabases" // GetDatabasesRequest generates a "aws/request.Request" representing the // client's request for the GetDatabases operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3700,7 +3700,7 @@ const opGetDataflowGraph = "GetDataflowGraph" // GetDataflowGraphRequest generates a "aws/request.Request" representing the // client's request for the GetDataflowGraph operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3785,7 +3785,7 @@ const opGetDevEndpoint = "GetDevEndpoint" // GetDevEndpointRequest generates a "aws/request.Request" representing the // client's request for the GetDevEndpoint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3873,7 +3873,7 @@ const opGetDevEndpoints = "GetDevEndpoints" // GetDevEndpointsRequest generates a "aws/request.Request" representing the // client's request for the GetDevEndpoints operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4017,7 +4017,7 @@ const opGetJob = "GetJob" // GetJobRequest generates a "aws/request.Request" representing the // client's request for the GetJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4105,7 +4105,7 @@ const opGetJobRun = "GetJobRun" // GetJobRunRequest generates a "aws/request.Request" representing the // client's request for the GetJobRun operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4193,7 +4193,7 @@ const opGetJobRuns = "GetJobRuns" // GetJobRunsRequest generates a "aws/request.Request" representing the // client's request for the GetJobRuns operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4337,7 +4337,7 @@ const opGetJobs = "GetJobs" // GetJobsRequest generates a "aws/request.Request" representing the // client's request for the GetJobs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4481,7 +4481,7 @@ const opGetMapping = "GetMapping" // GetMappingRequest generates a "aws/request.Request" representing the // client's request for the GetMapping operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4569,7 +4569,7 @@ const opGetPartition = "GetPartition" // GetPartitionRequest generates a "aws/request.Request" representing the // client's request for the GetPartition operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4657,7 +4657,7 @@ const opGetPartitions = "GetPartitions" // GetPartitionsRequest generates a "aws/request.Request" representing the // client's request for the GetPartitions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4801,7 +4801,7 @@ const opGetPlan = "GetPlan" // GetPlanRequest generates a "aws/request.Request" representing the // client's request for the GetPlan operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4886,7 +4886,7 @@ const opGetTable = "GetTable" // GetTableRequest generates a "aws/request.Request" representing the // client's request for the GetTable operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4974,7 +4974,7 @@ const opGetTableVersion = "GetTableVersion" // GetTableVersionRequest generates a "aws/request.Request" representing the // client's request for the GetTableVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5062,7 +5062,7 @@ const opGetTableVersions = "GetTableVersions" // GetTableVersionsRequest generates a "aws/request.Request" representing the // client's request for the GetTableVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5207,7 +5207,7 @@ const opGetTables = "GetTables" // GetTablesRequest generates a "aws/request.Request" representing the // client's request for the GetTables operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5351,7 +5351,7 @@ const opGetTrigger = "GetTrigger" // GetTriggerRequest generates a "aws/request.Request" representing the // client's request for the GetTrigger operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5439,7 +5439,7 @@ const opGetTriggers = "GetTriggers" // GetTriggersRequest generates a "aws/request.Request" representing the // client's request for the GetTriggers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5583,7 +5583,7 @@ const opGetUserDefinedFunction = "GetUserDefinedFunction" // GetUserDefinedFunctionRequest generates a "aws/request.Request" representing the // client's request for the GetUserDefinedFunction operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5671,7 +5671,7 @@ const opGetUserDefinedFunctions = "GetUserDefinedFunctions" // GetUserDefinedFunctionsRequest generates a "aws/request.Request" representing the // client's request for the GetUserDefinedFunctions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5815,7 +5815,7 @@ const opImportCatalogToGlue = "ImportCatalogToGlue" // ImportCatalogToGlueRequest generates a "aws/request.Request" representing the // client's request for the ImportCatalogToGlue operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5897,7 +5897,7 @@ const opResetJobBookmark = "ResetJobBookmark" // ResetJobBookmarkRequest generates a "aws/request.Request" representing the // client's request for the ResetJobBookmark operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5985,7 +5985,7 @@ const opStartCrawler = "StartCrawler" // StartCrawlerRequest generates a "aws/request.Request" representing the // client's request for the StartCrawler operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6071,7 +6071,7 @@ const opStartCrawlerSchedule = "StartCrawlerSchedule" // StartCrawlerScheduleRequest generates a "aws/request.Request" representing the // client's request for the StartCrawlerSchedule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6163,7 +6163,7 @@ const opStartJobRun = "StartJobRun" // StartJobRunRequest generates a "aws/request.Request" representing the // client's request for the StartJobRun operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6257,7 +6257,7 @@ const opStartTrigger = "StartTrigger" // StartTriggerRequest generates a "aws/request.Request" representing the // client's request for the StartTrigger operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6352,7 +6352,7 @@ const opStopCrawler = "StopCrawler" // StopCrawlerRequest generates a "aws/request.Request" representing the // client's request for the StopCrawler operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6440,7 +6440,7 @@ const opStopCrawlerSchedule = "StopCrawlerSchedule" // StopCrawlerScheduleRequest generates a "aws/request.Request" representing the // client's request for the StopCrawlerSchedule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6529,7 +6529,7 @@ const opStopTrigger = "StopTrigger" // StopTriggerRequest generates a "aws/request.Request" representing the // client's request for the StopTrigger operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6620,7 +6620,7 @@ const opUpdateClassifier = "UpdateClassifier" // UpdateClassifierRequest generates a "aws/request.Request" representing the // client's request for the UpdateClassifier operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6709,7 +6709,7 @@ const opUpdateConnection = "UpdateConnection" // UpdateConnectionRequest generates a "aws/request.Request" representing the // client's request for the UpdateConnection operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6794,7 +6794,7 @@ const opUpdateCrawler = "UpdateCrawler" // UpdateCrawlerRequest generates a "aws/request.Request" representing the // client's request for the UpdateCrawler operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6886,7 +6886,7 @@ const opUpdateCrawlerSchedule = "UpdateCrawlerSchedule" // UpdateCrawlerScheduleRequest generates a "aws/request.Request" representing the // client's request for the UpdateCrawlerSchedule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6977,7 +6977,7 @@ const opUpdateDatabase = "UpdateDatabase" // UpdateDatabaseRequest generates a "aws/request.Request" representing the // client's request for the UpdateDatabase operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7065,7 +7065,7 @@ const opUpdateDevEndpoint = "UpdateDevEndpoint" // UpdateDevEndpointRequest generates a "aws/request.Request" representing the // client's request for the UpdateDevEndpoint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7156,7 +7156,7 @@ const opUpdateJob = "UpdateJob" // UpdateJobRequest generates a "aws/request.Request" representing the // client's request for the UpdateJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7247,7 +7247,7 @@ const opUpdatePartition = "UpdatePartition" // UpdatePartitionRequest generates a "aws/request.Request" representing the // client's request for the UpdatePartition operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7335,7 +7335,7 @@ const opUpdateTable = "UpdateTable" // UpdateTableRequest generates a "aws/request.Request" representing the // client's request for the UpdateTable operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7429,7 +7429,7 @@ const opUpdateTrigger = "UpdateTrigger" // UpdateTriggerRequest generates a "aws/request.Request" representing the // client's request for the UpdateTrigger operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7520,7 +7520,7 @@ const opUpdateUserDefinedFunction = "UpdateUserDefinedFunction" // UpdateUserDefinedFunctionRequest generates a "aws/request.Request" representing the // client's request for the UpdateUserDefinedFunction operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9893,9 +9893,7 @@ type CreateDevEndpointInput struct { NumberOfNodes *int64 `type:"integer"` // The public key to use for authentication. - // - // PublicKey is a required field - PublicKey *string `type:"string" required:"true"` + PublicKey *string `type:"string"` // The IAM role for the DevEndpoint. // @@ -9925,9 +9923,6 @@ func (s *CreateDevEndpointInput) Validate() error { if s.EndpointName == nil { invalidParams.Add(request.NewErrParamRequired("EndpointName")) } - if s.PublicKey == nil { - invalidParams.Add(request.NewErrParamRequired("PublicKey")) - } if s.RoleArn == nil { invalidParams.Add(request.NewErrParamRequired("RoleArn")) } @@ -12011,7 +12006,10 @@ type DevEndpoint struct { // The number of AWS Glue Data Processing Units (DPUs) allocated to this DevEndpoint. NumberOfNodes *int64 `type:"integer"` - // The public address used by this DevEndpoint. + // The private address used by this DevEndpoint. + PrivateAddress *string `type:"string"` + + // The public VPC address used by this DevEndpoint. PublicAddress *string `type:"string"` // The public key to be used by this DevEndpoint for authentication. @@ -12103,6 +12101,12 @@ func (s *DevEndpoint) SetNumberOfNodes(v int64) *DevEndpoint { return s } +// SetPrivateAddress sets the PrivateAddress field's value. +func (s *DevEndpoint) SetPrivateAddress(v string) *DevEndpoint { + s.PrivateAddress = &v + return s +} + // SetPublicAddress sets the PublicAddress field's value. func (s *DevEndpoint) SetPublicAddress(v string) *DevEndpoint { s.PublicAddress = &v diff --git a/vendor/github.com/aws/aws-sdk-go/service/guardduty/api.go b/vendor/github.com/aws/aws-sdk-go/service/guardduty/api.go index 5a2e9cfe6007..0273d17d1f91 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/guardduty/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/guardduty/api.go @@ -12,7 +12,7 @@ const opAcceptInvitation = "AcceptInvitation" // AcceptInvitationRequest generates a "aws/request.Request" representing the // client's request for the AcceptInvitation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -94,7 +94,7 @@ const opArchiveFindings = "ArchiveFindings" // ArchiveFindingsRequest generates a "aws/request.Request" representing the // client's request for the ArchiveFindings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -176,7 +176,7 @@ const opCreateDetector = "CreateDetector" // CreateDetectorRequest generates a "aws/request.Request" representing the // client's request for the CreateDetector operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -260,7 +260,7 @@ const opCreateIPSet = "CreateIPSet" // CreateIPSetRequest generates a "aws/request.Request" representing the // client's request for the CreateIPSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -343,7 +343,7 @@ const opCreateMembers = "CreateMembers" // CreateMembersRequest generates a "aws/request.Request" representing the // client's request for the CreateMembers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -427,7 +427,7 @@ const opCreateSampleFindings = "CreateSampleFindings" // CreateSampleFindingsRequest generates a "aws/request.Request" representing the // client's request for the CreateSampleFindings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -511,7 +511,7 @@ const opCreateThreatIntelSet = "CreateThreatIntelSet" // CreateThreatIntelSetRequest generates a "aws/request.Request" representing the // client's request for the CreateThreatIntelSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -594,7 +594,7 @@ const opDeclineInvitations = "DeclineInvitations" // DeclineInvitationsRequest generates a "aws/request.Request" representing the // client's request for the DeclineInvitations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -677,7 +677,7 @@ const opDeleteDetector = "DeleteDetector" // DeleteDetectorRequest generates a "aws/request.Request" representing the // client's request for the DeleteDetector operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -759,7 +759,7 @@ const opDeleteIPSet = "DeleteIPSet" // DeleteIPSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteIPSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -841,7 +841,7 @@ const opDeleteInvitations = "DeleteInvitations" // DeleteInvitationsRequest generates a "aws/request.Request" representing the // client's request for the DeleteInvitations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -924,7 +924,7 @@ const opDeleteMembers = "DeleteMembers" // DeleteMembersRequest generates a "aws/request.Request" representing the // client's request for the DeleteMembers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1007,7 +1007,7 @@ const opDeleteThreatIntelSet = "DeleteThreatIntelSet" // DeleteThreatIntelSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteThreatIntelSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1089,7 +1089,7 @@ const opDisassociateFromMasterAccount = "DisassociateFromMasterAccount" // DisassociateFromMasterAccountRequest generates a "aws/request.Request" representing the // client's request for the DisassociateFromMasterAccount operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1171,7 +1171,7 @@ const opDisassociateMembers = "DisassociateMembers" // DisassociateMembersRequest generates a "aws/request.Request" representing the // client's request for the DisassociateMembers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1254,7 +1254,7 @@ const opGetDetector = "GetDetector" // GetDetectorRequest generates a "aws/request.Request" representing the // client's request for the GetDetector operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1336,7 +1336,7 @@ const opGetFindings = "GetFindings" // GetFindingsRequest generates a "aws/request.Request" representing the // client's request for the GetFindings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1418,7 +1418,7 @@ const opGetFindingsStatistics = "GetFindingsStatistics" // GetFindingsStatisticsRequest generates a "aws/request.Request" representing the // client's request for the GetFindingsStatistics operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1500,7 +1500,7 @@ const opGetIPSet = "GetIPSet" // GetIPSetRequest generates a "aws/request.Request" representing the // client's request for the GetIPSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1582,7 +1582,7 @@ const opGetInvitationsCount = "GetInvitationsCount" // GetInvitationsCountRequest generates a "aws/request.Request" representing the // client's request for the GetInvitationsCount operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1665,7 +1665,7 @@ const opGetMasterAccount = "GetMasterAccount" // GetMasterAccountRequest generates a "aws/request.Request" representing the // client's request for the GetMasterAccount operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1748,7 +1748,7 @@ const opGetMembers = "GetMembers" // GetMembersRequest generates a "aws/request.Request" representing the // client's request for the GetMembers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1831,7 +1831,7 @@ const opGetThreatIntelSet = "GetThreatIntelSet" // GetThreatIntelSetRequest generates a "aws/request.Request" representing the // client's request for the GetThreatIntelSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1913,7 +1913,7 @@ const opInviteMembers = "InviteMembers" // InviteMembersRequest generates a "aws/request.Request" representing the // client's request for the InviteMembers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1998,7 +1998,7 @@ const opListDetectors = "ListDetectors" // ListDetectorsRequest generates a "aws/request.Request" representing the // client's request for the ListDetectors operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2136,7 +2136,7 @@ const opListFindings = "ListFindings" // ListFindingsRequest generates a "aws/request.Request" representing the // client's request for the ListFindings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2274,7 +2274,7 @@ const opListIPSets = "ListIPSets" // ListIPSetsRequest generates a "aws/request.Request" representing the // client's request for the ListIPSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2412,7 +2412,7 @@ const opListInvitations = "ListInvitations" // ListInvitationsRequest generates a "aws/request.Request" representing the // client's request for the ListInvitations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2551,7 +2551,7 @@ const opListMembers = "ListMembers" // ListMembersRequest generates a "aws/request.Request" representing the // client's request for the ListMembers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2690,7 +2690,7 @@ const opListThreatIntelSets = "ListThreatIntelSets" // ListThreatIntelSetsRequest generates a "aws/request.Request" representing the // client's request for the ListThreatIntelSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2829,7 +2829,7 @@ const opStartMonitoringMembers = "StartMonitoringMembers" // StartMonitoringMembersRequest generates a "aws/request.Request" representing the // client's request for the StartMonitoringMembers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2913,7 +2913,7 @@ const opStopMonitoringMembers = "StopMonitoringMembers" // StopMonitoringMembersRequest generates a "aws/request.Request" representing the // client's request for the StopMonitoringMembers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2998,7 +2998,7 @@ const opUnarchiveFindings = "UnarchiveFindings" // UnarchiveFindingsRequest generates a "aws/request.Request" representing the // client's request for the UnarchiveFindings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3080,7 +3080,7 @@ const opUpdateDetector = "UpdateDetector" // UpdateDetectorRequest generates a "aws/request.Request" representing the // client's request for the UpdateDetector operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3162,7 +3162,7 @@ const opUpdateFindingsFeedback = "UpdateFindingsFeedback" // UpdateFindingsFeedbackRequest generates a "aws/request.Request" representing the // client's request for the UpdateFindingsFeedback operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3244,7 +3244,7 @@ const opUpdateIPSet = "UpdateIPSet" // UpdateIPSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateIPSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3326,7 +3326,7 @@ const opUpdateThreatIntelSet = "UpdateThreatIntelSet" // UpdateThreatIntelSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateThreatIntelSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/guardduty/service.go b/vendor/github.com/aws/aws-sdk-go/service/guardduty/service.go index 995709381aae..54c24d4f75f8 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/guardduty/service.go +++ b/vendor/github.com/aws/aws-sdk-go/service/guardduty/service.go @@ -45,14 +45,14 @@ const ( // svc := guardduty.New(mySession, aws.NewConfig().WithRegion("us-west-2")) func New(p client.ConfigProvider, cfgs ...*aws.Config) *GuardDuty { c := p.ClientConfig(EndpointsID, cfgs...) + if c.SigningNameDerived || len(c.SigningName) == 0 { + c.SigningName = "guardduty" + } return newClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion, c.SigningName) } // newClient creates, initializes and returns a new service client instance. func newClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion, signingName string) *GuardDuty { - if len(signingName) == 0 { - signingName = "guardduty" - } svc := &GuardDuty{ Client: client.New( cfg, diff --git a/vendor/github.com/aws/aws-sdk-go/service/iam/api.go b/vendor/github.com/aws/aws-sdk-go/service/iam/api.go index f7878f23ed68..81bab06bfac0 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/iam/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/iam/api.go @@ -17,7 +17,7 @@ const opAddClientIDToOpenIDConnectProvider = "AddClientIDToOpenIDConnectProvider // AddClientIDToOpenIDConnectProviderRequest generates a "aws/request.Request" representing the // client's request for the AddClientIDToOpenIDConnectProvider operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -62,8 +62,8 @@ func (c *IAM) AddClientIDToOpenIDConnectProviderRequest(input *AddClientIDToOpen // Adds a new client ID (also known as audience) to the list of client IDs already // registered for the specified IAM OpenID Connect (OIDC) provider resource. // -// This action is idempotent; it does not fail or return an error if you add -// an existing client ID to the provider. +// This operation is idempotent; it does not fail or return an error if you +// add an existing client ID to the provider. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -115,7 +115,7 @@ const opAddRoleToInstanceProfile = "AddRoleToInstanceProfile" // AddRoleToInstanceProfileRequest generates a "aws/request.Request" representing the // client's request for the AddRoleToInstanceProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -158,7 +158,13 @@ func (c *IAM) AddRoleToInstanceProfileRequest(input *AddRoleToInstanceProfileInp // AddRoleToInstanceProfile API operation for AWS Identity and Access Management. // // Adds the specified IAM role to the specified instance profile. An instance -// profile can contain only one role, and this limit cannot be increased. +// profile can contain only one role, and this limit cannot be increased. You +// can remove the existing role and then add a different role to an instance +// profile. You must then wait for the change to appear across all of AWS because +// of eventual consistency (https://en.wikipedia.org/wiki/Eventual_consistency). +// To force the change, you must disassociate the instance profile (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DisassociateIamInstanceProfile.html) +// and then associate the instance profile (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_AssociateIamInstanceProfile.html), +// or you can stop your instance and then restart it. // // The caller of this API must be granted the PassRole permission on the IAM // role by a permission policy. @@ -223,7 +229,7 @@ const opAddUserToGroup = "AddUserToGroup" // AddUserToGroupRequest generates a "aws/request.Request" representing the // client's request for the AddUserToGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -313,7 +319,7 @@ const opAttachGroupPolicy = "AttachGroupPolicy" // AttachGroupPolicyRequest generates a "aws/request.Request" representing the // client's request for the AttachGroupPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -418,7 +424,7 @@ const opAttachRolePolicy = "AttachRolePolicy" // AttachRolePolicyRequest generates a "aws/request.Request" representing the // client's request for the AttachRolePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -533,7 +539,7 @@ const opAttachUserPolicy = "AttachUserPolicy" // AttachUserPolicyRequest generates a "aws/request.Request" representing the // client's request for the AttachUserPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -638,7 +644,7 @@ const opChangePassword = "ChangePassword" // ChangePasswordRequest generates a "aws/request.Request" representing the // client's request for the ChangePassword operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -680,8 +686,8 @@ func (c *IAM) ChangePasswordRequest(input *ChangePasswordInput) (req *request.Re // ChangePassword API operation for AWS Identity and Access Management. // -// Changes the password of the IAM user who is calling this action. The root -// account password is not affected by this action. +// Changes the password of the IAM user who is calling this operation. The AWS +// account root user password is not affected by this operation. // // To change the password for a different user, see UpdateLoginProfile. For // more information about modifying passwords, see Managing Passwords (http://docs.aws.amazon.com/IAM/latest/UserGuide/Using_ManagingLogins.html) @@ -747,7 +753,7 @@ const opCreateAccessKey = "CreateAccessKey" // CreateAccessKeyRequest generates a "aws/request.Request" representing the // client's request for the CreateAccessKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -791,9 +797,10 @@ func (c *IAM) CreateAccessKeyRequest(input *CreateAccessKeyInput) (req *request. // the specified user. The default status for new keys is Active. // // If you do not specify a user name, IAM determines the user name implicitly -// based on the AWS access key ID signing the request. Because this action works -// for access keys under the AWS account, you can use this action to manage -// root credentials even if the AWS account has no associated users. +// based on the AWS access key ID signing the request. Because this operation +// works for access keys under the AWS account, you can use this operation to +// manage AWS account root user credentials. This is true even if the AWS account +// has no associated users. // // For information about limits on the number of keys you can create, see Limitations // on IAM Entities (http://docs.aws.amazon.com/IAM/latest/UserGuide/LimitationsOnEntities.html) @@ -851,7 +858,7 @@ const opCreateAccountAlias = "CreateAccountAlias" // CreateAccountAliasRequest generates a "aws/request.Request" representing the // client's request for the CreateAccountAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -943,7 +950,7 @@ const opCreateGroup = "CreateGroup" // CreateGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1039,7 +1046,7 @@ const opCreateInstanceProfile = "CreateInstanceProfile" // CreateInstanceProfileRequest generates a "aws/request.Request" representing the // client's request for the CreateInstanceProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1132,7 +1139,7 @@ const opCreateLoginProfile = "CreateLoginProfile" // CreateLoginProfileRequest generates a "aws/request.Request" representing the // client's request for the CreateLoginProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1231,7 +1238,7 @@ const opCreateOpenIDConnectProvider = "CreateOpenIDConnectProvider" // CreateOpenIDConnectProviderRequest generates a "aws/request.Request" representing the // client's request for the CreateOpenIDConnectProvider operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1275,19 +1282,24 @@ func (c *IAM) CreateOpenIDConnectProviderRequest(input *CreateOpenIDConnectProvi // OpenID Connect (OIDC) (http://openid.net/connect/). // // The OIDC provider that you create with this operation can be used as a principal -// in a role's trust policy to establish a trust relationship between AWS and -// the OIDC provider. +// in a role's trust policy. Such a policy establishes a trust relationship +// between AWS and the OIDC provider. // -// When you create the IAM OIDC provider, you specify the URL of the OIDC identity -// provider (IdP) to trust, a list of client IDs (also known as audiences) that -// identify the application or applications that are allowed to authenticate -// using the OIDC provider, and a list of thumbprints of the server certificate(s) -// that the IdP uses. You get all of this information from the OIDC IdP that -// you want to use for access to AWS. +// When you create the IAM OIDC provider, you specify the following: // -// Because trust for the OIDC provider is ultimately derived from the IAM provider -// that this action creates, it is a best practice to limit access to the CreateOpenIDConnectProvider -// action to highly-privileged users. +// * The URL of the OIDC identity provider (IdP) to trust +// +// * A list of client IDs (also known as audiences) that identify the application +// or applications that are allowed to authenticate using the OIDC provider +// +// * A list of thumbprints of the server certificate(s) that the IdP uses. +// +// You get all of this information from the OIDC IdP that you want to use to +// access AWS. +// +// Because trust for the OIDC provider is derived from the IAM provider that +// this operation creates, it is best to limit access to the CreateOpenIDConnectProvider +// operation to highly privileged users. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -1339,7 +1351,7 @@ const opCreatePolicy = "CreatePolicy" // CreatePolicyRequest generates a "aws/request.Request" representing the // client's request for the CreatePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1444,7 +1456,7 @@ const opCreatePolicyVersion = "CreatePolicyVersion" // CreatePolicyVersionRequest generates a "aws/request.Request" representing the // client's request for the CreatePolicyVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1551,7 +1563,7 @@ const opCreateRole = "CreateRole" // CreateRoleRequest generates a "aws/request.Request" representing the // client's request for the CreateRole operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1592,7 +1604,7 @@ func (c *IAM) CreateRoleRequest(input *CreateRoleInput) (req *request.Request, o // CreateRole API operation for AWS Identity and Access Management. // // Creates a new role for your AWS account. For more information about roles, -// go to Working with Roles (http://docs.aws.amazon.com/IAM/latest/UserGuide/WorkingWithRoles.html). +// go to IAM Roles (http://docs.aws.amazon.com/IAM/latest/UserGuide/WorkingWithRoles.html). // For information about limitations on role names and the number of roles you // can create, go to Limitations on IAM Entities (http://docs.aws.amazon.com/IAM/latest/UserGuide/LimitationsOnEntities.html) // in the IAM User Guide. @@ -1651,7 +1663,7 @@ const opCreateSAMLProvider = "CreateSAMLProvider" // CreateSAMLProviderRequest generates a "aws/request.Request" representing the // client's request for the CreateSAMLProvider operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1695,14 +1707,14 @@ func (c *IAM) CreateSAMLProviderRequest(input *CreateSAMLProviderInput) (req *re // SAML 2.0. // // The SAML provider resource that you create with this operation can be used -// as a principal in an IAM role's trust policy to enable federated users who -// sign-in using the SAML IdP to assume the role. You can create an IAM role -// that supports Web-based single sign-on (SSO) to the AWS Management Console -// or one that supports API access to AWS. -// -// When you create the SAML provider resource, you upload an a SAML metadata -// document that you get from your IdP and that includes the issuer's name, -// expiration information, and keys that can be used to validate the SAML authentication +// as a principal in an IAM role's trust policy. Such a policy can enable federated +// users who sign-in using the SAML IdP to assume the role. You can create an +// IAM role that supports Web-based single sign-on (SSO) to the AWS Management +// Console or one that supports API access to AWS. +// +// When you create the SAML provider resource, you upload a SAML metadata document +// that you get from your IdP. That document includes the issuer's name, expiration +// information, and keys that can be used to validate the SAML authentication // response (assertions) that the IdP sends. You must generate the metadata // document using the identity management software that is used as your organization's // IdP. @@ -1764,7 +1776,7 @@ const opCreateServiceLinkedRole = "CreateServiceLinkedRole" // CreateServiceLinkedRoleRequest generates a "aws/request.Request" representing the // client's request for the CreateServiceLinkedRole operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1811,7 +1823,7 @@ func (c *IAM) CreateServiceLinkedRoleRequest(input *CreateServiceLinkedRoleInput // the service to control the role helps improve service stability and proper // cleanup when a service and its role are no longer needed. // -// The name of the role is autogenerated by combining the string that you specify +// The name of the role is generated by combining the string that you specify // for the AWSServiceName parameter with the string that you specify for the // CustomSuffix parameter. The resulting name must be unique in your account // or the request fails. @@ -1869,7 +1881,7 @@ const opCreateServiceSpecificCredential = "CreateServiceSpecificCredential" // CreateServiceSpecificCredentialRequest generates a "aws/request.Request" representing the // client's request for the CreateServiceSpecificCredential operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1969,7 +1981,7 @@ const opCreateUser = "CreateUser" // CreateUserRequest generates a "aws/request.Request" representing the // client's request for the CreateUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2065,7 +2077,7 @@ const opCreateVirtualMFADevice = "CreateVirtualMFADevice" // CreateVirtualMFADeviceRequest generates a "aws/request.Request" representing the // client's request for the CreateVirtualMFADevice operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2166,7 +2178,7 @@ const opDeactivateMFADevice = "DeactivateMFADevice" // DeactivateMFADeviceRequest generates a "aws/request.Request" representing the // client's request for the DeactivateMFADevice operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2267,7 +2279,7 @@ const opDeleteAccessKey = "DeleteAccessKey" // DeleteAccessKeyRequest generates a "aws/request.Request" representing the // client's request for the DeleteAccessKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2312,9 +2324,10 @@ func (c *IAM) DeleteAccessKeyRequest(input *DeleteAccessKeyInput) (req *request. // Deletes the access key pair associated with the specified IAM user. // // If you do not specify a user name, IAM determines the user name implicitly -// based on the AWS access key ID signing the request. Because this action works -// for access keys under the AWS account, you can use this action to manage -// root credentials even if the AWS account has no associated users. +// based on the AWS access key ID signing the request. Because this operation +// works for access keys under the AWS account, you can use this operation to +// manage AWS account root user credentials even if the AWS account has no associated +// users. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -2362,7 +2375,7 @@ const opDeleteAccountAlias = "DeleteAccountAlias" // DeleteAccountAliasRequest generates a "aws/request.Request" representing the // client's request for the DeleteAccountAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2454,7 +2467,7 @@ const opDeleteAccountPasswordPolicy = "DeleteAccountPasswordPolicy" // DeleteAccountPasswordPolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteAccountPasswordPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2544,7 +2557,7 @@ const opDeleteGroup = "DeleteGroup" // DeleteGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2639,7 +2652,7 @@ const opDeleteGroupPolicy = "DeleteGroupPolicy" // DeleteGroupPolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteGroupPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2735,7 +2748,7 @@ const opDeleteInstanceProfile = "DeleteInstanceProfile" // DeleteInstanceProfileRequest generates a "aws/request.Request" representing the // client's request for the DeleteInstanceProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2780,9 +2793,9 @@ func (c *IAM) DeleteInstanceProfileRequest(input *DeleteInstanceProfileInput) (r // Deletes the specified instance profile. The instance profile must not have // an associated role. // -// Make sure you do not have any Amazon EC2 instances running with the instance -// profile you are about to delete. Deleting a role or instance profile that -// is associated with a running instance will break any applications running +// Make sure that you do not have any Amazon EC2 instances running with the +// instance profile you are about to delete. Deleting a role or instance profile +// that is associated with a running instance will break any applications running // on the instance. // // For more information about instance profiles, go to About Instance Profiles @@ -2838,7 +2851,7 @@ const opDeleteLoginProfile = "DeleteLoginProfile" // DeleteLoginProfileRequest generates a "aws/request.Request" representing the // client's request for the DeleteLoginProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2940,7 +2953,7 @@ const opDeleteOpenIDConnectProvider = "DeleteOpenIDConnectProvider" // DeleteOpenIDConnectProviderRequest generates a "aws/request.Request" representing the // client's request for the DeleteOpenIDConnectProvider operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2988,8 +3001,8 @@ func (c *IAM) DeleteOpenIDConnectProviderRequest(input *DeleteOpenIDConnectProvi // the provider as a principal in their trust policies. Any attempt to assume // a role that references a deleted provider fails. // -// This action is idempotent; it does not fail or return an error if you call -// the action for a provider that does not exist. +// This operation is idempotent; it does not fail or return an error if you +// call the operation for a provider that does not exist. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -3037,7 +3050,7 @@ const opDeletePolicy = "DeletePolicy" // DeletePolicyRequest generates a "aws/request.Request" representing the // client's request for the DeletePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3082,14 +3095,14 @@ func (c *IAM) DeletePolicyRequest(input *DeletePolicyInput) (req *request.Reques // Deletes the specified managed policy. // // Before you can delete a managed policy, you must first detach the policy -// from all users, groups, and roles that it is attached to, and you must delete -// all of the policy's versions. The following steps describe the process for -// deleting a managed policy: +// from all users, groups, and roles that it is attached to. In addition you +// must delete all the policy's versions. The following steps describe the process +// for deleting a managed policy: // // * Detach the policy from all users, groups, and roles that the policy // is attached to, using the DetachUserPolicy, DetachGroupPolicy, or DetachRolePolicy -// APIs. To list all the users, groups, and roles that a policy is attached -// to, use ListEntitiesForPolicy. +// API operations. To list all the users, groups, and roles that a policy +// is attached to, use ListEntitiesForPolicy. // // * Delete all versions of the policy using DeletePolicyVersion. To list // the policy's versions, use ListPolicyVersions. You cannot use DeletePolicyVersion @@ -3157,7 +3170,7 @@ const opDeletePolicyVersion = "DeletePolicyVersion" // DeletePolicyVersionRequest generates a "aws/request.Request" representing the // client's request for the DeletePolicyVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3263,7 +3276,7 @@ const opDeleteRole = "DeleteRole" // DeleteRoleRequest generates a "aws/request.Request" representing the // client's request for the DeleteRole operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3308,9 +3321,10 @@ func (c *IAM) DeleteRoleRequest(input *DeleteRoleInput) (req *request.Request, o // Deletes the specified role. The role must not have any policies attached. // For more information about roles, go to Working with Roles (http://docs.aws.amazon.com/IAM/latest/UserGuide/WorkingWithRoles.html). // -// Make sure you do not have any Amazon EC2 instances running with the role -// you are about to delete. Deleting a role or instance profile that is associated -// with a running instance will break any applications running on the instance. +// Make sure that you do not have any Amazon EC2 instances running with the +// role you are about to delete. Deleting a role or instance profile that is +// associated with a running instance will break any applications running on +// the instance. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -3368,7 +3382,7 @@ const opDeleteRolePolicy = "DeleteRolePolicy" // DeleteRolePolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteRolePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3470,7 +3484,7 @@ const opDeleteSAMLProvider = "DeleteSAMLProvider" // DeleteSAMLProviderRequest generates a "aws/request.Request" representing the // client's request for the DeleteSAMLProvider operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3571,7 +3585,7 @@ const opDeleteSSHPublicKey = "DeleteSSHPublicKey" // DeleteSSHPublicKeyRequest generates a "aws/request.Request" representing the // client's request for the DeleteSSHPublicKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3615,7 +3629,7 @@ func (c *IAM) DeleteSSHPublicKeyRequest(input *DeleteSSHPublicKeyInput) (req *re // // Deletes the specified SSH public key. // -// The SSH public key deleted by this action is used only for authenticating +// The SSH public key deleted by this operation is used only for authenticating // the associated IAM user to an AWS CodeCommit repository. For more information // about using SSH keys to authenticate to an AWS CodeCommit repository, see // Set up AWS CodeCommit for SSH Connections (http://docs.aws.amazon.com/codecommit/latest/userguide/setting-up-credentials-ssh.html) @@ -3659,7 +3673,7 @@ const opDeleteServerCertificate = "DeleteServerCertificate" // DeleteServerCertificateRequest generates a "aws/request.Request" representing the // client's request for the DeleteServerCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3703,10 +3717,10 @@ func (c *IAM) DeleteServerCertificateRequest(input *DeleteServerCertificateInput // // Deletes the specified server certificate. // -// For more information about working with server certificates, including a -// list of AWS services that can use the server certificates that you manage -// with IAM, go to Working with Server Certificates (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_server-certs.html) -// in the IAM User Guide. +// For more information about working with server certificates, see Working +// with Server Certificates (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_server-certs.html) +// in the IAM User Guide. This topic also includes a list of AWS services that +// can use the server certificates that you manage with IAM. // // If you are using a server certificate with Elastic Load Balancing, deleting // the certificate could have implications for your application. If Elastic @@ -3768,7 +3782,7 @@ const opDeleteServiceLinkedRole = "DeleteServiceLinkedRole" // DeleteServiceLinkedRoleRequest generates a "aws/request.Request" representing the // client's request for the DeleteServiceLinkedRole operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3818,8 +3832,8 @@ func (c *IAM) DeleteServiceLinkedRoleRequest(input *DeleteServiceLinkedRoleInput // If you submit a deletion request for a service-linked role whose linked service // is still accessing a resource, then the deletion task fails. If it fails, // the GetServiceLinkedRoleDeletionStatus API operation returns the reason for -// the failure, including the resources that must be deleted. To delete the -// service-linked role, you must first remove those resources from the linked +// the failure, usually including the resources that must be deleted. To delete +// the service-linked role, you must first remove those resources from the linked // service and then submit the deletion request again. Resources are specific // to the service that is linked to the role. For more information about removing // resources from a service, see the AWS documentation (http://docs.aws.amazon.com/) @@ -3875,7 +3889,7 @@ const opDeleteServiceSpecificCredential = "DeleteServiceSpecificCredential" // DeleteServiceSpecificCredentialRequest generates a "aws/request.Request" representing the // client's request for the DeleteServiceSpecificCredential operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3957,7 +3971,7 @@ const opDeleteSigningCertificate = "DeleteSigningCertificate" // DeleteSigningCertificateRequest generates a "aws/request.Request" representing the // client's request for the DeleteSigningCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4002,9 +4016,10 @@ func (c *IAM) DeleteSigningCertificateRequest(input *DeleteSigningCertificateInp // Deletes a signing certificate associated with the specified IAM user. // // If you do not specify a user name, IAM determines the user name implicitly -// based on the AWS access key ID signing the request. Because this action works -// for access keys under the AWS account, you can use this action to manage -// root credentials even if the AWS account has no associated IAM users. +// based on the AWS access key ID signing the request. Because this operation +// works for access keys under the AWS account, you can use this operation to +// manage AWS account root user credentials even if the AWS account has no associated +// IAM users. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -4052,7 +4067,7 @@ const opDeleteUser = "DeleteUser" // DeleteUserRequest generates a "aws/request.Request" representing the // client's request for the DeleteUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4147,7 +4162,7 @@ const opDeleteUserPolicy = "DeleteUserPolicy" // DeleteUserPolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteUserPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4243,7 +4258,7 @@ const opDeleteVirtualMFADevice = "DeleteVirtualMFADevice" // DeleteVirtualMFADeviceRequest generates a "aws/request.Request" representing the // client's request for the DeleteVirtualMFADevice operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4340,7 +4355,7 @@ const opDetachGroupPolicy = "DetachGroupPolicy" // DetachGroupPolicyRequest generates a "aws/request.Request" representing the // client's request for the DetachGroupPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4439,7 +4454,7 @@ const opDetachRolePolicy = "DetachRolePolicy" // DetachRolePolicyRequest generates a "aws/request.Request" representing the // client's request for the DetachRolePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4544,7 +4559,7 @@ const opDetachUserPolicy = "DetachUserPolicy" // DetachUserPolicyRequest generates a "aws/request.Request" representing the // client's request for the DetachUserPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4643,7 +4658,7 @@ const opEnableMFADevice = "EnableMFADevice" // EnableMFADeviceRequest generates a "aws/request.Request" representing the // client's request for the EnableMFADevice operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4749,7 +4764,7 @@ const opGenerateCredentialReport = "GenerateCredentialReport" // GenerateCredentialReportRequest generates a "aws/request.Request" representing the // client's request for the GenerateCredentialReport operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4835,7 +4850,7 @@ const opGetAccessKeyLastUsed = "GetAccessKeyLastUsed" // GetAccessKeyLastUsedRequest generates a "aws/request.Request" representing the // client's request for the GetAccessKeyLastUsed operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4918,7 +4933,7 @@ const opGetAccountAuthorizationDetails = "GetAccountAuthorizationDetails" // GetAccountAuthorizationDetailsRequest generates a "aws/request.Request" representing the // client's request for the GetAccountAuthorizationDetails operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4969,6 +4984,12 @@ func (c *IAM) GetAccountAuthorizationDetailsRequest(input *GetAccountAuthorizati // API to obtain a snapshot of the configuration of IAM permissions (users, // groups, roles, and policies) in your account. // +// Policies returned by this API are URL-encoded compliant with RFC 3986 (https://tools.ietf.org/html/rfc3986). +// You can use a URL decoding method to convert the policy back to plain JSON +// text. For example, if you use Java, you can use the decode method of the +// java.net.URLDecoder utility class in the Java SDK. Other languages and SDKs +// provide similar functionality. +// // You can optionally filter the results using the Filter parameter. You can // paginate the results using the MaxItems and Marker parameters. // @@ -5060,7 +5081,7 @@ const opGetAccountPasswordPolicy = "GetAccountPasswordPolicy" // GetAccountPasswordPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetAccountPasswordPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5145,7 +5166,7 @@ const opGetAccountSummary = "GetAccountSummary" // GetAccountSummaryRequest generates a "aws/request.Request" representing the // client's request for the GetAccountSummary operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5229,7 +5250,7 @@ const opGetContextKeysForCustomPolicy = "GetContextKeysForCustomPolicy" // GetContextKeysForCustomPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetContextKeysForCustomPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5274,10 +5295,10 @@ func (c *IAM) GetContextKeysForCustomPolicyRequest(input *GetContextKeysForCusto // keys from policies associated with an IAM user, group, or role, use GetContextKeysForPrincipalPolicy. // // Context keys are variables maintained by AWS and its services that provide -// details about the context of an API query request, and can be evaluated by -// testing against a value specified in an IAM policy. Use GetContextKeysForCustomPolicy +// details about the context of an API query request. Context keys can be evaluated +// by testing against a value specified in an IAM policy. Use GetContextKeysForCustomPolicy // to understand what key names and values you must supply when you call SimulateCustomPolicy. -// Note that all parameters are shown in unencoded form here for clarity, but +// Note that all parameters are shown in unencoded form here for clarity but // must be URL encoded to be included as a part of a real HTML request. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -5318,7 +5339,7 @@ const opGetContextKeysForPrincipalPolicy = "GetContextKeysForPrincipalPolicy" // GetContextKeysForPrincipalPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetContextKeysForPrincipalPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5358,10 +5379,10 @@ func (c *IAM) GetContextKeysForPrincipalPolicyRequest(input *GetContextKeysForPr // GetContextKeysForPrincipalPolicy API operation for AWS Identity and Access Management. // -// Gets a list of all of the context keys referenced in all of the IAM policies -// attached to the specified IAM entity. The entity can be an IAM user, group, -// or role. If you specify a user, then the request also includes all of the -// policies attached to groups that the user is a member of. +// Gets a list of all of the context keys referenced in all the IAM policies +// that are attached to the specified IAM entity. The entity can be an IAM user, +// group, or role. If you specify a user, then the request also includes all +// of the policies attached to groups that the user is a member of. // // You can optionally include a list of one or more additional policies, specified // as strings. If you want to include only a list of policies by string, use @@ -5372,8 +5393,8 @@ func (c *IAM) GetContextKeysForPrincipalPolicyRequest(input *GetContextKeysForPr // allowing them to use GetContextKeysForCustomPolicy instead. // // Context keys are variables maintained by AWS and its services that provide -// details about the context of an API query request, and can be evaluated by -// testing against a value in an IAM policy. Use GetContextKeysForPrincipalPolicy +// details about the context of an API query request. Context keys can be evaluated +// by testing against a value in an IAM policy. Use GetContextKeysForPrincipalPolicy // to understand what key names and values you must supply when you call SimulatePrincipalPolicy. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -5418,7 +5439,7 @@ const opGetCredentialReport = "GetCredentialReport" // GetCredentialReportRequest generates a "aws/request.Request" representing the // client's request for the GetCredentialReport operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5514,7 +5535,7 @@ const opGetGroup = "GetGroup" // GetGroupRequest generates a "aws/request.Request" representing the // client's request for the GetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5655,7 +5676,7 @@ const opGetGroupPolicy = "GetGroupPolicy" // GetGroupPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetGroupPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5755,7 +5776,7 @@ const opGetInstanceProfile = "GetInstanceProfile" // GetInstanceProfileRequest generates a "aws/request.Request" representing the // client's request for the GetInstanceProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5842,7 +5863,7 @@ const opGetLoginProfile = "GetLoginProfile" // GetLoginProfileRequest generates a "aws/request.Request" representing the // client's request for the GetLoginProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5883,8 +5904,8 @@ func (c *IAM) GetLoginProfileRequest(input *GetLoginProfileInput) (req *request. // GetLoginProfile API operation for AWS Identity and Access Management. // // Retrieves the user name and password-creation date for the specified IAM -// user. If the user has not been assigned a password, the action returns a -// 404 (NoSuchEntity) error. +// user. If the user has not been assigned a password, the operation returns +// a 404 (NoSuchEntity) error. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -5928,7 +5949,7 @@ const opGetOpenIDConnectProvider = "GetOpenIDConnectProvider" // GetOpenIDConnectProviderRequest generates a "aws/request.Request" representing the // client's request for the GetOpenIDConnectProvider operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6017,7 +6038,7 @@ const opGetPolicy = "GetPolicy" // GetPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6118,7 +6139,7 @@ const opGetPolicyVersion = "GetPolicyVersion" // GetPolicyVersionRequest generates a "aws/request.Request" representing the // client's request for the GetPolicyVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6227,7 +6248,7 @@ const opGetRole = "GetRole" // GetRoleRequest generates a "aws/request.Request" representing the // client's request for the GetRole operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6319,7 +6340,7 @@ const opGetRolePolicy = "GetRolePolicy" // GetRolePolicyRequest generates a "aws/request.Request" representing the // client's request for the GetRolePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6422,7 +6443,7 @@ const opGetSAMLProvider = "GetSAMLProvider" // GetSAMLProviderRequest generates a "aws/request.Request" representing the // client's request for the GetSAMLProvider operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6513,7 +6534,7 @@ const opGetSSHPublicKey = "GetSSHPublicKey" // GetSSHPublicKeyRequest generates a "aws/request.Request" representing the // client's request for the GetSSHPublicKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6555,7 +6576,7 @@ func (c *IAM) GetSSHPublicKeyRequest(input *GetSSHPublicKeyInput) (req *request. // // Retrieves the specified SSH public key, including metadata about the key. // -// The SSH public key retrieved by this action is used only for authenticating +// The SSH public key retrieved by this operation is used only for authenticating // the associated IAM user to an AWS CodeCommit repository. For more information // about using SSH keys to authenticate to an AWS CodeCommit repository, see // Set up AWS CodeCommit for SSH Connections (http://docs.aws.amazon.com/codecommit/latest/userguide/setting-up-credentials-ssh.html) @@ -6603,7 +6624,7 @@ const opGetServerCertificate = "GetServerCertificate" // GetServerCertificateRequest generates a "aws/request.Request" representing the // client's request for the GetServerCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6645,10 +6666,10 @@ func (c *IAM) GetServerCertificateRequest(input *GetServerCertificateInput) (req // // Retrieves information about the specified server certificate stored in IAM. // -// For more information about working with server certificates, including a -// list of AWS services that can use the server certificates that you manage -// with IAM, go to Working with Server Certificates (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_server-certs.html) -// in the IAM User Guide. +// For more information about working with server certificates, see Working +// with Server Certificates (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_server-certs.html) +// in the IAM User Guide. This topic includes a list of AWS services that can +// use the server certificates that you manage with IAM. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -6692,7 +6713,7 @@ const opGetServiceLinkedRoleDeletionStatus = "GetServiceLinkedRoleDeletionStatus // GetServiceLinkedRoleDeletionStatusRequest generates a "aws/request.Request" representing the // client's request for the GetServiceLinkedRoleDeletionStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6736,7 +6757,8 @@ func (c *IAM) GetServiceLinkedRoleDeletionStatusRequest(input *GetServiceLinkedR // the DeleteServiceLinkedRole API operation to submit a service-linked role // for deletion, you can use the DeletionTaskId parameter in GetServiceLinkedRoleDeletionStatus // to check the status of the deletion. If the deletion fails, this operation -// returns the reason that it failed. +// returns the reason that it failed, if that information is returned by the +// service. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -6784,7 +6806,7 @@ const opGetUser = "GetUser" // GetUserRequest generates a "aws/request.Request" representing the // client's request for the GetUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6872,7 +6894,7 @@ const opGetUserPolicy = "GetUserPolicy" // GetUserPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetUserPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6972,7 +6994,7 @@ const opListAccessKeys = "ListAccessKeys" // ListAccessKeysRequest generates a "aws/request.Request" representing the // client's request for the ListAccessKeys operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7019,15 +7041,16 @@ func (c *IAM) ListAccessKeysRequest(input *ListAccessKeysInput) (req *request.Re // ListAccessKeys API operation for AWS Identity and Access Management. // // Returns information about the access key IDs associated with the specified -// IAM user. If there are none, the action returns an empty list. +// IAM user. If there are none, the operation returns an empty list. // // Although each user is limited to a small number of keys, you can still paginate // the results using the MaxItems and Marker parameters. // -// If the UserName field is not specified, the UserName is determined implicitly -// based on the AWS access key ID used to sign the request. Because this action -// works for access keys under the AWS account, you can use this action to manage -// root credentials even if the AWS account has no associated users. +// If the UserName field is not specified, the user name is determined implicitly +// based on the AWS access key ID used to sign the request. Because this operation +// works for access keys under the AWS account, you can use this operation to +// manage AWS account root user credentials even if the AWS account has no associated +// users. // // To ensure the security of your AWS account, the secret access key is accessible // only during key and user creation. @@ -7124,7 +7147,7 @@ const opListAccountAliases = "ListAccountAliases" // ListAccountAliasesRequest generates a "aws/request.Request" representing the // client's request for the ListAccountAliases operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7263,7 +7286,7 @@ const opListAttachedGroupPolicies = "ListAttachedGroupPolicies" // ListAttachedGroupPoliciesRequest generates a "aws/request.Request" representing the // client's request for the ListAttachedGroupPolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7319,7 +7342,7 @@ func (c *IAM) ListAttachedGroupPoliciesRequest(input *ListAttachedGroupPoliciesI // You can paginate the results using the MaxItems and Marker parameters. You // can use the PathPrefix parameter to limit the list of policies to only those // matching the specified path prefix. If there are no policies attached to -// the specified group (or none that match the specified path prefix), the action +// the specified group (or none that match the specified path prefix), the operation // returns an empty list. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -7418,7 +7441,7 @@ const opListAttachedRolePolicies = "ListAttachedRolePolicies" // ListAttachedRolePoliciesRequest generates a "aws/request.Request" representing the // client's request for the ListAttachedRolePolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7474,7 +7497,7 @@ func (c *IAM) ListAttachedRolePoliciesRequest(input *ListAttachedRolePoliciesInp // You can paginate the results using the MaxItems and Marker parameters. You // can use the PathPrefix parameter to limit the list of policies to only those // matching the specified path prefix. If there are no policies attached to -// the specified role (or none that match the specified path prefix), the action +// the specified role (or none that match the specified path prefix), the operation // returns an empty list. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -7573,7 +7596,7 @@ const opListAttachedUserPolicies = "ListAttachedUserPolicies" // ListAttachedUserPoliciesRequest generates a "aws/request.Request" representing the // client's request for the ListAttachedUserPolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7629,7 +7652,7 @@ func (c *IAM) ListAttachedUserPoliciesRequest(input *ListAttachedUserPoliciesInp // You can paginate the results using the MaxItems and Marker parameters. You // can use the PathPrefix parameter to limit the list of policies to only those // matching the specified path prefix. If there are no policies attached to -// the specified group (or none that match the specified path prefix), the action +// the specified group (or none that match the specified path prefix), the operation // returns an empty list. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -7728,7 +7751,7 @@ const opListEntitiesForPolicy = "ListEntitiesForPolicy" // ListEntitiesForPolicyRequest generates a "aws/request.Request" representing the // client's request for the ListEntitiesForPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7880,7 +7903,7 @@ const opListGroupPolicies = "ListGroupPolicies" // ListGroupPoliciesRequest generates a "aws/request.Request" representing the // client's request for the ListGroupPolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7936,7 +7959,7 @@ func (c *IAM) ListGroupPoliciesRequest(input *ListGroupPoliciesInput) (req *requ // in the IAM User Guide. // // You can paginate the results using the MaxItems and Marker parameters. If -// there are no inline policies embedded with the specified group, the action +// there are no inline policies embedded with the specified group, the operation // returns an empty list. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -8031,7 +8054,7 @@ const opListGroups = "ListGroups" // ListGroupsRequest generates a "aws/request.Request" representing the // client's request for the ListGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8169,7 +8192,7 @@ const opListGroupsForUser = "ListGroupsForUser" // ListGroupsForUserRequest generates a "aws/request.Request" representing the // client's request for the ListGroupsForUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8311,7 +8334,7 @@ const opListInstanceProfiles = "ListInstanceProfiles" // ListInstanceProfilesRequest generates a "aws/request.Request" representing the // client's request for the ListInstanceProfiles operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8358,8 +8381,8 @@ func (c *IAM) ListInstanceProfilesRequest(input *ListInstanceProfilesInput) (req // ListInstanceProfiles API operation for AWS Identity and Access Management. // // Lists the instance profiles that have the specified path prefix. If there -// are none, the action returns an empty list. For more information about instance -// profiles, go to About Instance Profiles (http://docs.aws.amazon.com/IAM/latest/UserGuide/AboutInstanceProfiles.html). +// are none, the operation returns an empty list. For more information about +// instance profiles, go to About Instance Profiles (http://docs.aws.amazon.com/IAM/latest/UserGuide/AboutInstanceProfiles.html). // // You can paginate the results using the MaxItems and Marker parameters. // @@ -8451,7 +8474,7 @@ const opListInstanceProfilesForRole = "ListInstanceProfilesForRole" // ListInstanceProfilesForRoleRequest generates a "aws/request.Request" representing the // client's request for the ListInstanceProfilesForRole operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8498,7 +8521,7 @@ func (c *IAM) ListInstanceProfilesForRoleRequest(input *ListInstanceProfilesForR // ListInstanceProfilesForRole API operation for AWS Identity and Access Management. // // Lists the instance profiles that have the specified associated IAM role. -// If there are none, the action returns an empty list. For more information +// If there are none, the operation returns an empty list. For more information // about instance profiles, go to About Instance Profiles (http://docs.aws.amazon.com/IAM/latest/UserGuide/AboutInstanceProfiles.html). // // You can paginate the results using the MaxItems and Marker parameters. @@ -8595,7 +8618,7 @@ const opListMFADevices = "ListMFADevices" // ListMFADevicesRequest generates a "aws/request.Request" representing the // client's request for the ListMFADevices operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8642,7 +8665,7 @@ func (c *IAM) ListMFADevicesRequest(input *ListMFADevicesInput) (req *request.Re // ListMFADevices API operation for AWS Identity and Access Management. // // Lists the MFA devices for an IAM user. If the request includes a IAM user -// name, then this action lists all the MFA devices associated with the specified +// name, then this operation lists all the MFA devices associated with the specified // user. If you do not specify a user name, IAM determines the user name implicitly // based on the AWS access key ID signing the request for this API. // @@ -8740,7 +8763,7 @@ const opListOpenIDConnectProviders = "ListOpenIDConnectProviders" // ListOpenIDConnectProvidersRequest generates a "aws/request.Request" representing the // client's request for the ListOpenIDConnectProviders operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8821,7 +8844,7 @@ const opListPolicies = "ListPolicies" // ListPoliciesRequest generates a "aws/request.Request" representing the // client's request for the ListPolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8969,7 +8992,7 @@ const opListPolicyVersions = "ListPolicyVersions" // ListPolicyVersionsRequest generates a "aws/request.Request" representing the // client's request for the ListPolicyVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9118,7 +9141,7 @@ const opListRolePolicies = "ListRolePolicies" // ListRolePoliciesRequest generates a "aws/request.Request" representing the // client's request for the ListRolePolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9173,7 +9196,7 @@ func (c *IAM) ListRolePoliciesRequest(input *ListRolePoliciesInput) (req *reques // in the IAM User Guide. // // You can paginate the results using the MaxItems and Marker parameters. If -// there are no inline policies embedded with the specified role, the action +// there are no inline policies embedded with the specified role, the operation // returns an empty list. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -9268,7 +9291,7 @@ const opListRoles = "ListRoles" // ListRolesRequest generates a "aws/request.Request" representing the // client's request for the ListRoles operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9315,8 +9338,8 @@ func (c *IAM) ListRolesRequest(input *ListRolesInput) (req *request.Request, out // ListRoles API operation for AWS Identity and Access Management. // // Lists the IAM roles that have the specified path prefix. If there are none, -// the action returns an empty list. For more information about roles, go to -// Working with Roles (http://docs.aws.amazon.com/IAM/latest/UserGuide/WorkingWithRoles.html). +// the operation returns an empty list. For more information about roles, go +// to Working with Roles (http://docs.aws.amazon.com/IAM/latest/UserGuide/WorkingWithRoles.html). // // You can paginate the results using the MaxItems and Marker parameters. // @@ -9408,7 +9431,7 @@ const opListSAMLProviders = "ListSAMLProviders" // ListSAMLProvidersRequest generates a "aws/request.Request" representing the // client's request for the ListSAMLProviders operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9490,7 +9513,7 @@ const opListSSHPublicKeys = "ListSSHPublicKeys" // ListSSHPublicKeysRequest generates a "aws/request.Request" representing the // client's request for the ListSSHPublicKeys operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9537,9 +9560,9 @@ func (c *IAM) ListSSHPublicKeysRequest(input *ListSSHPublicKeysInput) (req *requ // ListSSHPublicKeys API operation for AWS Identity and Access Management. // // Returns information about the SSH public keys associated with the specified -// IAM user. If there are none, the action returns an empty list. +// IAM user. If there are none, the operation returns an empty list. // -// The SSH public keys returned by this action are used only for authenticating +// The SSH public keys returned by this operation are used only for authenticating // the IAM user to an AWS CodeCommit repository. For more information about // using SSH keys to authenticate to an AWS CodeCommit repository, see Set up // AWS CodeCommit for SSH Connections (http://docs.aws.amazon.com/codecommit/latest/userguide/setting-up-credentials-ssh.html) @@ -9636,7 +9659,7 @@ const opListServerCertificates = "ListServerCertificates" // ListServerCertificatesRequest generates a "aws/request.Request" representing the // client's request for the ListServerCertificates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9683,14 +9706,14 @@ func (c *IAM) ListServerCertificatesRequest(input *ListServerCertificatesInput) // ListServerCertificates API operation for AWS Identity and Access Management. // // Lists the server certificates stored in IAM that have the specified path -// prefix. If none exist, the action returns an empty list. +// prefix. If none exist, the operation returns an empty list. // // You can paginate the results using the MaxItems and Marker parameters. // -// For more information about working with server certificates, including a -// list of AWS services that can use the server certificates that you manage -// with IAM, go to Working with Server Certificates (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_server-certs.html) -// in the IAM User Guide. +// For more information about working with server certificates, see Working +// with Server Certificates (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_server-certs.html) +// in the IAM User Guide. This topic also includes a list of AWS services that +// can use the server certificates that you manage with IAM. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -9780,7 +9803,7 @@ const opListServiceSpecificCredentials = "ListServiceSpecificCredentials" // ListServiceSpecificCredentialsRequest generates a "aws/request.Request" representing the // client's request for the ListServiceSpecificCredentials operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9821,11 +9844,11 @@ func (c *IAM) ListServiceSpecificCredentialsRequest(input *ListServiceSpecificCr // ListServiceSpecificCredentials API operation for AWS Identity and Access Management. // // Returns information about the service-specific credentials associated with -// the specified IAM user. If there are none, the action returns an empty list. -// The service-specific credentials returned by this action are used only for -// authenticating the IAM user to a specific service. For more information about -// using service-specific credentials to authenticate to an AWS service, see -// Set Up service-specific credentials (http://docs.aws.amazon.com/codecommit/latest/userguide/setting-up-gc.html) +// the specified IAM user. If there are none, the operation returns an empty +// list. The service-specific credentials returned by this operation are used +// only for authenticating the IAM user to a specific service. For more information +// about using service-specific credentials to authenticate to an AWS service, +// see Set Up service-specific credentials (http://docs.aws.amazon.com/codecommit/latest/userguide/setting-up-gc.html) // in the AWS CodeCommit User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -9869,7 +9892,7 @@ const opListSigningCertificates = "ListSigningCertificates" // ListSigningCertificatesRequest generates a "aws/request.Request" representing the // client's request for the ListSigningCertificates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9916,16 +9939,16 @@ func (c *IAM) ListSigningCertificatesRequest(input *ListSigningCertificatesInput // ListSigningCertificates API operation for AWS Identity and Access Management. // // Returns information about the signing certificates associated with the specified -// IAM user. If there are none, the action returns an empty list. +// IAM user. If there are none, the operation returns an empty list. // // Although each user is limited to a small number of signing certificates, // you can still paginate the results using the MaxItems and Marker parameters. // // If the UserName field is not specified, the user name is determined implicitly // based on the AWS access key ID used to sign the request for this API. Because -// this action works for access keys under the AWS account, you can use this -// action to manage root credentials even if the AWS account has no associated -// users. +// this operation works for access keys under the AWS account, you can use this +// operation to manage AWS account root user credentials even if the AWS account +// has no associated users. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -10019,7 +10042,7 @@ const opListUserPolicies = "ListUserPolicies" // ListUserPoliciesRequest generates a "aws/request.Request" representing the // client's request for the ListUserPolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10073,7 +10096,7 @@ func (c *IAM) ListUserPoliciesRequest(input *ListUserPoliciesInput) (req *reques // in the IAM User Guide. // // You can paginate the results using the MaxItems and Marker parameters. If -// there are no inline policies embedded with the specified user, the action +// there are no inline policies embedded with the specified user, the operation // returns an empty list. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -10168,7 +10191,7 @@ const opListUsers = "ListUsers" // ListUsersRequest generates a "aws/request.Request" representing the // client's request for the ListUsers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10215,8 +10238,8 @@ func (c *IAM) ListUsersRequest(input *ListUsersInput) (req *request.Request, out // ListUsers API operation for AWS Identity and Access Management. // // Lists the IAM users that have the specified path prefix. If no path prefix -// is specified, the action returns all users in the AWS account. If there are -// none, the action returns an empty list. +// is specified, the operation returns all users in the AWS account. If there +// are none, the operation returns an empty list. // // You can paginate the results using the MaxItems and Marker parameters. // @@ -10308,7 +10331,7 @@ const opListVirtualMFADevices = "ListVirtualMFADevices" // ListVirtualMFADevicesRequest generates a "aws/request.Request" representing the // client's request for the ListVirtualMFADevices operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10355,9 +10378,9 @@ func (c *IAM) ListVirtualMFADevicesRequest(input *ListVirtualMFADevicesInput) (r // ListVirtualMFADevices API operation for AWS Identity and Access Management. // // Lists the virtual MFA devices defined in the AWS account by assignment status. -// If you do not specify an assignment status, the action returns a list of -// all virtual MFA devices. Assignment status can be Assigned, Unassigned, or -// Any. +// If you do not specify an assignment status, the operation returns a list +// of all virtual MFA devices. Assignment status can be Assigned, Unassigned, +// or Any. // // You can paginate the results using the MaxItems and Marker parameters. // @@ -10443,7 +10466,7 @@ const opPutGroupPolicy = "PutGroupPolicy" // PutGroupPolicyRequest generates a "aws/request.Request" representing the // client's request for the PutGroupPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10553,7 +10576,7 @@ const opPutRolePolicy = "PutRolePolicy" // PutRolePolicyRequest generates a "aws/request.Request" representing the // client's request for the PutRolePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10675,7 +10698,7 @@ const opPutUserPolicy = "PutUserPolicy" // PutUserPolicyRequest generates a "aws/request.Request" representing the // client's request for the PutUserPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10785,7 +10808,7 @@ const opRemoveClientIDFromOpenIDConnectProvider = "RemoveClientIDFromOpenIDConne // RemoveClientIDFromOpenIDConnectProviderRequest generates a "aws/request.Request" representing the // client's request for the RemoveClientIDFromOpenIDConnectProvider operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10831,8 +10854,8 @@ func (c *IAM) RemoveClientIDFromOpenIDConnectProviderRequest(input *RemoveClient // client IDs registered for the specified IAM OpenID Connect (OIDC) provider // resource object. // -// This action is idempotent; it does not fail or return an error if you try -// to remove a client ID that does not exist. +// This operation is idempotent; it does not fail or return an error if you +// try to remove a client ID that does not exist. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -10880,7 +10903,7 @@ const opRemoveRoleFromInstanceProfile = "RemoveRoleFromInstanceProfile" // RemoveRoleFromInstanceProfileRequest generates a "aws/request.Request" representing the // client's request for the RemoveRoleFromInstanceProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10924,10 +10947,10 @@ func (c *IAM) RemoveRoleFromInstanceProfileRequest(input *RemoveRoleFromInstance // // Removes the specified IAM role from the specified EC2 instance profile. // -// Make sure you do not have any Amazon EC2 instances running with the role -// you are about to remove from the instance profile. Removing a role from an -// instance profile that is associated with a running instance might break any -// applications running on the instance. +// Make sure that you do not have any Amazon EC2 instances running with the +// role you are about to remove from the instance profile. Removing a role from +// an instance profile that is associated with a running instance might break +// any applications running on the instance. // // For more information about IAM roles, go to Working with Roles (http://docs.aws.amazon.com/IAM/latest/UserGuide/WorkingWithRoles.html). // For more information about instance profiles, go to About Instance Profiles @@ -10985,7 +11008,7 @@ const opRemoveUserFromGroup = "RemoveUserFromGroup" // RemoveUserFromGroupRequest generates a "aws/request.Request" representing the // client's request for the RemoveUserFromGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11075,7 +11098,7 @@ const opResetServiceSpecificCredential = "ResetServiceSpecificCredential" // ResetServiceSpecificCredentialRequest generates a "aws/request.Request" representing the // client's request for the ResetServiceSpecificCredential operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11158,7 +11181,7 @@ const opResyncMFADevice = "ResyncMFADevice" // ResyncMFADeviceRequest generates a "aws/request.Request" representing the // client's request for the ResyncMFADevice operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11257,7 +11280,7 @@ const opSetDefaultPolicyVersion = "SetDefaultPolicyVersion" // SetDefaultPolicyVersionRequest generates a "aws/request.Request" representing the // client's request for the SetDefaultPolicyVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11302,7 +11325,7 @@ func (c *IAM) SetDefaultPolicyVersionRequest(input *SetDefaultPolicyVersionInput // Sets the specified version of the specified policy as the policy's default // (operative) version. // -// This action affects all users, groups, and roles that the policy is attached +// This operation affects all users, groups, and roles that the policy is attached // to. To list the users, groups, and roles that the policy is attached to, // use the ListEntitiesForPolicy API. // @@ -11360,7 +11383,7 @@ const opSimulateCustomPolicy = "SimulateCustomPolicy" // SimulateCustomPolicyRequest generates a "aws/request.Request" representing the // client's request for the SimulateCustomPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11407,11 +11430,11 @@ func (c *IAM) SimulateCustomPolicyRequest(input *SimulateCustomPolicyInput) (req // SimulateCustomPolicy API operation for AWS Identity and Access Management. // // Simulate how a set of IAM policies and optionally a resource-based policy -// works with a list of API actions and AWS resources to determine the policies' +// works with a list of API operations and AWS resources to determine the policies' // effective permissions. The policies are provided as strings. // -// The simulation does not perform the API actions; it only checks the authorization -// to determine if the simulated policies allow or deny the actions. +// The simulation does not perform the API operations; it only checks the authorization +// to determine if the simulated policies allow or deny the operations. // // If you want to simulate existing policies attached to an IAM user, group, // or role, use SimulatePrincipalPolicy instead. @@ -11516,7 +11539,7 @@ const opSimulatePrincipalPolicy = "SimulatePrincipalPolicy" // SimulatePrincipalPolicyRequest generates a "aws/request.Request" representing the // client's request for the SimulatePrincipalPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11563,10 +11586,10 @@ func (c *IAM) SimulatePrincipalPolicyRequest(input *SimulatePrincipalPolicyInput // SimulatePrincipalPolicy API operation for AWS Identity and Access Management. // // Simulate how a set of IAM policies attached to an IAM entity works with a -// list of API actions and AWS resources to determine the policies' effective +// list of API operations and AWS resources to determine the policies' effective // permissions. The entity can be an IAM user, group, or role. If you specify // a user, then the simulation also includes all of the policies that are attached -// to groups that the user belongs to . +// to groups that the user belongs to. // // You can optionally include a list of one or more additional policies specified // as strings to include in the simulation. If you want to simulate only policies @@ -11575,8 +11598,8 @@ func (c *IAM) SimulatePrincipalPolicyRequest(input *SimulatePrincipalPolicyInput // You can also optionally include one resource-based policy to be evaluated // with each of the resources included in the simulation. // -// The simulation does not perform the API actions, it only checks the authorization -// to determine if the simulated policies allow or deny the actions. +// The simulation does not perform the API operations, it only checks the authorization +// to determine if the simulated policies allow or deny the operations. // // Note: This API discloses information about the permissions granted to other // users. If you do not want users to see other user's permissions, then consider @@ -11686,7 +11709,7 @@ const opUpdateAccessKey = "UpdateAccessKey" // UpdateAccessKeyRequest generates a "aws/request.Request" representing the // client's request for the UpdateAccessKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11729,13 +11752,14 @@ func (c *IAM) UpdateAccessKeyRequest(input *UpdateAccessKeyInput) (req *request. // UpdateAccessKey API operation for AWS Identity and Access Management. // // Changes the status of the specified access key from Active to Inactive, or -// vice versa. This action can be used to disable a user's key as part of a -// key rotation work flow. +// vice versa. This operation can be used to disable a user's key as part of +// a key rotation workflow. // -// If the UserName field is not specified, the UserName is determined implicitly -// based on the AWS access key ID used to sign the request. Because this action -// works for access keys under the AWS account, you can use this action to manage -// root credentials even if the AWS account has no associated users. +// If the UserName field is not specified, the user name is determined implicitly +// based on the AWS access key ID used to sign the request. Because this operation +// works for access keys under the AWS account, you can use this operation to +// manage AWS account root user credentials even if the AWS account has no associated +// users. // // For information about rotating keys, see Managing Keys and Certificates (http://docs.aws.amazon.com/IAM/latest/UserGuide/ManagingCredentials.html) // in the IAM User Guide. @@ -11786,7 +11810,7 @@ const opUpdateAccountPasswordPolicy = "UpdateAccountPasswordPolicy" // UpdateAccountPasswordPolicyRequest generates a "aws/request.Request" representing the // client's request for the UpdateAccountPasswordPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11830,10 +11854,12 @@ func (c *IAM) UpdateAccountPasswordPolicyRequest(input *UpdateAccountPasswordPol // // Updates the password policy settings for the AWS account. // -// This action does not support partial updates. No parameters are required, +// This operation does not support partial updates. No parameters are required, // but if you do not specify a parameter, that parameter's value reverts to // its default value. See the Request Parameters section for each parameter's -// default value. +// default value. Also note that some parameters do not allow the default parameter +// to be explicitly set. Instead, to invoke the default value, do not include +// that parameter when you invoke the operation. // // For more information about using a password policy, see Managing an IAM Password // Policy (http://docs.aws.amazon.com/IAM/latest/UserGuide/Using_ManagingPasswordPolicies.html) @@ -11889,7 +11915,7 @@ const opUpdateAssumeRolePolicy = "UpdateAssumeRolePolicy" // UpdateAssumeRolePolicyRequest generates a "aws/request.Request" representing the // client's request for the UpdateAssumeRolePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11992,7 +12018,7 @@ const opUpdateGroup = "UpdateGroup" // UpdateGroupRequest generates a "aws/request.Request" representing the // client's request for the UpdateGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12040,11 +12066,12 @@ func (c *IAM) UpdateGroupRequest(input *UpdateGroupInput) (req *request.Request, // For more information, see Renaming Users and Groups (http://docs.aws.amazon.com/IAM/latest/UserGuide/Using_WorkingWithGroupsAndUsers.html) // in the IAM User Guide. // -// To change an IAM group name the requester must have appropriate permissions -// on both the source object and the target object. For example, to change "Managers" -// to "MGRs", the entity making the request must have permission on both "Managers" -// and "MGRs", or must have permission on all (*). For more information about -// permissions, see Permissions and Policies (http://docs.aws.amazon.com/IAM/latest/UserGuide/PermissionsAndPolicies.html). +// The person making the request (the principal), must have permission to change +// the role group with the old name and the new name. For example, to change +// the group named Managers to MGRs, the principal must have a policy that allows +// them to update both groups. If the principal has permission to update the +// Managers group, but not the MGRs group, then the update fails. For more information +// about permissions, see Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html). // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -12096,7 +12123,7 @@ const opUpdateLoginProfile = "UpdateLoginProfile" // UpdateLoginProfileRequest generates a "aws/request.Request" representing the // client's request for the UpdateLoginProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12200,7 +12227,7 @@ const opUpdateOpenIDConnectProviderThumbprint = "UpdateOpenIDConnectProviderThum // UpdateOpenIDConnectProviderThumbprintRequest generates a "aws/request.Request" representing the // client's request for the UpdateOpenIDConnectProviderThumbprint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12245,7 +12272,7 @@ func (c *IAM) UpdateOpenIDConnectProviderThumbprintRequest(input *UpdateOpenIDCo // Replaces the existing list of server certificate thumbprints associated with // an OpenID Connect (OIDC) provider resource object with a new list of thumbprints. // -// The list that you pass with this action completely replaces the existing +// The list that you pass with this operation completely replaces the existing // list of thumbprints. (The lists are not merged.) // // Typically, you need to update a thumbprint only when the identity provider's @@ -12253,10 +12280,9 @@ func (c *IAM) UpdateOpenIDConnectProviderThumbprintRequest(input *UpdateOpenIDCo // does change, any attempt to assume an IAM role that specifies the OIDC provider // as a principal fails until the certificate thumbprint is updated. // -// Because trust for the OIDC provider is ultimately derived from the provider's -// certificate and is validated by the thumbprint, it is a best practice to -// limit access to the UpdateOpenIDConnectProviderThumbprint action to highly-privileged -// users. +// Because trust for the OIDC provider is derived from the provider's certificate +// and is validated by the thumbprint, it is best to limit access to the UpdateOpenIDConnectProviderThumbprint +// operation to highly privileged users. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -12300,11 +12326,101 @@ func (c *IAM) UpdateOpenIDConnectProviderThumbprintWithContext(ctx aws.Context, return out, req.Send() } +const opUpdateRole = "UpdateRole" + +// UpdateRoleRequest generates a "aws/request.Request" representing the +// client's request for the UpdateRole operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateRole for more information on using the UpdateRole +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the UpdateRoleRequest method. +// req, resp := client.UpdateRoleRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/iam-2010-05-08/UpdateRole +func (c *IAM) UpdateRoleRequest(input *UpdateRoleInput) (req *request.Request, output *UpdateRoleOutput) { + op := &request.Operation{ + Name: opUpdateRole, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &UpdateRoleInput{} + } + + output = &UpdateRoleOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateRole API operation for AWS Identity and Access Management. +// +// Updates the description or maximum session duration setting of a role. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Identity and Access Management's +// API operation UpdateRole for usage and error information. +// +// Returned Error Codes: +// * ErrCodeUnmodifiableEntityException "UnmodifiableEntity" +// The request was rejected because only the service that depends on the service-linked +// role can modify or delete the role on your behalf. The error message includes +// the name of the service that depends on this service-linked role. You must +// request the change through that service. +// +// * ErrCodeNoSuchEntityException "NoSuchEntity" +// The request was rejected because it referenced an entity that does not exist. +// The error message describes the entity. +// +// * ErrCodeServiceFailureException "ServiceFailure" +// The request processing has failed because of an unknown error, exception +// or failure. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/iam-2010-05-08/UpdateRole +func (c *IAM) UpdateRole(input *UpdateRoleInput) (*UpdateRoleOutput, error) { + req, out := c.UpdateRoleRequest(input) + return out, req.Send() +} + +// UpdateRoleWithContext is the same as UpdateRole with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateRole for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *IAM) UpdateRoleWithContext(ctx aws.Context, input *UpdateRoleInput, opts ...request.Option) (*UpdateRoleOutput, error) { + req, out := c.UpdateRoleRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opUpdateRoleDescription = "UpdateRoleDescription" // UpdateRoleDescriptionRequest generates a "aws/request.Request" representing the // client's request for the UpdateRoleDescription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12344,7 +12460,10 @@ func (c *IAM) UpdateRoleDescriptionRequest(input *UpdateRoleDescriptionInput) (r // UpdateRoleDescription API operation for AWS Identity and Access Management. // -// Modifies the description of a role. +// Use instead. +// +// Modifies only the description of a role. This operation performs the same +// function as the Description parameter in the UpdateRole operation. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -12394,7 +12513,7 @@ const opUpdateSAMLProvider = "UpdateSAMLProvider" // UpdateSAMLProviderRequest generates a "aws/request.Request" representing the // client's request for the UpdateSAMLProvider operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12488,7 +12607,7 @@ const opUpdateSSHPublicKey = "UpdateSSHPublicKey" // UpdateSSHPublicKeyRequest generates a "aws/request.Request" representing the // client's request for the UpdateSSHPublicKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12531,11 +12650,11 @@ func (c *IAM) UpdateSSHPublicKeyRequest(input *UpdateSSHPublicKeyInput) (req *re // UpdateSSHPublicKey API operation for AWS Identity and Access Management. // // Sets the status of an IAM user's SSH public key to active or inactive. SSH -// public keys that are inactive cannot be used for authentication. This action +// public keys that are inactive cannot be used for authentication. This operation // can be used to disable a user's SSH public key as part of a key rotation // work flow. // -// The SSH public key affected by this action is used only for authenticating +// The SSH public key affected by this operation is used only for authenticating // the associated IAM user to an AWS CodeCommit repository. For more information // about using SSH keys to authenticate to an AWS CodeCommit repository, see // Set up AWS CodeCommit for SSH Connections (http://docs.aws.amazon.com/codecommit/latest/userguide/setting-up-credentials-ssh.html) @@ -12579,7 +12698,7 @@ const opUpdateServerCertificate = "UpdateServerCertificate" // UpdateServerCertificateRequest generates a "aws/request.Request" representing the // client's request for the UpdateServerCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12624,22 +12743,23 @@ func (c *IAM) UpdateServerCertificateRequest(input *UpdateServerCertificateInput // Updates the name and/or the path of the specified server certificate stored // in IAM. // -// For more information about working with server certificates, including a -// list of AWS services that can use the server certificates that you manage -// with IAM, go to Working with Server Certificates (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_server-certs.html) -// in the IAM User Guide. +// For more information about working with server certificates, see Working +// with Server Certificates (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_server-certs.html) +// in the IAM User Guide. This topic also includes a list of AWS services that +// can use the server certificates that you manage with IAM. // // You should understand the implications of changing a server certificate's // path or name. For more information, see Renaming a Server Certificate (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_server-certs_manage.html#RenamingServerCerts) // in the IAM User Guide. // -// To change a server certificate name the requester must have appropriate permissions -// on both the source object and the target object. For example, to change the -// name from "ProductionCert" to "ProdCert", the entity making the request must -// have permission on "ProductionCert" and "ProdCert", or must have permission -// on all (*). For more information about permissions, see Access Management -// (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) in the IAM -// User Guide. +// The person making the request (the principal), must have permission to change +// the server certificate with the old name and the new name. For example, to +// change the certificate named ProductionCert to ProdCert, the principal must +// have a policy that allows them to update both certificates. If the principal +// has permission to update the ProductionCert group, but not the ProdCert certificate, +// then the update fails. For more information about permissions, see Access +// Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -12691,7 +12811,7 @@ const opUpdateServiceSpecificCredential = "UpdateServiceSpecificCredential" // UpdateServiceSpecificCredentialRequest generates a "aws/request.Request" representing the // client's request for the UpdateServiceSpecificCredential operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12735,8 +12855,8 @@ func (c *IAM) UpdateServiceSpecificCredentialRequest(input *UpdateServiceSpecifi // // Sets the status of a service-specific credential to Active or Inactive. Service-specific // credentials that are inactive cannot be used for authentication to the service. -// This action can be used to disable a user’s service-specific credential as -// part of a credential rotation work flow. +// This operation can be used to disable a user’s service-specific credential +// as part of a credential rotation work flow. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -12776,7 +12896,7 @@ const opUpdateSigningCertificate = "UpdateSigningCertificate" // UpdateSigningCertificateRequest generates a "aws/request.Request" representing the // client's request for the UpdateSigningCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12819,13 +12939,14 @@ func (c *IAM) UpdateSigningCertificateRequest(input *UpdateSigningCertificateInp // UpdateSigningCertificate API operation for AWS Identity and Access Management. // // Changes the status of the specified user signing certificate from active -// to disabled, or vice versa. This action can be used to disable an IAM user's -// signing certificate as part of a certificate rotation work flow. +// to disabled, or vice versa. This operation can be used to disable an IAM +// user's signing certificate as part of a certificate rotation work flow. // -// If the UserName field is not specified, the UserName is determined implicitly -// based on the AWS access key ID used to sign the request. Because this action -// works for access keys under the AWS account, you can use this action to manage -// root credentials even if the AWS account has no associated users. +// If the UserName field is not specified, the user name is determined implicitly +// based on the AWS access key ID used to sign the request. Because this operation +// works for access keys under the AWS account, you can use this operation to +// manage AWS account root user credentials even if the AWS account has no associated +// users. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -12873,7 +12994,7 @@ const opUpdateUser = "UpdateUser" // UpdateUserRequest generates a "aws/request.Request" representing the // client's request for the UpdateUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12922,7 +13043,7 @@ func (c *IAM) UpdateUserRequest(input *UpdateUserInput) (req *request.Request, o // and Renaming an IAM Group (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_groups_manage_rename.html) // in the IAM User Guide. // -// To change a user name the requester must have appropriate permissions on +// To change a user name, the requester must have appropriate permissions on // both the source object and the target object. For example, to change Bob // to Robert, the entity making the request must have permission on Bob and // Robert, or must have permission on all (*). For more information about permissions, @@ -12984,7 +13105,7 @@ const opUploadSSHPublicKey = "UploadSSHPublicKey" // UploadSSHPublicKeyRequest generates a "aws/request.Request" representing the // client's request for the UploadSSHPublicKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -13026,7 +13147,7 @@ func (c *IAM) UploadSSHPublicKeyRequest(input *UploadSSHPublicKeyInput) (req *re // // Uploads an SSH public key and associates it with the specified IAM user. // -// The SSH public key uploaded by this action can be used only for authenticating +// The SSH public key uploaded by this operation can be used only for authenticating // the associated IAM user to an AWS CodeCommit repository. For more information // about using SSH keys to authenticate to an AWS CodeCommit repository, see // Set up AWS CodeCommit for SSH Connections (http://docs.aws.amazon.com/codecommit/latest/userguide/setting-up-credentials-ssh.html) @@ -13086,7 +13207,7 @@ const opUploadServerCertificate = "UploadServerCertificate" // UploadServerCertificateRequest generates a "aws/request.Request" representing the // client's request for the UploadServerCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -13136,10 +13257,10 @@ func (c *IAM) UploadServerCertificateRequest(input *UploadServerCertificateInput // renewals for you. Certificates provided by ACM are free. For more information // about using ACM, see the AWS Certificate Manager User Guide (http://docs.aws.amazon.com/acm/latest/userguide/). // -// For more information about working with server certificates, including a -// list of AWS services that can use the server certificates that you manage -// with IAM, go to Working with Server Certificates (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_server-certs.html) -// in the IAM User Guide. +// For more information about working with server certificates, see Working +// with Server Certificates (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_server-certs.html) +// in the IAM User Guide. This topic includes a list of AWS services that can +// use the server certificates that you manage with IAM. // // For information about the number of server certificates you can upload, see // Limitations on IAM Entities and Objects (http://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html) @@ -13207,7 +13328,7 @@ const opUploadSigningCertificate = "UploadSigningCertificate" // UploadSigningCertificateRequest generates a "aws/request.Request" representing the // client's request for the UploadSigningCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -13253,11 +13374,12 @@ func (c *IAM) UploadSigningCertificateRequest(input *UploadSigningCertificateInp // its default status is Active. // // If the UserName field is not specified, the IAM user name is determined implicitly -// based on the AWS access key ID used to sign the request. Because this action -// works for access keys under the AWS account, you can use this action to manage -// root credentials even if the AWS account has no associated users. +// based on the AWS access key ID used to sign the request. Because this operation +// works for access keys under the AWS account, you can use this operation to +// manage AWS account root user credentials even if the AWS account has no associated +// users. // -// Because the body of a X.509 certificate can be large, you should use POST +// Because the body of an X.509 certificate can be large, you should use POST // rather than GET when calling UploadSigningCertificate. For information about // setting up signatures and authorization through the API, go to Signing AWS // API Requests (http://docs.aws.amazon.com/general/latest/gr/signing_aws_api_requests.html) @@ -13325,7 +13447,7 @@ func (c *IAM) UploadSigningCertificateWithContext(ctx aws.Context, input *Upload // Contains information about an AWS access key. // // This data type is used as a response element in the CreateAccessKey and ListAccessKeys -// actions. +// operations. // // The SecretAccessKey value is returned only in response to CreateAccessKey. // You can get a secret access key only when you first create an access key; @@ -13347,8 +13469,8 @@ type AccessKey struct { // SecretAccessKey is a required field SecretAccessKey *string `type:"string" required:"true"` - // The status of the access key. Active means the key is valid for API calls, - // while Inactive means it is not. + // The status of the access key. Active means that the key is valid for API + // calls, while Inactive means it is not. // // Status is a required field Status *string `type:"string" required:"true" enum:"statusType"` @@ -13402,12 +13524,13 @@ func (s *AccessKey) SetUserName(v string) *AccessKey { // Contains information about the last time an AWS access key was used. // // This data type is used as a response element in the GetAccessKeyLastUsed -// action. +// operation. type AccessKeyLastUsed struct { _ struct{} `type:"structure"` // The date and time, in ISO 8601 date-time format (http://www.iso.org/iso/iso8601), - // when the access key was most recently used. This field is null when: + // when the access key was most recently used. This field is null in the following + // situations: // // * The user does not have an access key. // @@ -13420,7 +13543,7 @@ type AccessKeyLastUsed struct { LastUsedDate *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"` // The AWS region where this access key was most recently used. This field is - // displays "N/A" when: + // displays "N/A" in the following situations: // // * The user does not have an access key. // @@ -13436,7 +13559,7 @@ type AccessKeyLastUsed struct { Region *string `type:"string" required:"true"` // The name of the AWS service with which this access key was most recently - // used. This field displays "N/A" when: + // used. This field displays "N/A" in the following situations: // // * The user does not have an access key. // @@ -13479,7 +13602,7 @@ func (s *AccessKeyLastUsed) SetServiceName(v string) *AccessKeyLastUsed { // Contains information about an AWS access key, without its secret key. // -// This data type is used as a response element in the ListAccessKeys action. +// This data type is used as a response element in the ListAccessKeys operation. type AccessKeyMetadata struct { _ struct{} `type:"structure"` @@ -13542,7 +13665,7 @@ type AddClientIDToOpenIDConnectProviderInput struct { // The Amazon Resource Name (ARN) of the IAM OpenID Connect (OIDC) provider // resource to add the client ID to. You can get a list of OIDC provider ARNs - // by using the ListOpenIDConnectProviders action. + // by using the ListOpenIDConnectProviders operation. // // OpenIDConnectProviderArn is a required field OpenIDConnectProviderArn *string `min:"20" type:"string" required:"true"` @@ -13613,7 +13736,7 @@ type AddRoleToInstanceProfileInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // InstanceProfileName is a required field InstanceProfileName *string `min:"1" type:"string" required:"true"` @@ -13693,7 +13816,7 @@ type AddUserToGroupInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // GroupName is a required field GroupName *string `min:"1" type:"string" required:"true"` @@ -13702,7 +13825,7 @@ type AddUserToGroupInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -13773,7 +13896,7 @@ type AttachGroupPolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // GroupName is a required field GroupName *string `min:"1" type:"string" required:"true"` @@ -13942,7 +14065,7 @@ type AttachUserPolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -14011,7 +14134,7 @@ func (s AttachUserPolicyOutput) GoString() string { // An attached policy is a managed policy that has been attached to a user, // group, or role. This data type is used as a response element in the ListAttachedGroupPolicies, // ListAttachedRolePolicies, ListAttachedUserPolicies, and GetAccountAuthorizationDetails -// actions. +// operations. // // For more information about managed policies, refer to Managed Policies and // Inline Policies (http://docs.aws.amazon.com/IAM/latest/UserGuide/policies-managed-vs-inline.html) @@ -14058,14 +14181,14 @@ type ChangePasswordInput struct { // The new password. The new password must conform to the AWS account's password // policy, if one exists. // - // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of almost any printable ASCII - // character from the space (\u0020) through the end of the ASCII character - // range (\u00FF). You can also include the tab (\u0009), line feed (\u000A), - // and carriage return (\u000D) characters. Although any of these characters - // are valid in a password, note that many tools, such as the AWS Management - // Console, might restrict the ability to enter certain characters because they - // have special meaning within that tool. + // The regex pattern (http://wikipedia.org/wiki/regex) that is used to validate + // this parameter is a string of characters. That string can include almost + // any printable ASCII character from the space (\u0020) through the end of + // the ASCII character range (\u00FF). You can also include the tab (\u0009), + // line feed (\u000A), and carriage return (\u000D) characters. Any of these + // characters are valid in a password. However, many tools, such as the AWS + // Management Console, might restrict the ability to type certain characters + // because they have special meaning within that tool. // // NewPassword is a required field NewPassword *string `min:"1" type:"string" required:"true"` @@ -14153,8 +14276,8 @@ type ContextEntry struct { ContextKeyType *string `type:"string" enum:"ContextKeyTypeEnum"` // The value (or values, if the condition context key supports multiple values) - // to provide to the simulation for use when the key is referenced by a Condition - // element in an input policy. + // to provide to the simulation when the key is referenced by a Condition element + // in an input policy. ContextKeyValues []*string `type:"list"` } @@ -14206,7 +14329,7 @@ type CreateAccessKeyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- UserName *string `min:"1" type:"string"` } @@ -14332,7 +14455,7 @@ type CreateGroupInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@-. + // with no spaces. You can also include any of the following characters: _+=,.@-. // The group name must be unique within the account. Group names are not distinguished // by case. For example, you cannot create groups named both "ADMINS" and "admins". // @@ -14346,11 +14469,12 @@ type CreateGroupInput struct { // This parameter is optional. If it is not included, it defaults to a slash // (/). // - // This paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. Path *string `min:"1" type:"string"` } @@ -14428,7 +14552,7 @@ type CreateInstanceProfileInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // InstanceProfileName is a required field InstanceProfileName *string `min:"1" type:"string" required:"true"` @@ -14440,11 +14564,12 @@ type CreateInstanceProfileInput struct { // This parameter is optional. If it is not included, it defaults to a slash // (/). // - // This paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. Path *string `min:"1" type:"string"` } @@ -14520,14 +14645,14 @@ type CreateLoginProfileInput struct { // The new password for the user. // - // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of almost any printable ASCII - // character from the space (\u0020) through the end of the ASCII character - // range (\u00FF). You can also include the tab (\u0009), line feed (\u000A), - // and carriage return (\u000D) characters. Although any of these characters - // are valid in a password, note that many tools, such as the AWS Management - // Console, might restrict the ability to enter certain characters because they - // have special meaning within that tool. + // The regex pattern (http://wikipedia.org/wiki/regex) that is used to validate + // this parameter is a string of characters. That string can include almost + // any printable ASCII character from the space (\u0020) through the end of + // the ASCII character range (\u00FF). You can also include the tab (\u0009), + // line feed (\u000A), and carriage return (\u000D) characters. Any of these + // characters are valid in a password. However, many tools, such as the AWS + // Management Console, might restrict the ability to type certain characters + // because they have special meaning within that tool. // // Password is a required field Password *string `min:"1" type:"string" required:"true"` @@ -14540,7 +14665,7 @@ type CreateLoginProfileInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -14635,11 +14760,11 @@ type CreateOpenIDConnectProviderInput struct { // cannot register more than 100 client IDs with a single IAM OIDC provider. // // There is no defined format for a client ID. The CreateOpenIDConnectProviderRequest - // action accepts client IDs up to 255 characters long. + // operation accepts client IDs up to 255 characters long. ClientIDList []*string `type:"list"` // A list of server certificate thumbprints for the OpenID Connect (OIDC) identity - // provider's server certificate(s). Typically this list includes only one entry. + // provider's server certificates. Typically this list includes only one entry. // However, IAM lets you have up to five thumbprints for an OIDC provider. This // lets you maintain multiple thumbprints if the identity provider is rotating // certificates. @@ -14649,10 +14774,10 @@ type CreateOpenIDConnectProviderInput struct { // makes its keys available. It is always a 40-character string. // // You must provide at least one thumbprint when creating an IAM OIDC provider. - // For example, if the OIDC provider is server.example.com and the provider - // stores its keys at "https://keys.server.example.com/openid-connect", the - // thumbprint string would be the hex-encoded SHA-1 hash value of the certificate - // used by https://keys.server.example.com. + // For example, assume that the OIDC provider is server.example.com and the + // provider stores its keys at https://keys.server.example.com/openid-connect. + // In that case, the thumbprint string would be the hex-encoded SHA-1 hash value + // of the certificate used by https://keys.server.example.com. // // For more information about obtaining the OIDC provider's thumbprint, see // Obtaining the Thumbprint for an OpenID Connect Provider (http://docs.aws.amazon.com/IAM/latest/UserGuide/identity-providers-oidc-obtain-thumbprint.html) @@ -14661,11 +14786,11 @@ type CreateOpenIDConnectProviderInput struct { // ThumbprintList is a required field ThumbprintList []*string `type:"list" required:"true"` - // The URL of the identity provider. The URL must begin with "https://" and - // should correspond to the iss claim in the provider's OpenID Connect ID tokens. - // Per the OIDC standard, path components are allowed but query parameters are - // not. Typically the URL consists of only a host name, like "https://server.example.org" - // or "https://example.com". + // The URL of the identity provider. The URL must begin with https:// and should + // correspond to the iss claim in the provider's OpenID Connect ID tokens. Per + // the OIDC standard, path components are allowed but query parameters are not. + // Typically the URL consists of only a hostname, like https://server.example.org + // or https://example.com. // // You cannot register the same provider multiple times in a single AWS account. // If you try to submit a URL that has already been used for an OpenID Connect @@ -14767,22 +14892,28 @@ type CreatePolicyInput struct { // This parameter is optional. If it is not included, it defaults to a slash // (/). // - // This paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. Path *string `type:"string"` // The JSON policy document that you want to use as the content for the new // policy. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) // // PolicyDocument is a required field PolicyDocument *string `min:"1" type:"string" required:"true"` @@ -14791,7 +14922,7 @@ type CreatePolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@-+ + // with no spaces. You can also include any of the following characters: _+=,.@- // // PolicyName is a required field PolicyName *string `min:"1" type:"string" required:"true"` @@ -14894,11 +15025,16 @@ type CreatePolicyVersionInput struct { // version of the policy. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) // // PolicyDocument is a required field PolicyDocument *string `min:"1" type:"string" required:"true"` @@ -14906,8 +15042,8 @@ type CreatePolicyVersionInput struct { // Specifies whether to set this version as the policy's default version. // // When this parameter is true, the new policy version becomes the operative - // version; that is, the version that is in effect for the IAM users, groups, - // and roles that the policy is attached to. + // version. That is, it becomes the version that is in effect for the IAM users, + // groups, and roles that the policy is attached to. // // For more information about managed policy versions, see Versioning for Managed // Policies (http://docs.aws.amazon.com/IAM/latest/UserGuide/policies-managed-versions.html) @@ -14996,18 +15132,39 @@ type CreateRoleInput struct { // assume the role. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) // // AssumeRolePolicyDocument is a required field AssumeRolePolicyDocument *string `min:"1" type:"string" required:"true"` - // A customer-provided description of the role. + // A description of the role. Description *string `type:"string"` + // The maximum session duration (in seconds) that you want to set for the specified + // role. If you do not specify a value for this setting, the default maximum + // of one hour is applied. This setting can have a value from 1 hour to 12 hours. + // + // Anyone who assumes the role from the AWS CLI or API can use the DurationSeconds + // API parameter or the duration-seconds CLI parameter to request a longer session. + // The MaxSessionDuration setting determines the maximum duration that can be + // requested using the DurationSeconds parameter. If users don't specify a value + // for the DurationSeconds parameter, their security credentials are valid for + // one hour by default. This applies when you use the AssumeRole* API operations + // or the assume-role* CLI operations but does not apply when you use those + // operations to create a console URL. For more information, see Using IAM Roles + // (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html) in the + // IAM User Guide. + MaxSessionDuration *int64 `min:"3600" type:"integer"` + // The path to the role. For more information about paths, see IAM Identifiers // (http://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html) // in the IAM User Guide. @@ -15015,11 +15172,12 @@ type CreateRoleInput struct { // This parameter is optional. If it is not included, it defaults to a slash // (/). // - // This paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. Path *string `min:"1" type:"string"` // The name of the role to create. @@ -15054,6 +15212,9 @@ func (s *CreateRoleInput) Validate() error { if s.AssumeRolePolicyDocument != nil && len(*s.AssumeRolePolicyDocument) < 1 { invalidParams.Add(request.NewErrParamMinLen("AssumeRolePolicyDocument", 1)) } + if s.MaxSessionDuration != nil && *s.MaxSessionDuration < 3600 { + invalidParams.Add(request.NewErrParamMinValue("MaxSessionDuration", 3600)) + } if s.Path != nil && len(*s.Path) < 1 { invalidParams.Add(request.NewErrParamMinLen("Path", 1)) } @@ -15082,6 +15243,12 @@ func (s *CreateRoleInput) SetDescription(v string) *CreateRoleInput { return s } +// SetMaxSessionDuration sets the MaxSessionDuration field's value. +func (s *CreateRoleInput) SetMaxSessionDuration(v int64) *CreateRoleInput { + s.MaxSessionDuration = &v + return s +} + // SetPath sets the Path field's value. func (s *CreateRoleInput) SetPath(v string) *CreateRoleInput { s.Path = &v @@ -15127,7 +15294,7 @@ type CreateSAMLProviderInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // Name is a required field Name *string `min:"1" type:"string" required:"true"` @@ -15319,7 +15486,7 @@ type CreateServiceSpecificCredentialInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -15404,18 +15571,19 @@ type CreateUserInput struct { // This parameter is optional. If it is not included, it defaults to a slash // (/). // - // This paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. Path *string `min:"1" type:"string"` // The name of the user to create. // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@-. + // with no spaces. You can also include any of the following characters: _+=,.@-. // User names are not distinguished by case. For example, you cannot create // users named both "TESTUSER" and "testuser". // @@ -15498,11 +15666,12 @@ type CreateVirtualMFADeviceInput struct { // This parameter is optional. If it is not included, it defaults to a slash // (/). // - // This paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. Path *string `min:"1" type:"string"` // The name of the virtual MFA device. Use with path to uniquely identify a @@ -15510,7 +15679,7 @@ type CreateVirtualMFADeviceInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // VirtualMFADeviceName is a required field VirtualMFADeviceName *string `min:"1" type:"string" required:"true"` @@ -15600,7 +15769,7 @@ type DeactivateMFADeviceInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -15681,7 +15850,7 @@ type DeleteAccessKeyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- UserName *string `min:"1" type:"string"` } @@ -15835,7 +16004,7 @@ type DeleteGroupInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // GroupName is a required field GroupName *string `min:"1" type:"string" required:"true"` @@ -15895,7 +16064,7 @@ type DeleteGroupPolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // GroupName is a required field GroupName *string `min:"1" type:"string" required:"true"` @@ -15904,7 +16073,7 @@ type DeleteGroupPolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@-+ + // with no spaces. You can also include any of the following characters: _+=,.@- // // PolicyName is a required field PolicyName *string `min:"1" type:"string" required:"true"` @@ -15975,7 +16144,7 @@ type DeleteInstanceProfileInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // InstanceProfileName is a required field InstanceProfileName *string `min:"1" type:"string" required:"true"` @@ -16034,7 +16203,7 @@ type DeleteLoginProfileInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -16091,7 +16260,7 @@ type DeleteOpenIDConnectProviderInput struct { // The Amazon Resource Name (ARN) of the IAM OpenID Connect provider resource // object to delete. You can get a list of OpenID Connect provider resource - // ARNs by using the ListOpenIDConnectProviders action. + // ARNs by using the ListOpenIDConnectProviders operation. // // OpenIDConnectProviderArn is a required field OpenIDConnectProviderArn *string `min:"20" type:"string" required:"true"` @@ -16351,7 +16520,7 @@ type DeleteRolePolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@-+ + // with no spaces. You can also include any of the following characters: _+=,.@- // // PolicyName is a required field PolicyName *string `min:"1" type:"string" required:"true"` @@ -16496,7 +16665,7 @@ type DeleteSSHPublicKeyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -16567,7 +16736,7 @@ type DeleteServerCertificateInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // ServerCertificateName is a required field ServerCertificateName *string `min:"1" type:"string" required:"true"` @@ -16705,7 +16874,7 @@ type DeleteServiceSpecificCredentialInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- UserName *string `min:"1" type:"string"` } @@ -16780,7 +16949,7 @@ type DeleteSigningCertificateInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- UserName *string `min:"1" type:"string"` } @@ -16846,7 +17015,7 @@ type DeleteUserInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -16905,7 +17074,7 @@ type DeleteUserPolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@-+ + // with no spaces. You can also include any of the following characters: _+=,.@- // // PolicyName is a required field PolicyName *string `min:"1" type:"string" required:"true"` @@ -16915,7 +17084,7 @@ type DeleteUserPolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -17050,11 +17219,11 @@ type DeletionTaskFailureReasonType struct { Reason *string `type:"string"` // A list of objects that contains details about the service-linked role deletion - // failure. If the service-linked role has active sessions or if any resources - // that were used by the role have not been deleted from the linked service, - // the role can't be deleted. This parameter includes a list of the resources - // that are associated with the role and the region in which the resources are - // being used. + // failure, if that information is returned by the service. If the service-linked + // role has active sessions or if any resources that were used by the role have + // not been deleted from the linked service, the role can't be deleted. This + // parameter includes a list of the resources that are associated with the role + // and the region in which the resources are being used. RoleUsageList []*RoleUsageType `type:"list"` } @@ -17087,7 +17256,7 @@ type DetachGroupPolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // GroupName is a required field GroupName *string `min:"1" type:"string" required:"true"` @@ -17256,7 +17425,7 @@ type DetachUserPolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -17325,7 +17494,7 @@ type EnableMFADeviceInput struct { // An authentication code emitted by the device. // - // The format for this parameter is a string of 6 digits. + // The format for this parameter is a string of six digits. // // Submit your request immediately after generating the authentication codes. // If you generate the codes and then wait too long to submit the request, the @@ -17339,7 +17508,7 @@ type EnableMFADeviceInput struct { // A subsequent authentication code emitted by the device. // - // The format for this parameter is a string of 6 digits. + // The format for this parameter is a string of six digits. // // Submit your request immediately after generating the authentication codes. // If you generate the codes and then wait too long to submit the request, the @@ -17365,7 +17534,7 @@ type EnableMFADeviceInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -17460,7 +17629,7 @@ func (s EnableMFADeviceOutput) GoString() string { type EvaluationResult struct { _ struct{} `type:"structure"` - // The name of the API action tested on the indicated resource. + // The name of the API operation tested on the indicated resource. // // EvalActionName is a required field EvalActionName *string `min:"3" type:"string" required:"true"` @@ -17478,12 +17647,12 @@ type EvaluationResult struct { // Policies (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_compare-resource-policies.html) EvalDecisionDetails map[string]*string `type:"map"` - // The ARN of the resource that the indicated API action was tested on. + // The ARN of the resource that the indicated API operation was tested on. EvalResourceName *string `min:"1" type:"string"` // A list of the statements in the input policies that determine the result - // for this scenario. Remember that even if multiple statements allow the action - // on the resource, if only one statement denies that action, then the explicit + // for this scenario. Remember that even if multiple statements allow the operation + // on the resource, if only one statement denies that operation, then the explicit // deny overrides any allow, and the deny statement is the only entry included // in the result. MatchedStatements []*Statement `type:"list"` @@ -17502,8 +17671,8 @@ type EvaluationResult struct { // account is part of an organization. OrganizationsDecisionDetail *OrganizationsDecisionDetail `type:"structure"` - // The individual results of the simulation of the API action specified in EvalActionName - // on each resource. + // The individual results of the simulation of the API operation specified in + // EvalActionName on each resource. ResourceSpecificResults []*ResourceSpecificResult `type:"list"` } @@ -17928,11 +18097,16 @@ type GetContextKeysForCustomPolicyInput struct { // complete, valid JSON text of an IAM policy. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) // // PolicyInputList is a required field PolicyInputList []*string `type:"list" required:"true"` @@ -17999,20 +18173,26 @@ type GetContextKeysForPrincipalPolicyInput struct { // keys that are referenced. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) PolicyInputList []*string `type:"list"` // The ARN of a user, group, or role whose policies contain the context keys // that you want listed. If you specify a user, the list includes context keys - // that are found in all policies attached to the user as well as to all groups - // that the user is a member of. If you pick a group or a role, then it includes - // only those context keys that are found in policies attached to that entity. - // Note that all parameters are shown in unencoded form here for clarity, but - // must be URL encoded to be included as a part of a real HTML request. + // that are found in all policies that are attached to the user. The list also + // includes all groups that the user is a member of. If you pick a group or + // a role, then it includes only those context keys that are found in policies + // attached to that entity. Note that all parameters are shown in unencoded + // form here for clarity, but must be URL encoded to be included as a part of + // a real HTML request. // // For more information about ARNs, see Amazon Resource Names (ARNs) and AWS // Service Namespaces (http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html) @@ -18126,7 +18306,7 @@ type GetGroupInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // GroupName is a required field GroupName *string `min:"1" type:"string" required:"true"` @@ -18267,7 +18447,7 @@ type GetGroupPolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // GroupName is a required field GroupName *string `min:"1" type:"string" required:"true"` @@ -18276,7 +18456,7 @@ type GetGroupPolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@-+ + // with no spaces. You can also include any of the following characters: _+=,.@- // // PolicyName is a required field PolicyName *string `min:"1" type:"string" required:"true"` @@ -18381,7 +18561,7 @@ type GetInstanceProfileInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // InstanceProfileName is a required field InstanceProfileName *string `min:"1" type:"string" required:"true"` @@ -18452,7 +18632,7 @@ type GetLoginProfileInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -18521,7 +18701,7 @@ type GetOpenIDConnectProviderInput struct { // The Amazon Resource Name (ARN) of the OIDC provider resource object in IAM // to get information for. You can get a list of OIDC provider resource ARNs - // by using the ListOpenIDConnectProviders action. + // by using the ListOpenIDConnectProviders operation. // // For more information about ARNs, see Amazon Resource Names (ARNs) and AWS // Service Namespaces (http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html) @@ -18855,7 +19035,7 @@ type GetRolePolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@-+ + // with no spaces. You can also include any of the following characters: _+=,.@- // // PolicyName is a required field PolicyName *string `min:"1" type:"string" required:"true"` @@ -19073,7 +19253,7 @@ type GetSSHPublicKeyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -19163,7 +19343,7 @@ type GetServerCertificateInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // ServerCertificateName is a required field ServerCertificateName *string `min:"1" type:"string" required:"true"` @@ -19311,7 +19491,7 @@ type GetUserInput struct { // This parameter is optional. If it is not included, it defaults to the user // making the request. This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- UserName *string `min:"1" type:"string"` } @@ -19377,7 +19557,7 @@ type GetUserPolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@-+ + // with no spaces. You can also include any of the following characters: _+=,.@- // // PolicyName is a required field PolicyName *string `min:"1" type:"string" required:"true"` @@ -19386,7 +19566,7 @@ type GetUserPolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -19486,7 +19666,7 @@ func (s *GetUserPolicyOutput) SetUserName(v string) *GetUserPolicyOutput { // Contains information about an IAM group entity. // -// This data type is used as a response element in the following actions: +// This data type is used as a response element in the following operations: // // * CreateGroup // @@ -19572,7 +19752,7 @@ func (s *Group) SetPath(v string) *Group { // Contains information about an IAM group, including all of the group's policies. // // This data type is used as a response element in the GetAccountAuthorizationDetails -// action. +// operation. type GroupDetail struct { _ struct{} `type:"structure"` @@ -19661,7 +19841,7 @@ func (s *GroupDetail) SetPath(v string) *GroupDetail { // Contains information about an instance profile. // -// This data type is used as a response element in the following actions: +// This data type is used as a response element in the following operations: // // * CreateInstanceProfile // @@ -19781,7 +19961,7 @@ type ListAccessKeysInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- UserName *string `min:"1" type:"string"` } @@ -20000,7 +20180,7 @@ type ListAttachedGroupPoliciesInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // GroupName is a required field GroupName *string `min:"1" type:"string" required:"true"` @@ -20025,11 +20205,12 @@ type ListAttachedGroupPoliciesInput struct { // The path prefix for filtering the results. This parameter is optional. If // it is not included, it defaults to a slash (/), listing all policies. // - // This paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. PathPrefix *string `type:"string"` } @@ -20160,11 +20341,12 @@ type ListAttachedRolePoliciesInput struct { // The path prefix for filtering the results. This parameter is optional. If // it is not included, it defaults to a slash (/), listing all policies. // - // This paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. PathPrefix *string `type:"string"` // The name (friendly name, not ARN) of the role to list attached policies for. @@ -20304,18 +20486,19 @@ type ListAttachedUserPoliciesInput struct { // The path prefix for filtering the results. This parameter is optional. If // it is not included, it defaults to a slash (/), listing all policies. // - // This paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. PathPrefix *string `type:"string"` // The name (friendly name, not ARN) of the user to list attached policies for. // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -20456,11 +20639,12 @@ type ListEntitiesForPolicyInput struct { // The path prefix for filtering the results. This parameter is optional. If // it is not included, it defaults to a slash (/), listing all entities. // - // This paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. PathPrefix *string `min:"1" type:"string"` // The Amazon Resource Name (ARN) of the IAM policy for which you want the versions. @@ -20611,7 +20795,7 @@ type ListGroupPoliciesInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // GroupName is a required field GroupName *string `min:"1" type:"string" required:"true"` @@ -20704,7 +20888,7 @@ type ListGroupPoliciesOutput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@-+ + // with no spaces. You can also include any of the following characters: _+=,.@- // // PolicyNames is a required field PolicyNames []*string `type:"list" required:"true"` @@ -20762,7 +20946,7 @@ type ListGroupsForUserInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -20892,11 +21076,12 @@ type ListGroupsInput struct { // gets all groups whose path starts with /division_abc/subdivision_xyz/. // // This parameter is optional. If it is not included, it defaults to a slash - // (/), listing all groups. This paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // (/), listing all groups. This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. PathPrefix *string `min:"1" type:"string"` } @@ -21151,12 +21336,12 @@ type ListInstanceProfilesInput struct { // gets all instance profiles whose path starts with /application_abc/component_xyz/. // // This parameter is optional. If it is not included, it defaults to a slash - // (/), listing all instance profiles. This paramater allows (per its regex + // (/), listing all instance profiles. This parameter allows (per its regex // pattern (http://wikipedia.org/wiki/regex)) a string of characters consisting // of either a forward slash (/) by itself or a string that must begin and end - // with forward slashes, containing any ASCII character from the ! (\u0021) - // thru the DEL character (\u007F), including most punctuation characters, digits, - // and upper and lowercased letters. + // with forward slashes. In addition, it can contain any ASCII character from + // the ! (\u0021) through the DEL character (\u007F), including most punctuation + // characters, digits, and upper and lowercased letters. PathPrefix *string `min:"1" type:"string"` } @@ -21281,7 +21466,7 @@ type ListMFADevicesInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- UserName *string `min:"1" type:"string"` } @@ -21449,11 +21634,12 @@ type ListPoliciesInput struct { // The path prefix for filtering the results. This parameter is optional. If // it is not included, it defaults to a slash (/), listing all policies. This - // paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. PathPrefix *string `type:"string"` // The scope to use for filtering the results. @@ -21856,11 +22042,12 @@ type ListRolesInput struct { // gets all roles whose path starts with /application_abc/component_xyz/. // // This parameter is optional. If it is not included, it defaults to a slash - // (/), listing all roles. This paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // (/), listing all roles. This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. PathPrefix *string `min:"1" type:"string"` } @@ -22025,7 +22212,7 @@ type ListSSHPublicKeysInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- UserName *string `min:"1" type:"string"` } @@ -22148,12 +22335,12 @@ type ListServerCertificatesInput struct { // would get all server certificates for which the path starts with /company/servercerts. // // This parameter is optional. If it is not included, it defaults to a slash - // (/), listing all server certificates. This paramater allows (per its regex + // (/), listing all server certificates. This parameter allows (per its regex // pattern (http://wikipedia.org/wiki/regex)) a string of characters consisting // of either a forward slash (/) by itself or a string that must begin and end - // with forward slashes, containing any ASCII character from the ! (\u0021) - // thru the DEL character (\u007F), including most punctuation characters, digits, - // and upper and lowercased letters. + // with forward slashes. In addition, it can contain any ASCII character from + // the ! (\u0021) through the DEL character (\u007F), including most punctuation + // characters, digits, and upper and lowercased letters. PathPrefix *string `min:"1" type:"string"` } @@ -22262,12 +22449,12 @@ type ListServiceSpecificCredentialsInput struct { ServiceName *string `type:"string"` // The name of the user whose service-specific credentials you want information - // about. If this value is not specified then the operation assumes the user + // about. If this value is not specified, then the operation assumes the user // whose credentials are used to call the operation. // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- UserName *string `min:"1" type:"string"` } @@ -22353,7 +22540,7 @@ type ListSigningCertificatesInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- UserName *string `min:"1" type:"string"` } @@ -22478,7 +22665,7 @@ type ListUserPoliciesInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -22608,12 +22795,12 @@ type ListUsersInput struct { // which would get all user names whose path starts with /division_abc/subdivision_xyz/. // // This parameter is optional. If it is not included, it defaults to a slash - // (/), listing all user names. This paramater allows (per its regex pattern + // (/), listing all user names. This parameter allows (per its regex pattern // (http://wikipedia.org/wiki/regex)) a string of characters consisting of either // a forward slash (/) by itself or a string that must begin and end with forward - // slashes, containing any ASCII character from the ! (\u0021) thru the DEL - // character (\u007F), including most punctuation characters, digits, and upper - // and lowercased letters. + // slashes. In addition, it can contain any ASCII character from the ! (\u0021) + // through the DEL character (\u007F), including most punctuation characters, + // digits, and upper and lowercased letters. PathPrefix *string `min:"1" type:"string"` } @@ -22718,7 +22905,7 @@ type ListVirtualMFADevicesInput struct { _ struct{} `type:"structure"` // The status (Unassigned or Assigned) of the devices to list. If you do not - // specify an AssignmentStatus, the action defaults to Any which lists both + // specify an AssignmentStatus, the operation defaults to Any which lists both // assigned and unassigned virtual MFA devices. AssignmentStatus *string `type:"string" enum:"assignmentStatusType"` @@ -22838,7 +23025,7 @@ func (s *ListVirtualMFADevicesOutput) SetVirtualMFADevices(v []*VirtualMFADevice // Contains the user name and password create date for a user. // // This data type is used as a response element in the CreateLoginProfile and -// GetLoginProfile actions. +// GetLoginProfile operations. type LoginProfile struct { _ struct{} `type:"structure"` @@ -22887,7 +23074,7 @@ func (s *LoginProfile) SetUserName(v string) *LoginProfile { // Contains information about an MFA device. // -// This data type is used as a response element in the ListMFADevices action. +// This data type is used as a response element in the ListMFADevices operation. type MFADevice struct { _ struct{} `type:"structure"` @@ -22941,7 +23128,7 @@ func (s *MFADevice) SetUserName(v string) *MFADevice { // that the policy is attached to. // // This data type is used as a response element in the GetAccountAuthorizationDetails -// action. +// operation. // // For more information about managed policies, see Managed Policies and Inline // Policies (http://docs.aws.amazon.com/IAM/latest/UserGuide/policies-managed-vs-inline.html) @@ -23110,11 +23297,11 @@ func (s *OpenIDConnectProviderListEntry) SetArn(v string) *OpenIDConnectProvider return s } -// Contains information about AWS Organizations's affect on a policy simulation. +// Contains information about AWS Organizations's effect on a policy simulation. type OrganizationsDecisionDetail struct { _ struct{} `type:"structure"` - // Specifies whether the simulated action is allowed by the AWS Organizations + // Specifies whether the simulated operation is allowed by the AWS Organizations // service control policies that impact the simulated user's account. AllowedByOrganizations *bool `type:"boolean"` } @@ -23138,7 +23325,7 @@ func (s *OrganizationsDecisionDetail) SetAllowedByOrganizations(v bool) *Organiz // Contains information about the account password policy. // // This data type is used as a response element in the GetAccountPasswordPolicy -// action. +// operation. type PasswordPolicy struct { _ struct{} `type:"structure"` @@ -23146,8 +23333,8 @@ type PasswordPolicy struct { AllowUsersToChangePassword *bool `type:"boolean"` // Indicates whether passwords in the account expire. Returns true if MaxPasswordAge - // is contains a value greater than 0. Returns false if MaxPasswordAge is 0 - // or not present. + // contains a value greater than 0. Returns false if MaxPasswordAge is 0 or + // not present. ExpirePasswords *bool `type:"boolean"` // Specifies whether IAM users are prevented from setting a new password after @@ -23250,7 +23437,7 @@ func (s *PasswordPolicy) SetRequireUppercaseCharacters(v bool) *PasswordPolicy { // Contains information about a managed policy. // // This data type is used as a response element in the CreatePolicy, GetPolicy, -// and ListPolicies actions. +// and ListPolicies operations. // // For more information about managed policies, refer to Managed Policies and // Inline Policies (http://docs.aws.amazon.com/IAM/latest/UserGuide/policies-managed-vs-inline.html) @@ -23383,7 +23570,7 @@ func (s *Policy) SetUpdateDate(v time.Time) *Policy { // Contains information about an IAM policy, including the policy document. // // This data type is used as a response element in the GetAccountAuthorizationDetails -// action. +// operation. type PolicyDetail struct { _ struct{} `type:"structure"` @@ -23419,7 +23606,7 @@ func (s *PolicyDetail) SetPolicyName(v string) *PolicyDetail { // Contains information about a group that a managed policy is attached to. // // This data type is used as a response element in the ListEntitiesForPolicy -// action. +// operation. // // For more information about managed policies, refer to Managed Policies and // Inline Policies (http://docs.aws.amazon.com/IAM/latest/UserGuide/policies-managed-vs-inline.html) @@ -23461,7 +23648,7 @@ func (s *PolicyGroup) SetGroupName(v string) *PolicyGroup { // Contains information about a role that a managed policy is attached to. // // This data type is used as a response element in the ListEntitiesForPolicy -// action. +// operation. // // For more information about managed policies, refer to Managed Policies and // Inline Policies (http://docs.aws.amazon.com/IAM/latest/UserGuide/policies-managed-vs-inline.html) @@ -23503,7 +23690,7 @@ func (s *PolicyRole) SetRoleName(v string) *PolicyRole { // Contains information about a user that a managed policy is attached to. // // This data type is used as a response element in the ListEntitiesForPolicy -// action. +// operation. // // For more information about managed policies, refer to Managed Policies and // Inline Policies (http://docs.aws.amazon.com/IAM/latest/UserGuide/policies-managed-vs-inline.html) @@ -23546,7 +23733,7 @@ func (s *PolicyUser) SetUserName(v string) *PolicyUser { // // This data type is used as a response element in the CreatePolicyVersion, // GetPolicyVersion, ListPolicyVersions, and GetAccountAuthorizationDetails -// actions. +// operations. // // For more information about managed policies, refer to Managed Policies and // Inline Policies (http://docs.aws.amazon.com/IAM/latest/UserGuide/policies-managed-vs-inline.html) @@ -23563,6 +23750,12 @@ type PolicyVersion struct { // The policy document is returned in the response to the GetPolicyVersion and // GetAccountAuthorizationDetails operations. It is not returned in the response // to the CreatePolicyVersion or ListPolicyVersions operations. + // + // The policy document returned in this structure is URL-encoded compliant with + // RFC 3986 (https://tools.ietf.org/html/rfc3986). You can use a URL decoding + // method to convert the policy back to plain JSON text. For example, if you + // use Java, you can use the decode method of the java.net.URLDecoder utility + // class in the Java SDK. Other languages and SDKs provide similar functionality. Document *string `min:"1" type:"string"` // Specifies whether the policy version is set as the policy's default version. @@ -23652,7 +23845,7 @@ type PutGroupPolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // GroupName is a required field GroupName *string `min:"1" type:"string" required:"true"` @@ -23660,11 +23853,16 @@ type PutGroupPolicyInput struct { // The policy document. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) // // PolicyDocument is a required field PolicyDocument *string `min:"1" type:"string" required:"true"` @@ -23673,7 +23871,7 @@ type PutGroupPolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@-+ + // with no spaces. You can also include any of the following characters: _+=,.@- // // PolicyName is a required field PolicyName *string `min:"1" type:"string" required:"true"` @@ -23755,11 +23953,16 @@ type PutRolePolicyInput struct { // The policy document. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) // // PolicyDocument is a required field PolicyDocument *string `min:"1" type:"string" required:"true"` @@ -23768,7 +23971,7 @@ type PutRolePolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@-+ + // with no spaces. You can also include any of the following characters: _+=,.@- // // PolicyName is a required field PolicyName *string `min:"1" type:"string" required:"true"` @@ -23859,11 +24062,16 @@ type PutUserPolicyInput struct { // The policy document. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) // // PolicyDocument is a required field PolicyDocument *string `min:"1" type:"string" required:"true"` @@ -23872,7 +24080,7 @@ type PutUserPolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@-+ + // with no spaces. You can also include any of the following characters: _+=,.@- // // PolicyName is a required field PolicyName *string `min:"1" type:"string" required:"true"` @@ -23881,7 +24089,7 @@ type PutUserPolicyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -23968,7 +24176,7 @@ type RemoveClientIDFromOpenIDConnectProviderInput struct { // The Amazon Resource Name (ARN) of the IAM OIDC provider resource to remove // the client ID from. You can get a list of OIDC provider ARNs by using the - // ListOpenIDConnectProviders action. + // ListOpenIDConnectProviders operation. // // For more information about ARNs, see Amazon Resource Names (ARNs) and AWS // Service Namespaces (http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html) @@ -24043,7 +24251,7 @@ type RemoveRoleFromInstanceProfileInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // InstanceProfileName is a required field InstanceProfileName *string `min:"1" type:"string" required:"true"` @@ -24123,7 +24331,7 @@ type RemoveUserFromGroupInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // GroupName is a required field GroupName *string `min:"1" type:"string" required:"true"` @@ -24132,7 +24340,7 @@ type RemoveUserFromGroupInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -24214,7 +24422,7 @@ type ResetServiceSpecificCredentialInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- UserName *string `min:"1" type:"string"` } @@ -24286,8 +24494,8 @@ func (s *ResetServiceSpecificCredentialOutput) SetServiceSpecificCredential(v *S return s } -// Contains the result of the simulation of a single API action call on a single -// resource. +// Contains the result of the simulation of a single API operation call on a +// single resource. // // This data type is used by a member of the EvaluationResult data type. type ResourceSpecificResult struct { @@ -24300,7 +24508,7 @@ type ResourceSpecificResult struct { // caller's IAM policy must grant access. EvalDecisionDetails map[string]*string `type:"map"` - // The result of the simulation of the simulated API action on the resource + // The result of the simulation of the simulated API operation on the resource // specified in EvalResourceName. // // EvalResourceDecision is a required field @@ -24313,9 +24521,9 @@ type ResourceSpecificResult struct { // A list of the statements in the input policies that determine the result // for this part of the simulation. Remember that even if multiple statements - // allow the action on the resource, if any statement denies that action, then - // the explicit deny overrides any allow, and the deny statement is the only - // entry included in the result. + // allow the operation on the resource, if any statement denies that operation, + // then the explicit deny overrides any allow, and the deny statement is the + // only entry included in the result. MatchedStatements []*Statement `type:"list"` // A list of context keys that are required by the included input policies but @@ -24390,7 +24598,7 @@ type ResyncMFADeviceInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // SerialNumber is a required field SerialNumber *string `min:"9" type:"string" required:"true"` @@ -24399,7 +24607,7 @@ type ResyncMFADeviceInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -24488,7 +24696,7 @@ func (s ResyncMFADeviceOutput) GoString() string { } // Contains information about an IAM role. This structure is returned as a response -// element in several APIs that interact with roles. +// element in several API operations that interact with roles. type Role struct { _ struct{} `type:"structure"` @@ -24511,6 +24719,11 @@ type Role struct { // A description of the role that you provide. Description *string `type:"string"` + // The maximum session duration (in seconds) for the specified role. Anyone + // who uses the AWS CLI or API to assume the role can specify the duration using + // the optional DurationSeconds API parameter or duration-seconds CLI parameter. + MaxSessionDuration *int64 `min:"3600" type:"integer"` + // The path to the role. For more information about paths, see IAM Identifiers // (http://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html) // in the Using IAM guide. @@ -24565,6 +24778,12 @@ func (s *Role) SetDescription(v string) *Role { return s } +// SetMaxSessionDuration sets the MaxSessionDuration field's value. +func (s *Role) SetMaxSessionDuration(v int64) *Role { + s.MaxSessionDuration = &v + return s +} + // SetPath sets the Path field's value. func (s *Role) SetPath(v string) *Role { s.Path = &v @@ -24586,7 +24805,7 @@ func (s *Role) SetRoleName(v string) *Role { // Contains information about an IAM role, including all of the role's policies. // // This data type is used as a response element in the GetAccountAuthorizationDetails -// action. +// operation. type RoleDetail struct { _ struct{} `type:"structure"` @@ -24693,7 +24912,8 @@ func (s *RoleDetail) SetRolePolicyList(v []*PolicyDetail) *RoleDetail { return s } -// An object that contains details about how a service-linked role is used. +// An object that contains details about how a service-linked role is used, +// if that information is returned by the service. // // This data type is used as a response element in the GetServiceLinkedRoleDeletionStatus // operation. @@ -24774,7 +24994,7 @@ func (s *SAMLProviderListEntry) SetValidUntil(v time.Time) *SAMLProviderListEntr // Contains information about an SSH public key. // // This data type is used as a response element in the GetSSHPublicKey and UploadSSHPublicKey -// actions. +// operations. type SSHPublicKey struct { _ struct{} `type:"structure"` @@ -24793,8 +25013,9 @@ type SSHPublicKey struct { // SSHPublicKeyId is a required field SSHPublicKeyId *string `min:"20" type:"string" required:"true"` - // The status of the SSH public key. Active means the key can be used for authentication - // with an AWS CodeCommit repository. Inactive means the key cannot be used. + // The status of the SSH public key. Active means that the key can be used for + // authentication with an AWS CodeCommit repository. Inactive means that the + // key cannot be used. // // Status is a required field Status *string `type:"string" required:"true" enum:"statusType"` @@ -24857,7 +25078,7 @@ func (s *SSHPublicKey) SetUserName(v string) *SSHPublicKey { // Contains information about an SSH public key, without the key's body or fingerprint. // -// This data type is used as a response element in the ListSSHPublicKeys action. +// This data type is used as a response element in the ListSSHPublicKeys operation. type SSHPublicKeyMetadata struct { _ struct{} `type:"structure"` @@ -24866,8 +25087,9 @@ type SSHPublicKeyMetadata struct { // SSHPublicKeyId is a required field SSHPublicKeyId *string `min:"20" type:"string" required:"true"` - // The status of the SSH public key. Active means the key can be used for authentication - // with an AWS CodeCommit repository. Inactive means the key cannot be used. + // The status of the SSH public key. Active means that the key can be used for + // authentication with an AWS CodeCommit repository. Inactive means that the + // key cannot be used. // // Status is a required field Status *string `type:"string" required:"true" enum:"statusType"` @@ -24921,7 +25143,7 @@ func (s *SSHPublicKeyMetadata) SetUserName(v string) *SSHPublicKeyMetadata { // Contains information about a server certificate. // // This data type is used as a response element in the GetServerCertificate -// action. +// operation. type ServerCertificate struct { _ struct{} `type:"structure"` @@ -24972,7 +25194,7 @@ func (s *ServerCertificate) SetServerCertificateMetadata(v *ServerCertificateMet // certificate chain, and private key. // // This data type is used as a response element in the UploadServerCertificate -// and ListServerCertificates actions. +// and ListServerCertificates operations. type ServerCertificateMetadata struct { _ struct{} `type:"structure"` @@ -25056,7 +25278,7 @@ func (s *ServerCertificateMetadata) SetUploadDate(v time.Time) *ServerCertificat return s } -// Contains the details of a service specific credential. +// Contains the details of a service-specific credential. type ServiceSpecificCredential struct { _ struct{} `type:"structure"` @@ -25089,8 +25311,8 @@ type ServiceSpecificCredential struct { // ServiceUserName is a required field ServiceUserName *string `min:"17" type:"string" required:"true"` - // The status of the service-specific credential. Active means the key is valid - // for API calls, while Inactive means it is not. + // The status of the service-specific credential. Active means that the key + // is valid for API calls, while Inactive means it is not. // // Status is a required field Status *string `type:"string" required:"true" enum:"statusType"` @@ -25178,8 +25400,8 @@ type ServiceSpecificCredentialMetadata struct { // ServiceUserName is a required field ServiceUserName *string `min:"17" type:"string" required:"true"` - // The status of the service-specific credential. Active means the key is valid - // for API calls, while Inactive means it is not. + // The status of the service-specific credential. Active means that the key + // is valid for API calls, while Inactive means it is not. // // Status is a required field Status *string `type:"string" required:"true" enum:"statusType"` @@ -25317,7 +25539,7 @@ func (s SetDefaultPolicyVersionOutput) GoString() string { // Contains information about an X.509 signing certificate. // // This data type is used as a response element in the UploadSigningCertificate -// and ListSigningCertificates actions. +// and ListSigningCertificates operations. type SigningCertificate struct { _ struct{} `type:"structure"` @@ -25331,8 +25553,8 @@ type SigningCertificate struct { // CertificateId is a required field CertificateId *string `min:"24" type:"string" required:"true"` - // The status of the signing certificate. Active means the key is valid for - // API calls, while Inactive means it is not. + // The status of the signing certificate. Active means that the key is valid + // for API calls, while Inactive means it is not. // // Status is a required field Status *string `type:"string" required:"true" enum:"statusType"` @@ -25389,16 +25611,17 @@ func (s *SigningCertificate) SetUserName(v string) *SigningCertificate { type SimulateCustomPolicyInput struct { _ struct{} `type:"structure"` - // A list of names of API actions to evaluate in the simulation. Each action - // is evaluated against each resource. Each action must include the service + // A list of names of API operations to evaluate in the simulation. Each operation + // is evaluated against each resource. Each operation must include the service // identifier, such as iam:CreateUser. // // ActionNames is a required field ActionNames []*string `type:"list" required:"true"` // The ARN of the IAM user that you want to use as the simulated caller of the - // APIs. CallerArn is required if you include a ResourcePolicy so that the policy's - // Principal element has a value to use in evaluating the policy. + // API operations. CallerArn is required if you include a ResourcePolicy so + // that the policy's Principal element has a value to use in evaluating the + // policy. // // You can specify only the ARN of an IAM user. You cannot specify the ARN of // an assumed role, federated user, or a service principal. @@ -25433,14 +25656,20 @@ type SimulateCustomPolicyInput struct { // The policies cannot be "scope-down" policies, such as you could include in // a call to GetFederationToken (http://docs.aws.amazon.com/IAM/latest/APIReference/API_GetFederationToken.html) // or one of the AssumeRole (http://docs.aws.amazon.com/IAM/latest/APIReference/API_AssumeRole.html) - // APIs to restrict what a user can do while using the temporary credentials. + // API operations. In other words, do not use policies designed to restrict + // what a user can do while using the temporary credentials. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) // // PolicyInputList is a required field PolicyInputList []*string `type:"list" required:"true"` @@ -25463,13 +25692,13 @@ type SimulateCustomPolicyInput struct { // in the AWS General Reference. ResourceArns []*string `type:"list"` - // Specifies the type of simulation to run. Different APIs that support resource-based - // policies require different combinations of resources. By specifying the type - // of simulation to run, you enable the policy simulator to enforce the presence - // of the required resources to ensure reliable simulation results. If your - // simulation does not match one of the following scenarios, then you can omit - // this parameter. The following list shows each of the supported scenario values - // and the resources that you must define to run the simulation. + // Specifies the type of simulation to run. Different API operations that support + // resource-based policies require different combinations of resources. By specifying + // the type of simulation to run, you enable the policy simulator to enforce + // the presence of the required resources to ensure reliable simulation results. + // If your simulation does not match one of the following scenarios, then you + // can omit this parameter. The following list shows each of the supported scenario + // values and the resources that you must define to run the simulation. // // Each of the EC2 scenarios requires that you specify instance, image, and // security-group resources. If your scenario includes an EBS volume, then you @@ -25477,7 +25706,7 @@ type SimulateCustomPolicyInput struct { // then you must supply the network-interface resource. If it includes an IP // subnet, then you must specify the subnet resource. For more information on // the EC2 scenario options, see Supported Platforms (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-supported-platforms.html) - // in the AWS EC2 User Guide. + // in the Amazon EC2 User Guide. // // * EC2-Classic-InstanceStore // @@ -25520,11 +25749,16 @@ type SimulateCustomPolicyInput struct { // You can include only one resource-based policy in a simulation. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) ResourcePolicy *string `min:"1" type:"string"` } @@ -25694,19 +25928,20 @@ func (s *SimulatePolicyResponse) SetMarker(v string) *SimulatePolicyResponse { type SimulatePrincipalPolicyInput struct { _ struct{} `type:"structure"` - // A list of names of API actions to evaluate in the simulation. Each action - // is evaluated for each resource. Each action must include the service identifier, + // A list of names of API operations to evaluate in the simulation. Each operation + // is evaluated for each resource. Each operation must include the service identifier, // such as iam:CreateUser. // // ActionNames is a required field ActionNames []*string `type:"list" required:"true"` // The ARN of the IAM user that you want to specify as the simulated caller - // of the APIs. If you do not specify a CallerArn, it defaults to the ARN of - // the user that you specify in PolicySourceArn, if you specified a user. If - // you include both a PolicySourceArn (for example, arn:aws:iam::123456789012:user/David) + // of the API operations. If you do not specify a CallerArn, it defaults to + // the ARN of the user that you specify in PolicySourceArn, if you specified + // a user. If you include both a PolicySourceArn (for example, arn:aws:iam::123456789012:user/David) // and a CallerArn (for example, arn:aws:iam::123456789012:user/Bob), the result - // is that you simulate calling the APIs as Bob, as if Bob had David's policies. + // is that you simulate calling the API operations as Bob, as if Bob had David's + // policies. // // You can specify only the ARN of an IAM user. You cannot specify the ARN of // an assumed role, federated user, or a service principal. @@ -25747,11 +25982,16 @@ type SimulatePrincipalPolicyInput struct { // text of an IAM policy. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) PolicyInputList []*string `type:"list"` // The Amazon Resource Name (ARN) of a user, group, or role whose policies you @@ -25768,7 +26008,7 @@ type SimulatePrincipalPolicyInput struct { PolicySourceArn *string `min:"20" type:"string" required:"true"` // A list of ARNs of AWS resources to include in the simulation. If this parameter - // is not provided then the value defaults to * (all resources). Each API in + // is not provided, then the value defaults to * (all resources). Each API in // the ActionNames parameter is evaluated for each resource in this list. The // simulation determines the access result (allowed or denied) of each combination // and reports it in the response. @@ -25782,13 +26022,13 @@ type SimulatePrincipalPolicyInput struct { // in the AWS General Reference. ResourceArns []*string `type:"list"` - // Specifies the type of simulation to run. Different APIs that support resource-based - // policies require different combinations of resources. By specifying the type - // of simulation to run, you enable the policy simulator to enforce the presence - // of the required resources to ensure reliable simulation results. If your - // simulation does not match one of the following scenarios, then you can omit - // this parameter. The following list shows each of the supported scenario values - // and the resources that you must define to run the simulation. + // Specifies the type of simulation to run. Different API operations that support + // resource-based policies require different combinations of resources. By specifying + // the type of simulation to run, you enable the policy simulator to enforce + // the presence of the required resources to ensure reliable simulation results. + // If your simulation does not match one of the following scenarios, then you + // can omit this parameter. The following list shows each of the supported scenario + // values and the resources that you must define to run the simulation. // // Each of the EC2 scenarios requires that you specify instance, image, and // security-group resources. If your scenario includes an EBS volume, then you @@ -25796,7 +26036,7 @@ type SimulatePrincipalPolicyInput struct { // then you must supply the network-interface resource. If it includes an IP // subnet, then you must specify the subnet resource. For more information on // the EC2 scenario options, see Supported Platforms (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-supported-platforms.html) - // in the AWS EC2 User Guide. + // in the Amazon EC2 User Guide. // // * EC2-Classic-InstanceStore // @@ -25839,11 +26079,16 @@ type SimulatePrincipalPolicyInput struct { // You can include only one resource-based policy in a simulation. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) ResourcePolicy *string `min:"1" type:"string"` } @@ -26037,9 +26282,9 @@ type UpdateAccessKeyInput struct { // AccessKeyId is a required field AccessKeyId *string `min:"16" type:"string" required:"true"` - // The status you want to assign to the secret access key. Active means the - // key can be used for API calls to AWS, while Inactive means the key cannot - // be used. + // The status you want to assign to the secret access key. Active means that + // the key can be used for API calls to AWS, while Inactive means that the key + // cannot be used. // // Status is a required field Status *string `type:"string" required:"true" enum:"statusType"` @@ -26048,7 +26293,7 @@ type UpdateAccessKeyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- UserName *string `min:"1" type:"string"` } @@ -26124,42 +26369,53 @@ type UpdateAccountPasswordPolicyInput struct { // Their Own Passwords (http://docs.aws.amazon.com/IAM/latest/UserGuide/HowToPwdIAMUser.html) // in the IAM User Guide. // - // Default value: false + // If you do not specify a value for this parameter, then the operation uses + // the default value of false. The result is that IAM users in the account do + // not automatically have permissions to change their own password. AllowUsersToChangePassword *bool `type:"boolean"` // Prevents IAM users from setting a new password after their password has expired. + // The IAM user cannot be accessed until an administrator resets the password. // - // Default value: false + // If you do not specify a value for this parameter, then the operation uses + // the default value of false. The result is that IAM users can change their + // passwords after they expire and continue to sign in as the user. HardExpiry *bool `type:"boolean"` - // The number of days that an IAM user password is valid. The default value - // of 0 means IAM user passwords never expire. + // The number of days that an IAM user password is valid. // - // Default value: 0 + // If you do not specify a value for this parameter, then the operation uses + // the default value of 0. The result is that IAM user passwords never expire. MaxPasswordAge *int64 `min:"1" type:"integer"` // The minimum number of characters allowed in an IAM user password. // - // Default value: 6 + // If you do not specify a value for this parameter, then the operation uses + // the default value of 6. MinimumPasswordLength *int64 `min:"6" type:"integer"` // Specifies the number of previous passwords that IAM users are prevented from - // reusing. The default value of 0 means IAM users are not prevented from reusing - // previous passwords. + // reusing. // - // Default value: 0 + // If you do not specify a value for this parameter, then the operation uses + // the default value of 0. The result is that IAM users are not prevented from + // reusing previous passwords. PasswordReusePrevention *int64 `min:"1" type:"integer"` // Specifies whether IAM user passwords must contain at least one lowercase // character from the ISO basic Latin alphabet (a to z). // - // Default value: false + // If you do not specify a value for this parameter, then the operation uses + // the default value of false. The result is that passwords do not require at + // least one lowercase character. RequireLowercaseCharacters *bool `type:"boolean"` // Specifies whether IAM user passwords must contain at least one numeric character // (0 to 9). // - // Default value: false + // If you do not specify a value for this parameter, then the operation uses + // the default value of false. The result is that passwords do not require at + // least one numeric character. RequireNumbers *bool `type:"boolean"` // Specifies whether IAM user passwords must contain at least one of the following @@ -26167,13 +26423,17 @@ type UpdateAccountPasswordPolicyInput struct { // // ! @ # $ % ^ & * ( ) _ + - = [ ] { } | ' // - // Default value: false + // If you do not specify a value for this parameter, then the operation uses + // the default value of false. The result is that passwords do not require at + // least one symbol character. RequireSymbols *bool `type:"boolean"` // Specifies whether IAM user passwords must contain at least one uppercase // character from the ISO basic Latin alphabet (A to Z). // - // Default value: false + // If you do not specify a value for this parameter, then the operation uses + // the default value of false. The result is that passwords do not require at + // least one uppercase character. RequireUppercaseCharacters *bool `type:"boolean"` } @@ -26280,11 +26540,16 @@ type UpdateAssumeRolePolicyInput struct { // The policy that grants an entity permission to assume the role. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) // // PolicyDocument is a required field PolicyDocument *string `min:"1" type:"string" required:"true"` @@ -26365,7 +26630,7 @@ type UpdateGroupInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // GroupName is a required field GroupName *string `min:"1" type:"string" required:"true"` @@ -26374,16 +26639,17 @@ type UpdateGroupInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- NewGroupName *string `min:"1" type:"string"` // New path for the IAM group. Only include this if changing the group's path. // - // This paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. NewPath *string `min:"1" type:"string"` } @@ -26457,13 +26723,20 @@ type UpdateLoginProfileInput struct { // The new password for the specified IAM user. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). However, - // the format can be further restricted by the account administrator by setting - // a password policy on the AWS account. For more information, see UpdateAccountPasswordPolicy. + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) + // + // However, the format can be further restricted by the account administrator + // by setting a password policy on the AWS account. For more information, see + // UpdateAccountPasswordPolicy. Password *string `min:"1" type:"string"` // Allows this new password to be used only once by requiring the specified @@ -26474,7 +26747,7 @@ type UpdateLoginProfileInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -26546,7 +26819,7 @@ type UpdateOpenIDConnectProviderThumbprintInput struct { // The Amazon Resource Name (ARN) of the IAM OIDC provider resource object for // which you want to update the thumbprint. You can get a list of OIDC provider - // ARNs by using the ListOpenIDConnectProviders action. + // ARNs by using the ListOpenIDConnectProviders operation. // // For more information about ARNs, see Amazon Resource Names (ARNs) and AWS // Service Namespaces (http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html) @@ -26695,6 +26968,95 @@ func (s *UpdateRoleDescriptionOutput) SetRole(v *Role) *UpdateRoleDescriptionOut return s } +type UpdateRoleInput struct { + _ struct{} `type:"structure"` + + // The new description that you want to apply to the specified role. + Description *string `type:"string"` + + // The maximum session duration (in seconds) that you want to set for the specified + // role. If you do not specify a value for this setting, the default maximum + // of one hour is applied. This setting can have a value from 1 hour to 12 hours. + // + // Anyone who assumes the role from the AWS CLI or API can use the DurationSeconds + // API parameter or the duration-seconds CLI parameter to request a longer session. + // The MaxSessionDuration setting determines the maximum duration that can be + // requested using the DurationSeconds parameter. If users don't specify a value + // for the DurationSeconds parameter, their security credentials are valid for + // one hour by default. This applies when you use the AssumeRole* API operations + // or the assume-role* CLI operations but does not apply when you use those + // operations to create a console URL. For more information, see Using IAM Roles + // (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html) in the + // IAM User Guide. + MaxSessionDuration *int64 `min:"3600" type:"integer"` + + // The name of the role that you want to modify. + // + // RoleName is a required field + RoleName *string `min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s UpdateRoleInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateRoleInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *UpdateRoleInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateRoleInput"} + if s.MaxSessionDuration != nil && *s.MaxSessionDuration < 3600 { + invalidParams.Add(request.NewErrParamMinValue("MaxSessionDuration", 3600)) + } + if s.RoleName == nil { + invalidParams.Add(request.NewErrParamRequired("RoleName")) + } + if s.RoleName != nil && len(*s.RoleName) < 1 { + invalidParams.Add(request.NewErrParamMinLen("RoleName", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDescription sets the Description field's value. +func (s *UpdateRoleInput) SetDescription(v string) *UpdateRoleInput { + s.Description = &v + return s +} + +// SetMaxSessionDuration sets the MaxSessionDuration field's value. +func (s *UpdateRoleInput) SetMaxSessionDuration(v int64) *UpdateRoleInput { + s.MaxSessionDuration = &v + return s +} + +// SetRoleName sets the RoleName field's value. +func (s *UpdateRoleInput) SetRoleName(v string) *UpdateRoleInput { + s.RoleName = &v + return s +} + +type UpdateRoleOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s UpdateRoleOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateRoleOutput) GoString() string { + return s.String() +} + type UpdateSAMLProviderInput struct { _ struct{} `type:"structure"` @@ -26797,9 +27159,9 @@ type UpdateSSHPublicKeyInput struct { // SSHPublicKeyId is a required field SSHPublicKeyId *string `min:"20" type:"string" required:"true"` - // The status to assign to the SSH public key. Active means the key can be used - // for authentication with an AWS CodeCommit repository. Inactive means the - // key cannot be used. + // The status to assign to the SSH public key. Active means that the key can + // be used for authentication with an AWS CodeCommit repository. Inactive means + // that the key cannot be used. // // Status is a required field Status *string `type:"string" required:"true" enum:"statusType"` @@ -26808,7 +27170,7 @@ type UpdateSSHPublicKeyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -26887,11 +27249,12 @@ type UpdateServerCertificateInput struct { // The new path for the server certificate. Include this only if you are updating // the server certificate's path. // - // This paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. NewPath *string `min:"1" type:"string"` // The new name for the server certificate. Include this only if you are updating @@ -26900,14 +27263,14 @@ type UpdateServerCertificateInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- NewServerCertificateName *string `min:"1" type:"string"` // The name of the server certificate that you want to update. // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // ServerCertificateName is a required field ServerCertificateName *string `min:"1" type:"string" required:"true"` @@ -27000,7 +27363,7 @@ type UpdateServiceSpecificCredentialInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- UserName *string `min:"1" type:"string"` } @@ -27080,8 +27443,8 @@ type UpdateSigningCertificateInput struct { // CertificateId is a required field CertificateId *string `min:"24" type:"string" required:"true"` - // The status you want to assign to the certificate. Active means the certificate - // can be used for API calls to AWS, while Inactive means the certificate cannot + // The status you want to assign to the certificate. Active means that the certificate + // can be used for API calls to AWS Inactive means that the certificate cannot // be used. // // Status is a required field @@ -27091,7 +27454,7 @@ type UpdateSigningCertificateInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- UserName *string `min:"1" type:"string"` } @@ -27165,11 +27528,12 @@ type UpdateUserInput struct { // New path for the IAM user. Include this parameter only if you're changing // the user's path. // - // This paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. NewPath *string `min:"1" type:"string"` // New name for the user. Include this parameter only if you're changing the @@ -27177,7 +27541,7 @@ type UpdateUserInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- NewUserName *string `min:"1" type:"string"` // Name of the user to update. If you're changing the name of the user, this @@ -27185,7 +27549,7 @@ type UpdateUserInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -27262,11 +27626,16 @@ type UploadSSHPublicKeyInput struct { // format. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) // // SSHPublicKeyBody is a required field SSHPublicKeyBody *string `min:"1" type:"string" required:"true"` @@ -27275,7 +27644,7 @@ type UploadSSHPublicKeyInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // UserName is a required field UserName *string `min:"1" type:"string" required:"true"` @@ -27355,11 +27724,16 @@ type UploadServerCertificateInput struct { // The contents of the public key certificate in PEM-encoded format. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) // // CertificateBody is a required field CertificateBody *string `min:"1" type:"string" required:"true"` @@ -27368,11 +27742,16 @@ type UploadServerCertificateInput struct { // of the PEM-encoded public key certificates of the chain. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) CertificateChain *string `min:"1" type:"string"` // The path for the server certificate. For more information about paths, see @@ -27380,14 +27759,15 @@ type UploadServerCertificateInput struct { // in the IAM User Guide. // // This parameter is optional. If it is not included, it defaults to a slash - // (/). This paramater allows (per its regex pattern (http://wikipedia.org/wiki/regex)) + // (/). This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of either a forward slash (/) by itself - // or a string that must begin and end with forward slashes, containing any - // ASCII character from the ! (\u0021) thru the DEL character (\u007F), including - // most punctuation characters, digits, and upper and lowercased letters. + // or a string that must begin and end with forward slashes. In addition, it + // can contain any ASCII character from the ! (\u0021) through the DEL character + // (\u007F), including most punctuation characters, digits, and upper and lowercased + // letters. // // If you are uploading a server certificate specifically for use with Amazon - // CloudFront distributions, you must specify a path using the --path option. + // CloudFront distributions, you must specify a path using the path parameter. // The path must begin with /cloudfront and must include a trailing slash (for // example, /cloudfront/test/). Path *string `min:"1" type:"string"` @@ -27395,11 +27775,16 @@ type UploadServerCertificateInput struct { // The contents of the private key in PEM-encoded format. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) // // PrivateKey is a required field PrivateKey *string `min:"1" type:"string" required:"true"` @@ -27409,7 +27794,7 @@ type UploadServerCertificateInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- // // ServerCertificateName is a required field ServerCertificateName *string `min:"1" type:"string" required:"true"` @@ -27520,11 +27905,16 @@ type UploadSigningCertificateInput struct { // The contents of the signing certificate. // // The regex pattern (http://wikipedia.org/wiki/regex) used to validate this - // parameter is a string of characters consisting of any printable ASCII character - // ranging from the space character (\u0020) through end of the ASCII character - // range as well as the printable characters in the Basic Latin and Latin-1 - // Supplement character set (through \u00FF). It also includes the special characters - // tab (\u0009), line feed (\u000A), and carriage return (\u000D). + // parameter is a string of characters consisting of the following: + // + // * Any printable ASCII character ranging from the space character (\u0020) + // through the end of the ASCII character range + // + // * The printable characters in the Basic Latin and Latin-1 Supplement character + // set (through \u00FF) + // + // * The special characters tab (\u0009), line feed (\u000A), and carriage + // return (\u000D) // // CertificateBody is a required field CertificateBody *string `min:"1" type:"string" required:"true"` @@ -27533,7 +27923,7 @@ type UploadSigningCertificateInput struct { // // This parameter allows (per its regex pattern (http://wikipedia.org/wiki/regex)) // a string of characters consisting of upper and lowercase alphanumeric characters - // with no spaces. You can also include any of the following characters: =,.@- + // with no spaces. You can also include any of the following characters: _+=,.@- UserName *string `min:"1" type:"string"` } @@ -27606,7 +27996,7 @@ func (s *UploadSigningCertificateOutput) SetCertificate(v *SigningCertificate) * // Contains information about an IAM user entity. // -// This data type is used as a response element in the following actions: +// This data type is used as a response element in the following operations: // // * CreateUser // @@ -27647,7 +28037,7 @@ type User struct { // does not currently have a password, but had one in the past, then this field // contains the date and time the most recent password was used. // - // This value is returned only in the GetUser and ListUsers actions. + // This value is returned only in the GetUser and ListUsers operations. PasswordLastUsed *time.Time `type:"timestamp" timestampFormat:"iso8601"` // The path to the user. For more information about paths, see IAM Identifiers @@ -27720,7 +28110,7 @@ func (s *User) SetUserName(v string) *User { // and all the IAM groups the user is in. // // This data type is used as a response element in the GetAccountAuthorizationDetails -// action. +// operation. type UserDetail struct { _ struct{} `type:"structure"` diff --git a/vendor/github.com/aws/aws-sdk-go/service/inspector/api.go b/vendor/github.com/aws/aws-sdk-go/service/inspector/api.go index 0376ef0c2649..b59beb0315a9 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/inspector/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/inspector/api.go @@ -17,7 +17,7 @@ const opAddAttributesToFindings = "AddAttributesToFindings" // AddAttributesToFindingsRequest generates a "aws/request.Request" representing the // client's request for the AddAttributesToFindings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -108,7 +108,7 @@ const opCreateAssessmentTarget = "CreateAssessmentTarget" // CreateAssessmentTargetRequest generates a "aws/request.Request" representing the // client's request for the CreateAssessmentTarget operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -208,7 +208,7 @@ const opCreateAssessmentTemplate = "CreateAssessmentTemplate" // CreateAssessmentTemplateRequest generates a "aws/request.Request" representing the // client's request for the CreateAssessmentTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -306,7 +306,7 @@ const opCreateResourceGroup = "CreateResourceGroup" // CreateResourceGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateResourceGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -399,7 +399,7 @@ const opDeleteAssessmentRun = "DeleteAssessmentRun" // DeleteAssessmentRunRequest generates a "aws/request.Request" representing the // client's request for the DeleteAssessmentRun operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -496,7 +496,7 @@ const opDeleteAssessmentTarget = "DeleteAssessmentTarget" // DeleteAssessmentTargetRequest generates a "aws/request.Request" representing the // client's request for the DeleteAssessmentTarget operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -593,7 +593,7 @@ const opDeleteAssessmentTemplate = "DeleteAssessmentTemplate" // DeleteAssessmentTemplateRequest generates a "aws/request.Request" representing the // client's request for the DeleteAssessmentTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -690,7 +690,7 @@ const opDescribeAssessmentRuns = "DescribeAssessmentRuns" // DescribeAssessmentRunsRequest generates a "aws/request.Request" representing the // client's request for the DescribeAssessmentRuns operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -774,7 +774,7 @@ const opDescribeAssessmentTargets = "DescribeAssessmentTargets" // DescribeAssessmentTargetsRequest generates a "aws/request.Request" representing the // client's request for the DescribeAssessmentTargets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -858,7 +858,7 @@ const opDescribeAssessmentTemplates = "DescribeAssessmentTemplates" // DescribeAssessmentTemplatesRequest generates a "aws/request.Request" representing the // client's request for the DescribeAssessmentTemplates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -942,7 +942,7 @@ const opDescribeCrossAccountAccessRole = "DescribeCrossAccountAccessRole" // DescribeCrossAccountAccessRoleRequest generates a "aws/request.Request" representing the // client's request for the DescribeCrossAccountAccessRole operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1021,7 +1021,7 @@ const opDescribeFindings = "DescribeFindings" // DescribeFindingsRequest generates a "aws/request.Request" representing the // client's request for the DescribeFindings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1104,7 +1104,7 @@ const opDescribeResourceGroups = "DescribeResourceGroups" // DescribeResourceGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeResourceGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1188,7 +1188,7 @@ const opDescribeRulesPackages = "DescribeRulesPackages" // DescribeRulesPackagesRequest generates a "aws/request.Request" representing the // client's request for the DescribeRulesPackages operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1272,7 +1272,7 @@ const opGetAssessmentReport = "GetAssessmentReport" // GetAssessmentReportRequest generates a "aws/request.Request" representing the // client's request for the GetAssessmentReport operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1374,7 +1374,7 @@ const opGetTelemetryMetadata = "GetTelemetryMetadata" // GetTelemetryMetadataRequest generates a "aws/request.Request" representing the // client's request for the GetTelemetryMetadata operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1465,7 +1465,7 @@ const opListAssessmentRunAgents = "ListAssessmentRunAgents" // ListAssessmentRunAgentsRequest generates a "aws/request.Request" representing the // client's request for the ListAssessmentRunAgents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1612,7 +1612,7 @@ const opListAssessmentRuns = "ListAssessmentRuns" // ListAssessmentRunsRequest generates a "aws/request.Request" representing the // client's request for the ListAssessmentRuns operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1759,7 +1759,7 @@ const opListAssessmentTargets = "ListAssessmentTargets" // ListAssessmentTargetsRequest generates a "aws/request.Request" representing the // client's request for the ListAssessmentTargets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1903,7 +1903,7 @@ const opListAssessmentTemplates = "ListAssessmentTemplates" // ListAssessmentTemplatesRequest generates a "aws/request.Request" representing the // client's request for the ListAssessmentTemplates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2050,7 +2050,7 @@ const opListEventSubscriptions = "ListEventSubscriptions" // ListEventSubscriptionsRequest generates a "aws/request.Request" representing the // client's request for the ListEventSubscriptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2198,7 +2198,7 @@ const opListFindings = "ListFindings" // ListFindingsRequest generates a "aws/request.Request" representing the // client's request for the ListFindings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2345,7 +2345,7 @@ const opListRulesPackages = "ListRulesPackages" // ListRulesPackagesRequest generates a "aws/request.Request" representing the // client's request for the ListRulesPackages operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2487,7 +2487,7 @@ const opListTagsForResource = "ListTagsForResource" // ListTagsForResourceRequest generates a "aws/request.Request" representing the // client's request for the ListTagsForResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2577,7 +2577,7 @@ const opPreviewAgents = "PreviewAgents" // PreviewAgentsRequest generates a "aws/request.Request" representing the // client's request for the PreviewAgents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2728,7 +2728,7 @@ const opRegisterCrossAccountAccessRole = "RegisterCrossAccountAccessRole" // RegisterCrossAccountAccessRoleRequest generates a "aws/request.Request" representing the // client's request for the RegisterCrossAccountAccessRole operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2821,7 +2821,7 @@ const opRemoveAttributesFromFindings = "RemoveAttributesFromFindings" // RemoveAttributesFromFindingsRequest generates a "aws/request.Request" representing the // client's request for the RemoveAttributesFromFindings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2913,7 +2913,7 @@ const opSetTagsForResource = "SetTagsForResource" // SetTagsForResourceRequest generates a "aws/request.Request" representing the // client's request for the SetTagsForResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3006,7 +3006,7 @@ const opStartAssessmentRun = "StartAssessmentRun" // StartAssessmentRunRequest generates a "aws/request.Request" representing the // client's request for the StartAssessmentRun operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3110,7 +3110,7 @@ const opStopAssessmentRun = "StopAssessmentRun" // StopAssessmentRunRequest generates a "aws/request.Request" representing the // client's request for the StopAssessmentRun operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3202,7 +3202,7 @@ const opSubscribeToEvent = "SubscribeToEvent" // SubscribeToEventRequest generates a "aws/request.Request" representing the // client's request for the SubscribeToEvent operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3299,7 +3299,7 @@ const opUnsubscribeFromEvent = "UnsubscribeFromEvent" // UnsubscribeFromEventRequest generates a "aws/request.Request" representing the // client's request for the UnsubscribeFromEvent operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3392,7 +3392,7 @@ const opUpdateAssessmentTarget = "UpdateAssessmentTarget" // UpdateAssessmentTargetRequest generates a "aws/request.Request" representing the // client's request for the UpdateAssessmentTarget operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/iot/api.go b/vendor/github.com/aws/aws-sdk-go/service/iot/api.go index e9112b4a8a14..ef322f6b90ed 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/iot/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/iot/api.go @@ -17,7 +17,7 @@ const opAcceptCertificateTransfer = "AcceptCertificateTransfer" // AcceptCertificateTransferRequest generates a "aws/request.Request" representing the // client's request for the AcceptCertificateTransfer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -118,7 +118,7 @@ const opAddThingToThingGroup = "AddThingToThingGroup" // AddThingToThingGroupRequest generates a "aws/request.Request" representing the // client's request for the AddThingToThingGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -203,7 +203,7 @@ const opAssociateTargetsWithJob = "AssociateTargetsWithJob" // AssociateTargetsWithJobRequest generates a "aws/request.Request" representing the // client's request for the AssociateTargetsWithJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -299,7 +299,7 @@ const opAttachPolicy = "AttachPolicy" // AttachPolicyRequest generates a "aws/request.Request" representing the // client's request for the AttachPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -395,7 +395,7 @@ const opAttachPrincipalPolicy = "AttachPrincipalPolicy" // AttachPrincipalPolicyRequest generates a "aws/request.Request" representing the // client's request for the AttachPrincipalPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -497,7 +497,7 @@ const opAttachThingPrincipal = "AttachThingPrincipal" // AttachThingPrincipalRequest generates a "aws/request.Request" representing the // client's request for the AttachThingPrincipal operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -588,7 +588,7 @@ const opCancelCertificateTransfer = "CancelCertificateTransfer" // CancelCertificateTransferRequest generates a "aws/request.Request" representing the // client's request for the CancelCertificateTransfer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -694,7 +694,7 @@ const opCancelJob = "CancelJob" // CancelJobRequest generates a "aws/request.Request" representing the // client's request for the CancelJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -779,7 +779,7 @@ const opClearDefaultAuthorizer = "ClearDefaultAuthorizer" // ClearDefaultAuthorizerRequest generates a "aws/request.Request" representing the // client's request for the ClearDefaultAuthorizer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -870,7 +870,7 @@ const opCreateAuthorizer = "CreateAuthorizer" // CreateAuthorizerRequest generates a "aws/request.Request" representing the // client's request for the CreateAuthorizer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -964,7 +964,7 @@ const opCreateCertificateFromCsr = "CreateCertificateFromCsr" // CreateCertificateFromCsrRequest generates a "aws/request.Request" representing the // client's request for the CreateCertificateFromCsr operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1093,7 +1093,7 @@ const opCreateJob = "CreateJob" // CreateJobRequest generates a "aws/request.Request" representing the // client's request for the CreateJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1184,7 +1184,7 @@ const opCreateKeysAndCertificate = "CreateKeysAndCertificate" // CreateKeysAndCertificateRequest generates a "aws/request.Request" representing the // client's request for the CreateKeysAndCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1276,7 +1276,7 @@ const opCreateOTAUpdate = "CreateOTAUpdate" // CreateOTAUpdateRequest generates a "aws/request.Request" representing the // client's request for the CreateOTAUpdate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1370,7 +1370,7 @@ const opCreatePolicy = "CreatePolicy" // CreatePolicyRequest generates a "aws/request.Request" representing the // client's request for the CreatePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1468,7 +1468,7 @@ const opCreatePolicyVersion = "CreatePolicyVersion" // CreatePolicyVersionRequest generates a "aws/request.Request" representing the // client's request for the CreatePolicyVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1572,7 +1572,7 @@ const opCreateRoleAlias = "CreateRoleAlias" // CreateRoleAliasRequest generates a "aws/request.Request" representing the // client's request for the CreateRoleAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1666,7 +1666,7 @@ const opCreateStream = "CreateStream" // CreateStreamRequest generates a "aws/request.Request" representing the // client's request for the CreateStream operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1766,7 +1766,7 @@ const opCreateThing = "CreateThing" // CreateThingRequest generates a "aws/request.Request" representing the // client's request for the CreateThing operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1860,7 +1860,7 @@ const opCreateThingGroup = "CreateThingGroup" // CreateThingGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateThingGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1945,7 +1945,7 @@ const opCreateThingType = "CreateThingType" // CreateThingTypeRequest generates a "aws/request.Request" representing the // client's request for the CreateThingType operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2036,7 +2036,7 @@ const opCreateTopicRule = "CreateTopicRule" // CreateTopicRuleRequest generates a "aws/request.Request" representing the // client's request for the CreateTopicRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2128,7 +2128,7 @@ const opDeleteAuthorizer = "DeleteAuthorizer" // DeleteAuthorizerRequest generates a "aws/request.Request" representing the // client's request for the DeleteAuthorizer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2222,7 +2222,7 @@ const opDeleteCACertificate = "DeleteCACertificate" // DeleteCACertificateRequest generates a "aws/request.Request" representing the // client's request for the DeleteCACertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2316,7 +2316,7 @@ const opDeleteCertificate = "DeleteCertificate" // DeleteCertificateRequest generates a "aws/request.Request" representing the // client's request for the DeleteCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2420,7 +2420,7 @@ const opDeleteOTAUpdate = "DeleteOTAUpdate" // DeleteOTAUpdateRequest generates a "aws/request.Request" representing the // client's request for the DeleteOTAUpdate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2511,7 +2511,7 @@ const opDeletePolicy = "DeletePolicy" // DeletePolicyRequest generates a "aws/request.Request" representing the // client's request for the DeletePolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2617,7 +2617,7 @@ const opDeletePolicyVersion = "DeletePolicyVersion" // DeletePolicyVersionRequest generates a "aws/request.Request" representing the // client's request for the DeletePolicyVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2716,7 +2716,7 @@ const opDeleteRegistrationCode = "DeleteRegistrationCode" // DeleteRegistrationCodeRequest generates a "aws/request.Request" representing the // client's request for the DeleteRegistrationCode operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2804,7 +2804,7 @@ const opDeleteRoleAlias = "DeleteRoleAlias" // DeleteRoleAliasRequest generates a "aws/request.Request" representing the // client's request for the DeleteRoleAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2898,7 +2898,7 @@ const opDeleteStream = "DeleteStream" // DeleteStreamRequest generates a "aws/request.Request" representing the // client's request for the DeleteStream operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2992,7 +2992,7 @@ const opDeleteThing = "DeleteThing" // DeleteThingRequest generates a "aws/request.Request" representing the // client's request for the DeleteThing operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3087,7 +3087,7 @@ const opDeleteThingGroup = "DeleteThingGroup" // DeleteThingGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteThingGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3173,7 +3173,7 @@ const opDeleteThingType = "DeleteThingType" // DeleteThingTypeRequest generates a "aws/request.Request" representing the // client's request for the DeleteThingType operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3268,7 +3268,7 @@ const opDeleteTopicRule = "DeleteTopicRule" // DeleteTopicRuleRequest generates a "aws/request.Request" representing the // client's request for the DeleteTopicRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3355,7 +3355,7 @@ const opDeleteV2LoggingLevel = "DeleteV2LoggingLevel" // DeleteV2LoggingLevelRequest generates a "aws/request.Request" representing the // client's request for the DeleteV2LoggingLevel operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3439,7 +3439,7 @@ const opDeprecateThingType = "DeprecateThingType" // DeprecateThingTypeRequest generates a "aws/request.Request" representing the // client's request for the DeprecateThingType operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3531,7 +3531,7 @@ const opDescribeAuthorizer = "DescribeAuthorizer" // DescribeAuthorizerRequest generates a "aws/request.Request" representing the // client's request for the DescribeAuthorizer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3622,7 +3622,7 @@ const opDescribeCACertificate = "DescribeCACertificate" // DescribeCACertificateRequest generates a "aws/request.Request" representing the // client's request for the DescribeCACertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3713,7 +3713,7 @@ const opDescribeCertificate = "DescribeCertificate" // DescribeCertificateRequest generates a "aws/request.Request" representing the // client's request for the DescribeCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3804,7 +3804,7 @@ const opDescribeDefaultAuthorizer = "DescribeDefaultAuthorizer" // DescribeDefaultAuthorizerRequest generates a "aws/request.Request" representing the // client's request for the DescribeDefaultAuthorizer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3895,7 +3895,7 @@ const opDescribeEndpoint = "DescribeEndpoint" // DescribeEndpointRequest generates a "aws/request.Request" representing the // client's request for the DescribeEndpoint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3980,7 +3980,7 @@ const opDescribeEventConfigurations = "DescribeEventConfigurations" // DescribeEventConfigurationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEventConfigurations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4059,7 +4059,7 @@ const opDescribeIndex = "DescribeIndex" // DescribeIndexRequest generates a "aws/request.Request" representing the // client's request for the DescribeIndex operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4150,7 +4150,7 @@ const opDescribeJob = "DescribeJob" // DescribeJobRequest generates a "aws/request.Request" representing the // client's request for the DescribeJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4235,7 +4235,7 @@ const opDescribeJobExecution = "DescribeJobExecution" // DescribeJobExecutionRequest generates a "aws/request.Request" representing the // client's request for the DescribeJobExecution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4320,7 +4320,7 @@ const opDescribeRoleAlias = "DescribeRoleAlias" // DescribeRoleAliasRequest generates a "aws/request.Request" representing the // client's request for the DescribeRoleAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4411,7 +4411,7 @@ const opDescribeStream = "DescribeStream" // DescribeStreamRequest generates a "aws/request.Request" representing the // client's request for the DescribeStream operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4502,7 +4502,7 @@ const opDescribeThing = "DescribeThing" // DescribeThingRequest generates a "aws/request.Request" representing the // client's request for the DescribeThing operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4593,7 +4593,7 @@ const opDescribeThingGroup = "DescribeThingGroup" // DescribeThingGroupRequest generates a "aws/request.Request" representing the // client's request for the DescribeThingGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4678,7 +4678,7 @@ const opDescribeThingRegistrationTask = "DescribeThingRegistrationTask" // DescribeThingRegistrationTaskRequest generates a "aws/request.Request" representing the // client's request for the DescribeThingRegistrationTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4766,7 +4766,7 @@ const opDescribeThingType = "DescribeThingType" // DescribeThingTypeRequest generates a "aws/request.Request" representing the // client's request for the DescribeThingType operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4857,7 +4857,7 @@ const opDetachPolicy = "DetachPolicy" // DetachPolicyRequest generates a "aws/request.Request" representing the // client's request for the DetachPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4950,7 +4950,7 @@ const opDetachPrincipalPolicy = "DetachPrincipalPolicy" // DetachPrincipalPolicyRequest generates a "aws/request.Request" representing the // client's request for the DetachPrincipalPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5048,7 +5048,7 @@ const opDetachThingPrincipal = "DetachThingPrincipal" // DetachThingPrincipalRequest generates a "aws/request.Request" representing the // client's request for the DetachThingPrincipal operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5139,7 +5139,7 @@ const opDisableTopicRule = "DisableTopicRule" // DisableTopicRuleRequest generates a "aws/request.Request" representing the // client's request for the DisableTopicRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5226,7 +5226,7 @@ const opEnableTopicRule = "EnableTopicRule" // EnableTopicRuleRequest generates a "aws/request.Request" representing the // client's request for the EnableTopicRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5313,7 +5313,7 @@ const opGetEffectivePolicies = "GetEffectivePolicies" // GetEffectivePoliciesRequest generates a "aws/request.Request" representing the // client's request for the GetEffectivePolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5407,7 +5407,7 @@ const opGetIndexingConfiguration = "GetIndexingConfiguration" // GetIndexingConfigurationRequest generates a "aws/request.Request" representing the // client's request for the GetIndexingConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5495,7 +5495,7 @@ const opGetJobDocument = "GetJobDocument" // GetJobDocumentRequest generates a "aws/request.Request" representing the // client's request for the GetJobDocument operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5580,7 +5580,7 @@ const opGetLoggingOptions = "GetLoggingOptions" // GetLoggingOptionsRequest generates a "aws/request.Request" representing the // client's request for the GetLoggingOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5662,7 +5662,7 @@ const opGetOTAUpdate = "GetOTAUpdate" // GetOTAUpdateRequest generates a "aws/request.Request" representing the // client's request for the GetOTAUpdate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5753,7 +5753,7 @@ const opGetPolicy = "GetPolicy" // GetPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5845,7 +5845,7 @@ const opGetPolicyVersion = "GetPolicyVersion" // GetPolicyVersionRequest generates a "aws/request.Request" representing the // client's request for the GetPolicyVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5936,7 +5936,7 @@ const opGetRegistrationCode = "GetRegistrationCode" // GetRegistrationCodeRequest generates a "aws/request.Request" representing the // client's request for the GetRegistrationCode operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6024,7 +6024,7 @@ const opGetTopicRule = "GetTopicRule" // GetTopicRuleRequest generates a "aws/request.Request" representing the // client's request for the GetTopicRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6109,7 +6109,7 @@ const opGetV2LoggingOptions = "GetV2LoggingOptions" // GetV2LoggingOptionsRequest generates a "aws/request.Request" representing the // client's request for the GetV2LoggingOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6191,7 +6191,7 @@ const opListAttachedPolicies = "ListAttachedPolicies" // ListAttachedPoliciesRequest generates a "aws/request.Request" representing the // client's request for the ListAttachedPolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6285,7 +6285,7 @@ const opListAuthorizers = "ListAuthorizers" // ListAuthorizersRequest generates a "aws/request.Request" representing the // client's request for the ListAuthorizers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6373,7 +6373,7 @@ const opListCACertificates = "ListCACertificates" // ListCACertificatesRequest generates a "aws/request.Request" representing the // client's request for the ListCACertificates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6464,7 +6464,7 @@ const opListCertificates = "ListCertificates" // ListCertificatesRequest generates a "aws/request.Request" representing the // client's request for the ListCertificates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6555,7 +6555,7 @@ const opListCertificatesByCA = "ListCertificatesByCA" // ListCertificatesByCARequest generates a "aws/request.Request" representing the // client's request for the ListCertificatesByCA operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6643,7 +6643,7 @@ const opListIndices = "ListIndices" // ListIndicesRequest generates a "aws/request.Request" representing the // client's request for the ListIndices operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6731,7 +6731,7 @@ const opListJobExecutionsForJob = "ListJobExecutionsForJob" // ListJobExecutionsForJobRequest generates a "aws/request.Request" representing the // client's request for the ListJobExecutionsForJob operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6816,7 +6816,7 @@ const opListJobExecutionsForThing = "ListJobExecutionsForThing" // ListJobExecutionsForThingRequest generates a "aws/request.Request" representing the // client's request for the ListJobExecutionsForThing operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6901,7 +6901,7 @@ const opListJobs = "ListJobs" // ListJobsRequest generates a "aws/request.Request" representing the // client's request for the ListJobs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6986,7 +6986,7 @@ const opListOTAUpdates = "ListOTAUpdates" // ListOTAUpdatesRequest generates a "aws/request.Request" representing the // client's request for the ListOTAUpdates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7074,7 +7074,7 @@ const opListOutgoingCertificates = "ListOutgoingCertificates" // ListOutgoingCertificatesRequest generates a "aws/request.Request" representing the // client's request for the ListOutgoingCertificates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7162,7 +7162,7 @@ const opListPolicies = "ListPolicies" // ListPoliciesRequest generates a "aws/request.Request" representing the // client's request for the ListPolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7250,7 +7250,7 @@ const opListPolicyPrincipals = "ListPolicyPrincipals" // ListPolicyPrincipalsRequest generates a "aws/request.Request" representing the // client's request for the ListPolicyPrincipals operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7346,7 +7346,7 @@ const opListPolicyVersions = "ListPolicyVersions" // ListPolicyVersionsRequest generates a "aws/request.Request" representing the // client's request for the ListPolicyVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7437,7 +7437,7 @@ const opListPrincipalPolicies = "ListPrincipalPolicies" // ListPrincipalPoliciesRequest generates a "aws/request.Request" representing the // client's request for the ListPrincipalPolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7534,7 +7534,7 @@ const opListPrincipalThings = "ListPrincipalThings" // ListPrincipalThingsRequest generates a "aws/request.Request" representing the // client's request for the ListPrincipalThings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7625,7 +7625,7 @@ const opListRoleAliases = "ListRoleAliases" // ListRoleAliasesRequest generates a "aws/request.Request" representing the // client's request for the ListRoleAliases operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7713,7 +7713,7 @@ const opListStreams = "ListStreams" // ListStreamsRequest generates a "aws/request.Request" representing the // client's request for the ListStreams operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7801,7 +7801,7 @@ const opListTargetsForPolicy = "ListTargetsForPolicy" // ListTargetsForPolicyRequest generates a "aws/request.Request" representing the // client's request for the ListTargetsForPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7895,7 +7895,7 @@ const opListThingGroups = "ListThingGroups" // ListThingGroupsRequest generates a "aws/request.Request" representing the // client's request for the ListThingGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7977,7 +7977,7 @@ const opListThingGroupsForThing = "ListThingGroupsForThing" // ListThingGroupsForThingRequest generates a "aws/request.Request" representing the // client's request for the ListThingGroupsForThing operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8059,7 +8059,7 @@ const opListThingPrincipals = "ListThingPrincipals" // ListThingPrincipalsRequest generates a "aws/request.Request" representing the // client's request for the ListThingPrincipals operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8150,7 +8150,7 @@ const opListThingRegistrationTaskReports = "ListThingRegistrationTaskReports" // ListThingRegistrationTaskReportsRequest generates a "aws/request.Request" representing the // client's request for the ListThingRegistrationTaskReports operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8235,7 +8235,7 @@ const opListThingRegistrationTasks = "ListThingRegistrationTasks" // ListThingRegistrationTasksRequest generates a "aws/request.Request" representing the // client's request for the ListThingRegistrationTasks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8320,7 +8320,7 @@ const opListThingTypes = "ListThingTypes" // ListThingTypesRequest generates a "aws/request.Request" representing the // client's request for the ListThingTypes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8408,7 +8408,7 @@ const opListThings = "ListThings" // ListThingsRequest generates a "aws/request.Request" representing the // client's request for the ListThings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8499,7 +8499,7 @@ const opListThingsInThingGroup = "ListThingsInThingGroup" // ListThingsInThingGroupRequest generates a "aws/request.Request" representing the // client's request for the ListThingsInThingGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8581,7 +8581,7 @@ const opListTopicRules = "ListTopicRules" // ListTopicRulesRequest generates a "aws/request.Request" representing the // client's request for the ListTopicRules operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8663,7 +8663,7 @@ const opListV2LoggingLevels = "ListV2LoggingLevels" // ListV2LoggingLevelsRequest generates a "aws/request.Request" representing the // client's request for the ListV2LoggingLevels operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8748,7 +8748,7 @@ const opRegisterCACertificate = "RegisterCACertificate" // RegisterCACertificateRequest generates a "aws/request.Request" representing the // client's request for the RegisterCACertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8854,7 +8854,7 @@ const opRegisterCertificate = "RegisterCertificate" // RegisterCertificateRequest generates a "aws/request.Request" representing the // client's request for the RegisterCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8958,7 +8958,7 @@ const opRegisterThing = "RegisterThing" // RegisterThingRequest generates a "aws/request.Request" representing the // client's request for the RegisterThing operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9053,7 +9053,7 @@ const opRejectCertificateTransfer = "RejectCertificateTransfer" // RejectCertificateTransferRequest generates a "aws/request.Request" representing the // client's request for the RejectCertificateTransfer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9158,7 +9158,7 @@ const opRemoveThingFromThingGroup = "RemoveThingFromThingGroup" // RemoveThingFromThingGroupRequest generates a "aws/request.Request" representing the // client's request for the RemoveThingFromThingGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9243,7 +9243,7 @@ const opReplaceTopicRule = "ReplaceTopicRule" // ReplaceTopicRuleRequest generates a "aws/request.Request" representing the // client's request for the ReplaceTopicRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9335,7 +9335,7 @@ const opSearchIndex = "SearchIndex" // SearchIndexRequest generates a "aws/request.Request" representing the // client's request for the SearchIndex operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9432,7 +9432,7 @@ const opSetDefaultAuthorizer = "SetDefaultAuthorizer" // SetDefaultAuthorizerRequest generates a "aws/request.Request" representing the // client's request for the SetDefaultAuthorizer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9499,6 +9499,9 @@ func (c *IoT) SetDefaultAuthorizerRequest(input *SetDefaultAuthorizerInput) (req // * ErrCodeInternalFailureException "InternalFailureException" // An unexpected error has occurred. // +// * ErrCodeResourceAlreadyExistsException "ResourceAlreadyExistsException" +// The resource already exists. +// func (c *IoT) SetDefaultAuthorizer(input *SetDefaultAuthorizerInput) (*SetDefaultAuthorizerOutput, error) { req, out := c.SetDefaultAuthorizerRequest(input) return out, req.Send() @@ -9524,7 +9527,7 @@ const opSetDefaultPolicyVersion = "SetDefaultPolicyVersion" // SetDefaultPolicyVersionRequest generates a "aws/request.Request" representing the // client's request for the SetDefaultPolicyVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9620,7 +9623,7 @@ const opSetLoggingOptions = "SetLoggingOptions" // SetLoggingOptionsRequest generates a "aws/request.Request" representing the // client's request for the SetLoggingOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9704,7 +9707,7 @@ const opSetV2LoggingLevel = "SetV2LoggingLevel" // SetV2LoggingLevelRequest generates a "aws/request.Request" representing the // client's request for the SetV2LoggingLevel operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9791,7 +9794,7 @@ const opSetV2LoggingOptions = "SetV2LoggingOptions" // SetV2LoggingOptionsRequest generates a "aws/request.Request" representing the // client's request for the SetV2LoggingOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9875,7 +9878,7 @@ const opStartThingRegistrationTask = "StartThingRegistrationTask" // StartThingRegistrationTaskRequest generates a "aws/request.Request" representing the // client's request for the StartThingRegistrationTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9960,7 +9963,7 @@ const opStopThingRegistrationTask = "StopThingRegistrationTask" // StopThingRegistrationTaskRequest generates a "aws/request.Request" representing the // client's request for the StopThingRegistrationTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10048,7 +10051,7 @@ const opTestAuthorization = "TestAuthorization" // TestAuthorizationRequest generates a "aws/request.Request" representing the // client's request for the TestAuthorization operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10142,7 +10145,7 @@ const opTestInvokeAuthorizer = "TestInvokeAuthorizer" // TestInvokeAuthorizerRequest generates a "aws/request.Request" representing the // client's request for the TestInvokeAuthorizer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10236,7 +10239,7 @@ const opTransferCertificate = "TransferCertificate" // TransferCertificateRequest generates a "aws/request.Request" representing the // client's request for the TransferCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10345,7 +10348,7 @@ const opUpdateAuthorizer = "UpdateAuthorizer" // UpdateAuthorizerRequest generates a "aws/request.Request" representing the // client's request for the UpdateAuthorizer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10439,7 +10442,7 @@ const opUpdateCACertificate = "UpdateCACertificate" // UpdateCACertificateRequest generates a "aws/request.Request" representing the // client's request for the UpdateCACertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10532,7 +10535,7 @@ const opUpdateCertificate = "UpdateCertificate" // UpdateCertificateRequest generates a "aws/request.Request" representing the // client's request for the UpdateCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10634,7 +10637,7 @@ const opUpdateEventConfigurations = "UpdateEventConfigurations" // UpdateEventConfigurationsRequest generates a "aws/request.Request" representing the // client's request for the UpdateEventConfigurations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10716,7 +10719,7 @@ const opUpdateIndexingConfiguration = "UpdateIndexingConfiguration" // UpdateIndexingConfigurationRequest generates a "aws/request.Request" representing the // client's request for the UpdateIndexingConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10804,7 +10807,7 @@ const opUpdateRoleAlias = "UpdateRoleAlias" // UpdateRoleAliasRequest generates a "aws/request.Request" representing the // client's request for the UpdateRoleAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10895,7 +10898,7 @@ const opUpdateStream = "UpdateStream" // UpdateStreamRequest generates a "aws/request.Request" representing the // client's request for the UpdateStream operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10986,7 +10989,7 @@ const opUpdateThing = "UpdateThing" // UpdateThingRequest generates a "aws/request.Request" representing the // client's request for the UpdateThing operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11081,7 +11084,7 @@ const opUpdateThingGroup = "UpdateThingGroup" // UpdateThingGroupRequest generates a "aws/request.Request" representing the // client's request for the UpdateThingGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -11170,7 +11173,7 @@ const opUpdateThingGroupsForThing = "UpdateThingGroupsForThing" // UpdateThingGroupsForThingRequest generates a "aws/request.Request" representing the // client's request for the UpdateThingGroupsForThing operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12280,6 +12283,12 @@ type CACertificateDescription struct { // The date the CA certificate was created. CreationDate *time.Time `locationName:"creationDate" type:"timestamp" timestampFormat:"unix"` + CustomerVersion *int64 `locationName:"customerVersion" min:"1" type:"integer"` + + GenerationId *string `locationName:"generationId" type:"string"` + + LastModifiedDate *time.Time `locationName:"lastModifiedDate" type:"timestamp" timestampFormat:"unix"` + // The owner of the CA certificate. OwnedBy *string `locationName:"ownedBy" type:"string"` @@ -12327,6 +12336,24 @@ func (s *CACertificateDescription) SetCreationDate(v time.Time) *CACertificateDe return s } +// SetCustomerVersion sets the CustomerVersion field's value. +func (s *CACertificateDescription) SetCustomerVersion(v int64) *CACertificateDescription { + s.CustomerVersion = &v + return s +} + +// SetGenerationId sets the GenerationId field's value. +func (s *CACertificateDescription) SetGenerationId(v string) *CACertificateDescription { + s.GenerationId = &v + return s +} + +// SetLastModifiedDate sets the LastModifiedDate field's value. +func (s *CACertificateDescription) SetLastModifiedDate(v time.Time) *CACertificateDescription { + s.LastModifiedDate = &v + return s +} + // SetOwnedBy sets the OwnedBy field's value. func (s *CACertificateDescription) SetOwnedBy(v string) *CACertificateDescription { s.OwnedBy = &v @@ -12558,6 +12585,10 @@ type CertificateDescription struct { // The date and time the certificate was created. CreationDate *time.Time `locationName:"creationDate" type:"timestamp" timestampFormat:"unix"` + CustomerVersion *int64 `locationName:"customerVersion" min:"1" type:"integer"` + + GenerationId *string `locationName:"generationId" type:"string"` + // The date and time the certificate was last modified. LastModifiedDate *time.Time `locationName:"lastModifiedDate" type:"timestamp" timestampFormat:"unix"` @@ -12614,6 +12645,18 @@ func (s *CertificateDescription) SetCreationDate(v time.Time) *CertificateDescri return s } +// SetCustomerVersion sets the CustomerVersion field's value. +func (s *CertificateDescription) SetCustomerVersion(v int64) *CertificateDescription { + s.CustomerVersion = &v + return s +} + +// SetGenerationId sets the GenerationId field's value. +func (s *CertificateDescription) SetGenerationId(v string) *CertificateDescription { + s.GenerationId = &v + return s +} + // SetLastModifiedDate sets the LastModifiedDate field's value. func (s *CertificateDescription) SetLastModifiedDate(v time.Time) *CertificateDescription { s.LastModifiedDate = &v @@ -17902,9 +17945,15 @@ func (s *GetPolicyInput) SetPolicyName(v string) *GetPolicyInput { type GetPolicyOutput struct { _ struct{} `type:"structure"` + CreationDate *time.Time `locationName:"creationDate" type:"timestamp" timestampFormat:"unix"` + // The default policy version ID. DefaultVersionId *string `locationName:"defaultVersionId" type:"string"` + GenerationId *string `locationName:"generationId" type:"string"` + + LastModifiedDate *time.Time `locationName:"lastModifiedDate" type:"timestamp" timestampFormat:"unix"` + // The policy ARN. PolicyArn *string `locationName:"policyArn" type:"string"` @@ -17925,12 +17974,30 @@ func (s GetPolicyOutput) GoString() string { return s.String() } +// SetCreationDate sets the CreationDate field's value. +func (s *GetPolicyOutput) SetCreationDate(v time.Time) *GetPolicyOutput { + s.CreationDate = &v + return s +} + // SetDefaultVersionId sets the DefaultVersionId field's value. func (s *GetPolicyOutput) SetDefaultVersionId(v string) *GetPolicyOutput { s.DefaultVersionId = &v return s } +// SetGenerationId sets the GenerationId field's value. +func (s *GetPolicyOutput) SetGenerationId(v string) *GetPolicyOutput { + s.GenerationId = &v + return s +} + +// SetLastModifiedDate sets the LastModifiedDate field's value. +func (s *GetPolicyOutput) SetLastModifiedDate(v time.Time) *GetPolicyOutput { + s.LastModifiedDate = &v + return s +} + // SetPolicyArn sets the PolicyArn field's value. func (s *GetPolicyOutput) SetPolicyArn(v string) *GetPolicyOutput { s.PolicyArn = &v @@ -18009,9 +18076,15 @@ func (s *GetPolicyVersionInput) SetPolicyVersionId(v string) *GetPolicyVersionIn type GetPolicyVersionOutput struct { _ struct{} `type:"structure"` + CreationDate *time.Time `locationName:"creationDate" type:"timestamp" timestampFormat:"unix"` + + GenerationId *string `locationName:"generationId" type:"string"` + // Specifies whether the policy version is the default. IsDefaultVersion *bool `locationName:"isDefaultVersion" type:"boolean"` + LastModifiedDate *time.Time `locationName:"lastModifiedDate" type:"timestamp" timestampFormat:"unix"` + // The policy ARN. PolicyArn *string `locationName:"policyArn" type:"string"` @@ -18035,12 +18108,30 @@ func (s GetPolicyVersionOutput) GoString() string { return s.String() } +// SetCreationDate sets the CreationDate field's value. +func (s *GetPolicyVersionOutput) SetCreationDate(v time.Time) *GetPolicyVersionOutput { + s.CreationDate = &v + return s +} + +// SetGenerationId sets the GenerationId field's value. +func (s *GetPolicyVersionOutput) SetGenerationId(v string) *GetPolicyVersionOutput { + s.GenerationId = &v + return s +} + // SetIsDefaultVersion sets the IsDefaultVersion field's value. func (s *GetPolicyVersionOutput) SetIsDefaultVersion(v bool) *GetPolicyVersionOutput { s.IsDefaultVersion = &v return s } +// SetLastModifiedDate sets the LastModifiedDate field's value. +func (s *GetPolicyVersionOutput) SetLastModifiedDate(v time.Time) *GetPolicyVersionOutput { + s.LastModifiedDate = &v + return s +} + // SetPolicyArn sets the PolicyArn field's value. func (s *GetPolicyVersionOutput) SetPolicyArn(v string) *GetPolicyVersionOutput { s.PolicyArn = &v @@ -23077,6 +23168,8 @@ type RoleAliasDescription struct { // The role alias. RoleAlias *string `locationName:"roleAlias" min:"1" type:"string"` + RoleAliasArn *string `locationName:"roleAliasArn" type:"string"` + // The role ARN. RoleArn *string `locationName:"roleArn" min:"20" type:"string"` } @@ -23121,6 +23214,12 @@ func (s *RoleAliasDescription) SetRoleAlias(v string) *RoleAliasDescription { return s } +// SetRoleAliasArn sets the RoleAliasArn field's value. +func (s *RoleAliasDescription) SetRoleAliasArn(v string) *RoleAliasDescription { + s.RoleAliasArn = &v + return s +} + // SetRoleArn sets the RoleArn field's value. func (s *RoleAliasDescription) SetRoleArn(v string) *RoleAliasDescription { s.RoleArn = &v diff --git a/vendor/github.com/aws/aws-sdk-go/service/iot/service.go b/vendor/github.com/aws/aws-sdk-go/service/iot/service.go index 530757a190c3..1f03372ac9e3 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/iot/service.go +++ b/vendor/github.com/aws/aws-sdk-go/service/iot/service.go @@ -45,14 +45,14 @@ const ( // svc := iot.New(mySession, aws.NewConfig().WithRegion("us-west-2")) func New(p client.ConfigProvider, cfgs ...*aws.Config) *IoT { c := p.ClientConfig(EndpointsID, cfgs...) + if c.SigningNameDerived || len(c.SigningName) == 0 { + c.SigningName = "execute-api" + } return newClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion, c.SigningName) } // newClient creates, initializes and returns a new service client instance. func newClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion, signingName string) *IoT { - if len(signingName) == 0 { - signingName = "execute-api" - } svc := &IoT{ Client: client.New( cfg, diff --git a/vendor/github.com/aws/aws-sdk-go/service/kinesis/api.go b/vendor/github.com/aws/aws-sdk-go/service/kinesis/api.go index 3d6e3cd1275b..b99202f131c8 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/kinesis/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/kinesis/api.go @@ -17,7 +17,7 @@ const opAddTagsToStream = "AddTagsToStream" // AddTagsToStreamRequest generates a "aws/request.Request" representing the // client's request for the AddTagsToStream operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -117,7 +117,7 @@ const opCreateStream = "CreateStream" // CreateStreamRequest generates a "aws/request.Request" representing the // client's request for the CreateStream operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -245,7 +245,7 @@ const opDecreaseStreamRetentionPeriod = "DecreaseStreamRetentionPeriod" // DecreaseStreamRetentionPeriodRequest generates a "aws/request.Request" representing the // client's request for the DecreaseStreamRetentionPeriod operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -345,7 +345,7 @@ const opDeleteStream = "DeleteStream" // DeleteStreamRequest generates a "aws/request.Request" representing the // client's request for the DeleteStream operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -450,7 +450,7 @@ const opDescribeLimits = "DescribeLimits" // DescribeLimitsRequest generates a "aws/request.Request" representing the // client's request for the DescribeLimits operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -535,7 +535,7 @@ const opDescribeStream = "DescribeStream" // DescribeStreamRequest generates a "aws/request.Request" representing the // client's request for the DescribeStream operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -693,7 +693,7 @@ const opDescribeStreamSummary = "DescribeStreamSummary" // DescribeStreamSummaryRequest generates a "aws/request.Request" representing the // client's request for the DescribeStreamSummary operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -782,7 +782,7 @@ const opDisableEnhancedMonitoring = "DisableEnhancedMonitoring" // DisableEnhancedMonitoringRequest generates a "aws/request.Request" representing the // client's request for the DisableEnhancedMonitoring operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -874,7 +874,7 @@ const opEnableEnhancedMonitoring = "EnableEnhancedMonitoring" // EnableEnhancedMonitoringRequest generates a "aws/request.Request" representing the // client's request for the EnableEnhancedMonitoring operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -966,7 +966,7 @@ const opGetRecords = "GetRecords" // GetRecordsRequest generates a "aws/request.Request" representing the // client's request for the GetRecords operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1139,7 +1139,7 @@ const opGetShardIterator = "GetShardIterator" // GetShardIteratorRequest generates a "aws/request.Request" representing the // client's request for the GetShardIterator operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1269,7 +1269,7 @@ const opIncreaseStreamRetentionPeriod = "IncreaseStreamRetentionPeriod" // IncreaseStreamRetentionPeriodRequest generates a "aws/request.Request" representing the // client's request for the IncreaseStreamRetentionPeriod operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1373,7 +1373,7 @@ const opListShards = "ListShards" // ListShardsRequest generates a "aws/request.Request" representing the // client's request for the ListShards operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1475,7 +1475,7 @@ const opListStreams = "ListStreams" // ListStreamsRequest generates a "aws/request.Request" representing the // client's request for the ListStreams operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1626,7 +1626,7 @@ const opListTagsForStream = "ListTagsForStream" // ListTagsForStreamRequest generates a "aws/request.Request" representing the // client's request for the ListTagsForStream operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1715,7 +1715,7 @@ const opMergeShards = "MergeShards" // MergeShardsRequest generates a "aws/request.Request" representing the // client's request for the MergeShards operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1844,7 +1844,7 @@ const opPutRecord = "PutRecord" // PutRecordRequest generates a "aws/request.Request" representing the // client's request for the PutRecord operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2000,7 +2000,7 @@ const opPutRecords = "PutRecords" // PutRecordsRequest generates a "aws/request.Request" representing the // client's request for the PutRecords operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2176,7 +2176,7 @@ const opRemoveTagsFromStream = "RemoveTagsFromStream" // RemoveTagsFromStreamRequest generates a "aws/request.Request" representing the // client's request for the RemoveTagsFromStream operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2275,7 +2275,7 @@ const opSplitShard = "SplitShard" // SplitShardRequest generates a "aws/request.Request" representing the // client's request for the SplitShard operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2413,7 +2413,7 @@ const opStartStreamEncryption = "StartStreamEncryption" // StartStreamEncryptionRequest generates a "aws/request.Request" representing the // client's request for the StartStreamEncryption operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2551,7 +2551,7 @@ const opStopStreamEncryption = "StopStreamEncryption" // StopStreamEncryptionRequest generates a "aws/request.Request" representing the // client's request for the StopStreamEncryption operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2662,7 +2662,7 @@ const opUpdateShardCount = "UpdateShardCount" // UpdateShardCountRequest generates a "aws/request.Request" representing the // client's request for the UpdateShardCount operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/kms/api.go b/vendor/github.com/aws/aws-sdk-go/service/kms/api.go index e67cf240d477..eae393011513 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/kms/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/kms/api.go @@ -17,7 +17,7 @@ const opCancelKeyDeletion = "CancelKeyDeletion" // CancelKeyDeletionRequest generates a "aws/request.Request" representing the // client's request for the CancelKeyDeletion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -123,7 +123,7 @@ const opCreateAlias = "CreateAlias" // CreateAliasRequest generates a "aws/request.Request" representing the // client's request for the CreateAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -255,7 +255,7 @@ const opCreateGrant = "CreateGrant" // CreateGrantRequest generates a "aws/request.Request" representing the // client's request for the CreateGrant operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -372,7 +372,7 @@ const opCreateKey = "CreateKey" // CreateKeyRequest generates a "aws/request.Request" representing the // client's request for the CreateKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -487,7 +487,7 @@ const opDecrypt = "Decrypt" // DecryptRequest generates a "aws/request.Request" representing the // client's request for the Decrypt operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -614,7 +614,7 @@ const opDeleteAlias = "DeleteAlias" // DeleteAliasRequest generates a "aws/request.Request" representing the // client's request for the DeleteAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -722,7 +722,7 @@ const opDeleteImportedKeyMaterial = "DeleteImportedKeyMaterial" // DeleteImportedKeyMaterialRequest generates a "aws/request.Request" representing the // client's request for the DeleteImportedKeyMaterial operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -837,7 +837,7 @@ const opDescribeKey = "DescribeKey" // DescribeKeyRequest generates a "aws/request.Request" representing the // client's request for the DescribeKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -931,7 +931,7 @@ const opDisableKey = "DisableKey" // DisableKeyRequest generates a "aws/request.Request" representing the // client's request for the DisableKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1038,7 +1038,7 @@ const opDisableKeyRotation = "DisableKeyRotation" // DisableKeyRotationRequest generates a "aws/request.Request" representing the // client's request for the DisableKeyRotation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1148,7 +1148,7 @@ const opEnableKey = "EnableKey" // EnableKeyRequest generates a "aws/request.Request" representing the // client's request for the EnableKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1256,7 +1256,7 @@ const opEnableKeyRotation = "EnableKeyRotation" // EnableKeyRotationRequest generates a "aws/request.Request" representing the // client's request for the EnableKeyRotation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1366,7 +1366,7 @@ const opEncrypt = "Encrypt" // EncryptRequest generates a "aws/request.Request" representing the // client's request for the Encrypt operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1497,7 +1497,7 @@ const opGenerateDataKey = "GenerateDataKey" // GenerateDataKeyRequest generates a "aws/request.Request" representing the // client's request for the GenerateDataKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1651,7 +1651,7 @@ const opGenerateDataKeyWithoutPlaintext = "GenerateDataKeyWithoutPlaintext" // GenerateDataKeyWithoutPlaintextRequest generates a "aws/request.Request" representing the // client's request for the GenerateDataKeyWithoutPlaintext operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1777,7 +1777,7 @@ const opGenerateRandom = "GenerateRandom" // GenerateRandomRequest generates a "aws/request.Request" representing the // client's request for the GenerateRandom operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1865,7 +1865,7 @@ const opGetKeyPolicy = "GetKeyPolicy" // GetKeyPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetKeyPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1965,7 +1965,7 @@ const opGetKeyRotationStatus = "GetKeyRotationStatus" // GetKeyRotationStatusRequest generates a "aws/request.Request" representing the // client's request for the GetKeyRotationStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2072,7 +2072,7 @@ const opGetParametersForImport = "GetParametersForImport" // GetParametersForImportRequest generates a "aws/request.Request" representing the // client's request for the GetParametersForImport operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2191,7 +2191,7 @@ const opImportKeyMaterial = "ImportKeyMaterial" // ImportKeyMaterialRequest generates a "aws/request.Request" representing the // client's request for the ImportKeyMaterial operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2348,7 +2348,7 @@ const opListAliases = "ListAliases" // ListAliasesRequest generates a "aws/request.Request" representing the // client's request for the ListAliases operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2499,7 +2499,7 @@ const opListGrants = "ListGrants" // ListGrantsRequest generates a "aws/request.Request" representing the // client's request for the ListGrants operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2661,7 +2661,7 @@ const opListKeyPolicies = "ListKeyPolicies" // ListKeyPoliciesRequest generates a "aws/request.Request" representing the // client's request for the ListKeyPolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2819,7 +2819,7 @@ const opListKeys = "ListKeys" // ListKeysRequest generates a "aws/request.Request" representing the // client's request for the ListKeys operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2964,7 +2964,7 @@ const opListResourceTags = "ListResourceTags" // ListResourceTagsRequest generates a "aws/request.Request" representing the // client's request for the ListResourceTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3057,7 +3057,7 @@ const opListRetirableGrants = "ListRetirableGrants" // ListRetirableGrantsRequest generates a "aws/request.Request" representing the // client's request for the ListRetirableGrants operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3156,7 +3156,7 @@ const opPutKeyPolicy = "PutKeyPolicy" // PutKeyPolicyRequest generates a "aws/request.Request" representing the // client's request for the PutKeyPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3274,7 +3274,7 @@ const opReEncrypt = "ReEncrypt" // ReEncryptRequest generates a "aws/request.Request" representing the // client's request for the ReEncrypt operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3401,7 +3401,7 @@ const opRetireGrant = "RetireGrant" // RetireGrantRequest generates a "aws/request.Request" representing the // client's request for the RetireGrant operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3523,7 +3523,7 @@ const opRevokeGrant = "RevokeGrant" // RevokeGrantRequest generates a "aws/request.Request" representing the // client's request for the RevokeGrant operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3631,7 +3631,7 @@ const opScheduleKeyDeletion = "ScheduleKeyDeletion" // ScheduleKeyDeletionRequest generates a "aws/request.Request" representing the // client's request for the ScheduleKeyDeletion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3747,7 +3747,7 @@ const opTagResource = "TagResource" // TagResourceRequest generates a "aws/request.Request" representing the // client's request for the TagResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3866,7 +3866,7 @@ const opUntagResource = "UntagResource" // UntagResourceRequest generates a "aws/request.Request" representing the // client's request for the UntagResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3971,7 +3971,7 @@ const opUpdateAlias = "UpdateAlias" // UpdateAliasRequest generates a "aws/request.Request" representing the // client's request for the UpdateAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4088,7 +4088,7 @@ const opUpdateKeyDescription = "UpdateKeyDescription" // UpdateKeyDescriptionRequest generates a "aws/request.Request" representing the // client's request for the UpdateKeyDescription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/lambda/api.go b/vendor/github.com/aws/aws-sdk-go/service/lambda/api.go index d4e8db908c84..8024623fe936 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/lambda/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/lambda/api.go @@ -17,7 +17,7 @@ const opAddPermission = "AddPermission" // AddPermissionRequest generates a "aws/request.Request" representing the // client's request for the AddPermission operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -64,7 +64,7 @@ func (c *Lambda) AddPermissionRequest(input *AddPermissionInput) (req *request.R // you add to the resource policy allows an event source, permission to invoke // the Lambda function. // -// For information about the push model, see AWS Lambda: How it Works (http://docs.aws.amazon.com/lambda/latest/dg/lambda-introduction.html). +// For information about the push model, see Lambda Functions (http://docs.aws.amazon.com/lambda/latest/dg/lambda-introduction.html). // // If you are using versioning, the permissions you add are specific to the // Lambda function version or alias you specify in the AddPermission request @@ -132,7 +132,7 @@ const opCreateAlias = "CreateAlias" // CreateAliasRequest generates a "aws/request.Request" representing the // client's request for the CreateAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -229,7 +229,7 @@ const opCreateEventSourceMapping = "CreateEventSourceMapping" // CreateEventSourceMappingRequest generates a "aws/request.Request" representing the // client's request for the CreateEventSourceMapping operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -276,16 +276,11 @@ func (c *Lambda) CreateEventSourceMappingRequest(input *CreateEventSourceMapping // This association between a stream source and a Lambda function is called // the event source mapping. // -// This event source mapping is relevant only in the AWS Lambda pull model, -// where AWS Lambda invokes the function. For more information, see AWS Lambda: -// How it Works (http://docs.aws.amazon.com/lambda/latest/dg/lambda-introduction.html) -// in the AWS Lambda Developer Guide. -// // You provide mapping information (for example, which stream to read from and // which Lambda function to invoke) in the request body. // // Each event source, such as an Amazon Kinesis or a DynamoDB stream, can be -// associated with multiple AWS Lambda function. A given Lambda function can +// associated with multiple AWS Lambda functions. A given Lambda function can // be associated with multiple AWS event sources. // // If you are using versioning, you can specify a specific function version @@ -346,7 +341,7 @@ const opCreateFunction = "CreateFunction" // CreateFunctionRequest generates a "aws/request.Request" representing the // client's request for the CreateFunction operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -451,7 +446,7 @@ const opDeleteAlias = "DeleteAlias" // DeleteAliasRequest generates a "aws/request.Request" representing the // client's request for the DeleteAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -542,7 +537,7 @@ const opDeleteEventSourceMapping = "DeleteEventSourceMapping" // DeleteEventSourceMappingRequest generates a "aws/request.Request" representing the // client's request for the DeleteEventSourceMapping operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -636,7 +631,7 @@ const opDeleteFunction = "DeleteFunction" // DeleteFunctionRequest generates a "aws/request.Request" representing the // client's request for the DeleteFunction operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -743,7 +738,7 @@ const opDeleteFunctionConcurrency = "DeleteFunctionConcurrency" // DeleteFunctionConcurrencyRequest generates a "aws/request.Request" representing the // client's request for the DeleteFunctionConcurrency operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -836,7 +831,7 @@ const opGetAccountSettings = "GetAccountSettings" // GetAccountSettingsRequest generates a "aws/request.Request" representing the // client's request for the GetAccountSettings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -923,7 +918,7 @@ const opGetAlias = "GetAlias" // GetAliasRequest generates a "aws/request.Request" representing the // client's request for the GetAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1017,7 +1012,7 @@ const opGetEventSourceMapping = "GetEventSourceMapping" // GetEventSourceMappingRequest generates a "aws/request.Request" representing the // client's request for the GetEventSourceMapping operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1110,7 +1105,7 @@ const opGetFunction = "GetFunction" // GetFunctionRequest generates a "aws/request.Request" representing the // client's request for the GetFunction operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1212,7 +1207,7 @@ const opGetFunctionConfiguration = "GetFunctionConfiguration" // GetFunctionConfigurationRequest generates a "aws/request.Request" representing the // client's request for the GetFunctionConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1314,7 +1309,7 @@ const opGetPolicy = "GetPolicy" // GetPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1411,7 +1406,7 @@ const opInvoke = "Invoke" // InvokeRequest generates a "aws/request.Request" representing the // client's request for the Invoke operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1577,7 +1572,7 @@ const opInvokeAsync = "InvokeAsync" // InvokeAsyncRequest generates a "aws/request.Request" representing the // client's request for the InvokeAsync operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1675,7 +1670,7 @@ const opListAliases = "ListAliases" // ListAliasesRequest generates a "aws/request.Request" representing the // client's request for the ListAliases operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1770,7 +1765,7 @@ const opListEventSourceMappings = "ListEventSourceMappings" // ListEventSourceMappingsRequest generates a "aws/request.Request" representing the // client's request for the ListEventSourceMappings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1928,7 +1923,7 @@ const opListFunctions = "ListFunctions" // ListFunctionsRequest generates a "aws/request.Request" representing the // client's request for the ListFunctions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2078,7 +2073,7 @@ const opListTags = "ListTags" // ListTagsRequest generates a "aws/request.Request" representing the // client's request for the ListTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2119,7 +2114,9 @@ func (c *Lambda) ListTagsRequest(input *ListTagsInput) (req *request.Request, ou // ListTags API operation for AWS Lambda. // // Returns a list of tags assigned to a function when supplied the function -// ARN (Amazon Resource Name). +// ARN (Amazon Resource Name). For more information on Tagging, see Tagging +// Lambda Functions (http://docs.aws.amazon.com/lambda/latest/dg/tagging.html) +// in the AWS Lambda Developer Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -2169,7 +2166,7 @@ const opListVersionsByFunction = "ListVersionsByFunction" // ListVersionsByFunctionRequest generates a "aws/request.Request" representing the // client's request for the ListVersionsByFunction operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2260,7 +2257,7 @@ const opPublishVersion = "PublishVersion" // PublishVersionRequest generates a "aws/request.Request" representing the // client's request for the PublishVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2362,7 +2359,7 @@ const opPutFunctionConcurrency = "PutFunctionConcurrency" // PutFunctionConcurrencyRequest generates a "aws/request.Request" representing the // client's request for the PutFunctionConcurrency operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2457,7 +2454,7 @@ const opRemovePermission = "RemovePermission" // RemovePermissionRequest generates a "aws/request.Request" representing the // client's request for the RemovePermission operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2566,7 +2563,7 @@ const opTagResource = "TagResource" // TagResourceRequest generates a "aws/request.Request" representing the // client's request for the TagResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2611,6 +2608,8 @@ func (c *Lambda) TagResourceRequest(input *TagResourceInput) (req *request.Reque // Creates a list of tags (key-value pairs) on the Lambda function. Requires // the Lambda function ARN (Amazon Resource Name). If a key is specified without // a value, Lambda creates a tag with the specified key and a value of null. +// For more information, see Tagging Lambda Functions (http://docs.aws.amazon.com/lambda/latest/dg/tagging.html) +// in the AWS Lambda Developer Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -2660,7 +2659,7 @@ const opUntagResource = "UntagResource" // UntagResourceRequest generates a "aws/request.Request" representing the // client's request for the UntagResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2703,7 +2702,8 @@ func (c *Lambda) UntagResourceRequest(input *UntagResourceInput) (req *request.R // UntagResource API operation for AWS Lambda. // // Removes tags from a Lambda function. Requires the function ARN (Amazon Resource -// Name). +// Name). For more information, see Tagging Lambda Functions (http://docs.aws.amazon.com/lambda/latest/dg/tagging.html) +// in the AWS Lambda Developer Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -2753,7 +2753,7 @@ const opUpdateAlias = "UpdateAlias" // UpdateAliasRequest generates a "aws/request.Request" representing the // client's request for the UpdateAlias operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2852,7 +2852,7 @@ const opUpdateEventSourceMapping = "UpdateEventSourceMapping" // UpdateEventSourceMappingRequest generates a "aws/request.Request" representing the // client's request for the UpdateEventSourceMapping operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2961,7 +2961,7 @@ const opUpdateFunctionCode = "UpdateFunctionCode" // UpdateFunctionCodeRequest generates a "aws/request.Request" representing the // client's request for the UpdateFunctionCode operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3067,7 +3067,7 @@ const opUpdateFunctionConfiguration = "UpdateFunctionConfiguration" // UpdateFunctionConfigurationRequest generates a "aws/request.Request" representing the // client's request for the UpdateFunctionConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3719,9 +3719,11 @@ type CreateEventSourceMappingInput struct { // FunctionName is a required field FunctionName *string `min:"1" type:"string" required:"true"` - // The position in the stream where AWS Lambda should start reading. Valid only - // for Kinesis streams. For more information, see ShardIteratorType (http://docs.aws.amazon.com/kinesis/latest/APIReference/API_GetShardIterator.html#Kinesis-GetShardIterator-request-ShardIteratorType) - // in the Amazon Kinesis API Reference. + // The position in the DynamoDB or Kinesis stream where AWS Lambda should start + // reading. For more information, see GetShardIterator (http://docs.aws.amazon.com/kinesis/latest/APIReference/API_GetShardIterator.html#Kinesis-GetShardIterator-request-ShardIteratorType) + // in the Amazon Kinesis API Reference Guide or GetShardIterator (http://docs.aws.amazon.com/amazondynamodb/latest/APIReference/API_streams_GetShardIterator.html) + // in the Amazon DynamoDB API Reference Guide. The AT_TIMESTAMP value is supported + // only for Kinesis streams (http://docs.aws.amazon.com/streams/latest/dev/amazon-kinesis-streams.html). // // StartingPosition is a required field StartingPosition *string `type:"string" required:"true" enum:"EventSourcePosition"` @@ -3731,7 +3733,7 @@ type CreateEventSourceMappingInput struct { // AT_TIMESTAMP. If a record with this exact timestamp does not exist, the iterator // returned is for the next (later) record. If the timestamp is older than the // current trim horizon, the iterator returned is for the oldest untrimmed data - // record (TRIM_HORIZON). Valid only for Kinesis streams. + // record (TRIM_HORIZON). Valid only for Kinesis streams (http://docs.aws.amazon.com/streams/latest/dev/amazon-kinesis-streams.html). StartingPositionTimestamp *time.Time `type:"timestamp" timestampFormat:"unix"` } @@ -3815,7 +3817,7 @@ type CreateFunctionInput struct { Code *FunctionCode `type:"structure" required:"true"` // The parent object that contains the target ARN (Amazon Resource Name) of - // an Amazon SQS queue or Amazon SNS topic. + // an Amazon SQS queue or Amazon SNS topic. For more information, see dlq. DeadLetterConfig *DeadLetterConfig `type:"structure"` // A short, user-defined function description. Lambda does not use this value. @@ -3871,7 +3873,8 @@ type CreateFunctionInput struct { // To use the Python runtime v3.6, set the value to "python3.6". To use the // Python runtime v2.7, set the value to "python2.7". To use the Node.js runtime // v6.10, set the value to "nodejs6.10". To use the Node.js runtime v4.3, set - // the value to "nodejs4.3". + // the value to "nodejs4.3". To use the .NET Core runtime v1.0, set the value + // to "dotnetcore1.0". To use the .NET Core runtime v2.0, set the value to "dotnetcore2.0". // // Node v0.10.42 is currently marked as deprecated. You must migrate existing // functions to the newer Node.js runtime versions available on AWS Lambda (nodejs4.3 @@ -3882,7 +3885,9 @@ type CreateFunctionInput struct { // Runtime is a required field Runtime *string `type:"string" required:"true" enum:"Runtime"` - // The list of tags (key-value pairs) assigned to the new function. + // The list of tags (key-value pairs) assigned to the new function. For more + // information, see Tagging Lambda Functions (http://docs.aws.amazon.com/lambda/latest/dg/tagging.html) + // in the AWS Lambda Developer Guide. Tags map[string]*string `type:"map"` // The function execution time at which Lambda should terminate the function. @@ -4039,13 +4044,14 @@ func (s *CreateFunctionInput) SetVpcConfig(v *VpcConfig) *CreateFunctionInput { return s } -// The parent object that contains the target ARN (Amazon Resource Name) of -// an Amazon SQS queue or Amazon SNS topic. +// The Amazon Resource Name (ARN) of an Amazon SQS queue or Amazon SNS topic +// you specify as your Dead Letter Queue (DLQ). For more information, see dlq. type DeadLetterConfig struct { _ struct{} `type:"structure"` // The Amazon Resource Name (ARN) of an Amazon SQS queue or Amazon SNS topic - // you specify as your Dead Letter Queue (DLQ). + // you specify as your Dead Letter Queue (DLQ). dlq. For more information, see + // dlq. TargetArn *string `type:"string"` } @@ -4632,7 +4638,7 @@ type FunctionConfiguration struct { CodeSize *int64 `type:"long"` // The parent object that contains the target ARN (Amazon Resource Name) of - // an Amazon SQS queue or Amazon SNS topic. + // an Amazon SQS queue or Amazon SNS topic. For more information, see dlq. DeadLetterConfig *DeadLetterConfig `type:"structure"` // The user-provided description. @@ -5113,7 +5119,9 @@ type GetFunctionOutput struct { // A complex type that describes function metadata. Configuration *FunctionConfiguration `type:"structure"` - // Returns the list of tags associated with the function. + // Returns the list of tags associated with the function. For more information, + // see Tagging Lambda Functions (http://docs.aws.amazon.com/lambda/latest/dg/tagging.html) + // in the AWS Lambda Developer Guide. Tags map[string]*string `type:"map"` } @@ -5865,7 +5873,9 @@ func (s *ListFunctionsOutput) SetNextMarker(v string) *ListFunctionsOutput { type ListTagsInput struct { _ struct{} `type:"structure"` - // The ARN (Amazon Resource Name) of the function. + // The ARN (Amazon Resource Name) of the function. For more information, see + // Tagging Lambda Functions (http://docs.aws.amazon.com/lambda/latest/dg/tagging.html) + // in the AWS Lambda Developer Guide. // // Resource is a required field Resource *string `location:"uri" locationName:"ARN" type:"string" required:"true"` @@ -5903,7 +5913,9 @@ func (s *ListTagsInput) SetResource(v string) *ListTagsInput { type ListTagsOutput struct { _ struct{} `type:"structure"` - // The list of tags assigned to the function. + // The list of tags assigned to the function. For more information, see Tagging + // Lambda Functions (http://docs.aws.amazon.com/lambda/latest/dg/tagging.html) + // in the AWS Lambda Developer Guide. Tags map[string]*string `type:"map"` } @@ -6296,12 +6308,16 @@ func (s RemovePermissionOutput) GoString() string { type TagResourceInput struct { _ struct{} `type:"structure"` - // The ARN (Amazon Resource Name) of the Lambda function. + // The ARN (Amazon Resource Name) of the Lambda function. For more information, + // see Tagging Lambda Functions (http://docs.aws.amazon.com/lambda/latest/dg/tagging.html) + // in the AWS Lambda Developer Guide. // // Resource is a required field Resource *string `location:"uri" locationName:"ARN" type:"string" required:"true"` // The list of tags (key-value pairs) you are assigning to the Lambda function. + // For more information, see Tagging Lambda Functions (http://docs.aws.amazon.com/lambda/latest/dg/tagging.html) + // in the AWS Lambda Developer Guide. // // Tags is a required field Tags map[string]*string `type:"map" required:"true"` @@ -6414,12 +6430,16 @@ func (s *TracingConfigResponse) SetMode(v string) *TracingConfigResponse { type UntagResourceInput struct { _ struct{} `type:"structure"` - // The ARN (Amazon Resource Name) of the function. + // The ARN (Amazon Resource Name) of the function. For more information, see + // Tagging Lambda Functions (http://docs.aws.amazon.com/lambda/latest/dg/tagging.html) + // in the AWS Lambda Developer Guide. // // Resource is a required field Resource *string `location:"uri" locationName:"ARN" type:"string" required:"true"` - // The list of tag keys to be deleted from the function. + // The list of tag keys to be deleted from the function. For more information, + // see Tagging Lambda Functions (http://docs.aws.amazon.com/lambda/latest/dg/tagging.html) + // in the AWS Lambda Developer Guide. // // TagKeys is a required field TagKeys []*string `location:"querystring" locationName:"tagKeys" type:"list" required:"true"` @@ -6718,8 +6738,7 @@ type UpdateFunctionCodeInput struct { // are using the web API directly, the contents of the zip file must be base64-encoded. // If you are using the AWS SDKs or the AWS CLI, the SDKs or CLI will do the // encoding for you. For more information about creating a .zip file, see Execution - // Permissions (http://docs.aws.amazon.com/lambda/latest/dg/intro-permission-model.html#lambda-intro-execution-role.html) - // in the AWS Lambda Developer Guide. + // Permissions (http://docs.aws.amazon.com/lambda/latest/dg/intro-permission-model.html#lambda-intro-execution-role.html). // // ZipFile is automatically base64 encoded/decoded by the SDK. ZipFile []byte `type:"blob"` @@ -6812,7 +6831,7 @@ type UpdateFunctionConfigurationInput struct { _ struct{} `type:"structure"` // The parent object that contains the target ARN (Amazon Resource Name) of - // an Amazon SQS queue or Amazon SNS topic. + // an Amazon SQS queue or Amazon SNS topic. For more information, see dlq. DeadLetterConfig *DeadLetterConfig `type:"structure"` // A short user-defined function description. AWS Lambda does not use this value. @@ -6866,8 +6885,8 @@ type UpdateFunctionConfigurationInput struct { // To use the Python runtime v3.6, set the value to "python3.6". To use the // Python runtime v2.7, set the value to "python2.7". To use the Node.js runtime // v6.10, set the value to "nodejs6.10". To use the Node.js runtime v4.3, set - // the value to "nodejs4.3". To use the Python runtime v3.6, set the value to - // "python3.6". + // the value to "nodejs4.3". To use the .NET Core runtime v1.0, set the value + // to "dotnetcore1.0". To use the .NET Core runtime v2.0, set the value to "dotnetcore2.0". // // Node v0.10.42 is currently marked as deprecated. You must migrate existing // functions to the newer Node.js runtime versions available on AWS Lambda (nodejs4.3 @@ -7124,6 +7143,9 @@ const ( // RuntimeNodejs610 is a Runtime enum value RuntimeNodejs610 = "nodejs6.10" + // RuntimeNodejs810 is a Runtime enum value + RuntimeNodejs810 = "nodejs8.10" + // RuntimeJava8 is a Runtime enum value RuntimeJava8 = "java8" diff --git a/vendor/github.com/aws/aws-sdk-go/service/lexmodelbuildingservice/api.go b/vendor/github.com/aws/aws-sdk-go/service/lexmodelbuildingservice/api.go new file mode 100644 index 000000000000..c396a9b784f8 --- /dev/null +++ b/vendor/github.com/aws/aws-sdk-go/service/lexmodelbuildingservice/api.go @@ -0,0 +1,10787 @@ +// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. + +package lexmodelbuildingservice + +import ( + "fmt" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/awsutil" + "github.com/aws/aws-sdk-go/aws/request" + "github.com/aws/aws-sdk-go/private/protocol" + "github.com/aws/aws-sdk-go/private/protocol/restjson" +) + +const opCreateBotVersion = "CreateBotVersion" + +// CreateBotVersionRequest generates a "aws/request.Request" representing the +// client's request for the CreateBotVersion operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See CreateBotVersion for more information on using the CreateBotVersion +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the CreateBotVersionRequest method. +// req, resp := client.CreateBotVersionRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/CreateBotVersion +func (c *LexModelBuildingService) CreateBotVersionRequest(input *CreateBotVersionInput) (req *request.Request, output *CreateBotVersionOutput) { + op := &request.Operation{ + Name: opCreateBotVersion, + HTTPMethod: "POST", + HTTPPath: "/bots/{name}/versions", + } + + if input == nil { + input = &CreateBotVersionInput{} + } + + output = &CreateBotVersionOutput{} + req = c.newRequest(op, input, output) + return +} + +// CreateBotVersion API operation for Amazon Lex Model Building Service. +// +// Creates a new version of the bot based on the $LATEST version. If the $LATEST +// version of this resource hasn't changed since you created the last version, +// Amazon Lex doesn't create a new version. It returns the last created version. +// +// You can update only the $LATEST version of the bot. You can't update the +// numbered versions that you create with the CreateBotVersion operation. +// +// When you create the first version of a bot, Amazon Lex sets the version to +// 1. Subsequent versions increment by 1. For more information, see versioning-intro. +// +// This operation requires permission for the lex:CreateBotVersion action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation CreateBotVersion for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeConflictException "ConflictException" +// There was a conflict processing the request. Try your request again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// * ErrCodePreconditionFailedException "PreconditionFailedException" +// The checksum of the resource that you are trying to change does not match +// the checksum in the request. Check the resource's checksum and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/CreateBotVersion +func (c *LexModelBuildingService) CreateBotVersion(input *CreateBotVersionInput) (*CreateBotVersionOutput, error) { + req, out := c.CreateBotVersionRequest(input) + return out, req.Send() +} + +// CreateBotVersionWithContext is the same as CreateBotVersion with the addition of +// the ability to pass a context and additional request options. +// +// See CreateBotVersion for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) CreateBotVersionWithContext(ctx aws.Context, input *CreateBotVersionInput, opts ...request.Option) (*CreateBotVersionOutput, error) { + req, out := c.CreateBotVersionRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opCreateIntentVersion = "CreateIntentVersion" + +// CreateIntentVersionRequest generates a "aws/request.Request" representing the +// client's request for the CreateIntentVersion operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See CreateIntentVersion for more information on using the CreateIntentVersion +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the CreateIntentVersionRequest method. +// req, resp := client.CreateIntentVersionRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/CreateIntentVersion +func (c *LexModelBuildingService) CreateIntentVersionRequest(input *CreateIntentVersionInput) (req *request.Request, output *CreateIntentVersionOutput) { + op := &request.Operation{ + Name: opCreateIntentVersion, + HTTPMethod: "POST", + HTTPPath: "/intents/{name}/versions", + } + + if input == nil { + input = &CreateIntentVersionInput{} + } + + output = &CreateIntentVersionOutput{} + req = c.newRequest(op, input, output) + return +} + +// CreateIntentVersion API operation for Amazon Lex Model Building Service. +// +// Creates a new version of an intent based on the $LATEST version of the intent. +// If the $LATEST version of this intent hasn't changed since you last updated +// it, Amazon Lex doesn't create a new version. It returns the last version +// you created. +// +// You can update only the $LATEST version of the intent. You can't update the +// numbered versions that you create with the CreateIntentVersion operation. +// +// When you create a version of an intent, Amazon Lex sets the version to 1. +// Subsequent versions increment by 1. For more information, see versioning-intro. +// +// This operation requires permissions to perform the lex:CreateIntentVersion +// action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation CreateIntentVersion for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeConflictException "ConflictException" +// There was a conflict processing the request. Try your request again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// * ErrCodePreconditionFailedException "PreconditionFailedException" +// The checksum of the resource that you are trying to change does not match +// the checksum in the request. Check the resource's checksum and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/CreateIntentVersion +func (c *LexModelBuildingService) CreateIntentVersion(input *CreateIntentVersionInput) (*CreateIntentVersionOutput, error) { + req, out := c.CreateIntentVersionRequest(input) + return out, req.Send() +} + +// CreateIntentVersionWithContext is the same as CreateIntentVersion with the addition of +// the ability to pass a context and additional request options. +// +// See CreateIntentVersion for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) CreateIntentVersionWithContext(ctx aws.Context, input *CreateIntentVersionInput, opts ...request.Option) (*CreateIntentVersionOutput, error) { + req, out := c.CreateIntentVersionRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opCreateSlotTypeVersion = "CreateSlotTypeVersion" + +// CreateSlotTypeVersionRequest generates a "aws/request.Request" representing the +// client's request for the CreateSlotTypeVersion operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See CreateSlotTypeVersion for more information on using the CreateSlotTypeVersion +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the CreateSlotTypeVersionRequest method. +// req, resp := client.CreateSlotTypeVersionRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/CreateSlotTypeVersion +func (c *LexModelBuildingService) CreateSlotTypeVersionRequest(input *CreateSlotTypeVersionInput) (req *request.Request, output *CreateSlotTypeVersionOutput) { + op := &request.Operation{ + Name: opCreateSlotTypeVersion, + HTTPMethod: "POST", + HTTPPath: "/slottypes/{name}/versions", + } + + if input == nil { + input = &CreateSlotTypeVersionInput{} + } + + output = &CreateSlotTypeVersionOutput{} + req = c.newRequest(op, input, output) + return +} + +// CreateSlotTypeVersion API operation for Amazon Lex Model Building Service. +// +// Creates a new version of a slot type based on the $LATEST version of the +// specified slot type. If the $LATEST version of this resource has not changed +// since the last version that you created, Amazon Lex doesn't create a new +// version. It returns the last version that you created. +// +// You can update only the $LATEST version of a slot type. You can't update +// the numbered versions that you create with the CreateSlotTypeVersion operation. +// +// When you create a version of a slot type, Amazon Lex sets the version to +// 1. Subsequent versions increment by 1. For more information, see versioning-intro. +// +// This operation requires permissions for the lex:CreateSlotTypeVersion action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation CreateSlotTypeVersion for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeConflictException "ConflictException" +// There was a conflict processing the request. Try your request again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// * ErrCodePreconditionFailedException "PreconditionFailedException" +// The checksum of the resource that you are trying to change does not match +// the checksum in the request. Check the resource's checksum and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/CreateSlotTypeVersion +func (c *LexModelBuildingService) CreateSlotTypeVersion(input *CreateSlotTypeVersionInput) (*CreateSlotTypeVersionOutput, error) { + req, out := c.CreateSlotTypeVersionRequest(input) + return out, req.Send() +} + +// CreateSlotTypeVersionWithContext is the same as CreateSlotTypeVersion with the addition of +// the ability to pass a context and additional request options. +// +// See CreateSlotTypeVersion for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) CreateSlotTypeVersionWithContext(ctx aws.Context, input *CreateSlotTypeVersionInput, opts ...request.Option) (*CreateSlotTypeVersionOutput, error) { + req, out := c.CreateSlotTypeVersionRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeleteBot = "DeleteBot" + +// DeleteBotRequest generates a "aws/request.Request" representing the +// client's request for the DeleteBot operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteBot for more information on using the DeleteBot +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteBotRequest method. +// req, resp := client.DeleteBotRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteBot +func (c *LexModelBuildingService) DeleteBotRequest(input *DeleteBotInput) (req *request.Request, output *DeleteBotOutput) { + op := &request.Operation{ + Name: opDeleteBot, + HTTPMethod: "DELETE", + HTTPPath: "/bots/{name}", + } + + if input == nil { + input = &DeleteBotInput{} + } + + output = &DeleteBotOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeleteBot API operation for Amazon Lex Model Building Service. +// +// Deletes all versions of the bot, including the $LATEST version. To delete +// a specific version of the bot, use the DeleteBotVersion operation. +// +// If a bot has an alias, you can't delete it. Instead, the DeleteBot operation +// returns a ResourceInUseException exception that includes a reference to the +// alias that refers to the bot. To remove the reference to the bot, delete +// the alias. If you get the same exception again, delete the referring alias +// until the DeleteBot operation is successful. +// +// This operation requires permissions for the lex:DeleteBot action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation DeleteBot for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeConflictException "ConflictException" +// There was a conflict processing the request. Try your request again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// * ErrCodeResourceInUseException "ResourceInUseException" +// The resource that you are attempting to delete is referred to by another +// resource. Use this information to remove references to the resource that +// you are trying to delete. +// +// The body of the exception contains a JSON object that describes the resource. +// +// { "resourceType": BOT | BOTALIAS | BOTCHANNEL | INTENT, +// +// "resourceReference": { +// +// "name": string, "version": string } } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteBot +func (c *LexModelBuildingService) DeleteBot(input *DeleteBotInput) (*DeleteBotOutput, error) { + req, out := c.DeleteBotRequest(input) + return out, req.Send() +} + +// DeleteBotWithContext is the same as DeleteBot with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteBot for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) DeleteBotWithContext(ctx aws.Context, input *DeleteBotInput, opts ...request.Option) (*DeleteBotOutput, error) { + req, out := c.DeleteBotRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeleteBotAlias = "DeleteBotAlias" + +// DeleteBotAliasRequest generates a "aws/request.Request" representing the +// client's request for the DeleteBotAlias operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteBotAlias for more information on using the DeleteBotAlias +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteBotAliasRequest method. +// req, resp := client.DeleteBotAliasRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteBotAlias +func (c *LexModelBuildingService) DeleteBotAliasRequest(input *DeleteBotAliasInput) (req *request.Request, output *DeleteBotAliasOutput) { + op := &request.Operation{ + Name: opDeleteBotAlias, + HTTPMethod: "DELETE", + HTTPPath: "/bots/{botName}/aliases/{name}", + } + + if input == nil { + input = &DeleteBotAliasInput{} + } + + output = &DeleteBotAliasOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeleteBotAlias API operation for Amazon Lex Model Building Service. +// +// Deletes an alias for the specified bot. +// +// You can't delete an alias that is used in the association between a bot and +// a messaging channel. If an alias is used in a channel association, the DeleteBot +// operation returns a ResourceInUseException exception that includes a reference +// to the channel association that refers to the bot. You can remove the reference +// to the alias by deleting the channel association. If you get the same exception +// again, delete the referring association until the DeleteBotAlias operation +// is successful. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation DeleteBotAlias for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeConflictException "ConflictException" +// There was a conflict processing the request. Try your request again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// * ErrCodeResourceInUseException "ResourceInUseException" +// The resource that you are attempting to delete is referred to by another +// resource. Use this information to remove references to the resource that +// you are trying to delete. +// +// The body of the exception contains a JSON object that describes the resource. +// +// { "resourceType": BOT | BOTALIAS | BOTCHANNEL | INTENT, +// +// "resourceReference": { +// +// "name": string, "version": string } } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteBotAlias +func (c *LexModelBuildingService) DeleteBotAlias(input *DeleteBotAliasInput) (*DeleteBotAliasOutput, error) { + req, out := c.DeleteBotAliasRequest(input) + return out, req.Send() +} + +// DeleteBotAliasWithContext is the same as DeleteBotAlias with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteBotAlias for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) DeleteBotAliasWithContext(ctx aws.Context, input *DeleteBotAliasInput, opts ...request.Option) (*DeleteBotAliasOutput, error) { + req, out := c.DeleteBotAliasRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeleteBotChannelAssociation = "DeleteBotChannelAssociation" + +// DeleteBotChannelAssociationRequest generates a "aws/request.Request" representing the +// client's request for the DeleteBotChannelAssociation operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteBotChannelAssociation for more information on using the DeleteBotChannelAssociation +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteBotChannelAssociationRequest method. +// req, resp := client.DeleteBotChannelAssociationRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteBotChannelAssociation +func (c *LexModelBuildingService) DeleteBotChannelAssociationRequest(input *DeleteBotChannelAssociationInput) (req *request.Request, output *DeleteBotChannelAssociationOutput) { + op := &request.Operation{ + Name: opDeleteBotChannelAssociation, + HTTPMethod: "DELETE", + HTTPPath: "/bots/{botName}/aliases/{aliasName}/channels/{name}", + } + + if input == nil { + input = &DeleteBotChannelAssociationInput{} + } + + output = &DeleteBotChannelAssociationOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeleteBotChannelAssociation API operation for Amazon Lex Model Building Service. +// +// Deletes the association between an Amazon Lex bot and a messaging platform. +// +// This operation requires permission for the lex:DeleteBotChannelAssociation +// action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation DeleteBotChannelAssociation for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeConflictException "ConflictException" +// There was a conflict processing the request. Try your request again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteBotChannelAssociation +func (c *LexModelBuildingService) DeleteBotChannelAssociation(input *DeleteBotChannelAssociationInput) (*DeleteBotChannelAssociationOutput, error) { + req, out := c.DeleteBotChannelAssociationRequest(input) + return out, req.Send() +} + +// DeleteBotChannelAssociationWithContext is the same as DeleteBotChannelAssociation with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteBotChannelAssociation for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) DeleteBotChannelAssociationWithContext(ctx aws.Context, input *DeleteBotChannelAssociationInput, opts ...request.Option) (*DeleteBotChannelAssociationOutput, error) { + req, out := c.DeleteBotChannelAssociationRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeleteBotVersion = "DeleteBotVersion" + +// DeleteBotVersionRequest generates a "aws/request.Request" representing the +// client's request for the DeleteBotVersion operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteBotVersion for more information on using the DeleteBotVersion +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteBotVersionRequest method. +// req, resp := client.DeleteBotVersionRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteBotVersion +func (c *LexModelBuildingService) DeleteBotVersionRequest(input *DeleteBotVersionInput) (req *request.Request, output *DeleteBotVersionOutput) { + op := &request.Operation{ + Name: opDeleteBotVersion, + HTTPMethod: "DELETE", + HTTPPath: "/bots/{name}/versions/{version}", + } + + if input == nil { + input = &DeleteBotVersionInput{} + } + + output = &DeleteBotVersionOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeleteBotVersion API operation for Amazon Lex Model Building Service. +// +// Deletes a specific version of a bot. To delete all versions of a bot, use +// the DeleteBot operation. +// +// This operation requires permissions for the lex:DeleteBotVersion action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation DeleteBotVersion for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeConflictException "ConflictException" +// There was a conflict processing the request. Try your request again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// * ErrCodeResourceInUseException "ResourceInUseException" +// The resource that you are attempting to delete is referred to by another +// resource. Use this information to remove references to the resource that +// you are trying to delete. +// +// The body of the exception contains a JSON object that describes the resource. +// +// { "resourceType": BOT | BOTALIAS | BOTCHANNEL | INTENT, +// +// "resourceReference": { +// +// "name": string, "version": string } } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteBotVersion +func (c *LexModelBuildingService) DeleteBotVersion(input *DeleteBotVersionInput) (*DeleteBotVersionOutput, error) { + req, out := c.DeleteBotVersionRequest(input) + return out, req.Send() +} + +// DeleteBotVersionWithContext is the same as DeleteBotVersion with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteBotVersion for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) DeleteBotVersionWithContext(ctx aws.Context, input *DeleteBotVersionInput, opts ...request.Option) (*DeleteBotVersionOutput, error) { + req, out := c.DeleteBotVersionRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeleteIntent = "DeleteIntent" + +// DeleteIntentRequest generates a "aws/request.Request" representing the +// client's request for the DeleteIntent operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteIntent for more information on using the DeleteIntent +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteIntentRequest method. +// req, resp := client.DeleteIntentRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteIntent +func (c *LexModelBuildingService) DeleteIntentRequest(input *DeleteIntentInput) (req *request.Request, output *DeleteIntentOutput) { + op := &request.Operation{ + Name: opDeleteIntent, + HTTPMethod: "DELETE", + HTTPPath: "/intents/{name}", + } + + if input == nil { + input = &DeleteIntentInput{} + } + + output = &DeleteIntentOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeleteIntent API operation for Amazon Lex Model Building Service. +// +// Deletes all versions of the intent, including the $LATEST version. To delete +// a specific version of the intent, use the DeleteIntentVersion operation. +// +// You can delete a version of an intent only if it is not referenced. To delete +// an intent that is referred to in one or more bots (see how-it-works), you +// must remove those references first. +// +// If you get the ResourceInUseException exception, it provides an example reference +// that shows where the intent is referenced. To remove the reference to the +// intent, either update the bot or delete it. If you get the same exception +// when you attempt to delete the intent again, repeat until the intent has +// no references and the call to DeleteIntent is successful. +// +// This operation requires permission for the lex:DeleteIntent action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation DeleteIntent for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeConflictException "ConflictException" +// There was a conflict processing the request. Try your request again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// * ErrCodeResourceInUseException "ResourceInUseException" +// The resource that you are attempting to delete is referred to by another +// resource. Use this information to remove references to the resource that +// you are trying to delete. +// +// The body of the exception contains a JSON object that describes the resource. +// +// { "resourceType": BOT | BOTALIAS | BOTCHANNEL | INTENT, +// +// "resourceReference": { +// +// "name": string, "version": string } } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteIntent +func (c *LexModelBuildingService) DeleteIntent(input *DeleteIntentInput) (*DeleteIntentOutput, error) { + req, out := c.DeleteIntentRequest(input) + return out, req.Send() +} + +// DeleteIntentWithContext is the same as DeleteIntent with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteIntent for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) DeleteIntentWithContext(ctx aws.Context, input *DeleteIntentInput, opts ...request.Option) (*DeleteIntentOutput, error) { + req, out := c.DeleteIntentRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeleteIntentVersion = "DeleteIntentVersion" + +// DeleteIntentVersionRequest generates a "aws/request.Request" representing the +// client's request for the DeleteIntentVersion operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteIntentVersion for more information on using the DeleteIntentVersion +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteIntentVersionRequest method. +// req, resp := client.DeleteIntentVersionRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteIntentVersion +func (c *LexModelBuildingService) DeleteIntentVersionRequest(input *DeleteIntentVersionInput) (req *request.Request, output *DeleteIntentVersionOutput) { + op := &request.Operation{ + Name: opDeleteIntentVersion, + HTTPMethod: "DELETE", + HTTPPath: "/intents/{name}/versions/{version}", + } + + if input == nil { + input = &DeleteIntentVersionInput{} + } + + output = &DeleteIntentVersionOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeleteIntentVersion API operation for Amazon Lex Model Building Service. +// +// Deletes a specific version of an intent. To delete all versions of a intent, +// use the DeleteIntent operation. +// +// This operation requires permissions for the lex:DeleteIntentVersion action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation DeleteIntentVersion for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeConflictException "ConflictException" +// There was a conflict processing the request. Try your request again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// * ErrCodeResourceInUseException "ResourceInUseException" +// The resource that you are attempting to delete is referred to by another +// resource. Use this information to remove references to the resource that +// you are trying to delete. +// +// The body of the exception contains a JSON object that describes the resource. +// +// { "resourceType": BOT | BOTALIAS | BOTCHANNEL | INTENT, +// +// "resourceReference": { +// +// "name": string, "version": string } } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteIntentVersion +func (c *LexModelBuildingService) DeleteIntentVersion(input *DeleteIntentVersionInput) (*DeleteIntentVersionOutput, error) { + req, out := c.DeleteIntentVersionRequest(input) + return out, req.Send() +} + +// DeleteIntentVersionWithContext is the same as DeleteIntentVersion with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteIntentVersion for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) DeleteIntentVersionWithContext(ctx aws.Context, input *DeleteIntentVersionInput, opts ...request.Option) (*DeleteIntentVersionOutput, error) { + req, out := c.DeleteIntentVersionRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeleteSlotType = "DeleteSlotType" + +// DeleteSlotTypeRequest generates a "aws/request.Request" representing the +// client's request for the DeleteSlotType operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteSlotType for more information on using the DeleteSlotType +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteSlotTypeRequest method. +// req, resp := client.DeleteSlotTypeRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteSlotType +func (c *LexModelBuildingService) DeleteSlotTypeRequest(input *DeleteSlotTypeInput) (req *request.Request, output *DeleteSlotTypeOutput) { + op := &request.Operation{ + Name: opDeleteSlotType, + HTTPMethod: "DELETE", + HTTPPath: "/slottypes/{name}", + } + + if input == nil { + input = &DeleteSlotTypeInput{} + } + + output = &DeleteSlotTypeOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeleteSlotType API operation for Amazon Lex Model Building Service. +// +// Deletes all versions of the slot type, including the $LATEST version. To +// delete a specific version of the slot type, use the DeleteSlotTypeVersion +// operation. +// +// You can delete a version of a slot type only if it is not referenced. To +// delete a slot type that is referred to in one or more intents, you must remove +// those references first. +// +// If you get the ResourceInUseException exception, the exception provides an +// example reference that shows the intent where the slot type is referenced. +// To remove the reference to the slot type, either update the intent or delete +// it. If you get the same exception when you attempt to delete the slot type +// again, repeat until the slot type has no references and the DeleteSlotType +// call is successful. +// +// This operation requires permission for the lex:DeleteSlotType action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation DeleteSlotType for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeConflictException "ConflictException" +// There was a conflict processing the request. Try your request again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// * ErrCodeResourceInUseException "ResourceInUseException" +// The resource that you are attempting to delete is referred to by another +// resource. Use this information to remove references to the resource that +// you are trying to delete. +// +// The body of the exception contains a JSON object that describes the resource. +// +// { "resourceType": BOT | BOTALIAS | BOTCHANNEL | INTENT, +// +// "resourceReference": { +// +// "name": string, "version": string } } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteSlotType +func (c *LexModelBuildingService) DeleteSlotType(input *DeleteSlotTypeInput) (*DeleteSlotTypeOutput, error) { + req, out := c.DeleteSlotTypeRequest(input) + return out, req.Send() +} + +// DeleteSlotTypeWithContext is the same as DeleteSlotType with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteSlotType for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) DeleteSlotTypeWithContext(ctx aws.Context, input *DeleteSlotTypeInput, opts ...request.Option) (*DeleteSlotTypeOutput, error) { + req, out := c.DeleteSlotTypeRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeleteSlotTypeVersion = "DeleteSlotTypeVersion" + +// DeleteSlotTypeVersionRequest generates a "aws/request.Request" representing the +// client's request for the DeleteSlotTypeVersion operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteSlotTypeVersion for more information on using the DeleteSlotTypeVersion +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteSlotTypeVersionRequest method. +// req, resp := client.DeleteSlotTypeVersionRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteSlotTypeVersion +func (c *LexModelBuildingService) DeleteSlotTypeVersionRequest(input *DeleteSlotTypeVersionInput) (req *request.Request, output *DeleteSlotTypeVersionOutput) { + op := &request.Operation{ + Name: opDeleteSlotTypeVersion, + HTTPMethod: "DELETE", + HTTPPath: "/slottypes/{name}/version/{version}", + } + + if input == nil { + input = &DeleteSlotTypeVersionInput{} + } + + output = &DeleteSlotTypeVersionOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeleteSlotTypeVersion API operation for Amazon Lex Model Building Service. +// +// Deletes a specific version of a slot type. To delete all versions of a slot +// type, use the DeleteSlotType operation. +// +// This operation requires permissions for the lex:DeleteSlotTypeVersion action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation DeleteSlotTypeVersion for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeConflictException "ConflictException" +// There was a conflict processing the request. Try your request again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// * ErrCodeResourceInUseException "ResourceInUseException" +// The resource that you are attempting to delete is referred to by another +// resource. Use this information to remove references to the resource that +// you are trying to delete. +// +// The body of the exception contains a JSON object that describes the resource. +// +// { "resourceType": BOT | BOTALIAS | BOTCHANNEL | INTENT, +// +// "resourceReference": { +// +// "name": string, "version": string } } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteSlotTypeVersion +func (c *LexModelBuildingService) DeleteSlotTypeVersion(input *DeleteSlotTypeVersionInput) (*DeleteSlotTypeVersionOutput, error) { + req, out := c.DeleteSlotTypeVersionRequest(input) + return out, req.Send() +} + +// DeleteSlotTypeVersionWithContext is the same as DeleteSlotTypeVersion with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteSlotTypeVersion for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) DeleteSlotTypeVersionWithContext(ctx aws.Context, input *DeleteSlotTypeVersionInput, opts ...request.Option) (*DeleteSlotTypeVersionOutput, error) { + req, out := c.DeleteSlotTypeVersionRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeleteUtterances = "DeleteUtterances" + +// DeleteUtterancesRequest generates a "aws/request.Request" representing the +// client's request for the DeleteUtterances operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteUtterances for more information on using the DeleteUtterances +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteUtterancesRequest method. +// req, resp := client.DeleteUtterancesRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteUtterances +func (c *LexModelBuildingService) DeleteUtterancesRequest(input *DeleteUtterancesInput) (req *request.Request, output *DeleteUtterancesOutput) { + op := &request.Operation{ + Name: opDeleteUtterances, + HTTPMethod: "DELETE", + HTTPPath: "/bots/{botName}/utterances/{userId}", + } + + if input == nil { + input = &DeleteUtterancesInput{} + } + + output = &DeleteUtterancesOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeleteUtterances API operation for Amazon Lex Model Building Service. +// +// Deletes stored utterances. +// +// Amazon Lex stores the utterances that users send to your bot. Utterances +// are stored for 15 days for use with the GetUtterancesView operation, and +// then stored indefinitely for use in improving the ability of your bot to +// respond to user input. +// +// Use the DeleteStoredUtterances operation to manually delete stored utterances +// for a specific user. +// +// This operation requires permissions for the lex:DeleteUtterances action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation DeleteUtterances for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/DeleteUtterances +func (c *LexModelBuildingService) DeleteUtterances(input *DeleteUtterancesInput) (*DeleteUtterancesOutput, error) { + req, out := c.DeleteUtterancesRequest(input) + return out, req.Send() +} + +// DeleteUtterancesWithContext is the same as DeleteUtterances with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteUtterances for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) DeleteUtterancesWithContext(ctx aws.Context, input *DeleteUtterancesInput, opts ...request.Option) (*DeleteUtterancesOutput, error) { + req, out := c.DeleteUtterancesRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opGetBot = "GetBot" + +// GetBotRequest generates a "aws/request.Request" representing the +// client's request for the GetBot operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetBot for more information on using the GetBot +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetBotRequest method. +// req, resp := client.GetBotRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBot +func (c *LexModelBuildingService) GetBotRequest(input *GetBotInput) (req *request.Request, output *GetBotOutput) { + op := &request.Operation{ + Name: opGetBot, + HTTPMethod: "GET", + HTTPPath: "/bots/{name}/versions/{versionoralias}", + } + + if input == nil { + input = &GetBotInput{} + } + + output = &GetBotOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetBot API operation for Amazon Lex Model Building Service. +// +// Returns metadata information for a specific bot. You must provide the bot +// name and the bot version or alias. +// +// This operation requires permissions for the lex:GetBot action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetBot for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBot +func (c *LexModelBuildingService) GetBot(input *GetBotInput) (*GetBotOutput, error) { + req, out := c.GetBotRequest(input) + return out, req.Send() +} + +// GetBotWithContext is the same as GetBot with the addition of +// the ability to pass a context and additional request options. +// +// See GetBot for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetBotWithContext(ctx aws.Context, input *GetBotInput, opts ...request.Option) (*GetBotOutput, error) { + req, out := c.GetBotRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opGetBotAlias = "GetBotAlias" + +// GetBotAliasRequest generates a "aws/request.Request" representing the +// client's request for the GetBotAlias operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetBotAlias for more information on using the GetBotAlias +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetBotAliasRequest method. +// req, resp := client.GetBotAliasRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBotAlias +func (c *LexModelBuildingService) GetBotAliasRequest(input *GetBotAliasInput) (req *request.Request, output *GetBotAliasOutput) { + op := &request.Operation{ + Name: opGetBotAlias, + HTTPMethod: "GET", + HTTPPath: "/bots/{botName}/aliases/{name}", + } + + if input == nil { + input = &GetBotAliasInput{} + } + + output = &GetBotAliasOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetBotAlias API operation for Amazon Lex Model Building Service. +// +// Returns information about an Amazon Lex bot alias. For more information about +// aliases, see versioning-aliases. +// +// This operation requires permissions for the lex:GetBotAlias action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetBotAlias for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBotAlias +func (c *LexModelBuildingService) GetBotAlias(input *GetBotAliasInput) (*GetBotAliasOutput, error) { + req, out := c.GetBotAliasRequest(input) + return out, req.Send() +} + +// GetBotAliasWithContext is the same as GetBotAlias with the addition of +// the ability to pass a context and additional request options. +// +// See GetBotAlias for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetBotAliasWithContext(ctx aws.Context, input *GetBotAliasInput, opts ...request.Option) (*GetBotAliasOutput, error) { + req, out := c.GetBotAliasRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opGetBotAliases = "GetBotAliases" + +// GetBotAliasesRequest generates a "aws/request.Request" representing the +// client's request for the GetBotAliases operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetBotAliases for more information on using the GetBotAliases +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetBotAliasesRequest method. +// req, resp := client.GetBotAliasesRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBotAliases +func (c *LexModelBuildingService) GetBotAliasesRequest(input *GetBotAliasesInput) (req *request.Request, output *GetBotAliasesOutput) { + op := &request.Operation{ + Name: opGetBotAliases, + HTTPMethod: "GET", + HTTPPath: "/bots/{botName}/aliases/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &GetBotAliasesInput{} + } + + output = &GetBotAliasesOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetBotAliases API operation for Amazon Lex Model Building Service. +// +// Returns a list of aliases for a specified Amazon Lex bot. +// +// This operation requires permissions for the lex:GetBotAliases action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetBotAliases for usage and error information. +// +// Returned Error Codes: +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBotAliases +func (c *LexModelBuildingService) GetBotAliases(input *GetBotAliasesInput) (*GetBotAliasesOutput, error) { + req, out := c.GetBotAliasesRequest(input) + return out, req.Send() +} + +// GetBotAliasesWithContext is the same as GetBotAliases with the addition of +// the ability to pass a context and additional request options. +// +// See GetBotAliases for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetBotAliasesWithContext(ctx aws.Context, input *GetBotAliasesInput, opts ...request.Option) (*GetBotAliasesOutput, error) { + req, out := c.GetBotAliasesRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// GetBotAliasesPages iterates over the pages of a GetBotAliases operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See GetBotAliases method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a GetBotAliases operation. +// pageNum := 0 +// err := client.GetBotAliasesPages(params, +// func(page *GetBotAliasesOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *LexModelBuildingService) GetBotAliasesPages(input *GetBotAliasesInput, fn func(*GetBotAliasesOutput, bool) bool) error { + return c.GetBotAliasesPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// GetBotAliasesPagesWithContext same as GetBotAliasesPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetBotAliasesPagesWithContext(ctx aws.Context, input *GetBotAliasesInput, fn func(*GetBotAliasesOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *GetBotAliasesInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.GetBotAliasesRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*GetBotAliasesOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opGetBotChannelAssociation = "GetBotChannelAssociation" + +// GetBotChannelAssociationRequest generates a "aws/request.Request" representing the +// client's request for the GetBotChannelAssociation operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetBotChannelAssociation for more information on using the GetBotChannelAssociation +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetBotChannelAssociationRequest method. +// req, resp := client.GetBotChannelAssociationRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBotChannelAssociation +func (c *LexModelBuildingService) GetBotChannelAssociationRequest(input *GetBotChannelAssociationInput) (req *request.Request, output *GetBotChannelAssociationOutput) { + op := &request.Operation{ + Name: opGetBotChannelAssociation, + HTTPMethod: "GET", + HTTPPath: "/bots/{botName}/aliases/{aliasName}/channels/{name}", + } + + if input == nil { + input = &GetBotChannelAssociationInput{} + } + + output = &GetBotChannelAssociationOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetBotChannelAssociation API operation for Amazon Lex Model Building Service. +// +// Returns information about the association between an Amazon Lex bot and a +// messaging platform. +// +// This operation requires permissions for the lex:GetBotChannelAssociation +// action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetBotChannelAssociation for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBotChannelAssociation +func (c *LexModelBuildingService) GetBotChannelAssociation(input *GetBotChannelAssociationInput) (*GetBotChannelAssociationOutput, error) { + req, out := c.GetBotChannelAssociationRequest(input) + return out, req.Send() +} + +// GetBotChannelAssociationWithContext is the same as GetBotChannelAssociation with the addition of +// the ability to pass a context and additional request options. +// +// See GetBotChannelAssociation for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetBotChannelAssociationWithContext(ctx aws.Context, input *GetBotChannelAssociationInput, opts ...request.Option) (*GetBotChannelAssociationOutput, error) { + req, out := c.GetBotChannelAssociationRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opGetBotChannelAssociations = "GetBotChannelAssociations" + +// GetBotChannelAssociationsRequest generates a "aws/request.Request" representing the +// client's request for the GetBotChannelAssociations operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetBotChannelAssociations for more information on using the GetBotChannelAssociations +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetBotChannelAssociationsRequest method. +// req, resp := client.GetBotChannelAssociationsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBotChannelAssociations +func (c *LexModelBuildingService) GetBotChannelAssociationsRequest(input *GetBotChannelAssociationsInput) (req *request.Request, output *GetBotChannelAssociationsOutput) { + op := &request.Operation{ + Name: opGetBotChannelAssociations, + HTTPMethod: "GET", + HTTPPath: "/bots/{botName}/aliases/{aliasName}/channels/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &GetBotChannelAssociationsInput{} + } + + output = &GetBotChannelAssociationsOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetBotChannelAssociations API operation for Amazon Lex Model Building Service. +// +// Returns a list of all of the channels associated with the specified bot. +// +// The GetBotChannelAssociations operation requires permissions for the lex:GetBotChannelAssociations +// action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetBotChannelAssociations for usage and error information. +// +// Returned Error Codes: +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBotChannelAssociations +func (c *LexModelBuildingService) GetBotChannelAssociations(input *GetBotChannelAssociationsInput) (*GetBotChannelAssociationsOutput, error) { + req, out := c.GetBotChannelAssociationsRequest(input) + return out, req.Send() +} + +// GetBotChannelAssociationsWithContext is the same as GetBotChannelAssociations with the addition of +// the ability to pass a context and additional request options. +// +// See GetBotChannelAssociations for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetBotChannelAssociationsWithContext(ctx aws.Context, input *GetBotChannelAssociationsInput, opts ...request.Option) (*GetBotChannelAssociationsOutput, error) { + req, out := c.GetBotChannelAssociationsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// GetBotChannelAssociationsPages iterates over the pages of a GetBotChannelAssociations operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See GetBotChannelAssociations method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a GetBotChannelAssociations operation. +// pageNum := 0 +// err := client.GetBotChannelAssociationsPages(params, +// func(page *GetBotChannelAssociationsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *LexModelBuildingService) GetBotChannelAssociationsPages(input *GetBotChannelAssociationsInput, fn func(*GetBotChannelAssociationsOutput, bool) bool) error { + return c.GetBotChannelAssociationsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// GetBotChannelAssociationsPagesWithContext same as GetBotChannelAssociationsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetBotChannelAssociationsPagesWithContext(ctx aws.Context, input *GetBotChannelAssociationsInput, fn func(*GetBotChannelAssociationsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *GetBotChannelAssociationsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.GetBotChannelAssociationsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*GetBotChannelAssociationsOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opGetBotVersions = "GetBotVersions" + +// GetBotVersionsRequest generates a "aws/request.Request" representing the +// client's request for the GetBotVersions operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetBotVersions for more information on using the GetBotVersions +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetBotVersionsRequest method. +// req, resp := client.GetBotVersionsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBotVersions +func (c *LexModelBuildingService) GetBotVersionsRequest(input *GetBotVersionsInput) (req *request.Request, output *GetBotVersionsOutput) { + op := &request.Operation{ + Name: opGetBotVersions, + HTTPMethod: "GET", + HTTPPath: "/bots/{name}/versions/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &GetBotVersionsInput{} + } + + output = &GetBotVersionsOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetBotVersions API operation for Amazon Lex Model Building Service. +// +// Gets information about all of the versions of a bot. +// +// The GetBotVersions operation returns a BotMetadata object for each version +// of a bot. For example, if a bot has three numbered versions, the GetBotVersions +// operation returns four BotMetadata objects in the response, one for each +// numbered version and one for the $LATEST version. +// +// The GetBotVersions operation always returns at least one version, the $LATEST +// version. +// +// This operation requires permissions for the lex:GetBotVersions action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetBotVersions for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBotVersions +func (c *LexModelBuildingService) GetBotVersions(input *GetBotVersionsInput) (*GetBotVersionsOutput, error) { + req, out := c.GetBotVersionsRequest(input) + return out, req.Send() +} + +// GetBotVersionsWithContext is the same as GetBotVersions with the addition of +// the ability to pass a context and additional request options. +// +// See GetBotVersions for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetBotVersionsWithContext(ctx aws.Context, input *GetBotVersionsInput, opts ...request.Option) (*GetBotVersionsOutput, error) { + req, out := c.GetBotVersionsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// GetBotVersionsPages iterates over the pages of a GetBotVersions operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See GetBotVersions method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a GetBotVersions operation. +// pageNum := 0 +// err := client.GetBotVersionsPages(params, +// func(page *GetBotVersionsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *LexModelBuildingService) GetBotVersionsPages(input *GetBotVersionsInput, fn func(*GetBotVersionsOutput, bool) bool) error { + return c.GetBotVersionsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// GetBotVersionsPagesWithContext same as GetBotVersionsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetBotVersionsPagesWithContext(ctx aws.Context, input *GetBotVersionsInput, fn func(*GetBotVersionsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *GetBotVersionsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.GetBotVersionsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*GetBotVersionsOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opGetBots = "GetBots" + +// GetBotsRequest generates a "aws/request.Request" representing the +// client's request for the GetBots operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetBots for more information on using the GetBots +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetBotsRequest method. +// req, resp := client.GetBotsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBots +func (c *LexModelBuildingService) GetBotsRequest(input *GetBotsInput) (req *request.Request, output *GetBotsOutput) { + op := &request.Operation{ + Name: opGetBots, + HTTPMethod: "GET", + HTTPPath: "/bots/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &GetBotsInput{} + } + + output = &GetBotsOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetBots API operation for Amazon Lex Model Building Service. +// +// Returns bot information as follows: +// +// * If you provide the nameContains field, the response includes information +// for the $LATEST version of all bots whose name contains the specified +// string. +// +// * If you don't specify the nameContains field, the operation returns information +// about the $LATEST version of all of your bots. +// +// This operation requires permission for the lex:GetBots action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetBots for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBots +func (c *LexModelBuildingService) GetBots(input *GetBotsInput) (*GetBotsOutput, error) { + req, out := c.GetBotsRequest(input) + return out, req.Send() +} + +// GetBotsWithContext is the same as GetBots with the addition of +// the ability to pass a context and additional request options. +// +// See GetBots for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetBotsWithContext(ctx aws.Context, input *GetBotsInput, opts ...request.Option) (*GetBotsOutput, error) { + req, out := c.GetBotsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// GetBotsPages iterates over the pages of a GetBots operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See GetBots method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a GetBots operation. +// pageNum := 0 +// err := client.GetBotsPages(params, +// func(page *GetBotsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *LexModelBuildingService) GetBotsPages(input *GetBotsInput, fn func(*GetBotsOutput, bool) bool) error { + return c.GetBotsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// GetBotsPagesWithContext same as GetBotsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetBotsPagesWithContext(ctx aws.Context, input *GetBotsInput, fn func(*GetBotsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *GetBotsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.GetBotsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*GetBotsOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opGetBuiltinIntent = "GetBuiltinIntent" + +// GetBuiltinIntentRequest generates a "aws/request.Request" representing the +// client's request for the GetBuiltinIntent operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetBuiltinIntent for more information on using the GetBuiltinIntent +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetBuiltinIntentRequest method. +// req, resp := client.GetBuiltinIntentRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBuiltinIntent +func (c *LexModelBuildingService) GetBuiltinIntentRequest(input *GetBuiltinIntentInput) (req *request.Request, output *GetBuiltinIntentOutput) { + op := &request.Operation{ + Name: opGetBuiltinIntent, + HTTPMethod: "GET", + HTTPPath: "/builtins/intents/{signature}", + } + + if input == nil { + input = &GetBuiltinIntentInput{} + } + + output = &GetBuiltinIntentOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetBuiltinIntent API operation for Amazon Lex Model Building Service. +// +// Returns information about a built-in intent. +// +// This operation requires permission for the lex:GetBuiltinIntent action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetBuiltinIntent for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBuiltinIntent +func (c *LexModelBuildingService) GetBuiltinIntent(input *GetBuiltinIntentInput) (*GetBuiltinIntentOutput, error) { + req, out := c.GetBuiltinIntentRequest(input) + return out, req.Send() +} + +// GetBuiltinIntentWithContext is the same as GetBuiltinIntent with the addition of +// the ability to pass a context and additional request options. +// +// See GetBuiltinIntent for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetBuiltinIntentWithContext(ctx aws.Context, input *GetBuiltinIntentInput, opts ...request.Option) (*GetBuiltinIntentOutput, error) { + req, out := c.GetBuiltinIntentRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opGetBuiltinIntents = "GetBuiltinIntents" + +// GetBuiltinIntentsRequest generates a "aws/request.Request" representing the +// client's request for the GetBuiltinIntents operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetBuiltinIntents for more information on using the GetBuiltinIntents +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetBuiltinIntentsRequest method. +// req, resp := client.GetBuiltinIntentsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBuiltinIntents +func (c *LexModelBuildingService) GetBuiltinIntentsRequest(input *GetBuiltinIntentsInput) (req *request.Request, output *GetBuiltinIntentsOutput) { + op := &request.Operation{ + Name: opGetBuiltinIntents, + HTTPMethod: "GET", + HTTPPath: "/builtins/intents/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &GetBuiltinIntentsInput{} + } + + output = &GetBuiltinIntentsOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetBuiltinIntents API operation for Amazon Lex Model Building Service. +// +// Gets a list of built-in intents that meet the specified criteria. +// +// This operation requires permission for the lex:GetBuiltinIntents action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetBuiltinIntents for usage and error information. +// +// Returned Error Codes: +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBuiltinIntents +func (c *LexModelBuildingService) GetBuiltinIntents(input *GetBuiltinIntentsInput) (*GetBuiltinIntentsOutput, error) { + req, out := c.GetBuiltinIntentsRequest(input) + return out, req.Send() +} + +// GetBuiltinIntentsWithContext is the same as GetBuiltinIntents with the addition of +// the ability to pass a context and additional request options. +// +// See GetBuiltinIntents for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetBuiltinIntentsWithContext(ctx aws.Context, input *GetBuiltinIntentsInput, opts ...request.Option) (*GetBuiltinIntentsOutput, error) { + req, out := c.GetBuiltinIntentsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// GetBuiltinIntentsPages iterates over the pages of a GetBuiltinIntents operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See GetBuiltinIntents method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a GetBuiltinIntents operation. +// pageNum := 0 +// err := client.GetBuiltinIntentsPages(params, +// func(page *GetBuiltinIntentsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *LexModelBuildingService) GetBuiltinIntentsPages(input *GetBuiltinIntentsInput, fn func(*GetBuiltinIntentsOutput, bool) bool) error { + return c.GetBuiltinIntentsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// GetBuiltinIntentsPagesWithContext same as GetBuiltinIntentsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetBuiltinIntentsPagesWithContext(ctx aws.Context, input *GetBuiltinIntentsInput, fn func(*GetBuiltinIntentsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *GetBuiltinIntentsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.GetBuiltinIntentsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*GetBuiltinIntentsOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opGetBuiltinSlotTypes = "GetBuiltinSlotTypes" + +// GetBuiltinSlotTypesRequest generates a "aws/request.Request" representing the +// client's request for the GetBuiltinSlotTypes operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetBuiltinSlotTypes for more information on using the GetBuiltinSlotTypes +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetBuiltinSlotTypesRequest method. +// req, resp := client.GetBuiltinSlotTypesRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBuiltinSlotTypes +func (c *LexModelBuildingService) GetBuiltinSlotTypesRequest(input *GetBuiltinSlotTypesInput) (req *request.Request, output *GetBuiltinSlotTypesOutput) { + op := &request.Operation{ + Name: opGetBuiltinSlotTypes, + HTTPMethod: "GET", + HTTPPath: "/builtins/slottypes/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &GetBuiltinSlotTypesInput{} + } + + output = &GetBuiltinSlotTypesOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetBuiltinSlotTypes API operation for Amazon Lex Model Building Service. +// +// Gets a list of built-in slot types that meet the specified criteria. +// +// For a list of built-in slot types, see Slot Type Reference (https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/docs/built-in-intent-ref/slot-type-reference) +// in the Alexa Skills Kit. +// +// This operation requires permission for the lex:GetBuiltInSlotTypes action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetBuiltinSlotTypes for usage and error information. +// +// Returned Error Codes: +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetBuiltinSlotTypes +func (c *LexModelBuildingService) GetBuiltinSlotTypes(input *GetBuiltinSlotTypesInput) (*GetBuiltinSlotTypesOutput, error) { + req, out := c.GetBuiltinSlotTypesRequest(input) + return out, req.Send() +} + +// GetBuiltinSlotTypesWithContext is the same as GetBuiltinSlotTypes with the addition of +// the ability to pass a context and additional request options. +// +// See GetBuiltinSlotTypes for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetBuiltinSlotTypesWithContext(ctx aws.Context, input *GetBuiltinSlotTypesInput, opts ...request.Option) (*GetBuiltinSlotTypesOutput, error) { + req, out := c.GetBuiltinSlotTypesRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// GetBuiltinSlotTypesPages iterates over the pages of a GetBuiltinSlotTypes operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See GetBuiltinSlotTypes method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a GetBuiltinSlotTypes operation. +// pageNum := 0 +// err := client.GetBuiltinSlotTypesPages(params, +// func(page *GetBuiltinSlotTypesOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *LexModelBuildingService) GetBuiltinSlotTypesPages(input *GetBuiltinSlotTypesInput, fn func(*GetBuiltinSlotTypesOutput, bool) bool) error { + return c.GetBuiltinSlotTypesPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// GetBuiltinSlotTypesPagesWithContext same as GetBuiltinSlotTypesPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetBuiltinSlotTypesPagesWithContext(ctx aws.Context, input *GetBuiltinSlotTypesInput, fn func(*GetBuiltinSlotTypesOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *GetBuiltinSlotTypesInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.GetBuiltinSlotTypesRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*GetBuiltinSlotTypesOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opGetExport = "GetExport" + +// GetExportRequest generates a "aws/request.Request" representing the +// client's request for the GetExport operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetExport for more information on using the GetExport +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetExportRequest method. +// req, resp := client.GetExportRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetExport +func (c *LexModelBuildingService) GetExportRequest(input *GetExportInput) (req *request.Request, output *GetExportOutput) { + op := &request.Operation{ + Name: opGetExport, + HTTPMethod: "GET", + HTTPPath: "/exports/", + } + + if input == nil { + input = &GetExportInput{} + } + + output = &GetExportOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetExport API operation for Amazon Lex Model Building Service. +// +// Exports the contents of a Amazon Lex resource in a specified format. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetExport for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetExport +func (c *LexModelBuildingService) GetExport(input *GetExportInput) (*GetExportOutput, error) { + req, out := c.GetExportRequest(input) + return out, req.Send() +} + +// GetExportWithContext is the same as GetExport with the addition of +// the ability to pass a context and additional request options. +// +// See GetExport for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetExportWithContext(ctx aws.Context, input *GetExportInput, opts ...request.Option) (*GetExportOutput, error) { + req, out := c.GetExportRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opGetImport = "GetImport" + +// GetImportRequest generates a "aws/request.Request" representing the +// client's request for the GetImport operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetImport for more information on using the GetImport +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetImportRequest method. +// req, resp := client.GetImportRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetImport +func (c *LexModelBuildingService) GetImportRequest(input *GetImportInput) (req *request.Request, output *GetImportOutput) { + op := &request.Operation{ + Name: opGetImport, + HTTPMethod: "GET", + HTTPPath: "/imports/{importId}", + } + + if input == nil { + input = &GetImportInput{} + } + + output = &GetImportOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetImport API operation for Amazon Lex Model Building Service. +// +// Gets information about an import job started with the StartImport operation. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetImport for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetImport +func (c *LexModelBuildingService) GetImport(input *GetImportInput) (*GetImportOutput, error) { + req, out := c.GetImportRequest(input) + return out, req.Send() +} + +// GetImportWithContext is the same as GetImport with the addition of +// the ability to pass a context and additional request options. +// +// See GetImport for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetImportWithContext(ctx aws.Context, input *GetImportInput, opts ...request.Option) (*GetImportOutput, error) { + req, out := c.GetImportRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opGetIntent = "GetIntent" + +// GetIntentRequest generates a "aws/request.Request" representing the +// client's request for the GetIntent operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetIntent for more information on using the GetIntent +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetIntentRequest method. +// req, resp := client.GetIntentRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetIntent +func (c *LexModelBuildingService) GetIntentRequest(input *GetIntentInput) (req *request.Request, output *GetIntentOutput) { + op := &request.Operation{ + Name: opGetIntent, + HTTPMethod: "GET", + HTTPPath: "/intents/{name}/versions/{version}", + } + + if input == nil { + input = &GetIntentInput{} + } + + output = &GetIntentOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetIntent API operation for Amazon Lex Model Building Service. +// +// Returns information about an intent. In addition to the intent name, you +// must specify the intent version. +// +// This operation requires permissions to perform the lex:GetIntent action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetIntent for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetIntent +func (c *LexModelBuildingService) GetIntent(input *GetIntentInput) (*GetIntentOutput, error) { + req, out := c.GetIntentRequest(input) + return out, req.Send() +} + +// GetIntentWithContext is the same as GetIntent with the addition of +// the ability to pass a context and additional request options. +// +// See GetIntent for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetIntentWithContext(ctx aws.Context, input *GetIntentInput, opts ...request.Option) (*GetIntentOutput, error) { + req, out := c.GetIntentRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opGetIntentVersions = "GetIntentVersions" + +// GetIntentVersionsRequest generates a "aws/request.Request" representing the +// client's request for the GetIntentVersions operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetIntentVersions for more information on using the GetIntentVersions +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetIntentVersionsRequest method. +// req, resp := client.GetIntentVersionsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetIntentVersions +func (c *LexModelBuildingService) GetIntentVersionsRequest(input *GetIntentVersionsInput) (req *request.Request, output *GetIntentVersionsOutput) { + op := &request.Operation{ + Name: opGetIntentVersions, + HTTPMethod: "GET", + HTTPPath: "/intents/{name}/versions/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &GetIntentVersionsInput{} + } + + output = &GetIntentVersionsOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetIntentVersions API operation for Amazon Lex Model Building Service. +// +// Gets information about all of the versions of an intent. +// +// The GetIntentVersions operation returns an IntentMetadata object for each +// version of an intent. For example, if an intent has three numbered versions, +// the GetIntentVersions operation returns four IntentMetadata objects in the +// response, one for each numbered version and one for the $LATEST version. +// +// The GetIntentVersions operation always returns at least one version, the +// $LATEST version. +// +// This operation requires permissions for the lex:GetIntentVersions action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetIntentVersions for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetIntentVersions +func (c *LexModelBuildingService) GetIntentVersions(input *GetIntentVersionsInput) (*GetIntentVersionsOutput, error) { + req, out := c.GetIntentVersionsRequest(input) + return out, req.Send() +} + +// GetIntentVersionsWithContext is the same as GetIntentVersions with the addition of +// the ability to pass a context and additional request options. +// +// See GetIntentVersions for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetIntentVersionsWithContext(ctx aws.Context, input *GetIntentVersionsInput, opts ...request.Option) (*GetIntentVersionsOutput, error) { + req, out := c.GetIntentVersionsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// GetIntentVersionsPages iterates over the pages of a GetIntentVersions operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See GetIntentVersions method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a GetIntentVersions operation. +// pageNum := 0 +// err := client.GetIntentVersionsPages(params, +// func(page *GetIntentVersionsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *LexModelBuildingService) GetIntentVersionsPages(input *GetIntentVersionsInput, fn func(*GetIntentVersionsOutput, bool) bool) error { + return c.GetIntentVersionsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// GetIntentVersionsPagesWithContext same as GetIntentVersionsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetIntentVersionsPagesWithContext(ctx aws.Context, input *GetIntentVersionsInput, fn func(*GetIntentVersionsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *GetIntentVersionsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.GetIntentVersionsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*GetIntentVersionsOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opGetIntents = "GetIntents" + +// GetIntentsRequest generates a "aws/request.Request" representing the +// client's request for the GetIntents operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetIntents for more information on using the GetIntents +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetIntentsRequest method. +// req, resp := client.GetIntentsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetIntents +func (c *LexModelBuildingService) GetIntentsRequest(input *GetIntentsInput) (req *request.Request, output *GetIntentsOutput) { + op := &request.Operation{ + Name: opGetIntents, + HTTPMethod: "GET", + HTTPPath: "/intents/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &GetIntentsInput{} + } + + output = &GetIntentsOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetIntents API operation for Amazon Lex Model Building Service. +// +// Returns intent information as follows: +// +// * If you specify the nameContains field, returns the $LATEST version of +// all intents that contain the specified string. +// +// * If you don't specify the nameContains field, returns information about +// the $LATEST version of all intents. +// +// The operation requires permission for the lex:GetIntents action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetIntents for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetIntents +func (c *LexModelBuildingService) GetIntents(input *GetIntentsInput) (*GetIntentsOutput, error) { + req, out := c.GetIntentsRequest(input) + return out, req.Send() +} + +// GetIntentsWithContext is the same as GetIntents with the addition of +// the ability to pass a context and additional request options. +// +// See GetIntents for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetIntentsWithContext(ctx aws.Context, input *GetIntentsInput, opts ...request.Option) (*GetIntentsOutput, error) { + req, out := c.GetIntentsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// GetIntentsPages iterates over the pages of a GetIntents operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See GetIntents method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a GetIntents operation. +// pageNum := 0 +// err := client.GetIntentsPages(params, +// func(page *GetIntentsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *LexModelBuildingService) GetIntentsPages(input *GetIntentsInput, fn func(*GetIntentsOutput, bool) bool) error { + return c.GetIntentsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// GetIntentsPagesWithContext same as GetIntentsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetIntentsPagesWithContext(ctx aws.Context, input *GetIntentsInput, fn func(*GetIntentsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *GetIntentsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.GetIntentsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*GetIntentsOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opGetSlotType = "GetSlotType" + +// GetSlotTypeRequest generates a "aws/request.Request" representing the +// client's request for the GetSlotType operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetSlotType for more information on using the GetSlotType +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetSlotTypeRequest method. +// req, resp := client.GetSlotTypeRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetSlotType +func (c *LexModelBuildingService) GetSlotTypeRequest(input *GetSlotTypeInput) (req *request.Request, output *GetSlotTypeOutput) { + op := &request.Operation{ + Name: opGetSlotType, + HTTPMethod: "GET", + HTTPPath: "/slottypes/{name}/versions/{version}", + } + + if input == nil { + input = &GetSlotTypeInput{} + } + + output = &GetSlotTypeOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetSlotType API operation for Amazon Lex Model Building Service. +// +// Returns information about a specific version of a slot type. In addition +// to specifying the slot type name, you must specify the slot type version. +// +// This operation requires permissions for the lex:GetSlotType action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetSlotType for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetSlotType +func (c *LexModelBuildingService) GetSlotType(input *GetSlotTypeInput) (*GetSlotTypeOutput, error) { + req, out := c.GetSlotTypeRequest(input) + return out, req.Send() +} + +// GetSlotTypeWithContext is the same as GetSlotType with the addition of +// the ability to pass a context and additional request options. +// +// See GetSlotType for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetSlotTypeWithContext(ctx aws.Context, input *GetSlotTypeInput, opts ...request.Option) (*GetSlotTypeOutput, error) { + req, out := c.GetSlotTypeRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opGetSlotTypeVersions = "GetSlotTypeVersions" + +// GetSlotTypeVersionsRequest generates a "aws/request.Request" representing the +// client's request for the GetSlotTypeVersions operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetSlotTypeVersions for more information on using the GetSlotTypeVersions +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetSlotTypeVersionsRequest method. +// req, resp := client.GetSlotTypeVersionsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetSlotTypeVersions +func (c *LexModelBuildingService) GetSlotTypeVersionsRequest(input *GetSlotTypeVersionsInput) (req *request.Request, output *GetSlotTypeVersionsOutput) { + op := &request.Operation{ + Name: opGetSlotTypeVersions, + HTTPMethod: "GET", + HTTPPath: "/slottypes/{name}/versions/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &GetSlotTypeVersionsInput{} + } + + output = &GetSlotTypeVersionsOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetSlotTypeVersions API operation for Amazon Lex Model Building Service. +// +// Gets information about all versions of a slot type. +// +// The GetSlotTypeVersions operation returns a SlotTypeMetadata object for each +// version of a slot type. For example, if a slot type has three numbered versions, +// the GetSlotTypeVersions operation returns four SlotTypeMetadata objects in +// the response, one for each numbered version and one for the $LATEST version. +// +// The GetSlotTypeVersions operation always returns at least one version, the +// $LATEST version. +// +// This operation requires permissions for the lex:GetSlotTypeVersions action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetSlotTypeVersions for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetSlotTypeVersions +func (c *LexModelBuildingService) GetSlotTypeVersions(input *GetSlotTypeVersionsInput) (*GetSlotTypeVersionsOutput, error) { + req, out := c.GetSlotTypeVersionsRequest(input) + return out, req.Send() +} + +// GetSlotTypeVersionsWithContext is the same as GetSlotTypeVersions with the addition of +// the ability to pass a context and additional request options. +// +// See GetSlotTypeVersions for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetSlotTypeVersionsWithContext(ctx aws.Context, input *GetSlotTypeVersionsInput, opts ...request.Option) (*GetSlotTypeVersionsOutput, error) { + req, out := c.GetSlotTypeVersionsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// GetSlotTypeVersionsPages iterates over the pages of a GetSlotTypeVersions operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See GetSlotTypeVersions method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a GetSlotTypeVersions operation. +// pageNum := 0 +// err := client.GetSlotTypeVersionsPages(params, +// func(page *GetSlotTypeVersionsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *LexModelBuildingService) GetSlotTypeVersionsPages(input *GetSlotTypeVersionsInput, fn func(*GetSlotTypeVersionsOutput, bool) bool) error { + return c.GetSlotTypeVersionsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// GetSlotTypeVersionsPagesWithContext same as GetSlotTypeVersionsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetSlotTypeVersionsPagesWithContext(ctx aws.Context, input *GetSlotTypeVersionsInput, fn func(*GetSlotTypeVersionsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *GetSlotTypeVersionsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.GetSlotTypeVersionsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*GetSlotTypeVersionsOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opGetSlotTypes = "GetSlotTypes" + +// GetSlotTypesRequest generates a "aws/request.Request" representing the +// client's request for the GetSlotTypes operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetSlotTypes for more information on using the GetSlotTypes +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetSlotTypesRequest method. +// req, resp := client.GetSlotTypesRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetSlotTypes +func (c *LexModelBuildingService) GetSlotTypesRequest(input *GetSlotTypesInput) (req *request.Request, output *GetSlotTypesOutput) { + op := &request.Operation{ + Name: opGetSlotTypes, + HTTPMethod: "GET", + HTTPPath: "/slottypes/", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &GetSlotTypesInput{} + } + + output = &GetSlotTypesOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetSlotTypes API operation for Amazon Lex Model Building Service. +// +// Returns slot type information as follows: +// +// * If you specify the nameContains field, returns the $LATEST version of +// all slot types that contain the specified string. +// +// * If you don't specify the nameContains field, returns information about +// the $LATEST version of all slot types. +// +// The operation requires permission for the lex:GetSlotTypes action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetSlotTypes for usage and error information. +// +// Returned Error Codes: +// * ErrCodeNotFoundException "NotFoundException" +// The resource specified in the request was not found. Check the resource and +// try again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetSlotTypes +func (c *LexModelBuildingService) GetSlotTypes(input *GetSlotTypesInput) (*GetSlotTypesOutput, error) { + req, out := c.GetSlotTypesRequest(input) + return out, req.Send() +} + +// GetSlotTypesWithContext is the same as GetSlotTypes with the addition of +// the ability to pass a context and additional request options. +// +// See GetSlotTypes for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetSlotTypesWithContext(ctx aws.Context, input *GetSlotTypesInput, opts ...request.Option) (*GetSlotTypesOutput, error) { + req, out := c.GetSlotTypesRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// GetSlotTypesPages iterates over the pages of a GetSlotTypes operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See GetSlotTypes method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a GetSlotTypes operation. +// pageNum := 0 +// err := client.GetSlotTypesPages(params, +// func(page *GetSlotTypesOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *LexModelBuildingService) GetSlotTypesPages(input *GetSlotTypesInput, fn func(*GetSlotTypesOutput, bool) bool) error { + return c.GetSlotTypesPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// GetSlotTypesPagesWithContext same as GetSlotTypesPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetSlotTypesPagesWithContext(ctx aws.Context, input *GetSlotTypesInput, fn func(*GetSlotTypesOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *GetSlotTypesInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.GetSlotTypesRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*GetSlotTypesOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opGetUtterancesView = "GetUtterancesView" + +// GetUtterancesViewRequest generates a "aws/request.Request" representing the +// client's request for the GetUtterancesView operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetUtterancesView for more information on using the GetUtterancesView +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetUtterancesViewRequest method. +// req, resp := client.GetUtterancesViewRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetUtterancesView +func (c *LexModelBuildingService) GetUtterancesViewRequest(input *GetUtterancesViewInput) (req *request.Request, output *GetUtterancesViewOutput) { + op := &request.Operation{ + Name: opGetUtterancesView, + HTTPMethod: "GET", + HTTPPath: "/bots/{botname}/utterances?view=aggregation", + } + + if input == nil { + input = &GetUtterancesViewInput{} + } + + output = &GetUtterancesViewOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetUtterancesView API operation for Amazon Lex Model Building Service. +// +// Use the GetUtterancesView operation to get information about the utterances +// that your users have made to your bot. You can use this list to tune the +// utterances that your bot responds to. +// +// For example, say that you have created a bot to order flowers. After your +// users have used your bot for a while, use the GetUtterancesView operation +// to see the requests that they have made and whether they have been successful. +// You might find that the utterance "I want flowers" is not being recognized. +// You could add this utterance to the OrderFlowers intent so that your bot +// recognizes that utterance. +// +// After you publish a new version of a bot, you can get information about the +// old version and the new so that you can compare the performance across the +// two versions. +// +// Utterance statistics are generated once a day. Data is available for the +// last 15 days. You can request information for up to 5 versions in each request. +// The response contains information about a maximum of 100 utterances for each +// version. +// +// This operation requires permissions for the lex:GetUtterancesView action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation GetUtterancesView for usage and error information. +// +// Returned Error Codes: +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/GetUtterancesView +func (c *LexModelBuildingService) GetUtterancesView(input *GetUtterancesViewInput) (*GetUtterancesViewOutput, error) { + req, out := c.GetUtterancesViewRequest(input) + return out, req.Send() +} + +// GetUtterancesViewWithContext is the same as GetUtterancesView with the addition of +// the ability to pass a context and additional request options. +// +// See GetUtterancesView for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) GetUtterancesViewWithContext(ctx aws.Context, input *GetUtterancesViewInput, opts ...request.Option) (*GetUtterancesViewOutput, error) { + req, out := c.GetUtterancesViewRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opPutBot = "PutBot" + +// PutBotRequest generates a "aws/request.Request" representing the +// client's request for the PutBot operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See PutBot for more information on using the PutBot +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the PutBotRequest method. +// req, resp := client.PutBotRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/PutBot +func (c *LexModelBuildingService) PutBotRequest(input *PutBotInput) (req *request.Request, output *PutBotOutput) { + op := &request.Operation{ + Name: opPutBot, + HTTPMethod: "PUT", + HTTPPath: "/bots/{name}/versions/$LATEST", + } + + if input == nil { + input = &PutBotInput{} + } + + output = &PutBotOutput{} + req = c.newRequest(op, input, output) + return +} + +// PutBot API operation for Amazon Lex Model Building Service. +// +// Creates an Amazon Lex conversational bot or replaces an existing bot. When +// you create or update a bot you are only required to specify a name, a locale, +// and whether the bot is directed toward children under age 13. You can use +// this to add intents later, or to remove intents from an existing bot. When +// you create a bot with the minimum information, the bot is created or updated +// but Amazon Lex returns the response FAILED. You can build the bot after you add one or more intents. For more information +// about Amazon Lex bots, see how-it-works. +// +// If you specify the name of an existing bot, the fields in the request replace +// the existing values in the $LATESTversion of the bot. Amazon Lex removes any fields that you don't provide +// values for in the request, except for the idleTTLInSecondsand privacySettingsfields, which are set to their default values. If you don't specify values +// for required fields, Amazon Lex throws an exception. +// +// This operation requires permissions for the lex:PutBotaction. For more information, see auth-and-access-control +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation PutBot for usage and error information. +// +// Returned Error Codes: +// * ErrCodeConflictException "ConflictException" +// There was a conflict processing the request. Try your request again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// * ErrCodePreconditionFailedException "PreconditionFailedException" +// The checksum of the resource that you are trying to change does not match +// the checksum in the request. Check the resource's checksum and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/PutBot +func (c *LexModelBuildingService) PutBot(input *PutBotInput) (*PutBotOutput, error) { + req, out := c.PutBotRequest(input) + return out, req.Send() +} + +// PutBotWithContext is the same as PutBot with the addition of +// the ability to pass a context and additional request options. +// +// See PutBot for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) PutBotWithContext(ctx aws.Context, input *PutBotInput, opts ...request.Option) (*PutBotOutput, error) { + req, out := c.PutBotRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opPutBotAlias = "PutBotAlias" + +// PutBotAliasRequest generates a "aws/request.Request" representing the +// client's request for the PutBotAlias operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See PutBotAlias for more information on using the PutBotAlias +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the PutBotAliasRequest method. +// req, resp := client.PutBotAliasRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/PutBotAlias +func (c *LexModelBuildingService) PutBotAliasRequest(input *PutBotAliasInput) (req *request.Request, output *PutBotAliasOutput) { + op := &request.Operation{ + Name: opPutBotAlias, + HTTPMethod: "PUT", + HTTPPath: "/bots/{botName}/aliases/{name}", + } + + if input == nil { + input = &PutBotAliasInput{} + } + + output = &PutBotAliasOutput{} + req = c.newRequest(op, input, output) + return +} + +// PutBotAlias API operation for Amazon Lex Model Building Service. +// +// Creates an alias for the specified version of the bot or replaces an alias +// for the specified bot. To change the version of the bot that the alias points +// to, replace the alias. For more information about aliases, see versioning-aliases. +// +// This operation requires permissions for the lex:PutBotAlias action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation PutBotAlias for usage and error information. +// +// Returned Error Codes: +// * ErrCodeConflictException "ConflictException" +// There was a conflict processing the request. Try your request again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// * ErrCodePreconditionFailedException "PreconditionFailedException" +// The checksum of the resource that you are trying to change does not match +// the checksum in the request. Check the resource's checksum and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/PutBotAlias +func (c *LexModelBuildingService) PutBotAlias(input *PutBotAliasInput) (*PutBotAliasOutput, error) { + req, out := c.PutBotAliasRequest(input) + return out, req.Send() +} + +// PutBotAliasWithContext is the same as PutBotAlias with the addition of +// the ability to pass a context and additional request options. +// +// See PutBotAlias for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) PutBotAliasWithContext(ctx aws.Context, input *PutBotAliasInput, opts ...request.Option) (*PutBotAliasOutput, error) { + req, out := c.PutBotAliasRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opPutIntent = "PutIntent" + +// PutIntentRequest generates a "aws/request.Request" representing the +// client's request for the PutIntent operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See PutIntent for more information on using the PutIntent +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the PutIntentRequest method. +// req, resp := client.PutIntentRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/PutIntent +func (c *LexModelBuildingService) PutIntentRequest(input *PutIntentInput) (req *request.Request, output *PutIntentOutput) { + op := &request.Operation{ + Name: opPutIntent, + HTTPMethod: "PUT", + HTTPPath: "/intents/{name}/versions/$LATEST", + } + + if input == nil { + input = &PutIntentInput{} + } + + output = &PutIntentOutput{} + req = c.newRequest(op, input, output) + return +} + +// PutIntent API operation for Amazon Lex Model Building Service. +// +// Creates an intent or replaces an existing intent. +// +// To define the interaction between the user and your bot, you use one or more +// intents. For a pizza ordering bot, for example, you would create an OrderPizza +// intent. +// +// To create an intent or replace an existing intent, you must provide the following: +// +// * Intent name. For example, OrderPizza. +// +// * Sample utterances. For example, "Can I order a pizza, please." and "I +// want to order a pizza." +// +// * Information to be gathered. You specify slot types for the information +// that your bot will request from the user. You can specify standard slot +// types, such as a date or a time, or custom slot types such as the size +// and crust of a pizza. +// +// * How the intent will be fulfilled. You can provide a Lambda function +// or configure the intent to return the intent information to the client +// application. If you use a Lambda function, when all of the intent information +// is available, Amazon Lex invokes your Lambda function. If you configure +// your intent to return the intent information to the client application. +// +// +// You can specify other optional information in the request, such as: +// +// * A confirmation prompt to ask the user to confirm an intent. For example, +// "Shall I order your pizza?" +// +// * A conclusion statement to send to the user after the intent has been +// fulfilled. For example, "I placed your pizza order." +// +// * A follow-up prompt that asks the user for additional activity. For example, +// asking "Do you want to order a drink with your pizza?" +// +// If you specify an existing intent name to update the intent, Amazon Lex replaces +// the values in the $LATEST version of the intent with the values in the request. +// Amazon Lex removes fields that you don't provide in the request. If you don't +// specify the required fields, Amazon Lex throws an exception. When you update +// the $LATEST version of an intent, the status field of any bot that uses the +// $LATEST version of the intent is set to NOT_BUILT. +// +// For more information, see how-it-works. +// +// This operation requires permissions for the lex:PutIntent action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation PutIntent for usage and error information. +// +// Returned Error Codes: +// * ErrCodeConflictException "ConflictException" +// There was a conflict processing the request. Try your request again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// * ErrCodePreconditionFailedException "PreconditionFailedException" +// The checksum of the resource that you are trying to change does not match +// the checksum in the request. Check the resource's checksum and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/PutIntent +func (c *LexModelBuildingService) PutIntent(input *PutIntentInput) (*PutIntentOutput, error) { + req, out := c.PutIntentRequest(input) + return out, req.Send() +} + +// PutIntentWithContext is the same as PutIntent with the addition of +// the ability to pass a context and additional request options. +// +// See PutIntent for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) PutIntentWithContext(ctx aws.Context, input *PutIntentInput, opts ...request.Option) (*PutIntentOutput, error) { + req, out := c.PutIntentRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opPutSlotType = "PutSlotType" + +// PutSlotTypeRequest generates a "aws/request.Request" representing the +// client's request for the PutSlotType operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See PutSlotType for more information on using the PutSlotType +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the PutSlotTypeRequest method. +// req, resp := client.PutSlotTypeRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/PutSlotType +func (c *LexModelBuildingService) PutSlotTypeRequest(input *PutSlotTypeInput) (req *request.Request, output *PutSlotTypeOutput) { + op := &request.Operation{ + Name: opPutSlotType, + HTTPMethod: "PUT", + HTTPPath: "/slottypes/{name}/versions/$LATEST", + } + + if input == nil { + input = &PutSlotTypeInput{} + } + + output = &PutSlotTypeOutput{} + req = c.newRequest(op, input, output) + return +} + +// PutSlotType API operation for Amazon Lex Model Building Service. +// +// Creates a custom slot type or replaces an existing custom slot type. +// +// To create a custom slot type, specify a name for the slot type and a set +// of enumeration values, which are the values that a slot of this type can +// assume. For more information, see how-it-works. +// +// If you specify the name of an existing slot type, the fields in the request +// replace the existing values in the $LATEST version of the slot type. Amazon +// Lex removes the fields that you don't provide in the request. If you don't +// specify required fields, Amazon Lex throws an exception. When you update +// the $LATEST version of a slot type, if a bot uses the $LATEST version of +// an intent that contains the slot type, the bot's status field is set to NOT_BUILT. +// +// This operation requires permissions for the lex:PutSlotType action. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation PutSlotType for usage and error information. +// +// Returned Error Codes: +// * ErrCodeConflictException "ConflictException" +// There was a conflict processing the request. Try your request again. +// +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// * ErrCodePreconditionFailedException "PreconditionFailedException" +// The checksum of the resource that you are trying to change does not match +// the checksum in the request. Check the resource's checksum and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/PutSlotType +func (c *LexModelBuildingService) PutSlotType(input *PutSlotTypeInput) (*PutSlotTypeOutput, error) { + req, out := c.PutSlotTypeRequest(input) + return out, req.Send() +} + +// PutSlotTypeWithContext is the same as PutSlotType with the addition of +// the ability to pass a context and additional request options. +// +// See PutSlotType for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) PutSlotTypeWithContext(ctx aws.Context, input *PutSlotTypeInput, opts ...request.Option) (*PutSlotTypeOutput, error) { + req, out := c.PutSlotTypeRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opStartImport = "StartImport" + +// StartImportRequest generates a "aws/request.Request" representing the +// client's request for the StartImport operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See StartImport for more information on using the StartImport +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the StartImportRequest method. +// req, resp := client.StartImportRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/StartImport +func (c *LexModelBuildingService) StartImportRequest(input *StartImportInput) (req *request.Request, output *StartImportOutput) { + op := &request.Operation{ + Name: opStartImport, + HTTPMethod: "POST", + HTTPPath: "/imports/", + } + + if input == nil { + input = &StartImportInput{} + } + + output = &StartImportOutput{} + req = c.newRequest(op, input, output) + return +} + +// StartImport API operation for Amazon Lex Model Building Service. +// +// Starts a job to import a resource to Amazon Lex. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Lex Model Building Service's +// API operation StartImport for usage and error information. +// +// Returned Error Codes: +// * ErrCodeLimitExceededException "LimitExceededException" +// The request exceeded a limit. Try your request again. +// +// * ErrCodeInternalFailureException "InternalFailureException" +// An internal Amazon Lex error occurred. Try your request again. +// +// * ErrCodeBadRequestException "BadRequestException" +// The request is not well formed. For example, a value is invalid or a required +// field is missing. Check the field values, and try again. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19/StartImport +func (c *LexModelBuildingService) StartImport(input *StartImportInput) (*StartImportOutput, error) { + req, out := c.StartImportRequest(input) + return out, req.Send() +} + +// StartImportWithContext is the same as StartImport with the addition of +// the ability to pass a context and additional request options. +// +// See StartImport for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *LexModelBuildingService) StartImportWithContext(ctx aws.Context, input *StartImportInput, opts ...request.Option) (*StartImportOutput, error) { + req, out := c.StartImportRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// Provides information about a bot alias. +type BotAliasMetadata struct { + _ struct{} `type:"structure"` + + // The name of the bot to which the alias points. + BotName *string `locationName:"botName" min:"2" type:"string"` + + // The version of the Amazon Lex bot to which the alias points. + BotVersion *string `locationName:"botVersion" min:"1" type:"string"` + + // Checksum of the bot alias. + Checksum *string `locationName:"checksum" type:"string"` + + // The date that the bot alias was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A description of the bot alias. + Description *string `locationName:"description" type:"string"` + + // The date that the bot alias was updated. When you create a resource, the + // creation date and last updated date are the same. + LastUpdatedDate *time.Time `locationName:"lastUpdatedDate" type:"timestamp" timestampFormat:"unix"` + + // The name of the bot alias. + Name *string `locationName:"name" min:"1" type:"string"` +} + +// String returns the string representation +func (s BotAliasMetadata) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s BotAliasMetadata) GoString() string { + return s.String() +} + +// SetBotName sets the BotName field's value. +func (s *BotAliasMetadata) SetBotName(v string) *BotAliasMetadata { + s.BotName = &v + return s +} + +// SetBotVersion sets the BotVersion field's value. +func (s *BotAliasMetadata) SetBotVersion(v string) *BotAliasMetadata { + s.BotVersion = &v + return s +} + +// SetChecksum sets the Checksum field's value. +func (s *BotAliasMetadata) SetChecksum(v string) *BotAliasMetadata { + s.Checksum = &v + return s +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *BotAliasMetadata) SetCreatedDate(v time.Time) *BotAliasMetadata { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *BotAliasMetadata) SetDescription(v string) *BotAliasMetadata { + s.Description = &v + return s +} + +// SetLastUpdatedDate sets the LastUpdatedDate field's value. +func (s *BotAliasMetadata) SetLastUpdatedDate(v time.Time) *BotAliasMetadata { + s.LastUpdatedDate = &v + return s +} + +// SetName sets the Name field's value. +func (s *BotAliasMetadata) SetName(v string) *BotAliasMetadata { + s.Name = &v + return s +} + +// Represents an association between an Amazon Lex bot and an external messaging +// platform. +type BotChannelAssociation struct { + _ struct{} `type:"structure"` + + // An alias pointing to the specific version of the Amazon Lex bot to which + // this association is being made. + BotAlias *string `locationName:"botAlias" min:"1" type:"string"` + + // Provides information necessary to communicate with the messaging platform. + BotConfiguration map[string]*string `locationName:"botConfiguration" min:"1" type:"map"` + + // The name of the Amazon Lex bot to which this association is being made. + // + // Currently, Amazon Lex supports associations with Facebook and Slack, and + // Twilio. + BotName *string `locationName:"botName" min:"2" type:"string"` + + // The date that the association between the Amazon Lex bot and the channel + // was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A text description of the association you are creating. + Description *string `locationName:"description" type:"string"` + + // If status is FAILED, Amazon Lex provides the reason that it failed to create + // the association. + FailureReason *string `locationName:"failureReason" type:"string"` + + // The name of the association between the bot and the channel. + Name *string `locationName:"name" min:"1" type:"string"` + + // The status of the bot channel. + // + // * CREATED - The channel has been created and is ready for use. + // + // * IN_PROGRESS - Channel creation is in progress. + // + // * FAILED - There was an error creating the channel. For information about + // the reason for the failure, see the failureReason field. + Status *string `locationName:"status" type:"string" enum:"ChannelStatus"` + + // Specifies the type of association by indicating the type of channel being + // established between the Amazon Lex bot and the external messaging platform. + Type *string `locationName:"type" type:"string" enum:"ChannelType"` +} + +// String returns the string representation +func (s BotChannelAssociation) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s BotChannelAssociation) GoString() string { + return s.String() +} + +// SetBotAlias sets the BotAlias field's value. +func (s *BotChannelAssociation) SetBotAlias(v string) *BotChannelAssociation { + s.BotAlias = &v + return s +} + +// SetBotConfiguration sets the BotConfiguration field's value. +func (s *BotChannelAssociation) SetBotConfiguration(v map[string]*string) *BotChannelAssociation { + s.BotConfiguration = v + return s +} + +// SetBotName sets the BotName field's value. +func (s *BotChannelAssociation) SetBotName(v string) *BotChannelAssociation { + s.BotName = &v + return s +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *BotChannelAssociation) SetCreatedDate(v time.Time) *BotChannelAssociation { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *BotChannelAssociation) SetDescription(v string) *BotChannelAssociation { + s.Description = &v + return s +} + +// SetFailureReason sets the FailureReason field's value. +func (s *BotChannelAssociation) SetFailureReason(v string) *BotChannelAssociation { + s.FailureReason = &v + return s +} + +// SetName sets the Name field's value. +func (s *BotChannelAssociation) SetName(v string) *BotChannelAssociation { + s.Name = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *BotChannelAssociation) SetStatus(v string) *BotChannelAssociation { + s.Status = &v + return s +} + +// SetType sets the Type field's value. +func (s *BotChannelAssociation) SetType(v string) *BotChannelAssociation { + s.Type = &v + return s +} + +// Provides information about a bot. . +type BotMetadata struct { + _ struct{} `type:"structure"` + + // The date that the bot was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A description of the bot. + Description *string `locationName:"description" type:"string"` + + // The date that the bot was updated. When you create a bot, the creation date + // and last updated date are the same. + LastUpdatedDate *time.Time `locationName:"lastUpdatedDate" type:"timestamp" timestampFormat:"unix"` + + // The name of the bot. + Name *string `locationName:"name" min:"2" type:"string"` + + // The status of the bot. + Status *string `locationName:"status" type:"string" enum:"Status"` + + // The version of the bot. For a new bot, the version is always $LATEST. + Version *string `locationName:"version" min:"1" type:"string"` +} + +// String returns the string representation +func (s BotMetadata) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s BotMetadata) GoString() string { + return s.String() +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *BotMetadata) SetCreatedDate(v time.Time) *BotMetadata { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *BotMetadata) SetDescription(v string) *BotMetadata { + s.Description = &v + return s +} + +// SetLastUpdatedDate sets the LastUpdatedDate field's value. +func (s *BotMetadata) SetLastUpdatedDate(v time.Time) *BotMetadata { + s.LastUpdatedDate = &v + return s +} + +// SetName sets the Name field's value. +func (s *BotMetadata) SetName(v string) *BotMetadata { + s.Name = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *BotMetadata) SetStatus(v string) *BotMetadata { + s.Status = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *BotMetadata) SetVersion(v string) *BotMetadata { + s.Version = &v + return s +} + +// Provides metadata for a built-in intent. +type BuiltinIntentMetadata struct { + _ struct{} `type:"structure"` + + // A unique identifier for the built-in intent. To find the signature for an + // intent, see Standard Built-in Intents (https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/docs/built-in-intent-ref/standard-intents) + // in the Alexa Skills Kit. + Signature *string `locationName:"signature" type:"string"` + + // A list of identifiers for the locales that the intent supports. + SupportedLocales []*string `locationName:"supportedLocales" type:"list"` +} + +// String returns the string representation +func (s BuiltinIntentMetadata) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s BuiltinIntentMetadata) GoString() string { + return s.String() +} + +// SetSignature sets the Signature field's value. +func (s *BuiltinIntentMetadata) SetSignature(v string) *BuiltinIntentMetadata { + s.Signature = &v + return s +} + +// SetSupportedLocales sets the SupportedLocales field's value. +func (s *BuiltinIntentMetadata) SetSupportedLocales(v []*string) *BuiltinIntentMetadata { + s.SupportedLocales = v + return s +} + +// Provides information about a slot used in a built-in intent. +type BuiltinIntentSlot struct { + _ struct{} `type:"structure"` + + // A list of the slots defined for the intent. + Name *string `locationName:"name" type:"string"` +} + +// String returns the string representation +func (s BuiltinIntentSlot) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s BuiltinIntentSlot) GoString() string { + return s.String() +} + +// SetName sets the Name field's value. +func (s *BuiltinIntentSlot) SetName(v string) *BuiltinIntentSlot { + s.Name = &v + return s +} + +// Provides information about a built in slot type. +type BuiltinSlotTypeMetadata struct { + _ struct{} `type:"structure"` + + // A unique identifier for the built-in slot type. To find the signature for + // a slot type, see Slot Type Reference (https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/docs/built-in-intent-ref/slot-type-reference) + // in the Alexa Skills Kit. + Signature *string `locationName:"signature" type:"string"` + + // A list of target locales for the slot. + SupportedLocales []*string `locationName:"supportedLocales" type:"list"` +} + +// String returns the string representation +func (s BuiltinSlotTypeMetadata) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s BuiltinSlotTypeMetadata) GoString() string { + return s.String() +} + +// SetSignature sets the Signature field's value. +func (s *BuiltinSlotTypeMetadata) SetSignature(v string) *BuiltinSlotTypeMetadata { + s.Signature = &v + return s +} + +// SetSupportedLocales sets the SupportedLocales field's value. +func (s *BuiltinSlotTypeMetadata) SetSupportedLocales(v []*string) *BuiltinSlotTypeMetadata { + s.SupportedLocales = v + return s +} + +// Specifies a Lambda function that verifies requests to a bot or fulfills the +// user's request to a bot.. +type CodeHook struct { + _ struct{} `type:"structure"` + + // The version of the request-response that you want Amazon Lex to use to invoke + // your Lambda function. For more information, see using-lambda. + // + // MessageVersion is a required field + MessageVersion *string `locationName:"messageVersion" min:"1" type:"string" required:"true"` + + // The Amazon Resource Name (ARN) of the Lambda function. + // + // Uri is a required field + Uri *string `locationName:"uri" min:"20" type:"string" required:"true"` +} + +// String returns the string representation +func (s CodeHook) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CodeHook) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CodeHook) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CodeHook"} + if s.MessageVersion == nil { + invalidParams.Add(request.NewErrParamRequired("MessageVersion")) + } + if s.MessageVersion != nil && len(*s.MessageVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("MessageVersion", 1)) + } + if s.Uri == nil { + invalidParams.Add(request.NewErrParamRequired("Uri")) + } + if s.Uri != nil && len(*s.Uri) < 20 { + invalidParams.Add(request.NewErrParamMinLen("Uri", 20)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMessageVersion sets the MessageVersion field's value. +func (s *CodeHook) SetMessageVersion(v string) *CodeHook { + s.MessageVersion = &v + return s +} + +// SetUri sets the Uri field's value. +func (s *CodeHook) SetUri(v string) *CodeHook { + s.Uri = &v + return s +} + +type CreateBotVersionInput struct { + _ struct{} `type:"structure"` + + // Identifies a specific revision of the $LATEST version of the bot. If you + // specify a checksum and the $LATEST version of the bot has a different checksum, + // a PreconditionFailedException exception is returned and Amazon Lex doesn't + // publish a new version. If you don't specify a checksum, Amazon Lex publishes + // the $LATEST version. + Checksum *string `locationName:"checksum" type:"string"` + + // The name of the bot that you want to create a new version of. The name is + // case sensitive. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"2" type:"string" required:"true"` +} + +// String returns the string representation +func (s CreateBotVersionInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateBotVersionInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateBotVersionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateBotVersionInput"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Name", 2)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetChecksum sets the Checksum field's value. +func (s *CreateBotVersionInput) SetChecksum(v string) *CreateBotVersionInput { + s.Checksum = &v + return s +} + +// SetName sets the Name field's value. +func (s *CreateBotVersionInput) SetName(v string) *CreateBotVersionInput { + s.Name = &v + return s +} + +type CreateBotVersionOutput struct { + _ struct{} `type:"structure"` + + // The message that Amazon Lex uses to abort a conversation. For more information, + // see PutBot. + AbortStatement *Statement `locationName:"abortStatement" type:"structure"` + + // Checksum identifying the version of the bot that was created. + Checksum *string `locationName:"checksum" type:"string"` + + // For each Amazon Lex bot created with the Amazon Lex Model Building Service, + // you must specify whether your use of Amazon Lex is related to a website, + // program, or other application that is directed or targeted, in whole or in + // part, to children under age 13 and subject to the Children's Online Privacy + // Protection Act (COPPA) by specifying true or false in the childDirected field. + // By specifying true in the childDirected field, you confirm that your use + // of Amazon Lex is related to a website, program, or other application that + // is directed or targeted, in whole or in part, to children under age 13 and + // subject to COPPA. By specifying false in the childDirected field, you confirm + // that your use of Amazon Lex is not related to a website, program, or other + // application that is directed or targeted, in whole or in part, to children + // under age 13 and subject to COPPA. You may not specify a default value for + // the childDirected field that does not accurately reflect whether your use + // of Amazon Lex is related to a website, program, or other application that + // is directed or targeted, in whole or in part, to children under age 13 and + // subject to COPPA. + // + // If your use of Amazon Lex relates to a website, program, or other application + // that is directed in whole or in part, to children under age 13, you must + // obtain any required verifiable parental consent under COPPA. For information + // regarding the use of Amazon Lex in connection with websites, programs, or + // other applications that are directed or targeted, in whole or in part, to + // children under age 13, see the Amazon Lex FAQ. (https://aws.amazon.com/lex/faqs#data-security) + ChildDirected *bool `locationName:"childDirected" type:"boolean"` + + // The message that Amazon Lex uses when it doesn't understand the user's request. + // For more information, see PutBot. + ClarificationPrompt *Prompt `locationName:"clarificationPrompt" type:"structure"` + + // The date when the bot version was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A description of the bot. + Description *string `locationName:"description" type:"string"` + + // If status is FAILED, Amazon Lex provides the reason that it failed to build + // the bot. + FailureReason *string `locationName:"failureReason" type:"string"` + + // The maximum time in seconds that Amazon Lex retains the data gathered in + // a conversation. For more information, see PutBot. + IdleSessionTTLInSeconds *int64 `locationName:"idleSessionTTLInSeconds" min:"60" type:"integer"` + + // An array of Intent objects. For more information, see PutBot. + Intents []*Intent `locationName:"intents" type:"list"` + + // The date when the $LATEST version of this bot was updated. + LastUpdatedDate *time.Time `locationName:"lastUpdatedDate" type:"timestamp" timestampFormat:"unix"` + + // Specifies the target locale for the bot. + Locale *string `locationName:"locale" type:"string" enum:"Locale"` + + // The name of the bot. + Name *string `locationName:"name" min:"2" type:"string"` + + // When you send a request to create or update a bot, Amazon Lex sets the status + // response element to BUILDING. After Amazon Lex builds the bot, it sets status + // to READY. If Amazon Lex can't build the bot, it sets status to FAILED. Amazon + // Lex returns the reason for the failure in the failureReason response element. + Status *string `locationName:"status" type:"string" enum:"Status"` + + // The version of the bot. + Version *string `locationName:"version" min:"1" type:"string"` + + // The Amazon Polly voice ID that Amazon Lex uses for voice interactions with + // the user. + VoiceId *string `locationName:"voiceId" type:"string"` +} + +// String returns the string representation +func (s CreateBotVersionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateBotVersionOutput) GoString() string { + return s.String() +} + +// SetAbortStatement sets the AbortStatement field's value. +func (s *CreateBotVersionOutput) SetAbortStatement(v *Statement) *CreateBotVersionOutput { + s.AbortStatement = v + return s +} + +// SetChecksum sets the Checksum field's value. +func (s *CreateBotVersionOutput) SetChecksum(v string) *CreateBotVersionOutput { + s.Checksum = &v + return s +} + +// SetChildDirected sets the ChildDirected field's value. +func (s *CreateBotVersionOutput) SetChildDirected(v bool) *CreateBotVersionOutput { + s.ChildDirected = &v + return s +} + +// SetClarificationPrompt sets the ClarificationPrompt field's value. +func (s *CreateBotVersionOutput) SetClarificationPrompt(v *Prompt) *CreateBotVersionOutput { + s.ClarificationPrompt = v + return s +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *CreateBotVersionOutput) SetCreatedDate(v time.Time) *CreateBotVersionOutput { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreateBotVersionOutput) SetDescription(v string) *CreateBotVersionOutput { + s.Description = &v + return s +} + +// SetFailureReason sets the FailureReason field's value. +func (s *CreateBotVersionOutput) SetFailureReason(v string) *CreateBotVersionOutput { + s.FailureReason = &v + return s +} + +// SetIdleSessionTTLInSeconds sets the IdleSessionTTLInSeconds field's value. +func (s *CreateBotVersionOutput) SetIdleSessionTTLInSeconds(v int64) *CreateBotVersionOutput { + s.IdleSessionTTLInSeconds = &v + return s +} + +// SetIntents sets the Intents field's value. +func (s *CreateBotVersionOutput) SetIntents(v []*Intent) *CreateBotVersionOutput { + s.Intents = v + return s +} + +// SetLastUpdatedDate sets the LastUpdatedDate field's value. +func (s *CreateBotVersionOutput) SetLastUpdatedDate(v time.Time) *CreateBotVersionOutput { + s.LastUpdatedDate = &v + return s +} + +// SetLocale sets the Locale field's value. +func (s *CreateBotVersionOutput) SetLocale(v string) *CreateBotVersionOutput { + s.Locale = &v + return s +} + +// SetName sets the Name field's value. +func (s *CreateBotVersionOutput) SetName(v string) *CreateBotVersionOutput { + s.Name = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *CreateBotVersionOutput) SetStatus(v string) *CreateBotVersionOutput { + s.Status = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *CreateBotVersionOutput) SetVersion(v string) *CreateBotVersionOutput { + s.Version = &v + return s +} + +// SetVoiceId sets the VoiceId field's value. +func (s *CreateBotVersionOutput) SetVoiceId(v string) *CreateBotVersionOutput { + s.VoiceId = &v + return s +} + +type CreateIntentVersionInput struct { + _ struct{} `type:"structure"` + + // Checksum of the $LATEST version of the intent that should be used to create + // the new version. If you specify a checksum and the $LATEST version of the + // intent has a different checksum, Amazon Lex returns a PreconditionFailedException + // exception and doesn't publish a new version. If you don't specify a checksum, + // Amazon Lex publishes the $LATEST version. + Checksum *string `locationName:"checksum" type:"string"` + + // The name of the intent that you want to create a new version of. The name + // is case sensitive. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s CreateIntentVersionInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateIntentVersionInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateIntentVersionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateIntentVersionInput"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetChecksum sets the Checksum field's value. +func (s *CreateIntentVersionInput) SetChecksum(v string) *CreateIntentVersionInput { + s.Checksum = &v + return s +} + +// SetName sets the Name field's value. +func (s *CreateIntentVersionInput) SetName(v string) *CreateIntentVersionInput { + s.Name = &v + return s +} + +type CreateIntentVersionOutput struct { + _ struct{} `type:"structure"` + + // Checksum of the intent version created. + Checksum *string `locationName:"checksum" type:"string"` + + // After the Lambda function specified in the fulfillmentActivity field fulfills + // the intent, Amazon Lex conveys this statement to the user. + ConclusionStatement *Statement `locationName:"conclusionStatement" type:"structure"` + + // If defined, the prompt that Amazon Lex uses to confirm the user's intent + // before fulfilling it. + ConfirmationPrompt *Prompt `locationName:"confirmationPrompt" type:"structure"` + + // The date that the intent was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A description of the intent. + Description *string `locationName:"description" type:"string"` + + // If defined, Amazon Lex invokes this Lambda function for each user input. + DialogCodeHook *CodeHook `locationName:"dialogCodeHook" type:"structure"` + + // If defined, Amazon Lex uses this prompt to solicit additional user activity + // after the intent is fulfilled. + FollowUpPrompt *FollowUpPrompt `locationName:"followUpPrompt" type:"structure"` + + // Describes how the intent is fulfilled. + FulfillmentActivity *FulfillmentActivity `locationName:"fulfillmentActivity" type:"structure"` + + // The date that the intent was updated. + LastUpdatedDate *time.Time `locationName:"lastUpdatedDate" type:"timestamp" timestampFormat:"unix"` + + // The name of the intent. + Name *string `locationName:"name" min:"1" type:"string"` + + // A unique identifier for a built-in intent. + ParentIntentSignature *string `locationName:"parentIntentSignature" type:"string"` + + // If the user answers "no" to the question defined in confirmationPrompt, Amazon + // Lex responds with this statement to acknowledge that the intent was canceled. + RejectionStatement *Statement `locationName:"rejectionStatement" type:"structure"` + + // An array of sample utterances configured for the intent. + SampleUtterances []*string `locationName:"sampleUtterances" type:"list"` + + // An array of slot types that defines the information required to fulfill the + // intent. + Slots []*Slot `locationName:"slots" type:"list"` + + // The version number assigned to the new version of the intent. + Version *string `locationName:"version" min:"1" type:"string"` +} + +// String returns the string representation +func (s CreateIntentVersionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateIntentVersionOutput) GoString() string { + return s.String() +} + +// SetChecksum sets the Checksum field's value. +func (s *CreateIntentVersionOutput) SetChecksum(v string) *CreateIntentVersionOutput { + s.Checksum = &v + return s +} + +// SetConclusionStatement sets the ConclusionStatement field's value. +func (s *CreateIntentVersionOutput) SetConclusionStatement(v *Statement) *CreateIntentVersionOutput { + s.ConclusionStatement = v + return s +} + +// SetConfirmationPrompt sets the ConfirmationPrompt field's value. +func (s *CreateIntentVersionOutput) SetConfirmationPrompt(v *Prompt) *CreateIntentVersionOutput { + s.ConfirmationPrompt = v + return s +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *CreateIntentVersionOutput) SetCreatedDate(v time.Time) *CreateIntentVersionOutput { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreateIntentVersionOutput) SetDescription(v string) *CreateIntentVersionOutput { + s.Description = &v + return s +} + +// SetDialogCodeHook sets the DialogCodeHook field's value. +func (s *CreateIntentVersionOutput) SetDialogCodeHook(v *CodeHook) *CreateIntentVersionOutput { + s.DialogCodeHook = v + return s +} + +// SetFollowUpPrompt sets the FollowUpPrompt field's value. +func (s *CreateIntentVersionOutput) SetFollowUpPrompt(v *FollowUpPrompt) *CreateIntentVersionOutput { + s.FollowUpPrompt = v + return s +} + +// SetFulfillmentActivity sets the FulfillmentActivity field's value. +func (s *CreateIntentVersionOutput) SetFulfillmentActivity(v *FulfillmentActivity) *CreateIntentVersionOutput { + s.FulfillmentActivity = v + return s +} + +// SetLastUpdatedDate sets the LastUpdatedDate field's value. +func (s *CreateIntentVersionOutput) SetLastUpdatedDate(v time.Time) *CreateIntentVersionOutput { + s.LastUpdatedDate = &v + return s +} + +// SetName sets the Name field's value. +func (s *CreateIntentVersionOutput) SetName(v string) *CreateIntentVersionOutput { + s.Name = &v + return s +} + +// SetParentIntentSignature sets the ParentIntentSignature field's value. +func (s *CreateIntentVersionOutput) SetParentIntentSignature(v string) *CreateIntentVersionOutput { + s.ParentIntentSignature = &v + return s +} + +// SetRejectionStatement sets the RejectionStatement field's value. +func (s *CreateIntentVersionOutput) SetRejectionStatement(v *Statement) *CreateIntentVersionOutput { + s.RejectionStatement = v + return s +} + +// SetSampleUtterances sets the SampleUtterances field's value. +func (s *CreateIntentVersionOutput) SetSampleUtterances(v []*string) *CreateIntentVersionOutput { + s.SampleUtterances = v + return s +} + +// SetSlots sets the Slots field's value. +func (s *CreateIntentVersionOutput) SetSlots(v []*Slot) *CreateIntentVersionOutput { + s.Slots = v + return s +} + +// SetVersion sets the Version field's value. +func (s *CreateIntentVersionOutput) SetVersion(v string) *CreateIntentVersionOutput { + s.Version = &v + return s +} + +type CreateSlotTypeVersionInput struct { + _ struct{} `type:"structure"` + + // Checksum for the $LATEST version of the slot type that you want to publish. + // If you specify a checksum and the $LATEST version of the slot type has a + // different checksum, Amazon Lex returns a PreconditionFailedException exception + // and doesn't publish the new version. If you don't specify a checksum, Amazon + // Lex publishes the $LATEST version. + Checksum *string `locationName:"checksum" type:"string"` + + // The name of the slot type that you want to create a new version for. The + // name is case sensitive. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s CreateSlotTypeVersionInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateSlotTypeVersionInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateSlotTypeVersionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateSlotTypeVersionInput"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetChecksum sets the Checksum field's value. +func (s *CreateSlotTypeVersionInput) SetChecksum(v string) *CreateSlotTypeVersionInput { + s.Checksum = &v + return s +} + +// SetName sets the Name field's value. +func (s *CreateSlotTypeVersionInput) SetName(v string) *CreateSlotTypeVersionInput { + s.Name = &v + return s +} + +type CreateSlotTypeVersionOutput struct { + _ struct{} `type:"structure"` + + // Checksum of the $LATEST version of the slot type. + Checksum *string `locationName:"checksum" type:"string"` + + // The date that the slot type was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A description of the slot type. + Description *string `locationName:"description" type:"string"` + + // A list of EnumerationValue objects that defines the values that the slot + // type can take. + EnumerationValues []*EnumerationValue `locationName:"enumerationValues" min:"1" type:"list"` + + // The date that the slot type was updated. When you create a resource, the + // creation date and last update date are the same. + LastUpdatedDate *time.Time `locationName:"lastUpdatedDate" type:"timestamp" timestampFormat:"unix"` + + // The name of the slot type. + Name *string `locationName:"name" min:"1" type:"string"` + + // The strategy that Amazon Lex uses to determine the value of the slot. For + // more information, see PutSlotType. + ValueSelectionStrategy *string `locationName:"valueSelectionStrategy" type:"string" enum:"SlotValueSelectionStrategy"` + + // The version assigned to the new slot type version. + Version *string `locationName:"version" min:"1" type:"string"` +} + +// String returns the string representation +func (s CreateSlotTypeVersionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateSlotTypeVersionOutput) GoString() string { + return s.String() +} + +// SetChecksum sets the Checksum field's value. +func (s *CreateSlotTypeVersionOutput) SetChecksum(v string) *CreateSlotTypeVersionOutput { + s.Checksum = &v + return s +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *CreateSlotTypeVersionOutput) SetCreatedDate(v time.Time) *CreateSlotTypeVersionOutput { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreateSlotTypeVersionOutput) SetDescription(v string) *CreateSlotTypeVersionOutput { + s.Description = &v + return s +} + +// SetEnumerationValues sets the EnumerationValues field's value. +func (s *CreateSlotTypeVersionOutput) SetEnumerationValues(v []*EnumerationValue) *CreateSlotTypeVersionOutput { + s.EnumerationValues = v + return s +} + +// SetLastUpdatedDate sets the LastUpdatedDate field's value. +func (s *CreateSlotTypeVersionOutput) SetLastUpdatedDate(v time.Time) *CreateSlotTypeVersionOutput { + s.LastUpdatedDate = &v + return s +} + +// SetName sets the Name field's value. +func (s *CreateSlotTypeVersionOutput) SetName(v string) *CreateSlotTypeVersionOutput { + s.Name = &v + return s +} + +// SetValueSelectionStrategy sets the ValueSelectionStrategy field's value. +func (s *CreateSlotTypeVersionOutput) SetValueSelectionStrategy(v string) *CreateSlotTypeVersionOutput { + s.ValueSelectionStrategy = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *CreateSlotTypeVersionOutput) SetVersion(v string) *CreateSlotTypeVersionOutput { + s.Version = &v + return s +} + +type DeleteBotAliasInput struct { + _ struct{} `type:"structure"` + + // The name of the bot that the alias points to. + // + // BotName is a required field + BotName *string `location:"uri" locationName:"botName" min:"2" type:"string" required:"true"` + + // The name of the alias to delete. The name is case sensitive. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s DeleteBotAliasInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteBotAliasInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteBotAliasInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteBotAliasInput"} + if s.BotName == nil { + invalidParams.Add(request.NewErrParamRequired("BotName")) + } + if s.BotName != nil && len(*s.BotName) < 2 { + invalidParams.Add(request.NewErrParamMinLen("BotName", 2)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetBotName sets the BotName field's value. +func (s *DeleteBotAliasInput) SetBotName(v string) *DeleteBotAliasInput { + s.BotName = &v + return s +} + +// SetName sets the Name field's value. +func (s *DeleteBotAliasInput) SetName(v string) *DeleteBotAliasInput { + s.Name = &v + return s +} + +type DeleteBotAliasOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteBotAliasOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteBotAliasOutput) GoString() string { + return s.String() +} + +type DeleteBotChannelAssociationInput struct { + _ struct{} `type:"structure"` + + // An alias that points to the specific version of the Amazon Lex bot to which + // this association is being made. + // + // BotAlias is a required field + BotAlias *string `location:"uri" locationName:"aliasName" min:"1" type:"string" required:"true"` + + // The name of the Amazon Lex bot. + // + // BotName is a required field + BotName *string `location:"uri" locationName:"botName" min:"2" type:"string" required:"true"` + + // The name of the association. The name is case sensitive. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s DeleteBotChannelAssociationInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteBotChannelAssociationInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteBotChannelAssociationInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteBotChannelAssociationInput"} + if s.BotAlias == nil { + invalidParams.Add(request.NewErrParamRequired("BotAlias")) + } + if s.BotAlias != nil && len(*s.BotAlias) < 1 { + invalidParams.Add(request.NewErrParamMinLen("BotAlias", 1)) + } + if s.BotName == nil { + invalidParams.Add(request.NewErrParamRequired("BotName")) + } + if s.BotName != nil && len(*s.BotName) < 2 { + invalidParams.Add(request.NewErrParamMinLen("BotName", 2)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetBotAlias sets the BotAlias field's value. +func (s *DeleteBotChannelAssociationInput) SetBotAlias(v string) *DeleteBotChannelAssociationInput { + s.BotAlias = &v + return s +} + +// SetBotName sets the BotName field's value. +func (s *DeleteBotChannelAssociationInput) SetBotName(v string) *DeleteBotChannelAssociationInput { + s.BotName = &v + return s +} + +// SetName sets the Name field's value. +func (s *DeleteBotChannelAssociationInput) SetName(v string) *DeleteBotChannelAssociationInput { + s.Name = &v + return s +} + +type DeleteBotChannelAssociationOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteBotChannelAssociationOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteBotChannelAssociationOutput) GoString() string { + return s.String() +} + +type DeleteBotInput struct { + _ struct{} `type:"structure"` + + // The name of the bot. The name is case sensitive. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"2" type:"string" required:"true"` +} + +// String returns the string representation +func (s DeleteBotInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteBotInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteBotInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteBotInput"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Name", 2)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetName sets the Name field's value. +func (s *DeleteBotInput) SetName(v string) *DeleteBotInput { + s.Name = &v + return s +} + +type DeleteBotOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteBotOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteBotOutput) GoString() string { + return s.String() +} + +type DeleteBotVersionInput struct { + _ struct{} `type:"structure"` + + // The name of the bot. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"2" type:"string" required:"true"` + + // The version of the bot to delete. You cannot delete the $LATEST version of + // the bot. To delete the $LATEST version, use the DeleteBot operation. + // + // Version is a required field + Version *string `location:"uri" locationName:"version" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s DeleteBotVersionInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteBotVersionInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteBotVersionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteBotVersionInput"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Name", 2)) + } + if s.Version == nil { + invalidParams.Add(request.NewErrParamRequired("Version")) + } + if s.Version != nil && len(*s.Version) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Version", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetName sets the Name field's value. +func (s *DeleteBotVersionInput) SetName(v string) *DeleteBotVersionInput { + s.Name = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *DeleteBotVersionInput) SetVersion(v string) *DeleteBotVersionInput { + s.Version = &v + return s +} + +type DeleteBotVersionOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteBotVersionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteBotVersionOutput) GoString() string { + return s.String() +} + +type DeleteIntentInput struct { + _ struct{} `type:"structure"` + + // The name of the intent. The name is case sensitive. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s DeleteIntentInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteIntentInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteIntentInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteIntentInput"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetName sets the Name field's value. +func (s *DeleteIntentInput) SetName(v string) *DeleteIntentInput { + s.Name = &v + return s +} + +type DeleteIntentOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteIntentOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteIntentOutput) GoString() string { + return s.String() +} + +type DeleteIntentVersionInput struct { + _ struct{} `type:"structure"` + + // The name of the intent. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` + + // The version of the intent to delete. You cannot delete the $LATEST version + // of the intent. To delete the $LATEST version, use the DeleteIntent operation. + // + // Version is a required field + Version *string `location:"uri" locationName:"version" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s DeleteIntentVersionInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteIntentVersionInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteIntentVersionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteIntentVersionInput"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + if s.Version == nil { + invalidParams.Add(request.NewErrParamRequired("Version")) + } + if s.Version != nil && len(*s.Version) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Version", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetName sets the Name field's value. +func (s *DeleteIntentVersionInput) SetName(v string) *DeleteIntentVersionInput { + s.Name = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *DeleteIntentVersionInput) SetVersion(v string) *DeleteIntentVersionInput { + s.Version = &v + return s +} + +type DeleteIntentVersionOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteIntentVersionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteIntentVersionOutput) GoString() string { + return s.String() +} + +type DeleteSlotTypeInput struct { + _ struct{} `type:"structure"` + + // The name of the slot type. The name is case sensitive. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s DeleteSlotTypeInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteSlotTypeInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteSlotTypeInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteSlotTypeInput"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetName sets the Name field's value. +func (s *DeleteSlotTypeInput) SetName(v string) *DeleteSlotTypeInput { + s.Name = &v + return s +} + +type DeleteSlotTypeOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteSlotTypeOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteSlotTypeOutput) GoString() string { + return s.String() +} + +type DeleteSlotTypeVersionInput struct { + _ struct{} `type:"structure"` + + // The name of the slot type. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` + + // The version of the slot type to delete. You cannot delete the $LATEST version + // of the slot type. To delete the $LATEST version, use the DeleteSlotType operation. + // + // Version is a required field + Version *string `location:"uri" locationName:"version" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s DeleteSlotTypeVersionInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteSlotTypeVersionInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteSlotTypeVersionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteSlotTypeVersionInput"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + if s.Version == nil { + invalidParams.Add(request.NewErrParamRequired("Version")) + } + if s.Version != nil && len(*s.Version) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Version", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetName sets the Name field's value. +func (s *DeleteSlotTypeVersionInput) SetName(v string) *DeleteSlotTypeVersionInput { + s.Name = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *DeleteSlotTypeVersionInput) SetVersion(v string) *DeleteSlotTypeVersionInput { + s.Version = &v + return s +} + +type DeleteSlotTypeVersionOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteSlotTypeVersionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteSlotTypeVersionOutput) GoString() string { + return s.String() +} + +type DeleteUtterancesInput struct { + _ struct{} `type:"structure"` + + // The name of the bot that stored the utterances. + // + // BotName is a required field + BotName *string `location:"uri" locationName:"botName" min:"2" type:"string" required:"true"` + + // The unique identifier for the user that made the utterances. This is the + // user ID that was sent in the PostContent (http://docs.aws.amazon.com/lex/latest/dg/API_runtime_PostContent.html) + // or PostText (http://docs.aws.amazon.com/lex/latest/dg/API_runtime_PostText.html) + // operation request that contained the utterance. + // + // UserId is a required field + UserId *string `location:"uri" locationName:"userId" min:"2" type:"string" required:"true"` +} + +// String returns the string representation +func (s DeleteUtterancesInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteUtterancesInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteUtterancesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteUtterancesInput"} + if s.BotName == nil { + invalidParams.Add(request.NewErrParamRequired("BotName")) + } + if s.BotName != nil && len(*s.BotName) < 2 { + invalidParams.Add(request.NewErrParamMinLen("BotName", 2)) + } + if s.UserId == nil { + invalidParams.Add(request.NewErrParamRequired("UserId")) + } + if s.UserId != nil && len(*s.UserId) < 2 { + invalidParams.Add(request.NewErrParamMinLen("UserId", 2)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetBotName sets the BotName field's value. +func (s *DeleteUtterancesInput) SetBotName(v string) *DeleteUtterancesInput { + s.BotName = &v + return s +} + +// SetUserId sets the UserId field's value. +func (s *DeleteUtterancesInput) SetUserId(v string) *DeleteUtterancesInput { + s.UserId = &v + return s +} + +type DeleteUtterancesOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteUtterancesOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteUtterancesOutput) GoString() string { + return s.String() +} + +// Each slot type can have a set of values. Each enumeration value represents +// a value the slot type can take. +// +// For example, a pizza ordering bot could have a slot type that specifies the +// type of crust that the pizza should have. The slot type could include the +// values +// +// * thick +// +// * thin +// +// * stuffed +type EnumerationValue struct { + _ struct{} `type:"structure"` + + // Additional values related to the slot type value. + Synonyms []*string `locationName:"synonyms" type:"list"` + + // The value of the slot type. + // + // Value is a required field + Value *string `locationName:"value" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s EnumerationValue) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s EnumerationValue) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *EnumerationValue) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "EnumerationValue"} + if s.Value == nil { + invalidParams.Add(request.NewErrParamRequired("Value")) + } + if s.Value != nil && len(*s.Value) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Value", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetSynonyms sets the Synonyms field's value. +func (s *EnumerationValue) SetSynonyms(v []*string) *EnumerationValue { + s.Synonyms = v + return s +} + +// SetValue sets the Value field's value. +func (s *EnumerationValue) SetValue(v string) *EnumerationValue { + s.Value = &v + return s +} + +// A prompt for additional activity after an intent is fulfilled. For example, +// after the OrderPizza intent is fulfilled, you might prompt the user to find +// out whether the user wants to order drinks. +type FollowUpPrompt struct { + _ struct{} `type:"structure"` + + // Prompts for information from the user. + // + // Prompt is a required field + Prompt *Prompt `locationName:"prompt" type:"structure" required:"true"` + + // If the user answers "no" to the question defined in the prompt field, Amazon + // Lex responds with this statement to acknowledge that the intent was canceled. + // + // RejectionStatement is a required field + RejectionStatement *Statement `locationName:"rejectionStatement" type:"structure" required:"true"` +} + +// String returns the string representation +func (s FollowUpPrompt) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s FollowUpPrompt) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *FollowUpPrompt) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FollowUpPrompt"} + if s.Prompt == nil { + invalidParams.Add(request.NewErrParamRequired("Prompt")) + } + if s.RejectionStatement == nil { + invalidParams.Add(request.NewErrParamRequired("RejectionStatement")) + } + if s.Prompt != nil { + if err := s.Prompt.Validate(); err != nil { + invalidParams.AddNested("Prompt", err.(request.ErrInvalidParams)) + } + } + if s.RejectionStatement != nil { + if err := s.RejectionStatement.Validate(); err != nil { + invalidParams.AddNested("RejectionStatement", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetPrompt sets the Prompt field's value. +func (s *FollowUpPrompt) SetPrompt(v *Prompt) *FollowUpPrompt { + s.Prompt = v + return s +} + +// SetRejectionStatement sets the RejectionStatement field's value. +func (s *FollowUpPrompt) SetRejectionStatement(v *Statement) *FollowUpPrompt { + s.RejectionStatement = v + return s +} + +// Describes how the intent is fulfilled after the user provides all of the +// information required for the intent. You can provide a Lambda function to +// process the intent, or you can return the intent information to the client +// application. We recommend that you use a Lambda function so that the relevant +// logic lives in the Cloud and limit the client-side code primarily to presentation. +// If you need to update the logic, you only update the Lambda function; you +// don't need to upgrade your client application. +// +// Consider the following examples: +// +// * In a pizza ordering application, after the user provides all of the +// information for placing an order, you use a Lambda function to place an +// order with a pizzeria. +// +// * In a gaming application, when a user says "pick up a rock," this information +// must go back to the client application so that it can perform the operation +// and update the graphics. In this case, you want Amazon Lex to return the +// intent data to the client. +type FulfillmentActivity struct { + _ struct{} `type:"structure"` + + // A description of the Lambda function that is run to fulfill the intent. + CodeHook *CodeHook `locationName:"codeHook" type:"structure"` + + // How the intent should be fulfilled, either by running a Lambda function or + // by returning the slot data to the client application. + // + // Type is a required field + Type *string `locationName:"type" type:"string" required:"true" enum:"FulfillmentActivityType"` +} + +// String returns the string representation +func (s FulfillmentActivity) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s FulfillmentActivity) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *FulfillmentActivity) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "FulfillmentActivity"} + if s.Type == nil { + invalidParams.Add(request.NewErrParamRequired("Type")) + } + if s.CodeHook != nil { + if err := s.CodeHook.Validate(); err != nil { + invalidParams.AddNested("CodeHook", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetCodeHook sets the CodeHook field's value. +func (s *FulfillmentActivity) SetCodeHook(v *CodeHook) *FulfillmentActivity { + s.CodeHook = v + return s +} + +// SetType sets the Type field's value. +func (s *FulfillmentActivity) SetType(v string) *FulfillmentActivity { + s.Type = &v + return s +} + +type GetBotAliasInput struct { + _ struct{} `type:"structure"` + + // The name of the bot. + // + // BotName is a required field + BotName *string `location:"uri" locationName:"botName" min:"2" type:"string" required:"true"` + + // The name of the bot alias. The name is case sensitive. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s GetBotAliasInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBotAliasInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetBotAliasInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetBotAliasInput"} + if s.BotName == nil { + invalidParams.Add(request.NewErrParamRequired("BotName")) + } + if s.BotName != nil && len(*s.BotName) < 2 { + invalidParams.Add(request.NewErrParamMinLen("BotName", 2)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetBotName sets the BotName field's value. +func (s *GetBotAliasInput) SetBotName(v string) *GetBotAliasInput { + s.BotName = &v + return s +} + +// SetName sets the Name field's value. +func (s *GetBotAliasInput) SetName(v string) *GetBotAliasInput { + s.Name = &v + return s +} + +type GetBotAliasOutput struct { + _ struct{} `type:"structure"` + + // The name of the bot that the alias points to. + BotName *string `locationName:"botName" min:"2" type:"string"` + + // The version of the bot that the alias points to. + BotVersion *string `locationName:"botVersion" min:"1" type:"string"` + + // Checksum of the bot alias. + Checksum *string `locationName:"checksum" type:"string"` + + // The date that the bot alias was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A description of the bot alias. + Description *string `locationName:"description" type:"string"` + + // The date that the bot alias was updated. When you create a resource, the + // creation date and the last updated date are the same. + LastUpdatedDate *time.Time `locationName:"lastUpdatedDate" type:"timestamp" timestampFormat:"unix"` + + // The name of the bot alias. + Name *string `locationName:"name" min:"1" type:"string"` +} + +// String returns the string representation +func (s GetBotAliasOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBotAliasOutput) GoString() string { + return s.String() +} + +// SetBotName sets the BotName field's value. +func (s *GetBotAliasOutput) SetBotName(v string) *GetBotAliasOutput { + s.BotName = &v + return s +} + +// SetBotVersion sets the BotVersion field's value. +func (s *GetBotAliasOutput) SetBotVersion(v string) *GetBotAliasOutput { + s.BotVersion = &v + return s +} + +// SetChecksum sets the Checksum field's value. +func (s *GetBotAliasOutput) SetChecksum(v string) *GetBotAliasOutput { + s.Checksum = &v + return s +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *GetBotAliasOutput) SetCreatedDate(v time.Time) *GetBotAliasOutput { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *GetBotAliasOutput) SetDescription(v string) *GetBotAliasOutput { + s.Description = &v + return s +} + +// SetLastUpdatedDate sets the LastUpdatedDate field's value. +func (s *GetBotAliasOutput) SetLastUpdatedDate(v time.Time) *GetBotAliasOutput { + s.LastUpdatedDate = &v + return s +} + +// SetName sets the Name field's value. +func (s *GetBotAliasOutput) SetName(v string) *GetBotAliasOutput { + s.Name = &v + return s +} + +type GetBotAliasesInput struct { + _ struct{} `type:"structure"` + + // The name of the bot. + // + // BotName is a required field + BotName *string `location:"uri" locationName:"botName" min:"2" type:"string" required:"true"` + + // The maximum number of aliases to return in the response. The default is 50. + // . + MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` + + // Substring to match in bot alias names. An alias will be returned if any part + // of its name matches the substring. For example, "xyz" matches both "xyzabc" + // and "abcxyz." + NameContains *string `location:"querystring" locationName:"nameContains" min:"1" type:"string"` + + // A pagination token for fetching the next page of aliases. If the response + // to this call is truncated, Amazon Lex returns a pagination token in the response. + // To fetch the next page of aliases, specify the pagination token in the next + // request. + NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` +} + +// String returns the string representation +func (s GetBotAliasesInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBotAliasesInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetBotAliasesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetBotAliasesInput"} + if s.BotName == nil { + invalidParams.Add(request.NewErrParamRequired("BotName")) + } + if s.BotName != nil && len(*s.BotName) < 2 { + invalidParams.Add(request.NewErrParamMinLen("BotName", 2)) + } + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.NameContains != nil && len(*s.NameContains) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NameContains", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetBotName sets the BotName field's value. +func (s *GetBotAliasesInput) SetBotName(v string) *GetBotAliasesInput { + s.BotName = &v + return s +} + +// SetMaxResults sets the MaxResults field's value. +func (s *GetBotAliasesInput) SetMaxResults(v int64) *GetBotAliasesInput { + s.MaxResults = &v + return s +} + +// SetNameContains sets the NameContains field's value. +func (s *GetBotAliasesInput) SetNameContains(v string) *GetBotAliasesInput { + s.NameContains = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetBotAliasesInput) SetNextToken(v string) *GetBotAliasesInput { + s.NextToken = &v + return s +} + +type GetBotAliasesOutput struct { + _ struct{} `type:"structure"` + + // An array of BotAliasMetadata objects, each describing a bot alias. + BotAliases []*BotAliasMetadata `type:"list"` + + // A pagination token for fetching next page of aliases. If the response to + // this call is truncated, Amazon Lex returns a pagination token in the response. + // To fetch the next page of aliases, specify the pagination token in the next + // request. + NextToken *string `locationName:"nextToken" type:"string"` +} + +// String returns the string representation +func (s GetBotAliasesOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBotAliasesOutput) GoString() string { + return s.String() +} + +// SetBotAliases sets the BotAliases field's value. +func (s *GetBotAliasesOutput) SetBotAliases(v []*BotAliasMetadata) *GetBotAliasesOutput { + s.BotAliases = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetBotAliasesOutput) SetNextToken(v string) *GetBotAliasesOutput { + s.NextToken = &v + return s +} + +type GetBotChannelAssociationInput struct { + _ struct{} `type:"structure"` + + // An alias pointing to the specific version of the Amazon Lex bot to which + // this association is being made. + // + // BotAlias is a required field + BotAlias *string `location:"uri" locationName:"aliasName" min:"1" type:"string" required:"true"` + + // The name of the Amazon Lex bot. + // + // BotName is a required field + BotName *string `location:"uri" locationName:"botName" min:"2" type:"string" required:"true"` + + // The name of the association between the bot and the channel. The name is + // case sensitive. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s GetBotChannelAssociationInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBotChannelAssociationInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetBotChannelAssociationInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetBotChannelAssociationInput"} + if s.BotAlias == nil { + invalidParams.Add(request.NewErrParamRequired("BotAlias")) + } + if s.BotAlias != nil && len(*s.BotAlias) < 1 { + invalidParams.Add(request.NewErrParamMinLen("BotAlias", 1)) + } + if s.BotName == nil { + invalidParams.Add(request.NewErrParamRequired("BotName")) + } + if s.BotName != nil && len(*s.BotName) < 2 { + invalidParams.Add(request.NewErrParamMinLen("BotName", 2)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetBotAlias sets the BotAlias field's value. +func (s *GetBotChannelAssociationInput) SetBotAlias(v string) *GetBotChannelAssociationInput { + s.BotAlias = &v + return s +} + +// SetBotName sets the BotName field's value. +func (s *GetBotChannelAssociationInput) SetBotName(v string) *GetBotChannelAssociationInput { + s.BotName = &v + return s +} + +// SetName sets the Name field's value. +func (s *GetBotChannelAssociationInput) SetName(v string) *GetBotChannelAssociationInput { + s.Name = &v + return s +} + +type GetBotChannelAssociationOutput struct { + _ struct{} `type:"structure"` + + // An alias pointing to the specific version of the Amazon Lex bot to which + // this association is being made. + BotAlias *string `locationName:"botAlias" min:"1" type:"string"` + + // Provides information that the messaging platform needs to communicate with + // the Amazon Lex bot. + BotConfiguration map[string]*string `locationName:"botConfiguration" min:"1" type:"map"` + + // The name of the Amazon Lex bot. + BotName *string `locationName:"botName" min:"2" type:"string"` + + // The date that the association between the bot and the channel was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A description of the association between the bot and the channel. + Description *string `locationName:"description" type:"string"` + + // If status is FAILED, Amazon Lex provides the reason that it failed to create + // the association. + FailureReason *string `locationName:"failureReason" type:"string"` + + // The name of the association between the bot and the channel. + Name *string `locationName:"name" min:"1" type:"string"` + + // The status of the bot channel. + // + // * CREATED - The channel has been created and is ready for use. + // + // * IN_PROGRESS - Channel creation is in progress. + // + // * FAILED - There was an error creating the channel. For information about + // the reason for the failure, see the failureReason field. + Status *string `locationName:"status" type:"string" enum:"ChannelStatus"` + + // The type of the messaging platform. + Type *string `locationName:"type" type:"string" enum:"ChannelType"` +} + +// String returns the string representation +func (s GetBotChannelAssociationOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBotChannelAssociationOutput) GoString() string { + return s.String() +} + +// SetBotAlias sets the BotAlias field's value. +func (s *GetBotChannelAssociationOutput) SetBotAlias(v string) *GetBotChannelAssociationOutput { + s.BotAlias = &v + return s +} + +// SetBotConfiguration sets the BotConfiguration field's value. +func (s *GetBotChannelAssociationOutput) SetBotConfiguration(v map[string]*string) *GetBotChannelAssociationOutput { + s.BotConfiguration = v + return s +} + +// SetBotName sets the BotName field's value. +func (s *GetBotChannelAssociationOutput) SetBotName(v string) *GetBotChannelAssociationOutput { + s.BotName = &v + return s +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *GetBotChannelAssociationOutput) SetCreatedDate(v time.Time) *GetBotChannelAssociationOutput { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *GetBotChannelAssociationOutput) SetDescription(v string) *GetBotChannelAssociationOutput { + s.Description = &v + return s +} + +// SetFailureReason sets the FailureReason field's value. +func (s *GetBotChannelAssociationOutput) SetFailureReason(v string) *GetBotChannelAssociationOutput { + s.FailureReason = &v + return s +} + +// SetName sets the Name field's value. +func (s *GetBotChannelAssociationOutput) SetName(v string) *GetBotChannelAssociationOutput { + s.Name = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *GetBotChannelAssociationOutput) SetStatus(v string) *GetBotChannelAssociationOutput { + s.Status = &v + return s +} + +// SetType sets the Type field's value. +func (s *GetBotChannelAssociationOutput) SetType(v string) *GetBotChannelAssociationOutput { + s.Type = &v + return s +} + +type GetBotChannelAssociationsInput struct { + _ struct{} `type:"structure"` + + // An alias pointing to the specific version of the Amazon Lex bot to which + // this association is being made. + // + // BotAlias is a required field + BotAlias *string `location:"uri" locationName:"aliasName" min:"1" type:"string" required:"true"` + + // The name of the Amazon Lex bot in the association. + // + // BotName is a required field + BotName *string `location:"uri" locationName:"botName" min:"2" type:"string" required:"true"` + + // The maximum number of associations to return in the response. The default + // is 50. + MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` + + // Substring to match in channel association names. An association will be returned + // if any part of its name matches the substring. For example, "xyz" matches + // both "xyzabc" and "abcxyz." To return all bot channel associations, use a + // hyphen ("-") as the nameContains parameter. + NameContains *string `location:"querystring" locationName:"nameContains" min:"1" type:"string"` + + // A pagination token for fetching the next page of associations. If the response + // to this call is truncated, Amazon Lex returns a pagination token in the response. + // To fetch the next page of associations, specify the pagination token in the + // next request. + NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` +} + +// String returns the string representation +func (s GetBotChannelAssociationsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBotChannelAssociationsInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetBotChannelAssociationsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetBotChannelAssociationsInput"} + if s.BotAlias == nil { + invalidParams.Add(request.NewErrParamRequired("BotAlias")) + } + if s.BotAlias != nil && len(*s.BotAlias) < 1 { + invalidParams.Add(request.NewErrParamMinLen("BotAlias", 1)) + } + if s.BotName == nil { + invalidParams.Add(request.NewErrParamRequired("BotName")) + } + if s.BotName != nil && len(*s.BotName) < 2 { + invalidParams.Add(request.NewErrParamMinLen("BotName", 2)) + } + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.NameContains != nil && len(*s.NameContains) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NameContains", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetBotAlias sets the BotAlias field's value. +func (s *GetBotChannelAssociationsInput) SetBotAlias(v string) *GetBotChannelAssociationsInput { + s.BotAlias = &v + return s +} + +// SetBotName sets the BotName field's value. +func (s *GetBotChannelAssociationsInput) SetBotName(v string) *GetBotChannelAssociationsInput { + s.BotName = &v + return s +} + +// SetMaxResults sets the MaxResults field's value. +func (s *GetBotChannelAssociationsInput) SetMaxResults(v int64) *GetBotChannelAssociationsInput { + s.MaxResults = &v + return s +} + +// SetNameContains sets the NameContains field's value. +func (s *GetBotChannelAssociationsInput) SetNameContains(v string) *GetBotChannelAssociationsInput { + s.NameContains = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetBotChannelAssociationsInput) SetNextToken(v string) *GetBotChannelAssociationsInput { + s.NextToken = &v + return s +} + +type GetBotChannelAssociationsOutput struct { + _ struct{} `type:"structure"` + + // An array of objects, one for each association, that provides information + // about the Amazon Lex bot and its association with the channel. + BotChannelAssociations []*BotChannelAssociation `locationName:"botChannelAssociations" type:"list"` + + // A pagination token that fetches the next page of associations. If the response + // to this call is truncated, Amazon Lex returns a pagination token in the response. + // To fetch the next page of associations, specify the pagination token in the + // next request. + NextToken *string `locationName:"nextToken" type:"string"` +} + +// String returns the string representation +func (s GetBotChannelAssociationsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBotChannelAssociationsOutput) GoString() string { + return s.String() +} + +// SetBotChannelAssociations sets the BotChannelAssociations field's value. +func (s *GetBotChannelAssociationsOutput) SetBotChannelAssociations(v []*BotChannelAssociation) *GetBotChannelAssociationsOutput { + s.BotChannelAssociations = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetBotChannelAssociationsOutput) SetNextToken(v string) *GetBotChannelAssociationsOutput { + s.NextToken = &v + return s +} + +type GetBotInput struct { + _ struct{} `type:"structure"` + + // The name of the bot. The name is case sensitive. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"2" type:"string" required:"true"` + + // The version or alias of the bot. + // + // VersionOrAlias is a required field + VersionOrAlias *string `location:"uri" locationName:"versionoralias" type:"string" required:"true"` +} + +// String returns the string representation +func (s GetBotInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBotInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetBotInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetBotInput"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Name", 2)) + } + if s.VersionOrAlias == nil { + invalidParams.Add(request.NewErrParamRequired("VersionOrAlias")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetName sets the Name field's value. +func (s *GetBotInput) SetName(v string) *GetBotInput { + s.Name = &v + return s +} + +// SetVersionOrAlias sets the VersionOrAlias field's value. +func (s *GetBotInput) SetVersionOrAlias(v string) *GetBotInput { + s.VersionOrAlias = &v + return s +} + +type GetBotOutput struct { + _ struct{} `type:"structure"` + + // The message that Amazon Lex returns when the user elects to end the conversation + // without completing it. For more information, see PutBot. + AbortStatement *Statement `locationName:"abortStatement" type:"structure"` + + // Checksum of the bot used to identify a specific revision of the bot's $LATEST + // version. + Checksum *string `locationName:"checksum" type:"string"` + + // For each Amazon Lex bot created with the Amazon Lex Model Building Service, + // you must specify whether your use of Amazon Lex is related to a website, + // program, or other application that is directed or targeted, in whole or in + // part, to children under age 13 and subject to the Children's Online Privacy + // Protection Act (COPPA) by specifying true or false in the childDirected field. + // By specifying true in the childDirected field, you confirm that your use + // of Amazon Lex is related to a website, program, or other application that + // is directed or targeted, in whole or in part, to children under age 13 and + // subject to COPPA. By specifying false in the childDirected field, you confirm + // that your use of Amazon Lex is not related to a website, program, or other + // application that is directed or targeted, in whole or in part, to children + // under age 13 and subject to COPPA. You may not specify a default value for + // the childDirected field that does not accurately reflect whether your use + // of Amazon Lex is related to a website, program, or other application that + // is directed or targeted, in whole or in part, to children under age 13 and + // subject to COPPA. + // + // If your use of Amazon Lex relates to a website, program, or other application + // that is directed in whole or in part, to children under age 13, you must + // obtain any required verifiable parental consent under COPPA. For information + // regarding the use of Amazon Lex in connection with websites, programs, or + // other applications that are directed or targeted, in whole or in part, to + // children under age 13, see the Amazon Lex FAQ. (https://aws.amazon.com/lex/faqs#data-security) + ChildDirected *bool `locationName:"childDirected" type:"boolean"` + + // The message Amazon Lex uses when it doesn't understand the user's request. + // For more information, see PutBot. + ClarificationPrompt *Prompt `locationName:"clarificationPrompt" type:"structure"` + + // The date that the bot was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A description of the bot. + Description *string `locationName:"description" type:"string"` + + // If status is FAILED, Amazon Lex explains why it failed to build the bot. + FailureReason *string `locationName:"failureReason" type:"string"` + + // The maximum time in seconds that Amazon Lex retains the data gathered in + // a conversation. For more information, see PutBot. + IdleSessionTTLInSeconds *int64 `locationName:"idleSessionTTLInSeconds" min:"60" type:"integer"` + + // An array of intent objects. For more information, see PutBot. + Intents []*Intent `locationName:"intents" type:"list"` + + // The date that the bot was updated. When you create a resource, the creation + // date and last updated date are the same. + LastUpdatedDate *time.Time `locationName:"lastUpdatedDate" type:"timestamp" timestampFormat:"unix"` + + // The target locale for the bot. + Locale *string `locationName:"locale" type:"string" enum:"Locale"` + + // The name of the bot. + Name *string `locationName:"name" min:"2" type:"string"` + + // The status of the bot. If the bot is ready to run, the status is READY. If + // there was a problem with building the bot, the status is FAILED and the failureReason + // explains why the bot did not build. If the bot was saved but not built, the + // status is NOT BUILT. + Status *string `locationName:"status" type:"string" enum:"Status"` + + // The version of the bot. For a new bot, the version is always $LATEST. + Version *string `locationName:"version" min:"1" type:"string"` + + // The Amazon Polly voice ID that Amazon Lex uses for voice interaction with + // the user. For more information, see PutBot. + VoiceId *string `locationName:"voiceId" type:"string"` +} + +// String returns the string representation +func (s GetBotOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBotOutput) GoString() string { + return s.String() +} + +// SetAbortStatement sets the AbortStatement field's value. +func (s *GetBotOutput) SetAbortStatement(v *Statement) *GetBotOutput { + s.AbortStatement = v + return s +} + +// SetChecksum sets the Checksum field's value. +func (s *GetBotOutput) SetChecksum(v string) *GetBotOutput { + s.Checksum = &v + return s +} + +// SetChildDirected sets the ChildDirected field's value. +func (s *GetBotOutput) SetChildDirected(v bool) *GetBotOutput { + s.ChildDirected = &v + return s +} + +// SetClarificationPrompt sets the ClarificationPrompt field's value. +func (s *GetBotOutput) SetClarificationPrompt(v *Prompt) *GetBotOutput { + s.ClarificationPrompt = v + return s +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *GetBotOutput) SetCreatedDate(v time.Time) *GetBotOutput { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *GetBotOutput) SetDescription(v string) *GetBotOutput { + s.Description = &v + return s +} + +// SetFailureReason sets the FailureReason field's value. +func (s *GetBotOutput) SetFailureReason(v string) *GetBotOutput { + s.FailureReason = &v + return s +} + +// SetIdleSessionTTLInSeconds sets the IdleSessionTTLInSeconds field's value. +func (s *GetBotOutput) SetIdleSessionTTLInSeconds(v int64) *GetBotOutput { + s.IdleSessionTTLInSeconds = &v + return s +} + +// SetIntents sets the Intents field's value. +func (s *GetBotOutput) SetIntents(v []*Intent) *GetBotOutput { + s.Intents = v + return s +} + +// SetLastUpdatedDate sets the LastUpdatedDate field's value. +func (s *GetBotOutput) SetLastUpdatedDate(v time.Time) *GetBotOutput { + s.LastUpdatedDate = &v + return s +} + +// SetLocale sets the Locale field's value. +func (s *GetBotOutput) SetLocale(v string) *GetBotOutput { + s.Locale = &v + return s +} + +// SetName sets the Name field's value. +func (s *GetBotOutput) SetName(v string) *GetBotOutput { + s.Name = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *GetBotOutput) SetStatus(v string) *GetBotOutput { + s.Status = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *GetBotOutput) SetVersion(v string) *GetBotOutput { + s.Version = &v + return s +} + +// SetVoiceId sets the VoiceId field's value. +func (s *GetBotOutput) SetVoiceId(v string) *GetBotOutput { + s.VoiceId = &v + return s +} + +type GetBotVersionsInput struct { + _ struct{} `type:"structure"` + + // The maximum number of bot versions to return in the response. The default + // is 10. + MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` + + // The name of the bot for which versions should be returned. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"2" type:"string" required:"true"` + + // A pagination token for fetching the next page of bot versions. If the response + // to this call is truncated, Amazon Lex returns a pagination token in the response. + // To fetch the next page of versions, specify the pagination token in the next + // request. + NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` +} + +// String returns the string representation +func (s GetBotVersionsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBotVersionsInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetBotVersionsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetBotVersionsInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Name", 2)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMaxResults sets the MaxResults field's value. +func (s *GetBotVersionsInput) SetMaxResults(v int64) *GetBotVersionsInput { + s.MaxResults = &v + return s +} + +// SetName sets the Name field's value. +func (s *GetBotVersionsInput) SetName(v string) *GetBotVersionsInput { + s.Name = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetBotVersionsInput) SetNextToken(v string) *GetBotVersionsInput { + s.NextToken = &v + return s +} + +type GetBotVersionsOutput struct { + _ struct{} `type:"structure"` + + // An array of BotMetadata objects, one for each numbered version of the bot + // plus one for the $LATEST version. + Bots []*BotMetadata `locationName:"bots" type:"list"` + + // A pagination token for fetching the next page of bot versions. If the response + // to this call is truncated, Amazon Lex returns a pagination token in the response. + // To fetch the next page of versions, specify the pagination token in the next + // request. + NextToken *string `locationName:"nextToken" type:"string"` +} + +// String returns the string representation +func (s GetBotVersionsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBotVersionsOutput) GoString() string { + return s.String() +} + +// SetBots sets the Bots field's value. +func (s *GetBotVersionsOutput) SetBots(v []*BotMetadata) *GetBotVersionsOutput { + s.Bots = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetBotVersionsOutput) SetNextToken(v string) *GetBotVersionsOutput { + s.NextToken = &v + return s +} + +type GetBotsInput struct { + _ struct{} `type:"structure"` + + // The maximum number of bots to return in the response that the request will + // return. The default is 10. + MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` + + // Substring to match in bot names. A bot will be returned if any part of its + // name matches the substring. For example, "xyz" matches both "xyzabc" and + // "abcxyz." + NameContains *string `location:"querystring" locationName:"nameContains" min:"2" type:"string"` + + // A pagination token that fetches the next page of bots. If the response to + // this call is truncated, Amazon Lex returns a pagination token in the response. + // To fetch the next page of bots, specify the pagination token in the next + // request. + NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` +} + +// String returns the string representation +func (s GetBotsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBotsInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetBotsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetBotsInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.NameContains != nil && len(*s.NameContains) < 2 { + invalidParams.Add(request.NewErrParamMinLen("NameContains", 2)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMaxResults sets the MaxResults field's value. +func (s *GetBotsInput) SetMaxResults(v int64) *GetBotsInput { + s.MaxResults = &v + return s +} + +// SetNameContains sets the NameContains field's value. +func (s *GetBotsInput) SetNameContains(v string) *GetBotsInput { + s.NameContains = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetBotsInput) SetNextToken(v string) *GetBotsInput { + s.NextToken = &v + return s +} + +type GetBotsOutput struct { + _ struct{} `type:"structure"` + + // An array of botMetadata objects, with one entry for each bot. + Bots []*BotMetadata `locationName:"bots" type:"list"` + + // If the response is truncated, it includes a pagination token that you can + // specify in your next request to fetch the next page of bots. + NextToken *string `locationName:"nextToken" type:"string"` +} + +// String returns the string representation +func (s GetBotsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBotsOutput) GoString() string { + return s.String() +} + +// SetBots sets the Bots field's value. +func (s *GetBotsOutput) SetBots(v []*BotMetadata) *GetBotsOutput { + s.Bots = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetBotsOutput) SetNextToken(v string) *GetBotsOutput { + s.NextToken = &v + return s +} + +type GetBuiltinIntentInput struct { + _ struct{} `type:"structure"` + + // The unique identifier for a built-in intent. To find the signature for an + // intent, see Standard Built-in Intents (https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/docs/built-in-intent-ref/standard-intents) + // in the Alexa Skills Kit. + // + // Signature is a required field + Signature *string `location:"uri" locationName:"signature" type:"string" required:"true"` +} + +// String returns the string representation +func (s GetBuiltinIntentInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBuiltinIntentInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetBuiltinIntentInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetBuiltinIntentInput"} + if s.Signature == nil { + invalidParams.Add(request.NewErrParamRequired("Signature")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetSignature sets the Signature field's value. +func (s *GetBuiltinIntentInput) SetSignature(v string) *GetBuiltinIntentInput { + s.Signature = &v + return s +} + +type GetBuiltinIntentOutput struct { + _ struct{} `type:"structure"` + + // The unique identifier for a built-in intent. + Signature *string `locationName:"signature" type:"string"` + + // An array of BuiltinIntentSlot objects, one entry for each slot type in the + // intent. + Slots []*BuiltinIntentSlot `locationName:"slots" type:"list"` + + // A list of locales that the intent supports. + SupportedLocales []*string `locationName:"supportedLocales" type:"list"` +} + +// String returns the string representation +func (s GetBuiltinIntentOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBuiltinIntentOutput) GoString() string { + return s.String() +} + +// SetSignature sets the Signature field's value. +func (s *GetBuiltinIntentOutput) SetSignature(v string) *GetBuiltinIntentOutput { + s.Signature = &v + return s +} + +// SetSlots sets the Slots field's value. +func (s *GetBuiltinIntentOutput) SetSlots(v []*BuiltinIntentSlot) *GetBuiltinIntentOutput { + s.Slots = v + return s +} + +// SetSupportedLocales sets the SupportedLocales field's value. +func (s *GetBuiltinIntentOutput) SetSupportedLocales(v []*string) *GetBuiltinIntentOutput { + s.SupportedLocales = v + return s +} + +type GetBuiltinIntentsInput struct { + _ struct{} `type:"structure"` + + // A list of locales that the intent supports. + Locale *string `location:"querystring" locationName:"locale" type:"string" enum:"Locale"` + + // The maximum number of intents to return in the response. The default is 10. + MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` + + // A pagination token that fetches the next page of intents. If this API call + // is truncated, Amazon Lex returns a pagination token in the response. To fetch + // the next page of intents, use the pagination token in the next request. + NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` + + // Substring to match in built-in intent signatures. An intent will be returned + // if any part of its signature matches the substring. For example, "xyz" matches + // both "xyzabc" and "abcxyz." To find the signature for an intent, see Standard + // Built-in Intents (https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/docs/built-in-intent-ref/standard-intents) + // in the Alexa Skills Kit. + SignatureContains *string `location:"querystring" locationName:"signatureContains" type:"string"` +} + +// String returns the string representation +func (s GetBuiltinIntentsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBuiltinIntentsInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetBuiltinIntentsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetBuiltinIntentsInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetLocale sets the Locale field's value. +func (s *GetBuiltinIntentsInput) SetLocale(v string) *GetBuiltinIntentsInput { + s.Locale = &v + return s +} + +// SetMaxResults sets the MaxResults field's value. +func (s *GetBuiltinIntentsInput) SetMaxResults(v int64) *GetBuiltinIntentsInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetBuiltinIntentsInput) SetNextToken(v string) *GetBuiltinIntentsInput { + s.NextToken = &v + return s +} + +// SetSignatureContains sets the SignatureContains field's value. +func (s *GetBuiltinIntentsInput) SetSignatureContains(v string) *GetBuiltinIntentsInput { + s.SignatureContains = &v + return s +} + +type GetBuiltinIntentsOutput struct { + _ struct{} `type:"structure"` + + // An array of builtinIntentMetadata objects, one for each intent in the response. + Intents []*BuiltinIntentMetadata `locationName:"intents" type:"list"` + + // A pagination token that fetches the next page of intents. If the response + // to this API call is truncated, Amazon Lex returns a pagination token in the + // response. To fetch the next page of intents, specify the pagination token + // in the next request. + NextToken *string `locationName:"nextToken" type:"string"` +} + +// String returns the string representation +func (s GetBuiltinIntentsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBuiltinIntentsOutput) GoString() string { + return s.String() +} + +// SetIntents sets the Intents field's value. +func (s *GetBuiltinIntentsOutput) SetIntents(v []*BuiltinIntentMetadata) *GetBuiltinIntentsOutput { + s.Intents = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetBuiltinIntentsOutput) SetNextToken(v string) *GetBuiltinIntentsOutput { + s.NextToken = &v + return s +} + +type GetBuiltinSlotTypesInput struct { + _ struct{} `type:"structure"` + + // A list of locales that the slot type supports. + Locale *string `location:"querystring" locationName:"locale" type:"string" enum:"Locale"` + + // The maximum number of slot types to return in the response. The default is + // 10. + MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` + + // A pagination token that fetches the next page of slot types. If the response + // to this API call is truncated, Amazon Lex returns a pagination token in the + // response. To fetch the next page of slot types, specify the pagination token + // in the next request. + NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` + + // Substring to match in built-in slot type signatures. A slot type will be + // returned if any part of its signature matches the substring. For example, + // "xyz" matches both "xyzabc" and "abcxyz." + SignatureContains *string `location:"querystring" locationName:"signatureContains" type:"string"` +} + +// String returns the string representation +func (s GetBuiltinSlotTypesInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBuiltinSlotTypesInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetBuiltinSlotTypesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetBuiltinSlotTypesInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetLocale sets the Locale field's value. +func (s *GetBuiltinSlotTypesInput) SetLocale(v string) *GetBuiltinSlotTypesInput { + s.Locale = &v + return s +} + +// SetMaxResults sets the MaxResults field's value. +func (s *GetBuiltinSlotTypesInput) SetMaxResults(v int64) *GetBuiltinSlotTypesInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetBuiltinSlotTypesInput) SetNextToken(v string) *GetBuiltinSlotTypesInput { + s.NextToken = &v + return s +} + +// SetSignatureContains sets the SignatureContains field's value. +func (s *GetBuiltinSlotTypesInput) SetSignatureContains(v string) *GetBuiltinSlotTypesInput { + s.SignatureContains = &v + return s +} + +type GetBuiltinSlotTypesOutput struct { + _ struct{} `type:"structure"` + + // If the response is truncated, the response includes a pagination token that + // you can use in your next request to fetch the next page of slot types. + NextToken *string `locationName:"nextToken" type:"string"` + + // An array of BuiltInSlotTypeMetadata objects, one entry for each slot type + // returned. + SlotTypes []*BuiltinSlotTypeMetadata `locationName:"slotTypes" type:"list"` +} + +// String returns the string representation +func (s GetBuiltinSlotTypesOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetBuiltinSlotTypesOutput) GoString() string { + return s.String() +} + +// SetNextToken sets the NextToken field's value. +func (s *GetBuiltinSlotTypesOutput) SetNextToken(v string) *GetBuiltinSlotTypesOutput { + s.NextToken = &v + return s +} + +// SetSlotTypes sets the SlotTypes field's value. +func (s *GetBuiltinSlotTypesOutput) SetSlotTypes(v []*BuiltinSlotTypeMetadata) *GetBuiltinSlotTypesOutput { + s.SlotTypes = v + return s +} + +type GetExportInput struct { + _ struct{} `type:"structure"` + + // The format of the exported data. + // + // ExportType is a required field + ExportType *string `location:"querystring" locationName:"exportType" type:"string" required:"true" enum:"ExportType"` + + // The name of the bot to export. + // + // Name is a required field + Name *string `location:"querystring" locationName:"name" min:"1" type:"string" required:"true"` + + // The type of resource to export. + // + // ResourceType is a required field + ResourceType *string `location:"querystring" locationName:"resourceType" type:"string" required:"true" enum:"ResourceType"` + + // The version of the bot to export. + // + // Version is a required field + Version *string `location:"querystring" locationName:"version" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s GetExportInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetExportInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetExportInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetExportInput"} + if s.ExportType == nil { + invalidParams.Add(request.NewErrParamRequired("ExportType")) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + if s.ResourceType == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceType")) + } + if s.Version == nil { + invalidParams.Add(request.NewErrParamRequired("Version")) + } + if s.Version != nil && len(*s.Version) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Version", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetExportType sets the ExportType field's value. +func (s *GetExportInput) SetExportType(v string) *GetExportInput { + s.ExportType = &v + return s +} + +// SetName sets the Name field's value. +func (s *GetExportInput) SetName(v string) *GetExportInput { + s.Name = &v + return s +} + +// SetResourceType sets the ResourceType field's value. +func (s *GetExportInput) SetResourceType(v string) *GetExportInput { + s.ResourceType = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *GetExportInput) SetVersion(v string) *GetExportInput { + s.Version = &v + return s +} + +type GetExportOutput struct { + _ struct{} `type:"structure"` + + // The status of the export. + // + // * IN_PROGRESS - The export is in progress. + // + // * READY - The export is complete. + // + // * FAILED - The export could not be completed. + ExportStatus *string `locationName:"exportStatus" type:"string" enum:"ExportStatus"` + + // The format of the exported data. + ExportType *string `locationName:"exportType" type:"string" enum:"ExportType"` + + // If status is FAILED, Amazon Lex provides the reason that it failed to export + // the resource. + FailureReason *string `locationName:"failureReason" type:"string"` + + // The name of the bot being exported. + Name *string `locationName:"name" min:"1" type:"string"` + + // The type of the exported resource. + ResourceType *string `locationName:"resourceType" type:"string" enum:"ResourceType"` + + // An S3 pre-signed URL that provides the location of the exported resource. + // The exported resource is a ZIP archive that contains the exported resource + // in JSON format. The structure of the archive may change. Your code should + // not rely on the archive structure. + Url *string `locationName:"url" type:"string"` + + // The version of the bot being exported. + Version *string `locationName:"version" min:"1" type:"string"` +} + +// String returns the string representation +func (s GetExportOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetExportOutput) GoString() string { + return s.String() +} + +// SetExportStatus sets the ExportStatus field's value. +func (s *GetExportOutput) SetExportStatus(v string) *GetExportOutput { + s.ExportStatus = &v + return s +} + +// SetExportType sets the ExportType field's value. +func (s *GetExportOutput) SetExportType(v string) *GetExportOutput { + s.ExportType = &v + return s +} + +// SetFailureReason sets the FailureReason field's value. +func (s *GetExportOutput) SetFailureReason(v string) *GetExportOutput { + s.FailureReason = &v + return s +} + +// SetName sets the Name field's value. +func (s *GetExportOutput) SetName(v string) *GetExportOutput { + s.Name = &v + return s +} + +// SetResourceType sets the ResourceType field's value. +func (s *GetExportOutput) SetResourceType(v string) *GetExportOutput { + s.ResourceType = &v + return s +} + +// SetUrl sets the Url field's value. +func (s *GetExportOutput) SetUrl(v string) *GetExportOutput { + s.Url = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *GetExportOutput) SetVersion(v string) *GetExportOutput { + s.Version = &v + return s +} + +type GetImportInput struct { + _ struct{} `type:"structure"` + + // The identifier of the import job information to return. + // + // ImportId is a required field + ImportId *string `location:"uri" locationName:"importId" type:"string" required:"true"` +} + +// String returns the string representation +func (s GetImportInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetImportInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetImportInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetImportInput"} + if s.ImportId == nil { + invalidParams.Add(request.NewErrParamRequired("ImportId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetImportId sets the ImportId field's value. +func (s *GetImportInput) SetImportId(v string) *GetImportInput { + s.ImportId = &v + return s +} + +type GetImportOutput struct { + _ struct{} `type:"structure"` + + // A timestamp for the date and time that the import job was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A string that describes why an import job failed to complete. + FailureReason []*string `locationName:"failureReason" type:"list"` + + // The identifier for the specific import job. + ImportId *string `locationName:"importId" type:"string"` + + // The status of the import job. If the status is FAILED, you can get the reason + // for the failure from the failureReason field. + ImportStatus *string `locationName:"importStatus" type:"string" enum:"ImportStatus"` + + // The action taken when there was a conflict between an existing resource and + // a resource in the import file. + MergeStrategy *string `locationName:"mergeStrategy" type:"string" enum:"MergeStrategy"` + + // The name given to the import job. + Name *string `locationName:"name" min:"1" type:"string"` + + // The type of resource imported. + ResourceType *string `locationName:"resourceType" type:"string" enum:"ResourceType"` +} + +// String returns the string representation +func (s GetImportOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetImportOutput) GoString() string { + return s.String() +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *GetImportOutput) SetCreatedDate(v time.Time) *GetImportOutput { + s.CreatedDate = &v + return s +} + +// SetFailureReason sets the FailureReason field's value. +func (s *GetImportOutput) SetFailureReason(v []*string) *GetImportOutput { + s.FailureReason = v + return s +} + +// SetImportId sets the ImportId field's value. +func (s *GetImportOutput) SetImportId(v string) *GetImportOutput { + s.ImportId = &v + return s +} + +// SetImportStatus sets the ImportStatus field's value. +func (s *GetImportOutput) SetImportStatus(v string) *GetImportOutput { + s.ImportStatus = &v + return s +} + +// SetMergeStrategy sets the MergeStrategy field's value. +func (s *GetImportOutput) SetMergeStrategy(v string) *GetImportOutput { + s.MergeStrategy = &v + return s +} + +// SetName sets the Name field's value. +func (s *GetImportOutput) SetName(v string) *GetImportOutput { + s.Name = &v + return s +} + +// SetResourceType sets the ResourceType field's value. +func (s *GetImportOutput) SetResourceType(v string) *GetImportOutput { + s.ResourceType = &v + return s +} + +type GetIntentInput struct { + _ struct{} `type:"structure"` + + // The name of the intent. The name is case sensitive. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` + + // The version of the intent. + // + // Version is a required field + Version *string `location:"uri" locationName:"version" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s GetIntentInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetIntentInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetIntentInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetIntentInput"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + if s.Version == nil { + invalidParams.Add(request.NewErrParamRequired("Version")) + } + if s.Version != nil && len(*s.Version) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Version", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetName sets the Name field's value. +func (s *GetIntentInput) SetName(v string) *GetIntentInput { + s.Name = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *GetIntentInput) SetVersion(v string) *GetIntentInput { + s.Version = &v + return s +} + +type GetIntentOutput struct { + _ struct{} `type:"structure"` + + // Checksum of the intent. + Checksum *string `locationName:"checksum" type:"string"` + + // After the Lambda function specified in the fulfillmentActivity element fulfills + // the intent, Amazon Lex conveys this statement to the user. + ConclusionStatement *Statement `locationName:"conclusionStatement" type:"structure"` + + // If defined in the bot, Amazon Lex uses prompt to confirm the intent before + // fulfilling the user's request. For more information, see PutIntent. + ConfirmationPrompt *Prompt `locationName:"confirmationPrompt" type:"structure"` + + // The date that the intent was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A description of the intent. + Description *string `locationName:"description" type:"string"` + + // If defined in the bot, Amazon Amazon Lex invokes this Lambda function for + // each user input. For more information, see PutIntent. + DialogCodeHook *CodeHook `locationName:"dialogCodeHook" type:"structure"` + + // If defined in the bot, Amazon Lex uses this prompt to solicit additional + // user activity after the intent is fulfilled. For more information, see PutIntent. + FollowUpPrompt *FollowUpPrompt `locationName:"followUpPrompt" type:"structure"` + + // Describes how the intent is fulfilled. For more information, see PutIntent. + FulfillmentActivity *FulfillmentActivity `locationName:"fulfillmentActivity" type:"structure"` + + // The date that the intent was updated. When you create a resource, the creation + // date and the last updated date are the same. + LastUpdatedDate *time.Time `locationName:"lastUpdatedDate" type:"timestamp" timestampFormat:"unix"` + + // The name of the intent. + Name *string `locationName:"name" min:"1" type:"string"` + + // A unique identifier for a built-in intent. + ParentIntentSignature *string `locationName:"parentIntentSignature" type:"string"` + + // If the user answers "no" to the question defined in confirmationPrompt, Amazon + // Lex responds with this statement to acknowledge that the intent was canceled. + RejectionStatement *Statement `locationName:"rejectionStatement" type:"structure"` + + // An array of sample utterances configured for the intent. + SampleUtterances []*string `locationName:"sampleUtterances" type:"list"` + + // An array of intent slots configured for the intent. + Slots []*Slot `locationName:"slots" type:"list"` + + // The version of the intent. + Version *string `locationName:"version" min:"1" type:"string"` +} + +// String returns the string representation +func (s GetIntentOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetIntentOutput) GoString() string { + return s.String() +} + +// SetChecksum sets the Checksum field's value. +func (s *GetIntentOutput) SetChecksum(v string) *GetIntentOutput { + s.Checksum = &v + return s +} + +// SetConclusionStatement sets the ConclusionStatement field's value. +func (s *GetIntentOutput) SetConclusionStatement(v *Statement) *GetIntentOutput { + s.ConclusionStatement = v + return s +} + +// SetConfirmationPrompt sets the ConfirmationPrompt field's value. +func (s *GetIntentOutput) SetConfirmationPrompt(v *Prompt) *GetIntentOutput { + s.ConfirmationPrompt = v + return s +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *GetIntentOutput) SetCreatedDate(v time.Time) *GetIntentOutput { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *GetIntentOutput) SetDescription(v string) *GetIntentOutput { + s.Description = &v + return s +} + +// SetDialogCodeHook sets the DialogCodeHook field's value. +func (s *GetIntentOutput) SetDialogCodeHook(v *CodeHook) *GetIntentOutput { + s.DialogCodeHook = v + return s +} + +// SetFollowUpPrompt sets the FollowUpPrompt field's value. +func (s *GetIntentOutput) SetFollowUpPrompt(v *FollowUpPrompt) *GetIntentOutput { + s.FollowUpPrompt = v + return s +} + +// SetFulfillmentActivity sets the FulfillmentActivity field's value. +func (s *GetIntentOutput) SetFulfillmentActivity(v *FulfillmentActivity) *GetIntentOutput { + s.FulfillmentActivity = v + return s +} + +// SetLastUpdatedDate sets the LastUpdatedDate field's value. +func (s *GetIntentOutput) SetLastUpdatedDate(v time.Time) *GetIntentOutput { + s.LastUpdatedDate = &v + return s +} + +// SetName sets the Name field's value. +func (s *GetIntentOutput) SetName(v string) *GetIntentOutput { + s.Name = &v + return s +} + +// SetParentIntentSignature sets the ParentIntentSignature field's value. +func (s *GetIntentOutput) SetParentIntentSignature(v string) *GetIntentOutput { + s.ParentIntentSignature = &v + return s +} + +// SetRejectionStatement sets the RejectionStatement field's value. +func (s *GetIntentOutput) SetRejectionStatement(v *Statement) *GetIntentOutput { + s.RejectionStatement = v + return s +} + +// SetSampleUtterances sets the SampleUtterances field's value. +func (s *GetIntentOutput) SetSampleUtterances(v []*string) *GetIntentOutput { + s.SampleUtterances = v + return s +} + +// SetSlots sets the Slots field's value. +func (s *GetIntentOutput) SetSlots(v []*Slot) *GetIntentOutput { + s.Slots = v + return s +} + +// SetVersion sets the Version field's value. +func (s *GetIntentOutput) SetVersion(v string) *GetIntentOutput { + s.Version = &v + return s +} + +type GetIntentVersionsInput struct { + _ struct{} `type:"structure"` + + // The maximum number of intent versions to return in the response. The default + // is 10. + MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` + + // The name of the intent for which versions should be returned. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` + + // A pagination token for fetching the next page of intent versions. If the + // response to this call is truncated, Amazon Lex returns a pagination token + // in the response. To fetch the next page of versions, specify the pagination + // token in the next request. + NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` +} + +// String returns the string representation +func (s GetIntentVersionsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetIntentVersionsInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetIntentVersionsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetIntentVersionsInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMaxResults sets the MaxResults field's value. +func (s *GetIntentVersionsInput) SetMaxResults(v int64) *GetIntentVersionsInput { + s.MaxResults = &v + return s +} + +// SetName sets the Name field's value. +func (s *GetIntentVersionsInput) SetName(v string) *GetIntentVersionsInput { + s.Name = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetIntentVersionsInput) SetNextToken(v string) *GetIntentVersionsInput { + s.NextToken = &v + return s +} + +type GetIntentVersionsOutput struct { + _ struct{} `type:"structure"` + + // An array of IntentMetadata objects, one for each numbered version of the + // intent plus one for the $LATEST version. + Intents []*IntentMetadata `locationName:"intents" type:"list"` + + // A pagination token for fetching the next page of intent versions. If the + // response to this call is truncated, Amazon Lex returns a pagination token + // in the response. To fetch the next page of versions, specify the pagination + // token in the next request. + NextToken *string `locationName:"nextToken" type:"string"` +} + +// String returns the string representation +func (s GetIntentVersionsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetIntentVersionsOutput) GoString() string { + return s.String() +} + +// SetIntents sets the Intents field's value. +func (s *GetIntentVersionsOutput) SetIntents(v []*IntentMetadata) *GetIntentVersionsOutput { + s.Intents = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetIntentVersionsOutput) SetNextToken(v string) *GetIntentVersionsOutput { + s.NextToken = &v + return s +} + +type GetIntentsInput struct { + _ struct{} `type:"structure"` + + // The maximum number of intents to return in the response. The default is 10. + MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` + + // Substring to match in intent names. An intent will be returned if any part + // of its name matches the substring. For example, "xyz" matches both "xyzabc" + // and "abcxyz." + NameContains *string `location:"querystring" locationName:"nameContains" min:"1" type:"string"` + + // A pagination token that fetches the next page of intents. If the response + // to this API call is truncated, Amazon Lex returns a pagination token in the + // response. To fetch the next page of intents, specify the pagination token + // in the next request. + NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` +} + +// String returns the string representation +func (s GetIntentsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetIntentsInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetIntentsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetIntentsInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.NameContains != nil && len(*s.NameContains) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NameContains", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMaxResults sets the MaxResults field's value. +func (s *GetIntentsInput) SetMaxResults(v int64) *GetIntentsInput { + s.MaxResults = &v + return s +} + +// SetNameContains sets the NameContains field's value. +func (s *GetIntentsInput) SetNameContains(v string) *GetIntentsInput { + s.NameContains = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetIntentsInput) SetNextToken(v string) *GetIntentsInput { + s.NextToken = &v + return s +} + +type GetIntentsOutput struct { + _ struct{} `type:"structure"` + + // An array of Intent objects. For more information, see PutBot. + Intents []*IntentMetadata `locationName:"intents" type:"list"` + + // If the response is truncated, the response includes a pagination token that + // you can specify in your next request to fetch the next page of intents. + NextToken *string `locationName:"nextToken" type:"string"` +} + +// String returns the string representation +func (s GetIntentsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetIntentsOutput) GoString() string { + return s.String() +} + +// SetIntents sets the Intents field's value. +func (s *GetIntentsOutput) SetIntents(v []*IntentMetadata) *GetIntentsOutput { + s.Intents = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetIntentsOutput) SetNextToken(v string) *GetIntentsOutput { + s.NextToken = &v + return s +} + +type GetSlotTypeInput struct { + _ struct{} `type:"structure"` + + // The name of the slot type. The name is case sensitive. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` + + // The version of the slot type. + // + // Version is a required field + Version *string `location:"uri" locationName:"version" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s GetSlotTypeInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetSlotTypeInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetSlotTypeInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetSlotTypeInput"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + if s.Version == nil { + invalidParams.Add(request.NewErrParamRequired("Version")) + } + if s.Version != nil && len(*s.Version) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Version", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetName sets the Name field's value. +func (s *GetSlotTypeInput) SetName(v string) *GetSlotTypeInput { + s.Name = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *GetSlotTypeInput) SetVersion(v string) *GetSlotTypeInput { + s.Version = &v + return s +} + +type GetSlotTypeOutput struct { + _ struct{} `type:"structure"` + + // Checksum of the $LATEST version of the slot type. + Checksum *string `locationName:"checksum" type:"string"` + + // The date that the slot type was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A description of the slot type. + Description *string `locationName:"description" type:"string"` + + // A list of EnumerationValue objects that defines the values that the slot + // type can take. + EnumerationValues []*EnumerationValue `locationName:"enumerationValues" min:"1" type:"list"` + + // The date that the slot type was updated. When you create a resource, the + // creation date and last update date are the same. + LastUpdatedDate *time.Time `locationName:"lastUpdatedDate" type:"timestamp" timestampFormat:"unix"` + + // The name of the slot type. + Name *string `locationName:"name" min:"1" type:"string"` + + // The strategy that Amazon Lex uses to determine the value of the slot. For + // more information, see PutSlotType. + ValueSelectionStrategy *string `locationName:"valueSelectionStrategy" type:"string" enum:"SlotValueSelectionStrategy"` + + // The version of the slot type. + Version *string `locationName:"version" min:"1" type:"string"` +} + +// String returns the string representation +func (s GetSlotTypeOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetSlotTypeOutput) GoString() string { + return s.String() +} + +// SetChecksum sets the Checksum field's value. +func (s *GetSlotTypeOutput) SetChecksum(v string) *GetSlotTypeOutput { + s.Checksum = &v + return s +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *GetSlotTypeOutput) SetCreatedDate(v time.Time) *GetSlotTypeOutput { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *GetSlotTypeOutput) SetDescription(v string) *GetSlotTypeOutput { + s.Description = &v + return s +} + +// SetEnumerationValues sets the EnumerationValues field's value. +func (s *GetSlotTypeOutput) SetEnumerationValues(v []*EnumerationValue) *GetSlotTypeOutput { + s.EnumerationValues = v + return s +} + +// SetLastUpdatedDate sets the LastUpdatedDate field's value. +func (s *GetSlotTypeOutput) SetLastUpdatedDate(v time.Time) *GetSlotTypeOutput { + s.LastUpdatedDate = &v + return s +} + +// SetName sets the Name field's value. +func (s *GetSlotTypeOutput) SetName(v string) *GetSlotTypeOutput { + s.Name = &v + return s +} + +// SetValueSelectionStrategy sets the ValueSelectionStrategy field's value. +func (s *GetSlotTypeOutput) SetValueSelectionStrategy(v string) *GetSlotTypeOutput { + s.ValueSelectionStrategy = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *GetSlotTypeOutput) SetVersion(v string) *GetSlotTypeOutput { + s.Version = &v + return s +} + +type GetSlotTypeVersionsInput struct { + _ struct{} `type:"structure"` + + // The maximum number of slot type versions to return in the response. The default + // is 10. + MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` + + // The name of the slot type for which versions should be returned. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` + + // A pagination token for fetching the next page of slot type versions. If the + // response to this call is truncated, Amazon Lex returns a pagination token + // in the response. To fetch the next page of versions, specify the pagination + // token in the next request. + NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` +} + +// String returns the string representation +func (s GetSlotTypeVersionsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetSlotTypeVersionsInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetSlotTypeVersionsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetSlotTypeVersionsInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMaxResults sets the MaxResults field's value. +func (s *GetSlotTypeVersionsInput) SetMaxResults(v int64) *GetSlotTypeVersionsInput { + s.MaxResults = &v + return s +} + +// SetName sets the Name field's value. +func (s *GetSlotTypeVersionsInput) SetName(v string) *GetSlotTypeVersionsInput { + s.Name = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetSlotTypeVersionsInput) SetNextToken(v string) *GetSlotTypeVersionsInput { + s.NextToken = &v + return s +} + +type GetSlotTypeVersionsOutput struct { + _ struct{} `type:"structure"` + + // A pagination token for fetching the next page of slot type versions. If the + // response to this call is truncated, Amazon Lex returns a pagination token + // in the response. To fetch the next page of versions, specify the pagination + // token in the next request. + NextToken *string `locationName:"nextToken" type:"string"` + + // An array of SlotTypeMetadata objects, one for each numbered version of the + // slot type plus one for the $LATEST version. + SlotTypes []*SlotTypeMetadata `locationName:"slotTypes" type:"list"` +} + +// String returns the string representation +func (s GetSlotTypeVersionsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetSlotTypeVersionsOutput) GoString() string { + return s.String() +} + +// SetNextToken sets the NextToken field's value. +func (s *GetSlotTypeVersionsOutput) SetNextToken(v string) *GetSlotTypeVersionsOutput { + s.NextToken = &v + return s +} + +// SetSlotTypes sets the SlotTypes field's value. +func (s *GetSlotTypeVersionsOutput) SetSlotTypes(v []*SlotTypeMetadata) *GetSlotTypeVersionsOutput { + s.SlotTypes = v + return s +} + +type GetSlotTypesInput struct { + _ struct{} `type:"structure"` + + // The maximum number of slot types to return in the response. The default is + // 10. + MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"` + + // Substring to match in slot type names. A slot type will be returned if any + // part of its name matches the substring. For example, "xyz" matches both "xyzabc" + // and "abcxyz." + NameContains *string `location:"querystring" locationName:"nameContains" min:"1" type:"string"` + + // A pagination token that fetches the next page of slot types. If the response + // to this API call is truncated, Amazon Lex returns a pagination token in the + // response. To fetch next page of slot types, specify the pagination token + // in the next request. + NextToken *string `location:"querystring" locationName:"nextToken" type:"string"` +} + +// String returns the string representation +func (s GetSlotTypesInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetSlotTypesInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetSlotTypesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetSlotTypesInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.NameContains != nil && len(*s.NameContains) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NameContains", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMaxResults sets the MaxResults field's value. +func (s *GetSlotTypesInput) SetMaxResults(v int64) *GetSlotTypesInput { + s.MaxResults = &v + return s +} + +// SetNameContains sets the NameContains field's value. +func (s *GetSlotTypesInput) SetNameContains(v string) *GetSlotTypesInput { + s.NameContains = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *GetSlotTypesInput) SetNextToken(v string) *GetSlotTypesInput { + s.NextToken = &v + return s +} + +type GetSlotTypesOutput struct { + _ struct{} `type:"structure"` + + // If the response is truncated, it includes a pagination token that you can + // specify in your next request to fetch the next page of slot types. + NextToken *string `locationName:"nextToken" type:"string"` + + // An array of objects, one for each slot type, that provides information such + // as the name of the slot type, the version, and a description. + SlotTypes []*SlotTypeMetadata `locationName:"slotTypes" type:"list"` +} + +// String returns the string representation +func (s GetSlotTypesOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetSlotTypesOutput) GoString() string { + return s.String() +} + +// SetNextToken sets the NextToken field's value. +func (s *GetSlotTypesOutput) SetNextToken(v string) *GetSlotTypesOutput { + s.NextToken = &v + return s +} + +// SetSlotTypes sets the SlotTypes field's value. +func (s *GetSlotTypesOutput) SetSlotTypes(v []*SlotTypeMetadata) *GetSlotTypesOutput { + s.SlotTypes = v + return s +} + +type GetUtterancesViewInput struct { + _ struct{} `type:"structure"` + + // The name of the bot for which utterance information should be returned. + // + // BotName is a required field + BotName *string `location:"uri" locationName:"botname" min:"2" type:"string" required:"true"` + + // An array of bot versions for which utterance information should be returned. + // The limit is 5 versions per request. + // + // BotVersions is a required field + BotVersions []*string `location:"querystring" locationName:"bot_versions" min:"1" type:"list" required:"true"` + + // To return utterances that were recognized and handled, useDetected. To return + // utterances that were not recognized, use Missed. + // + // StatusType is a required field + StatusType *string `location:"querystring" locationName:"status_type" type:"string" required:"true" enum:"StatusType"` +} + +// String returns the string representation +func (s GetUtterancesViewInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetUtterancesViewInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetUtterancesViewInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetUtterancesViewInput"} + if s.BotName == nil { + invalidParams.Add(request.NewErrParamRequired("BotName")) + } + if s.BotName != nil && len(*s.BotName) < 2 { + invalidParams.Add(request.NewErrParamMinLen("BotName", 2)) + } + if s.BotVersions == nil { + invalidParams.Add(request.NewErrParamRequired("BotVersions")) + } + if s.BotVersions != nil && len(s.BotVersions) < 1 { + invalidParams.Add(request.NewErrParamMinLen("BotVersions", 1)) + } + if s.StatusType == nil { + invalidParams.Add(request.NewErrParamRequired("StatusType")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetBotName sets the BotName field's value. +func (s *GetUtterancesViewInput) SetBotName(v string) *GetUtterancesViewInput { + s.BotName = &v + return s +} + +// SetBotVersions sets the BotVersions field's value. +func (s *GetUtterancesViewInput) SetBotVersions(v []*string) *GetUtterancesViewInput { + s.BotVersions = v + return s +} + +// SetStatusType sets the StatusType field's value. +func (s *GetUtterancesViewInput) SetStatusType(v string) *GetUtterancesViewInput { + s.StatusType = &v + return s +} + +type GetUtterancesViewOutput struct { + _ struct{} `type:"structure"` + + // The name of the bot for which utterance information was returned. + BotName *string `locationName:"botName" min:"2" type:"string"` + + // An array of UtteranceList objects, each containing a list of UtteranceData + // objects describing the utterances that were processed by your bot. The response + // contains a maximum of 100 UtteranceData objects for each version. + Utterances []*UtteranceList `locationName:"utterances" type:"list"` +} + +// String returns the string representation +func (s GetUtterancesViewOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetUtterancesViewOutput) GoString() string { + return s.String() +} + +// SetBotName sets the BotName field's value. +func (s *GetUtterancesViewOutput) SetBotName(v string) *GetUtterancesViewOutput { + s.BotName = &v + return s +} + +// SetUtterances sets the Utterances field's value. +func (s *GetUtterancesViewOutput) SetUtterances(v []*UtteranceList) *GetUtterancesViewOutput { + s.Utterances = v + return s +} + +// Identifies the specific version of an intent. +type Intent struct { + _ struct{} `type:"structure"` + + // The name of the intent. + // + // IntentName is a required field + IntentName *string `locationName:"intentName" min:"1" type:"string" required:"true"` + + // The version of the intent. + // + // IntentVersion is a required field + IntentVersion *string `locationName:"intentVersion" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s Intent) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s Intent) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *Intent) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "Intent"} + if s.IntentName == nil { + invalidParams.Add(request.NewErrParamRequired("IntentName")) + } + if s.IntentName != nil && len(*s.IntentName) < 1 { + invalidParams.Add(request.NewErrParamMinLen("IntentName", 1)) + } + if s.IntentVersion == nil { + invalidParams.Add(request.NewErrParamRequired("IntentVersion")) + } + if s.IntentVersion != nil && len(*s.IntentVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("IntentVersion", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetIntentName sets the IntentName field's value. +func (s *Intent) SetIntentName(v string) *Intent { + s.IntentName = &v + return s +} + +// SetIntentVersion sets the IntentVersion field's value. +func (s *Intent) SetIntentVersion(v string) *Intent { + s.IntentVersion = &v + return s +} + +// Provides information about an intent. +type IntentMetadata struct { + _ struct{} `type:"structure"` + + // The date that the intent was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A description of the intent. + Description *string `locationName:"description" type:"string"` + + // The date that the intent was updated. When you create an intent, the creation + // date and last updated date are the same. + LastUpdatedDate *time.Time `locationName:"lastUpdatedDate" type:"timestamp" timestampFormat:"unix"` + + // The name of the intent. + Name *string `locationName:"name" min:"1" type:"string"` + + // The version of the intent. + Version *string `locationName:"version" min:"1" type:"string"` +} + +// String returns the string representation +func (s IntentMetadata) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s IntentMetadata) GoString() string { + return s.String() +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *IntentMetadata) SetCreatedDate(v time.Time) *IntentMetadata { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *IntentMetadata) SetDescription(v string) *IntentMetadata { + s.Description = &v + return s +} + +// SetLastUpdatedDate sets the LastUpdatedDate field's value. +func (s *IntentMetadata) SetLastUpdatedDate(v time.Time) *IntentMetadata { + s.LastUpdatedDate = &v + return s +} + +// SetName sets the Name field's value. +func (s *IntentMetadata) SetName(v string) *IntentMetadata { + s.Name = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *IntentMetadata) SetVersion(v string) *IntentMetadata { + s.Version = &v + return s +} + +// The message object that provides the message text and its type. +type Message struct { + _ struct{} `type:"structure"` + + // The text of the message. + // + // Content is a required field + Content *string `locationName:"content" min:"1" type:"string" required:"true"` + + // The content type of the message string. + // + // ContentType is a required field + ContentType *string `locationName:"contentType" type:"string" required:"true" enum:"ContentType"` + + // Identifies the message group that the message belongs to. When a group is + // assigned to a message, Amazon Lex returns one message from each group in + // the response. + GroupNumber *int64 `locationName:"groupNumber" min:"1" type:"integer"` +} + +// String returns the string representation +func (s Message) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s Message) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *Message) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "Message"} + if s.Content == nil { + invalidParams.Add(request.NewErrParamRequired("Content")) + } + if s.Content != nil && len(*s.Content) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Content", 1)) + } + if s.ContentType == nil { + invalidParams.Add(request.NewErrParamRequired("ContentType")) + } + if s.GroupNumber != nil && *s.GroupNumber < 1 { + invalidParams.Add(request.NewErrParamMinValue("GroupNumber", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetContent sets the Content field's value. +func (s *Message) SetContent(v string) *Message { + s.Content = &v + return s +} + +// SetContentType sets the ContentType field's value. +func (s *Message) SetContentType(v string) *Message { + s.ContentType = &v + return s +} + +// SetGroupNumber sets the GroupNumber field's value. +func (s *Message) SetGroupNumber(v int64) *Message { + s.GroupNumber = &v + return s +} + +// Obtains information from the user. To define a prompt, provide one or more +// messages and specify the number of attempts to get information from the user. +// If you provide more than one message, Amazon Lex chooses one of the messages +// to use to prompt the user. For more information, see how-it-works. +type Prompt struct { + _ struct{} `type:"structure"` + + // The number of times to prompt the user for information. + // + // MaxAttempts is a required field + MaxAttempts *int64 `locationName:"maxAttempts" min:"1" type:"integer" required:"true"` + + // An array of objects, each of which provides a message string and its type. + // You can specify the message string in plain text or in Speech Synthesis Markup + // Language (SSML). + // + // Messages is a required field + Messages []*Message `locationName:"messages" min:"1" type:"list" required:"true"` + + // A response card. Amazon Lex uses this prompt at runtime, in the PostText + // API response. It substitutes session attributes and slot values for placeholders + // in the response card. For more information, see ex-resp-card. + ResponseCard *string `locationName:"responseCard" min:"1" type:"string"` +} + +// String returns the string representation +func (s Prompt) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s Prompt) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *Prompt) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "Prompt"} + if s.MaxAttempts == nil { + invalidParams.Add(request.NewErrParamRequired("MaxAttempts")) + } + if s.MaxAttempts != nil && *s.MaxAttempts < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxAttempts", 1)) + } + if s.Messages == nil { + invalidParams.Add(request.NewErrParamRequired("Messages")) + } + if s.Messages != nil && len(s.Messages) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Messages", 1)) + } + if s.ResponseCard != nil && len(*s.ResponseCard) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ResponseCard", 1)) + } + if s.Messages != nil { + for i, v := range s.Messages { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Messages", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMaxAttempts sets the MaxAttempts field's value. +func (s *Prompt) SetMaxAttempts(v int64) *Prompt { + s.MaxAttempts = &v + return s +} + +// SetMessages sets the Messages field's value. +func (s *Prompt) SetMessages(v []*Message) *Prompt { + s.Messages = v + return s +} + +// SetResponseCard sets the ResponseCard field's value. +func (s *Prompt) SetResponseCard(v string) *Prompt { + s.ResponseCard = &v + return s +} + +type PutBotAliasInput struct { + _ struct{} `type:"structure"` + + // The name of the bot. + // + // BotName is a required field + BotName *string `location:"uri" locationName:"botName" min:"2" type:"string" required:"true"` + + // The version of the bot. + // + // BotVersion is a required field + BotVersion *string `locationName:"botVersion" min:"1" type:"string" required:"true"` + + // Identifies a specific revision of the $LATEST version. + // + // When you create a new bot alias, leave the checksum field blank. If you specify + // a checksum you get a BadRequestException exception. + // + // When you want to update a bot alias, set the checksum field to the checksum + // of the most recent revision of the $LATEST version. If you don't specify + // the checksum field, or if the checksum does not match the $LATEST version, + // you get a PreconditionFailedException exception. + Checksum *string `locationName:"checksum" type:"string"` + + // A description of the alias. + Description *string `locationName:"description" type:"string"` + + // The name of the alias. The name is not case sensitive. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s PutBotAliasInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PutBotAliasInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *PutBotAliasInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PutBotAliasInput"} + if s.BotName == nil { + invalidParams.Add(request.NewErrParamRequired("BotName")) + } + if s.BotName != nil && len(*s.BotName) < 2 { + invalidParams.Add(request.NewErrParamMinLen("BotName", 2)) + } + if s.BotVersion == nil { + invalidParams.Add(request.NewErrParamRequired("BotVersion")) + } + if s.BotVersion != nil && len(*s.BotVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("BotVersion", 1)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetBotName sets the BotName field's value. +func (s *PutBotAliasInput) SetBotName(v string) *PutBotAliasInput { + s.BotName = &v + return s +} + +// SetBotVersion sets the BotVersion field's value. +func (s *PutBotAliasInput) SetBotVersion(v string) *PutBotAliasInput { + s.BotVersion = &v + return s +} + +// SetChecksum sets the Checksum field's value. +func (s *PutBotAliasInput) SetChecksum(v string) *PutBotAliasInput { + s.Checksum = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *PutBotAliasInput) SetDescription(v string) *PutBotAliasInput { + s.Description = &v + return s +} + +// SetName sets the Name field's value. +func (s *PutBotAliasInput) SetName(v string) *PutBotAliasInput { + s.Name = &v + return s +} + +type PutBotAliasOutput struct { + _ struct{} `type:"structure"` + + // The name of the bot that the alias points to. + BotName *string `locationName:"botName" min:"2" type:"string"` + + // The version of the bot that the alias points to. + BotVersion *string `locationName:"botVersion" min:"1" type:"string"` + + // The checksum for the current version of the alias. + Checksum *string `locationName:"checksum" type:"string"` + + // The date that the bot alias was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A description of the alias. + Description *string `locationName:"description" type:"string"` + + // The date that the bot alias was updated. When you create a resource, the + // creation date and the last updated date are the same. + LastUpdatedDate *time.Time `locationName:"lastUpdatedDate" type:"timestamp" timestampFormat:"unix"` + + // The name of the alias. + Name *string `locationName:"name" min:"1" type:"string"` +} + +// String returns the string representation +func (s PutBotAliasOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PutBotAliasOutput) GoString() string { + return s.String() +} + +// SetBotName sets the BotName field's value. +func (s *PutBotAliasOutput) SetBotName(v string) *PutBotAliasOutput { + s.BotName = &v + return s +} + +// SetBotVersion sets the BotVersion field's value. +func (s *PutBotAliasOutput) SetBotVersion(v string) *PutBotAliasOutput { + s.BotVersion = &v + return s +} + +// SetChecksum sets the Checksum field's value. +func (s *PutBotAliasOutput) SetChecksum(v string) *PutBotAliasOutput { + s.Checksum = &v + return s +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *PutBotAliasOutput) SetCreatedDate(v time.Time) *PutBotAliasOutput { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *PutBotAliasOutput) SetDescription(v string) *PutBotAliasOutput { + s.Description = &v + return s +} + +// SetLastUpdatedDate sets the LastUpdatedDate field's value. +func (s *PutBotAliasOutput) SetLastUpdatedDate(v time.Time) *PutBotAliasOutput { + s.LastUpdatedDate = &v + return s +} + +// SetName sets the Name field's value. +func (s *PutBotAliasOutput) SetName(v string) *PutBotAliasOutput { + s.Name = &v + return s +} + +type PutBotInput struct { + _ struct{} `type:"structure"` + + // When Amazon Lex can't understand the user's input in context, it tries to + // elicit the information a few times. After that, Amazon Lex sends the message + // defined in abortStatement to the user, and then aborts the conversation. + // To set the number of retries, use the valueElicitationPrompt field for the + // slot type. + // + // For example, in a pizza ordering bot, Amazon Lex might ask a user "What type + // of crust would you like?" If the user's response is not one of the expected + // responses (for example, "thin crust, "deep dish," etc.), Amazon Lex tries + // to elicit a correct response a few more times. + // + // For example, in a pizza ordering application, OrderPizza might be one of + // the intents. This intent might require the CrustType slot. You specify the + // valueElicitationPrompt field when you create the CrustType slot. + AbortStatement *Statement `locationName:"abortStatement" type:"structure"` + + // Identifies a specific revision of the $LATEST version. + // + // When you create a new bot, leave the checksum field blank. If you specify + // a checksum you get a BadRequestException exception. + // + // When you want to update a bot, set the checksum field to the checksum of + // the most recent revision of the $LATEST version. If you don't specify the + // checksum field, or if the checksum does not match the $LATEST version, you + // get a PreconditionFailedException exception. + Checksum *string `locationName:"checksum" type:"string"` + + // For each Amazon Lex bot created with the Amazon Lex Model Building Service, + // you must specify whether your use of Amazon Lex is related to a website, + // program, or other application that is directed or targeted, in whole or in + // part, to children under age 13 and subject to the Children's Online Privacy + // Protection Act (COPPA) by specifying true or false in the childDirected field. + // By specifying true in the childDirected field, you confirm that your use + // of Amazon Lex is related to a website, program, or other application that + // is directed or targeted, in whole or in part, to children under age 13 and + // subject to COPPA. By specifying false in the childDirected field, you confirm + // that your use of Amazon Lex is not related to a website, program, or other + // application that is directed or targeted, in whole or in part, to children + // under age 13 and subject to COPPA. You may not specify a default value for + // the childDirected field that does not accurately reflect whether your use + // of Amazon Lex is related to a website, program, or other application that + // is directed or targeted, in whole or in part, to children under age 13 and + // subject to COPPA. + // + // If your use of Amazon Lex relates to a website, program, or other application + // that is directed in whole or in part, to children under age 13, you must + // obtain any required verifiable parental consent under COPPA. For information + // regarding the use of Amazon Lex in connection with websites, programs, or + // other applications that are directed or targeted, in whole or in part, to + // children under age 13, see the Amazon Lex FAQ. (https://aws.amazon.com/lex/faqs#data-security) + // + // ChildDirected is a required field + ChildDirected *bool `locationName:"childDirected" type:"boolean" required:"true"` + + // When Amazon Lex doesn't understand the user's intent, it uses this message + // to get clarification. To specify how many times Amazon Lex should repeate + // the clarification prompt, use the maxAttempts field. If Amazon Lex still + // doesn't understand, it sends the message in the abortStatement field. + // + // When you create a clarification prompt, make sure that it suggests the correct + // response from the user. for example, for a bot that orders pizza and drinks, + // you might create this clarification prompt: "What would you like to do? You + // can say 'Order a pizza' or 'Order a drink.'" + ClarificationPrompt *Prompt `locationName:"clarificationPrompt" type:"structure"` + + CreateVersion *bool `locationName:"createVersion" type:"boolean"` + + // A description of the bot. + Description *string `locationName:"description" type:"string"` + + // The maximum time in seconds that Amazon Lex retains the data gathered in + // a conversation. + // + // A user interaction session remains active for the amount of time specified. + // If no conversation occurs during this time, the session expires and Amazon + // Lex deletes any data provided before the timeout. + // + // For example, suppose that a user chooses the OrderPizza intent, but gets + // sidetracked halfway through placing an order. If the user doesn't complete + // the order within the specified time, Amazon Lex discards the slot information + // that it gathered, and the user must start over. + // + // If you don't include the idleSessionTTLInSeconds element in a PutBot operation + // request, Amazon Lex uses the default value. This is also true if the request + // replaces an existing bot. + // + // The default is 300 seconds (5 minutes). + IdleSessionTTLInSeconds *int64 `locationName:"idleSessionTTLInSeconds" min:"60" type:"integer"` + + // An array of Intent objects. Each intent represents a command that a user + // can express. For example, a pizza ordering bot might support an OrderPizza + // intent. For more information, see how-it-works. + Intents []*Intent `locationName:"intents" type:"list"` + + // Specifies the target locale for the bot. Any intent used in the bot must + // be compatible with the locale of the bot. + // + // The default is en-US. + // + // Locale is a required field + Locale *string `locationName:"locale" type:"string" required:"true" enum:"Locale"` + + // The name of the bot. The name is not case sensitive. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"2" type:"string" required:"true"` + + // If you set the processBehavior element to BUILD, Amazon Lex builds the bot + // so that it can be run. If you set the element to SAVE Amazon Lex saves the + // bot, but doesn't build it. + // + // If you don't specify this value, the default value is BUILD. + ProcessBehavior *string `locationName:"processBehavior" type:"string" enum:"ProcessBehavior"` + + // The Amazon Polly voice ID that you want Amazon Lex to use for voice interactions + // with the user. The locale configured for the voice must match the locale + // of the bot. For more information, see Available Voices (http://docs.aws.amazon.com/polly/latest/dg/voicelist.html) + // in the Amazon Polly Developer Guide. + VoiceId *string `locationName:"voiceId" type:"string"` +} + +// String returns the string representation +func (s PutBotInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PutBotInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *PutBotInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PutBotInput"} + if s.ChildDirected == nil { + invalidParams.Add(request.NewErrParamRequired("ChildDirected")) + } + if s.IdleSessionTTLInSeconds != nil && *s.IdleSessionTTLInSeconds < 60 { + invalidParams.Add(request.NewErrParamMinValue("IdleSessionTTLInSeconds", 60)) + } + if s.Locale == nil { + invalidParams.Add(request.NewErrParamRequired("Locale")) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Name", 2)) + } + if s.AbortStatement != nil { + if err := s.AbortStatement.Validate(); err != nil { + invalidParams.AddNested("AbortStatement", err.(request.ErrInvalidParams)) + } + } + if s.ClarificationPrompt != nil { + if err := s.ClarificationPrompt.Validate(); err != nil { + invalidParams.AddNested("ClarificationPrompt", err.(request.ErrInvalidParams)) + } + } + if s.Intents != nil { + for i, v := range s.Intents { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Intents", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAbortStatement sets the AbortStatement field's value. +func (s *PutBotInput) SetAbortStatement(v *Statement) *PutBotInput { + s.AbortStatement = v + return s +} + +// SetChecksum sets the Checksum field's value. +func (s *PutBotInput) SetChecksum(v string) *PutBotInput { + s.Checksum = &v + return s +} + +// SetChildDirected sets the ChildDirected field's value. +func (s *PutBotInput) SetChildDirected(v bool) *PutBotInput { + s.ChildDirected = &v + return s +} + +// SetClarificationPrompt sets the ClarificationPrompt field's value. +func (s *PutBotInput) SetClarificationPrompt(v *Prompt) *PutBotInput { + s.ClarificationPrompt = v + return s +} + +// SetCreateVersion sets the CreateVersion field's value. +func (s *PutBotInput) SetCreateVersion(v bool) *PutBotInput { + s.CreateVersion = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *PutBotInput) SetDescription(v string) *PutBotInput { + s.Description = &v + return s +} + +// SetIdleSessionTTLInSeconds sets the IdleSessionTTLInSeconds field's value. +func (s *PutBotInput) SetIdleSessionTTLInSeconds(v int64) *PutBotInput { + s.IdleSessionTTLInSeconds = &v + return s +} + +// SetIntents sets the Intents field's value. +func (s *PutBotInput) SetIntents(v []*Intent) *PutBotInput { + s.Intents = v + return s +} + +// SetLocale sets the Locale field's value. +func (s *PutBotInput) SetLocale(v string) *PutBotInput { + s.Locale = &v + return s +} + +// SetName sets the Name field's value. +func (s *PutBotInput) SetName(v string) *PutBotInput { + s.Name = &v + return s +} + +// SetProcessBehavior sets the ProcessBehavior field's value. +func (s *PutBotInput) SetProcessBehavior(v string) *PutBotInput { + s.ProcessBehavior = &v + return s +} + +// SetVoiceId sets the VoiceId field's value. +func (s *PutBotInput) SetVoiceId(v string) *PutBotInput { + s.VoiceId = &v + return s +} + +type PutBotOutput struct { + _ struct{} `type:"structure"` + + // The message that Amazon Lex uses to abort a conversation. For more information, + // see PutBot. + AbortStatement *Statement `locationName:"abortStatement" type:"structure"` + + // Checksum of the bot that you created. + Checksum *string `locationName:"checksum" type:"string"` + + // For each Amazon Lex bot created with the Amazon Lex Model Building Service, + // you must specify whether your use of Amazon Lex is related to a website, + // program, or other application that is directed or targeted, in whole or in + // part, to children under age 13 and subject to the Children's Online Privacy + // Protection Act (COPPA) by specifying true or false in the childDirected field. + // By specifying true in the childDirected field, you confirm that your use + // of Amazon Lex is related to a website, program, or other application that + // is directed or targeted, in whole or in part, to children under age 13 and + // subject to COPPA. By specifying false in the childDirected field, you confirm + // that your use of Amazon Lex is not related to a website, program, or other + // application that is directed or targeted, in whole or in part, to children + // under age 13 and subject to COPPA. You may not specify a default value for + // the childDirected field that does not accurately reflect whether your use + // of Amazon Lex is related to a website, program, or other application that + // is directed or targeted, in whole or in part, to children under age 13 and + // subject to COPPA. + // + // If your use of Amazon Lex relates to a website, program, or other application + // that is directed in whole or in part, to children under age 13, you must + // obtain any required verifiable parental consent under COPPA. For information + // regarding the use of Amazon Lex in connection with websites, programs, or + // other applications that are directed or targeted, in whole or in part, to + // children under age 13, see the Amazon Lex FAQ. (https://aws.amazon.com/lex/faqs#data-security) + ChildDirected *bool `locationName:"childDirected" type:"boolean"` + + // The prompts that Amazon Lex uses when it doesn't understand the user's intent. + // For more information, see PutBot. + ClarificationPrompt *Prompt `locationName:"clarificationPrompt" type:"structure"` + + CreateVersion *bool `locationName:"createVersion" type:"boolean"` + + // The date that the bot was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A description of the bot. + Description *string `locationName:"description" type:"string"` + + // If status is FAILED, Amazon Lex provides the reason that it failed to build + // the bot. + FailureReason *string `locationName:"failureReason" type:"string"` + + // The maximum length of time that Amazon Lex retains the data gathered in a + // conversation. For more information, see PutBot. + IdleSessionTTLInSeconds *int64 `locationName:"idleSessionTTLInSeconds" min:"60" type:"integer"` + + // An array of Intent objects. For more information, see PutBot. + Intents []*Intent `locationName:"intents" type:"list"` + + // The date that the bot was updated. When you create a resource, the creation + // date and last updated date are the same. + LastUpdatedDate *time.Time `locationName:"lastUpdatedDate" type:"timestamp" timestampFormat:"unix"` + + // The target locale for the bot. + Locale *string `locationName:"locale" type:"string" enum:"Locale"` + + // The name of the bot. + Name *string `locationName:"name" min:"2" type:"string"` + + // When you send a request to create a bot with processBehavior set to BUILD, + // Amazon Lex sets the status response element to BUILDING. After Amazon Lex + // builds the bot, it sets status to READY. If Amazon Lex can't build the bot, + // Amazon Lex sets status to FAILED. Amazon Lex returns the reason for the failure + // in the failureReason response element. + // + // When you set processBehaviorto SAVE, Amazon Lex sets the status code to NOT + // BUILT. + Status *string `locationName:"status" type:"string" enum:"Status"` + + // The version of the bot. For a new bot, the version is always $LATEST. + Version *string `locationName:"version" min:"1" type:"string"` + + // The Amazon Polly voice ID that Amazon Lex uses for voice interaction with + // the user. For more information, see PutBot. + VoiceId *string `locationName:"voiceId" type:"string"` +} + +// String returns the string representation +func (s PutBotOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PutBotOutput) GoString() string { + return s.String() +} + +// SetAbortStatement sets the AbortStatement field's value. +func (s *PutBotOutput) SetAbortStatement(v *Statement) *PutBotOutput { + s.AbortStatement = v + return s +} + +// SetChecksum sets the Checksum field's value. +func (s *PutBotOutput) SetChecksum(v string) *PutBotOutput { + s.Checksum = &v + return s +} + +// SetChildDirected sets the ChildDirected field's value. +func (s *PutBotOutput) SetChildDirected(v bool) *PutBotOutput { + s.ChildDirected = &v + return s +} + +// SetClarificationPrompt sets the ClarificationPrompt field's value. +func (s *PutBotOutput) SetClarificationPrompt(v *Prompt) *PutBotOutput { + s.ClarificationPrompt = v + return s +} + +// SetCreateVersion sets the CreateVersion field's value. +func (s *PutBotOutput) SetCreateVersion(v bool) *PutBotOutput { + s.CreateVersion = &v + return s +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *PutBotOutput) SetCreatedDate(v time.Time) *PutBotOutput { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *PutBotOutput) SetDescription(v string) *PutBotOutput { + s.Description = &v + return s +} + +// SetFailureReason sets the FailureReason field's value. +func (s *PutBotOutput) SetFailureReason(v string) *PutBotOutput { + s.FailureReason = &v + return s +} + +// SetIdleSessionTTLInSeconds sets the IdleSessionTTLInSeconds field's value. +func (s *PutBotOutput) SetIdleSessionTTLInSeconds(v int64) *PutBotOutput { + s.IdleSessionTTLInSeconds = &v + return s +} + +// SetIntents sets the Intents field's value. +func (s *PutBotOutput) SetIntents(v []*Intent) *PutBotOutput { + s.Intents = v + return s +} + +// SetLastUpdatedDate sets the LastUpdatedDate field's value. +func (s *PutBotOutput) SetLastUpdatedDate(v time.Time) *PutBotOutput { + s.LastUpdatedDate = &v + return s +} + +// SetLocale sets the Locale field's value. +func (s *PutBotOutput) SetLocale(v string) *PutBotOutput { + s.Locale = &v + return s +} + +// SetName sets the Name field's value. +func (s *PutBotOutput) SetName(v string) *PutBotOutput { + s.Name = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *PutBotOutput) SetStatus(v string) *PutBotOutput { + s.Status = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *PutBotOutput) SetVersion(v string) *PutBotOutput { + s.Version = &v + return s +} + +// SetVoiceId sets the VoiceId field's value. +func (s *PutBotOutput) SetVoiceId(v string) *PutBotOutput { + s.VoiceId = &v + return s +} + +type PutIntentInput struct { + _ struct{} `type:"structure"` + + // Identifies a specific revision of the $LATEST version. + // + // When you create a new intent, leave the checksum field blank. If you specify + // a checksum you get a BadRequestException exception. + // + // When you want to update a intent, set the checksum field to the checksum + // of the most recent revision of the $LATEST version. If you don't specify + // the checksum field, or if the checksum does not match the $LATEST version, + // you get a PreconditionFailedException exception. + Checksum *string `locationName:"checksum" type:"string"` + + // The statement that you want Amazon Lex to convey to the user after the intent + // is successfully fulfilled by the Lambda function. + // + // This element is relevant only if you provide a Lambda function in the fulfillmentActivity. + // If you return the intent to the client application, you can't specify this + // element. + // + // The followUpPrompt and conclusionStatement are mutually exclusive. You can + // specify only one. + ConclusionStatement *Statement `locationName:"conclusionStatement" type:"structure"` + + // Prompts the user to confirm the intent. This question should have a yes or + // no answer. + // + // Amazon Lex uses this prompt to ensure that the user acknowledges that the + // intent is ready for fulfillment. For example, with the OrderPizza intent, + // you might want to confirm that the order is correct before placing it. For + // other intents, such as intents that simply respond to user questions, you + // might not need to ask the user for confirmation before providing the information. + // + // You you must provide both the rejectionStatement and the confirmationPrompt, + // or neither. + ConfirmationPrompt *Prompt `locationName:"confirmationPrompt" type:"structure"` + + CreateVersion *bool `locationName:"createVersion" type:"boolean"` + + // A description of the intent. + Description *string `locationName:"description" type:"string"` + + // Specifies a Lambda function to invoke for each user input. You can invoke + // this Lambda function to personalize user interaction. + // + // For example, suppose your bot determines that the user is John. Your Lambda + // function might retrieve John's information from a backend database and prepopulate + // some of the values. For example, if you find that John is gluten intolerant, + // you might set the corresponding intent slot, GlutenIntolerant, to true. You + // might find John's phone number and set the corresponding session attribute. + DialogCodeHook *CodeHook `locationName:"dialogCodeHook" type:"structure"` + + // Amazon Lex uses this prompt to solicit additional activity after fulfilling + // an intent. For example, after the OrderPizza intent is fulfilled, you might + // prompt the user to order a drink. + // + // The action that Amazon Lex takes depends on the user's response, as follows: + // + // * If the user says "Yes" it responds with the clarification prompt that + // is configured for the bot. + // + // * if the user says "Yes" and continues with an utterance that triggers + // an intent it starts a conversation for the intent. + // + // * If the user says "No" it responds with the rejection statement configured + // for the the follow-up prompt. + // + // * If it doesn't recognize the utterance it repeats the follow-up prompt + // again. + // + // The followUpPrompt field and the conclusionStatement field are mutually exclusive. + // You can specify only one. + FollowUpPrompt *FollowUpPrompt `locationName:"followUpPrompt" type:"structure"` + + // Required. Describes how the intent is fulfilled. For example, after a user + // provides all of the information for a pizza order, fulfillmentActivity defines + // how the bot places an order with a local pizza store. + // + // You might configure Amazon Lex to return all of the intent information to + // the client application, or direct it to invoke a Lambda function that can + // process the intent (for example, place an order with a pizzeria). + FulfillmentActivity *FulfillmentActivity `locationName:"fulfillmentActivity" type:"structure"` + + // The name of the intent. The name is not case sensitive. + // + // The name can't match a built-in intent name, or a built-in intent name with + // "AMAZON." removed. For example, because there is a built-in intent called + // AMAZON.HelpIntent, you can't create a custom intent called HelpIntent. + // + // For a list of built-in intents, see Standard Built-in Intents (https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/docs/built-in-intent-ref/standard-intents) + // in the Alexa Skills Kit. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` + + // A unique identifier for the built-in intent to base this intent on. To find + // the signature for an intent, see Standard Built-in Intents (https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/docs/built-in-intent-ref/standard-intents) + // in the Alexa Skills Kit. + ParentIntentSignature *string `locationName:"parentIntentSignature" type:"string"` + + // When the user answers "no" to the question defined in confirmationPrompt, + // Amazon Lex responds with this statement to acknowledge that the intent was + // canceled. + // + // You must provide both the rejectionStatement and the confirmationPrompt, + // or neither. + RejectionStatement *Statement `locationName:"rejectionStatement" type:"structure"` + + // An array of utterances (strings) that a user might say to signal the intent. + // For example, "I want {PizzaSize} pizza", "Order {Quantity} {PizzaSize} pizzas". + // + // In each utterance, a slot name is enclosed in curly braces. + SampleUtterances []*string `locationName:"sampleUtterances" type:"list"` + + // An array of intent slots. At runtime, Amazon Lex elicits required slot values + // from the user using prompts defined in the slots. For more information, see + // how-it-works. + Slots []*Slot `locationName:"slots" type:"list"` +} + +// String returns the string representation +func (s PutIntentInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PutIntentInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *PutIntentInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PutIntentInput"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + if s.ConclusionStatement != nil { + if err := s.ConclusionStatement.Validate(); err != nil { + invalidParams.AddNested("ConclusionStatement", err.(request.ErrInvalidParams)) + } + } + if s.ConfirmationPrompt != nil { + if err := s.ConfirmationPrompt.Validate(); err != nil { + invalidParams.AddNested("ConfirmationPrompt", err.(request.ErrInvalidParams)) + } + } + if s.DialogCodeHook != nil { + if err := s.DialogCodeHook.Validate(); err != nil { + invalidParams.AddNested("DialogCodeHook", err.(request.ErrInvalidParams)) + } + } + if s.FollowUpPrompt != nil { + if err := s.FollowUpPrompt.Validate(); err != nil { + invalidParams.AddNested("FollowUpPrompt", err.(request.ErrInvalidParams)) + } + } + if s.FulfillmentActivity != nil { + if err := s.FulfillmentActivity.Validate(); err != nil { + invalidParams.AddNested("FulfillmentActivity", err.(request.ErrInvalidParams)) + } + } + if s.RejectionStatement != nil { + if err := s.RejectionStatement.Validate(); err != nil { + invalidParams.AddNested("RejectionStatement", err.(request.ErrInvalidParams)) + } + } + if s.Slots != nil { + for i, v := range s.Slots { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Slots", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetChecksum sets the Checksum field's value. +func (s *PutIntentInput) SetChecksum(v string) *PutIntentInput { + s.Checksum = &v + return s +} + +// SetConclusionStatement sets the ConclusionStatement field's value. +func (s *PutIntentInput) SetConclusionStatement(v *Statement) *PutIntentInput { + s.ConclusionStatement = v + return s +} + +// SetConfirmationPrompt sets the ConfirmationPrompt field's value. +func (s *PutIntentInput) SetConfirmationPrompt(v *Prompt) *PutIntentInput { + s.ConfirmationPrompt = v + return s +} + +// SetCreateVersion sets the CreateVersion field's value. +func (s *PutIntentInput) SetCreateVersion(v bool) *PutIntentInput { + s.CreateVersion = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *PutIntentInput) SetDescription(v string) *PutIntentInput { + s.Description = &v + return s +} + +// SetDialogCodeHook sets the DialogCodeHook field's value. +func (s *PutIntentInput) SetDialogCodeHook(v *CodeHook) *PutIntentInput { + s.DialogCodeHook = v + return s +} + +// SetFollowUpPrompt sets the FollowUpPrompt field's value. +func (s *PutIntentInput) SetFollowUpPrompt(v *FollowUpPrompt) *PutIntentInput { + s.FollowUpPrompt = v + return s +} + +// SetFulfillmentActivity sets the FulfillmentActivity field's value. +func (s *PutIntentInput) SetFulfillmentActivity(v *FulfillmentActivity) *PutIntentInput { + s.FulfillmentActivity = v + return s +} + +// SetName sets the Name field's value. +func (s *PutIntentInput) SetName(v string) *PutIntentInput { + s.Name = &v + return s +} + +// SetParentIntentSignature sets the ParentIntentSignature field's value. +func (s *PutIntentInput) SetParentIntentSignature(v string) *PutIntentInput { + s.ParentIntentSignature = &v + return s +} + +// SetRejectionStatement sets the RejectionStatement field's value. +func (s *PutIntentInput) SetRejectionStatement(v *Statement) *PutIntentInput { + s.RejectionStatement = v + return s +} + +// SetSampleUtterances sets the SampleUtterances field's value. +func (s *PutIntentInput) SetSampleUtterances(v []*string) *PutIntentInput { + s.SampleUtterances = v + return s +} + +// SetSlots sets the Slots field's value. +func (s *PutIntentInput) SetSlots(v []*Slot) *PutIntentInput { + s.Slots = v + return s +} + +type PutIntentOutput struct { + _ struct{} `type:"structure"` + + // Checksum of the $LATESTversion of the intent created or updated. + Checksum *string `locationName:"checksum" type:"string"` + + // After the Lambda function specified in thefulfillmentActivityintent fulfills + // the intent, Amazon Lex conveys this statement to the user. + ConclusionStatement *Statement `locationName:"conclusionStatement" type:"structure"` + + // If defined in the intent, Amazon Lex prompts the user to confirm the intent + // before fulfilling it. + ConfirmationPrompt *Prompt `locationName:"confirmationPrompt" type:"structure"` + + CreateVersion *bool `locationName:"createVersion" type:"boolean"` + + // The date that the intent was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A description of the intent. + Description *string `locationName:"description" type:"string"` + + // If defined in the intent, Amazon Lex invokes this Lambda function for each + // user input. + DialogCodeHook *CodeHook `locationName:"dialogCodeHook" type:"structure"` + + // If defined in the intent, Amazon Lex uses this prompt to solicit additional + // user activity after the intent is fulfilled. + FollowUpPrompt *FollowUpPrompt `locationName:"followUpPrompt" type:"structure"` + + // If defined in the intent, Amazon Lex invokes this Lambda function to fulfill + // the intent after the user provides all of the information required by the + // intent. + FulfillmentActivity *FulfillmentActivity `locationName:"fulfillmentActivity" type:"structure"` + + // The date that the intent was updated. When you create a resource, the creation + // date and last update dates are the same. + LastUpdatedDate *time.Time `locationName:"lastUpdatedDate" type:"timestamp" timestampFormat:"unix"` + + // The name of the intent. + Name *string `locationName:"name" min:"1" type:"string"` + + // A unique identifier for the built-in intent that this intent is based on. + ParentIntentSignature *string `locationName:"parentIntentSignature" type:"string"` + + // If the user answers "no" to the question defined in confirmationPrompt Amazon + // Lex responds with this statement to acknowledge that the intent was canceled. + RejectionStatement *Statement `locationName:"rejectionStatement" type:"structure"` + + // An array of sample utterances that are configured for the intent. + SampleUtterances []*string `locationName:"sampleUtterances" type:"list"` + + // An array of intent slots that are configured for the intent. + Slots []*Slot `locationName:"slots" type:"list"` + + // The version of the intent. For a new intent, the version is always $LATEST. + Version *string `locationName:"version" min:"1" type:"string"` +} + +// String returns the string representation +func (s PutIntentOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PutIntentOutput) GoString() string { + return s.String() +} + +// SetChecksum sets the Checksum field's value. +func (s *PutIntentOutput) SetChecksum(v string) *PutIntentOutput { + s.Checksum = &v + return s +} + +// SetConclusionStatement sets the ConclusionStatement field's value. +func (s *PutIntentOutput) SetConclusionStatement(v *Statement) *PutIntentOutput { + s.ConclusionStatement = v + return s +} + +// SetConfirmationPrompt sets the ConfirmationPrompt field's value. +func (s *PutIntentOutput) SetConfirmationPrompt(v *Prompt) *PutIntentOutput { + s.ConfirmationPrompt = v + return s +} + +// SetCreateVersion sets the CreateVersion field's value. +func (s *PutIntentOutput) SetCreateVersion(v bool) *PutIntentOutput { + s.CreateVersion = &v + return s +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *PutIntentOutput) SetCreatedDate(v time.Time) *PutIntentOutput { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *PutIntentOutput) SetDescription(v string) *PutIntentOutput { + s.Description = &v + return s +} + +// SetDialogCodeHook sets the DialogCodeHook field's value. +func (s *PutIntentOutput) SetDialogCodeHook(v *CodeHook) *PutIntentOutput { + s.DialogCodeHook = v + return s +} + +// SetFollowUpPrompt sets the FollowUpPrompt field's value. +func (s *PutIntentOutput) SetFollowUpPrompt(v *FollowUpPrompt) *PutIntentOutput { + s.FollowUpPrompt = v + return s +} + +// SetFulfillmentActivity sets the FulfillmentActivity field's value. +func (s *PutIntentOutput) SetFulfillmentActivity(v *FulfillmentActivity) *PutIntentOutput { + s.FulfillmentActivity = v + return s +} + +// SetLastUpdatedDate sets the LastUpdatedDate field's value. +func (s *PutIntentOutput) SetLastUpdatedDate(v time.Time) *PutIntentOutput { + s.LastUpdatedDate = &v + return s +} + +// SetName sets the Name field's value. +func (s *PutIntentOutput) SetName(v string) *PutIntentOutput { + s.Name = &v + return s +} + +// SetParentIntentSignature sets the ParentIntentSignature field's value. +func (s *PutIntentOutput) SetParentIntentSignature(v string) *PutIntentOutput { + s.ParentIntentSignature = &v + return s +} + +// SetRejectionStatement sets the RejectionStatement field's value. +func (s *PutIntentOutput) SetRejectionStatement(v *Statement) *PutIntentOutput { + s.RejectionStatement = v + return s +} + +// SetSampleUtterances sets the SampleUtterances field's value. +func (s *PutIntentOutput) SetSampleUtterances(v []*string) *PutIntentOutput { + s.SampleUtterances = v + return s +} + +// SetSlots sets the Slots field's value. +func (s *PutIntentOutput) SetSlots(v []*Slot) *PutIntentOutput { + s.Slots = v + return s +} + +// SetVersion sets the Version field's value. +func (s *PutIntentOutput) SetVersion(v string) *PutIntentOutput { + s.Version = &v + return s +} + +type PutSlotTypeInput struct { + _ struct{} `type:"structure"` + + // Identifies a specific revision of the $LATEST version. + // + // When you create a new slot type, leave the checksum field blank. If you specify + // a checksum you get a BadRequestException exception. + // + // When you want to update a slot type, set the checksum field to the checksum + // of the most recent revision of the $LATEST version. If you don't specify + // the checksum field, or if the checksum does not match the $LATEST version, + // you get a PreconditionFailedException exception. + Checksum *string `locationName:"checksum" type:"string"` + + CreateVersion *bool `locationName:"createVersion" type:"boolean"` + + // A description of the slot type. + Description *string `locationName:"description" type:"string"` + + // A list of EnumerationValue objects that defines the values that the slot + // type can take. Each value can have a list of synonyms, which are additional + // values that help train the machine learning model about the values that it + // resolves for a slot. + // + // When Amazon Lex resolves a slot value, it generates a resolution list that + // contains up to five possible values for the slot. If you are using a Lambda + // function, this resolution list is passed to the function. If you are not + // using a Lambda function you can choose to return the value that the user + // entered or the first value in the resolution list as the slot value. The + // valueSelectionStrategy field indicates the option to use. + EnumerationValues []*EnumerationValue `locationName:"enumerationValues" min:"1" type:"list"` + + // The name of the slot type. The name is not case sensitive. + // + // The name can't match a built-in slot type name, or a built-in slot type name + // with "AMAZON." removed. For example, because there is a built-in slot type + // called AMAZON.DATE, you can't create a custom slot type called DATE. + // + // For a list of built-in slot types, see Slot Type Reference (https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/docs/built-in-intent-ref/slot-type-reference) + // in the Alexa Skills Kit. + // + // Name is a required field + Name *string `location:"uri" locationName:"name" min:"1" type:"string" required:"true"` + + // Determines the slot resolution strategy that Amazon Lex uses to return slot + // type values. The field can be set to one of the following values: + // + // * ORIGINAL_VALUE - Returns the value entered by the user, if the user + // value is similar to the slot value. + // + // * TOP_RESOLUTION - If there is a resolution list for the slot, return + // the first value in the resolution list as the slot type value. If there + // is no resolution list, null is returned. + // + // If you don't specify the valueSelectionStrategy, the default is ORIGINAL_VALUE. + ValueSelectionStrategy *string `locationName:"valueSelectionStrategy" type:"string" enum:"SlotValueSelectionStrategy"` +} + +// String returns the string representation +func (s PutSlotTypeInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PutSlotTypeInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *PutSlotTypeInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PutSlotTypeInput"} + if s.EnumerationValues != nil && len(s.EnumerationValues) < 1 { + invalidParams.Add(request.NewErrParamMinLen("EnumerationValues", 1)) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + if s.EnumerationValues != nil { + for i, v := range s.EnumerationValues { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "EnumerationValues", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetChecksum sets the Checksum field's value. +func (s *PutSlotTypeInput) SetChecksum(v string) *PutSlotTypeInput { + s.Checksum = &v + return s +} + +// SetCreateVersion sets the CreateVersion field's value. +func (s *PutSlotTypeInput) SetCreateVersion(v bool) *PutSlotTypeInput { + s.CreateVersion = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *PutSlotTypeInput) SetDescription(v string) *PutSlotTypeInput { + s.Description = &v + return s +} + +// SetEnumerationValues sets the EnumerationValues field's value. +func (s *PutSlotTypeInput) SetEnumerationValues(v []*EnumerationValue) *PutSlotTypeInput { + s.EnumerationValues = v + return s +} + +// SetName sets the Name field's value. +func (s *PutSlotTypeInput) SetName(v string) *PutSlotTypeInput { + s.Name = &v + return s +} + +// SetValueSelectionStrategy sets the ValueSelectionStrategy field's value. +func (s *PutSlotTypeInput) SetValueSelectionStrategy(v string) *PutSlotTypeInput { + s.ValueSelectionStrategy = &v + return s +} + +type PutSlotTypeOutput struct { + _ struct{} `type:"structure"` + + // Checksum of the $LATEST version of the slot type. + Checksum *string `locationName:"checksum" type:"string"` + + CreateVersion *bool `locationName:"createVersion" type:"boolean"` + + // The date that the slot type was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A description of the slot type. + Description *string `locationName:"description" type:"string"` + + // A list of EnumerationValue objects that defines the values that the slot + // type can take. + EnumerationValues []*EnumerationValue `locationName:"enumerationValues" min:"1" type:"list"` + + // The date that the slot type was updated. When you create a slot type, the + // creation date and last update date are the same. + LastUpdatedDate *time.Time `locationName:"lastUpdatedDate" type:"timestamp" timestampFormat:"unix"` + + // The name of the slot type. + Name *string `locationName:"name" min:"1" type:"string"` + + // The slot resolution strategy that Amazon Lex uses to determine the value + // of the slot. For more information, see PutSlotType. + ValueSelectionStrategy *string `locationName:"valueSelectionStrategy" type:"string" enum:"SlotValueSelectionStrategy"` + + // The version of the slot type. For a new slot type, the version is always + // $LATEST. + Version *string `locationName:"version" min:"1" type:"string"` +} + +// String returns the string representation +func (s PutSlotTypeOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PutSlotTypeOutput) GoString() string { + return s.String() +} + +// SetChecksum sets the Checksum field's value. +func (s *PutSlotTypeOutput) SetChecksum(v string) *PutSlotTypeOutput { + s.Checksum = &v + return s +} + +// SetCreateVersion sets the CreateVersion field's value. +func (s *PutSlotTypeOutput) SetCreateVersion(v bool) *PutSlotTypeOutput { + s.CreateVersion = &v + return s +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *PutSlotTypeOutput) SetCreatedDate(v time.Time) *PutSlotTypeOutput { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *PutSlotTypeOutput) SetDescription(v string) *PutSlotTypeOutput { + s.Description = &v + return s +} + +// SetEnumerationValues sets the EnumerationValues field's value. +func (s *PutSlotTypeOutput) SetEnumerationValues(v []*EnumerationValue) *PutSlotTypeOutput { + s.EnumerationValues = v + return s +} + +// SetLastUpdatedDate sets the LastUpdatedDate field's value. +func (s *PutSlotTypeOutput) SetLastUpdatedDate(v time.Time) *PutSlotTypeOutput { + s.LastUpdatedDate = &v + return s +} + +// SetName sets the Name field's value. +func (s *PutSlotTypeOutput) SetName(v string) *PutSlotTypeOutput { + s.Name = &v + return s +} + +// SetValueSelectionStrategy sets the ValueSelectionStrategy field's value. +func (s *PutSlotTypeOutput) SetValueSelectionStrategy(v string) *PutSlotTypeOutput { + s.ValueSelectionStrategy = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *PutSlotTypeOutput) SetVersion(v string) *PutSlotTypeOutput { + s.Version = &v + return s +} + +// Describes the resource that refers to the resource that you are attempting +// to delete. This object is returned as part of the ResourceInUseException +// exception. +type ResourceReference struct { + _ struct{} `type:"structure"` + + // The name of the resource that is using the resource that you are trying to + // delete. + Name *string `locationName:"name" min:"1" type:"string"` + + // The version of the resource that is using the resource that you are trying + // to delete. + Version *string `locationName:"version" min:"1" type:"string"` +} + +// String returns the string representation +func (s ResourceReference) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ResourceReference) GoString() string { + return s.String() +} + +// SetName sets the Name field's value. +func (s *ResourceReference) SetName(v string) *ResourceReference { + s.Name = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *ResourceReference) SetVersion(v string) *ResourceReference { + s.Version = &v + return s +} + +// Identifies the version of a specific slot. +type Slot struct { + _ struct{} `type:"structure"` + + // A description of the slot. + Description *string `locationName:"description" type:"string"` + + // The name of the slot. + // + // Name is a required field + Name *string `locationName:"name" min:"1" type:"string" required:"true"` + + // Directs Lex the order in which to elicit this slot value from the user. For + // example, if the intent has two slots with priorities 1 and 2, AWS Lex first + // elicits a value for the slot with priority 1. + // + // If multiple slots share the same priority, the order in which Lex elicits + // values is arbitrary. + Priority *int64 `locationName:"priority" type:"integer"` + + // A set of possible responses for the slot type used by text-based clients. + // A user chooses an option from the response card, instead of using text to + // reply. + ResponseCard *string `locationName:"responseCard" min:"1" type:"string"` + + // If you know a specific pattern with which users might respond to an Amazon + // Lex request for a slot value, you can provide those utterances to improve + // accuracy. This is optional. In most cases, Amazon Lex is capable of understanding + // user utterances. + SampleUtterances []*string `locationName:"sampleUtterances" type:"list"` + + // Specifies whether the slot is required or optional. + // + // SlotConstraint is a required field + SlotConstraint *string `locationName:"slotConstraint" type:"string" required:"true" enum:"SlotConstraint"` + + // The type of the slot, either a custom slot type that you defined or one of + // the built-in slot types. + SlotType *string `locationName:"slotType" min:"1" type:"string"` + + // The version of the slot type. + SlotTypeVersion *string `locationName:"slotTypeVersion" min:"1" type:"string"` + + // The prompt that Amazon Lex uses to elicit the slot value from the user. + ValueElicitationPrompt *Prompt `locationName:"valueElicitationPrompt" type:"structure"` +} + +// String returns the string representation +func (s Slot) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s Slot) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *Slot) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "Slot"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + if s.ResponseCard != nil && len(*s.ResponseCard) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ResponseCard", 1)) + } + if s.SlotConstraint == nil { + invalidParams.Add(request.NewErrParamRequired("SlotConstraint")) + } + if s.SlotType != nil && len(*s.SlotType) < 1 { + invalidParams.Add(request.NewErrParamMinLen("SlotType", 1)) + } + if s.SlotTypeVersion != nil && len(*s.SlotTypeVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("SlotTypeVersion", 1)) + } + if s.ValueElicitationPrompt != nil { + if err := s.ValueElicitationPrompt.Validate(); err != nil { + invalidParams.AddNested("ValueElicitationPrompt", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDescription sets the Description field's value. +func (s *Slot) SetDescription(v string) *Slot { + s.Description = &v + return s +} + +// SetName sets the Name field's value. +func (s *Slot) SetName(v string) *Slot { + s.Name = &v + return s +} + +// SetPriority sets the Priority field's value. +func (s *Slot) SetPriority(v int64) *Slot { + s.Priority = &v + return s +} + +// SetResponseCard sets the ResponseCard field's value. +func (s *Slot) SetResponseCard(v string) *Slot { + s.ResponseCard = &v + return s +} + +// SetSampleUtterances sets the SampleUtterances field's value. +func (s *Slot) SetSampleUtterances(v []*string) *Slot { + s.SampleUtterances = v + return s +} + +// SetSlotConstraint sets the SlotConstraint field's value. +func (s *Slot) SetSlotConstraint(v string) *Slot { + s.SlotConstraint = &v + return s +} + +// SetSlotType sets the SlotType field's value. +func (s *Slot) SetSlotType(v string) *Slot { + s.SlotType = &v + return s +} + +// SetSlotTypeVersion sets the SlotTypeVersion field's value. +func (s *Slot) SetSlotTypeVersion(v string) *Slot { + s.SlotTypeVersion = &v + return s +} + +// SetValueElicitationPrompt sets the ValueElicitationPrompt field's value. +func (s *Slot) SetValueElicitationPrompt(v *Prompt) *Slot { + s.ValueElicitationPrompt = v + return s +} + +// Provides information about a slot type.. +type SlotTypeMetadata struct { + _ struct{} `type:"structure"` + + // The date that the slot type was created. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // A description of the slot type. + Description *string `locationName:"description" type:"string"` + + // The date that the slot type was updated. When you create a resource, the + // creation date and last updated date are the same. + LastUpdatedDate *time.Time `locationName:"lastUpdatedDate" type:"timestamp" timestampFormat:"unix"` + + // The name of the slot type. + Name *string `locationName:"name" min:"1" type:"string"` + + // The version of the slot type. + Version *string `locationName:"version" min:"1" type:"string"` +} + +// String returns the string representation +func (s SlotTypeMetadata) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s SlotTypeMetadata) GoString() string { + return s.String() +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *SlotTypeMetadata) SetCreatedDate(v time.Time) *SlotTypeMetadata { + s.CreatedDate = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *SlotTypeMetadata) SetDescription(v string) *SlotTypeMetadata { + s.Description = &v + return s +} + +// SetLastUpdatedDate sets the LastUpdatedDate field's value. +func (s *SlotTypeMetadata) SetLastUpdatedDate(v time.Time) *SlotTypeMetadata { + s.LastUpdatedDate = &v + return s +} + +// SetName sets the Name field's value. +func (s *SlotTypeMetadata) SetName(v string) *SlotTypeMetadata { + s.Name = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *SlotTypeMetadata) SetVersion(v string) *SlotTypeMetadata { + s.Version = &v + return s +} + +type StartImportInput struct { + _ struct{} `type:"structure"` + + // Specifies the action that the StartImport operation should take when there + // is an existing resource with the same name. + // + // * FAIL_ON_CONFLICT - The import operation is stopped on the first conflict + // between a resource in the import file and an existing resource. The name + // of the resource causing the conflict is in the failureReason field of + // the response to the GetImport operation. + // + // OVERWRITE_LATEST - The import operation proceeds even if there is a conflict + // with an existing resource. The $LASTEST version of the existing resource + // is overwritten with the data from the import file. + // + // MergeStrategy is a required field + MergeStrategy *string `locationName:"mergeStrategy" type:"string" required:"true" enum:"MergeStrategy"` + + // A zip archive in binary format. The archive should contain one file, a JSON + // file containing the resource to import. The resource should match the type + // specified in the resourceType field. + // + // Payload is automatically base64 encoded/decoded by the SDK. + // + // Payload is a required field + Payload []byte `locationName:"payload" type:"blob" required:"true"` + + // Specifies the type of resource to export. Each resource also exports any + // resources that it depends on. + // + // * A bot exports dependent intents. + // + // * An intent exports dependent slot types. + // + // ResourceType is a required field + ResourceType *string `locationName:"resourceType" type:"string" required:"true" enum:"ResourceType"` +} + +// String returns the string representation +func (s StartImportInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s StartImportInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *StartImportInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "StartImportInput"} + if s.MergeStrategy == nil { + invalidParams.Add(request.NewErrParamRequired("MergeStrategy")) + } + if s.Payload == nil { + invalidParams.Add(request.NewErrParamRequired("Payload")) + } + if s.ResourceType == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceType")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMergeStrategy sets the MergeStrategy field's value. +func (s *StartImportInput) SetMergeStrategy(v string) *StartImportInput { + s.MergeStrategy = &v + return s +} + +// SetPayload sets the Payload field's value. +func (s *StartImportInput) SetPayload(v []byte) *StartImportInput { + s.Payload = v + return s +} + +// SetResourceType sets the ResourceType field's value. +func (s *StartImportInput) SetResourceType(v string) *StartImportInput { + s.ResourceType = &v + return s +} + +type StartImportOutput struct { + _ struct{} `type:"structure"` + + // A timestamp for the date and time that the import job was requested. + CreatedDate *time.Time `locationName:"createdDate" type:"timestamp" timestampFormat:"unix"` + + // The identifier for the specific import job. + ImportId *string `locationName:"importId" type:"string"` + + // The status of the import job. If the status is FAILED, you can get the reason + // for the failure using the GetImport operation. + ImportStatus *string `locationName:"importStatus" type:"string" enum:"ImportStatus"` + + // The action to take when there is a merge conflict. + MergeStrategy *string `locationName:"mergeStrategy" type:"string" enum:"MergeStrategy"` + + // The name given to the import job. + Name *string `locationName:"name" min:"1" type:"string"` + + // The type of resource to import. + ResourceType *string `locationName:"resourceType" type:"string" enum:"ResourceType"` +} + +// String returns the string representation +func (s StartImportOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s StartImportOutput) GoString() string { + return s.String() +} + +// SetCreatedDate sets the CreatedDate field's value. +func (s *StartImportOutput) SetCreatedDate(v time.Time) *StartImportOutput { + s.CreatedDate = &v + return s +} + +// SetImportId sets the ImportId field's value. +func (s *StartImportOutput) SetImportId(v string) *StartImportOutput { + s.ImportId = &v + return s +} + +// SetImportStatus sets the ImportStatus field's value. +func (s *StartImportOutput) SetImportStatus(v string) *StartImportOutput { + s.ImportStatus = &v + return s +} + +// SetMergeStrategy sets the MergeStrategy field's value. +func (s *StartImportOutput) SetMergeStrategy(v string) *StartImportOutput { + s.MergeStrategy = &v + return s +} + +// SetName sets the Name field's value. +func (s *StartImportOutput) SetName(v string) *StartImportOutput { + s.Name = &v + return s +} + +// SetResourceType sets the ResourceType field's value. +func (s *StartImportOutput) SetResourceType(v string) *StartImportOutput { + s.ResourceType = &v + return s +} + +// A collection of messages that convey information to the user. At runtime, +// Amazon Lex selects the message to convey. +type Statement struct { + _ struct{} `type:"structure"` + + // A collection of message objects. + // + // Messages is a required field + Messages []*Message `locationName:"messages" min:"1" type:"list" required:"true"` + + // At runtime, if the client is using the PostText (http://docs.aws.amazon.com/lex/latest/dg/API_runtime_PostText.html) + // API, Amazon Lex includes the response card in the response. It substitutes + // all of the session attributes and slot values for placeholders in the response + // card. + ResponseCard *string `locationName:"responseCard" min:"1" type:"string"` +} + +// String returns the string representation +func (s Statement) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s Statement) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *Statement) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "Statement"} + if s.Messages == nil { + invalidParams.Add(request.NewErrParamRequired("Messages")) + } + if s.Messages != nil && len(s.Messages) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Messages", 1)) + } + if s.ResponseCard != nil && len(*s.ResponseCard) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ResponseCard", 1)) + } + if s.Messages != nil { + for i, v := range s.Messages { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Messages", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMessages sets the Messages field's value. +func (s *Statement) SetMessages(v []*Message) *Statement { + s.Messages = v + return s +} + +// SetResponseCard sets the ResponseCard field's value. +func (s *Statement) SetResponseCard(v string) *Statement { + s.ResponseCard = &v + return s +} + +// Provides information about a single utterance that was made to your bot. +type UtteranceData struct { + _ struct{} `type:"structure"` + + // The number of times that the utterance was processed. + Count *int64 `locationName:"count" type:"integer"` + + // The total number of individuals that used the utterance. + DistinctUsers *int64 `locationName:"distinctUsers" type:"integer"` + + // The date that the utterance was first recorded. + FirstUtteredDate *time.Time `locationName:"firstUtteredDate" type:"timestamp" timestampFormat:"unix"` + + // The date that the utterance was last recorded. + LastUtteredDate *time.Time `locationName:"lastUtteredDate" type:"timestamp" timestampFormat:"unix"` + + // The text that was entered by the user or the text representation of an audio + // clip. + UtteranceString *string `locationName:"utteranceString" min:"1" type:"string"` +} + +// String returns the string representation +func (s UtteranceData) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UtteranceData) GoString() string { + return s.String() +} + +// SetCount sets the Count field's value. +func (s *UtteranceData) SetCount(v int64) *UtteranceData { + s.Count = &v + return s +} + +// SetDistinctUsers sets the DistinctUsers field's value. +func (s *UtteranceData) SetDistinctUsers(v int64) *UtteranceData { + s.DistinctUsers = &v + return s +} + +// SetFirstUtteredDate sets the FirstUtteredDate field's value. +func (s *UtteranceData) SetFirstUtteredDate(v time.Time) *UtteranceData { + s.FirstUtteredDate = &v + return s +} + +// SetLastUtteredDate sets the LastUtteredDate field's value. +func (s *UtteranceData) SetLastUtteredDate(v time.Time) *UtteranceData { + s.LastUtteredDate = &v + return s +} + +// SetUtteranceString sets the UtteranceString field's value. +func (s *UtteranceData) SetUtteranceString(v string) *UtteranceData { + s.UtteranceString = &v + return s +} + +// Provides a list of utterances that have been made to a specific version of +// your bot. The list contains a maximum of 100 utterances. +type UtteranceList struct { + _ struct{} `type:"structure"` + + // The version of the bot that processed the list. + BotVersion *string `locationName:"botVersion" min:"1" type:"string"` + + // One or more UtteranceData objects that contain information about the utterances + // that have been made to a bot. The maximum number of object is 100. + Utterances []*UtteranceData `locationName:"utterances" type:"list"` +} + +// String returns the string representation +func (s UtteranceList) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UtteranceList) GoString() string { + return s.String() +} + +// SetBotVersion sets the BotVersion field's value. +func (s *UtteranceList) SetBotVersion(v string) *UtteranceList { + s.BotVersion = &v + return s +} + +// SetUtterances sets the Utterances field's value. +func (s *UtteranceList) SetUtterances(v []*UtteranceData) *UtteranceList { + s.Utterances = v + return s +} + +const ( + // ChannelStatusInProgress is a ChannelStatus enum value + ChannelStatusInProgress = "IN_PROGRESS" + + // ChannelStatusCreated is a ChannelStatus enum value + ChannelStatusCreated = "CREATED" + + // ChannelStatusFailed is a ChannelStatus enum value + ChannelStatusFailed = "FAILED" +) + +const ( + // ChannelTypeFacebook is a ChannelType enum value + ChannelTypeFacebook = "Facebook" + + // ChannelTypeSlack is a ChannelType enum value + ChannelTypeSlack = "Slack" + + // ChannelTypeTwilioSms is a ChannelType enum value + ChannelTypeTwilioSms = "Twilio-Sms" + + // ChannelTypeKik is a ChannelType enum value + ChannelTypeKik = "Kik" +) + +const ( + // ContentTypePlainText is a ContentType enum value + ContentTypePlainText = "PlainText" + + // ContentTypeSsml is a ContentType enum value + ContentTypeSsml = "SSML" + + // ContentTypeCustomPayload is a ContentType enum value + ContentTypeCustomPayload = "CustomPayload" +) + +const ( + // ExportStatusInProgress is a ExportStatus enum value + ExportStatusInProgress = "IN_PROGRESS" + + // ExportStatusReady is a ExportStatus enum value + ExportStatusReady = "READY" + + // ExportStatusFailed is a ExportStatus enum value + ExportStatusFailed = "FAILED" +) + +const ( + // ExportTypeAlexaSkillsKit is a ExportType enum value + ExportTypeAlexaSkillsKit = "ALEXA_SKILLS_KIT" + + // ExportTypeLex is a ExportType enum value + ExportTypeLex = "LEX" +) + +const ( + // FulfillmentActivityTypeReturnIntent is a FulfillmentActivityType enum value + FulfillmentActivityTypeReturnIntent = "ReturnIntent" + + // FulfillmentActivityTypeCodeHook is a FulfillmentActivityType enum value + FulfillmentActivityTypeCodeHook = "CodeHook" +) + +const ( + // ImportStatusInProgress is a ImportStatus enum value + ImportStatusInProgress = "IN_PROGRESS" + + // ImportStatusComplete is a ImportStatus enum value + ImportStatusComplete = "COMPLETE" + + // ImportStatusFailed is a ImportStatus enum value + ImportStatusFailed = "FAILED" +) + +const ( + // LocaleEnUs is a Locale enum value + LocaleEnUs = "en-US" + + // LocaleEnGb is a Locale enum value + LocaleEnGb = "en-GB" + + // LocaleDeDe is a Locale enum value + LocaleDeDe = "de-DE" +) + +const ( + // MergeStrategyOverwriteLatest is a MergeStrategy enum value + MergeStrategyOverwriteLatest = "OVERWRITE_LATEST" + + // MergeStrategyFailOnConflict is a MergeStrategy enum value + MergeStrategyFailOnConflict = "FAIL_ON_CONFLICT" +) + +const ( + // ProcessBehaviorSave is a ProcessBehavior enum value + ProcessBehaviorSave = "SAVE" + + // ProcessBehaviorBuild is a ProcessBehavior enum value + ProcessBehaviorBuild = "BUILD" +) + +const ( + // ReferenceTypeIntent is a ReferenceType enum value + ReferenceTypeIntent = "Intent" + + // ReferenceTypeBot is a ReferenceType enum value + ReferenceTypeBot = "Bot" + + // ReferenceTypeBotAlias is a ReferenceType enum value + ReferenceTypeBotAlias = "BotAlias" + + // ReferenceTypeBotChannel is a ReferenceType enum value + ReferenceTypeBotChannel = "BotChannel" +) + +const ( + // ResourceTypeBot is a ResourceType enum value + ResourceTypeBot = "BOT" + + // ResourceTypeIntent is a ResourceType enum value + ResourceTypeIntent = "INTENT" + + // ResourceTypeSlotType is a ResourceType enum value + ResourceTypeSlotType = "SLOT_TYPE" +) + +const ( + // SlotConstraintRequired is a SlotConstraint enum value + SlotConstraintRequired = "Required" + + // SlotConstraintOptional is a SlotConstraint enum value + SlotConstraintOptional = "Optional" +) + +const ( + // SlotValueSelectionStrategyOriginalValue is a SlotValueSelectionStrategy enum value + SlotValueSelectionStrategyOriginalValue = "ORIGINAL_VALUE" + + // SlotValueSelectionStrategyTopResolution is a SlotValueSelectionStrategy enum value + SlotValueSelectionStrategyTopResolution = "TOP_RESOLUTION" +) + +const ( + // StatusBuilding is a Status enum value + StatusBuilding = "BUILDING" + + // StatusReady is a Status enum value + StatusReady = "READY" + + // StatusFailed is a Status enum value + StatusFailed = "FAILED" + + // StatusNotBuilt is a Status enum value + StatusNotBuilt = "NOT_BUILT" +) + +const ( + // StatusTypeDetected is a StatusType enum value + StatusTypeDetected = "Detected" + + // StatusTypeMissed is a StatusType enum value + StatusTypeMissed = "Missed" +) diff --git a/vendor/github.com/aws/aws-sdk-go/service/lexmodelbuildingservice/doc.go b/vendor/github.com/aws/aws-sdk-go/service/lexmodelbuildingservice/doc.go new file mode 100644 index 000000000000..3e4aae2ee0b7 --- /dev/null +++ b/vendor/github.com/aws/aws-sdk-go/service/lexmodelbuildingservice/doc.go @@ -0,0 +1,30 @@ +// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. + +// Package lexmodelbuildingservice provides the client and types for making API +// requests to Amazon Lex Model Building Service. +// +// Amazon Lex is an AWS service for building conversational voice and text interfaces. +// Use these actions to create, update, and delete conversational bots for new +// and existing client applications. +// +// See https://docs.aws.amazon.com/goto/WebAPI/lex-models-2017-04-19 for more information on this service. +// +// See lexmodelbuildingservice package documentation for more information. +// https://docs.aws.amazon.com/sdk-for-go/api/service/lexmodelbuildingservice/ +// +// Using the Client +// +// To contact Amazon Lex Model Building Service with the SDK use the New function to create +// a new service client. With that client you can make API requests to the service. +// These clients are safe to use concurrently. +// +// See the SDK's documentation for more information on how to use the SDK. +// https://docs.aws.amazon.com/sdk-for-go/api/ +// +// See aws.Config documentation for more information on configuring SDK clients. +// https://docs.aws.amazon.com/sdk-for-go/api/aws/#Config +// +// See the Amazon Lex Model Building Service client LexModelBuildingService for more +// information on creating client for this service. +// https://docs.aws.amazon.com/sdk-for-go/api/service/lexmodelbuildingservice/#New +package lexmodelbuildingservice diff --git a/vendor/github.com/aws/aws-sdk-go/service/lexmodelbuildingservice/errors.go b/vendor/github.com/aws/aws-sdk-go/service/lexmodelbuildingservice/errors.go new file mode 100644 index 000000000000..da3b08cb8d6e --- /dev/null +++ b/vendor/github.com/aws/aws-sdk-go/service/lexmodelbuildingservice/errors.go @@ -0,0 +1,61 @@ +// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. + +package lexmodelbuildingservice + +const ( + + // ErrCodeBadRequestException for service response error code + // "BadRequestException". + // + // The request is not well formed. For example, a value is invalid or a required + // field is missing. Check the field values, and try again. + ErrCodeBadRequestException = "BadRequestException" + + // ErrCodeConflictException for service response error code + // "ConflictException". + // + // There was a conflict processing the request. Try your request again. + ErrCodeConflictException = "ConflictException" + + // ErrCodeInternalFailureException for service response error code + // "InternalFailureException". + // + // An internal Amazon Lex error occurred. Try your request again. + ErrCodeInternalFailureException = "InternalFailureException" + + // ErrCodeLimitExceededException for service response error code + // "LimitExceededException". + // + // The request exceeded a limit. Try your request again. + ErrCodeLimitExceededException = "LimitExceededException" + + // ErrCodeNotFoundException for service response error code + // "NotFoundException". + // + // The resource specified in the request was not found. Check the resource and + // try again. + ErrCodeNotFoundException = "NotFoundException" + + // ErrCodePreconditionFailedException for service response error code + // "PreconditionFailedException". + // + // The checksum of the resource that you are trying to change does not match + // the checksum in the request. Check the resource's checksum and try again. + ErrCodePreconditionFailedException = "PreconditionFailedException" + + // ErrCodeResourceInUseException for service response error code + // "ResourceInUseException". + // + // The resource that you are attempting to delete is referred to by another + // resource. Use this information to remove references to the resource that + // you are trying to delete. + // + // The body of the exception contains a JSON object that describes the resource. + // + // { "resourceType": BOT | BOTALIAS | BOTCHANNEL | INTENT, + // + // "resourceReference": { + // + // "name": string, "version": string } } + ErrCodeResourceInUseException = "ResourceInUseException" +) diff --git a/vendor/github.com/aws/aws-sdk-go/service/lexmodelbuildingservice/service.go b/vendor/github.com/aws/aws-sdk-go/service/lexmodelbuildingservice/service.go new file mode 100644 index 000000000000..cc122d1a2a33 --- /dev/null +++ b/vendor/github.com/aws/aws-sdk-go/service/lexmodelbuildingservice/service.go @@ -0,0 +1,97 @@ +// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. + +package lexmodelbuildingservice + +import ( + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/client" + "github.com/aws/aws-sdk-go/aws/client/metadata" + "github.com/aws/aws-sdk-go/aws/request" + "github.com/aws/aws-sdk-go/aws/signer/v4" + "github.com/aws/aws-sdk-go/private/protocol/restjson" +) + +// LexModelBuildingService provides the API operation methods for making requests to +// Amazon Lex Model Building Service. See this package's package overview docs +// for details on the service. +// +// LexModelBuildingService methods are safe to use concurrently. It is not safe to +// modify mutate any of the struct's properties though. +type LexModelBuildingService struct { + *client.Client +} + +// Used for custom client initialization logic +var initClient func(*client.Client) + +// Used for custom request initialization logic +var initRequest func(*request.Request) + +// Service information constants +const ( + ServiceName = "models.lex" // Service endpoint prefix API calls made to. + EndpointsID = ServiceName // Service ID for Regions and Endpoints metadata. +) + +// New creates a new instance of the LexModelBuildingService client with a session. +// If additional configuration is needed for the client instance use the optional +// aws.Config parameter to add your extra config. +// +// Example: +// // Create a LexModelBuildingService client from just a session. +// svc := lexmodelbuildingservice.New(mySession) +// +// // Create a LexModelBuildingService client with additional configuration +// svc := lexmodelbuildingservice.New(mySession, aws.NewConfig().WithRegion("us-west-2")) +func New(p client.ConfigProvider, cfgs ...*aws.Config) *LexModelBuildingService { + c := p.ClientConfig(EndpointsID, cfgs...) + if c.SigningNameDerived || len(c.SigningName) == 0 { + c.SigningName = "lex" + } + return newClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion, c.SigningName) +} + +// newClient creates, initializes and returns a new service client instance. +func newClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion, signingName string) *LexModelBuildingService { + svc := &LexModelBuildingService{ + Client: client.New( + cfg, + metadata.ClientInfo{ + ServiceName: ServiceName, + SigningName: signingName, + SigningRegion: signingRegion, + Endpoint: endpoint, + APIVersion: "2017-04-19", + JSONVersion: "1.1", + }, + handlers, + ), + } + + // Handlers + svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler) + svc.Handlers.Build.PushBackNamed(restjson.BuildHandler) + svc.Handlers.Unmarshal.PushBackNamed(restjson.UnmarshalHandler) + svc.Handlers.UnmarshalMeta.PushBackNamed(restjson.UnmarshalMetaHandler) + svc.Handlers.UnmarshalError.PushBackNamed(restjson.UnmarshalErrorHandler) + + // Run custom client initialization if present + if initClient != nil { + initClient(svc.Client) + } + + return svc +} + +// newRequest creates a new request for a LexModelBuildingService operation and runs any +// custom request initialization. +func (c *LexModelBuildingService) newRequest(op *request.Operation, params, data interface{}) *request.Request { + req := c.NewRequest(op, params, data) + + // Run custom request initialization if present + if initRequest != nil { + initRequest(req) + } + + return req +} diff --git a/vendor/github.com/aws/aws-sdk-go/service/lightsail/api.go b/vendor/github.com/aws/aws-sdk-go/service/lightsail/api.go index 9d3eb928d068..0feedda0afc0 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/lightsail/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/lightsail/api.go @@ -14,7 +14,7 @@ const opAllocateStaticIp = "AllocateStaticIp" // AllocateStaticIpRequest generates a "aws/request.Request" representing the // client's request for the AllocateStaticIp operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -72,8 +72,8 @@ func (c *Lightsail) AllocateStaticIpRequest(input *AllocateStaticIpInput) (req * // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -118,7 +118,7 @@ const opAttachDisk = "AttachDisk" // AttachDiskRequest generates a "aws/request.Request" representing the // client's request for the AttachDisk operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -177,8 +177,8 @@ func (c *Lightsail) AttachDiskRequest(input *AttachDiskInput) (req *request.Requ // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -223,7 +223,7 @@ const opAttachInstancesToLoadBalancer = "AttachInstancesToLoadBalancer" // AttachInstancesToLoadBalancerRequest generates a "aws/request.Request" representing the // client's request for the AttachInstancesToLoadBalancer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -265,6 +265,9 @@ func (c *Lightsail) AttachInstancesToLoadBalancerRequest(input *AttachInstancesT // // Attaches one or more Lightsail instances to a load balancer. // +// After some time, the instances are attached to the load balancer and the +// health check status is available. +// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -281,8 +284,8 @@ func (c *Lightsail) AttachInstancesToLoadBalancerRequest(input *AttachInstancesT // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -327,7 +330,7 @@ const opAttachLoadBalancerTlsCertificate = "AttachLoadBalancerTlsCertificate" // AttachLoadBalancerTlsCertificateRequest generates a "aws/request.Request" representing the // client's request for the AttachLoadBalancerTlsCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -368,9 +371,14 @@ func (c *Lightsail) AttachLoadBalancerTlsCertificateRequest(input *AttachLoadBal // AttachLoadBalancerTlsCertificate API operation for Amazon Lightsail. // // Attaches a Transport Layer Security (TLS) certificate to your load balancer. -// // TLS is just an updated, more secure version of Secure Socket Layer (SSL). // +// Once you create and validate your certificate, you can attach it to your +// load balancer. You can also use this API to rotate the certificates on your +// account. Use the AttachLoadBalancerTlsCertificate operation with the non-attached +// certificate, and it will replace the existing one and become the attached +// certificate. +// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -387,8 +395,8 @@ func (c *Lightsail) AttachLoadBalancerTlsCertificateRequest(input *AttachLoadBal // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -433,7 +441,7 @@ const opAttachStaticIp = "AttachStaticIp" // AttachStaticIpRequest generates a "aws/request.Request" representing the // client's request for the AttachStaticIp operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -491,8 +499,8 @@ func (c *Lightsail) AttachStaticIpRequest(input *AttachStaticIpInput) (req *requ // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -537,7 +545,7 @@ const opCloseInstancePublicPorts = "CloseInstancePublicPorts" // CloseInstancePublicPortsRequest generates a "aws/request.Request" representing the // client's request for the CloseInstancePublicPorts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -595,8 +603,8 @@ func (c *Lightsail) CloseInstancePublicPortsRequest(input *CloseInstancePublicPo // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -641,7 +649,7 @@ const opCreateDisk = "CreateDisk" // CreateDiskRequest generates a "aws/request.Request" representing the // client's request for the CreateDisk operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -702,8 +710,8 @@ func (c *Lightsail) CreateDiskRequest(input *CreateDiskInput) (req *request.Requ // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -748,7 +756,7 @@ const opCreateDiskFromSnapshot = "CreateDiskFromSnapshot" // CreateDiskFromSnapshotRequest generates a "aws/request.Request" representing the // client's request for the CreateDiskFromSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -809,8 +817,8 @@ func (c *Lightsail) CreateDiskFromSnapshotRequest(input *CreateDiskFromSnapshotI // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -855,7 +863,7 @@ const opCreateDiskSnapshot = "CreateDiskSnapshot" // CreateDiskSnapshotRequest generates a "aws/request.Request" representing the // client's request for the CreateDiskSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -926,8 +934,8 @@ func (c *Lightsail) CreateDiskSnapshotRequest(input *CreateDiskSnapshotInput) (r // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -972,7 +980,7 @@ const opCreateDomain = "CreateDomain" // CreateDomainRequest generates a "aws/request.Request" representing the // client's request for the CreateDomain operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1030,8 +1038,8 @@ func (c *Lightsail) CreateDomainRequest(input *CreateDomainInput) (req *request. // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -1076,7 +1084,7 @@ const opCreateDomainEntry = "CreateDomainEntry" // CreateDomainEntryRequest generates a "aws/request.Request" representing the // client's request for the CreateDomainEntry operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1135,8 +1143,8 @@ func (c *Lightsail) CreateDomainEntryRequest(input *CreateDomainEntryInput) (req // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -1181,7 +1189,7 @@ const opCreateInstanceSnapshot = "CreateInstanceSnapshot" // CreateInstanceSnapshotRequest generates a "aws/request.Request" representing the // client's request for the CreateInstanceSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1240,8 +1248,8 @@ func (c *Lightsail) CreateInstanceSnapshotRequest(input *CreateInstanceSnapshotI // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -1286,7 +1294,7 @@ const opCreateInstances = "CreateInstances" // CreateInstancesRequest generates a "aws/request.Request" representing the // client's request for the CreateInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1344,8 +1352,8 @@ func (c *Lightsail) CreateInstancesRequest(input *CreateInstancesInput) (req *re // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -1390,7 +1398,7 @@ const opCreateInstancesFromSnapshot = "CreateInstancesFromSnapshot" // CreateInstancesFromSnapshotRequest generates a "aws/request.Request" representing the // client's request for the CreateInstancesFromSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1449,8 +1457,8 @@ func (c *Lightsail) CreateInstancesFromSnapshotRequest(input *CreateInstancesFro // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -1495,7 +1503,7 @@ const opCreateKeyPair = "CreateKeyPair" // CreateKeyPairRequest generates a "aws/request.Request" representing the // client's request for the CreateKeyPair operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1553,8 +1561,8 @@ func (c *Lightsail) CreateKeyPairRequest(input *CreateKeyPairInput) (req *reques // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -1599,7 +1607,7 @@ const opCreateLoadBalancer = "CreateLoadBalancer" // CreateLoadBalancerRequest generates a "aws/request.Request" representing the // client's request for the CreateLoadBalancer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1639,11 +1647,15 @@ func (c *Lightsail) CreateLoadBalancerRequest(input *CreateLoadBalancerInput) (r // CreateLoadBalancer API operation for Amazon Lightsail. // -// Creates a Lightsail load balancer. -// -// When you create a load balancer, you can specify certificates and port settings. +// Creates a Lightsail load balancer. To learn more about deciding whether to +// load balance your application, see Configure your Lightsail instances for +// load balancing (https://lightsail.aws.amazon.com/ls/docs/how-to/article/configure-lightsail-instances-for-load-balancing). // You can create up to 5 load balancers per AWS Region in your account. // +// When you create a load balancer, you can specify a unique name and port settings. +// To change additional load balancer settings, use the UpdateLoadBalancerAttribute +// operation. +// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -1660,8 +1672,8 @@ func (c *Lightsail) CreateLoadBalancerRequest(input *CreateLoadBalancerInput) (r // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -1706,7 +1718,7 @@ const opCreateLoadBalancerTlsCertificate = "CreateLoadBalancerTlsCertificate" // CreateLoadBalancerTlsCertificateRequest generates a "aws/request.Request" representing the // client's request for the CreateLoadBalancerTlsCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1766,8 +1778,8 @@ func (c *Lightsail) CreateLoadBalancerTlsCertificateRequest(input *CreateLoadBal // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -1812,7 +1824,7 @@ const opDeleteDisk = "DeleteDisk" // DeleteDiskRequest generates a "aws/request.Request" representing the // client's request for the DeleteDisk operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1873,8 +1885,8 @@ func (c *Lightsail) DeleteDiskRequest(input *DeleteDiskInput) (req *request.Requ // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -1919,7 +1931,7 @@ const opDeleteDiskSnapshot = "DeleteDiskSnapshot" // DeleteDiskSnapshotRequest generates a "aws/request.Request" representing the // client's request for the DeleteDiskSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1984,8 +1996,8 @@ func (c *Lightsail) DeleteDiskSnapshotRequest(input *DeleteDiskSnapshotInput) (r // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -2030,7 +2042,7 @@ const opDeleteDomain = "DeleteDomain" // DeleteDomainRequest generates a "aws/request.Request" representing the // client's request for the DeleteDomain operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2088,8 +2100,8 @@ func (c *Lightsail) DeleteDomainRequest(input *DeleteDomainInput) (req *request. // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -2134,7 +2146,7 @@ const opDeleteDomainEntry = "DeleteDomainEntry" // DeleteDomainEntryRequest generates a "aws/request.Request" representing the // client's request for the DeleteDomainEntry operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2192,8 +2204,8 @@ func (c *Lightsail) DeleteDomainEntryRequest(input *DeleteDomainEntryInput) (req // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -2238,7 +2250,7 @@ const opDeleteInstance = "DeleteInstance" // DeleteInstanceRequest generates a "aws/request.Request" representing the // client's request for the DeleteInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2296,8 +2308,8 @@ func (c *Lightsail) DeleteInstanceRequest(input *DeleteInstanceInput) (req *requ // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -2342,7 +2354,7 @@ const opDeleteInstanceSnapshot = "DeleteInstanceSnapshot" // DeleteInstanceSnapshotRequest generates a "aws/request.Request" representing the // client's request for the DeleteInstanceSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2400,8 +2412,8 @@ func (c *Lightsail) DeleteInstanceSnapshotRequest(input *DeleteInstanceSnapshotI // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -2446,7 +2458,7 @@ const opDeleteKeyPair = "DeleteKeyPair" // DeleteKeyPairRequest generates a "aws/request.Request" representing the // client's request for the DeleteKeyPair operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2504,8 +2516,8 @@ func (c *Lightsail) DeleteKeyPairRequest(input *DeleteKeyPairInput) (req *reques // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -2550,7 +2562,7 @@ const opDeleteLoadBalancer = "DeleteLoadBalancer" // DeleteLoadBalancerRequest generates a "aws/request.Request" representing the // client's request for the DeleteLoadBalancer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2590,7 +2602,9 @@ func (c *Lightsail) DeleteLoadBalancerRequest(input *DeleteLoadBalancerInput) (r // DeleteLoadBalancer API operation for Amazon Lightsail. // -// Deletes a Lightsail load balancer. +// Deletes a Lightsail load balancer and all its associated SSL/TLS certificates. +// Once the load balancer is deleted, you will need to create a new load balancer, +// create a new certificate, and verify domain ownership again. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -2608,8 +2622,8 @@ func (c *Lightsail) DeleteLoadBalancerRequest(input *DeleteLoadBalancerInput) (r // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -2654,7 +2668,7 @@ const opDeleteLoadBalancerTlsCertificate = "DeleteLoadBalancerTlsCertificate" // DeleteLoadBalancerTlsCertificateRequest generates a "aws/request.Request" representing the // client's request for the DeleteLoadBalancerTlsCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2694,7 +2708,7 @@ func (c *Lightsail) DeleteLoadBalancerTlsCertificateRequest(input *DeleteLoadBal // DeleteLoadBalancerTlsCertificate API operation for Amazon Lightsail. // -// Deletes a TLS/SSL certificate associated with a Lightsail load balancer. +// Deletes an SSL/TLS certificate associated with a Lightsail load balancer. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -2712,8 +2726,8 @@ func (c *Lightsail) DeleteLoadBalancerTlsCertificateRequest(input *DeleteLoadBal // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -2758,7 +2772,7 @@ const opDetachDisk = "DetachDisk" // DetachDiskRequest generates a "aws/request.Request" representing the // client's request for the DetachDisk operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2818,8 +2832,8 @@ func (c *Lightsail) DetachDiskRequest(input *DetachDiskInput) (req *request.Requ // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -2864,7 +2878,7 @@ const opDetachInstancesFromLoadBalancer = "DetachInstancesFromLoadBalancer" // DetachInstancesFromLoadBalancerRequest generates a "aws/request.Request" representing the // client's request for the DetachInstancesFromLoadBalancer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2906,6 +2920,9 @@ func (c *Lightsail) DetachInstancesFromLoadBalancerRequest(input *DetachInstance // // Detaches the specified instances from a Lightsail load balancer. // +// This operation waits until the instances are no longer needed before they +// are detached from the load balancer. +// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -2922,8 +2939,8 @@ func (c *Lightsail) DetachInstancesFromLoadBalancerRequest(input *DetachInstance // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -2968,7 +2985,7 @@ const opDetachStaticIp = "DetachStaticIp" // DetachStaticIpRequest generates a "aws/request.Request" representing the // client's request for the DetachStaticIp operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3026,8 +3043,8 @@ func (c *Lightsail) DetachStaticIpRequest(input *DetachStaticIpInput) (req *requ // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -3072,7 +3089,7 @@ const opDownloadDefaultKeyPair = "DownloadDefaultKeyPair" // DownloadDefaultKeyPairRequest generates a "aws/request.Request" representing the // client's request for the DownloadDefaultKeyPair operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3130,8 +3147,8 @@ func (c *Lightsail) DownloadDefaultKeyPairRequest(input *DownloadDefaultKeyPairI // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -3176,7 +3193,7 @@ const opGetActiveNames = "GetActiveNames" // GetActiveNamesRequest generates a "aws/request.Request" representing the // client's request for the GetActiveNames operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3234,8 +3251,8 @@ func (c *Lightsail) GetActiveNamesRequest(input *GetActiveNamesInput) (req *requ // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -3280,7 +3297,7 @@ const opGetBlueprints = "GetBlueprints" // GetBlueprintsRequest generates a "aws/request.Request" representing the // client's request for the GetBlueprints operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3341,8 +3358,8 @@ func (c *Lightsail) GetBlueprintsRequest(input *GetBlueprintsInput) (req *reques // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -3387,7 +3404,7 @@ const opGetBundles = "GetBundles" // GetBundlesRequest generates a "aws/request.Request" representing the // client's request for the GetBundles operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3446,8 +3463,8 @@ func (c *Lightsail) GetBundlesRequest(input *GetBundlesInput) (req *request.Requ // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -3492,7 +3509,7 @@ const opGetDisk = "GetDisk" // GetDiskRequest generates a "aws/request.Request" representing the // client's request for the GetDisk operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3550,8 +3567,8 @@ func (c *Lightsail) GetDiskRequest(input *GetDiskInput) (req *request.Request, o // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -3596,7 +3613,7 @@ const opGetDiskSnapshot = "GetDiskSnapshot" // GetDiskSnapshotRequest generates a "aws/request.Request" representing the // client's request for the GetDiskSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3654,8 +3671,8 @@ func (c *Lightsail) GetDiskSnapshotRequest(input *GetDiskSnapshotInput) (req *re // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -3700,7 +3717,7 @@ const opGetDiskSnapshots = "GetDiskSnapshots" // GetDiskSnapshotsRequest generates a "aws/request.Request" representing the // client's request for the GetDiskSnapshots operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3763,8 +3780,8 @@ func (c *Lightsail) GetDiskSnapshotsRequest(input *GetDiskSnapshotsInput) (req * // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -3809,7 +3826,7 @@ const opGetDisks = "GetDisks" // GetDisksRequest generates a "aws/request.Request" representing the // client's request for the GetDisks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3872,8 +3889,8 @@ func (c *Lightsail) GetDisksRequest(input *GetDisksInput) (req *request.Request, // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -3918,7 +3935,7 @@ const opGetDomain = "GetDomain" // GetDomainRequest generates a "aws/request.Request" representing the // client's request for the GetDomain operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3976,8 +3993,8 @@ func (c *Lightsail) GetDomainRequest(input *GetDomainInput) (req *request.Reques // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -4022,7 +4039,7 @@ const opGetDomains = "GetDomains" // GetDomainsRequest generates a "aws/request.Request" representing the // client's request for the GetDomains operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4080,8 +4097,8 @@ func (c *Lightsail) GetDomainsRequest(input *GetDomainsInput) (req *request.Requ // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -4126,7 +4143,7 @@ const opGetInstance = "GetInstance" // GetInstanceRequest generates a "aws/request.Request" representing the // client's request for the GetInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4185,8 +4202,8 @@ func (c *Lightsail) GetInstanceRequest(input *GetInstanceInput) (req *request.Re // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -4231,7 +4248,7 @@ const opGetInstanceAccessDetails = "GetInstanceAccessDetails" // GetInstanceAccessDetailsRequest generates a "aws/request.Request" representing the // client's request for the GetInstanceAccessDetails operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4290,8 +4307,8 @@ func (c *Lightsail) GetInstanceAccessDetailsRequest(input *GetInstanceAccessDeta // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -4336,7 +4353,7 @@ const opGetInstanceMetricData = "GetInstanceMetricData" // GetInstanceMetricDataRequest generates a "aws/request.Request" representing the // client's request for the GetInstanceMetricData operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4395,8 +4412,8 @@ func (c *Lightsail) GetInstanceMetricDataRequest(input *GetInstanceMetricDataInp // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -4441,7 +4458,7 @@ const opGetInstancePortStates = "GetInstancePortStates" // GetInstancePortStatesRequest generates a "aws/request.Request" representing the // client's request for the GetInstancePortStates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4499,8 +4516,8 @@ func (c *Lightsail) GetInstancePortStatesRequest(input *GetInstancePortStatesInp // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -4545,7 +4562,7 @@ const opGetInstanceSnapshot = "GetInstanceSnapshot" // GetInstanceSnapshotRequest generates a "aws/request.Request" representing the // client's request for the GetInstanceSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4603,8 +4620,8 @@ func (c *Lightsail) GetInstanceSnapshotRequest(input *GetInstanceSnapshotInput) // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -4649,7 +4666,7 @@ const opGetInstanceSnapshots = "GetInstanceSnapshots" // GetInstanceSnapshotsRequest generates a "aws/request.Request" representing the // client's request for the GetInstanceSnapshots operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4707,8 +4724,8 @@ func (c *Lightsail) GetInstanceSnapshotsRequest(input *GetInstanceSnapshotsInput // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -4753,7 +4770,7 @@ const opGetInstanceState = "GetInstanceState" // GetInstanceStateRequest generates a "aws/request.Request" representing the // client's request for the GetInstanceState operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4811,8 +4828,8 @@ func (c *Lightsail) GetInstanceStateRequest(input *GetInstanceStateInput) (req * // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -4857,7 +4874,7 @@ const opGetInstances = "GetInstances" // GetInstancesRequest generates a "aws/request.Request" representing the // client's request for the GetInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4916,8 +4933,8 @@ func (c *Lightsail) GetInstancesRequest(input *GetInstancesInput) (req *request. // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -4962,7 +4979,7 @@ const opGetKeyPair = "GetKeyPair" // GetKeyPairRequest generates a "aws/request.Request" representing the // client's request for the GetKeyPair operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5020,8 +5037,8 @@ func (c *Lightsail) GetKeyPairRequest(input *GetKeyPairInput) (req *request.Requ // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -5066,7 +5083,7 @@ const opGetKeyPairs = "GetKeyPairs" // GetKeyPairsRequest generates a "aws/request.Request" representing the // client's request for the GetKeyPairs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5124,8 +5141,8 @@ func (c *Lightsail) GetKeyPairsRequest(input *GetKeyPairsInput) (req *request.Re // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -5170,7 +5187,7 @@ const opGetLoadBalancer = "GetLoadBalancer" // GetLoadBalancerRequest generates a "aws/request.Request" representing the // client's request for the GetLoadBalancer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5228,8 +5245,8 @@ func (c *Lightsail) GetLoadBalancerRequest(input *GetLoadBalancerInput) (req *re // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -5274,7 +5291,7 @@ const opGetLoadBalancerMetricData = "GetLoadBalancerMetricData" // GetLoadBalancerMetricDataRequest generates a "aws/request.Request" representing the // client's request for the GetLoadBalancerMetricData operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5332,8 +5349,8 @@ func (c *Lightsail) GetLoadBalancerMetricDataRequest(input *GetLoadBalancerMetri // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -5378,7 +5395,7 @@ const opGetLoadBalancerTlsCertificates = "GetLoadBalancerTlsCertificates" // GetLoadBalancerTlsCertificatesRequest generates a "aws/request.Request" representing the // client's request for the GetLoadBalancerTlsCertificates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5423,6 +5440,9 @@ func (c *Lightsail) GetLoadBalancerTlsCertificatesRequest(input *GetLoadBalancer // // TLS is just an updated, more secure version of Secure Socket Layer (SSL). // +// You can have a maximum of 2 certificates associated with a Lightsail load +// balancer. One is active and the other is inactive. +// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -5439,8 +5459,8 @@ func (c *Lightsail) GetLoadBalancerTlsCertificatesRequest(input *GetLoadBalancer // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -5485,7 +5505,7 @@ const opGetLoadBalancers = "GetLoadBalancers" // GetLoadBalancersRequest generates a "aws/request.Request" representing the // client's request for the GetLoadBalancers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5547,8 +5567,8 @@ func (c *Lightsail) GetLoadBalancersRequest(input *GetLoadBalancersInput) (req * // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -5593,7 +5613,7 @@ const opGetOperation = "GetOperation" // GetOperationRequest generates a "aws/request.Request" representing the // client's request for the GetOperation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5653,8 +5673,8 @@ func (c *Lightsail) GetOperationRequest(input *GetOperationInput) (req *request. // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -5699,7 +5719,7 @@ const opGetOperations = "GetOperations" // GetOperationsRequest generates a "aws/request.Request" representing the // client's request for the GetOperations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5761,8 +5781,8 @@ func (c *Lightsail) GetOperationsRequest(input *GetOperationsInput) (req *reques // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -5807,7 +5827,7 @@ const opGetOperationsForResource = "GetOperationsForResource" // GetOperationsForResourceRequest generates a "aws/request.Request" representing the // client's request for the GetOperationsForResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5865,8 +5885,8 @@ func (c *Lightsail) GetOperationsForResourceRequest(input *GetOperationsForResou // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -5911,7 +5931,7 @@ const opGetRegions = "GetRegions" // GetRegionsRequest generates a "aws/request.Request" representing the // client's request for the GetRegions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5970,8 +5990,8 @@ func (c *Lightsail) GetRegionsRequest(input *GetRegionsInput) (req *request.Requ // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -6016,7 +6036,7 @@ const opGetStaticIp = "GetStaticIp" // GetStaticIpRequest generates a "aws/request.Request" representing the // client's request for the GetStaticIp operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6074,8 +6094,8 @@ func (c *Lightsail) GetStaticIpRequest(input *GetStaticIpInput) (req *request.Re // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -6120,7 +6140,7 @@ const opGetStaticIps = "GetStaticIps" // GetStaticIpsRequest generates a "aws/request.Request" representing the // client's request for the GetStaticIps operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6178,8 +6198,8 @@ func (c *Lightsail) GetStaticIpsRequest(input *GetStaticIpsInput) (req *request. // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -6224,7 +6244,7 @@ const opImportKeyPair = "ImportKeyPair" // ImportKeyPairRequest generates a "aws/request.Request" representing the // client's request for the ImportKeyPair operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6282,8 +6302,8 @@ func (c *Lightsail) ImportKeyPairRequest(input *ImportKeyPairInput) (req *reques // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -6328,7 +6348,7 @@ const opIsVpcPeered = "IsVpcPeered" // IsVpcPeeredRequest generates a "aws/request.Request" representing the // client's request for the IsVpcPeered operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6386,8 +6406,8 @@ func (c *Lightsail) IsVpcPeeredRequest(input *IsVpcPeeredInput) (req *request.Re // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -6432,7 +6452,7 @@ const opOpenInstancePublicPorts = "OpenInstancePublicPorts" // OpenInstancePublicPortsRequest generates a "aws/request.Request" representing the // client's request for the OpenInstancePublicPorts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6490,8 +6510,8 @@ func (c *Lightsail) OpenInstancePublicPortsRequest(input *OpenInstancePublicPort // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -6536,7 +6556,7 @@ const opPeerVpc = "PeerVpc" // PeerVpcRequest generates a "aws/request.Request" representing the // client's request for the PeerVpc operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6594,8 +6614,8 @@ func (c *Lightsail) PeerVpcRequest(input *PeerVpcInput) (req *request.Request, o // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -6640,7 +6660,7 @@ const opPutInstancePublicPorts = "PutInstancePublicPorts" // PutInstancePublicPortsRequest generates a "aws/request.Request" representing the // client's request for the PutInstancePublicPorts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6699,8 +6719,8 @@ func (c *Lightsail) PutInstancePublicPortsRequest(input *PutInstancePublicPortsI // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -6745,7 +6765,7 @@ const opRebootInstance = "RebootInstance" // RebootInstanceRequest generates a "aws/request.Request" representing the // client's request for the RebootInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6806,8 +6826,8 @@ func (c *Lightsail) RebootInstanceRequest(input *RebootInstanceInput) (req *requ // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -6852,7 +6872,7 @@ const opReleaseStaticIp = "ReleaseStaticIp" // ReleaseStaticIpRequest generates a "aws/request.Request" representing the // client's request for the ReleaseStaticIp operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6910,8 +6930,8 @@ func (c *Lightsail) ReleaseStaticIpRequest(input *ReleaseStaticIpInput) (req *re // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -6956,7 +6976,7 @@ const opStartInstance = "StartInstance" // StartInstanceRequest generates a "aws/request.Request" representing the // client's request for the StartInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7015,8 +7035,8 @@ func (c *Lightsail) StartInstanceRequest(input *StartInstanceInput) (req *reques // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -7061,7 +7081,7 @@ const opStopInstance = "StopInstance" // StopInstanceRequest generates a "aws/request.Request" representing the // client's request for the StopInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7119,8 +7139,8 @@ func (c *Lightsail) StopInstanceRequest(input *StopInstanceInput) (req *request. // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -7165,7 +7185,7 @@ const opUnpeerVpc = "UnpeerVpc" // UnpeerVpcRequest generates a "aws/request.Request" representing the // client's request for the UnpeerVpc operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7223,8 +7243,8 @@ func (c *Lightsail) UnpeerVpcRequest(input *UnpeerVpcInput) (req *request.Reques // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -7269,7 +7289,7 @@ const opUpdateDomainEntry = "UpdateDomainEntry" // UpdateDomainEntryRequest generates a "aws/request.Request" representing the // client's request for the UpdateDomainEntry operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7327,8 +7347,8 @@ func (c *Lightsail) UpdateDomainEntryRequest(input *UpdateDomainEntryInput) (req // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -7373,7 +7393,7 @@ const opUpdateLoadBalancerAttribute = "UpdateLoadBalancerAttribute" // UpdateLoadBalancerAttributeRequest generates a "aws/request.Request" representing the // client's request for the UpdateLoadBalancerAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7413,7 +7433,8 @@ func (c *Lightsail) UpdateLoadBalancerAttributeRequest(input *UpdateLoadBalancer // UpdateLoadBalancerAttribute API operation for Amazon Lightsail. // -// Updates the specified attribute for a load balancer. +// Updates the specified attribute for a load balancer. You can only update +// one attribute at a time. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -7431,8 +7452,8 @@ func (c *Lightsail) UpdateLoadBalancerAttributeRequest(input *UpdateLoadBalancer // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. -// Please set your Region configuration to us-east-1 to create, view, or edit -// these resources. +// Please set your AWS Region configuration to us-east-1 to create, view, or +// edit these resources. // // * ErrCodeNotFoundException "NotFoundException" // Lightsail throws this exception when it cannot find a resource. @@ -7631,6 +7652,12 @@ type AttachInstancesToLoadBalancerInput struct { // An array of strings representing the instance name(s) you want to attach // to your load balancer. // + // An instance must be running before you can attach it to your load balancer. + // + // There are no additional limits on the number of instances you can attach + // to your load balancer, aside from the limit of Lightsail instances you can + // create in your account (20). + // // InstanceNames is a required field InstanceNames []*string `locationName:"instanceNames" type:"list" required:"true"` @@ -7704,12 +7731,12 @@ func (s *AttachInstancesToLoadBalancerOutput) SetOperations(v []*Operation) *Att type AttachLoadBalancerTlsCertificateInput struct { _ struct{} `type:"structure"` - // The name of your TLS/SSL certificate. + // The name of your SSL/TLS certificate. // // CertificateName is a required field CertificateName *string `locationName:"certificateName" type:"string" required:"true"` - // The name of the load balancer to which you want to associate the TLS/SSL + // The name of the load balancer to which you want to associate the SSL/TLS // certificate. // // LoadBalancerName is a required field @@ -7758,6 +7785,9 @@ type AttachLoadBalancerTlsCertificateOutput struct { _ struct{} `type:"structure"` // An object representing the API operations. + // + // These SSL/TLS certificates are only usable by Lightsail load balancers. You + // can't get the certificate and use it for another purpose. Operations []*Operation `locationName:"operations" type:"list"` } @@ -9096,8 +9126,8 @@ func (s *CreateKeyPairOutput) SetPublicKeyBase64(v string) *CreateKeyPairOutput type CreateLoadBalancerInput struct { _ struct{} `type:"structure"` - // The alternative domain names to use with your TLS/SSL certificate (e.g., - // www.example.com, www.ejemplo.com, ejemplo.com). + // The optional alternative domains and subdomains to use with your SSL/TLS + // certificate (e.g., www.example.com, example.com, m.example.com, blog.example.com). CertificateAlternativeNames []*string `locationName:"certificateAlternativeNames" type:"list"` // The domain name with which your certificate is associated (e.g., example.com). @@ -9106,7 +9136,7 @@ type CreateLoadBalancerInput struct { // vice-versa). CertificateDomainName *string `locationName:"certificateDomainName" type:"string"` - // The name of the TLS/SSL certificate. + // The name of the SSL/TLS certificate. // // If you specify certificateName, then certificateDomainName is required (and // vice-versa). @@ -9115,6 +9145,10 @@ type CreateLoadBalancerInput struct { // The path you provided to perform the load balancer health check. If you didn't // specify a health check path, Lightsail uses the root path of your website // (e.g., "/"). + // + // You may want to specify a custom health check path other than the root of + // your application if your home page loads slowly or has a lot of media or + // scripting on it. HealthCheckPath *string `locationName:"healthCheckPath" type:"string"` // The instance port where you're creating your load balancer. @@ -9216,20 +9250,28 @@ func (s *CreateLoadBalancerOutput) SetOperations(v []*Operation) *CreateLoadBala type CreateLoadBalancerTlsCertificateInput struct { _ struct{} `type:"structure"` - // An array of strings listing alternative domain names for your TLS/SSL certificate. + // An array of strings listing alternative domains and subdomains for your SSL/TLS + // certificate. Lightsail will de-dupe the names for you. You can have a maximum + // of 9 alternative names (in addition to the 1 primary domain). We do not support + // wildcards (e.g., *.example.com). CertificateAlternativeNames []*string `locationName:"certificateAlternativeNames" type:"list"` - // The domain name (e.g., example.com) for your TLS/SSL certificate. + // The domain name (e.g., example.com) for your SSL/TLS certificate. // // CertificateDomainName is a required field CertificateDomainName *string `locationName:"certificateDomainName" type:"string" required:"true"` - // The TLS/SSL certificate name. + // The SSL/TLS certificate name. + // + // You can have up to 10 certificates in your account at one time. Each Lightsail + // load balancer can have up to 2 certificates associated with it at one time. + // There is also an overall limit to the number of certificates that can be + // issue in a 365-day period. For more information, see Limits (http://docs.aws.amazon.com/acm/latest/userguide/acm-limits.html). // // CertificateName is a required field CertificateName *string `locationName:"certificateName" type:"string" required:"true"` - // The load balancer name where you want to create the TLS/SSL certificate. + // The load balancer name where you want to create the SSL/TLS certificate. // // LoadBalancerName is a required field LoadBalancerName *string `locationName:"loadBalancerName" type:"string" required:"true"` @@ -9821,12 +9863,16 @@ func (s *DeleteLoadBalancerOutput) SetOperations(v []*Operation) *DeleteLoadBala type DeleteLoadBalancerTlsCertificateInput struct { _ struct{} `type:"structure"` - // The TLS/SSL certificate name. + // The SSL/TLS certificate name. // // CertificateName is a required field CertificateName *string `locationName:"certificateName" type:"string" required:"true"` - // When true, forces the deletion of a TLS/SSL certificate. + // When true, forces the deletion of an SSL/TLS certificate. + // + // There can be two certificates associated with a Lightsail load balancer: + // the primary and the backup. The force parameter is required when the primary + // SSL/TLS certificate is in use by an instance attached to the load balancer. Force *bool `locationName:"force" type:"boolean"` // The load balancer name. @@ -10500,7 +10546,9 @@ type DomainEntry struct { Id *string `locationName:"id" type:"string"` // When true, specifies whether the domain entry is an alias used by the Lightsail - // load balancer. + // load balancer. You can include an alias (A type) record in your request, + // which points to a load balancer DNS name and routes traffic to your load + // balancer IsAlias *bool `locationName:"isAlias" type:"boolean"` // The name of the domain. @@ -10513,6 +10561,10 @@ type DomainEntry struct { Options map[string]*string `locationName:"options" deprecated:"true" type:"map"` // The target AWS name server (e.g., ns-111.awsdns-22.com.). + // + // For Lightsail load balancers, the value looks like ab1234c56789c6b86aba6fb203d443bc-123456789.us-east-2.elb.amazonaws.com. + // Be sure to also set isAlias to true when setting up an A record for a load + // balancer. Target *string `locationName:"target" type:"string"` // The type of domain entry (e.g., SOA or NS). @@ -12014,6 +12066,24 @@ type GetLoadBalancerMetricDataInput struct { // An array of statistics that you want to request metrics for. Valid values // are listed below. // + // * SampleCount - The count (number) of data points used for the statistical + // calculation. + // + // * Average - The value of Sum / SampleCount during the specified period. + // By comparing this statistic with the Minimum and Maximum, you can determine + // the full scope of a metric and how close the average use is to the Minimum + // and Maximum. This comparison helps you to know when to increase or decrease + // your resources as needed. + // + // * Sum - All values submitted for the matching metric added together. This + // statistic can be useful for determining the total volume of a metric. + // + // * Minimum - The lowest value observed during the specified period. You + // can use this value to determine low volumes of activity for your application. + // + // * Maximum - The highest value observed during the specified period. You + // can use this value to determine high volumes of activity for your application. + // // Statistics is a required field Statistics []*string `locationName:"statistics" type:"list" required:"true"` @@ -12116,7 +12186,86 @@ type GetLoadBalancerMetricDataOutput struct { MetricData []*MetricDatapoint `locationName:"metricData" type:"list"` // The metric about which you are receiving information. Valid values are listed - // below. + // below, along with the most useful statistics to include in your request. + // + // * ClientTLSNegotiationErrorCount - The number of TLS connections initiated + // by the client that did not establish a session with the load balancer. + // Possible causes include a mismatch of ciphers or protocols. + // + // Statistics: The most useful statistic is Sum. + // + // * HealthyHostCount - The number of target instances that are considered + // healthy. + // + // Statistics: The most useful statistic are Average, Minimum, and Maximum. + // + // * UnhealthyHostCount - The number of target instances that are considered + // unhealthy. + // + // Statistics: The most useful statistic are Average, Minimum, and Maximum. + // + // * HTTPCode_LB_4XX_Count - The number of HTTP 4XX client error codes that + // originate from the load balancer. Client errors are generated when requests + // are malformed or incomplete. These requests have not been received by + // the target instance. This count does not include any response codes generated + // by the target instances. + // + // Statistics: The most useful statistic is Sum. Note that Minimum, Maximum, + // and Average all return 1. + // + // * HTTPCode_LB_5XX_Count - The number of HTTP 5XX server error codes that + // originate from the load balancer. This count does not include any response + // codes generated by the target instances. + // + // Statistics: The most useful statistic is Sum. Note that Minimum, Maximum, + // and Average all return 1. Note that Minimum, Maximum, and Average all + // return 1. + // + // * HTTPCode_Instance_2XX_Count - The number of HTTP response codes generated + // by the target instances. This does not include any response codes generated + // by the load balancer. + // + // Statistics: The most useful statistic is Sum. Note that Minimum, Maximum, + // and Average all return 1. + // + // * HTTPCode_Instance_3XX_Count - The number of HTTP response codes generated + // by the target instances. This does not include any response codes generated + // by the load balancer. + // + // Statistics: The most useful statistic is Sum. Note that Minimum, Maximum, + // and Average all return 1. + // + // * HTTPCode_Instance_4XX_Count - The number of HTTP response codes generated + // by the target instances. This does not include any response codes generated + // by the load balancer. + // + // Statistics: The most useful statistic is Sum. Note that Minimum, Maximum, + // and Average all return 1. + // + // * HTTPCode_Instance_5XX_Count - The number of HTTP response codes generated + // by the target instances. This does not include any response codes generated + // by the load balancer. + // + // Statistics: The most useful statistic is Sum. Note that Minimum, Maximum, + // and Average all return 1. + // + // * InstanceResponseTime - The time elapsed, in seconds, after the request + // leaves the load balancer until a response from the target instance is + // received. + // + // Statistics: The most useful statistic is Average. + // + // * RejectedConnectionCount - The number of connections that were rejected + // because the load balancer had reached its maximum number of connections. + // + // Statistics: The most useful statistic is Sum. + // + // * RequestCount - The number of requests processed over IPv4. This count + // includes only the requests with a response generated by a target instance + // of the load balancer. + // + // Statistics: The most useful statistic is Sum. Note that Minimum, Maximum, + // and Average all return 1. MetricName *string `locationName:"metricName" type:"string" enum:"LoadBalancerMetricName"` } @@ -12168,7 +12317,7 @@ func (s *GetLoadBalancerOutput) SetLoadBalancer(v *LoadBalancer) *GetLoadBalance type GetLoadBalancerTlsCertificatesInput struct { _ struct{} `type:"structure"` - // The name of the load balancer where you stored your TLS/SSL certificate. + // The name of the load balancer you associated with your SSL/TLS certificate. // // LoadBalancerName is a required field LoadBalancerName *string `locationName:"loadBalancerName" type:"string" required:"true"` @@ -12206,7 +12355,7 @@ func (s *GetLoadBalancerTlsCertificatesInput) SetLoadBalancerName(v string) *Get type GetLoadBalancerTlsCertificatesOutput struct { _ struct{} `type:"structure"` - // An array of LoadBalancerTlsCertificate objects describing your TLS/SSL certificates. + // An array of LoadBalancerTlsCertificate objects describing your SSL/TLS certificates. TlsCertificates []*LoadBalancerTlsCertificate `locationName:"tlsCertificates" type:"list"` } @@ -13083,7 +13232,53 @@ type InstanceHealthSummary struct { // Describes the overall instance health. Valid values are below. InstanceHealth *string `locationName:"instanceHealth" type:"string" enum:"InstanceHealthState"` - // More information about the instance health. Valid values are below. + // More information about the instance health. If the instanceHealth is healthy, + // then an instanceHealthReason value is not provided. + // + // If instanceHealth is initial, the instanceHealthReason value can be one of + // the following: + // + // * Lb.RegistrationInProgress - The target instance is in the process of + // being registered with the load balancer. + // + // * Lb.InitialHealthChecking - The Lightsail load balancer is still sending + // the target instance the minimum number of health checks required to determine + // its health status. + // + // If instanceHealth is unhealthy, the instanceHealthReason value can be one + // of the following: + // + // * Instance.ResponseCodeMismatch - The health checks did not return an + // expected HTTP code. + // + // * Instance.Timeout - The health check requests timed out. + // + // * Instance.FailedHealthChecks - The health checks failed because the connection + // to the target instance timed out, the target instance response was malformed, + // or the target instance failed the health check for an unknown reason. + // + // * Lb.InternalError - The health checks failed due to an internal error. + // + // If instanceHealth is unused, the instanceHealthReason value can be one of + // the following: + // + // * Instance.NotRegistered - The target instance is not registered with + // the target group. + // + // * Instance.NotInUse - The target group is not used by any load balancer, + // or the target instance is in an Availability Zone that is not enabled + // for its load balancer. + // + // * Instance.IpUnusable - The target IP address is reserved for use by a + // Lightsail load balancer. + // + // * Instance.InvalidState - The target is in the stopped or terminated state. + // + // If instanceHealth is draining, the instanceHealthReason value can be one + // of the following: + // + // * Instance.DeregistrationInProgress - The target instance is in the process + // of being deregistered and the deregistration delay period has not expired. InstanceHealthReason *string `locationName:"instanceHealthReason" type:"string" enum:"InstanceHealthReason"` // The name of the Lightsail instance for which you are requesting health check @@ -13637,20 +13832,24 @@ type LoadBalancer struct { // balancer. InstanceHealthSummary []*InstanceHealthSummary `locationName:"instanceHealthSummary" type:"list"` - // The instance port where the load balancer is listening. + // The port where the load balancer will direct traffic to your Lightsail instances. + // For HTTP traffic, it's port 80. For HTTPS traffic, it's port 443. InstancePort *int64 `locationName:"instancePort" type:"integer"` - // The AWS Region and Availability Zone where your load balancer was created - // (e.g., us-east-2a). + // The AWS Region where your load balancer was created (e.g., us-east-2a). Lightsail + // automatically creates your load balancer across Availability Zones. Location *ResourceLocation `locationName:"location" type:"structure"` // The name of the load balancer (e.g., my-load-balancer). Name *string `locationName:"name" type:"string"` // The protocol you have enabled for your load balancer. Valid values are below. + // + // You can't just have HTTP_HTTPS, but you can have just HTTP. Protocol *string `locationName:"protocol" type:"string" enum:"LoadBalancerProtocol"` - // An array of public port settings for your load balancer. + // An array of public port settings for your load balancer. For HTTP, use port + // 80. For HTTPS, use port 443. PublicPorts []*int64 `locationName:"publicPorts" type:"list"` // The resource type (e.g., LoadBalancer. @@ -13665,7 +13864,8 @@ type LoadBalancer struct { SupportCode *string `locationName:"supportCode" type:"string"` // An array of LoadBalancerTlsCertificateSummary objects that provide additional - // information about the TLS/SSL certificates. + // information about the SSL/TLS certificates. For example, if true, the certificate + // is attached to the load balancer. TlsCertificateSummaries []*LoadBalancerTlsCertificateSummary `locationName:"tlsCertificateSummaries" type:"list"` } @@ -13769,32 +13969,32 @@ func (s *LoadBalancer) SetTlsCertificateSummaries(v []*LoadBalancerTlsCertificat return s } -// Describes a load balancer TLS/SSL certificate. +// Describes a load balancer SSL/TLS certificate. // // TLS is just an updated, more secure version of Secure Socket Layer (SSL). type LoadBalancerTlsCertificate struct { _ struct{} `type:"structure"` - // The Amazon Resource Name (ARN) of the TLS/SSL certificate. + // The Amazon Resource Name (ARN) of the SSL/TLS certificate. Arn *string `locationName:"arn" type:"string"` - // The time when you created your TLS/SSL certificate. + // The time when you created your SSL/TLS certificate. CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"unix"` - // The domain name for your TLS/SSL certificate. + // The domain name for your SSL/TLS certificate. DomainName *string `locationName:"domainName" type:"string"` // An array of LoadBalancerTlsCertificateDomainValidationRecord objects describing // the records. DomainValidationRecords []*LoadBalancerTlsCertificateDomainValidationRecord `locationName:"domainValidationRecords" type:"list"` - // The reason for the TLS/SSL certificate validation failure. + // The reason for the SSL/TLS certificate validation failure. FailureReason *string `locationName:"failureReason" type:"string" enum:"LoadBalancerTlsCertificateFailureReason"` - // When true, the TLS/SSL certificate is attached to the Lightsail load balancer. + // When true, the SSL/TLS certificate is attached to the Lightsail load balancer. IsAttached *bool `locationName:"isAttached" type:"boolean"` - // The time when the TLS/SSL certificate was issued. + // The time when the SSL/TLS certificate was issued. IssuedAt *time.Time `locationName:"issuedAt" type:"timestamp" timestampFormat:"unix"` // The issuer of the certificate. @@ -13804,32 +14004,53 @@ type LoadBalancerTlsCertificate struct { // key). KeyAlgorithm *string `locationName:"keyAlgorithm" type:"string"` - // The load balancer name where your TLS/SSL certificate is attached. + // The load balancer name where your SSL/TLS certificate is attached. LoadBalancerName *string `locationName:"loadBalancerName" type:"string"` // The AWS Region and Availability Zone where you created your certificate. Location *ResourceLocation `locationName:"location" type:"structure"` - // The name of the TLS/SSL certificate (e.g., my-certificate). + // The name of the SSL/TLS certificate (e.g., my-certificate). Name *string `locationName:"name" type:"string"` - // The timestamp when the TLS/SSL certificate expires. + // The timestamp when the SSL/TLS certificate expires. NotAfter *time.Time `locationName:"notAfter" type:"timestamp" timestampFormat:"unix"` - // The timestamp when the TLS/SSL certificate is first valid. + // The timestamp when the SSL/TLS certificate is first valid. NotBefore *time.Time `locationName:"notBefore" type:"timestamp" timestampFormat:"unix"` // An object containing information about the status of Lightsail's managed // renewal for the certificate. RenewalSummary *LoadBalancerTlsCertificateRenewalSummary `locationName:"renewalSummary" type:"structure"` - // The resource type (e.g., LoadBalancerTlsCertificate. + // The resource type (e.g., LoadBalancerTlsCertificate). + // + // * Instance - A Lightsail instance (a virtual private server) + // + // * StaticIp - A static IP address + // + // * KeyPair - The key pair used to connect to a Lightsail instance + // + // * InstanceSnapshot - A Lightsail instance snapshot + // + // * Domain - A DNS zone + // + // * PeeredVpc - A peered VPC + // + // * LoadBalancer - A Lightsail load balancer + // + // * LoadBalancerTlsCertificate - An SSL/TLS certificate associated with + // a Lightsail load balancer + // + // * Disk - A Lightsail block storage disk + // + // * DiskSnapshot - A block storage disk snapshot ResourceType *string `locationName:"resourceType" type:"string" enum:"ResourceType"` // The reason the certificate was revoked. Valid values are below. RevocationReason *string `locationName:"revocationReason" type:"string" enum:"LoadBalancerTlsCertificateRevocationReason"` - // The timestamp when the TLS/SSL certificate was revoked. + // The timestamp when the SSL/TLS certificate was revoked. RevokedAt *time.Time `locationName:"revokedAt" type:"timestamp" timestampFormat:"unix"` // The serial number of the certificate. @@ -13838,22 +14059,22 @@ type LoadBalancerTlsCertificate struct { // The algorithm that was used to sign the certificate. SignatureAlgorithm *string `locationName:"signatureAlgorithm" type:"string"` - // The status of the TLS/SSL certificate. Valid values are below. + // The status of the SSL/TLS certificate. Valid values are below. Status *string `locationName:"status" type:"string" enum:"LoadBalancerTlsCertificateStatus"` // The name of the entity that is associated with the public key contained in // the certificate. Subject *string `locationName:"subject" type:"string"` - // One or more domain names (subject alternative names) included in the certificate. - // This list contains the domain names that are bound to the public key that - // is contained in the certificate. The subject alternative names include the - // canonical domain name (CN) of the certificate and additional domain names - // that can be used to connect to the website. + // One or more domains or subdomains included in the certificate. This list + // contains the domain names that are bound to the public key that is contained + // in the certificate. The subject alternative names include the canonical domain + // name (CNAME) of the certificate and additional domain names that can be used + // to connect to the website, such as example.com, www.example.com, or m.example.com. SubjectAlternativeNames []*string `locationName:"subjectAlternativeNames" type:"list"` // The support code. Include this code in your email to support when you have - // questions about your Lightsail load balancer or TLS/SSL certificate. This + // questions about your Lightsail load balancer or SSL/TLS certificate. This // code enables our support team to look up your Lightsail information more // easily. SupportCode *string `locationName:"supportCode" type:"string"` @@ -14013,12 +14234,12 @@ func (s *LoadBalancerTlsCertificate) SetSupportCode(v string) *LoadBalancerTlsCe return s } -// Contains information about the domain names on a TLS/SSL certificate that +// Contains information about the domain names on an SSL/TLS certificate that // you will use to validate domain ownership. type LoadBalancerTlsCertificateDomainValidationOption struct { _ struct{} `type:"structure"` - // A fully qualified domain name in the certificate request. + // The fully qualified domain name in the certificate request. DomainName *string `locationName:"domainName" type:"string"` // The status of the domain validation. Valid values are listed below. @@ -14047,11 +14268,11 @@ func (s *LoadBalancerTlsCertificateDomainValidationOption) SetValidationStatus(v return s } -// Describes the validation record of each domain name in the TLS/SSL certificate. +// Describes the validation record of each domain name in the SSL/TLS certificate. type LoadBalancerTlsCertificateDomainValidationRecord struct { _ struct{} `type:"structure"` - // The domain name against which your TLS/SSL certificate was validated. + // The domain name against which your SSL/TLS certificate was validated. DomainName *string `locationName:"domainName" type:"string"` // A fully qualified domain name in the certificate. For example, example.com. @@ -14144,14 +14365,14 @@ func (s *LoadBalancerTlsCertificateRenewalSummary) SetRenewalStatus(v string) *L return s } -// Provides a summary of TLS/SSL certificate metadata. +// Provides a summary of SSL/TLS certificate metadata. type LoadBalancerTlsCertificateSummary struct { _ struct{} `type:"structure"` - // When true, the TLS/SSL certificate is attached to the Lightsail load balancer. + // When true, the SSL/TLS certificate is attached to the Lightsail load balancer. IsAttached *bool `locationName:"isAttached" type:"boolean"` - // The name of the TLS/SSL certificate. + // The name of the SSL/TLS certificate. Name *string `locationName:"name" type:"string"` } @@ -14726,7 +14947,7 @@ func (s *RebootInstanceInput) SetInstanceName(v string) *RebootInstanceInput { type RebootInstanceOutput struct { _ struct{} `type:"structure"` - // An array of key-value pairs containing information about the request operation. + // An array of key-value pairs containing information about the request operations. Operations []*Operation `locationName:"operations" type:"list"` } @@ -15260,7 +15481,7 @@ type UpdateLoadBalancerAttributeInput struct { // AttributeValue is a required field AttributeValue *string `locationName:"attributeValue" min:"1" type:"string" required:"true"` - // The name of the load balancer that you want to modify. + // The name of the load balancer that you want to modify (e.g., my-load-balancer. // // LoadBalancerName is a required field LoadBalancerName *string `locationName:"loadBalancerName" type:"string" required:"true"` @@ -15785,6 +16006,9 @@ const ( // OperationStatusCompleted is a OperationStatus enum value OperationStatusCompleted = "Completed" + + // OperationStatusSucceeded is a OperationStatus enum value + OperationStatusSucceeded = "Succeeded" ) const ( @@ -15920,11 +16144,14 @@ const ( // RegionNameUsWest2 is a RegionName enum value RegionNameUsWest2 = "us-west-2" + // RegionNameEuCentral1 is a RegionName enum value + RegionNameEuCentral1 = "eu-central-1" + // RegionNameEuWest1 is a RegionName enum value RegionNameEuWest1 = "eu-west-1" - // RegionNameEuCentral1 is a RegionName enum value - RegionNameEuCentral1 = "eu-central-1" + // RegionNameEuWest2 is a RegionName enum value + RegionNameEuWest2 = "eu-west-2" // RegionNameApSouth1 is a RegionName enum value RegionNameApSouth1 = "ap-south-1" diff --git a/vendor/github.com/aws/aws-sdk-go/service/lightsail/errors.go b/vendor/github.com/aws/aws-sdk-go/service/lightsail/errors.go index d1ef481f201b..bda8b8a66887 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/lightsail/errors.go +++ b/vendor/github.com/aws/aws-sdk-go/service/lightsail/errors.go @@ -25,8 +25,8 @@ const ( // rules of an input field. // // Domain-related APIs are only available in the N. Virginia (us-east-1) Region. - // Please set your Region configuration to us-east-1 to create, view, or edit - // these resources. + // Please set your AWS Region configuration to us-east-1 to create, view, or + // edit these resources. ErrCodeInvalidInputException = "InvalidInputException" // ErrCodeNotFoundException for service response error code diff --git a/vendor/github.com/aws/aws-sdk-go/service/mediastore/api.go b/vendor/github.com/aws/aws-sdk-go/service/mediastore/api.go index f5d369592ab7..172f138eb0f3 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/mediastore/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/mediastore/api.go @@ -14,7 +14,7 @@ const opCreateContainer = "CreateContainer" // CreateContainerRequest generates a "aws/request.Request" representing the // client's request for the CreateContainer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -100,7 +100,7 @@ const opDeleteContainer = "DeleteContainer" // DeleteContainerRequest generates a "aws/request.Request" representing the // client's request for the DeleteContainer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -187,7 +187,7 @@ const opDeleteContainerPolicy = "DeleteContainerPolicy" // DeleteContainerPolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteContainerPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -275,7 +275,7 @@ const opDeleteCorsPolicy = "DeleteCorsPolicy" // DeleteCorsPolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteCorsPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -368,7 +368,7 @@ const opDescribeContainer = "DescribeContainer" // DescribeContainerRequest generates a "aws/request.Request" representing the // client's request for the DescribeContainer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -455,7 +455,7 @@ const opGetContainerPolicy = "GetContainerPolicy" // GetContainerPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetContainerPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -545,7 +545,7 @@ const opGetCorsPolicy = "GetCorsPolicy" // GetCorsPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetCorsPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -638,7 +638,7 @@ const opListContainers = "ListContainers" // ListContainersRequest generates a "aws/request.Request" representing the // client's request for the ListContainers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -726,7 +726,7 @@ const opPutContainerPolicy = "PutContainerPolicy" // PutContainerPolicyRequest generates a "aws/request.Request" representing the // client's request for the PutContainerPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -818,7 +818,7 @@ const opPutCorsPolicy = "PutCorsPolicy" // PutCorsPolicyRequest generates a "aws/request.Request" representing the // client's request for the PutCorsPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/mediastore/service.go b/vendor/github.com/aws/aws-sdk-go/service/mediastore/service.go index fa36fb91063f..23ce93615c57 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/mediastore/service.go +++ b/vendor/github.com/aws/aws-sdk-go/service/mediastore/service.go @@ -45,14 +45,14 @@ const ( // svc := mediastore.New(mySession, aws.NewConfig().WithRegion("us-west-2")) func New(p client.ConfigProvider, cfgs ...*aws.Config) *MediaStore { c := p.ClientConfig(EndpointsID, cfgs...) + if c.SigningNameDerived || len(c.SigningName) == 0 { + c.SigningName = "mediastore" + } return newClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion, c.SigningName) } // newClient creates, initializes and returns a new service client instance. func newClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion, signingName string) *MediaStore { - if len(signingName) == 0 { - signingName = "mediastore" - } svc := &MediaStore{ Client: client.New( cfg, diff --git a/vendor/github.com/aws/aws-sdk-go/service/mq/api.go b/vendor/github.com/aws/aws-sdk-go/service/mq/api.go index e9f68af095b6..b083caf384df 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/mq/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/mq/api.go @@ -12,7 +12,7 @@ const opCreateBroker = "CreateBroker" // CreateBrokerRequest generates a "aws/request.Request" representing the // client's request for the CreateBroker operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -103,7 +103,7 @@ const opCreateConfiguration = "CreateConfiguration" // CreateConfigurationRequest generates a "aws/request.Request" representing the // client's request for the CreateConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -193,7 +193,7 @@ const opCreateUser = "CreateUser" // CreateUserRequest generates a "aws/request.Request" representing the // client's request for the CreateUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -284,7 +284,7 @@ const opDeleteBroker = "DeleteBroker" // DeleteBrokerRequest generates a "aws/request.Request" representing the // client's request for the DeleteBroker operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -372,7 +372,7 @@ const opDeleteUser = "DeleteUser" // DeleteUserRequest generates a "aws/request.Request" representing the // client's request for the DeleteUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -460,7 +460,7 @@ const opDescribeBroker = "DescribeBroker" // DescribeBrokerRequest generates a "aws/request.Request" representing the // client's request for the DescribeBroker operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -548,7 +548,7 @@ const opDescribeConfiguration = "DescribeConfiguration" // DescribeConfigurationRequest generates a "aws/request.Request" representing the // client's request for the DescribeConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -636,7 +636,7 @@ const opDescribeConfigurationRevision = "DescribeConfigurationRevision" // DescribeConfigurationRevisionRequest generates a "aws/request.Request" representing the // client's request for the DescribeConfigurationRevision operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -724,7 +724,7 @@ const opDescribeUser = "DescribeUser" // DescribeUserRequest generates a "aws/request.Request" representing the // client's request for the DescribeUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -812,7 +812,7 @@ const opListBrokers = "ListBrokers" // ListBrokersRequest generates a "aws/request.Request" representing the // client's request for the ListBrokers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -897,7 +897,7 @@ const opListConfigurationRevisions = "ListConfigurationRevisions" // ListConfigurationRevisionsRequest generates a "aws/request.Request" representing the // client's request for the ListConfigurationRevisions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -985,7 +985,7 @@ const opListConfigurations = "ListConfigurations" // ListConfigurationsRequest generates a "aws/request.Request" representing the // client's request for the ListConfigurations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1070,7 +1070,7 @@ const opListUsers = "ListUsers" // ListUsersRequest generates a "aws/request.Request" representing the // client's request for the ListUsers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1158,7 +1158,7 @@ const opRebootBroker = "RebootBroker" // RebootBrokerRequest generates a "aws/request.Request" representing the // client's request for the RebootBroker operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1246,7 +1246,7 @@ const opUpdateBroker = "UpdateBroker" // UpdateBrokerRequest generates a "aws/request.Request" representing the // client's request for the UpdateBroker operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1334,7 +1334,7 @@ const opUpdateConfiguration = "UpdateConfiguration" // UpdateConfigurationRequest generates a "aws/request.Request" representing the // client's request for the UpdateConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1425,7 +1425,7 @@ const opUpdateUser = "UpdateUser" // UpdateUserRequest generates a "aws/request.Request" representing the // client's request for the UpdateUser operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/mq/service.go b/vendor/github.com/aws/aws-sdk-go/service/mq/service.go index 91b17544c4db..455e3622f1d5 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/mq/service.go +++ b/vendor/github.com/aws/aws-sdk-go/service/mq/service.go @@ -45,14 +45,14 @@ const ( // svc := mq.New(mySession, aws.NewConfig().WithRegion("us-west-2")) func New(p client.ConfigProvider, cfgs ...*aws.Config) *MQ { c := p.ClientConfig(EndpointsID, cfgs...) + if c.SigningNameDerived || len(c.SigningName) == 0 { + c.SigningName = "mq" + } return newClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion, c.SigningName) } // newClient creates, initializes and returns a new service client instance. func newClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion, signingName string) *MQ { - if len(signingName) == 0 { - signingName = "mq" - } svc := &MQ{ Client: client.New( cfg, diff --git a/vendor/github.com/aws/aws-sdk-go/service/opsworks/api.go b/vendor/github.com/aws/aws-sdk-go/service/opsworks/api.go index f266280ef0dd..51065004df15 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/opsworks/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/opsworks/api.go @@ -16,7 +16,7 @@ const opAssignInstance = "AssignInstance" // AssignInstanceRequest generates a "aws/request.Request" representing the // client's request for the AssignInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -112,7 +112,7 @@ const opAssignVolume = "AssignVolume" // AssignVolumeRequest generates a "aws/request.Request" representing the // client's request for the AssignVolume operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -205,7 +205,7 @@ const opAssociateElasticIp = "AssociateElasticIp" // AssociateElasticIpRequest generates a "aws/request.Request" representing the // client's request for the AssociateElasticIp operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -296,7 +296,7 @@ const opAttachElasticLoadBalancer = "AttachElasticLoadBalancer" // AttachElasticLoadBalancerRequest generates a "aws/request.Request" representing the // client's request for the AttachElasticLoadBalancer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -392,7 +392,7 @@ const opCloneStack = "CloneStack" // CloneStackRequest generates a "aws/request.Request" representing the // client's request for the CloneStack operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -480,7 +480,7 @@ const opCreateApp = "CreateApp" // CreateAppRequest generates a "aws/request.Request" representing the // client's request for the CreateApp operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -568,7 +568,7 @@ const opCreateDeployment = "CreateDeployment" // CreateDeploymentRequest generates a "aws/request.Request" representing the // client's request for the CreateDeployment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -657,7 +657,7 @@ const opCreateInstance = "CreateInstance" // CreateInstanceRequest generates a "aws/request.Request" representing the // client's request for the CreateInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -745,7 +745,7 @@ const opCreateLayer = "CreateLayer" // CreateLayerRequest generates a "aws/request.Request" representing the // client's request for the CreateLayer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -839,7 +839,7 @@ const opCreateStack = "CreateStack" // CreateStackRequest generates a "aws/request.Request" representing the // client's request for the CreateStack operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -922,7 +922,7 @@ const opCreateUserProfile = "CreateUserProfile" // CreateUserProfileRequest generates a "aws/request.Request" representing the // client's request for the CreateUserProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1005,7 +1005,7 @@ const opDeleteApp = "DeleteApp" // DeleteAppRequest generates a "aws/request.Request" representing the // client's request for the DeleteApp operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1094,7 +1094,7 @@ const opDeleteInstance = "DeleteInstance" // DeleteInstanceRequest generates a "aws/request.Request" representing the // client's request for the DeleteInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1186,7 +1186,7 @@ const opDeleteLayer = "DeleteLayer" // DeleteLayerRequest generates a "aws/request.Request" representing the // client's request for the DeleteLayer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1277,7 +1277,7 @@ const opDeleteStack = "DeleteStack" // DeleteStackRequest generates a "aws/request.Request" representing the // client's request for the DeleteStack operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1368,7 +1368,7 @@ const opDeleteUserProfile = "DeleteUserProfile" // DeleteUserProfileRequest generates a "aws/request.Request" representing the // client's request for the DeleteUserProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1456,7 +1456,7 @@ const opDeregisterEcsCluster = "DeregisterEcsCluster" // DeregisterEcsClusterRequest generates a "aws/request.Request" representing the // client's request for the DeregisterEcsCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1546,7 +1546,7 @@ const opDeregisterElasticIp = "DeregisterElasticIp" // DeregisterElasticIpRequest generates a "aws/request.Request" representing the // client's request for the DeregisterElasticIp operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1636,7 +1636,7 @@ const opDeregisterInstance = "DeregisterInstance" // DeregisterInstanceRequest generates a "aws/request.Request" representing the // client's request for the DeregisterInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1727,7 +1727,7 @@ const opDeregisterRdsDbInstance = "DeregisterRdsDbInstance" // DeregisterRdsDbInstanceRequest generates a "aws/request.Request" representing the // client's request for the DeregisterRdsDbInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1816,7 +1816,7 @@ const opDeregisterVolume = "DeregisterVolume" // DeregisterVolumeRequest generates a "aws/request.Request" representing the // client's request for the DeregisterVolume operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1906,7 +1906,7 @@ const opDescribeAgentVersions = "DescribeAgentVersions" // DescribeAgentVersionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeAgentVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1990,7 +1990,7 @@ const opDescribeApps = "DescribeApps" // DescribeAppsRequest generates a "aws/request.Request" representing the // client's request for the DescribeApps operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2079,7 +2079,7 @@ const opDescribeCommands = "DescribeCommands" // DescribeCommandsRequest generates a "aws/request.Request" representing the // client's request for the DescribeCommands operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2168,7 +2168,7 @@ const opDescribeDeployments = "DescribeDeployments" // DescribeDeploymentsRequest generates a "aws/request.Request" representing the // client's request for the DescribeDeployments operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2257,7 +2257,7 @@ const opDescribeEcsClusters = "DescribeEcsClusters" // DescribeEcsClustersRequest generates a "aws/request.Request" representing the // client's request for the DescribeEcsClusters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2405,7 +2405,7 @@ const opDescribeElasticIps = "DescribeElasticIps" // DescribeElasticIpsRequest generates a "aws/request.Request" representing the // client's request for the DescribeElasticIps operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2494,7 +2494,7 @@ const opDescribeElasticLoadBalancers = "DescribeElasticLoadBalancers" // DescribeElasticLoadBalancersRequest generates a "aws/request.Request" representing the // client's request for the DescribeElasticLoadBalancers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2583,7 +2583,7 @@ const opDescribeInstances = "DescribeInstances" // DescribeInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2672,7 +2672,7 @@ const opDescribeLayers = "DescribeLayers" // DescribeLayersRequest generates a "aws/request.Request" representing the // client's request for the DescribeLayers operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2761,7 +2761,7 @@ const opDescribeLoadBasedAutoScaling = "DescribeLoadBasedAutoScaling" // DescribeLoadBasedAutoScalingRequest generates a "aws/request.Request" representing the // client's request for the DescribeLoadBasedAutoScaling operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2850,7 +2850,7 @@ const opDescribeMyUserProfile = "DescribeMyUserProfile" // DescribeMyUserProfileRequest generates a "aws/request.Request" representing the // client's request for the DescribeMyUserProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2928,7 +2928,7 @@ const opDescribeOperatingSystems = "DescribeOperatingSystems" // DescribeOperatingSystemsRequest generates a "aws/request.Request" representing the // client's request for the DescribeOperatingSystems operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3002,7 +3002,7 @@ const opDescribePermissions = "DescribePermissions" // DescribePermissionsRequest generates a "aws/request.Request" representing the // client's request for the DescribePermissions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3089,7 +3089,7 @@ const opDescribeRaidArrays = "DescribeRaidArrays" // DescribeRaidArraysRequest generates a "aws/request.Request" representing the // client's request for the DescribeRaidArrays operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3178,7 +3178,7 @@ const opDescribeRdsDbInstances = "DescribeRdsDbInstances" // DescribeRdsDbInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeRdsDbInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3267,7 +3267,7 @@ const opDescribeServiceErrors = "DescribeServiceErrors" // DescribeServiceErrorsRequest generates a "aws/request.Request" representing the // client's request for the DescribeServiceErrors operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3356,7 +3356,7 @@ const opDescribeStackProvisioningParameters = "DescribeStackProvisioningParamete // DescribeStackProvisioningParametersRequest generates a "aws/request.Request" representing the // client's request for the DescribeStackProvisioningParameters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3443,7 +3443,7 @@ const opDescribeStackSummary = "DescribeStackSummary" // DescribeStackSummaryRequest generates a "aws/request.Request" representing the // client's request for the DescribeStackSummary operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3531,7 +3531,7 @@ const opDescribeStacks = "DescribeStacks" // DescribeStacksRequest generates a "aws/request.Request" representing the // client's request for the DescribeStacks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3618,7 +3618,7 @@ const opDescribeTimeBasedAutoScaling = "DescribeTimeBasedAutoScaling" // DescribeTimeBasedAutoScalingRequest generates a "aws/request.Request" representing the // client's request for the DescribeTimeBasedAutoScaling operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3707,7 +3707,7 @@ const opDescribeUserProfiles = "DescribeUserProfiles" // DescribeUserProfilesRequest generates a "aws/request.Request" representing the // client's request for the DescribeUserProfiles operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3793,7 +3793,7 @@ const opDescribeVolumes = "DescribeVolumes" // DescribeVolumesRequest generates a "aws/request.Request" representing the // client's request for the DescribeVolumes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3882,7 +3882,7 @@ const opDetachElasticLoadBalancer = "DetachElasticLoadBalancer" // DetachElasticLoadBalancerRequest generates a "aws/request.Request" representing the // client's request for the DetachElasticLoadBalancer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3968,7 +3968,7 @@ const opDisassociateElasticIp = "DisassociateElasticIp" // DisassociateElasticIpRequest generates a "aws/request.Request" representing the // client's request for the DisassociateElasticIp operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4059,7 +4059,7 @@ const opGetHostnameSuggestion = "GetHostnameSuggestion" // GetHostnameSuggestionRequest generates a "aws/request.Request" representing the // client's request for the GetHostnameSuggestion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4147,7 +4147,7 @@ const opGrantAccess = "GrantAccess" // GrantAccessRequest generates a "aws/request.Request" representing the // client's request for the GrantAccess operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4231,7 +4231,7 @@ const opListTags = "ListTags" // ListTagsRequest generates a "aws/request.Request" representing the // client's request for the ListTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4313,7 +4313,7 @@ const opRebootInstance = "RebootInstance" // RebootInstanceRequest generates a "aws/request.Request" representing the // client's request for the RebootInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4403,7 +4403,7 @@ const opRegisterEcsCluster = "RegisterEcsCluster" // RegisterEcsClusterRequest generates a "aws/request.Request" representing the // client's request for the RegisterEcsCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4492,7 +4492,7 @@ const opRegisterElasticIp = "RegisterElasticIp" // RegisterElasticIpRequest generates a "aws/request.Request" representing the // client's request for the RegisterElasticIp operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4582,7 +4582,7 @@ const opRegisterInstance = "RegisterInstance" // RegisterInstanceRequest generates a "aws/request.Request" representing the // client's request for the RegisterInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4683,7 +4683,7 @@ const opRegisterRdsDbInstance = "RegisterRdsDbInstance" // RegisterRdsDbInstanceRequest generates a "aws/request.Request" representing the // client's request for the RegisterRdsDbInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4772,7 +4772,7 @@ const opRegisterVolume = "RegisterVolume" // RegisterVolumeRequest generates a "aws/request.Request" representing the // client's request for the RegisterVolume operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4862,7 +4862,7 @@ const opSetLoadBasedAutoScaling = "SetLoadBasedAutoScaling" // SetLoadBasedAutoScalingRequest generates a "aws/request.Request" representing the // client's request for the SetLoadBasedAutoScaling operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4958,7 +4958,7 @@ const opSetPermission = "SetPermission" // SetPermissionRequest generates a "aws/request.Request" representing the // client's request for the SetPermission operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5048,7 +5048,7 @@ const opSetTimeBasedAutoScaling = "SetTimeBasedAutoScaling" // SetTimeBasedAutoScalingRequest generates a "aws/request.Request" representing the // client's request for the SetTimeBasedAutoScaling operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5139,7 +5139,7 @@ const opStartInstance = "StartInstance" // StartInstanceRequest generates a "aws/request.Request" representing the // client's request for the StartInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5229,7 +5229,7 @@ const opStartStack = "StartStack" // StartStackRequest generates a "aws/request.Request" representing the // client's request for the StartStack operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5318,7 +5318,7 @@ const opStopInstance = "StopInstance" // StopInstanceRequest generates a "aws/request.Request" representing the // client's request for the StopInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5410,7 +5410,7 @@ const opStopStack = "StopStack" // StopStackRequest generates a "aws/request.Request" representing the // client's request for the StopStack operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5499,7 +5499,7 @@ const opTagResource = "TagResource" // TagResourceRequest generates a "aws/request.Request" representing the // client's request for the TagResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5585,7 +5585,7 @@ const opUnassignInstance = "UnassignInstance" // UnassignInstanceRequest generates a "aws/request.Request" representing the // client's request for the UnassignInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5677,7 +5677,7 @@ const opUnassignVolume = "UnassignVolume" // UnassignVolumeRequest generates a "aws/request.Request" representing the // client's request for the UnassignVolume operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5767,7 +5767,7 @@ const opUntagResource = "UntagResource" // UntagResourceRequest generates a "aws/request.Request" representing the // client's request for the UntagResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5851,7 +5851,7 @@ const opUpdateApp = "UpdateApp" // UpdateAppRequest generates a "aws/request.Request" representing the // client's request for the UpdateApp operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5940,7 +5940,7 @@ const opUpdateElasticIp = "UpdateElasticIp" // UpdateElasticIpRequest generates a "aws/request.Request" representing the // client's request for the UpdateElasticIp operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6030,7 +6030,7 @@ const opUpdateInstance = "UpdateInstance" // UpdateInstanceRequest generates a "aws/request.Request" representing the // client's request for the UpdateInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6119,7 +6119,7 @@ const opUpdateLayer = "UpdateLayer" // UpdateLayerRequest generates a "aws/request.Request" representing the // client's request for the UpdateLayer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6208,7 +6208,7 @@ const opUpdateMyUserProfile = "UpdateMyUserProfile" // UpdateMyUserProfileRequest generates a "aws/request.Request" representing the // client's request for the UpdateMyUserProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6293,7 +6293,7 @@ const opUpdateRdsDbInstance = "UpdateRdsDbInstance" // UpdateRdsDbInstanceRequest generates a "aws/request.Request" representing the // client's request for the UpdateRdsDbInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6382,7 +6382,7 @@ const opUpdateStack = "UpdateStack" // UpdateStackRequest generates a "aws/request.Request" representing the // client's request for the UpdateStack operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6471,7 +6471,7 @@ const opUpdateUserProfile = "UpdateUserProfile" // UpdateUserProfileRequest generates a "aws/request.Request" representing the // client's request for the UpdateUserProfile operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6559,7 +6559,7 @@ const opUpdateVolume = "UpdateVolume" // UpdateVolumeRequest generates a "aws/request.Request" representing the // client's request for the UpdateVolume operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/organizations/api.go b/vendor/github.com/aws/aws-sdk-go/service/organizations/api.go new file mode 100644 index 000000000000..22c5cd91ab8a --- /dev/null +++ b/vendor/github.com/aws/aws-sdk-go/service/organizations/api.go @@ -0,0 +1,14217 @@ +// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. + +package organizations + +import ( + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/awsutil" + "github.com/aws/aws-sdk-go/aws/request" + "github.com/aws/aws-sdk-go/private/protocol" + "github.com/aws/aws-sdk-go/private/protocol/jsonrpc" +) + +const opAcceptHandshake = "AcceptHandshake" + +// AcceptHandshakeRequest generates a "aws/request.Request" representing the +// client's request for the AcceptHandshake operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See AcceptHandshake for more information on using the AcceptHandshake +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the AcceptHandshakeRequest method. +// req, resp := client.AcceptHandshakeRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/AcceptHandshake +func (c *Organizations) AcceptHandshakeRequest(input *AcceptHandshakeInput) (req *request.Request, output *AcceptHandshakeOutput) { + op := &request.Operation{ + Name: opAcceptHandshake, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &AcceptHandshakeInput{} + } + + output = &AcceptHandshakeOutput{} + req = c.newRequest(op, input, output) + return +} + +// AcceptHandshake API operation for AWS Organizations. +// +// Sends a response to the originator of a handshake agreeing to the action +// proposed by the handshake request. +// +// This operation can be called only by the following principals when they also +// have the relevant IAM permissions: +// +// * Invitation to join or Approve all features request handshakes: only +// a principal from the member account. +// +// The user who calls the API for an invitation to join must have the organizations:AcceptHandshake +// permission. If you enabled all features in the organization, then the +// user must also have the iam:CreateServiceLinkedRole permission so that +// Organizations can create the required service-linked role named OrgsServiceLinkedRoleName. +// For more information, see AWS Organizations and Service-Linked Roles (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integration_services.html#orgs_integration_service-linked-roles) +// in the AWS Organizations User Guide. +// +// * Enable all features final confirmation handshake: only a principal from +// the master account. +// +// For more information about invitations, see Inviting an AWS Account to Join +// Your Organization (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_invites.html) +// in the AWS Organizations User Guide. For more information about requests +// to enable all features in the organization, see Enabling All Features +// in Your Organization (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html) +// in the AWS Organizations User Guide. +// +// After you accept a handshake, it continues to appear in the results of relevant +// APIs for only 30 days. After that it is deleted. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation AcceptHandshake for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeHandshakeConstraintViolationException "HandshakeConstraintViolationException" +// The requested operation would violate the constraint identified in the reason +// code. +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on +// the number of accounts in an organization. Note: deleted and closed accounts +// still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * ALREADY_IN_AN_ORGANIZATION: The handshake request is invalid because +// the invited account is already a member of an organization. +// +// * ORGANIZATION_ALREADY_HAS_ALL_FEATURES: The handshake request is invalid +// because the organization has already enabled all features. +// +// * INVITE_DISABLED_DURING_ENABLE_ALL_FEATURES: You cannot issue new invitations +// to join an organization while it is in the process of enabling all features. +// You can resume inviting accounts after you finalize the process when all +// accounts have agreed to the change. +// +// * PAYMENT_INSTRUMENT_REQUIRED: You cannot complete the operation with +// an account that does not have a payment instrument, such as a credit card, +// associated with it. +// +// * ORGANIZATION_FROM_DIFFERENT_SELLER_OF_RECORD: The request failed because +// the account is from a different marketplace than the accounts in the organization. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be from the same +// marketplace. +// +// * ORGANIZATION_MEMBERSHIP_CHANGE_RATE_LIMIT_EXCEEDED: You attempted to +// change the membership of an account too quickly after its previous change. +// +// * ErrCodeHandshakeNotFoundException "HandshakeNotFoundException" +// We can't find a handshake with the HandshakeId that you specified. +// +// * ErrCodeInvalidHandshakeTransitionException "InvalidHandshakeTransitionException" +// You can't perform the operation on the handshake in its current state. For +// example, you can't cancel a handshake that was already accepted, or accept +// a handshake that was already declined. +// +// * ErrCodeHandshakeAlreadyInStateException "HandshakeAlreadyInStateException" +// The specified handshake is already in the requested state. For example, you +// can't accept a handshake that was already accepted. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// * ErrCodeAccessDeniedForDependencyException "AccessDeniedForDependencyException" +// The operation you attempted requires you to have the iam:CreateServiceLinkedRole +// so that Organizations can create the required service-linked role. You do +// not have that permission. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/AcceptHandshake +func (c *Organizations) AcceptHandshake(input *AcceptHandshakeInput) (*AcceptHandshakeOutput, error) { + req, out := c.AcceptHandshakeRequest(input) + return out, req.Send() +} + +// AcceptHandshakeWithContext is the same as AcceptHandshake with the addition of +// the ability to pass a context and additional request options. +// +// See AcceptHandshake for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) AcceptHandshakeWithContext(ctx aws.Context, input *AcceptHandshakeInput, opts ...request.Option) (*AcceptHandshakeOutput, error) { + req, out := c.AcceptHandshakeRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opAttachPolicy = "AttachPolicy" + +// AttachPolicyRequest generates a "aws/request.Request" representing the +// client's request for the AttachPolicy operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See AttachPolicy for more information on using the AttachPolicy +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the AttachPolicyRequest method. +// req, resp := client.AttachPolicyRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/AttachPolicy +func (c *Organizations) AttachPolicyRequest(input *AttachPolicyInput) (req *request.Request, output *AttachPolicyOutput) { + op := &request.Operation{ + Name: opAttachPolicy, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &AttachPolicyInput{} + } + + output = &AttachPolicyOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// AttachPolicy API operation for AWS Organizations. +// +// Attaches a policy to a root, an organizational unit, or an individual account. +// How the policy affects accounts depends on the type of policy: +// +// * Service control policy (SCP) - An SCP specifies what permissions can +// be delegated to users in affected member accounts. The scope of influence +// for a policy depends on what you attach the policy to: +// +// If you attach an SCP to a root, it affects all accounts in the organization. +// +// If you attach an SCP to an OU, it affects all accounts in that OU and in +// any child OUs. +// +// If you attach the policy directly to an account, then it affects only that +// account. +// +// SCPs essentially are permission "filters". When you attach one SCP to a higher +// level root or OU, and you also attach a different SCP to a child OU or +// to an account, the child policy can further restrict only the permissions +// that pass through the parent filter and are available to the child. An +// SCP that is attached to a child cannot grant a permission that is not +// already granted by the parent. For example, imagine that the parent SCP +// allows permissions A, B, C, D, and E. The child SCP allows C, D, E, F, +// and G. The result is that the accounts affected by the child SCP are allowed +// to use only C, D, and E. They cannot use A or B because they were filtered +// out by the child OU. They also cannot use F and G because they were filtered +// out by the parent OU. They cannot be granted back by the child SCP; child +// SCPs can only filter the permissions they receive from the parent SCP. +// +// AWS Organizations attaches a default SCP named "FullAWSAccess to every root, +// OU, and account. This default SCP allows all services and actions, enabling +// any new child OU or account to inherit the permissions of the parent root +// or OU. If you detach the default policy, you must replace it with a policy +// that specifies the permissions that you want to allow in that OU or account. +// +// For more information about how Organizations policies permissions work, see +// Using Service Control Policies (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_scp.html) +// in the AWS Organizations User Guide. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation AttachPolicy for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeConstraintViolationException "ConstraintViolationException" +// Performing this operation violates a minimum or maximum value limit. For +// example, attempting to removing the last SCP from an OU or root, inviting +// or creating too many accounts to the organization, or attaching too many +// policies to an account, OU, or root. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on the number +// of accounts in an organization. If you need more accounts, contact AWS Support +// to request an increase in your limit. +// +// Or, The number of invitations that you tried to send would cause you to exceed +// the limit of accounts in your organization. Send fewer invitations, or contact +// AWS Support to request an increase in the number of accounts. +// +// Note: deleted and closed accounts still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * OU_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the number of organizational +// units you can have in an organization. +// +// * OU_DEPTH_LIMIT_EXCEEDED: You attempted to create an organizational unit +// tree that is too many levels deep. +// +// * POLICY_NUMBER_LIMIT_EXCEEDED. You attempted to exceed the number of +// policies that you can have in an organization. +// +// * MAX_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to exceed the +// number of policies of a certain type that can be attached to an entity +// at one time. +// +// * MIN_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to detach a +// policy from an entity that would cause the entity to have fewer than the +// minimum number of policies of a certain type required. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_EULA: You attempted to remove an account +// from the organization that does not yet have enough information to exist +// as a stand-alone account. This account requires you to first agree to +// the AWS Customer Agreement. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_PHONE_VERIFICATION: You attempted to remove +// an account from the organization that does not yet have enough information +// to exist as a stand-alone account. This account requires you to first +// complete phone verification. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MASTER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To create an organization +// with this account, you first must associate a payment instrument, such +// as a credit card, with the account. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MEMBER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To complete this operation +// with this member account, you first must associate a payment instrument, +// such as a credit card, with the account. Follow the steps at To leave +// an organization when all required account information has not yet been +// provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CREATION_RATE_LIMIT_EXCEEDED: You attempted to exceed the number +// of accounts that you can create in one day. +// +// * MASTER_ACCOUNT_ADDRESS_DOES_NOT_MATCH_MARKETPLACE: To create an account +// in this organization, you first must migrate the organization's master +// account to the marketplace that corresponds to the master account's address. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be associated +// with the same marketplace. +// +// * MASTER_ACCOUNT_MISSING_CONTACT_INFO: To complete this operation, you +// must first provide contact a valid address and phone number for the master +// account. Then try the operation again. +// +// * ErrCodeDuplicatePolicyAttachmentException "DuplicatePolicyAttachmentException" +// The selected policy is already attached to the specified target. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodePolicyNotFoundException "PolicyNotFoundException" +// We can't find a policy with the PolicyId that you specified. +// +// * ErrCodePolicyTypeNotEnabledException "PolicyTypeNotEnabledException" +// The specified policy type is not currently enabled in this root. You cannot +// attach policies of the specified type to entities in a root until you enable +// that type in the root. For more information, see Enabling All Features in +// Your Organization (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html) +// in the AWS Organizations User Guide. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTargetNotFoundException "TargetNotFoundException" +// We can't find a root, OU, or account with the TargetId that you specified. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/AttachPolicy +func (c *Organizations) AttachPolicy(input *AttachPolicyInput) (*AttachPolicyOutput, error) { + req, out := c.AttachPolicyRequest(input) + return out, req.Send() +} + +// AttachPolicyWithContext is the same as AttachPolicy with the addition of +// the ability to pass a context and additional request options. +// +// See AttachPolicy for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) AttachPolicyWithContext(ctx aws.Context, input *AttachPolicyInput, opts ...request.Option) (*AttachPolicyOutput, error) { + req, out := c.AttachPolicyRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opCancelHandshake = "CancelHandshake" + +// CancelHandshakeRequest generates a "aws/request.Request" representing the +// client's request for the CancelHandshake operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See CancelHandshake for more information on using the CancelHandshake +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the CancelHandshakeRequest method. +// req, resp := client.CancelHandshakeRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/CancelHandshake +func (c *Organizations) CancelHandshakeRequest(input *CancelHandshakeInput) (req *request.Request, output *CancelHandshakeOutput) { + op := &request.Operation{ + Name: opCancelHandshake, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &CancelHandshakeInput{} + } + + output = &CancelHandshakeOutput{} + req = c.newRequest(op, input, output) + return +} + +// CancelHandshake API operation for AWS Organizations. +// +// Cancels a handshake. Canceling a handshake sets the handshake state to CANCELED. +// +// This operation can be called only from the account that originated the handshake. +// The recipient of the handshake can't cancel it, but can use DeclineHandshake +// instead. After a handshake is canceled, the recipient can no longer respond +// to that handshake. +// +// After you cancel a handshake, it continues to appear in the results of relevant +// APIs for only 30 days. After that it is deleted. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation CancelHandshake for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeHandshakeNotFoundException "HandshakeNotFoundException" +// We can't find a handshake with the HandshakeId that you specified. +// +// * ErrCodeInvalidHandshakeTransitionException "InvalidHandshakeTransitionException" +// You can't perform the operation on the handshake in its current state. For +// example, you can't cancel a handshake that was already accepted, or accept +// a handshake that was already declined. +// +// * ErrCodeHandshakeAlreadyInStateException "HandshakeAlreadyInStateException" +// The specified handshake is already in the requested state. For example, you +// can't accept a handshake that was already accepted. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/CancelHandshake +func (c *Organizations) CancelHandshake(input *CancelHandshakeInput) (*CancelHandshakeOutput, error) { + req, out := c.CancelHandshakeRequest(input) + return out, req.Send() +} + +// CancelHandshakeWithContext is the same as CancelHandshake with the addition of +// the ability to pass a context and additional request options. +// +// See CancelHandshake for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) CancelHandshakeWithContext(ctx aws.Context, input *CancelHandshakeInput, opts ...request.Option) (*CancelHandshakeOutput, error) { + req, out := c.CancelHandshakeRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opCreateAccount = "CreateAccount" + +// CreateAccountRequest generates a "aws/request.Request" representing the +// client's request for the CreateAccount operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See CreateAccount for more information on using the CreateAccount +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the CreateAccountRequest method. +// req, resp := client.CreateAccountRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/CreateAccount +func (c *Organizations) CreateAccountRequest(input *CreateAccountInput) (req *request.Request, output *CreateAccountOutput) { + op := &request.Operation{ + Name: opCreateAccount, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &CreateAccountInput{} + } + + output = &CreateAccountOutput{} + req = c.newRequest(op, input, output) + return +} + +// CreateAccount API operation for AWS Organizations. +// +// Creates an AWS account that is automatically a member of the organization +// whose credentials made the request. This is an asynchronous request that +// AWS performs in the background. If you want to check the status of the request +// later, you need the OperationId response element from this operation to provide +// as a parameter to the DescribeCreateAccountStatus operation. +// +// The user who calls the API for an invitation to join must have the organizations:CreateAccount +// permission. If you enabled all features in the organization, then the user +// must also have the iam:CreateServiceLinkedRole permission so that Organizations +// can create the required service-linked role named OrgsServiceLinkedRoleName. +// For more information, see AWS Organizations and Service-Linked Roles (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integration_services.html#orgs_integration_service-linked-roles) +// in the AWS Organizations User Guide. +// +// The user in the master account who calls this API must also have the iam:CreateRole +// permission because AWS Organizations preconfigures the new member account +// with a role (named OrganizationAccountAccessRole by default) that grants +// users in the master account administrator permissions in the new member account. +// Principals in the master account can assume the role. AWS Organizations clones +// the company name and address information for the new account from the organization's +// master account. +// +// This operation can be called only from the organization's master account. +// +// For more information about creating accounts, see Creating an AWS Account +// in Your Organization (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_create.html) +// in the AWS Organizations User Guide. +// +// When you create an account in an organization using the AWS Organizations +// console, API, or CLI commands, the information required for the account to +// operate as a standalone account, such as a payment method and signing the +// End User Licence Agreement (EULA) is not automatically collected. If you +// must remove an account from your organization later, you can do so only after +// you provide the missing information. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// When you create a member account with this operation, you can choose whether +// to create the account with the IAM User and Role Access to Billing Information +// switch enabled. If you enable it, IAM users and roles that have appropriate +// permissions can view billing information for the account. If you disable +// this, then only the account root user can access billing information. For +// information about how to disable this for an account, see Granting Access +// to Your Billing Information and Tools (http://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/grantaccess.html). +// +// This operation can be called only from the organization's master account. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation CreateAccount for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeConstraintViolationException "ConstraintViolationException" +// Performing this operation violates a minimum or maximum value limit. For +// example, attempting to removing the last SCP from an OU or root, inviting +// or creating too many accounts to the organization, or attaching too many +// policies to an account, OU, or root. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on the number +// of accounts in an organization. If you need more accounts, contact AWS Support +// to request an increase in your limit. +// +// Or, The number of invitations that you tried to send would cause you to exceed +// the limit of accounts in your organization. Send fewer invitations, or contact +// AWS Support to request an increase in the number of accounts. +// +// Note: deleted and closed accounts still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * OU_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the number of organizational +// units you can have in an organization. +// +// * OU_DEPTH_LIMIT_EXCEEDED: You attempted to create an organizational unit +// tree that is too many levels deep. +// +// * POLICY_NUMBER_LIMIT_EXCEEDED. You attempted to exceed the number of +// policies that you can have in an organization. +// +// * MAX_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to exceed the +// number of policies of a certain type that can be attached to an entity +// at one time. +// +// * MIN_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to detach a +// policy from an entity that would cause the entity to have fewer than the +// minimum number of policies of a certain type required. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_EULA: You attempted to remove an account +// from the organization that does not yet have enough information to exist +// as a stand-alone account. This account requires you to first agree to +// the AWS Customer Agreement. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_PHONE_VERIFICATION: You attempted to remove +// an account from the organization that does not yet have enough information +// to exist as a stand-alone account. This account requires you to first +// complete phone verification. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MASTER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To create an organization +// with this account, you first must associate a payment instrument, such +// as a credit card, with the account. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MEMBER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To complete this operation +// with this member account, you first must associate a payment instrument, +// such as a credit card, with the account. Follow the steps at To leave +// an organization when all required account information has not yet been +// provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CREATION_RATE_LIMIT_EXCEEDED: You attempted to exceed the number +// of accounts that you can create in one day. +// +// * MASTER_ACCOUNT_ADDRESS_DOES_NOT_MATCH_MARKETPLACE: To create an account +// in this organization, you first must migrate the organization's master +// account to the marketplace that corresponds to the master account's address. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be associated +// with the same marketplace. +// +// * MASTER_ACCOUNT_MISSING_CONTACT_INFO: To complete this operation, you +// must first provide contact a valid address and phone number for the master +// account. Then try the operation again. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeFinalizingOrganizationException "FinalizingOrganizationException" +// AWS Organizations could not finalize the creation of your organization. Try +// again later. If this persists, contact AWS customer support. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/CreateAccount +func (c *Organizations) CreateAccount(input *CreateAccountInput) (*CreateAccountOutput, error) { + req, out := c.CreateAccountRequest(input) + return out, req.Send() +} + +// CreateAccountWithContext is the same as CreateAccount with the addition of +// the ability to pass a context and additional request options. +// +// See CreateAccount for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) CreateAccountWithContext(ctx aws.Context, input *CreateAccountInput, opts ...request.Option) (*CreateAccountOutput, error) { + req, out := c.CreateAccountRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opCreateOrganization = "CreateOrganization" + +// CreateOrganizationRequest generates a "aws/request.Request" representing the +// client's request for the CreateOrganization operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See CreateOrganization for more information on using the CreateOrganization +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the CreateOrganizationRequest method. +// req, resp := client.CreateOrganizationRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/CreateOrganization +func (c *Organizations) CreateOrganizationRequest(input *CreateOrganizationInput) (req *request.Request, output *CreateOrganizationOutput) { + op := &request.Operation{ + Name: opCreateOrganization, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &CreateOrganizationInput{} + } + + output = &CreateOrganizationOutput{} + req = c.newRequest(op, input, output) + return +} + +// CreateOrganization API operation for AWS Organizations. +// +// Creates an AWS organization. The account whose user is calling the CreateOrganization +// operation automatically becomes the master account (http://docs.aws.amazon.com/IAM/latest/UserGuide/orgs_getting-started_concepts.html#account) +// of the new organization. +// +// This operation must be called using credentials from the account that is +// to become the new organization's master account. The principal must also +// have the relevant IAM permissions. +// +// By default (or if you set the FeatureSet parameter to ALL), the new organization +// is created with all features enabled and service control policies automatically +// enabled in the root. If you instead choose to create the organization supporting +// only the consolidated billing features by setting the FeatureSet parameter +// to CONSOLIDATED_BILLING", then no policy types are enabled by default and +// you cannot use organization policies. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation CreateOrganization for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAlreadyInOrganizationException "AlreadyInOrganizationException" +// This account is already a member of an organization. An account can belong +// to only one organization at a time. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeConstraintViolationException "ConstraintViolationException" +// Performing this operation violates a minimum or maximum value limit. For +// example, attempting to removing the last SCP from an OU or root, inviting +// or creating too many accounts to the organization, or attaching too many +// policies to an account, OU, or root. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on the number +// of accounts in an organization. If you need more accounts, contact AWS Support +// to request an increase in your limit. +// +// Or, The number of invitations that you tried to send would cause you to exceed +// the limit of accounts in your organization. Send fewer invitations, or contact +// AWS Support to request an increase in the number of accounts. +// +// Note: deleted and closed accounts still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * OU_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the number of organizational +// units you can have in an organization. +// +// * OU_DEPTH_LIMIT_EXCEEDED: You attempted to create an organizational unit +// tree that is too many levels deep. +// +// * POLICY_NUMBER_LIMIT_EXCEEDED. You attempted to exceed the number of +// policies that you can have in an organization. +// +// * MAX_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to exceed the +// number of policies of a certain type that can be attached to an entity +// at one time. +// +// * MIN_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to detach a +// policy from an entity that would cause the entity to have fewer than the +// minimum number of policies of a certain type required. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_EULA: You attempted to remove an account +// from the organization that does not yet have enough information to exist +// as a stand-alone account. This account requires you to first agree to +// the AWS Customer Agreement. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_PHONE_VERIFICATION: You attempted to remove +// an account from the organization that does not yet have enough information +// to exist as a stand-alone account. This account requires you to first +// complete phone verification. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MASTER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To create an organization +// with this account, you first must associate a payment instrument, such +// as a credit card, with the account. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MEMBER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To complete this operation +// with this member account, you first must associate a payment instrument, +// such as a credit card, with the account. Follow the steps at To leave +// an organization when all required account information has not yet been +// provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CREATION_RATE_LIMIT_EXCEEDED: You attempted to exceed the number +// of accounts that you can create in one day. +// +// * MASTER_ACCOUNT_ADDRESS_DOES_NOT_MATCH_MARKETPLACE: To create an account +// in this organization, you first must migrate the organization's master +// account to the marketplace that corresponds to the master account's address. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be associated +// with the same marketplace. +// +// * MASTER_ACCOUNT_MISSING_CONTACT_INFO: To complete this operation, you +// must first provide contact a valid address and phone number for the master +// account. Then try the operation again. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// * ErrCodeAccessDeniedForDependencyException "AccessDeniedForDependencyException" +// The operation you attempted requires you to have the iam:CreateServiceLinkedRole +// so that Organizations can create the required service-linked role. You do +// not have that permission. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/CreateOrganization +func (c *Organizations) CreateOrganization(input *CreateOrganizationInput) (*CreateOrganizationOutput, error) { + req, out := c.CreateOrganizationRequest(input) + return out, req.Send() +} + +// CreateOrganizationWithContext is the same as CreateOrganization with the addition of +// the ability to pass a context and additional request options. +// +// See CreateOrganization for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) CreateOrganizationWithContext(ctx aws.Context, input *CreateOrganizationInput, opts ...request.Option) (*CreateOrganizationOutput, error) { + req, out := c.CreateOrganizationRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opCreateOrganizationalUnit = "CreateOrganizationalUnit" + +// CreateOrganizationalUnitRequest generates a "aws/request.Request" representing the +// client's request for the CreateOrganizationalUnit operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See CreateOrganizationalUnit for more information on using the CreateOrganizationalUnit +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the CreateOrganizationalUnitRequest method. +// req, resp := client.CreateOrganizationalUnitRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/CreateOrganizationalUnit +func (c *Organizations) CreateOrganizationalUnitRequest(input *CreateOrganizationalUnitInput) (req *request.Request, output *CreateOrganizationalUnitOutput) { + op := &request.Operation{ + Name: opCreateOrganizationalUnit, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &CreateOrganizationalUnitInput{} + } + + output = &CreateOrganizationalUnitOutput{} + req = c.newRequest(op, input, output) + return +} + +// CreateOrganizationalUnit API operation for AWS Organizations. +// +// Creates an organizational unit (OU) within a root or parent OU. An OU is +// a container for accounts that enables you to organize your accounts to apply +// policies according to your business requirements. The number of levels deep +// that you can nest OUs is dependent upon the policy types enabled for that +// root. For service control policies, the limit is five. +// +// For more information about OUs, see Managing Organizational Units (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_ous.html) +// in the AWS Organizations User Guide. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation CreateOrganizationalUnit for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeConstraintViolationException "ConstraintViolationException" +// Performing this operation violates a minimum or maximum value limit. For +// example, attempting to removing the last SCP from an OU or root, inviting +// or creating too many accounts to the organization, or attaching too many +// policies to an account, OU, or root. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on the number +// of accounts in an organization. If you need more accounts, contact AWS Support +// to request an increase in your limit. +// +// Or, The number of invitations that you tried to send would cause you to exceed +// the limit of accounts in your organization. Send fewer invitations, or contact +// AWS Support to request an increase in the number of accounts. +// +// Note: deleted and closed accounts still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * OU_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the number of organizational +// units you can have in an organization. +// +// * OU_DEPTH_LIMIT_EXCEEDED: You attempted to create an organizational unit +// tree that is too many levels deep. +// +// * POLICY_NUMBER_LIMIT_EXCEEDED. You attempted to exceed the number of +// policies that you can have in an organization. +// +// * MAX_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to exceed the +// number of policies of a certain type that can be attached to an entity +// at one time. +// +// * MIN_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to detach a +// policy from an entity that would cause the entity to have fewer than the +// minimum number of policies of a certain type required. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_EULA: You attempted to remove an account +// from the organization that does not yet have enough information to exist +// as a stand-alone account. This account requires you to first agree to +// the AWS Customer Agreement. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_PHONE_VERIFICATION: You attempted to remove +// an account from the organization that does not yet have enough information +// to exist as a stand-alone account. This account requires you to first +// complete phone verification. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MASTER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To create an organization +// with this account, you first must associate a payment instrument, such +// as a credit card, with the account. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MEMBER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To complete this operation +// with this member account, you first must associate a payment instrument, +// such as a credit card, with the account. Follow the steps at To leave +// an organization when all required account information has not yet been +// provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CREATION_RATE_LIMIT_EXCEEDED: You attempted to exceed the number +// of accounts that you can create in one day. +// +// * MASTER_ACCOUNT_ADDRESS_DOES_NOT_MATCH_MARKETPLACE: To create an account +// in this organization, you first must migrate the organization's master +// account to the marketplace that corresponds to the master account's address. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be associated +// with the same marketplace. +// +// * MASTER_ACCOUNT_MISSING_CONTACT_INFO: To complete this operation, you +// must first provide contact a valid address and phone number for the master +// account. Then try the operation again. +// +// * ErrCodeDuplicateOrganizationalUnitException "DuplicateOrganizationalUnitException" +// An organizational unit (OU) with the same name already exists. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeParentNotFoundException "ParentNotFoundException" +// We can't find a root or organizational unit (OU) with the ParentId that you +// specified. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/CreateOrganizationalUnit +func (c *Organizations) CreateOrganizationalUnit(input *CreateOrganizationalUnitInput) (*CreateOrganizationalUnitOutput, error) { + req, out := c.CreateOrganizationalUnitRequest(input) + return out, req.Send() +} + +// CreateOrganizationalUnitWithContext is the same as CreateOrganizationalUnit with the addition of +// the ability to pass a context and additional request options. +// +// See CreateOrganizationalUnit for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) CreateOrganizationalUnitWithContext(ctx aws.Context, input *CreateOrganizationalUnitInput, opts ...request.Option) (*CreateOrganizationalUnitOutput, error) { + req, out := c.CreateOrganizationalUnitRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opCreatePolicy = "CreatePolicy" + +// CreatePolicyRequest generates a "aws/request.Request" representing the +// client's request for the CreatePolicy operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See CreatePolicy for more information on using the CreatePolicy +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the CreatePolicyRequest method. +// req, resp := client.CreatePolicyRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/CreatePolicy +func (c *Organizations) CreatePolicyRequest(input *CreatePolicyInput) (req *request.Request, output *CreatePolicyOutput) { + op := &request.Operation{ + Name: opCreatePolicy, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &CreatePolicyInput{} + } + + output = &CreatePolicyOutput{} + req = c.newRequest(op, input, output) + return +} + +// CreatePolicy API operation for AWS Organizations. +// +// Creates a policy of a specified type that you can attach to a root, an organizational +// unit (OU), or an individual AWS account. +// +// For more information about policies and their use, see Managing Organization +// Policies (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies.html). +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation CreatePolicy for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeConstraintViolationException "ConstraintViolationException" +// Performing this operation violates a minimum or maximum value limit. For +// example, attempting to removing the last SCP from an OU or root, inviting +// or creating too many accounts to the organization, or attaching too many +// policies to an account, OU, or root. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on the number +// of accounts in an organization. If you need more accounts, contact AWS Support +// to request an increase in your limit. +// +// Or, The number of invitations that you tried to send would cause you to exceed +// the limit of accounts in your organization. Send fewer invitations, or contact +// AWS Support to request an increase in the number of accounts. +// +// Note: deleted and closed accounts still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * OU_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the number of organizational +// units you can have in an organization. +// +// * OU_DEPTH_LIMIT_EXCEEDED: You attempted to create an organizational unit +// tree that is too many levels deep. +// +// * POLICY_NUMBER_LIMIT_EXCEEDED. You attempted to exceed the number of +// policies that you can have in an organization. +// +// * MAX_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to exceed the +// number of policies of a certain type that can be attached to an entity +// at one time. +// +// * MIN_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to detach a +// policy from an entity that would cause the entity to have fewer than the +// minimum number of policies of a certain type required. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_EULA: You attempted to remove an account +// from the organization that does not yet have enough information to exist +// as a stand-alone account. This account requires you to first agree to +// the AWS Customer Agreement. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_PHONE_VERIFICATION: You attempted to remove +// an account from the organization that does not yet have enough information +// to exist as a stand-alone account. This account requires you to first +// complete phone verification. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MASTER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To create an organization +// with this account, you first must associate a payment instrument, such +// as a credit card, with the account. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MEMBER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To complete this operation +// with this member account, you first must associate a payment instrument, +// such as a credit card, with the account. Follow the steps at To leave +// an organization when all required account information has not yet been +// provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CREATION_RATE_LIMIT_EXCEEDED: You attempted to exceed the number +// of accounts that you can create in one day. +// +// * MASTER_ACCOUNT_ADDRESS_DOES_NOT_MATCH_MARKETPLACE: To create an account +// in this organization, you first must migrate the organization's master +// account to the marketplace that corresponds to the master account's address. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be associated +// with the same marketplace. +// +// * MASTER_ACCOUNT_MISSING_CONTACT_INFO: To complete this operation, you +// must first provide contact a valid address and phone number for the master +// account. Then try the operation again. +// +// * ErrCodeDuplicatePolicyException "DuplicatePolicyException" +// A policy with the same name already exists. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeMalformedPolicyDocumentException "MalformedPolicyDocumentException" +// The provided policy document does not meet the requirements of the specified +// policy type. For example, the syntax might be incorrect. For details about +// service control policy syntax, see Service Control Policy Syntax (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_scp-syntax.html) +// in the AWS Organizations User Guide. +// +// * ErrCodePolicyTypeNotAvailableForOrganizationException "PolicyTypeNotAvailableForOrganizationException" +// You can't use the specified policy type with the feature set currently enabled +// for this organization. For example, you can enable service control policies +// (SCPs) only after you enable all features in the organization. For more information, +// see Enabling and Disabling a Policy Type on a Root (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies.html#enable_policies_on_root) +// in the AWS Organizations User Guide. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/CreatePolicy +func (c *Organizations) CreatePolicy(input *CreatePolicyInput) (*CreatePolicyOutput, error) { + req, out := c.CreatePolicyRequest(input) + return out, req.Send() +} + +// CreatePolicyWithContext is the same as CreatePolicy with the addition of +// the ability to pass a context and additional request options. +// +// See CreatePolicy for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) CreatePolicyWithContext(ctx aws.Context, input *CreatePolicyInput, opts ...request.Option) (*CreatePolicyOutput, error) { + req, out := c.CreatePolicyRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeclineHandshake = "DeclineHandshake" + +// DeclineHandshakeRequest generates a "aws/request.Request" representing the +// client's request for the DeclineHandshake operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeclineHandshake for more information on using the DeclineHandshake +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeclineHandshakeRequest method. +// req, resp := client.DeclineHandshakeRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DeclineHandshake +func (c *Organizations) DeclineHandshakeRequest(input *DeclineHandshakeInput) (req *request.Request, output *DeclineHandshakeOutput) { + op := &request.Operation{ + Name: opDeclineHandshake, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DeclineHandshakeInput{} + } + + output = &DeclineHandshakeOutput{} + req = c.newRequest(op, input, output) + return +} + +// DeclineHandshake API operation for AWS Organizations. +// +// Declines a handshake request. This sets the handshake state to DECLINED and +// effectively deactivates the request. +// +// This operation can be called only from the account that received the handshake. +// The originator of the handshake can use CancelHandshake instead. The originator +// can't reactivate a declined request, but can re-initiate the process with +// a new handshake request. +// +// After you decline a handshake, it continues to appear in the results of relevant +// APIs for only 30 days. After that it is deleted. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation DeclineHandshake for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeHandshakeNotFoundException "HandshakeNotFoundException" +// We can't find a handshake with the HandshakeId that you specified. +// +// * ErrCodeInvalidHandshakeTransitionException "InvalidHandshakeTransitionException" +// You can't perform the operation on the handshake in its current state. For +// example, you can't cancel a handshake that was already accepted, or accept +// a handshake that was already declined. +// +// * ErrCodeHandshakeAlreadyInStateException "HandshakeAlreadyInStateException" +// The specified handshake is already in the requested state. For example, you +// can't accept a handshake that was already accepted. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DeclineHandshake +func (c *Organizations) DeclineHandshake(input *DeclineHandshakeInput) (*DeclineHandshakeOutput, error) { + req, out := c.DeclineHandshakeRequest(input) + return out, req.Send() +} + +// DeclineHandshakeWithContext is the same as DeclineHandshake with the addition of +// the ability to pass a context and additional request options. +// +// See DeclineHandshake for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) DeclineHandshakeWithContext(ctx aws.Context, input *DeclineHandshakeInput, opts ...request.Option) (*DeclineHandshakeOutput, error) { + req, out := c.DeclineHandshakeRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeleteOrganization = "DeleteOrganization" + +// DeleteOrganizationRequest generates a "aws/request.Request" representing the +// client's request for the DeleteOrganization operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteOrganization for more information on using the DeleteOrganization +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteOrganizationRequest method. +// req, resp := client.DeleteOrganizationRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DeleteOrganization +func (c *Organizations) DeleteOrganizationRequest(input *DeleteOrganizationInput) (req *request.Request, output *DeleteOrganizationOutput) { + op := &request.Operation{ + Name: opDeleteOrganization, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DeleteOrganizationInput{} + } + + output = &DeleteOrganizationOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeleteOrganization API operation for AWS Organizations. +// +// Deletes the organization. You can delete an organization only by using credentials +// from the master account. The organization must be empty of member accounts, +// OUs, and policies. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation DeleteOrganization for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeOrganizationNotEmptyException "OrganizationNotEmptyException" +// The organization isn't empty. To delete an organization, you must first remove +// all accounts except the master account, delete all organizational units (OUs), +// and delete all policies. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DeleteOrganization +func (c *Organizations) DeleteOrganization(input *DeleteOrganizationInput) (*DeleteOrganizationOutput, error) { + req, out := c.DeleteOrganizationRequest(input) + return out, req.Send() +} + +// DeleteOrganizationWithContext is the same as DeleteOrganization with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteOrganization for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) DeleteOrganizationWithContext(ctx aws.Context, input *DeleteOrganizationInput, opts ...request.Option) (*DeleteOrganizationOutput, error) { + req, out := c.DeleteOrganizationRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeleteOrganizationalUnit = "DeleteOrganizationalUnit" + +// DeleteOrganizationalUnitRequest generates a "aws/request.Request" representing the +// client's request for the DeleteOrganizationalUnit operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteOrganizationalUnit for more information on using the DeleteOrganizationalUnit +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteOrganizationalUnitRequest method. +// req, resp := client.DeleteOrganizationalUnitRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DeleteOrganizationalUnit +func (c *Organizations) DeleteOrganizationalUnitRequest(input *DeleteOrganizationalUnitInput) (req *request.Request, output *DeleteOrganizationalUnitOutput) { + op := &request.Operation{ + Name: opDeleteOrganizationalUnit, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DeleteOrganizationalUnitInput{} + } + + output = &DeleteOrganizationalUnitOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeleteOrganizationalUnit API operation for AWS Organizations. +// +// Deletes an organizational unit from a root or another OU. You must first +// remove all accounts and child OUs from the OU that you want to delete. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation DeleteOrganizationalUnit for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeOrganizationalUnitNotEmptyException "OrganizationalUnitNotEmptyException" +// The specified organizational unit (OU) is not empty. Move all accounts to +// another root or to other OUs, remove all child OUs, and then try the operation +// again. +// +// * ErrCodeOrganizationalUnitNotFoundException "OrganizationalUnitNotFoundException" +// We can't find an organizational unit (OU) with the OrganizationalUnitId that +// you specified. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DeleteOrganizationalUnit +func (c *Organizations) DeleteOrganizationalUnit(input *DeleteOrganizationalUnitInput) (*DeleteOrganizationalUnitOutput, error) { + req, out := c.DeleteOrganizationalUnitRequest(input) + return out, req.Send() +} + +// DeleteOrganizationalUnitWithContext is the same as DeleteOrganizationalUnit with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteOrganizationalUnit for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) DeleteOrganizationalUnitWithContext(ctx aws.Context, input *DeleteOrganizationalUnitInput, opts ...request.Option) (*DeleteOrganizationalUnitOutput, error) { + req, out := c.DeleteOrganizationalUnitRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDeletePolicy = "DeletePolicy" + +// DeletePolicyRequest generates a "aws/request.Request" representing the +// client's request for the DeletePolicy operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeletePolicy for more information on using the DeletePolicy +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeletePolicyRequest method. +// req, resp := client.DeletePolicyRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DeletePolicy +func (c *Organizations) DeletePolicyRequest(input *DeletePolicyInput) (req *request.Request, output *DeletePolicyOutput) { + op := &request.Operation{ + Name: opDeletePolicy, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DeletePolicyInput{} + } + + output = &DeletePolicyOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DeletePolicy API operation for AWS Organizations. +// +// Deletes the specified policy from your organization. Before you perform this +// operation, you must first detach the policy from all OUs, roots, and accounts. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation DeletePolicy for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodePolicyInUseException "PolicyInUseException" +// The policy is attached to one or more entities. You must detach it from all +// roots, organizational units (OUs), and accounts before performing this operation. +// +// * ErrCodePolicyNotFoundException "PolicyNotFoundException" +// We can't find a policy with the PolicyId that you specified. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DeletePolicy +func (c *Organizations) DeletePolicy(input *DeletePolicyInput) (*DeletePolicyOutput, error) { + req, out := c.DeletePolicyRequest(input) + return out, req.Send() +} + +// DeletePolicyWithContext is the same as DeletePolicy with the addition of +// the ability to pass a context and additional request options. +// +// See DeletePolicy for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) DeletePolicyWithContext(ctx aws.Context, input *DeletePolicyInput, opts ...request.Option) (*DeletePolicyOutput, error) { + req, out := c.DeletePolicyRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDescribeAccount = "DescribeAccount" + +// DescribeAccountRequest generates a "aws/request.Request" representing the +// client's request for the DescribeAccount operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DescribeAccount for more information on using the DescribeAccount +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DescribeAccountRequest method. +// req, resp := client.DescribeAccountRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DescribeAccount +func (c *Organizations) DescribeAccountRequest(input *DescribeAccountInput) (req *request.Request, output *DescribeAccountOutput) { + op := &request.Operation{ + Name: opDescribeAccount, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DescribeAccountInput{} + } + + output = &DescribeAccountOutput{} + req = c.newRequest(op, input, output) + return +} + +// DescribeAccount API operation for AWS Organizations. +// +// Retrieves Organizations-related information about the specified account. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation DescribeAccount for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAccountNotFoundException "AccountNotFoundException" +// We can't find an AWS account with the AccountId that you specified, or the +// account whose credentials you used to make this request is not a member of +// an organization. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DescribeAccount +func (c *Organizations) DescribeAccount(input *DescribeAccountInput) (*DescribeAccountOutput, error) { + req, out := c.DescribeAccountRequest(input) + return out, req.Send() +} + +// DescribeAccountWithContext is the same as DescribeAccount with the addition of +// the ability to pass a context and additional request options. +// +// See DescribeAccount for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) DescribeAccountWithContext(ctx aws.Context, input *DescribeAccountInput, opts ...request.Option) (*DescribeAccountOutput, error) { + req, out := c.DescribeAccountRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDescribeCreateAccountStatus = "DescribeCreateAccountStatus" + +// DescribeCreateAccountStatusRequest generates a "aws/request.Request" representing the +// client's request for the DescribeCreateAccountStatus operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DescribeCreateAccountStatus for more information on using the DescribeCreateAccountStatus +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DescribeCreateAccountStatusRequest method. +// req, resp := client.DescribeCreateAccountStatusRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DescribeCreateAccountStatus +func (c *Organizations) DescribeCreateAccountStatusRequest(input *DescribeCreateAccountStatusInput) (req *request.Request, output *DescribeCreateAccountStatusOutput) { + op := &request.Operation{ + Name: opDescribeCreateAccountStatus, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DescribeCreateAccountStatusInput{} + } + + output = &DescribeCreateAccountStatusOutput{} + req = c.newRequest(op, input, output) + return +} + +// DescribeCreateAccountStatus API operation for AWS Organizations. +// +// Retrieves the current status of an asynchronous request to create an account. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation DescribeCreateAccountStatus for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeCreateAccountStatusNotFoundException "CreateAccountStatusNotFoundException" +// We can't find an create account request with the CreateAccountRequestId that +// you specified. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DescribeCreateAccountStatus +func (c *Organizations) DescribeCreateAccountStatus(input *DescribeCreateAccountStatusInput) (*DescribeCreateAccountStatusOutput, error) { + req, out := c.DescribeCreateAccountStatusRequest(input) + return out, req.Send() +} + +// DescribeCreateAccountStatusWithContext is the same as DescribeCreateAccountStatus with the addition of +// the ability to pass a context and additional request options. +// +// See DescribeCreateAccountStatus for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) DescribeCreateAccountStatusWithContext(ctx aws.Context, input *DescribeCreateAccountStatusInput, opts ...request.Option) (*DescribeCreateAccountStatusOutput, error) { + req, out := c.DescribeCreateAccountStatusRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDescribeHandshake = "DescribeHandshake" + +// DescribeHandshakeRequest generates a "aws/request.Request" representing the +// client's request for the DescribeHandshake operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DescribeHandshake for more information on using the DescribeHandshake +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DescribeHandshakeRequest method. +// req, resp := client.DescribeHandshakeRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DescribeHandshake +func (c *Organizations) DescribeHandshakeRequest(input *DescribeHandshakeInput) (req *request.Request, output *DescribeHandshakeOutput) { + op := &request.Operation{ + Name: opDescribeHandshake, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DescribeHandshakeInput{} + } + + output = &DescribeHandshakeOutput{} + req = c.newRequest(op, input, output) + return +} + +// DescribeHandshake API operation for AWS Organizations. +// +// Retrieves information about a previously requested handshake. The handshake +// ID comes from the response to the original InviteAccountToOrganization operation +// that generated the handshake. +// +// You can access handshakes that are ACCEPTED, DECLINED, or CANCELED for only +// 30 days after they change to that state. They are then deleted and no longer +// accessible. +// +// This operation can be called from any account in the organization. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation DescribeHandshake for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeHandshakeNotFoundException "HandshakeNotFoundException" +// We can't find a handshake with the HandshakeId that you specified. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DescribeHandshake +func (c *Organizations) DescribeHandshake(input *DescribeHandshakeInput) (*DescribeHandshakeOutput, error) { + req, out := c.DescribeHandshakeRequest(input) + return out, req.Send() +} + +// DescribeHandshakeWithContext is the same as DescribeHandshake with the addition of +// the ability to pass a context and additional request options. +// +// See DescribeHandshake for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) DescribeHandshakeWithContext(ctx aws.Context, input *DescribeHandshakeInput, opts ...request.Option) (*DescribeHandshakeOutput, error) { + req, out := c.DescribeHandshakeRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDescribeOrganization = "DescribeOrganization" + +// DescribeOrganizationRequest generates a "aws/request.Request" representing the +// client's request for the DescribeOrganization operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DescribeOrganization for more information on using the DescribeOrganization +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DescribeOrganizationRequest method. +// req, resp := client.DescribeOrganizationRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DescribeOrganization +func (c *Organizations) DescribeOrganizationRequest(input *DescribeOrganizationInput) (req *request.Request, output *DescribeOrganizationOutput) { + op := &request.Operation{ + Name: opDescribeOrganization, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DescribeOrganizationInput{} + } + + output = &DescribeOrganizationOutput{} + req = c.newRequest(op, input, output) + return +} + +// DescribeOrganization API operation for AWS Organizations. +// +// Retrieves information about the organization that the user's account belongs +// to. +// +// This operation can be called from any account in the organization. +// +// Even if a policy type is shown as available in the organization, it can be +// disabled separately at the root level with DisablePolicyType. Use ListRoots +// to see the status of policy types for a specified root. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation DescribeOrganization for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DescribeOrganization +func (c *Organizations) DescribeOrganization(input *DescribeOrganizationInput) (*DescribeOrganizationOutput, error) { + req, out := c.DescribeOrganizationRequest(input) + return out, req.Send() +} + +// DescribeOrganizationWithContext is the same as DescribeOrganization with the addition of +// the ability to pass a context and additional request options. +// +// See DescribeOrganization for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) DescribeOrganizationWithContext(ctx aws.Context, input *DescribeOrganizationInput, opts ...request.Option) (*DescribeOrganizationOutput, error) { + req, out := c.DescribeOrganizationRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDescribeOrganizationalUnit = "DescribeOrganizationalUnit" + +// DescribeOrganizationalUnitRequest generates a "aws/request.Request" representing the +// client's request for the DescribeOrganizationalUnit operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DescribeOrganizationalUnit for more information on using the DescribeOrganizationalUnit +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DescribeOrganizationalUnitRequest method. +// req, resp := client.DescribeOrganizationalUnitRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DescribeOrganizationalUnit +func (c *Organizations) DescribeOrganizationalUnitRequest(input *DescribeOrganizationalUnitInput) (req *request.Request, output *DescribeOrganizationalUnitOutput) { + op := &request.Operation{ + Name: opDescribeOrganizationalUnit, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DescribeOrganizationalUnitInput{} + } + + output = &DescribeOrganizationalUnitOutput{} + req = c.newRequest(op, input, output) + return +} + +// DescribeOrganizationalUnit API operation for AWS Organizations. +// +// Retrieves information about an organizational unit (OU). +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation DescribeOrganizationalUnit for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeOrganizationalUnitNotFoundException "OrganizationalUnitNotFoundException" +// We can't find an organizational unit (OU) with the OrganizationalUnitId that +// you specified. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DescribeOrganizationalUnit +func (c *Organizations) DescribeOrganizationalUnit(input *DescribeOrganizationalUnitInput) (*DescribeOrganizationalUnitOutput, error) { + req, out := c.DescribeOrganizationalUnitRequest(input) + return out, req.Send() +} + +// DescribeOrganizationalUnitWithContext is the same as DescribeOrganizationalUnit with the addition of +// the ability to pass a context and additional request options. +// +// See DescribeOrganizationalUnit for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) DescribeOrganizationalUnitWithContext(ctx aws.Context, input *DescribeOrganizationalUnitInput, opts ...request.Option) (*DescribeOrganizationalUnitOutput, error) { + req, out := c.DescribeOrganizationalUnitRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDescribePolicy = "DescribePolicy" + +// DescribePolicyRequest generates a "aws/request.Request" representing the +// client's request for the DescribePolicy operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DescribePolicy for more information on using the DescribePolicy +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DescribePolicyRequest method. +// req, resp := client.DescribePolicyRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DescribePolicy +func (c *Organizations) DescribePolicyRequest(input *DescribePolicyInput) (req *request.Request, output *DescribePolicyOutput) { + op := &request.Operation{ + Name: opDescribePolicy, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DescribePolicyInput{} + } + + output = &DescribePolicyOutput{} + req = c.newRequest(op, input, output) + return +} + +// DescribePolicy API operation for AWS Organizations. +// +// Retrieves information about a policy. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation DescribePolicy for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodePolicyNotFoundException "PolicyNotFoundException" +// We can't find a policy with the PolicyId that you specified. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DescribePolicy +func (c *Organizations) DescribePolicy(input *DescribePolicyInput) (*DescribePolicyOutput, error) { + req, out := c.DescribePolicyRequest(input) + return out, req.Send() +} + +// DescribePolicyWithContext is the same as DescribePolicy with the addition of +// the ability to pass a context and additional request options. +// +// See DescribePolicy for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) DescribePolicyWithContext(ctx aws.Context, input *DescribePolicyInput, opts ...request.Option) (*DescribePolicyOutput, error) { + req, out := c.DescribePolicyRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDetachPolicy = "DetachPolicy" + +// DetachPolicyRequest generates a "aws/request.Request" representing the +// client's request for the DetachPolicy operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DetachPolicy for more information on using the DetachPolicy +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DetachPolicyRequest method. +// req, resp := client.DetachPolicyRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DetachPolicy +func (c *Organizations) DetachPolicyRequest(input *DetachPolicyInput) (req *request.Request, output *DetachPolicyOutput) { + op := &request.Operation{ + Name: opDetachPolicy, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DetachPolicyInput{} + } + + output = &DetachPolicyOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DetachPolicy API operation for AWS Organizations. +// +// Detaches a policy from a target root, organizational unit, or account. If +// the policy being detached is a service control policy (SCP), the changes +// to permissions for IAM users and roles in affected accounts are immediate. +// +// Note: Every root, OU, and account must have at least one SCP attached. If +// you want to replace the default FullAWSAccess policy with one that limits +// the permissions that can be delegated, then you must attach the replacement +// policy before you can remove the default one. This is the authorization strategy +// of whitelisting (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_about-scps.html#orgs_policies_whitelist). +// If you instead attach a second SCP and leave the FullAWSAccess SCP still +// attached, and specify "Effect": "Deny" in the second SCP to override the +// "Effect": "Allow" in the FullAWSAccess policy (or any other attached SCP), +// then you are using the authorization strategy of blacklisting (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_about-scps.html#orgs_policies_blacklist). +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation DetachPolicy for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeConstraintViolationException "ConstraintViolationException" +// Performing this operation violates a minimum or maximum value limit. For +// example, attempting to removing the last SCP from an OU or root, inviting +// or creating too many accounts to the organization, or attaching too many +// policies to an account, OU, or root. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on the number +// of accounts in an organization. If you need more accounts, contact AWS Support +// to request an increase in your limit. +// +// Or, The number of invitations that you tried to send would cause you to exceed +// the limit of accounts in your organization. Send fewer invitations, or contact +// AWS Support to request an increase in the number of accounts. +// +// Note: deleted and closed accounts still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * OU_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the number of organizational +// units you can have in an organization. +// +// * OU_DEPTH_LIMIT_EXCEEDED: You attempted to create an organizational unit +// tree that is too many levels deep. +// +// * POLICY_NUMBER_LIMIT_EXCEEDED. You attempted to exceed the number of +// policies that you can have in an organization. +// +// * MAX_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to exceed the +// number of policies of a certain type that can be attached to an entity +// at one time. +// +// * MIN_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to detach a +// policy from an entity that would cause the entity to have fewer than the +// minimum number of policies of a certain type required. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_EULA: You attempted to remove an account +// from the organization that does not yet have enough information to exist +// as a stand-alone account. This account requires you to first agree to +// the AWS Customer Agreement. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_PHONE_VERIFICATION: You attempted to remove +// an account from the organization that does not yet have enough information +// to exist as a stand-alone account. This account requires you to first +// complete phone verification. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MASTER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To create an organization +// with this account, you first must associate a payment instrument, such +// as a credit card, with the account. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MEMBER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To complete this operation +// with this member account, you first must associate a payment instrument, +// such as a credit card, with the account. Follow the steps at To leave +// an organization when all required account information has not yet been +// provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CREATION_RATE_LIMIT_EXCEEDED: You attempted to exceed the number +// of accounts that you can create in one day. +// +// * MASTER_ACCOUNT_ADDRESS_DOES_NOT_MATCH_MARKETPLACE: To create an account +// in this organization, you first must migrate the organization's master +// account to the marketplace that corresponds to the master account's address. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be associated +// with the same marketplace. +// +// * MASTER_ACCOUNT_MISSING_CONTACT_INFO: To complete this operation, you +// must first provide contact a valid address and phone number for the master +// account. Then try the operation again. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodePolicyNotAttachedException "PolicyNotAttachedException" +// The policy isn't attached to the specified target in the specified root. +// +// * ErrCodePolicyNotFoundException "PolicyNotFoundException" +// We can't find a policy with the PolicyId that you specified. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTargetNotFoundException "TargetNotFoundException" +// We can't find a root, OU, or account with the TargetId that you specified. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DetachPolicy +func (c *Organizations) DetachPolicy(input *DetachPolicyInput) (*DetachPolicyOutput, error) { + req, out := c.DetachPolicyRequest(input) + return out, req.Send() +} + +// DetachPolicyWithContext is the same as DetachPolicy with the addition of +// the ability to pass a context and additional request options. +// +// See DetachPolicy for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) DetachPolicyWithContext(ctx aws.Context, input *DetachPolicyInput, opts ...request.Option) (*DetachPolicyOutput, error) { + req, out := c.DetachPolicyRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDisableAWSServiceAccess = "DisableAWSServiceAccess" + +// DisableAWSServiceAccessRequest generates a "aws/request.Request" representing the +// client's request for the DisableAWSServiceAccess operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DisableAWSServiceAccess for more information on using the DisableAWSServiceAccess +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DisableAWSServiceAccessRequest method. +// req, resp := client.DisableAWSServiceAccessRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DisableAWSServiceAccess +func (c *Organizations) DisableAWSServiceAccessRequest(input *DisableAWSServiceAccessInput) (req *request.Request, output *DisableAWSServiceAccessOutput) { + op := &request.Operation{ + Name: opDisableAWSServiceAccess, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DisableAWSServiceAccessInput{} + } + + output = &DisableAWSServiceAccessOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// DisableAWSServiceAccess API operation for AWS Organizations. +// +// Disables the integration of an AWS service (the service that is specified +// by ServicePrincipal) with AWS Organizations. When you disable integration, +// the specified service no longer can create a service-linked role (http://docs.aws.amazon.com/IAM/latest/UserGuide/using-service-linked-roles.html) +// in new accounts in your organization. This means the service can't perform +// operations on your behalf on any new accounts in your organization. The service +// can still perform operations in older accounts until the service completes +// its clean-up from AWS Organizations. +// +// We recommend that you disable integration between AWS Organizations and the +// specified AWS service by using the console or commands that are provided +// by the specified service. Doing so ensures that the other service is aware +// that it can clean up any resources that are required only for the integration. +// How the service cleans up its resources in the organization's accounts depends +// on that service. For more information, see the documentation for the other +// AWS service. +// +// After you perform the DisableAWSServiceAccessoperation, the specified service can no longer perform operations in your +// organization's accounts unless the operations are explicitly permitted by +// the IAM policies that are attached to your roles. +// +// For more information about integrating other services with AWS Organizations, +// including the list of services that work with Organizations, see Integrating +// AWS Organizations with Other AWS Services (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services.html)in the AWS Organizations User Guide +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation DisableAWSServiceAccess for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeConstraintViolationException "ConstraintViolationException" +// Performing this operation violates a minimum or maximum value limit. For +// example, attempting to removing the last SCP from an OU or root, inviting +// or creating too many accounts to the organization, or attaching too many +// policies to an account, OU, or root. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on the number +// of accounts in an organization. If you need more accounts, contact AWS Support +// to request an increase in your limit. +// +// Or, The number of invitations that you tried to send would cause you to exceed +// the limit of accounts in your organization. Send fewer invitations, or contact +// AWS Support to request an increase in the number of accounts. +// +// Note: deleted and closed accounts still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * OU_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the number of organizational +// units you can have in an organization. +// +// * OU_DEPTH_LIMIT_EXCEEDED: You attempted to create an organizational unit +// tree that is too many levels deep. +// +// * POLICY_NUMBER_LIMIT_EXCEEDED. You attempted to exceed the number of +// policies that you can have in an organization. +// +// * MAX_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to exceed the +// number of policies of a certain type that can be attached to an entity +// at one time. +// +// * MIN_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to detach a +// policy from an entity that would cause the entity to have fewer than the +// minimum number of policies of a certain type required. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_EULA: You attempted to remove an account +// from the organization that does not yet have enough information to exist +// as a stand-alone account. This account requires you to first agree to +// the AWS Customer Agreement. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_PHONE_VERIFICATION: You attempted to remove +// an account from the organization that does not yet have enough information +// to exist as a stand-alone account. This account requires you to first +// complete phone verification. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MASTER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To create an organization +// with this account, you first must associate a payment instrument, such +// as a credit card, with the account. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MEMBER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To complete this operation +// with this member account, you first must associate a payment instrument, +// such as a credit card, with the account. Follow the steps at To leave +// an organization when all required account information has not yet been +// provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CREATION_RATE_LIMIT_EXCEEDED: You attempted to exceed the number +// of accounts that you can create in one day. +// +// * MASTER_ACCOUNT_ADDRESS_DOES_NOT_MATCH_MARKETPLACE: To create an account +// in this organization, you first must migrate the organization's master +// account to the marketplace that corresponds to the master account's address. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be associated +// with the same marketplace. +// +// * MASTER_ACCOUNT_MISSING_CONTACT_INFO: To complete this operation, you +// must first provide contact a valid address and phone number for the master +// account. Then try the operation again. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DisableAWSServiceAccess +func (c *Organizations) DisableAWSServiceAccess(input *DisableAWSServiceAccessInput) (*DisableAWSServiceAccessOutput, error) { + req, out := c.DisableAWSServiceAccessRequest(input) + return out, req.Send() +} + +// DisableAWSServiceAccessWithContext is the same as DisableAWSServiceAccess with the addition of +// the ability to pass a context and additional request options. +// +// See DisableAWSServiceAccess for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) DisableAWSServiceAccessWithContext(ctx aws.Context, input *DisableAWSServiceAccessInput, opts ...request.Option) (*DisableAWSServiceAccessOutput, error) { + req, out := c.DisableAWSServiceAccessRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opDisablePolicyType = "DisablePolicyType" + +// DisablePolicyTypeRequest generates a "aws/request.Request" representing the +// client's request for the DisablePolicyType operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DisablePolicyType for more information on using the DisablePolicyType +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DisablePolicyTypeRequest method. +// req, resp := client.DisablePolicyTypeRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DisablePolicyType +func (c *Organizations) DisablePolicyTypeRequest(input *DisablePolicyTypeInput) (req *request.Request, output *DisablePolicyTypeOutput) { + op := &request.Operation{ + Name: opDisablePolicyType, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DisablePolicyTypeInput{} + } + + output = &DisablePolicyTypeOutput{} + req = c.newRequest(op, input, output) + return +} + +// DisablePolicyType API operation for AWS Organizations. +// +// Disables an organizational control policy type in a root. A policy of a certain +// type can be attached to entities in a root only if that type is enabled in +// the root. After you perform this operation, you no longer can attach policies +// of the specified type to that root or to any OU or account in that root. +// You can undo this by using the EnablePolicyType operation. +// +// This operation can be called only from the organization's master account. +// +// If you disable a policy type for a root, it still shows as enabled for the +// organization if all features are enabled in that organization. Use ListRoots +// to see the status of policy types for a specified root. Use DescribeOrganization +// to see the status of policy types in the organization. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation DisablePolicyType for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeConstraintViolationException "ConstraintViolationException" +// Performing this operation violates a minimum or maximum value limit. For +// example, attempting to removing the last SCP from an OU or root, inviting +// or creating too many accounts to the organization, or attaching too many +// policies to an account, OU, or root. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on the number +// of accounts in an organization. If you need more accounts, contact AWS Support +// to request an increase in your limit. +// +// Or, The number of invitations that you tried to send would cause you to exceed +// the limit of accounts in your organization. Send fewer invitations, or contact +// AWS Support to request an increase in the number of accounts. +// +// Note: deleted and closed accounts still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * OU_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the number of organizational +// units you can have in an organization. +// +// * OU_DEPTH_LIMIT_EXCEEDED: You attempted to create an organizational unit +// tree that is too many levels deep. +// +// * POLICY_NUMBER_LIMIT_EXCEEDED. You attempted to exceed the number of +// policies that you can have in an organization. +// +// * MAX_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to exceed the +// number of policies of a certain type that can be attached to an entity +// at one time. +// +// * MIN_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to detach a +// policy from an entity that would cause the entity to have fewer than the +// minimum number of policies of a certain type required. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_EULA: You attempted to remove an account +// from the organization that does not yet have enough information to exist +// as a stand-alone account. This account requires you to first agree to +// the AWS Customer Agreement. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_PHONE_VERIFICATION: You attempted to remove +// an account from the organization that does not yet have enough information +// to exist as a stand-alone account. This account requires you to first +// complete phone verification. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MASTER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To create an organization +// with this account, you first must associate a payment instrument, such +// as a credit card, with the account. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MEMBER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To complete this operation +// with this member account, you first must associate a payment instrument, +// such as a credit card, with the account. Follow the steps at To leave +// an organization when all required account information has not yet been +// provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CREATION_RATE_LIMIT_EXCEEDED: You attempted to exceed the number +// of accounts that you can create in one day. +// +// * MASTER_ACCOUNT_ADDRESS_DOES_NOT_MATCH_MARKETPLACE: To create an account +// in this organization, you first must migrate the organization's master +// account to the marketplace that corresponds to the master account's address. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be associated +// with the same marketplace. +// +// * MASTER_ACCOUNT_MISSING_CONTACT_INFO: To complete this operation, you +// must first provide contact a valid address and phone number for the master +// account. Then try the operation again. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodePolicyTypeNotEnabledException "PolicyTypeNotEnabledException" +// The specified policy type is not currently enabled in this root. You cannot +// attach policies of the specified type to entities in a root until you enable +// that type in the root. For more information, see Enabling All Features in +// Your Organization (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html) +// in the AWS Organizations User Guide. +// +// * ErrCodeRootNotFoundException "RootNotFoundException" +// We can't find a root with the RootId that you specified. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/DisablePolicyType +func (c *Organizations) DisablePolicyType(input *DisablePolicyTypeInput) (*DisablePolicyTypeOutput, error) { + req, out := c.DisablePolicyTypeRequest(input) + return out, req.Send() +} + +// DisablePolicyTypeWithContext is the same as DisablePolicyType with the addition of +// the ability to pass a context and additional request options. +// +// See DisablePolicyType for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) DisablePolicyTypeWithContext(ctx aws.Context, input *DisablePolicyTypeInput, opts ...request.Option) (*DisablePolicyTypeOutput, error) { + req, out := c.DisablePolicyTypeRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opEnableAWSServiceAccess = "EnableAWSServiceAccess" + +// EnableAWSServiceAccessRequest generates a "aws/request.Request" representing the +// client's request for the EnableAWSServiceAccess operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See EnableAWSServiceAccess for more information on using the EnableAWSServiceAccess +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the EnableAWSServiceAccessRequest method. +// req, resp := client.EnableAWSServiceAccessRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/EnableAWSServiceAccess +func (c *Organizations) EnableAWSServiceAccessRequest(input *EnableAWSServiceAccessInput) (req *request.Request, output *EnableAWSServiceAccessOutput) { + op := &request.Operation{ + Name: opEnableAWSServiceAccess, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &EnableAWSServiceAccessInput{} + } + + output = &EnableAWSServiceAccessOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// EnableAWSServiceAccess API operation for AWS Organizations. +// +// Enables the integration of an AWS service (the service that is specified +// by ServicePrincipal) with AWS Organizations. When you enable integration, +// you allow the specified service to create a service-linked role (http://docs.aws.amazon.com/IAM/latest/UserGuide/using-service-linked-roles.html) +// in all the accounts in your organization. This allows the service to perform +// operations on your behalf in your organization and its accounts. +// +// We recommend that you enable integration between AWS Organizations and the +// specified AWS service by using the console or commands that are provided +// by the specified service. Doing so ensures that the service is aware that +// it can create the resources that are required for the integration. How the +// service creates those resources in the organization's accounts depends on +// that service. For more information, see the documentation for the other AWS +// service. +// +// For more information about enabling services to integrate with AWS Organizations, +// see Integrating AWS Organizations with Other AWS Services (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services.html) +// in the AWS Organizations User Guide. +// +// This operation can be called only from the organization's master account +// and only if the organization has enabled all features (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html). +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation EnableAWSServiceAccess for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeConstraintViolationException "ConstraintViolationException" +// Performing this operation violates a minimum or maximum value limit. For +// example, attempting to removing the last SCP from an OU or root, inviting +// or creating too many accounts to the organization, or attaching too many +// policies to an account, OU, or root. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on the number +// of accounts in an organization. If you need more accounts, contact AWS Support +// to request an increase in your limit. +// +// Or, The number of invitations that you tried to send would cause you to exceed +// the limit of accounts in your organization. Send fewer invitations, or contact +// AWS Support to request an increase in the number of accounts. +// +// Note: deleted and closed accounts still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * OU_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the number of organizational +// units you can have in an organization. +// +// * OU_DEPTH_LIMIT_EXCEEDED: You attempted to create an organizational unit +// tree that is too many levels deep. +// +// * POLICY_NUMBER_LIMIT_EXCEEDED. You attempted to exceed the number of +// policies that you can have in an organization. +// +// * MAX_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to exceed the +// number of policies of a certain type that can be attached to an entity +// at one time. +// +// * MIN_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to detach a +// policy from an entity that would cause the entity to have fewer than the +// minimum number of policies of a certain type required. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_EULA: You attempted to remove an account +// from the organization that does not yet have enough information to exist +// as a stand-alone account. This account requires you to first agree to +// the AWS Customer Agreement. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_PHONE_VERIFICATION: You attempted to remove +// an account from the organization that does not yet have enough information +// to exist as a stand-alone account. This account requires you to first +// complete phone verification. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MASTER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To create an organization +// with this account, you first must associate a payment instrument, such +// as a credit card, with the account. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MEMBER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To complete this operation +// with this member account, you first must associate a payment instrument, +// such as a credit card, with the account. Follow the steps at To leave +// an organization when all required account information has not yet been +// provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CREATION_RATE_LIMIT_EXCEEDED: You attempted to exceed the number +// of accounts that you can create in one day. +// +// * MASTER_ACCOUNT_ADDRESS_DOES_NOT_MATCH_MARKETPLACE: To create an account +// in this organization, you first must migrate the organization's master +// account to the marketplace that corresponds to the master account's address. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be associated +// with the same marketplace. +// +// * MASTER_ACCOUNT_MISSING_CONTACT_INFO: To complete this operation, you +// must first provide contact a valid address and phone number for the master +// account. Then try the operation again. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/EnableAWSServiceAccess +func (c *Organizations) EnableAWSServiceAccess(input *EnableAWSServiceAccessInput) (*EnableAWSServiceAccessOutput, error) { + req, out := c.EnableAWSServiceAccessRequest(input) + return out, req.Send() +} + +// EnableAWSServiceAccessWithContext is the same as EnableAWSServiceAccess with the addition of +// the ability to pass a context and additional request options. +// +// See EnableAWSServiceAccess for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) EnableAWSServiceAccessWithContext(ctx aws.Context, input *EnableAWSServiceAccessInput, opts ...request.Option) (*EnableAWSServiceAccessOutput, error) { + req, out := c.EnableAWSServiceAccessRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opEnableAllFeatures = "EnableAllFeatures" + +// EnableAllFeaturesRequest generates a "aws/request.Request" representing the +// client's request for the EnableAllFeatures operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See EnableAllFeatures for more information on using the EnableAllFeatures +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the EnableAllFeaturesRequest method. +// req, resp := client.EnableAllFeaturesRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/EnableAllFeatures +func (c *Organizations) EnableAllFeaturesRequest(input *EnableAllFeaturesInput) (req *request.Request, output *EnableAllFeaturesOutput) { + op := &request.Operation{ + Name: opEnableAllFeatures, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &EnableAllFeaturesInput{} + } + + output = &EnableAllFeaturesOutput{} + req = c.newRequest(op, input, output) + return +} + +// EnableAllFeatures API operation for AWS Organizations. +// +// Enables all features in an organization. This enables the use of organization +// policies that can restrict the services and actions that can be called in +// each account. Until you enable all features, you have access only to consolidated +// billing, and you can't use any of the advanced account administration features +// that AWS Organizations supports. For more information, see Enabling All Features +// in Your Organization (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html) +// in the AWS Organizations User Guide. +// +// This operation is required only for organizations that were created explicitly +// with only the consolidated billing features enabled, or that were migrated +// from a Consolidated Billing account family to Organizations. Calling this +// operation sends a handshake to every invited account in the organization. +// The feature set change can be finalized and the additional features enabled +// only after all administrators in the invited accounts approve the change +// by accepting the handshake. +// +// After you enable all features, you can separately enable or disable individual +// policy types in a root using EnablePolicyType and DisablePolicyType. To see +// the status of policy types in a root, use ListRoots. +// +// After all invited member accounts accept the handshake, you finalize the +// feature set change by accepting the handshake that contains "Action": "ENABLE_ALL_FEATURES". +// This completes the change. +// +// After you enable all features in your organization, the master account in +// the organization can apply policies on all member accounts. These policies +// can restrict what users and even administrators in those accounts can do. +// The master account can apply policies that prevent accounts from leaving +// the organization. Ensure that your account administrators are aware of this. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation EnableAllFeatures for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeHandshakeConstraintViolationException "HandshakeConstraintViolationException" +// The requested operation would violate the constraint identified in the reason +// code. +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on +// the number of accounts in an organization. Note: deleted and closed accounts +// still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * ALREADY_IN_AN_ORGANIZATION: The handshake request is invalid because +// the invited account is already a member of an organization. +// +// * ORGANIZATION_ALREADY_HAS_ALL_FEATURES: The handshake request is invalid +// because the organization has already enabled all features. +// +// * INVITE_DISABLED_DURING_ENABLE_ALL_FEATURES: You cannot issue new invitations +// to join an organization while it is in the process of enabling all features. +// You can resume inviting accounts after you finalize the process when all +// accounts have agreed to the change. +// +// * PAYMENT_INSTRUMENT_REQUIRED: You cannot complete the operation with +// an account that does not have a payment instrument, such as a credit card, +// associated with it. +// +// * ORGANIZATION_FROM_DIFFERENT_SELLER_OF_RECORD: The request failed because +// the account is from a different marketplace than the accounts in the organization. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be from the same +// marketplace. +// +// * ORGANIZATION_MEMBERSHIP_CHANGE_RATE_LIMIT_EXCEEDED: You attempted to +// change the membership of an account too quickly after its previous change. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/EnableAllFeatures +func (c *Organizations) EnableAllFeatures(input *EnableAllFeaturesInput) (*EnableAllFeaturesOutput, error) { + req, out := c.EnableAllFeaturesRequest(input) + return out, req.Send() +} + +// EnableAllFeaturesWithContext is the same as EnableAllFeatures with the addition of +// the ability to pass a context and additional request options. +// +// See EnableAllFeatures for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) EnableAllFeaturesWithContext(ctx aws.Context, input *EnableAllFeaturesInput, opts ...request.Option) (*EnableAllFeaturesOutput, error) { + req, out := c.EnableAllFeaturesRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opEnablePolicyType = "EnablePolicyType" + +// EnablePolicyTypeRequest generates a "aws/request.Request" representing the +// client's request for the EnablePolicyType operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See EnablePolicyType for more information on using the EnablePolicyType +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the EnablePolicyTypeRequest method. +// req, resp := client.EnablePolicyTypeRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/EnablePolicyType +func (c *Organizations) EnablePolicyTypeRequest(input *EnablePolicyTypeInput) (req *request.Request, output *EnablePolicyTypeOutput) { + op := &request.Operation{ + Name: opEnablePolicyType, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &EnablePolicyTypeInput{} + } + + output = &EnablePolicyTypeOutput{} + req = c.newRequest(op, input, output) + return +} + +// EnablePolicyType API operation for AWS Organizations. +// +// Enables a policy type in a root. After you enable a policy type in a root, +// you can attach policies of that type to the root, any OU, or account in that +// root. You can undo this by using the DisablePolicyType operation. +// +// This operation can be called only from the organization's master account. +// +// You can enable a policy type in a root only if that policy type is available +// in the organization. Use DescribeOrganization to view the status of available +// policy types in the organization. +// +// To view the status of policy type in a root, use ListRoots. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation EnablePolicyType for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeConstraintViolationException "ConstraintViolationException" +// Performing this operation violates a minimum or maximum value limit. For +// example, attempting to removing the last SCP from an OU or root, inviting +// or creating too many accounts to the organization, or attaching too many +// policies to an account, OU, or root. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on the number +// of accounts in an organization. If you need more accounts, contact AWS Support +// to request an increase in your limit. +// +// Or, The number of invitations that you tried to send would cause you to exceed +// the limit of accounts in your organization. Send fewer invitations, or contact +// AWS Support to request an increase in the number of accounts. +// +// Note: deleted and closed accounts still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * OU_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the number of organizational +// units you can have in an organization. +// +// * OU_DEPTH_LIMIT_EXCEEDED: You attempted to create an organizational unit +// tree that is too many levels deep. +// +// * POLICY_NUMBER_LIMIT_EXCEEDED. You attempted to exceed the number of +// policies that you can have in an organization. +// +// * MAX_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to exceed the +// number of policies of a certain type that can be attached to an entity +// at one time. +// +// * MIN_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to detach a +// policy from an entity that would cause the entity to have fewer than the +// minimum number of policies of a certain type required. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_EULA: You attempted to remove an account +// from the organization that does not yet have enough information to exist +// as a stand-alone account. This account requires you to first agree to +// the AWS Customer Agreement. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_PHONE_VERIFICATION: You attempted to remove +// an account from the organization that does not yet have enough information +// to exist as a stand-alone account. This account requires you to first +// complete phone verification. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MASTER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To create an organization +// with this account, you first must associate a payment instrument, such +// as a credit card, with the account. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MEMBER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To complete this operation +// with this member account, you first must associate a payment instrument, +// such as a credit card, with the account. Follow the steps at To leave +// an organization when all required account information has not yet been +// provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CREATION_RATE_LIMIT_EXCEEDED: You attempted to exceed the number +// of accounts that you can create in one day. +// +// * MASTER_ACCOUNT_ADDRESS_DOES_NOT_MATCH_MARKETPLACE: To create an account +// in this organization, you first must migrate the organization's master +// account to the marketplace that corresponds to the master account's address. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be associated +// with the same marketplace. +// +// * MASTER_ACCOUNT_MISSING_CONTACT_INFO: To complete this operation, you +// must first provide contact a valid address and phone number for the master +// account. Then try the operation again. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodePolicyTypeAlreadyEnabledException "PolicyTypeAlreadyEnabledException" +// The specified policy type is already enabled in the specified root. +// +// * ErrCodeRootNotFoundException "RootNotFoundException" +// We can't find a root with the RootId that you specified. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// * ErrCodePolicyTypeNotAvailableForOrganizationException "PolicyTypeNotAvailableForOrganizationException" +// You can't use the specified policy type with the feature set currently enabled +// for this organization. For example, you can enable service control policies +// (SCPs) only after you enable all features in the organization. For more information, +// see Enabling and Disabling a Policy Type on a Root (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies.html#enable_policies_on_root) +// in the AWS Organizations User Guide. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/EnablePolicyType +func (c *Organizations) EnablePolicyType(input *EnablePolicyTypeInput) (*EnablePolicyTypeOutput, error) { + req, out := c.EnablePolicyTypeRequest(input) + return out, req.Send() +} + +// EnablePolicyTypeWithContext is the same as EnablePolicyType with the addition of +// the ability to pass a context and additional request options. +// +// See EnablePolicyType for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) EnablePolicyTypeWithContext(ctx aws.Context, input *EnablePolicyTypeInput, opts ...request.Option) (*EnablePolicyTypeOutput, error) { + req, out := c.EnablePolicyTypeRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opInviteAccountToOrganization = "InviteAccountToOrganization" + +// InviteAccountToOrganizationRequest generates a "aws/request.Request" representing the +// client's request for the InviteAccountToOrganization operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See InviteAccountToOrganization for more information on using the InviteAccountToOrganization +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the InviteAccountToOrganizationRequest method. +// req, resp := client.InviteAccountToOrganizationRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/InviteAccountToOrganization +func (c *Organizations) InviteAccountToOrganizationRequest(input *InviteAccountToOrganizationInput) (req *request.Request, output *InviteAccountToOrganizationOutput) { + op := &request.Operation{ + Name: opInviteAccountToOrganization, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &InviteAccountToOrganizationInput{} + } + + output = &InviteAccountToOrganizationOutput{} + req = c.newRequest(op, input, output) + return +} + +// InviteAccountToOrganization API operation for AWS Organizations. +// +// Sends an invitation to another account to join your organization as a member +// account. Organizations sends email on your behalf to the email address that +// is associated with the other account's owner. The invitation is implemented +// as a Handshake whose details are in the response. +// +// You can invite AWS accounts only from the same seller as the master account. +// For example, if your organization's master account was created by Amazon +// Internet Services Pvt. Ltd (AISPL), an AWS seller in India, then you can +// only invite other AISPL accounts to your organization. You can't combine +// accounts from AISPL and AWS, or any other AWS seller. For more information, +// see Consolidated Billing in India (http://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/useconsolidatedbilliing-India.html). +// +// This operation can be called only from the organization's master account. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation InviteAccountToOrganization for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeHandshakeConstraintViolationException "HandshakeConstraintViolationException" +// The requested operation would violate the constraint identified in the reason +// code. +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on +// the number of accounts in an organization. Note: deleted and closed accounts +// still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * ALREADY_IN_AN_ORGANIZATION: The handshake request is invalid because +// the invited account is already a member of an organization. +// +// * ORGANIZATION_ALREADY_HAS_ALL_FEATURES: The handshake request is invalid +// because the organization has already enabled all features. +// +// * INVITE_DISABLED_DURING_ENABLE_ALL_FEATURES: You cannot issue new invitations +// to join an organization while it is in the process of enabling all features. +// You can resume inviting accounts after you finalize the process when all +// accounts have agreed to the change. +// +// * PAYMENT_INSTRUMENT_REQUIRED: You cannot complete the operation with +// an account that does not have a payment instrument, such as a credit card, +// associated with it. +// +// * ORGANIZATION_FROM_DIFFERENT_SELLER_OF_RECORD: The request failed because +// the account is from a different marketplace than the accounts in the organization. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be from the same +// marketplace. +// +// * ORGANIZATION_MEMBERSHIP_CHANGE_RATE_LIMIT_EXCEEDED: You attempted to +// change the membership of an account too quickly after its previous change. +// +// * ErrCodeDuplicateHandshakeException "DuplicateHandshakeException" +// A handshake with the same action and target already exists. For example, +// if you invited an account to join your organization, the invited account +// might already have a pending invitation from this organization. If you intend +// to resend an invitation to an account, ensure that existing handshakes that +// might be considered duplicates are canceled or declined. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeFinalizingOrganizationException "FinalizingOrganizationException" +// AWS Organizations could not finalize the creation of your organization. Try +// again later. If this persists, contact AWS customer support. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/InviteAccountToOrganization +func (c *Organizations) InviteAccountToOrganization(input *InviteAccountToOrganizationInput) (*InviteAccountToOrganizationOutput, error) { + req, out := c.InviteAccountToOrganizationRequest(input) + return out, req.Send() +} + +// InviteAccountToOrganizationWithContext is the same as InviteAccountToOrganization with the addition of +// the ability to pass a context and additional request options. +// +// See InviteAccountToOrganization for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) InviteAccountToOrganizationWithContext(ctx aws.Context, input *InviteAccountToOrganizationInput, opts ...request.Option) (*InviteAccountToOrganizationOutput, error) { + req, out := c.InviteAccountToOrganizationRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opLeaveOrganization = "LeaveOrganization" + +// LeaveOrganizationRequest generates a "aws/request.Request" representing the +// client's request for the LeaveOrganization operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See LeaveOrganization for more information on using the LeaveOrganization +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the LeaveOrganizationRequest method. +// req, resp := client.LeaveOrganizationRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/LeaveOrganization +func (c *Organizations) LeaveOrganizationRequest(input *LeaveOrganizationInput) (req *request.Request, output *LeaveOrganizationOutput) { + op := &request.Operation{ + Name: opLeaveOrganization, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &LeaveOrganizationInput{} + } + + output = &LeaveOrganizationOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// LeaveOrganization API operation for AWS Organizations. +// +// Removes a member account from its parent organization. This version of the +// operation is performed by the account that wants to leave. To remove a member +// account as a user in the master account, use RemoveAccountFromOrganization +// instead. +// +// This operation can be called only from a member account in the organization. +// +// The master account in an organization with all features enabled can set service +// control policies (SCPs) that can restrict what administrators of member accounts +// can do, including preventing them from successfully calling LeaveOrganization +// and leaving the organization. +// +// You can leave an organization as a member account only if the account is +// configured with the information required to operate as a standalone account. +// When you create an account in an organization using the AWS Organizations +// console, API, or CLI commands, the information required of standalone accounts +// is not automatically collected. For each account that you want to make standalone, +// you must accept the End User License Agreement (EULA), choose a support plan, +// provide and verify the required contact information, and provide a current +// payment method. AWS uses the payment method to charge for any billable (not +// free tier) AWS activity that occurs while the account is not attached to +// an organization. Follow the steps at To leave an organization when all required +// account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// You can leave an organization only after you enable IAM user access to billing +// in your account. For more information, see Activating Access to the Billing +// and Cost Management Console (http://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/grantaccess.html#ControllingAccessWebsite-Activate) +// in the AWS Billing and Cost Management User Guide. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation LeaveOrganization for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAccountNotFoundException "AccountNotFoundException" +// We can't find an AWS account with the AccountId that you specified, or the +// account whose credentials you used to make this request is not a member of +// an organization. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeConstraintViolationException "ConstraintViolationException" +// Performing this operation violates a minimum or maximum value limit. For +// example, attempting to removing the last SCP from an OU or root, inviting +// or creating too many accounts to the organization, or attaching too many +// policies to an account, OU, or root. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on the number +// of accounts in an organization. If you need more accounts, contact AWS Support +// to request an increase in your limit. +// +// Or, The number of invitations that you tried to send would cause you to exceed +// the limit of accounts in your organization. Send fewer invitations, or contact +// AWS Support to request an increase in the number of accounts. +// +// Note: deleted and closed accounts still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * OU_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the number of organizational +// units you can have in an organization. +// +// * OU_DEPTH_LIMIT_EXCEEDED: You attempted to create an organizational unit +// tree that is too many levels deep. +// +// * POLICY_NUMBER_LIMIT_EXCEEDED. You attempted to exceed the number of +// policies that you can have in an organization. +// +// * MAX_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to exceed the +// number of policies of a certain type that can be attached to an entity +// at one time. +// +// * MIN_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to detach a +// policy from an entity that would cause the entity to have fewer than the +// minimum number of policies of a certain type required. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_EULA: You attempted to remove an account +// from the organization that does not yet have enough information to exist +// as a stand-alone account. This account requires you to first agree to +// the AWS Customer Agreement. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_PHONE_VERIFICATION: You attempted to remove +// an account from the organization that does not yet have enough information +// to exist as a stand-alone account. This account requires you to first +// complete phone verification. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MASTER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To create an organization +// with this account, you first must associate a payment instrument, such +// as a credit card, with the account. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MEMBER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To complete this operation +// with this member account, you first must associate a payment instrument, +// such as a credit card, with the account. Follow the steps at To leave +// an organization when all required account information has not yet been +// provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CREATION_RATE_LIMIT_EXCEEDED: You attempted to exceed the number +// of accounts that you can create in one day. +// +// * MASTER_ACCOUNT_ADDRESS_DOES_NOT_MATCH_MARKETPLACE: To create an account +// in this organization, you first must migrate the organization's master +// account to the marketplace that corresponds to the master account's address. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be associated +// with the same marketplace. +// +// * MASTER_ACCOUNT_MISSING_CONTACT_INFO: To complete this operation, you +// must first provide contact a valid address and phone number for the master +// account. Then try the operation again. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeMasterCannotLeaveOrganizationException "MasterCannotLeaveOrganizationException" +// You can't remove a master account from an organization. If you want the master +// account to become a member account in another organization, you must first +// delete the current organization of the master account. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/LeaveOrganization +func (c *Organizations) LeaveOrganization(input *LeaveOrganizationInput) (*LeaveOrganizationOutput, error) { + req, out := c.LeaveOrganizationRequest(input) + return out, req.Send() +} + +// LeaveOrganizationWithContext is the same as LeaveOrganization with the addition of +// the ability to pass a context and additional request options. +// +// See LeaveOrganization for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) LeaveOrganizationWithContext(ctx aws.Context, input *LeaveOrganizationInput, opts ...request.Option) (*LeaveOrganizationOutput, error) { + req, out := c.LeaveOrganizationRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opListAWSServiceAccessForOrganization = "ListAWSServiceAccessForOrganization" + +// ListAWSServiceAccessForOrganizationRequest generates a "aws/request.Request" representing the +// client's request for the ListAWSServiceAccessForOrganization operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListAWSServiceAccessForOrganization for more information on using the ListAWSServiceAccessForOrganization +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListAWSServiceAccessForOrganizationRequest method. +// req, resp := client.ListAWSServiceAccessForOrganizationRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListAWSServiceAccessForOrganization +func (c *Organizations) ListAWSServiceAccessForOrganizationRequest(input *ListAWSServiceAccessForOrganizationInput) (req *request.Request, output *ListAWSServiceAccessForOrganizationOutput) { + op := &request.Operation{ + Name: opListAWSServiceAccessForOrganization, + HTTPMethod: "POST", + HTTPPath: "/", + Paginator: &request.Paginator{ + InputTokens: []string{"NextToken"}, + OutputTokens: []string{"NextToken"}, + LimitToken: "MaxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListAWSServiceAccessForOrganizationInput{} + } + + output = &ListAWSServiceAccessForOrganizationOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListAWSServiceAccessForOrganization API operation for AWS Organizations. +// +// Returns a list of the AWS services that you enabled to integrate with your +// organization. After a service on this list creates the resources that it +// requires for the integration, it can perform operations on your organization +// and its accounts. +// +// For more information about integrating other services with AWS Organizations, +// including the list of services that currently work with Organizations, see +// Integrating AWS Organizations with Other AWS Services (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_integrate_services.html) +// in the AWS Organizations User Guide. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation ListAWSServiceAccessForOrganization for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConstraintViolationException "ConstraintViolationException" +// Performing this operation violates a minimum or maximum value limit. For +// example, attempting to removing the last SCP from an OU or root, inviting +// or creating too many accounts to the organization, or attaching too many +// policies to an account, OU, or root. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on the number +// of accounts in an organization. If you need more accounts, contact AWS Support +// to request an increase in your limit. +// +// Or, The number of invitations that you tried to send would cause you to exceed +// the limit of accounts in your organization. Send fewer invitations, or contact +// AWS Support to request an increase in the number of accounts. +// +// Note: deleted and closed accounts still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * OU_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the number of organizational +// units you can have in an organization. +// +// * OU_DEPTH_LIMIT_EXCEEDED: You attempted to create an organizational unit +// tree that is too many levels deep. +// +// * POLICY_NUMBER_LIMIT_EXCEEDED. You attempted to exceed the number of +// policies that you can have in an organization. +// +// * MAX_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to exceed the +// number of policies of a certain type that can be attached to an entity +// at one time. +// +// * MIN_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to detach a +// policy from an entity that would cause the entity to have fewer than the +// minimum number of policies of a certain type required. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_EULA: You attempted to remove an account +// from the organization that does not yet have enough information to exist +// as a stand-alone account. This account requires you to first agree to +// the AWS Customer Agreement. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_PHONE_VERIFICATION: You attempted to remove +// an account from the organization that does not yet have enough information +// to exist as a stand-alone account. This account requires you to first +// complete phone verification. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MASTER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To create an organization +// with this account, you first must associate a payment instrument, such +// as a credit card, with the account. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MEMBER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To complete this operation +// with this member account, you first must associate a payment instrument, +// such as a credit card, with the account. Follow the steps at To leave +// an organization when all required account information has not yet been +// provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CREATION_RATE_LIMIT_EXCEEDED: You attempted to exceed the number +// of accounts that you can create in one day. +// +// * MASTER_ACCOUNT_ADDRESS_DOES_NOT_MATCH_MARKETPLACE: To create an account +// in this organization, you first must migrate the organization's master +// account to the marketplace that corresponds to the master account's address. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be associated +// with the same marketplace. +// +// * MASTER_ACCOUNT_MISSING_CONTACT_INFO: To complete this operation, you +// must first provide contact a valid address and phone number for the master +// account. Then try the operation again. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListAWSServiceAccessForOrganization +func (c *Organizations) ListAWSServiceAccessForOrganization(input *ListAWSServiceAccessForOrganizationInput) (*ListAWSServiceAccessForOrganizationOutput, error) { + req, out := c.ListAWSServiceAccessForOrganizationRequest(input) + return out, req.Send() +} + +// ListAWSServiceAccessForOrganizationWithContext is the same as ListAWSServiceAccessForOrganization with the addition of +// the ability to pass a context and additional request options. +// +// See ListAWSServiceAccessForOrganization for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListAWSServiceAccessForOrganizationWithContext(ctx aws.Context, input *ListAWSServiceAccessForOrganizationInput, opts ...request.Option) (*ListAWSServiceAccessForOrganizationOutput, error) { + req, out := c.ListAWSServiceAccessForOrganizationRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListAWSServiceAccessForOrganizationPages iterates over the pages of a ListAWSServiceAccessForOrganization operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListAWSServiceAccessForOrganization method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListAWSServiceAccessForOrganization operation. +// pageNum := 0 +// err := client.ListAWSServiceAccessForOrganizationPages(params, +// func(page *ListAWSServiceAccessForOrganizationOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *Organizations) ListAWSServiceAccessForOrganizationPages(input *ListAWSServiceAccessForOrganizationInput, fn func(*ListAWSServiceAccessForOrganizationOutput, bool) bool) error { + return c.ListAWSServiceAccessForOrganizationPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListAWSServiceAccessForOrganizationPagesWithContext same as ListAWSServiceAccessForOrganizationPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListAWSServiceAccessForOrganizationPagesWithContext(ctx aws.Context, input *ListAWSServiceAccessForOrganizationInput, fn func(*ListAWSServiceAccessForOrganizationOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListAWSServiceAccessForOrganizationInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListAWSServiceAccessForOrganizationRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListAWSServiceAccessForOrganizationOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListAccounts = "ListAccounts" + +// ListAccountsRequest generates a "aws/request.Request" representing the +// client's request for the ListAccounts operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListAccounts for more information on using the ListAccounts +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListAccountsRequest method. +// req, resp := client.ListAccountsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListAccounts +func (c *Organizations) ListAccountsRequest(input *ListAccountsInput) (req *request.Request, output *ListAccountsOutput) { + op := &request.Operation{ + Name: opListAccounts, + HTTPMethod: "POST", + HTTPPath: "/", + Paginator: &request.Paginator{ + InputTokens: []string{"NextToken"}, + OutputTokens: []string{"NextToken"}, + LimitToken: "MaxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListAccountsInput{} + } + + output = &ListAccountsOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListAccounts API operation for AWS Organizations. +// +// Lists all the accounts in the organization. To request only the accounts +// in a specified root or OU, use the ListAccountsForParent operation instead. +// +// Always check the NextToken response parameter for a null value when calling +// a List* operation. These operations can occasionally return an empty set +// of results even when there are more results available. The NextToken response +// parameter value is nullonly when there are no more results to display. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation ListAccounts for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListAccounts +func (c *Organizations) ListAccounts(input *ListAccountsInput) (*ListAccountsOutput, error) { + req, out := c.ListAccountsRequest(input) + return out, req.Send() +} + +// ListAccountsWithContext is the same as ListAccounts with the addition of +// the ability to pass a context and additional request options. +// +// See ListAccounts for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListAccountsWithContext(ctx aws.Context, input *ListAccountsInput, opts ...request.Option) (*ListAccountsOutput, error) { + req, out := c.ListAccountsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListAccountsPages iterates over the pages of a ListAccounts operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListAccounts method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListAccounts operation. +// pageNum := 0 +// err := client.ListAccountsPages(params, +// func(page *ListAccountsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *Organizations) ListAccountsPages(input *ListAccountsInput, fn func(*ListAccountsOutput, bool) bool) error { + return c.ListAccountsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListAccountsPagesWithContext same as ListAccountsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListAccountsPagesWithContext(ctx aws.Context, input *ListAccountsInput, fn func(*ListAccountsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListAccountsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListAccountsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListAccountsOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListAccountsForParent = "ListAccountsForParent" + +// ListAccountsForParentRequest generates a "aws/request.Request" representing the +// client's request for the ListAccountsForParent operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListAccountsForParent for more information on using the ListAccountsForParent +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListAccountsForParentRequest method. +// req, resp := client.ListAccountsForParentRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListAccountsForParent +func (c *Organizations) ListAccountsForParentRequest(input *ListAccountsForParentInput) (req *request.Request, output *ListAccountsForParentOutput) { + op := &request.Operation{ + Name: opListAccountsForParent, + HTTPMethod: "POST", + HTTPPath: "/", + Paginator: &request.Paginator{ + InputTokens: []string{"NextToken"}, + OutputTokens: []string{"NextToken"}, + LimitToken: "MaxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListAccountsForParentInput{} + } + + output = &ListAccountsForParentOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListAccountsForParent API operation for AWS Organizations. +// +// Lists the accounts in an organization that are contained by the specified +// target root or organizational unit (OU). If you specify the root, you get +// a list of all the accounts that are not in any OU. If you specify an OU, +// you get a list of all the accounts in only that OU, and not in any child +// OUs. To get a list of all accounts in the organization, use the ListAccounts +// operation. +// +// Always check the NextToken response parameter for a null value when calling +// a List* operation. These operations can occasionally return an empty set +// of results even when there are more results available. The NextToken response +// parameter value is nullonly when there are no more results to display. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation ListAccountsForParent for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeParentNotFoundException "ParentNotFoundException" +// We can't find a root or organizational unit (OU) with the ParentId that you +// specified. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListAccountsForParent +func (c *Organizations) ListAccountsForParent(input *ListAccountsForParentInput) (*ListAccountsForParentOutput, error) { + req, out := c.ListAccountsForParentRequest(input) + return out, req.Send() +} + +// ListAccountsForParentWithContext is the same as ListAccountsForParent with the addition of +// the ability to pass a context and additional request options. +// +// See ListAccountsForParent for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListAccountsForParentWithContext(ctx aws.Context, input *ListAccountsForParentInput, opts ...request.Option) (*ListAccountsForParentOutput, error) { + req, out := c.ListAccountsForParentRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListAccountsForParentPages iterates over the pages of a ListAccountsForParent operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListAccountsForParent method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListAccountsForParent operation. +// pageNum := 0 +// err := client.ListAccountsForParentPages(params, +// func(page *ListAccountsForParentOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *Organizations) ListAccountsForParentPages(input *ListAccountsForParentInput, fn func(*ListAccountsForParentOutput, bool) bool) error { + return c.ListAccountsForParentPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListAccountsForParentPagesWithContext same as ListAccountsForParentPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListAccountsForParentPagesWithContext(ctx aws.Context, input *ListAccountsForParentInput, fn func(*ListAccountsForParentOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListAccountsForParentInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListAccountsForParentRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListAccountsForParentOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListChildren = "ListChildren" + +// ListChildrenRequest generates a "aws/request.Request" representing the +// client's request for the ListChildren operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListChildren for more information on using the ListChildren +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListChildrenRequest method. +// req, resp := client.ListChildrenRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListChildren +func (c *Organizations) ListChildrenRequest(input *ListChildrenInput) (req *request.Request, output *ListChildrenOutput) { + op := &request.Operation{ + Name: opListChildren, + HTTPMethod: "POST", + HTTPPath: "/", + Paginator: &request.Paginator{ + InputTokens: []string{"NextToken"}, + OutputTokens: []string{"NextToken"}, + LimitToken: "MaxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListChildrenInput{} + } + + output = &ListChildrenOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListChildren API operation for AWS Organizations. +// +// Lists all of the OUs or accounts that are contained in the specified parent +// OU or root. This operation, along with ListParents enables you to traverse +// the tree structure that makes up this root. +// +// Always check the NextToken response parameter for a null value when calling +// a List* operation. These operations can occasionally return an empty set +// of results even when there are more results available. The NextToken response +// parameter value is nullonly when there are no more results to display. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation ListChildren for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeParentNotFoundException "ParentNotFoundException" +// We can't find a root or organizational unit (OU) with the ParentId that you +// specified. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListChildren +func (c *Organizations) ListChildren(input *ListChildrenInput) (*ListChildrenOutput, error) { + req, out := c.ListChildrenRequest(input) + return out, req.Send() +} + +// ListChildrenWithContext is the same as ListChildren with the addition of +// the ability to pass a context and additional request options. +// +// See ListChildren for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListChildrenWithContext(ctx aws.Context, input *ListChildrenInput, opts ...request.Option) (*ListChildrenOutput, error) { + req, out := c.ListChildrenRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListChildrenPages iterates over the pages of a ListChildren operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListChildren method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListChildren operation. +// pageNum := 0 +// err := client.ListChildrenPages(params, +// func(page *ListChildrenOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *Organizations) ListChildrenPages(input *ListChildrenInput, fn func(*ListChildrenOutput, bool) bool) error { + return c.ListChildrenPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListChildrenPagesWithContext same as ListChildrenPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListChildrenPagesWithContext(ctx aws.Context, input *ListChildrenInput, fn func(*ListChildrenOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListChildrenInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListChildrenRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListChildrenOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListCreateAccountStatus = "ListCreateAccountStatus" + +// ListCreateAccountStatusRequest generates a "aws/request.Request" representing the +// client's request for the ListCreateAccountStatus operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListCreateAccountStatus for more information on using the ListCreateAccountStatus +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListCreateAccountStatusRequest method. +// req, resp := client.ListCreateAccountStatusRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListCreateAccountStatus +func (c *Organizations) ListCreateAccountStatusRequest(input *ListCreateAccountStatusInput) (req *request.Request, output *ListCreateAccountStatusOutput) { + op := &request.Operation{ + Name: opListCreateAccountStatus, + HTTPMethod: "POST", + HTTPPath: "/", + Paginator: &request.Paginator{ + InputTokens: []string{"NextToken"}, + OutputTokens: []string{"NextToken"}, + LimitToken: "MaxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListCreateAccountStatusInput{} + } + + output = &ListCreateAccountStatusOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListCreateAccountStatus API operation for AWS Organizations. +// +// Lists the account creation requests that match the specified status that +// is currently being tracked for the organization. +// +// Always check the NextToken response parameter for a null value when calling +// a List* operation. These operations can occasionally return an empty set +// of results even when there are more results available. The NextToken response +// parameter value is nullonly when there are no more results to display. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation ListCreateAccountStatus for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListCreateAccountStatus +func (c *Organizations) ListCreateAccountStatus(input *ListCreateAccountStatusInput) (*ListCreateAccountStatusOutput, error) { + req, out := c.ListCreateAccountStatusRequest(input) + return out, req.Send() +} + +// ListCreateAccountStatusWithContext is the same as ListCreateAccountStatus with the addition of +// the ability to pass a context and additional request options. +// +// See ListCreateAccountStatus for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListCreateAccountStatusWithContext(ctx aws.Context, input *ListCreateAccountStatusInput, opts ...request.Option) (*ListCreateAccountStatusOutput, error) { + req, out := c.ListCreateAccountStatusRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListCreateAccountStatusPages iterates over the pages of a ListCreateAccountStatus operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListCreateAccountStatus method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListCreateAccountStatus operation. +// pageNum := 0 +// err := client.ListCreateAccountStatusPages(params, +// func(page *ListCreateAccountStatusOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *Organizations) ListCreateAccountStatusPages(input *ListCreateAccountStatusInput, fn func(*ListCreateAccountStatusOutput, bool) bool) error { + return c.ListCreateAccountStatusPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListCreateAccountStatusPagesWithContext same as ListCreateAccountStatusPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListCreateAccountStatusPagesWithContext(ctx aws.Context, input *ListCreateAccountStatusInput, fn func(*ListCreateAccountStatusOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListCreateAccountStatusInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListCreateAccountStatusRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListCreateAccountStatusOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListHandshakesForAccount = "ListHandshakesForAccount" + +// ListHandshakesForAccountRequest generates a "aws/request.Request" representing the +// client's request for the ListHandshakesForAccount operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListHandshakesForAccount for more information on using the ListHandshakesForAccount +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListHandshakesForAccountRequest method. +// req, resp := client.ListHandshakesForAccountRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListHandshakesForAccount +func (c *Organizations) ListHandshakesForAccountRequest(input *ListHandshakesForAccountInput) (req *request.Request, output *ListHandshakesForAccountOutput) { + op := &request.Operation{ + Name: opListHandshakesForAccount, + HTTPMethod: "POST", + HTTPPath: "/", + Paginator: &request.Paginator{ + InputTokens: []string{"NextToken"}, + OutputTokens: []string{"NextToken"}, + LimitToken: "MaxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListHandshakesForAccountInput{} + } + + output = &ListHandshakesForAccountOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListHandshakesForAccount API operation for AWS Organizations. +// +// Lists the current handshakes that are associated with the account of the +// requesting user. +// +// Handshakes that are ACCEPTED, DECLINED, or CANCELED appear in the results +// of this API for only 30 days after changing to that state. After that they +// are deleted and no longer accessible. +// +// Always check the NextToken response parameter for a null value when calling +// a List* operation. These operations can occasionally return an empty set +// of results even when there are more results available. The NextToken response +// parameter value is nullonly when there are no more results to display. +// +// This operation can be called from any account in the organization. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation ListHandshakesForAccount for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListHandshakesForAccount +func (c *Organizations) ListHandshakesForAccount(input *ListHandshakesForAccountInput) (*ListHandshakesForAccountOutput, error) { + req, out := c.ListHandshakesForAccountRequest(input) + return out, req.Send() +} + +// ListHandshakesForAccountWithContext is the same as ListHandshakesForAccount with the addition of +// the ability to pass a context and additional request options. +// +// See ListHandshakesForAccount for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListHandshakesForAccountWithContext(ctx aws.Context, input *ListHandshakesForAccountInput, opts ...request.Option) (*ListHandshakesForAccountOutput, error) { + req, out := c.ListHandshakesForAccountRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListHandshakesForAccountPages iterates over the pages of a ListHandshakesForAccount operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListHandshakesForAccount method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListHandshakesForAccount operation. +// pageNum := 0 +// err := client.ListHandshakesForAccountPages(params, +// func(page *ListHandshakesForAccountOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *Organizations) ListHandshakesForAccountPages(input *ListHandshakesForAccountInput, fn func(*ListHandshakesForAccountOutput, bool) bool) error { + return c.ListHandshakesForAccountPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListHandshakesForAccountPagesWithContext same as ListHandshakesForAccountPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListHandshakesForAccountPagesWithContext(ctx aws.Context, input *ListHandshakesForAccountInput, fn func(*ListHandshakesForAccountOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListHandshakesForAccountInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListHandshakesForAccountRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListHandshakesForAccountOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListHandshakesForOrganization = "ListHandshakesForOrganization" + +// ListHandshakesForOrganizationRequest generates a "aws/request.Request" representing the +// client's request for the ListHandshakesForOrganization operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListHandshakesForOrganization for more information on using the ListHandshakesForOrganization +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListHandshakesForOrganizationRequest method. +// req, resp := client.ListHandshakesForOrganizationRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListHandshakesForOrganization +func (c *Organizations) ListHandshakesForOrganizationRequest(input *ListHandshakesForOrganizationInput) (req *request.Request, output *ListHandshakesForOrganizationOutput) { + op := &request.Operation{ + Name: opListHandshakesForOrganization, + HTTPMethod: "POST", + HTTPPath: "/", + Paginator: &request.Paginator{ + InputTokens: []string{"NextToken"}, + OutputTokens: []string{"NextToken"}, + LimitToken: "MaxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListHandshakesForOrganizationInput{} + } + + output = &ListHandshakesForOrganizationOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListHandshakesForOrganization API operation for AWS Organizations. +// +// Lists the handshakes that are associated with the organization that the requesting +// user is part of. The ListHandshakesForOrganization operation returns a list +// of handshake structures. Each structure contains details and status about +// a handshake. +// +// Handshakes that are ACCEPTED, DECLINED, or CANCELED appear in the results +// of this API for only 30 days after changing to that state. After that they +// are deleted and no longer accessible. +// +// Always check the NextToken response parameter for a null value when calling +// a List* operation. These operations can occasionally return an empty set +// of results even when there are more results available. The NextToken response +// parameter value is nullonly when there are no more results to display. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation ListHandshakesForOrganization for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListHandshakesForOrganization +func (c *Organizations) ListHandshakesForOrganization(input *ListHandshakesForOrganizationInput) (*ListHandshakesForOrganizationOutput, error) { + req, out := c.ListHandshakesForOrganizationRequest(input) + return out, req.Send() +} + +// ListHandshakesForOrganizationWithContext is the same as ListHandshakesForOrganization with the addition of +// the ability to pass a context and additional request options. +// +// See ListHandshakesForOrganization for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListHandshakesForOrganizationWithContext(ctx aws.Context, input *ListHandshakesForOrganizationInput, opts ...request.Option) (*ListHandshakesForOrganizationOutput, error) { + req, out := c.ListHandshakesForOrganizationRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListHandshakesForOrganizationPages iterates over the pages of a ListHandshakesForOrganization operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListHandshakesForOrganization method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListHandshakesForOrganization operation. +// pageNum := 0 +// err := client.ListHandshakesForOrganizationPages(params, +// func(page *ListHandshakesForOrganizationOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *Organizations) ListHandshakesForOrganizationPages(input *ListHandshakesForOrganizationInput, fn func(*ListHandshakesForOrganizationOutput, bool) bool) error { + return c.ListHandshakesForOrganizationPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListHandshakesForOrganizationPagesWithContext same as ListHandshakesForOrganizationPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListHandshakesForOrganizationPagesWithContext(ctx aws.Context, input *ListHandshakesForOrganizationInput, fn func(*ListHandshakesForOrganizationOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListHandshakesForOrganizationInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListHandshakesForOrganizationRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListHandshakesForOrganizationOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListOrganizationalUnitsForParent = "ListOrganizationalUnitsForParent" + +// ListOrganizationalUnitsForParentRequest generates a "aws/request.Request" representing the +// client's request for the ListOrganizationalUnitsForParent operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListOrganizationalUnitsForParent for more information on using the ListOrganizationalUnitsForParent +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListOrganizationalUnitsForParentRequest method. +// req, resp := client.ListOrganizationalUnitsForParentRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListOrganizationalUnitsForParent +func (c *Organizations) ListOrganizationalUnitsForParentRequest(input *ListOrganizationalUnitsForParentInput) (req *request.Request, output *ListOrganizationalUnitsForParentOutput) { + op := &request.Operation{ + Name: opListOrganizationalUnitsForParent, + HTTPMethod: "POST", + HTTPPath: "/", + Paginator: &request.Paginator{ + InputTokens: []string{"NextToken"}, + OutputTokens: []string{"NextToken"}, + LimitToken: "MaxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListOrganizationalUnitsForParentInput{} + } + + output = &ListOrganizationalUnitsForParentOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListOrganizationalUnitsForParent API operation for AWS Organizations. +// +// Lists the organizational units (OUs) in a parent organizational unit or root. +// +// Always check the NextToken response parameter for a null value when calling +// a List* operation. These operations can occasionally return an empty set +// of results even when there are more results available. The NextToken response +// parameter value is nullonly when there are no more results to display. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation ListOrganizationalUnitsForParent for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeParentNotFoundException "ParentNotFoundException" +// We can't find a root or organizational unit (OU) with the ParentId that you +// specified. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListOrganizationalUnitsForParent +func (c *Organizations) ListOrganizationalUnitsForParent(input *ListOrganizationalUnitsForParentInput) (*ListOrganizationalUnitsForParentOutput, error) { + req, out := c.ListOrganizationalUnitsForParentRequest(input) + return out, req.Send() +} + +// ListOrganizationalUnitsForParentWithContext is the same as ListOrganizationalUnitsForParent with the addition of +// the ability to pass a context and additional request options. +// +// See ListOrganizationalUnitsForParent for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListOrganizationalUnitsForParentWithContext(ctx aws.Context, input *ListOrganizationalUnitsForParentInput, opts ...request.Option) (*ListOrganizationalUnitsForParentOutput, error) { + req, out := c.ListOrganizationalUnitsForParentRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListOrganizationalUnitsForParentPages iterates over the pages of a ListOrganizationalUnitsForParent operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListOrganizationalUnitsForParent method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListOrganizationalUnitsForParent operation. +// pageNum := 0 +// err := client.ListOrganizationalUnitsForParentPages(params, +// func(page *ListOrganizationalUnitsForParentOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *Organizations) ListOrganizationalUnitsForParentPages(input *ListOrganizationalUnitsForParentInput, fn func(*ListOrganizationalUnitsForParentOutput, bool) bool) error { + return c.ListOrganizationalUnitsForParentPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListOrganizationalUnitsForParentPagesWithContext same as ListOrganizationalUnitsForParentPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListOrganizationalUnitsForParentPagesWithContext(ctx aws.Context, input *ListOrganizationalUnitsForParentInput, fn func(*ListOrganizationalUnitsForParentOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListOrganizationalUnitsForParentInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListOrganizationalUnitsForParentRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListOrganizationalUnitsForParentOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListParents = "ListParents" + +// ListParentsRequest generates a "aws/request.Request" representing the +// client's request for the ListParents operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListParents for more information on using the ListParents +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListParentsRequest method. +// req, resp := client.ListParentsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListParents +func (c *Organizations) ListParentsRequest(input *ListParentsInput) (req *request.Request, output *ListParentsOutput) { + op := &request.Operation{ + Name: opListParents, + HTTPMethod: "POST", + HTTPPath: "/", + Paginator: &request.Paginator{ + InputTokens: []string{"NextToken"}, + OutputTokens: []string{"NextToken"}, + LimitToken: "MaxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListParentsInput{} + } + + output = &ListParentsOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListParents API operation for AWS Organizations. +// +// Lists the root or organizational units (OUs) that serve as the immediate +// parent of the specified child OU or account. This operation, along with ListChildren +// enables you to traverse the tree structure that makes up this root. +// +// Always check the NextToken response parameter for a null value when calling +// a List* operation. These operations can occasionally return an empty set +// of results even when there are more results available. The NextToken response +// parameter value is nullonly when there are no more results to display. +// +// This operation can be called only from the organization's master account. +// +// In the current release, a child can have only a single parent. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation ListParents for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeChildNotFoundException "ChildNotFoundException" +// We can't find an organizational unit (OU) or AWS account with the ChildId +// that you specified. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListParents +func (c *Organizations) ListParents(input *ListParentsInput) (*ListParentsOutput, error) { + req, out := c.ListParentsRequest(input) + return out, req.Send() +} + +// ListParentsWithContext is the same as ListParents with the addition of +// the ability to pass a context and additional request options. +// +// See ListParents for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListParentsWithContext(ctx aws.Context, input *ListParentsInput, opts ...request.Option) (*ListParentsOutput, error) { + req, out := c.ListParentsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListParentsPages iterates over the pages of a ListParents operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListParents method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListParents operation. +// pageNum := 0 +// err := client.ListParentsPages(params, +// func(page *ListParentsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *Organizations) ListParentsPages(input *ListParentsInput, fn func(*ListParentsOutput, bool) bool) error { + return c.ListParentsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListParentsPagesWithContext same as ListParentsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListParentsPagesWithContext(ctx aws.Context, input *ListParentsInput, fn func(*ListParentsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListParentsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListParentsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListParentsOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListPolicies = "ListPolicies" + +// ListPoliciesRequest generates a "aws/request.Request" representing the +// client's request for the ListPolicies operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListPolicies for more information on using the ListPolicies +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListPoliciesRequest method. +// req, resp := client.ListPoliciesRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListPolicies +func (c *Organizations) ListPoliciesRequest(input *ListPoliciesInput) (req *request.Request, output *ListPoliciesOutput) { + op := &request.Operation{ + Name: opListPolicies, + HTTPMethod: "POST", + HTTPPath: "/", + Paginator: &request.Paginator{ + InputTokens: []string{"NextToken"}, + OutputTokens: []string{"NextToken"}, + LimitToken: "MaxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListPoliciesInput{} + } + + output = &ListPoliciesOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListPolicies API operation for AWS Organizations. +// +// Retrieves the list of all policies in an organization of a specified type. +// +// Always check the NextToken response parameter for a null value when calling +// a List* operation. These operations can occasionally return an empty set +// of results even when there are more results available. The NextToken response +// parameter value is nullonly when there are no more results to display. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation ListPolicies for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListPolicies +func (c *Organizations) ListPolicies(input *ListPoliciesInput) (*ListPoliciesOutput, error) { + req, out := c.ListPoliciesRequest(input) + return out, req.Send() +} + +// ListPoliciesWithContext is the same as ListPolicies with the addition of +// the ability to pass a context and additional request options. +// +// See ListPolicies for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListPoliciesWithContext(ctx aws.Context, input *ListPoliciesInput, opts ...request.Option) (*ListPoliciesOutput, error) { + req, out := c.ListPoliciesRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListPoliciesPages iterates over the pages of a ListPolicies operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListPolicies method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListPolicies operation. +// pageNum := 0 +// err := client.ListPoliciesPages(params, +// func(page *ListPoliciesOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *Organizations) ListPoliciesPages(input *ListPoliciesInput, fn func(*ListPoliciesOutput, bool) bool) error { + return c.ListPoliciesPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListPoliciesPagesWithContext same as ListPoliciesPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListPoliciesPagesWithContext(ctx aws.Context, input *ListPoliciesInput, fn func(*ListPoliciesOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListPoliciesInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListPoliciesRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListPoliciesOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListPoliciesForTarget = "ListPoliciesForTarget" + +// ListPoliciesForTargetRequest generates a "aws/request.Request" representing the +// client's request for the ListPoliciesForTarget operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListPoliciesForTarget for more information on using the ListPoliciesForTarget +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListPoliciesForTargetRequest method. +// req, resp := client.ListPoliciesForTargetRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListPoliciesForTarget +func (c *Organizations) ListPoliciesForTargetRequest(input *ListPoliciesForTargetInput) (req *request.Request, output *ListPoliciesForTargetOutput) { + op := &request.Operation{ + Name: opListPoliciesForTarget, + HTTPMethod: "POST", + HTTPPath: "/", + Paginator: &request.Paginator{ + InputTokens: []string{"NextToken"}, + OutputTokens: []string{"NextToken"}, + LimitToken: "MaxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListPoliciesForTargetInput{} + } + + output = &ListPoliciesForTargetOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListPoliciesForTarget API operation for AWS Organizations. +// +// Lists the policies that are directly attached to the specified target root, +// organizational unit (OU), or account. You must specify the policy type that +// you want included in the returned list. +// +// Always check the NextToken response parameter for a null value when calling +// a List* operation. These operations can occasionally return an empty set +// of results even when there are more results available. The NextToken response +// parameter value is nullonly when there are no more results to display. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation ListPoliciesForTarget for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTargetNotFoundException "TargetNotFoundException" +// We can't find a root, OU, or account with the TargetId that you specified. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListPoliciesForTarget +func (c *Organizations) ListPoliciesForTarget(input *ListPoliciesForTargetInput) (*ListPoliciesForTargetOutput, error) { + req, out := c.ListPoliciesForTargetRequest(input) + return out, req.Send() +} + +// ListPoliciesForTargetWithContext is the same as ListPoliciesForTarget with the addition of +// the ability to pass a context and additional request options. +// +// See ListPoliciesForTarget for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListPoliciesForTargetWithContext(ctx aws.Context, input *ListPoliciesForTargetInput, opts ...request.Option) (*ListPoliciesForTargetOutput, error) { + req, out := c.ListPoliciesForTargetRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListPoliciesForTargetPages iterates over the pages of a ListPoliciesForTarget operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListPoliciesForTarget method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListPoliciesForTarget operation. +// pageNum := 0 +// err := client.ListPoliciesForTargetPages(params, +// func(page *ListPoliciesForTargetOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *Organizations) ListPoliciesForTargetPages(input *ListPoliciesForTargetInput, fn func(*ListPoliciesForTargetOutput, bool) bool) error { + return c.ListPoliciesForTargetPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListPoliciesForTargetPagesWithContext same as ListPoliciesForTargetPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListPoliciesForTargetPagesWithContext(ctx aws.Context, input *ListPoliciesForTargetInput, fn func(*ListPoliciesForTargetOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListPoliciesForTargetInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListPoliciesForTargetRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListPoliciesForTargetOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListRoots = "ListRoots" + +// ListRootsRequest generates a "aws/request.Request" representing the +// client's request for the ListRoots operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListRoots for more information on using the ListRoots +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListRootsRequest method. +// req, resp := client.ListRootsRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListRoots +func (c *Organizations) ListRootsRequest(input *ListRootsInput) (req *request.Request, output *ListRootsOutput) { + op := &request.Operation{ + Name: opListRoots, + HTTPMethod: "POST", + HTTPPath: "/", + Paginator: &request.Paginator{ + InputTokens: []string{"NextToken"}, + OutputTokens: []string{"NextToken"}, + LimitToken: "MaxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListRootsInput{} + } + + output = &ListRootsOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListRoots API operation for AWS Organizations. +// +// Lists the roots that are defined in the current organization. +// +// Always check the NextToken response parameter for a null value when calling +// a List* operation. These operations can occasionally return an empty set +// of results even when there are more results available. The NextToken response +// parameter value is nullonly when there are no more results to display. +// +// This operation can be called only from the organization's master account. +// +// Policy types can be enabled and disabled in roots. This is distinct from +// whether they are available in the organization. When you enable all features, +// you make policy types available for use in that organization. Individual +// policy types can then be enabled and disabled in a root. To see the availability +// of a policy type in an organization, use DescribeOrganization. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation ListRoots for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListRoots +func (c *Organizations) ListRoots(input *ListRootsInput) (*ListRootsOutput, error) { + req, out := c.ListRootsRequest(input) + return out, req.Send() +} + +// ListRootsWithContext is the same as ListRoots with the addition of +// the ability to pass a context and additional request options. +// +// See ListRoots for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListRootsWithContext(ctx aws.Context, input *ListRootsInput, opts ...request.Option) (*ListRootsOutput, error) { + req, out := c.ListRootsRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListRootsPages iterates over the pages of a ListRoots operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListRoots method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListRoots operation. +// pageNum := 0 +// err := client.ListRootsPages(params, +// func(page *ListRootsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *Organizations) ListRootsPages(input *ListRootsInput, fn func(*ListRootsOutput, bool) bool) error { + return c.ListRootsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListRootsPagesWithContext same as ListRootsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListRootsPagesWithContext(ctx aws.Context, input *ListRootsInput, fn func(*ListRootsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListRootsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListRootsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListRootsOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opListTargetsForPolicy = "ListTargetsForPolicy" + +// ListTargetsForPolicyRequest generates a "aws/request.Request" representing the +// client's request for the ListTargetsForPolicy operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListTargetsForPolicy for more information on using the ListTargetsForPolicy +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListTargetsForPolicyRequest method. +// req, resp := client.ListTargetsForPolicyRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListTargetsForPolicy +func (c *Organizations) ListTargetsForPolicyRequest(input *ListTargetsForPolicyInput) (req *request.Request, output *ListTargetsForPolicyOutput) { + op := &request.Operation{ + Name: opListTargetsForPolicy, + HTTPMethod: "POST", + HTTPPath: "/", + Paginator: &request.Paginator{ + InputTokens: []string{"NextToken"}, + OutputTokens: []string{"NextToken"}, + LimitToken: "MaxResults", + TruncationToken: "", + }, + } + + if input == nil { + input = &ListTargetsForPolicyInput{} + } + + output = &ListTargetsForPolicyOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListTargetsForPolicy API operation for AWS Organizations. +// +// Lists all the roots, OUs, and accounts to which the specified policy is attached. +// +// Always check the NextToken response parameter for a null value when calling +// a List* operation. These operations can occasionally return an empty set +// of results even when there are more results available. The NextToken response +// parameter value is nullonly when there are no more results to display. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation ListTargetsForPolicy for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodePolicyNotFoundException "PolicyNotFoundException" +// We can't find a policy with the PolicyId that you specified. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/ListTargetsForPolicy +func (c *Organizations) ListTargetsForPolicy(input *ListTargetsForPolicyInput) (*ListTargetsForPolicyOutput, error) { + req, out := c.ListTargetsForPolicyRequest(input) + return out, req.Send() +} + +// ListTargetsForPolicyWithContext is the same as ListTargetsForPolicy with the addition of +// the ability to pass a context and additional request options. +// +// See ListTargetsForPolicy for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListTargetsForPolicyWithContext(ctx aws.Context, input *ListTargetsForPolicyInput, opts ...request.Option) (*ListTargetsForPolicyOutput, error) { + req, out := c.ListTargetsForPolicyRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// ListTargetsForPolicyPages iterates over the pages of a ListTargetsForPolicy operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListTargetsForPolicy method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListTargetsForPolicy operation. +// pageNum := 0 +// err := client.ListTargetsForPolicyPages(params, +// func(page *ListTargetsForPolicyOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +// +func (c *Organizations) ListTargetsForPolicyPages(input *ListTargetsForPolicyInput, fn func(*ListTargetsForPolicyOutput, bool) bool) error { + return c.ListTargetsForPolicyPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListTargetsForPolicyPagesWithContext same as ListTargetsForPolicyPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) ListTargetsForPolicyPagesWithContext(ctx aws.Context, input *ListTargetsForPolicyInput, fn func(*ListTargetsForPolicyOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListTargetsForPolicyInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListTargetsForPolicyRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + cont := true + for p.Next() && cont { + cont = fn(p.Page().(*ListTargetsForPolicyOutput), !p.HasNextPage()) + } + return p.Err() +} + +const opMoveAccount = "MoveAccount" + +// MoveAccountRequest generates a "aws/request.Request" representing the +// client's request for the MoveAccount operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See MoveAccount for more information on using the MoveAccount +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the MoveAccountRequest method. +// req, resp := client.MoveAccountRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/MoveAccount +func (c *Organizations) MoveAccountRequest(input *MoveAccountInput) (req *request.Request, output *MoveAccountOutput) { + op := &request.Operation{ + Name: opMoveAccount, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &MoveAccountInput{} + } + + output = &MoveAccountOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// MoveAccount API operation for AWS Organizations. +// +// Moves an account from its current source parent root or OU to the specified +// destination parent root or OU. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation MoveAccount for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeSourceParentNotFoundException "SourceParentNotFoundException" +// We can't find a source root or OU with the ParentId that you specified. +// +// * ErrCodeDestinationParentNotFoundException "DestinationParentNotFoundException" +// We can't find the destination container (a root or OU) with the ParentId +// that you specified. +// +// * ErrCodeDuplicateAccountException "DuplicateAccountException" +// That account is already present in the specified destination. +// +// * ErrCodeAccountNotFoundException "AccountNotFoundException" +// We can't find an AWS account with the AccountId that you specified, or the +// account whose credentials you used to make this request is not a member of +// an organization. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/MoveAccount +func (c *Organizations) MoveAccount(input *MoveAccountInput) (*MoveAccountOutput, error) { + req, out := c.MoveAccountRequest(input) + return out, req.Send() +} + +// MoveAccountWithContext is the same as MoveAccount with the addition of +// the ability to pass a context and additional request options. +// +// See MoveAccount for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) MoveAccountWithContext(ctx aws.Context, input *MoveAccountInput, opts ...request.Option) (*MoveAccountOutput, error) { + req, out := c.MoveAccountRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opRemoveAccountFromOrganization = "RemoveAccountFromOrganization" + +// RemoveAccountFromOrganizationRequest generates a "aws/request.Request" representing the +// client's request for the RemoveAccountFromOrganization operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See RemoveAccountFromOrganization for more information on using the RemoveAccountFromOrganization +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the RemoveAccountFromOrganizationRequest method. +// req, resp := client.RemoveAccountFromOrganizationRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/RemoveAccountFromOrganization +func (c *Organizations) RemoveAccountFromOrganizationRequest(input *RemoveAccountFromOrganizationInput) (req *request.Request, output *RemoveAccountFromOrganizationOutput) { + op := &request.Operation{ + Name: opRemoveAccountFromOrganization, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &RemoveAccountFromOrganizationInput{} + } + + output = &RemoveAccountFromOrganizationOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// RemoveAccountFromOrganization API operation for AWS Organizations. +// +// Removes the specified account from the organization. +// +// The removed account becomes a stand-alone account that is not a member of +// any organization. It is no longer subject to any policies and is responsible +// for its own bill payments. The organization's master account is no longer +// charged for any expenses accrued by the member account after it is removed +// from the organization. +// +// This operation can be called only from the organization's master account. +// Member accounts can remove themselves with LeaveOrganization instead. +// +// You can remove an account from your organization only if the account is configured +// with the information required to operate as a standalone account. When you +// create an account in an organization using the AWS Organizations console, +// API, or CLI commands, the information required of standalone accounts is +// not automatically collected. For an account that you want to make standalone, +// you must accept the End User License Agreement (EULA), choose a support plan, +// provide and verify the required contact information, and provide a current +// payment method. AWS uses the payment method to charge for any billable (not +// free tier) AWS activity that occurs while the account is not attached to +// an organization. To remove an account that does not yet have this information, +// you must sign in as the member account and follow the steps at To leave +// an organization when all required account information has not yet been provided +// (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// You can remove a member account only after you enable IAM user access to +// billing in the member account. For more information, see Activating Access +// to the Billing and Cost Management Console (http://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/grantaccess.html#ControllingAccessWebsite-Activate) +// in the AWS Billing and Cost Management User Guide. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation RemoveAccountFromOrganization for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAccountNotFoundException "AccountNotFoundException" +// We can't find an AWS account with the AccountId that you specified, or the +// account whose credentials you used to make this request is not a member of +// an organization. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeConstraintViolationException "ConstraintViolationException" +// Performing this operation violates a minimum or maximum value limit. For +// example, attempting to removing the last SCP from an OU or root, inviting +// or creating too many accounts to the organization, or attaching too many +// policies to an account, OU, or root. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on the number +// of accounts in an organization. If you need more accounts, contact AWS Support +// to request an increase in your limit. +// +// Or, The number of invitations that you tried to send would cause you to exceed +// the limit of accounts in your organization. Send fewer invitations, or contact +// AWS Support to request an increase in the number of accounts. +// +// Note: deleted and closed accounts still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * OU_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the number of organizational +// units you can have in an organization. +// +// * OU_DEPTH_LIMIT_EXCEEDED: You attempted to create an organizational unit +// tree that is too many levels deep. +// +// * POLICY_NUMBER_LIMIT_EXCEEDED. You attempted to exceed the number of +// policies that you can have in an organization. +// +// * MAX_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to exceed the +// number of policies of a certain type that can be attached to an entity +// at one time. +// +// * MIN_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to detach a +// policy from an entity that would cause the entity to have fewer than the +// minimum number of policies of a certain type required. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_EULA: You attempted to remove an account +// from the organization that does not yet have enough information to exist +// as a stand-alone account. This account requires you to first agree to +// the AWS Customer Agreement. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_PHONE_VERIFICATION: You attempted to remove +// an account from the organization that does not yet have enough information +// to exist as a stand-alone account. This account requires you to first +// complete phone verification. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MASTER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To create an organization +// with this account, you first must associate a payment instrument, such +// as a credit card, with the account. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MEMBER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To complete this operation +// with this member account, you first must associate a payment instrument, +// such as a credit card, with the account. Follow the steps at To leave +// an organization when all required account information has not yet been +// provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CREATION_RATE_LIMIT_EXCEEDED: You attempted to exceed the number +// of accounts that you can create in one day. +// +// * MASTER_ACCOUNT_ADDRESS_DOES_NOT_MATCH_MARKETPLACE: To create an account +// in this organization, you first must migrate the organization's master +// account to the marketplace that corresponds to the master account's address. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be associated +// with the same marketplace. +// +// * MASTER_ACCOUNT_MISSING_CONTACT_INFO: To complete this operation, you +// must first provide contact a valid address and phone number for the master +// account. Then try the operation again. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeMasterCannotLeaveOrganizationException "MasterCannotLeaveOrganizationException" +// You can't remove a master account from an organization. If you want the master +// account to become a member account in another organization, you must first +// delete the current organization of the master account. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/RemoveAccountFromOrganization +func (c *Organizations) RemoveAccountFromOrganization(input *RemoveAccountFromOrganizationInput) (*RemoveAccountFromOrganizationOutput, error) { + req, out := c.RemoveAccountFromOrganizationRequest(input) + return out, req.Send() +} + +// RemoveAccountFromOrganizationWithContext is the same as RemoveAccountFromOrganization with the addition of +// the ability to pass a context and additional request options. +// +// See RemoveAccountFromOrganization for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) RemoveAccountFromOrganizationWithContext(ctx aws.Context, input *RemoveAccountFromOrganizationInput, opts ...request.Option) (*RemoveAccountFromOrganizationOutput, error) { + req, out := c.RemoveAccountFromOrganizationRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateOrganizationalUnit = "UpdateOrganizationalUnit" + +// UpdateOrganizationalUnitRequest generates a "aws/request.Request" representing the +// client's request for the UpdateOrganizationalUnit operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateOrganizationalUnit for more information on using the UpdateOrganizationalUnit +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the UpdateOrganizationalUnitRequest method. +// req, resp := client.UpdateOrganizationalUnitRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/UpdateOrganizationalUnit +func (c *Organizations) UpdateOrganizationalUnitRequest(input *UpdateOrganizationalUnitInput) (req *request.Request, output *UpdateOrganizationalUnitOutput) { + op := &request.Operation{ + Name: opUpdateOrganizationalUnit, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &UpdateOrganizationalUnitInput{} + } + + output = &UpdateOrganizationalUnitOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateOrganizationalUnit API operation for AWS Organizations. +// +// Renames the specified organizational unit (OU). The ID and ARN do not change. +// The child OUs and accounts remain in place, and any attached policies of +// the OU remain attached. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation UpdateOrganizationalUnit for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeDuplicateOrganizationalUnitException "DuplicateOrganizationalUnitException" +// An organizational unit (OU) with the same name already exists. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeOrganizationalUnitNotFoundException "OrganizationalUnitNotFoundException" +// We can't find an organizational unit (OU) with the OrganizationalUnitId that +// you specified. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/UpdateOrganizationalUnit +func (c *Organizations) UpdateOrganizationalUnit(input *UpdateOrganizationalUnitInput) (*UpdateOrganizationalUnitOutput, error) { + req, out := c.UpdateOrganizationalUnitRequest(input) + return out, req.Send() +} + +// UpdateOrganizationalUnitWithContext is the same as UpdateOrganizationalUnit with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateOrganizationalUnit for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) UpdateOrganizationalUnitWithContext(ctx aws.Context, input *UpdateOrganizationalUnitInput, opts ...request.Option) (*UpdateOrganizationalUnitOutput, error) { + req, out := c.UpdateOrganizationalUnitRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdatePolicy = "UpdatePolicy" + +// UpdatePolicyRequest generates a "aws/request.Request" representing the +// client's request for the UpdatePolicy operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdatePolicy for more information on using the UpdatePolicy +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the UpdatePolicyRequest method. +// req, resp := client.UpdatePolicyRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/UpdatePolicy +func (c *Organizations) UpdatePolicyRequest(input *UpdatePolicyInput) (req *request.Request, output *UpdatePolicyOutput) { + op := &request.Operation{ + Name: opUpdatePolicy, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &UpdatePolicyInput{} + } + + output = &UpdatePolicyOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdatePolicy API operation for AWS Organizations. +// +// Updates an existing policy with a new name, description, or content. If any +// parameter is not supplied, that value remains unchanged. Note that you cannot +// change a policy's type. +// +// This operation can be called only from the organization's master account. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Organizations's +// API operation UpdatePolicy for usage and error information. +// +// Returned Error Codes: +// * ErrCodeAccessDeniedException "AccessDeniedException" +// You don't have permissions to perform the requested operation. The user or +// role that is making the request must have at least one IAM permissions policy +// attached that grants the required permissions. For more information, see +// Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) +// in the IAM User Guide. +// +// * ErrCodeAWSOrganizationsNotInUseException "AWSOrganizationsNotInUseException" +// Your account is not a member of an organization. To make this request, you +// must use the credentials of an account that belongs to an organization. +// +// * ErrCodeConcurrentModificationException "ConcurrentModificationException" +// The target of the operation is currently being modified by a different request. +// Try again later. +// +// * ErrCodeConstraintViolationException "ConstraintViolationException" +// Performing this operation violates a minimum or maximum value limit. For +// example, attempting to removing the last SCP from an OU or root, inviting +// or creating too many accounts to the organization, or attaching too many +// policies to an account, OU, or root. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on the number +// of accounts in an organization. If you need more accounts, contact AWS Support +// to request an increase in your limit. +// +// Or, The number of invitations that you tried to send would cause you to exceed +// the limit of accounts in your organization. Send fewer invitations, or contact +// AWS Support to request an increase in the number of accounts. +// +// Note: deleted and closed accounts still count toward your limit. +// +// If you get an exception that indicates that you exceeded your account limits +// for the organization or that you can"t add an account because your organization +// is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). +// +// * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of +// handshakes you can send in one day. +// +// * OU_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the number of organizational +// units you can have in an organization. +// +// * OU_DEPTH_LIMIT_EXCEEDED: You attempted to create an organizational unit +// tree that is too many levels deep. +// +// * POLICY_NUMBER_LIMIT_EXCEEDED. You attempted to exceed the number of +// policies that you can have in an organization. +// +// * MAX_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to exceed the +// number of policies of a certain type that can be attached to an entity +// at one time. +// +// * MIN_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to detach a +// policy from an entity that would cause the entity to have fewer than the +// minimum number of policies of a certain type required. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_EULA: You attempted to remove an account +// from the organization that does not yet have enough information to exist +// as a stand-alone account. This account requires you to first agree to +// the AWS Customer Agreement. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CANNOT_LEAVE_WITHOUT_PHONE_VERIFICATION: You attempted to remove +// an account from the organization that does not yet have enough information +// to exist as a stand-alone account. This account requires you to first +// complete phone verification. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MASTER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To create an organization +// with this account, you first must associate a payment instrument, such +// as a credit card, with the account. Follow the steps at To leave an organization +// when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * MEMBER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To complete this operation +// with this member account, you first must associate a payment instrument, +// such as a credit card, with the account. Follow the steps at To leave +// an organization when all required account information has not yet been +// provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) +// in the AWS Organizations User Guide. +// +// * ACCOUNT_CREATION_RATE_LIMIT_EXCEEDED: You attempted to exceed the number +// of accounts that you can create in one day. +// +// * MASTER_ACCOUNT_ADDRESS_DOES_NOT_MATCH_MARKETPLACE: To create an account +// in this organization, you first must migrate the organization's master +// account to the marketplace that corresponds to the master account's address. +// For example, accounts with India addresses must be associated with the +// AISPL marketplace. All accounts in an organization must be associated +// with the same marketplace. +// +// * MASTER_ACCOUNT_MISSING_CONTACT_INFO: To complete this operation, you +// must first provide contact a valid address and phone number for the master +// account. Then try the operation again. +// +// * ErrCodeDuplicatePolicyException "DuplicatePolicyException" +// A policy with the same name already exists. +// +// * ErrCodeInvalidInputException "InvalidInputException" +// The requested operation failed because you provided invalid values for one +// or more of the request parameters. This exception includes a reason that +// contains additional information about the violated limit: +// +// Some of the reasons in the following list might not be applicable to this +// specific API or operation: +// +// * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and +// cannot be modified. +// +// * INPUT_REQUIRED: You must include a value for all required parameters. +// +// * INVALID_ENUM: You specified a value that is not valid for that parameter. +// +// * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid +// characters. +// +// * INVALID_LIST_MEMBER: You provided a list to a parameter that contains +// at least one invalid value. +// +// * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, +// organization, or email) as a party. +// +// * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter +// from the response to a previous call of the operation. +// +// * INVALID_PATTERN: You provided a value that doesn't match the required +// pattern. +// +// * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't +// match the required pattern. +// +// * INVALID_ROLE_NAME: You provided a role name that is not valid. A role +// name can’t begin with the reserved prefix 'AWSServiceRoleFor'. +// +// * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the +// organization. +// +// * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. +// +// * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter +// for the operation. +// +// * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer +// than allowed. +// +// * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger +// value than allowed. +// +// * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter +// than allowed. +// +// * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller +// value than allowed. +// +// * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only +// between entities in the same root. +// +// * ErrCodeMalformedPolicyDocumentException "MalformedPolicyDocumentException" +// The provided policy document does not meet the requirements of the specified +// policy type. For example, the syntax might be incorrect. For details about +// service control policy syntax, see Service Control Policy Syntax (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_scp-syntax.html) +// in the AWS Organizations User Guide. +// +// * ErrCodePolicyNotFoundException "PolicyNotFoundException" +// We can't find a policy with the PolicyId that you specified. +// +// * ErrCodeServiceException "ServiceException" +// AWS Organizations can't complete your request because of an internal service +// error. Try again later. +// +// * ErrCodeTooManyRequestsException "TooManyRequestsException" +// You've sent too many requests in too short a period of time. The limit helps +// protect against denial-of-service attacks. Try again later. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28/UpdatePolicy +func (c *Organizations) UpdatePolicy(input *UpdatePolicyInput) (*UpdatePolicyOutput, error) { + req, out := c.UpdatePolicyRequest(input) + return out, req.Send() +} + +// UpdatePolicyWithContext is the same as UpdatePolicy with the addition of +// the ability to pass a context and additional request options. +// +// See UpdatePolicy for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *Organizations) UpdatePolicyWithContext(ctx aws.Context, input *UpdatePolicyInput, opts ...request.Option) (*UpdatePolicyOutput, error) { + req, out := c.UpdatePolicyRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +type AcceptHandshakeInput struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) of the handshake that you want to accept. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for handshake ID string + // requires "h-" followed by from 8 to 32 lower-case letters or digits. + // + // HandshakeId is a required field + HandshakeId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s AcceptHandshakeInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s AcceptHandshakeInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *AcceptHandshakeInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "AcceptHandshakeInput"} + if s.HandshakeId == nil { + invalidParams.Add(request.NewErrParamRequired("HandshakeId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetHandshakeId sets the HandshakeId field's value. +func (s *AcceptHandshakeInput) SetHandshakeId(v string) *AcceptHandshakeInput { + s.HandshakeId = &v + return s +} + +type AcceptHandshakeOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains details about the accepted handshake. + Handshake *Handshake `type:"structure"` +} + +// String returns the string representation +func (s AcceptHandshakeOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s AcceptHandshakeOutput) GoString() string { + return s.String() +} + +// SetHandshake sets the Handshake field's value. +func (s *AcceptHandshakeOutput) SetHandshake(v *Handshake) *AcceptHandshakeOutput { + s.Handshake = v + return s +} + +// Contains information about an AWS account that is a member of an organization. +type Account struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the account. + // + // For more information about ARNs in Organizations, see ARN Formats Supported + // by Organizations (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_permissions.html#orgs-permissions-arns) + // in the AWS Organizations User Guide. + Arn *string `type:"string"` + + // The email address associated with the AWS account. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for this parameter is + // a string of characters that represents a standard Internet email address. + Email *string `min:"6" type:"string"` + + // The unique identifier (ID) of the account. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for an account ID string + // requires exactly 12 digits. + Id *string `type:"string"` + + // The method by which the account joined the organization. + JoinedMethod *string `type:"string" enum:"AccountJoinedMethod"` + + // The date the account became a part of the organization. + JoinedTimestamp *time.Time `type:"timestamp" timestampFormat:"unix"` + + // The friendly name of the account. + // + // The regex pattern (http://wikipedia.org/wiki/regex) that is used to validate + // this parameter is a string of any of the characters in the ASCII character + // range. + Name *string `min:"1" type:"string"` + + // The status of the account in the organization. + Status *string `type:"string" enum:"AccountStatus"` +} + +// String returns the string representation +func (s Account) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s Account) GoString() string { + return s.String() +} + +// SetArn sets the Arn field's value. +func (s *Account) SetArn(v string) *Account { + s.Arn = &v + return s +} + +// SetEmail sets the Email field's value. +func (s *Account) SetEmail(v string) *Account { + s.Email = &v + return s +} + +// SetId sets the Id field's value. +func (s *Account) SetId(v string) *Account { + s.Id = &v + return s +} + +// SetJoinedMethod sets the JoinedMethod field's value. +func (s *Account) SetJoinedMethod(v string) *Account { + s.JoinedMethod = &v + return s +} + +// SetJoinedTimestamp sets the JoinedTimestamp field's value. +func (s *Account) SetJoinedTimestamp(v time.Time) *Account { + s.JoinedTimestamp = &v + return s +} + +// SetName sets the Name field's value. +func (s *Account) SetName(v string) *Account { + s.Name = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *Account) SetStatus(v string) *Account { + s.Status = &v + return s +} + +type AttachPolicyInput struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) of the policy that you want to attach to the target. + // You can get the ID for the policy by calling the ListPolicies operation. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a policy ID string + // requires "p-" followed by from 8 to 128 lower-case letters or digits. + // + // PolicyId is a required field + PolicyId *string `type:"string" required:"true"` + + // The unique identifier (ID) of the root, OU, or account that you want to attach + // the policy to. You can get the ID by calling the ListRoots, ListOrganizationalUnitsForParent, + // or ListAccounts operations. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a target ID string + // requires one of the following: + // + // * Root: a string that begins with "r-" followed by from 4 to 32 lower-case + // letters or digits. + // + // * Account: a string that consists of exactly 12 digits. + // + // * Organizational unit (OU): a string that begins with "ou-" followed by + // from 4 to 32 lower-case letters or digits (the ID of the root that the + // OU is in) followed by a second "-" dash and from 8 to 32 additional lower-case + // letters or digits. + // + // TargetId is a required field + TargetId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s AttachPolicyInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s AttachPolicyInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *AttachPolicyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "AttachPolicyInput"} + if s.PolicyId == nil { + invalidParams.Add(request.NewErrParamRequired("PolicyId")) + } + if s.TargetId == nil { + invalidParams.Add(request.NewErrParamRequired("TargetId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetPolicyId sets the PolicyId field's value. +func (s *AttachPolicyInput) SetPolicyId(v string) *AttachPolicyInput { + s.PolicyId = &v + return s +} + +// SetTargetId sets the TargetId field's value. +func (s *AttachPolicyInput) SetTargetId(v string) *AttachPolicyInput { + s.TargetId = &v + return s +} + +type AttachPolicyOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s AttachPolicyOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s AttachPolicyOutput) GoString() string { + return s.String() +} + +type CancelHandshakeInput struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) of the handshake that you want to cancel. You + // can get the ID from the ListHandshakesForOrganization operation. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for handshake ID string + // requires "h-" followed by from 8 to 32 lower-case letters or digits. + // + // HandshakeId is a required field + HandshakeId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s CancelHandshakeInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CancelHandshakeInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CancelHandshakeInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CancelHandshakeInput"} + if s.HandshakeId == nil { + invalidParams.Add(request.NewErrParamRequired("HandshakeId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetHandshakeId sets the HandshakeId field's value. +func (s *CancelHandshakeInput) SetHandshakeId(v string) *CancelHandshakeInput { + s.HandshakeId = &v + return s +} + +type CancelHandshakeOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains details about the handshake that you canceled. + Handshake *Handshake `type:"structure"` +} + +// String returns the string representation +func (s CancelHandshakeOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CancelHandshakeOutput) GoString() string { + return s.String() +} + +// SetHandshake sets the Handshake field's value. +func (s *CancelHandshakeOutput) SetHandshake(v *Handshake) *CancelHandshakeOutput { + s.Handshake = v + return s +} + +// Contains a list of child entities, either OUs or accounts. +type Child struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) of this child entity. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a child ID string + // requires one of the following: + // + // * Account: a string that consists of exactly 12 digits. + // + // * Organizational unit (OU): a string that begins with "ou-" followed by + // from 4 to 32 lower-case letters or digits (the ID of the root that contains + // the OU) followed by a second "-" dash and from 8 to 32 additional lower-case + // letters or digits. + Id *string `type:"string"` + + // The type of this child entity. + Type *string `type:"string" enum:"ChildType"` +} + +// String returns the string representation +func (s Child) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s Child) GoString() string { + return s.String() +} + +// SetId sets the Id field's value. +func (s *Child) SetId(v string) *Child { + s.Id = &v + return s +} + +// SetType sets the Type field's value. +func (s *Child) SetType(v string) *Child { + s.Type = &v + return s +} + +type CreateAccountInput struct { + _ struct{} `type:"structure"` + + // The friendly name of the member account. + // + // AccountName is a required field + AccountName *string `min:"1" type:"string" required:"true"` + + // The email address of the owner to assign to the new member account. This + // email address must not already be associated with another AWS account. You + // must use a valid email address to complete account creation. You cannot access + // the root user of the account or remove an account that was created with an + // invalid email address. + // + // Email is a required field + Email *string `min:"6" type:"string" required:"true"` + + // If set to ALLOW, the new account enables IAM users to access account billing + // information if they have the required permissions. If set to DENY, then only + // the root user of the new account can access account billing information. + // For more information, see Activating Access to the Billing and Cost Management + // Console (http://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/grantaccess.html#ControllingAccessWebsite-Activate) + // in the AWS Billing and Cost Management User Guide. + // + // If you do not specify this parameter, the value defaults to ALLOW, and IAM + // users and roles with the required permissions can access billing information + // for the new account. + IamUserAccessToBilling *string `type:"string" enum:"IAMUserAccessToBilling"` + + // (Optional) + // + // The name of an IAM role that Organizations automatically preconfigures in + // the new member account. This role trusts the master account, allowing users + // in the master account to assume the role, as permitted by the master account + // administrator. The role has administrator permissions in the new member account. + // + // If you do not specify this parameter, the role name defaults to OrganizationAccountAccessRole. + // + // For more information about how to use this role to access the member account, + // see Accessing and Administering the Member Accounts in Your Organization + // (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_access.html#orgs_manage_accounts_create-cross-account-role) + // in the AWS Organizations User Guide, and steps 2 and 3 in Tutorial: Delegate + // Access Across AWS Accounts Using IAM Roles (http://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_cross-account-with-roles.html) + // in the IAM User Guide. + // + // The regex pattern (http://wikipedia.org/wiki/regex) that is used to validate + // this parameter is a string of characters that can consist of uppercase letters, + // lowercase letters, digits with no spaces, and any of the following characters: + // =,.@- + RoleName *string `type:"string"` +} + +// String returns the string representation +func (s CreateAccountInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateAccountInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateAccountInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateAccountInput"} + if s.AccountName == nil { + invalidParams.Add(request.NewErrParamRequired("AccountName")) + } + if s.AccountName != nil && len(*s.AccountName) < 1 { + invalidParams.Add(request.NewErrParamMinLen("AccountName", 1)) + } + if s.Email == nil { + invalidParams.Add(request.NewErrParamRequired("Email")) + } + if s.Email != nil && len(*s.Email) < 6 { + invalidParams.Add(request.NewErrParamMinLen("Email", 6)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAccountName sets the AccountName field's value. +func (s *CreateAccountInput) SetAccountName(v string) *CreateAccountInput { + s.AccountName = &v + return s +} + +// SetEmail sets the Email field's value. +func (s *CreateAccountInput) SetEmail(v string) *CreateAccountInput { + s.Email = &v + return s +} + +// SetIamUserAccessToBilling sets the IamUserAccessToBilling field's value. +func (s *CreateAccountInput) SetIamUserAccessToBilling(v string) *CreateAccountInput { + s.IamUserAccessToBilling = &v + return s +} + +// SetRoleName sets the RoleName field's value. +func (s *CreateAccountInput) SetRoleName(v string) *CreateAccountInput { + s.RoleName = &v + return s +} + +type CreateAccountOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains details about the request to create an account. + // This response structure might not be fully populated when you first receive + // it because account creation is an asynchronous process. You can pass the + // returned CreateAccountStatus ID as a parameter to DescribeCreateAccountStatus + // to get status about the progress of the request at later times. + CreateAccountStatus *CreateAccountStatus `type:"structure"` +} + +// String returns the string representation +func (s CreateAccountOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateAccountOutput) GoString() string { + return s.String() +} + +// SetCreateAccountStatus sets the CreateAccountStatus field's value. +func (s *CreateAccountOutput) SetCreateAccountStatus(v *CreateAccountStatus) *CreateAccountOutput { + s.CreateAccountStatus = v + return s +} + +// Contains the status about a CreateAccount request to create an AWS account +// in an organization. +type CreateAccountStatus struct { + _ struct{} `type:"structure"` + + // If the account was created successfully, the unique identifier (ID) of the + // new account. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for an account ID string + // requires exactly 12 digits. + AccountId *string `type:"string"` + + // The account name given to the account when it was created. + AccountName *string `min:"1" type:"string"` + + // The date and time that the account was created and the request completed. + CompletedTimestamp *time.Time `type:"timestamp" timestampFormat:"unix"` + + // If the request failed, a description of the reason for the failure. + // + // * ACCOUNT_LIMIT_EXCEEDED: The account could not be created because you + // have reached the limit on the number of accounts in your organization. + // + // * EMAIL_ALREADY_EXISTS: The account could not be created because another + // AWS account with that email address already exists. + // + // * INVALID_ADDRESS: The account could not be created because the address + // you provided is not valid. + // + // * INVALID_EMAIL: The account could not be created because the email address + // you provided is not valid. + // + // * INTERNAL_FAILURE: The account could not be created because of an internal + // failure. Try again later. If the problem persists, contact Customer Support. + FailureReason *string `type:"string" enum:"CreateAccountFailureReason"` + + // The unique identifier (ID) that references this request. You get this value + // from the response of the initial CreateAccount request to create the account. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for an create account + // request ID string requires "car-" followed by from 8 to 32 lower-case letters + // or digits. + Id *string `type:"string"` + + // The date and time that the request was made for the account creation. + RequestedTimestamp *time.Time `type:"timestamp" timestampFormat:"unix"` + + // The status of the request. + State *string `type:"string" enum:"CreateAccountState"` +} + +// String returns the string representation +func (s CreateAccountStatus) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateAccountStatus) GoString() string { + return s.String() +} + +// SetAccountId sets the AccountId field's value. +func (s *CreateAccountStatus) SetAccountId(v string) *CreateAccountStatus { + s.AccountId = &v + return s +} + +// SetAccountName sets the AccountName field's value. +func (s *CreateAccountStatus) SetAccountName(v string) *CreateAccountStatus { + s.AccountName = &v + return s +} + +// SetCompletedTimestamp sets the CompletedTimestamp field's value. +func (s *CreateAccountStatus) SetCompletedTimestamp(v time.Time) *CreateAccountStatus { + s.CompletedTimestamp = &v + return s +} + +// SetFailureReason sets the FailureReason field's value. +func (s *CreateAccountStatus) SetFailureReason(v string) *CreateAccountStatus { + s.FailureReason = &v + return s +} + +// SetId sets the Id field's value. +func (s *CreateAccountStatus) SetId(v string) *CreateAccountStatus { + s.Id = &v + return s +} + +// SetRequestedTimestamp sets the RequestedTimestamp field's value. +func (s *CreateAccountStatus) SetRequestedTimestamp(v time.Time) *CreateAccountStatus { + s.RequestedTimestamp = &v + return s +} + +// SetState sets the State field's value. +func (s *CreateAccountStatus) SetState(v string) *CreateAccountStatus { + s.State = &v + return s +} + +type CreateOrganizationInput struct { + _ struct{} `type:"structure"` + + // Specifies the feature set supported by the new organization. Each feature + // set supports different levels of functionality. + // + // * CONSOLIDATED_BILLING: All member accounts have their bills consolidated + // to and paid by the master account. For more information, see Consolidated + // Billing (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_getting-started_concepts.html#feature-set-cb-only) + // in the AWS Organizations User Guide. + // + // * ALL: In addition to all the features supported by the consolidated billing + // feature set, the master account can also apply any type of policy to any + // member account in the organization. For more information, see All features + // (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_getting-started_concepts.html#feature-set-all) + // in the AWS Organizations User Guide. + FeatureSet *string `type:"string" enum:"OrganizationFeatureSet"` +} + +// String returns the string representation +func (s CreateOrganizationInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateOrganizationInput) GoString() string { + return s.String() +} + +// SetFeatureSet sets the FeatureSet field's value. +func (s *CreateOrganizationInput) SetFeatureSet(v string) *CreateOrganizationInput { + s.FeatureSet = &v + return s +} + +type CreateOrganizationOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains details about the newly created organization. + Organization *Organization `type:"structure"` +} + +// String returns the string representation +func (s CreateOrganizationOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateOrganizationOutput) GoString() string { + return s.String() +} + +// SetOrganization sets the Organization field's value. +func (s *CreateOrganizationOutput) SetOrganization(v *Organization) *CreateOrganizationOutput { + s.Organization = v + return s +} + +type CreateOrganizationalUnitInput struct { + _ struct{} `type:"structure"` + + // The friendly name to assign to the new OU. + // + // Name is a required field + Name *string `min:"1" type:"string" required:"true"` + + // The unique identifier (ID) of the parent root or OU in which you want to + // create the new OU. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a parent ID string + // requires one of the following: + // + // * Root: a string that begins with "r-" followed by from 4 to 32 lower-case + // letters or digits. + // + // * Organizational unit (OU): a string that begins with "ou-" followed by + // from 4 to 32 lower-case letters or digits (the ID of the root that the + // OU is in) followed by a second "-" dash and from 8 to 32 additional lower-case + // letters or digits. + // + // ParentId is a required field + ParentId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s CreateOrganizationalUnitInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateOrganizationalUnitInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateOrganizationalUnitInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateOrganizationalUnitInput"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + if s.ParentId == nil { + invalidParams.Add(request.NewErrParamRequired("ParentId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetName sets the Name field's value. +func (s *CreateOrganizationalUnitInput) SetName(v string) *CreateOrganizationalUnitInput { + s.Name = &v + return s +} + +// SetParentId sets the ParentId field's value. +func (s *CreateOrganizationalUnitInput) SetParentId(v string) *CreateOrganizationalUnitInput { + s.ParentId = &v + return s +} + +type CreateOrganizationalUnitOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains details about the newly created OU. + OrganizationalUnit *OrganizationalUnit `type:"structure"` +} + +// String returns the string representation +func (s CreateOrganizationalUnitOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreateOrganizationalUnitOutput) GoString() string { + return s.String() +} + +// SetOrganizationalUnit sets the OrganizationalUnit field's value. +func (s *CreateOrganizationalUnitOutput) SetOrganizationalUnit(v *OrganizationalUnit) *CreateOrganizationalUnitOutput { + s.OrganizationalUnit = v + return s +} + +type CreatePolicyInput struct { + _ struct{} `type:"structure"` + + // The policy content to add to the new policy. For example, if you create a + // service control policy (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_scp.html) + // (SCP), this string must be JSON text that specifies the permissions that + // admins in attached accounts can delegate to their users, groups, and roles. + // For more information about the SCP syntax, see Service Control Policy Syntax + // (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_scp-syntax.html) + // in the AWS Organizations User Guide. + // + // Content is a required field + Content *string `min:"1" type:"string" required:"true"` + + // An optional description to assign to the policy. + // + // Description is a required field + Description *string `type:"string" required:"true"` + + // The friendly name to assign to the policy. + // + // The regex pattern (http://wikipedia.org/wiki/regex) that is used to validate + // this parameter is a string of any of the characters in the ASCII character + // range. + // + // Name is a required field + Name *string `min:"1" type:"string" required:"true"` + + // The type of policy to create. + // + // In the current release, the only type of policy that you can create is a + // service control policy (SCP). + // + // Type is a required field + Type *string `type:"string" required:"true" enum:"PolicyType"` +} + +// String returns the string representation +func (s CreatePolicyInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreatePolicyInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreatePolicyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreatePolicyInput"} + if s.Content == nil { + invalidParams.Add(request.NewErrParamRequired("Content")) + } + if s.Content != nil && len(*s.Content) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Content", 1)) + } + if s.Description == nil { + invalidParams.Add(request.NewErrParamRequired("Description")) + } + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + if s.Type == nil { + invalidParams.Add(request.NewErrParamRequired("Type")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetContent sets the Content field's value. +func (s *CreatePolicyInput) SetContent(v string) *CreatePolicyInput { + s.Content = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreatePolicyInput) SetDescription(v string) *CreatePolicyInput { + s.Description = &v + return s +} + +// SetName sets the Name field's value. +func (s *CreatePolicyInput) SetName(v string) *CreatePolicyInput { + s.Name = &v + return s +} + +// SetType sets the Type field's value. +func (s *CreatePolicyInput) SetType(v string) *CreatePolicyInput { + s.Type = &v + return s +} + +type CreatePolicyOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains details about the newly created policy. + Policy *Policy `type:"structure"` +} + +// String returns the string representation +func (s CreatePolicyOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CreatePolicyOutput) GoString() string { + return s.String() +} + +// SetPolicy sets the Policy field's value. +func (s *CreatePolicyOutput) SetPolicy(v *Policy) *CreatePolicyOutput { + s.Policy = v + return s +} + +type DeclineHandshakeInput struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) of the handshake that you want to decline. You + // can get the ID from the ListHandshakesForAccount operation. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for handshake ID string + // requires "h-" followed by from 8 to 32 lower-case letters or digits. + // + // HandshakeId is a required field + HandshakeId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s DeclineHandshakeInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeclineHandshakeInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeclineHandshakeInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeclineHandshakeInput"} + if s.HandshakeId == nil { + invalidParams.Add(request.NewErrParamRequired("HandshakeId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetHandshakeId sets the HandshakeId field's value. +func (s *DeclineHandshakeInput) SetHandshakeId(v string) *DeclineHandshakeInput { + s.HandshakeId = &v + return s +} + +type DeclineHandshakeOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains details about the declined handshake. The state + // is updated to show the value DECLINED. + Handshake *Handshake `type:"structure"` +} + +// String returns the string representation +func (s DeclineHandshakeOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeclineHandshakeOutput) GoString() string { + return s.String() +} + +// SetHandshake sets the Handshake field's value. +func (s *DeclineHandshakeOutput) SetHandshake(v *Handshake) *DeclineHandshakeOutput { + s.Handshake = v + return s +} + +type DeleteOrganizationInput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteOrganizationInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteOrganizationInput) GoString() string { + return s.String() +} + +type DeleteOrganizationOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteOrganizationOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteOrganizationOutput) GoString() string { + return s.String() +} + +type DeleteOrganizationalUnitInput struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) of the organizational unit that you want to delete. + // You can get the ID from the ListOrganizationalUnitsForParent operation. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for an organizational + // unit ID string requires "ou-" followed by from 4 to 32 lower-case letters + // or digits (the ID of the root that contains the OU) followed by a second + // "-" dash and from 8 to 32 additional lower-case letters or digits. + // + // OrganizationalUnitId is a required field + OrganizationalUnitId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s DeleteOrganizationalUnitInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteOrganizationalUnitInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteOrganizationalUnitInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteOrganizationalUnitInput"} + if s.OrganizationalUnitId == nil { + invalidParams.Add(request.NewErrParamRequired("OrganizationalUnitId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetOrganizationalUnitId sets the OrganizationalUnitId field's value. +func (s *DeleteOrganizationalUnitInput) SetOrganizationalUnitId(v string) *DeleteOrganizationalUnitInput { + s.OrganizationalUnitId = &v + return s +} + +type DeleteOrganizationalUnitOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteOrganizationalUnitOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteOrganizationalUnitOutput) GoString() string { + return s.String() +} + +type DeletePolicyInput struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) of the policy that you want to delete. You can + // get the ID from the ListPolicies or ListPoliciesForTarget operations. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a policy ID string + // requires "p-" followed by from 8 to 128 lower-case letters or digits. + // + // PolicyId is a required field + PolicyId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s DeletePolicyInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeletePolicyInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeletePolicyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeletePolicyInput"} + if s.PolicyId == nil { + invalidParams.Add(request.NewErrParamRequired("PolicyId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetPolicyId sets the PolicyId field's value. +func (s *DeletePolicyInput) SetPolicyId(v string) *DeletePolicyInput { + s.PolicyId = &v + return s +} + +type DeletePolicyOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeletePolicyOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeletePolicyOutput) GoString() string { + return s.String() +} + +type DescribeAccountInput struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) of the AWS account that you want information about. + // You can get the ID from the ListAccounts or ListAccountsForParent operations. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for an account ID string + // requires exactly 12 digits. + // + // AccountId is a required field + AccountId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s DescribeAccountInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeAccountInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DescribeAccountInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DescribeAccountInput"} + if s.AccountId == nil { + invalidParams.Add(request.NewErrParamRequired("AccountId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAccountId sets the AccountId field's value. +func (s *DescribeAccountInput) SetAccountId(v string) *DescribeAccountInput { + s.AccountId = &v + return s +} + +type DescribeAccountOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains information about the requested account. + Account *Account `type:"structure"` +} + +// String returns the string representation +func (s DescribeAccountOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeAccountOutput) GoString() string { + return s.String() +} + +// SetAccount sets the Account field's value. +func (s *DescribeAccountOutput) SetAccount(v *Account) *DescribeAccountOutput { + s.Account = v + return s +} + +type DescribeCreateAccountStatusInput struct { + _ struct{} `type:"structure"` + + // Specifies the operationId that uniquely identifies the request. You can get + // the ID from the response to an earlier CreateAccount request, or from the + // ListCreateAccountStatus operation. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for an create account + // request ID string requires "car-" followed by from 8 to 32 lower-case letters + // or digits. + // + // CreateAccountRequestId is a required field + CreateAccountRequestId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s DescribeCreateAccountStatusInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeCreateAccountStatusInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DescribeCreateAccountStatusInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DescribeCreateAccountStatusInput"} + if s.CreateAccountRequestId == nil { + invalidParams.Add(request.NewErrParamRequired("CreateAccountRequestId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetCreateAccountRequestId sets the CreateAccountRequestId field's value. +func (s *DescribeCreateAccountStatusInput) SetCreateAccountRequestId(v string) *DescribeCreateAccountStatusInput { + s.CreateAccountRequestId = &v + return s +} + +type DescribeCreateAccountStatusOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains the current status of an account creation request. + CreateAccountStatus *CreateAccountStatus `type:"structure"` +} + +// String returns the string representation +func (s DescribeCreateAccountStatusOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeCreateAccountStatusOutput) GoString() string { + return s.String() +} + +// SetCreateAccountStatus sets the CreateAccountStatus field's value. +func (s *DescribeCreateAccountStatusOutput) SetCreateAccountStatus(v *CreateAccountStatus) *DescribeCreateAccountStatusOutput { + s.CreateAccountStatus = v + return s +} + +type DescribeHandshakeInput struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) of the handshake that you want information about. + // You can get the ID from the original call to InviteAccountToOrganization, + // or from a call to ListHandshakesForAccount or ListHandshakesForOrganization. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for handshake ID string + // requires "h-" followed by from 8 to 32 lower-case letters or digits. + // + // HandshakeId is a required field + HandshakeId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s DescribeHandshakeInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeHandshakeInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DescribeHandshakeInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DescribeHandshakeInput"} + if s.HandshakeId == nil { + invalidParams.Add(request.NewErrParamRequired("HandshakeId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetHandshakeId sets the HandshakeId field's value. +func (s *DescribeHandshakeInput) SetHandshakeId(v string) *DescribeHandshakeInput { + s.HandshakeId = &v + return s +} + +type DescribeHandshakeOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains information about the specified handshake. + Handshake *Handshake `type:"structure"` +} + +// String returns the string representation +func (s DescribeHandshakeOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeHandshakeOutput) GoString() string { + return s.String() +} + +// SetHandshake sets the Handshake field's value. +func (s *DescribeHandshakeOutput) SetHandshake(v *Handshake) *DescribeHandshakeOutput { + s.Handshake = v + return s +} + +type DescribeOrganizationInput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DescribeOrganizationInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeOrganizationInput) GoString() string { + return s.String() +} + +type DescribeOrganizationOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains information about the organization. + Organization *Organization `type:"structure"` +} + +// String returns the string representation +func (s DescribeOrganizationOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeOrganizationOutput) GoString() string { + return s.String() +} + +// SetOrganization sets the Organization field's value. +func (s *DescribeOrganizationOutput) SetOrganization(v *Organization) *DescribeOrganizationOutput { + s.Organization = v + return s +} + +type DescribeOrganizationalUnitInput struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) of the organizational unit that you want details + // about. You can get the ID from the ListOrganizationalUnitsForParent operation. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for an organizational + // unit ID string requires "ou-" followed by from 4 to 32 lower-case letters + // or digits (the ID of the root that contains the OU) followed by a second + // "-" dash and from 8 to 32 additional lower-case letters or digits. + // + // OrganizationalUnitId is a required field + OrganizationalUnitId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s DescribeOrganizationalUnitInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeOrganizationalUnitInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DescribeOrganizationalUnitInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DescribeOrganizationalUnitInput"} + if s.OrganizationalUnitId == nil { + invalidParams.Add(request.NewErrParamRequired("OrganizationalUnitId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetOrganizationalUnitId sets the OrganizationalUnitId field's value. +func (s *DescribeOrganizationalUnitInput) SetOrganizationalUnitId(v string) *DescribeOrganizationalUnitInput { + s.OrganizationalUnitId = &v + return s +} + +type DescribeOrganizationalUnitOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains details about the specified OU. + OrganizationalUnit *OrganizationalUnit `type:"structure"` +} + +// String returns the string representation +func (s DescribeOrganizationalUnitOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribeOrganizationalUnitOutput) GoString() string { + return s.String() +} + +// SetOrganizationalUnit sets the OrganizationalUnit field's value. +func (s *DescribeOrganizationalUnitOutput) SetOrganizationalUnit(v *OrganizationalUnit) *DescribeOrganizationalUnitOutput { + s.OrganizationalUnit = v + return s +} + +type DescribePolicyInput struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) of the policy that you want details about. You + // can get the ID from the ListPolicies or ListPoliciesForTarget operations. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a policy ID string + // requires "p-" followed by from 8 to 128 lower-case letters or digits. + // + // PolicyId is a required field + PolicyId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s DescribePolicyInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribePolicyInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DescribePolicyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DescribePolicyInput"} + if s.PolicyId == nil { + invalidParams.Add(request.NewErrParamRequired("PolicyId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetPolicyId sets the PolicyId field's value. +func (s *DescribePolicyInput) SetPolicyId(v string) *DescribePolicyInput { + s.PolicyId = &v + return s +} + +type DescribePolicyOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains details about the specified policy. + Policy *Policy `type:"structure"` +} + +// String returns the string representation +func (s DescribePolicyOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DescribePolicyOutput) GoString() string { + return s.String() +} + +// SetPolicy sets the Policy field's value. +func (s *DescribePolicyOutput) SetPolicy(v *Policy) *DescribePolicyOutput { + s.Policy = v + return s +} + +type DetachPolicyInput struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) of the policy you want to detach. You can get + // the ID from the ListPolicies or ListPoliciesForTarget operations. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a policy ID string + // requires "p-" followed by from 8 to 128 lower-case letters or digits. + // + // PolicyId is a required field + PolicyId *string `type:"string" required:"true"` + + // The unique identifier (ID) of the root, OU, or account from which you want + // to detach the policy. You can get the ID from the ListRoots, ListOrganizationalUnitsForParent, + // or ListAccounts operations. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a target ID string + // requires one of the following: + // + // * Root: a string that begins with "r-" followed by from 4 to 32 lower-case + // letters or digits. + // + // * Account: a string that consists of exactly 12 digits. + // + // * Organizational unit (OU): a string that begins with "ou-" followed by + // from 4 to 32 lower-case letters or digits (the ID of the root that the + // OU is in) followed by a second "-" dash and from 8 to 32 additional lower-case + // letters or digits. + // + // TargetId is a required field + TargetId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s DetachPolicyInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DetachPolicyInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DetachPolicyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DetachPolicyInput"} + if s.PolicyId == nil { + invalidParams.Add(request.NewErrParamRequired("PolicyId")) + } + if s.TargetId == nil { + invalidParams.Add(request.NewErrParamRequired("TargetId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetPolicyId sets the PolicyId field's value. +func (s *DetachPolicyInput) SetPolicyId(v string) *DetachPolicyInput { + s.PolicyId = &v + return s +} + +// SetTargetId sets the TargetId field's value. +func (s *DetachPolicyInput) SetTargetId(v string) *DetachPolicyInput { + s.TargetId = &v + return s +} + +type DetachPolicyOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DetachPolicyOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DetachPolicyOutput) GoString() string { + return s.String() +} + +type DisableAWSServiceAccessInput struct { + _ struct{} `type:"structure"` + + // The service principal name of the AWS service for which you want to disable + // integration with your organization. This is typically in the form of a URL, + // such as service-abbreviation.amazonaws.com. + // + // ServicePrincipal is a required field + ServicePrincipal *string `min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s DisableAWSServiceAccessInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DisableAWSServiceAccessInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DisableAWSServiceAccessInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DisableAWSServiceAccessInput"} + if s.ServicePrincipal == nil { + invalidParams.Add(request.NewErrParamRequired("ServicePrincipal")) + } + if s.ServicePrincipal != nil && len(*s.ServicePrincipal) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ServicePrincipal", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetServicePrincipal sets the ServicePrincipal field's value. +func (s *DisableAWSServiceAccessInput) SetServicePrincipal(v string) *DisableAWSServiceAccessInput { + s.ServicePrincipal = &v + return s +} + +type DisableAWSServiceAccessOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DisableAWSServiceAccessOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DisableAWSServiceAccessOutput) GoString() string { + return s.String() +} + +type DisablePolicyTypeInput struct { + _ struct{} `type:"structure"` + + // The policy type that you want to disable in this root. + // + // PolicyType is a required field + PolicyType *string `type:"string" required:"true" enum:"PolicyType"` + + // The unique identifier (ID) of the root in which you want to disable a policy + // type. You can get the ID from the ListRoots operation. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a root ID string + // requires "r-" followed by from 4 to 32 lower-case letters or digits. + // + // RootId is a required field + RootId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s DisablePolicyTypeInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DisablePolicyTypeInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DisablePolicyTypeInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DisablePolicyTypeInput"} + if s.PolicyType == nil { + invalidParams.Add(request.NewErrParamRequired("PolicyType")) + } + if s.RootId == nil { + invalidParams.Add(request.NewErrParamRequired("RootId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetPolicyType sets the PolicyType field's value. +func (s *DisablePolicyTypeInput) SetPolicyType(v string) *DisablePolicyTypeInput { + s.PolicyType = &v + return s +} + +// SetRootId sets the RootId field's value. +func (s *DisablePolicyTypeInput) SetRootId(v string) *DisablePolicyTypeInput { + s.RootId = &v + return s +} + +type DisablePolicyTypeOutput struct { + _ struct{} `type:"structure"` + + // A structure that shows the root with the updated list of enabled policy types. + Root *Root `type:"structure"` +} + +// String returns the string representation +func (s DisablePolicyTypeOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DisablePolicyTypeOutput) GoString() string { + return s.String() +} + +// SetRoot sets the Root field's value. +func (s *DisablePolicyTypeOutput) SetRoot(v *Root) *DisablePolicyTypeOutput { + s.Root = v + return s +} + +type EnableAWSServiceAccessInput struct { + _ struct{} `type:"structure"` + + // The service principal name of the AWS service for which you want to enable + // integration with your organization. This is typically in the form of a URL, + // such as service-abbreviation.amazonaws.com. + // + // ServicePrincipal is a required field + ServicePrincipal *string `min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s EnableAWSServiceAccessInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s EnableAWSServiceAccessInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *EnableAWSServiceAccessInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "EnableAWSServiceAccessInput"} + if s.ServicePrincipal == nil { + invalidParams.Add(request.NewErrParamRequired("ServicePrincipal")) + } + if s.ServicePrincipal != nil && len(*s.ServicePrincipal) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ServicePrincipal", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetServicePrincipal sets the ServicePrincipal field's value. +func (s *EnableAWSServiceAccessInput) SetServicePrincipal(v string) *EnableAWSServiceAccessInput { + s.ServicePrincipal = &v + return s +} + +type EnableAWSServiceAccessOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s EnableAWSServiceAccessOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s EnableAWSServiceAccessOutput) GoString() string { + return s.String() +} + +type EnableAllFeaturesInput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s EnableAllFeaturesInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s EnableAllFeaturesInput) GoString() string { + return s.String() +} + +type EnableAllFeaturesOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains details about the handshake created to support + // this request to enable all features in the organization. + Handshake *Handshake `type:"structure"` +} + +// String returns the string representation +func (s EnableAllFeaturesOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s EnableAllFeaturesOutput) GoString() string { + return s.String() +} + +// SetHandshake sets the Handshake field's value. +func (s *EnableAllFeaturesOutput) SetHandshake(v *Handshake) *EnableAllFeaturesOutput { + s.Handshake = v + return s +} + +type EnablePolicyTypeInput struct { + _ struct{} `type:"structure"` + + // The policy type that you want to enable. + // + // PolicyType is a required field + PolicyType *string `type:"string" required:"true" enum:"PolicyType"` + + // The unique identifier (ID) of the root in which you want to enable a policy + // type. You can get the ID from the ListRoots operation. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a root ID string + // requires "r-" followed by from 4 to 32 lower-case letters or digits. + // + // RootId is a required field + RootId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s EnablePolicyTypeInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s EnablePolicyTypeInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *EnablePolicyTypeInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "EnablePolicyTypeInput"} + if s.PolicyType == nil { + invalidParams.Add(request.NewErrParamRequired("PolicyType")) + } + if s.RootId == nil { + invalidParams.Add(request.NewErrParamRequired("RootId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetPolicyType sets the PolicyType field's value. +func (s *EnablePolicyTypeInput) SetPolicyType(v string) *EnablePolicyTypeInput { + s.PolicyType = &v + return s +} + +// SetRootId sets the RootId field's value. +func (s *EnablePolicyTypeInput) SetRootId(v string) *EnablePolicyTypeInput { + s.RootId = &v + return s +} + +type EnablePolicyTypeOutput struct { + _ struct{} `type:"structure"` + + // A structure that shows the root with the updated list of enabled policy types. + Root *Root `type:"structure"` +} + +// String returns the string representation +func (s EnablePolicyTypeOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s EnablePolicyTypeOutput) GoString() string { + return s.String() +} + +// SetRoot sets the Root field's value. +func (s *EnablePolicyTypeOutput) SetRoot(v *Root) *EnablePolicyTypeOutput { + s.Root = v + return s +} + +// A structure that contains details of a service principal that is enabled +// to integrate with AWS Organizations. +type EnabledServicePrincipal struct { + _ struct{} `type:"structure"` + + // The date that the service principal was enabled for integration with AWS + // Organizations. + DateEnabled *time.Time `type:"timestamp" timestampFormat:"unix"` + + // The name of the service principal. This is typically in the form of a URL, + // such as: servicename.amazonaws.com. + ServicePrincipal *string `min:"1" type:"string"` +} + +// String returns the string representation +func (s EnabledServicePrincipal) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s EnabledServicePrincipal) GoString() string { + return s.String() +} + +// SetDateEnabled sets the DateEnabled field's value. +func (s *EnabledServicePrincipal) SetDateEnabled(v time.Time) *EnabledServicePrincipal { + s.DateEnabled = &v + return s +} + +// SetServicePrincipal sets the ServicePrincipal field's value. +func (s *EnabledServicePrincipal) SetServicePrincipal(v string) *EnabledServicePrincipal { + s.ServicePrincipal = &v + return s +} + +// Contains information that must be exchanged to securely establish a relationship +// between two accounts (an originator and a recipient). For example, when a +// master account (the originator) invites another account (the recipient) to +// join its organization, the two accounts exchange information as a series +// of handshake requests and responses. +// +// Note: Handshakes that are CANCELED, ACCEPTED, or DECLINED show up in lists +// for only 30 days after entering that state After that they are deleted. +type Handshake struct { + _ struct{} `type:"structure"` + + // The type of handshake, indicating what action occurs when the recipient accepts + // the handshake. The following handshake types are supported: + // + // * INVITE: This type of handshake represents a request to join an organization. + // It is always sent from the master account to only non-member accounts. + // + // * ENABLE_ALL_FEATURES: This type of handshake represents a request to + // enable all features in an organization. It is always sent from the master + // account to only invited member accounts. Created accounts do not receive + // this because those accounts were created by the organization's master + // account and approval is inferred. + // + // * APPROVE_ALL_FEATURES: This type of handshake is sent from the Organizations + // service when all member accounts have approved the ENABLE_ALL_FEATURES + // invitation. It is sent only to the master account and signals the master + // that it can finalize the process to enable all features. + Action *string `type:"string" enum:"ActionType"` + + // The Amazon Resource Name (ARN) of a handshake. + // + // For more information about ARNs in Organizations, see ARN Formats Supported + // by Organizations (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_permissions.html#orgs-permissions-arns) + // in the AWS Organizations User Guide. + Arn *string `type:"string"` + + // The date and time that the handshake expires. If the recipient of the handshake + // request fails to respond before the specified date and time, the handshake + // becomes inactive and is no longer valid. + ExpirationTimestamp *time.Time `type:"timestamp" timestampFormat:"unix"` + + // The unique identifier (ID) of a handshake. The originating account creates + // the ID when it initiates the handshake. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for handshake ID string + // requires "h-" followed by from 8 to 32 lower-case letters or digits. + Id *string `type:"string"` + + // Information about the two accounts that are participating in the handshake. + Parties []*HandshakeParty `type:"list"` + + // The date and time that the handshake request was made. + RequestedTimestamp *time.Time `type:"timestamp" timestampFormat:"unix"` + + // Additional information that is needed to process the handshake. + Resources []*HandshakeResource `type:"list"` + + // The current state of the handshake. Use the state to trace the flow of the + // handshake through the process from its creation to its acceptance. The meaning + // of each of the valid values is as follows: + // + // * REQUESTED: This handshake was sent to multiple recipients (applicable + // to only some handshake types) and not all recipients have responded yet. + // The request stays in this state until all recipients respond. + // + // * OPEN: This handshake was sent to multiple recipients (applicable to + // only some policy types) and all recipients have responded, allowing the + // originator to complete the handshake action. + // + // * CANCELED: This handshake is no longer active because it was canceled + // by the originating account. + // + // * ACCEPTED: This handshake is complete because it has been accepted by + // the recipient. + // + // * DECLINED: This handshake is no longer active because it was declined + // by the recipient account. + // + // * EXPIRED: This handshake is no longer active because the originator did + // not receive a response of any kind from the recipient before the expiration + // time (15 days). + State *string `type:"string" enum:"HandshakeState"` +} + +// String returns the string representation +func (s Handshake) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s Handshake) GoString() string { + return s.String() +} + +// SetAction sets the Action field's value. +func (s *Handshake) SetAction(v string) *Handshake { + s.Action = &v + return s +} + +// SetArn sets the Arn field's value. +func (s *Handshake) SetArn(v string) *Handshake { + s.Arn = &v + return s +} + +// SetExpirationTimestamp sets the ExpirationTimestamp field's value. +func (s *Handshake) SetExpirationTimestamp(v time.Time) *Handshake { + s.ExpirationTimestamp = &v + return s +} + +// SetId sets the Id field's value. +func (s *Handshake) SetId(v string) *Handshake { + s.Id = &v + return s +} + +// SetParties sets the Parties field's value. +func (s *Handshake) SetParties(v []*HandshakeParty) *Handshake { + s.Parties = v + return s +} + +// SetRequestedTimestamp sets the RequestedTimestamp field's value. +func (s *Handshake) SetRequestedTimestamp(v time.Time) *Handshake { + s.RequestedTimestamp = &v + return s +} + +// SetResources sets the Resources field's value. +func (s *Handshake) SetResources(v []*HandshakeResource) *Handshake { + s.Resources = v + return s +} + +// SetState sets the State field's value. +func (s *Handshake) SetState(v string) *Handshake { + s.State = &v + return s +} + +// Specifies the criteria that are used to select the handshakes for the operation. +type HandshakeFilter struct { + _ struct{} `type:"structure"` + + // Specifies the type of handshake action. + // + // If you specify ActionType, you cannot also specify ParentHandshakeId. + ActionType *string `type:"string" enum:"ActionType"` + + // Specifies the parent handshake. Only used for handshake types that are a + // child of another type. + // + // If you specify ParentHandshakeId, you cannot also specify ActionType. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for handshake ID string + // requires "h-" followed by from 8 to 32 lower-case letters or digits. + ParentHandshakeId *string `type:"string"` +} + +// String returns the string representation +func (s HandshakeFilter) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s HandshakeFilter) GoString() string { + return s.String() +} + +// SetActionType sets the ActionType field's value. +func (s *HandshakeFilter) SetActionType(v string) *HandshakeFilter { + s.ActionType = &v + return s +} + +// SetParentHandshakeId sets the ParentHandshakeId field's value. +func (s *HandshakeFilter) SetParentHandshakeId(v string) *HandshakeFilter { + s.ParentHandshakeId = &v + return s +} + +// Identifies a participant in a handshake. +type HandshakeParty struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) for the party. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for handshake ID string + // requires "h-" followed by from 8 to 32 lower-case letters or digits. + // + // Id is a required field + Id *string `min:"1" type:"string" required:"true"` + + // The type of party. + // + // Type is a required field + Type *string `type:"string" required:"true" enum:"HandshakePartyType"` +} + +// String returns the string representation +func (s HandshakeParty) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s HandshakeParty) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *HandshakeParty) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "HandshakeParty"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } + if s.Id != nil && len(*s.Id) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Id", 1)) + } + if s.Type == nil { + invalidParams.Add(request.NewErrParamRequired("Type")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetId sets the Id field's value. +func (s *HandshakeParty) SetId(v string) *HandshakeParty { + s.Id = &v + return s +} + +// SetType sets the Type field's value. +func (s *HandshakeParty) SetType(v string) *HandshakeParty { + s.Type = &v + return s +} + +// Contains additional data that is needed to process a handshake. +type HandshakeResource struct { + _ struct{} `type:"structure"` + + // When needed, contains an additional array of HandshakeResource objects. + Resources []*HandshakeResource `type:"list"` + + // The type of information being passed, specifying how the value is to be interpreted + // by the other party: + // + // * ACCOUNT - Specifies an AWS account ID number. + // + // * ORGANIZATION - Specifies an organization ID number. + // + // * EMAIL - Specifies the email address that is associated with the account + // that receives the handshake. + // + // * OWNER_EMAIL - Specifies the email address associated with the master + // account. Included as information about an organization. + // + // * OWNER_NAME - Specifies the name associated with the master account. + // Included as information about an organization. + // + // * NOTES - Additional text provided by the handshake initiator and intended + // for the recipient to read. + Type *string `type:"string" enum:"HandshakeResourceType"` + + // The information that is passed to the other party in the handshake. The format + // of the value string must match the requirements of the specified type. + Value *string `type:"string"` +} + +// String returns the string representation +func (s HandshakeResource) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s HandshakeResource) GoString() string { + return s.String() +} + +// SetResources sets the Resources field's value. +func (s *HandshakeResource) SetResources(v []*HandshakeResource) *HandshakeResource { + s.Resources = v + return s +} + +// SetType sets the Type field's value. +func (s *HandshakeResource) SetType(v string) *HandshakeResource { + s.Type = &v + return s +} + +// SetValue sets the Value field's value. +func (s *HandshakeResource) SetValue(v string) *HandshakeResource { + s.Value = &v + return s +} + +type InviteAccountToOrganizationInput struct { + _ struct{} `type:"structure"` + + // Additional information that you want to include in the generated email to + // the recipient account owner. + Notes *string `type:"string"` + + // The identifier (ID) of the AWS account that you want to invite to join your + // organization. This is a JSON object that contains the following elements: + // + // { "Type": "ACCOUNT", "Id": "" } + // + // If you use the AWS CLI, you can submit this as a single string, similar to + // the following example: + // + // --target Id=123456789012,Type=ACCOUNT + // + // If you specify "Type": "ACCOUNT", then you must provide the AWS account ID + // number as the Id. If you specify "Type": "EMAIL", then you must specify the + // email address that is associated with the account. + // + // --target Id=bill@example.com,Type=EMAIL + // + // Target is a required field + Target *HandshakeParty `type:"structure" required:"true"` +} + +// String returns the string representation +func (s InviteAccountToOrganizationInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s InviteAccountToOrganizationInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *InviteAccountToOrganizationInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "InviteAccountToOrganizationInput"} + if s.Target == nil { + invalidParams.Add(request.NewErrParamRequired("Target")) + } + if s.Target != nil { + if err := s.Target.Validate(); err != nil { + invalidParams.AddNested("Target", err.(request.ErrInvalidParams)) + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetNotes sets the Notes field's value. +func (s *InviteAccountToOrganizationInput) SetNotes(v string) *InviteAccountToOrganizationInput { + s.Notes = &v + return s +} + +// SetTarget sets the Target field's value. +func (s *InviteAccountToOrganizationInput) SetTarget(v *HandshakeParty) *InviteAccountToOrganizationInput { + s.Target = v + return s +} + +type InviteAccountToOrganizationOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains details about the handshake that is created to + // support this invitation request. + Handshake *Handshake `type:"structure"` +} + +// String returns the string representation +func (s InviteAccountToOrganizationOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s InviteAccountToOrganizationOutput) GoString() string { + return s.String() +} + +// SetHandshake sets the Handshake field's value. +func (s *InviteAccountToOrganizationOutput) SetHandshake(v *Handshake) *InviteAccountToOrganizationOutput { + s.Handshake = v + return s +} + +type LeaveOrganizationInput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s LeaveOrganizationInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s LeaveOrganizationInput) GoString() string { + return s.String() +} + +type LeaveOrganizationOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s LeaveOrganizationOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s LeaveOrganizationOutput) GoString() string { + return s.String() +} + +type ListAWSServiceAccessForOrganizationInput struct { + _ struct{} `type:"structure"` + + // (Optional) Use this to limit the number of results you want included in the + // response. If you do not include this parameter, it defaults to a value that + // is specific to the operation. If additional items exist beyond the maximum + // you specify, the NextToken response element is present and has a value (is + // not null). Include that value as the NextToken request parameter in the next + // call to the operation to get the next part of the results. Note that Organizations + // might return fewer results than the maximum even when there are more results + // available. You should check NextToken after every operation to ensure that + // you receive all of the results. + MaxResults *int64 `min:"1" type:"integer"` + + // Use this parameter if you receive a NextToken response in a previous request + // that indicates that there is more output available. Set it to the value of + // the previous call's NextToken response to indicate where the output should + // continue from. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s ListAWSServiceAccessForOrganizationInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListAWSServiceAccessForOrganizationInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListAWSServiceAccessForOrganizationInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListAWSServiceAccessForOrganizationInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMaxResults sets the MaxResults field's value. +func (s *ListAWSServiceAccessForOrganizationInput) SetMaxResults(v int64) *ListAWSServiceAccessForOrganizationInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListAWSServiceAccessForOrganizationInput) SetNextToken(v string) *ListAWSServiceAccessForOrganizationInput { + s.NextToken = &v + return s +} + +type ListAWSServiceAccessForOrganizationOutput struct { + _ struct{} `type:"structure"` + + // A list of the service principals for the services that are enabled to integrate + // with your organization. Each principal is a structure that includes the name + // and the date that it was enabled for integration with AWS Organizations. + EnabledServicePrincipals []*EnabledServicePrincipal `type:"list"` + + // If present, this value indicates that there is more output available than + // is included in the current response. Use this value in the NextToken request + // parameter in a subsequent call to the operation to get the next part of the + // output. You should repeat this until the NextToken response element comes + // back as null. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s ListAWSServiceAccessForOrganizationOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListAWSServiceAccessForOrganizationOutput) GoString() string { + return s.String() +} + +// SetEnabledServicePrincipals sets the EnabledServicePrincipals field's value. +func (s *ListAWSServiceAccessForOrganizationOutput) SetEnabledServicePrincipals(v []*EnabledServicePrincipal) *ListAWSServiceAccessForOrganizationOutput { + s.EnabledServicePrincipals = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListAWSServiceAccessForOrganizationOutput) SetNextToken(v string) *ListAWSServiceAccessForOrganizationOutput { + s.NextToken = &v + return s +} + +type ListAccountsForParentInput struct { + _ struct{} `type:"structure"` + + // (Optional) Use this to limit the number of results you want included in the + // response. If you do not include this parameter, it defaults to a value that + // is specific to the operation. If additional items exist beyond the maximum + // you specify, the NextToken response element is present and has a value (is + // not null). Include that value as the NextToken request parameter in the next + // call to the operation to get the next part of the results. Note that Organizations + // might return fewer results than the maximum even when there are more results + // available. You should check NextToken after every operation to ensure that + // you receive all of the results. + MaxResults *int64 `min:"1" type:"integer"` + + // Use this parameter if you receive a NextToken response in a previous request + // that indicates that there is more output available. Set it to the value of + // the previous call's NextToken response to indicate where the output should + // continue from. + NextToken *string `type:"string"` + + // The unique identifier (ID) for the parent root or organization unit (OU) + // whose accounts you want to list. + // + // ParentId is a required field + ParentId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s ListAccountsForParentInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListAccountsForParentInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListAccountsForParentInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListAccountsForParentInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.ParentId == nil { + invalidParams.Add(request.NewErrParamRequired("ParentId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMaxResults sets the MaxResults field's value. +func (s *ListAccountsForParentInput) SetMaxResults(v int64) *ListAccountsForParentInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListAccountsForParentInput) SetNextToken(v string) *ListAccountsForParentInput { + s.NextToken = &v + return s +} + +// SetParentId sets the ParentId field's value. +func (s *ListAccountsForParentInput) SetParentId(v string) *ListAccountsForParentInput { + s.ParentId = &v + return s +} + +type ListAccountsForParentOutput struct { + _ struct{} `type:"structure"` + + // A list of the accounts in the specified root or OU. + Accounts []*Account `type:"list"` + + // If present, this value indicates that there is more output available than + // is included in the current response. Use this value in the NextToken request + // parameter in a subsequent call to the operation to get the next part of the + // output. You should repeat this until the NextToken response element comes + // back as null. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s ListAccountsForParentOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListAccountsForParentOutput) GoString() string { + return s.String() +} + +// SetAccounts sets the Accounts field's value. +func (s *ListAccountsForParentOutput) SetAccounts(v []*Account) *ListAccountsForParentOutput { + s.Accounts = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListAccountsForParentOutput) SetNextToken(v string) *ListAccountsForParentOutput { + s.NextToken = &v + return s +} + +type ListAccountsInput struct { + _ struct{} `type:"structure"` + + // (Optional) Use this to limit the number of results you want included in the + // response. If you do not include this parameter, it defaults to a value that + // is specific to the operation. If additional items exist beyond the maximum + // you specify, the NextToken response element is present and has a value (is + // not null). Include that value as the NextToken request parameter in the next + // call to the operation to get the next part of the results. Note that Organizations + // might return fewer results than the maximum even when there are more results + // available. You should check NextToken after every operation to ensure that + // you receive all of the results. + MaxResults *int64 `min:"1" type:"integer"` + + // Use this parameter if you receive a NextToken response in a previous request + // that indicates that there is more output available. Set it to the value of + // the previous call's NextToken response to indicate where the output should + // continue from. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s ListAccountsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListAccountsInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListAccountsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListAccountsInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMaxResults sets the MaxResults field's value. +func (s *ListAccountsInput) SetMaxResults(v int64) *ListAccountsInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListAccountsInput) SetNextToken(v string) *ListAccountsInput { + s.NextToken = &v + return s +} + +type ListAccountsOutput struct { + _ struct{} `type:"structure"` + + // A list of objects in the organization. + Accounts []*Account `type:"list"` + + // If present, this value indicates that there is more output available than + // is included in the current response. Use this value in the NextToken request + // parameter in a subsequent call to the operation to get the next part of the + // output. You should repeat this until the NextToken response element comes + // back as null. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s ListAccountsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListAccountsOutput) GoString() string { + return s.String() +} + +// SetAccounts sets the Accounts field's value. +func (s *ListAccountsOutput) SetAccounts(v []*Account) *ListAccountsOutput { + s.Accounts = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListAccountsOutput) SetNextToken(v string) *ListAccountsOutput { + s.NextToken = &v + return s +} + +type ListChildrenInput struct { + _ struct{} `type:"structure"` + + // Filters the output to include only the specified child type. + // + // ChildType is a required field + ChildType *string `type:"string" required:"true" enum:"ChildType"` + + // (Optional) Use this to limit the number of results you want included in the + // response. If you do not include this parameter, it defaults to a value that + // is specific to the operation. If additional items exist beyond the maximum + // you specify, the NextToken response element is present and has a value (is + // not null). Include that value as the NextToken request parameter in the next + // call to the operation to get the next part of the results. Note that Organizations + // might return fewer results than the maximum even when there are more results + // available. You should check NextToken after every operation to ensure that + // you receive all of the results. + MaxResults *int64 `min:"1" type:"integer"` + + // Use this parameter if you receive a NextToken response in a previous request + // that indicates that there is more output available. Set it to the value of + // the previous call's NextToken response to indicate where the output should + // continue from. + NextToken *string `type:"string"` + + // The unique identifier (ID) for the parent root or OU whose children you want + // to list. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a parent ID string + // requires one of the following: + // + // * Root: a string that begins with "r-" followed by from 4 to 32 lower-case + // letters or digits. + // + // * Organizational unit (OU): a string that begins with "ou-" followed by + // from 4 to 32 lower-case letters or digits (the ID of the root that the + // OU is in) followed by a second "-" dash and from 8 to 32 additional lower-case + // letters or digits. + // + // ParentId is a required field + ParentId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s ListChildrenInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListChildrenInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListChildrenInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListChildrenInput"} + if s.ChildType == nil { + invalidParams.Add(request.NewErrParamRequired("ChildType")) + } + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.ParentId == nil { + invalidParams.Add(request.NewErrParamRequired("ParentId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetChildType sets the ChildType field's value. +func (s *ListChildrenInput) SetChildType(v string) *ListChildrenInput { + s.ChildType = &v + return s +} + +// SetMaxResults sets the MaxResults field's value. +func (s *ListChildrenInput) SetMaxResults(v int64) *ListChildrenInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListChildrenInput) SetNextToken(v string) *ListChildrenInput { + s.NextToken = &v + return s +} + +// SetParentId sets the ParentId field's value. +func (s *ListChildrenInput) SetParentId(v string) *ListChildrenInput { + s.ParentId = &v + return s +} + +type ListChildrenOutput struct { + _ struct{} `type:"structure"` + + // The list of children of the specified parent container. + Children []*Child `type:"list"` + + // If present, this value indicates that there is more output available than + // is included in the current response. Use this value in the NextToken request + // parameter in a subsequent call to the operation to get the next part of the + // output. You should repeat this until the NextToken response element comes + // back as null. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s ListChildrenOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListChildrenOutput) GoString() string { + return s.String() +} + +// SetChildren sets the Children field's value. +func (s *ListChildrenOutput) SetChildren(v []*Child) *ListChildrenOutput { + s.Children = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListChildrenOutput) SetNextToken(v string) *ListChildrenOutput { + s.NextToken = &v + return s +} + +type ListCreateAccountStatusInput struct { + _ struct{} `type:"structure"` + + // (Optional) Use this to limit the number of results you want included in the + // response. If you do not include this parameter, it defaults to a value that + // is specific to the operation. If additional items exist beyond the maximum + // you specify, the NextToken response element is present and has a value (is + // not null). Include that value as the NextToken request parameter in the next + // call to the operation to get the next part of the results. Note that Organizations + // might return fewer results than the maximum even when there are more results + // available. You should check NextToken after every operation to ensure that + // you receive all of the results. + MaxResults *int64 `min:"1" type:"integer"` + + // Use this parameter if you receive a NextToken response in a previous request + // that indicates that there is more output available. Set it to the value of + // the previous call's NextToken response to indicate where the output should + // continue from. + NextToken *string `type:"string"` + + // A list of one or more states that you want included in the response. If this + // parameter is not present, then all requests are included in the response. + States []*string `type:"list"` +} + +// String returns the string representation +func (s ListCreateAccountStatusInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListCreateAccountStatusInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListCreateAccountStatusInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListCreateAccountStatusInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMaxResults sets the MaxResults field's value. +func (s *ListCreateAccountStatusInput) SetMaxResults(v int64) *ListCreateAccountStatusInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListCreateAccountStatusInput) SetNextToken(v string) *ListCreateAccountStatusInput { + s.NextToken = &v + return s +} + +// SetStates sets the States field's value. +func (s *ListCreateAccountStatusInput) SetStates(v []*string) *ListCreateAccountStatusInput { + s.States = v + return s +} + +type ListCreateAccountStatusOutput struct { + _ struct{} `type:"structure"` + + // A list of objects with details about the requests. Certain elements, such + // as the accountId number, are present in the output only after the account + // has been successfully created. + CreateAccountStatuses []*CreateAccountStatus `type:"list"` + + // If present, this value indicates that there is more output available than + // is included in the current response. Use this value in the NextToken request + // parameter in a subsequent call to the operation to get the next part of the + // output. You should repeat this until the NextToken response element comes + // back as null. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s ListCreateAccountStatusOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListCreateAccountStatusOutput) GoString() string { + return s.String() +} + +// SetCreateAccountStatuses sets the CreateAccountStatuses field's value. +func (s *ListCreateAccountStatusOutput) SetCreateAccountStatuses(v []*CreateAccountStatus) *ListCreateAccountStatusOutput { + s.CreateAccountStatuses = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListCreateAccountStatusOutput) SetNextToken(v string) *ListCreateAccountStatusOutput { + s.NextToken = &v + return s +} + +type ListHandshakesForAccountInput struct { + _ struct{} `type:"structure"` + + // Filters the handshakes that you want included in the response. The default + // is all types. Use the ActionType element to limit the output to only a specified + // type, such as INVITE, ENABLE-FULL-CONTROL, or APPROVE-FULL-CONTROL. Alternatively, + // for the ENABLE-FULL-CONTROL handshake that generates a separate child handshake + // for each member account, you can specify ParentHandshakeId to see only the + // handshakes that were generated by that parent request. + Filter *HandshakeFilter `type:"structure"` + + // (Optional) Use this to limit the number of results you want included in the + // response. If you do not include this parameter, it defaults to a value that + // is specific to the operation. If additional items exist beyond the maximum + // you specify, the NextToken response element is present and has a value (is + // not null). Include that value as the NextToken request parameter in the next + // call to the operation to get the next part of the results. Note that Organizations + // might return fewer results than the maximum even when there are more results + // available. You should check NextToken after every operation to ensure that + // you receive all of the results. + MaxResults *int64 `min:"1" type:"integer"` + + // Use this parameter if you receive a NextToken response in a previous request + // that indicates that there is more output available. Set it to the value of + // the previous call's NextToken response to indicate where the output should + // continue from. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s ListHandshakesForAccountInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListHandshakesForAccountInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListHandshakesForAccountInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListHandshakesForAccountInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFilter sets the Filter field's value. +func (s *ListHandshakesForAccountInput) SetFilter(v *HandshakeFilter) *ListHandshakesForAccountInput { + s.Filter = v + return s +} + +// SetMaxResults sets the MaxResults field's value. +func (s *ListHandshakesForAccountInput) SetMaxResults(v int64) *ListHandshakesForAccountInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListHandshakesForAccountInput) SetNextToken(v string) *ListHandshakesForAccountInput { + s.NextToken = &v + return s +} + +type ListHandshakesForAccountOutput struct { + _ struct{} `type:"structure"` + + // A list of Handshake objects with details about each of the handshakes that + // is associated with the specified account. + Handshakes []*Handshake `type:"list"` + + // If present, this value indicates that there is more output available than + // is included in the current response. Use this value in the NextToken request + // parameter in a subsequent call to the operation to get the next part of the + // output. You should repeat this until the NextToken response element comes + // back as null. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s ListHandshakesForAccountOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListHandshakesForAccountOutput) GoString() string { + return s.String() +} + +// SetHandshakes sets the Handshakes field's value. +func (s *ListHandshakesForAccountOutput) SetHandshakes(v []*Handshake) *ListHandshakesForAccountOutput { + s.Handshakes = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListHandshakesForAccountOutput) SetNextToken(v string) *ListHandshakesForAccountOutput { + s.NextToken = &v + return s +} + +type ListHandshakesForOrganizationInput struct { + _ struct{} `type:"structure"` + + // A filter of the handshakes that you want included in the response. The default + // is all types. Use the ActionType element to limit the output to only a specified + // type, such as INVITE, ENABLE-ALL-FEATURES, or APPROVE-ALL-FEATURES. Alternatively, + // for the ENABLE-ALL-FEATURES handshake that generates a separate child handshake + // for each member account, you can specify the ParentHandshakeId to see only + // the handshakes that were generated by that parent request. + Filter *HandshakeFilter `type:"structure"` + + // (Optional) Use this to limit the number of results you want included in the + // response. If you do not include this parameter, it defaults to a value that + // is specific to the operation. If additional items exist beyond the maximum + // you specify, the NextToken response element is present and has a value (is + // not null). Include that value as the NextToken request parameter in the next + // call to the operation to get the next part of the results. Note that Organizations + // might return fewer results than the maximum even when there are more results + // available. You should check NextToken after every operation to ensure that + // you receive all of the results. + MaxResults *int64 `min:"1" type:"integer"` + + // Use this parameter if you receive a NextToken response in a previous request + // that indicates that there is more output available. Set it to the value of + // the previous call's NextToken response to indicate where the output should + // continue from. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s ListHandshakesForOrganizationInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListHandshakesForOrganizationInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListHandshakesForOrganizationInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListHandshakesForOrganizationInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFilter sets the Filter field's value. +func (s *ListHandshakesForOrganizationInput) SetFilter(v *HandshakeFilter) *ListHandshakesForOrganizationInput { + s.Filter = v + return s +} + +// SetMaxResults sets the MaxResults field's value. +func (s *ListHandshakesForOrganizationInput) SetMaxResults(v int64) *ListHandshakesForOrganizationInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListHandshakesForOrganizationInput) SetNextToken(v string) *ListHandshakesForOrganizationInput { + s.NextToken = &v + return s +} + +type ListHandshakesForOrganizationOutput struct { + _ struct{} `type:"structure"` + + // A list of Handshake objects with details about each of the handshakes that + // are associated with an organization. + Handshakes []*Handshake `type:"list"` + + // If present, this value indicates that there is more output available than + // is included in the current response. Use this value in the NextToken request + // parameter in a subsequent call to the operation to get the next part of the + // output. You should repeat this until the NextToken response element comes + // back as null. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s ListHandshakesForOrganizationOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListHandshakesForOrganizationOutput) GoString() string { + return s.String() +} + +// SetHandshakes sets the Handshakes field's value. +func (s *ListHandshakesForOrganizationOutput) SetHandshakes(v []*Handshake) *ListHandshakesForOrganizationOutput { + s.Handshakes = v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListHandshakesForOrganizationOutput) SetNextToken(v string) *ListHandshakesForOrganizationOutput { + s.NextToken = &v + return s +} + +type ListOrganizationalUnitsForParentInput struct { + _ struct{} `type:"structure"` + + // (Optional) Use this to limit the number of results you want included in the + // response. If you do not include this parameter, it defaults to a value that + // is specific to the operation. If additional items exist beyond the maximum + // you specify, the NextToken response element is present and has a value (is + // not null). Include that value as the NextToken request parameter in the next + // call to the operation to get the next part of the results. Note that Organizations + // might return fewer results than the maximum even when there are more results + // available. You should check NextToken after every operation to ensure that + // you receive all of the results. + MaxResults *int64 `min:"1" type:"integer"` + + // Use this parameter if you receive a NextToken response in a previous request + // that indicates that there is more output available. Set it to the value of + // the previous call's NextToken response to indicate where the output should + // continue from. + NextToken *string `type:"string"` + + // The unique identifier (ID) of the root or OU whose child OUs you want to + // list. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a parent ID string + // requires one of the following: + // + // * Root: a string that begins with "r-" followed by from 4 to 32 lower-case + // letters or digits. + // + // * Organizational unit (OU): a string that begins with "ou-" followed by + // from 4 to 32 lower-case letters or digits (the ID of the root that the + // OU is in) followed by a second "-" dash and from 8 to 32 additional lower-case + // letters or digits. + // + // ParentId is a required field + ParentId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s ListOrganizationalUnitsForParentInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListOrganizationalUnitsForParentInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListOrganizationalUnitsForParentInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListOrganizationalUnitsForParentInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.ParentId == nil { + invalidParams.Add(request.NewErrParamRequired("ParentId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMaxResults sets the MaxResults field's value. +func (s *ListOrganizationalUnitsForParentInput) SetMaxResults(v int64) *ListOrganizationalUnitsForParentInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListOrganizationalUnitsForParentInput) SetNextToken(v string) *ListOrganizationalUnitsForParentInput { + s.NextToken = &v + return s +} + +// SetParentId sets the ParentId field's value. +func (s *ListOrganizationalUnitsForParentInput) SetParentId(v string) *ListOrganizationalUnitsForParentInput { + s.ParentId = &v + return s +} + +type ListOrganizationalUnitsForParentOutput struct { + _ struct{} `type:"structure"` + + // If present, this value indicates that there is more output available than + // is included in the current response. Use this value in the NextToken request + // parameter in a subsequent call to the operation to get the next part of the + // output. You should repeat this until the NextToken response element comes + // back as null. + NextToken *string `type:"string"` + + // A list of the OUs in the specified root or parent OU. + OrganizationalUnits []*OrganizationalUnit `type:"list"` +} + +// String returns the string representation +func (s ListOrganizationalUnitsForParentOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListOrganizationalUnitsForParentOutput) GoString() string { + return s.String() +} + +// SetNextToken sets the NextToken field's value. +func (s *ListOrganizationalUnitsForParentOutput) SetNextToken(v string) *ListOrganizationalUnitsForParentOutput { + s.NextToken = &v + return s +} + +// SetOrganizationalUnits sets the OrganizationalUnits field's value. +func (s *ListOrganizationalUnitsForParentOutput) SetOrganizationalUnits(v []*OrganizationalUnit) *ListOrganizationalUnitsForParentOutput { + s.OrganizationalUnits = v + return s +} + +type ListParentsInput struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) of the OU or account whose parent containers you + // want to list. Do not specify a root. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a child ID string + // requires one of the following: + // + // * Account: a string that consists of exactly 12 digits. + // + // * Organizational unit (OU): a string that begins with "ou-" followed by + // from 4 to 32 lower-case letters or digits (the ID of the root that contains + // the OU) followed by a second "-" dash and from 8 to 32 additional lower-case + // letters or digits. + // + // ChildId is a required field + ChildId *string `type:"string" required:"true"` + + // (Optional) Use this to limit the number of results you want included in the + // response. If you do not include this parameter, it defaults to a value that + // is specific to the operation. If additional items exist beyond the maximum + // you specify, the NextToken response element is present and has a value (is + // not null). Include that value as the NextToken request parameter in the next + // call to the operation to get the next part of the results. Note that Organizations + // might return fewer results than the maximum even when there are more results + // available. You should check NextToken after every operation to ensure that + // you receive all of the results. + MaxResults *int64 `min:"1" type:"integer"` + + // Use this parameter if you receive a NextToken response in a previous request + // that indicates that there is more output available. Set it to the value of + // the previous call's NextToken response to indicate where the output should + // continue from. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s ListParentsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListParentsInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListParentsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListParentsInput"} + if s.ChildId == nil { + invalidParams.Add(request.NewErrParamRequired("ChildId")) + } + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetChildId sets the ChildId field's value. +func (s *ListParentsInput) SetChildId(v string) *ListParentsInput { + s.ChildId = &v + return s +} + +// SetMaxResults sets the MaxResults field's value. +func (s *ListParentsInput) SetMaxResults(v int64) *ListParentsInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListParentsInput) SetNextToken(v string) *ListParentsInput { + s.NextToken = &v + return s +} + +type ListParentsOutput struct { + _ struct{} `type:"structure"` + + // If present, this value indicates that there is more output available than + // is included in the current response. Use this value in the NextToken request + // parameter in a subsequent call to the operation to get the next part of the + // output. You should repeat this until the NextToken response element comes + // back as null. + NextToken *string `type:"string"` + + // A list of parents for the specified child account or OU. + Parents []*Parent `type:"list"` +} + +// String returns the string representation +func (s ListParentsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListParentsOutput) GoString() string { + return s.String() +} + +// SetNextToken sets the NextToken field's value. +func (s *ListParentsOutput) SetNextToken(v string) *ListParentsOutput { + s.NextToken = &v + return s +} + +// SetParents sets the Parents field's value. +func (s *ListParentsOutput) SetParents(v []*Parent) *ListParentsOutput { + s.Parents = v + return s +} + +type ListPoliciesForTargetInput struct { + _ struct{} `type:"structure"` + + // The type of policy that you want to include in the returned list. + // + // Filter is a required field + Filter *string `type:"string" required:"true" enum:"PolicyType"` + + // (Optional) Use this to limit the number of results you want included in the + // response. If you do not include this parameter, it defaults to a value that + // is specific to the operation. If additional items exist beyond the maximum + // you specify, the NextToken response element is present and has a value (is + // not null). Include that value as the NextToken request parameter in the next + // call to the operation to get the next part of the results. Note that Organizations + // might return fewer results than the maximum even when there are more results + // available. You should check NextToken after every operation to ensure that + // you receive all of the results. + MaxResults *int64 `min:"1" type:"integer"` + + // Use this parameter if you receive a NextToken response in a previous request + // that indicates that there is more output available. Set it to the value of + // the previous call's NextToken response to indicate where the output should + // continue from. + NextToken *string `type:"string"` + + // The unique identifier (ID) of the root, organizational unit, or account whose + // policies you want to list. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a target ID string + // requires one of the following: + // + // * Root: a string that begins with "r-" followed by from 4 to 32 lower-case + // letters or digits. + // + // * Account: a string that consists of exactly 12 digits. + // + // * Organizational unit (OU): a string that begins with "ou-" followed by + // from 4 to 32 lower-case letters or digits (the ID of the root that the + // OU is in) followed by a second "-" dash and from 8 to 32 additional lower-case + // letters or digits. + // + // TargetId is a required field + TargetId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s ListPoliciesForTargetInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListPoliciesForTargetInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListPoliciesForTargetInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListPoliciesForTargetInput"} + if s.Filter == nil { + invalidParams.Add(request.NewErrParamRequired("Filter")) + } + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.TargetId == nil { + invalidParams.Add(request.NewErrParamRequired("TargetId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFilter sets the Filter field's value. +func (s *ListPoliciesForTargetInput) SetFilter(v string) *ListPoliciesForTargetInput { + s.Filter = &v + return s +} + +// SetMaxResults sets the MaxResults field's value. +func (s *ListPoliciesForTargetInput) SetMaxResults(v int64) *ListPoliciesForTargetInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListPoliciesForTargetInput) SetNextToken(v string) *ListPoliciesForTargetInput { + s.NextToken = &v + return s +} + +// SetTargetId sets the TargetId field's value. +func (s *ListPoliciesForTargetInput) SetTargetId(v string) *ListPoliciesForTargetInput { + s.TargetId = &v + return s +} + +type ListPoliciesForTargetOutput struct { + _ struct{} `type:"structure"` + + // If present, this value indicates that there is more output available than + // is included in the current response. Use this value in the NextToken request + // parameter in a subsequent call to the operation to get the next part of the + // output. You should repeat this until the NextToken response element comes + // back as null. + NextToken *string `type:"string"` + + // The list of policies that match the criteria in the request. + Policies []*PolicySummary `type:"list"` +} + +// String returns the string representation +func (s ListPoliciesForTargetOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListPoliciesForTargetOutput) GoString() string { + return s.String() +} + +// SetNextToken sets the NextToken field's value. +func (s *ListPoliciesForTargetOutput) SetNextToken(v string) *ListPoliciesForTargetOutput { + s.NextToken = &v + return s +} + +// SetPolicies sets the Policies field's value. +func (s *ListPoliciesForTargetOutput) SetPolicies(v []*PolicySummary) *ListPoliciesForTargetOutput { + s.Policies = v + return s +} + +type ListPoliciesInput struct { + _ struct{} `type:"structure"` + + // Specifies the type of policy that you want to include in the response. + // + // Filter is a required field + Filter *string `type:"string" required:"true" enum:"PolicyType"` + + // (Optional) Use this to limit the number of results you want included in the + // response. If you do not include this parameter, it defaults to a value that + // is specific to the operation. If additional items exist beyond the maximum + // you specify, the NextToken response element is present and has a value (is + // not null). Include that value as the NextToken request parameter in the next + // call to the operation to get the next part of the results. Note that Organizations + // might return fewer results than the maximum even when there are more results + // available. You should check NextToken after every operation to ensure that + // you receive all of the results. + MaxResults *int64 `min:"1" type:"integer"` + + // Use this parameter if you receive a NextToken response in a previous request + // that indicates that there is more output available. Set it to the value of + // the previous call's NextToken response to indicate where the output should + // continue from. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s ListPoliciesInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListPoliciesInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListPoliciesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListPoliciesInput"} + if s.Filter == nil { + invalidParams.Add(request.NewErrParamRequired("Filter")) + } + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFilter sets the Filter field's value. +func (s *ListPoliciesInput) SetFilter(v string) *ListPoliciesInput { + s.Filter = &v + return s +} + +// SetMaxResults sets the MaxResults field's value. +func (s *ListPoliciesInput) SetMaxResults(v int64) *ListPoliciesInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListPoliciesInput) SetNextToken(v string) *ListPoliciesInput { + s.NextToken = &v + return s +} + +type ListPoliciesOutput struct { + _ struct{} `type:"structure"` + + // If present, this value indicates that there is more output available than + // is included in the current response. Use this value in the NextToken request + // parameter in a subsequent call to the operation to get the next part of the + // output. You should repeat this until the NextToken response element comes + // back as null. + NextToken *string `type:"string"` + + // A list of policies that match the filter criteria in the request. The output + // list does not include the policy contents. To see the content for a policy, + // see DescribePolicy. + Policies []*PolicySummary `type:"list"` +} + +// String returns the string representation +func (s ListPoliciesOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListPoliciesOutput) GoString() string { + return s.String() +} + +// SetNextToken sets the NextToken field's value. +func (s *ListPoliciesOutput) SetNextToken(v string) *ListPoliciesOutput { + s.NextToken = &v + return s +} + +// SetPolicies sets the Policies field's value. +func (s *ListPoliciesOutput) SetPolicies(v []*PolicySummary) *ListPoliciesOutput { + s.Policies = v + return s +} + +type ListRootsInput struct { + _ struct{} `type:"structure"` + + // (Optional) Use this to limit the number of results you want included in the + // response. If you do not include this parameter, it defaults to a value that + // is specific to the operation. If additional items exist beyond the maximum + // you specify, the NextToken response element is present and has a value (is + // not null). Include that value as the NextToken request parameter in the next + // call to the operation to get the next part of the results. Note that Organizations + // might return fewer results than the maximum even when there are more results + // available. You should check NextToken after every operation to ensure that + // you receive all of the results. + MaxResults *int64 `min:"1" type:"integer"` + + // Use this parameter if you receive a NextToken response in a previous request + // that indicates that there is more output available. Set it to the value of + // the previous call's NextToken response to indicate where the output should + // continue from. + NextToken *string `type:"string"` +} + +// String returns the string representation +func (s ListRootsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListRootsInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListRootsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListRootsInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMaxResults sets the MaxResults field's value. +func (s *ListRootsInput) SetMaxResults(v int64) *ListRootsInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListRootsInput) SetNextToken(v string) *ListRootsInput { + s.NextToken = &v + return s +} + +type ListRootsOutput struct { + _ struct{} `type:"structure"` + + // If present, this value indicates that there is more output available than + // is included in the current response. Use this value in the NextToken request + // parameter in a subsequent call to the operation to get the next part of the + // output. You should repeat this until the NextToken response element comes + // back as null. + NextToken *string `type:"string"` + + // A list of roots that are defined in an organization. + Roots []*Root `type:"list"` +} + +// String returns the string representation +func (s ListRootsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListRootsOutput) GoString() string { + return s.String() +} + +// SetNextToken sets the NextToken field's value. +func (s *ListRootsOutput) SetNextToken(v string) *ListRootsOutput { + s.NextToken = &v + return s +} + +// SetRoots sets the Roots field's value. +func (s *ListRootsOutput) SetRoots(v []*Root) *ListRootsOutput { + s.Roots = v + return s +} + +type ListTargetsForPolicyInput struct { + _ struct{} `type:"structure"` + + // (Optional) Use this to limit the number of results you want included in the + // response. If you do not include this parameter, it defaults to a value that + // is specific to the operation. If additional items exist beyond the maximum + // you specify, the NextToken response element is present and has a value (is + // not null). Include that value as the NextToken request parameter in the next + // call to the operation to get the next part of the results. Note that Organizations + // might return fewer results than the maximum even when there are more results + // available. You should check NextToken after every operation to ensure that + // you receive all of the results. + MaxResults *int64 `min:"1" type:"integer"` + + // Use this parameter if you receive a NextToken response in a previous request + // that indicates that there is more output available. Set it to the value of + // the previous call's NextToken response to indicate where the output should + // continue from. + NextToken *string `type:"string"` + + // The unique identifier (ID) of the policy for which you want to know its attachments. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a policy ID string + // requires "p-" followed by from 8 to 128 lower-case letters or digits. + // + // PolicyId is a required field + PolicyId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s ListTargetsForPolicyInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListTargetsForPolicyInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListTargetsForPolicyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListTargetsForPolicyInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.PolicyId == nil { + invalidParams.Add(request.NewErrParamRequired("PolicyId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetMaxResults sets the MaxResults field's value. +func (s *ListTargetsForPolicyInput) SetMaxResults(v int64) *ListTargetsForPolicyInput { + s.MaxResults = &v + return s +} + +// SetNextToken sets the NextToken field's value. +func (s *ListTargetsForPolicyInput) SetNextToken(v string) *ListTargetsForPolicyInput { + s.NextToken = &v + return s +} + +// SetPolicyId sets the PolicyId field's value. +func (s *ListTargetsForPolicyInput) SetPolicyId(v string) *ListTargetsForPolicyInput { + s.PolicyId = &v + return s +} + +type ListTargetsForPolicyOutput struct { + _ struct{} `type:"structure"` + + // If present, this value indicates that there is more output available than + // is included in the current response. Use this value in the NextToken request + // parameter in a subsequent call to the operation to get the next part of the + // output. You should repeat this until the NextToken response element comes + // back as null. + NextToken *string `type:"string"` + + // A list of structures, each of which contains details about one of the entities + // to which the specified policy is attached. + Targets []*PolicyTargetSummary `type:"list"` +} + +// String returns the string representation +func (s ListTargetsForPolicyOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListTargetsForPolicyOutput) GoString() string { + return s.String() +} + +// SetNextToken sets the NextToken field's value. +func (s *ListTargetsForPolicyOutput) SetNextToken(v string) *ListTargetsForPolicyOutput { + s.NextToken = &v + return s +} + +// SetTargets sets the Targets field's value. +func (s *ListTargetsForPolicyOutput) SetTargets(v []*PolicyTargetSummary) *ListTargetsForPolicyOutput { + s.Targets = v + return s +} + +type MoveAccountInput struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) of the account that you want to move. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for an account ID string + // requires exactly 12 digits. + // + // AccountId is a required field + AccountId *string `type:"string" required:"true"` + + // The unique identifier (ID) of the root or organizational unit that you want + // to move the account to. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a parent ID string + // requires one of the following: + // + // * Root: a string that begins with "r-" followed by from 4 to 32 lower-case + // letters or digits. + // + // * Organizational unit (OU): a string that begins with "ou-" followed by + // from 4 to 32 lower-case letters or digits (the ID of the root that the + // OU is in) followed by a second "-" dash and from 8 to 32 additional lower-case + // letters or digits. + // + // DestinationParentId is a required field + DestinationParentId *string `type:"string" required:"true"` + + // The unique identifier (ID) of the root or organizational unit that you want + // to move the account from. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a parent ID string + // requires one of the following: + // + // * Root: a string that begins with "r-" followed by from 4 to 32 lower-case + // letters or digits. + // + // * Organizational unit (OU): a string that begins with "ou-" followed by + // from 4 to 32 lower-case letters or digits (the ID of the root that the + // OU is in) followed by a second "-" dash and from 8 to 32 additional lower-case + // letters or digits. + // + // SourceParentId is a required field + SourceParentId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s MoveAccountInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s MoveAccountInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *MoveAccountInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "MoveAccountInput"} + if s.AccountId == nil { + invalidParams.Add(request.NewErrParamRequired("AccountId")) + } + if s.DestinationParentId == nil { + invalidParams.Add(request.NewErrParamRequired("DestinationParentId")) + } + if s.SourceParentId == nil { + invalidParams.Add(request.NewErrParamRequired("SourceParentId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAccountId sets the AccountId field's value. +func (s *MoveAccountInput) SetAccountId(v string) *MoveAccountInput { + s.AccountId = &v + return s +} + +// SetDestinationParentId sets the DestinationParentId field's value. +func (s *MoveAccountInput) SetDestinationParentId(v string) *MoveAccountInput { + s.DestinationParentId = &v + return s +} + +// SetSourceParentId sets the SourceParentId field's value. +func (s *MoveAccountInput) SetSourceParentId(v string) *MoveAccountInput { + s.SourceParentId = &v + return s +} + +type MoveAccountOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s MoveAccountOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s MoveAccountOutput) GoString() string { + return s.String() +} + +// Contains details about an organization. An organization is a collection of +// accounts that are centrally managed together using consolidated billing, +// organized hierarchically with organizational units (OUs), and controlled +// with policies . +type Organization struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of an organization. + // + // For more information about ARNs in Organizations, see ARN Formats Supported + // by Organizations (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_permissions.html#orgs-permissions-arns) + // in the AWS Organizations User Guide. + Arn *string `type:"string"` + + // A list of policy types that are enabled for this organization. For example, + // if your organization has all features enabled, then service control policies + // (SCPs) are included in the list. + // + // Even if a policy type is shown as available in the organization, you can + // separately enable and disable them at the root level by using EnablePolicyType + // and DisablePolicyType. Use ListRoots to see the status of a policy type in + // that root. + AvailablePolicyTypes []*PolicyTypeSummary `type:"list"` + + // Specifies the functionality that currently is available to the organization. + // If set to "ALL", then all features are enabled and policies can be applied + // to accounts in the organization. If set to "CONSOLIDATED_BILLING", then only + // consolidated billing functionality is available. For more information, see + // Enabling All Features in Your Organization (http://docs.aws.amazon.com/IAM/latest/UserGuide/orgs_manage_org_support-all-features.html) + // in the AWS Organizations User Guide. + FeatureSet *string `type:"string" enum:"OrganizationFeatureSet"` + + // The unique identifier (ID) of an organization. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for an organization ID + // string requires "o-" followed by from 10 to 32 lower-case letters or digits. + Id *string `type:"string"` + + // The Amazon Resource Name (ARN) of the account that is designated as the master + // account for the organization. + // + // For more information about ARNs in Organizations, see ARN Formats Supported + // by Organizations (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_permissions.html#orgs-permissions-arns) + // in the AWS Organizations User Guide. + MasterAccountArn *string `type:"string"` + + // The email address that is associated with the AWS account that is designated + // as the master account for the organization. + MasterAccountEmail *string `min:"6" type:"string"` + + // The unique identifier (ID) of the master account of an organization. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for an account ID string + // requires exactly 12 digits. + MasterAccountId *string `type:"string"` +} + +// String returns the string representation +func (s Organization) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s Organization) GoString() string { + return s.String() +} + +// SetArn sets the Arn field's value. +func (s *Organization) SetArn(v string) *Organization { + s.Arn = &v + return s +} + +// SetAvailablePolicyTypes sets the AvailablePolicyTypes field's value. +func (s *Organization) SetAvailablePolicyTypes(v []*PolicyTypeSummary) *Organization { + s.AvailablePolicyTypes = v + return s +} + +// SetFeatureSet sets the FeatureSet field's value. +func (s *Organization) SetFeatureSet(v string) *Organization { + s.FeatureSet = &v + return s +} + +// SetId sets the Id field's value. +func (s *Organization) SetId(v string) *Organization { + s.Id = &v + return s +} + +// SetMasterAccountArn sets the MasterAccountArn field's value. +func (s *Organization) SetMasterAccountArn(v string) *Organization { + s.MasterAccountArn = &v + return s +} + +// SetMasterAccountEmail sets the MasterAccountEmail field's value. +func (s *Organization) SetMasterAccountEmail(v string) *Organization { + s.MasterAccountEmail = &v + return s +} + +// SetMasterAccountId sets the MasterAccountId field's value. +func (s *Organization) SetMasterAccountId(v string) *Organization { + s.MasterAccountId = &v + return s +} + +// Contains details about an organizational unit (OU). An OU is a container +// of AWS accounts within a root of an organization. Policies that are attached +// to an OU apply to all accounts contained in that OU and in any child OUs. +type OrganizationalUnit struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of this OU. + // + // For more information about ARNs in Organizations, see ARN Formats Supported + // by Organizations (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_permissions.html#orgs-permissions-arns) + // in the AWS Organizations User Guide. + Arn *string `type:"string"` + + // The unique identifier (ID) associated with this OU. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for an organizational + // unit ID string requires "ou-" followed by from 4 to 32 lower-case letters + // or digits (the ID of the root that contains the OU) followed by a second + // "-" dash and from 8 to 32 additional lower-case letters or digits. + Id *string `type:"string"` + + // The friendly name of this OU. + // + // The regex pattern (http://wikipedia.org/wiki/regex) that is used to validate + // this parameter is a string of any of the characters in the ASCII character + // range. + Name *string `min:"1" type:"string"` +} + +// String returns the string representation +func (s OrganizationalUnit) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s OrganizationalUnit) GoString() string { + return s.String() +} + +// SetArn sets the Arn field's value. +func (s *OrganizationalUnit) SetArn(v string) *OrganizationalUnit { + s.Arn = &v + return s +} + +// SetId sets the Id field's value. +func (s *OrganizationalUnit) SetId(v string) *OrganizationalUnit { + s.Id = &v + return s +} + +// SetName sets the Name field's value. +func (s *OrganizationalUnit) SetName(v string) *OrganizationalUnit { + s.Name = &v + return s +} + +// Contains information about either a root or an organizational unit (OU) that +// can contain OUs or accounts in an organization. +type Parent struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) of the parent entity. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a parent ID string + // requires one of the following: + // + // * Root: a string that begins with "r-" followed by from 4 to 32 lower-case + // letters or digits. + // + // * Organizational unit (OU): a string that begins with "ou-" followed by + // from 4 to 32 lower-case letters or digits (the ID of the root that the + // OU is in) followed by a second "-" dash and from 8 to 32 additional lower-case + // letters or digits. + Id *string `type:"string"` + + // The type of the parent entity. + Type *string `type:"string" enum:"ParentType"` +} + +// String returns the string representation +func (s Parent) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s Parent) GoString() string { + return s.String() +} + +// SetId sets the Id field's value. +func (s *Parent) SetId(v string) *Parent { + s.Id = &v + return s +} + +// SetType sets the Type field's value. +func (s *Parent) SetType(v string) *Parent { + s.Type = &v + return s +} + +// Contains rules to be applied to the affected accounts. Policies can be attached +// directly to accounts, or to roots and OUs to affect all accounts in those +// hierarchies. +type Policy struct { + _ struct{} `type:"structure"` + + // The text content of the policy. + Content *string `min:"1" type:"string"` + + // A structure that contains additional details about the policy. + PolicySummary *PolicySummary `type:"structure"` +} + +// String returns the string representation +func (s Policy) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s Policy) GoString() string { + return s.String() +} + +// SetContent sets the Content field's value. +func (s *Policy) SetContent(v string) *Policy { + s.Content = &v + return s +} + +// SetPolicySummary sets the PolicySummary field's value. +func (s *Policy) SetPolicySummary(v *PolicySummary) *Policy { + s.PolicySummary = v + return s +} + +// Contains information about a policy, but does not include the content. To +// see the content of a policy, see DescribePolicy. +type PolicySummary struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the policy. + // + // For more information about ARNs in Organizations, see ARN Formats Supported + // by Organizations (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_permissions.html#orgs-permissions-arns) + // in the AWS Organizations User Guide. + Arn *string `type:"string"` + + // A boolean value that indicates whether the specified policy is an AWS managed + // policy. If true, then you can attach the policy to roots, OUs, or accounts, + // but you cannot edit it. + AwsManaged *bool `type:"boolean"` + + // The description of the policy. + Description *string `type:"string"` + + // The unique identifier (ID) of the policy. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a policy ID string + // requires "p-" followed by from 8 to 128 lower-case letters or digits. + Id *string `type:"string"` + + // The friendly name of the policy. + // + // The regex pattern (http://wikipedia.org/wiki/regex) that is used to validate + // this parameter is a string of any of the characters in the ASCII character + // range. + Name *string `min:"1" type:"string"` + + // The type of policy. + Type *string `type:"string" enum:"PolicyType"` +} + +// String returns the string representation +func (s PolicySummary) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PolicySummary) GoString() string { + return s.String() +} + +// SetArn sets the Arn field's value. +func (s *PolicySummary) SetArn(v string) *PolicySummary { + s.Arn = &v + return s +} + +// SetAwsManaged sets the AwsManaged field's value. +func (s *PolicySummary) SetAwsManaged(v bool) *PolicySummary { + s.AwsManaged = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *PolicySummary) SetDescription(v string) *PolicySummary { + s.Description = &v + return s +} + +// SetId sets the Id field's value. +func (s *PolicySummary) SetId(v string) *PolicySummary { + s.Id = &v + return s +} + +// SetName sets the Name field's value. +func (s *PolicySummary) SetName(v string) *PolicySummary { + s.Name = &v + return s +} + +// SetType sets the Type field's value. +func (s *PolicySummary) SetType(v string) *PolicySummary { + s.Type = &v + return s +} + +// Contains information about a root, OU, or account that a policy is attached +// to. +type PolicyTargetSummary struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the policy target. + // + // For more information about ARNs in Organizations, see ARN Formats Supported + // by Organizations (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_permissions.html#orgs-permissions-arns) + // in the AWS Organizations User Guide. + Arn *string `type:"string"` + + // The friendly name of the policy target. + // + // The regex pattern (http://wikipedia.org/wiki/regex) that is used to validate + // this parameter is a string of any of the characters in the ASCII character + // range. + Name *string `min:"1" type:"string"` + + // The unique identifier (ID) of the policy target. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a target ID string + // requires one of the following: + // + // * Root: a string that begins with "r-" followed by from 4 to 32 lower-case + // letters or digits. + // + // * Account: a string that consists of exactly 12 digits. + // + // * Organizational unit (OU): a string that begins with "ou-" followed by + // from 4 to 32 lower-case letters or digits (the ID of the root that the + // OU is in) followed by a second "-" dash and from 8 to 32 additional lower-case + // letters or digits. + TargetId *string `type:"string"` + + // The type of the policy target. + Type *string `type:"string" enum:"TargetType"` +} + +// String returns the string representation +func (s PolicyTargetSummary) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PolicyTargetSummary) GoString() string { + return s.String() +} + +// SetArn sets the Arn field's value. +func (s *PolicyTargetSummary) SetArn(v string) *PolicyTargetSummary { + s.Arn = &v + return s +} + +// SetName sets the Name field's value. +func (s *PolicyTargetSummary) SetName(v string) *PolicyTargetSummary { + s.Name = &v + return s +} + +// SetTargetId sets the TargetId field's value. +func (s *PolicyTargetSummary) SetTargetId(v string) *PolicyTargetSummary { + s.TargetId = &v + return s +} + +// SetType sets the Type field's value. +func (s *PolicyTargetSummary) SetType(v string) *PolicyTargetSummary { + s.Type = &v + return s +} + +// Contains information about a policy type and its status in the associated +// root. +type PolicyTypeSummary struct { + _ struct{} `type:"structure"` + + // The status of the policy type as it relates to the associated root. To attach + // a policy of the specified type to a root or to an OU or account in that root, + // it must be available in the organization and enabled for that root. + Status *string `type:"string" enum:"PolicyTypeStatus"` + + // The name of the policy type. + Type *string `type:"string" enum:"PolicyType"` +} + +// String returns the string representation +func (s PolicyTypeSummary) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PolicyTypeSummary) GoString() string { + return s.String() +} + +// SetStatus sets the Status field's value. +func (s *PolicyTypeSummary) SetStatus(v string) *PolicyTypeSummary { + s.Status = &v + return s +} + +// SetType sets the Type field's value. +func (s *PolicyTypeSummary) SetType(v string) *PolicyTypeSummary { + s.Type = &v + return s +} + +type RemoveAccountFromOrganizationInput struct { + _ struct{} `type:"structure"` + + // The unique identifier (ID) of the member account that you want to remove + // from the organization. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for an account ID string + // requires exactly 12 digits. + // + // AccountId is a required field + AccountId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s RemoveAccountFromOrganizationInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s RemoveAccountFromOrganizationInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *RemoveAccountFromOrganizationInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "RemoveAccountFromOrganizationInput"} + if s.AccountId == nil { + invalidParams.Add(request.NewErrParamRequired("AccountId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAccountId sets the AccountId field's value. +func (s *RemoveAccountFromOrganizationInput) SetAccountId(v string) *RemoveAccountFromOrganizationInput { + s.AccountId = &v + return s +} + +type RemoveAccountFromOrganizationOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s RemoveAccountFromOrganizationOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s RemoveAccountFromOrganizationOutput) GoString() string { + return s.String() +} + +// Contains details about a root. A root is a top-level parent node in the hierarchy +// of an organization that can contain organizational units (OUs) and accounts. +// Every root contains every AWS account in the organization. Each root enables +// the accounts to be organized in a different way and to have different policy +// types enabled for use in that root. +type Root struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the root. + // + // For more information about ARNs in Organizations, see ARN Formats Supported + // by Organizations (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_permissions.html#orgs-permissions-arns) + // in the AWS Organizations User Guide. + Arn *string `type:"string"` + + // The unique identifier (ID) for the root. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a root ID string + // requires "r-" followed by from 4 to 32 lower-case letters or digits. + Id *string `type:"string"` + + // The friendly name of the root. + // + // The regex pattern (http://wikipedia.org/wiki/regex) that is used to validate + // this parameter is a string of any of the characters in the ASCII character + // range. + Name *string `min:"1" type:"string"` + + // The types of policies that are currently enabled for the root and therefore + // can be attached to the root or to its OUs or accounts. + // + // Even if a policy type is shown as available in the organization, you can + // separately enable and disable them at the root level by using EnablePolicyType + // and DisablePolicyType. Use DescribeOrganization to see the availability of + // the policy types in that organization. + PolicyTypes []*PolicyTypeSummary `type:"list"` +} + +// String returns the string representation +func (s Root) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s Root) GoString() string { + return s.String() +} + +// SetArn sets the Arn field's value. +func (s *Root) SetArn(v string) *Root { + s.Arn = &v + return s +} + +// SetId sets the Id field's value. +func (s *Root) SetId(v string) *Root { + s.Id = &v + return s +} + +// SetName sets the Name field's value. +func (s *Root) SetName(v string) *Root { + s.Name = &v + return s +} + +// SetPolicyTypes sets the PolicyTypes field's value. +func (s *Root) SetPolicyTypes(v []*PolicyTypeSummary) *Root { + s.PolicyTypes = v + return s +} + +type UpdateOrganizationalUnitInput struct { + _ struct{} `type:"structure"` + + // The new name that you want to assign to the OU. + // + // The regex pattern (http://wikipedia.org/wiki/regex) that is used to validate + // this parameter is a string of any of the characters in the ASCII character + // range. + Name *string `min:"1" type:"string"` + + // The unique identifier (ID) of the OU that you want to rename. You can get + // the ID from the ListOrganizationalUnitsForParent operation. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for an organizational + // unit ID string requires "ou-" followed by from 4 to 32 lower-case letters + // or digits (the ID of the root that contains the OU) followed by a second + // "-" dash and from 8 to 32 additional lower-case letters or digits. + // + // OrganizationalUnitId is a required field + OrganizationalUnitId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s UpdateOrganizationalUnitInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateOrganizationalUnitInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *UpdateOrganizationalUnitInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateOrganizationalUnitInput"} + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + if s.OrganizationalUnitId == nil { + invalidParams.Add(request.NewErrParamRequired("OrganizationalUnitId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetName sets the Name field's value. +func (s *UpdateOrganizationalUnitInput) SetName(v string) *UpdateOrganizationalUnitInput { + s.Name = &v + return s +} + +// SetOrganizationalUnitId sets the OrganizationalUnitId field's value. +func (s *UpdateOrganizationalUnitInput) SetOrganizationalUnitId(v string) *UpdateOrganizationalUnitInput { + s.OrganizationalUnitId = &v + return s +} + +type UpdateOrganizationalUnitOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains the details about the specified OU, including its + // new name. + OrganizationalUnit *OrganizationalUnit `type:"structure"` +} + +// String returns the string representation +func (s UpdateOrganizationalUnitOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateOrganizationalUnitOutput) GoString() string { + return s.String() +} + +// SetOrganizationalUnit sets the OrganizationalUnit field's value. +func (s *UpdateOrganizationalUnitOutput) SetOrganizationalUnit(v *OrganizationalUnit) *UpdateOrganizationalUnitOutput { + s.OrganizationalUnit = v + return s +} + +type UpdatePolicyInput struct { + _ struct{} `type:"structure"` + + // If provided, the new content for the policy. The text must be correctly formatted + // JSON that complies with the syntax for the policy's type. For more information, + // see Service Control Policy Syntax (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_scp-syntax.html) + // in the AWS Organizations User Guide. + Content *string `min:"1" type:"string"` + + // If provided, the new description for the policy. + Description *string `type:"string"` + + // If provided, the new name for the policy. + // + // The regex pattern (http://wikipedia.org/wiki/regex) that is used to validate + // this parameter is a string of any of the characters in the ASCII character + // range. + Name *string `min:"1" type:"string"` + + // The unique identifier (ID) of the policy that you want to update. + // + // The regex pattern (http://wikipedia.org/wiki/regex) for a policy ID string + // requires "p-" followed by from 8 to 128 lower-case letters or digits. + // + // PolicyId is a required field + PolicyId *string `type:"string" required:"true"` +} + +// String returns the string representation +func (s UpdatePolicyInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdatePolicyInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *UpdatePolicyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdatePolicyInput"} + if s.Content != nil && len(*s.Content) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Content", 1)) + } + if s.Name != nil && len(*s.Name) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Name", 1)) + } + if s.PolicyId == nil { + invalidParams.Add(request.NewErrParamRequired("PolicyId")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetContent sets the Content field's value. +func (s *UpdatePolicyInput) SetContent(v string) *UpdatePolicyInput { + s.Content = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *UpdatePolicyInput) SetDescription(v string) *UpdatePolicyInput { + s.Description = &v + return s +} + +// SetName sets the Name field's value. +func (s *UpdatePolicyInput) SetName(v string) *UpdatePolicyInput { + s.Name = &v + return s +} + +// SetPolicyId sets the PolicyId field's value. +func (s *UpdatePolicyInput) SetPolicyId(v string) *UpdatePolicyInput { + s.PolicyId = &v + return s +} + +type UpdatePolicyOutput struct { + _ struct{} `type:"structure"` + + // A structure that contains details about the updated policy, showing the requested + // changes. + Policy *Policy `type:"structure"` +} + +// String returns the string representation +func (s UpdatePolicyOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdatePolicyOutput) GoString() string { + return s.String() +} + +// SetPolicy sets the Policy field's value. +func (s *UpdatePolicyOutput) SetPolicy(v *Policy) *UpdatePolicyOutput { + s.Policy = v + return s +} + +const ( + // AccessDeniedForDependencyExceptionReasonAccessDeniedDuringCreateServiceLinkedRole is a AccessDeniedForDependencyExceptionReason enum value + AccessDeniedForDependencyExceptionReasonAccessDeniedDuringCreateServiceLinkedRole = "ACCESS_DENIED_DURING_CREATE_SERVICE_LINKED_ROLE" +) + +const ( + // AccountJoinedMethodInvited is a AccountJoinedMethod enum value + AccountJoinedMethodInvited = "INVITED" + + // AccountJoinedMethodCreated is a AccountJoinedMethod enum value + AccountJoinedMethodCreated = "CREATED" +) + +const ( + // AccountStatusActive is a AccountStatus enum value + AccountStatusActive = "ACTIVE" + + // AccountStatusSuspended is a AccountStatus enum value + AccountStatusSuspended = "SUSPENDED" +) + +const ( + // ActionTypeInvite is a ActionType enum value + ActionTypeInvite = "INVITE" + + // ActionTypeEnableAllFeatures is a ActionType enum value + ActionTypeEnableAllFeatures = "ENABLE_ALL_FEATURES" + + // ActionTypeApproveAllFeatures is a ActionType enum value + ActionTypeApproveAllFeatures = "APPROVE_ALL_FEATURES" + + // ActionTypeAddOrganizationsServiceLinkedRole is a ActionType enum value + ActionTypeAddOrganizationsServiceLinkedRole = "ADD_ORGANIZATIONS_SERVICE_LINKED_ROLE" +) + +const ( + // ChildTypeAccount is a ChildType enum value + ChildTypeAccount = "ACCOUNT" + + // ChildTypeOrganizationalUnit is a ChildType enum value + ChildTypeOrganizationalUnit = "ORGANIZATIONAL_UNIT" +) + +const ( + // ConstraintViolationExceptionReasonAccountNumberLimitExceeded is a ConstraintViolationExceptionReason enum value + ConstraintViolationExceptionReasonAccountNumberLimitExceeded = "ACCOUNT_NUMBER_LIMIT_EXCEEDED" + + // ConstraintViolationExceptionReasonHandshakeRateLimitExceeded is a ConstraintViolationExceptionReason enum value + ConstraintViolationExceptionReasonHandshakeRateLimitExceeded = "HANDSHAKE_RATE_LIMIT_EXCEEDED" + + // ConstraintViolationExceptionReasonOuNumberLimitExceeded is a ConstraintViolationExceptionReason enum value + ConstraintViolationExceptionReasonOuNumberLimitExceeded = "OU_NUMBER_LIMIT_EXCEEDED" + + // ConstraintViolationExceptionReasonOuDepthLimitExceeded is a ConstraintViolationExceptionReason enum value + ConstraintViolationExceptionReasonOuDepthLimitExceeded = "OU_DEPTH_LIMIT_EXCEEDED" + + // ConstraintViolationExceptionReasonPolicyNumberLimitExceeded is a ConstraintViolationExceptionReason enum value + ConstraintViolationExceptionReasonPolicyNumberLimitExceeded = "POLICY_NUMBER_LIMIT_EXCEEDED" + + // ConstraintViolationExceptionReasonMaxPolicyTypeAttachmentLimitExceeded is a ConstraintViolationExceptionReason enum value + ConstraintViolationExceptionReasonMaxPolicyTypeAttachmentLimitExceeded = "MAX_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED" + + // ConstraintViolationExceptionReasonMinPolicyTypeAttachmentLimitExceeded is a ConstraintViolationExceptionReason enum value + ConstraintViolationExceptionReasonMinPolicyTypeAttachmentLimitExceeded = "MIN_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED" + + // ConstraintViolationExceptionReasonAccountCannotLeaveOrganization is a ConstraintViolationExceptionReason enum value + ConstraintViolationExceptionReasonAccountCannotLeaveOrganization = "ACCOUNT_CANNOT_LEAVE_ORGANIZATION" + + // ConstraintViolationExceptionReasonAccountCannotLeaveWithoutEula is a ConstraintViolationExceptionReason enum value + ConstraintViolationExceptionReasonAccountCannotLeaveWithoutEula = "ACCOUNT_CANNOT_LEAVE_WITHOUT_EULA" + + // ConstraintViolationExceptionReasonAccountCannotLeaveWithoutPhoneVerification is a ConstraintViolationExceptionReason enum value + ConstraintViolationExceptionReasonAccountCannotLeaveWithoutPhoneVerification = "ACCOUNT_CANNOT_LEAVE_WITHOUT_PHONE_VERIFICATION" + + // ConstraintViolationExceptionReasonMasterAccountPaymentInstrumentRequired is a ConstraintViolationExceptionReason enum value + ConstraintViolationExceptionReasonMasterAccountPaymentInstrumentRequired = "MASTER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED" + + // ConstraintViolationExceptionReasonMemberAccountPaymentInstrumentRequired is a ConstraintViolationExceptionReason enum value + ConstraintViolationExceptionReasonMemberAccountPaymentInstrumentRequired = "MEMBER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED" + + // ConstraintViolationExceptionReasonAccountCreationRateLimitExceeded is a ConstraintViolationExceptionReason enum value + ConstraintViolationExceptionReasonAccountCreationRateLimitExceeded = "ACCOUNT_CREATION_RATE_LIMIT_EXCEEDED" + + // ConstraintViolationExceptionReasonMasterAccountAddressDoesNotMatchMarketplace is a ConstraintViolationExceptionReason enum value + ConstraintViolationExceptionReasonMasterAccountAddressDoesNotMatchMarketplace = "MASTER_ACCOUNT_ADDRESS_DOES_NOT_MATCH_MARKETPLACE" + + // ConstraintViolationExceptionReasonMasterAccountMissingContactInfo is a ConstraintViolationExceptionReason enum value + ConstraintViolationExceptionReasonMasterAccountMissingContactInfo = "MASTER_ACCOUNT_MISSING_CONTACT_INFO" + + // ConstraintViolationExceptionReasonOrganizationNotInAllFeaturesMode is a ConstraintViolationExceptionReason enum value + ConstraintViolationExceptionReasonOrganizationNotInAllFeaturesMode = "ORGANIZATION_NOT_IN_ALL_FEATURES_MODE" +) + +const ( + // CreateAccountFailureReasonAccountLimitExceeded is a CreateAccountFailureReason enum value + CreateAccountFailureReasonAccountLimitExceeded = "ACCOUNT_LIMIT_EXCEEDED" + + // CreateAccountFailureReasonEmailAlreadyExists is a CreateAccountFailureReason enum value + CreateAccountFailureReasonEmailAlreadyExists = "EMAIL_ALREADY_EXISTS" + + // CreateAccountFailureReasonInvalidAddress is a CreateAccountFailureReason enum value + CreateAccountFailureReasonInvalidAddress = "INVALID_ADDRESS" + + // CreateAccountFailureReasonInvalidEmail is a CreateAccountFailureReason enum value + CreateAccountFailureReasonInvalidEmail = "INVALID_EMAIL" + + // CreateAccountFailureReasonConcurrentAccountModification is a CreateAccountFailureReason enum value + CreateAccountFailureReasonConcurrentAccountModification = "CONCURRENT_ACCOUNT_MODIFICATION" + + // CreateAccountFailureReasonInternalFailure is a CreateAccountFailureReason enum value + CreateAccountFailureReasonInternalFailure = "INTERNAL_FAILURE" +) + +const ( + // CreateAccountStateInProgress is a CreateAccountState enum value + CreateAccountStateInProgress = "IN_PROGRESS" + + // CreateAccountStateSucceeded is a CreateAccountState enum value + CreateAccountStateSucceeded = "SUCCEEDED" + + // CreateAccountStateFailed is a CreateAccountState enum value + CreateAccountStateFailed = "FAILED" +) + +const ( + // HandshakeConstraintViolationExceptionReasonAccountNumberLimitExceeded is a HandshakeConstraintViolationExceptionReason enum value + HandshakeConstraintViolationExceptionReasonAccountNumberLimitExceeded = "ACCOUNT_NUMBER_LIMIT_EXCEEDED" + + // HandshakeConstraintViolationExceptionReasonHandshakeRateLimitExceeded is a HandshakeConstraintViolationExceptionReason enum value + HandshakeConstraintViolationExceptionReasonHandshakeRateLimitExceeded = "HANDSHAKE_RATE_LIMIT_EXCEEDED" + + // HandshakeConstraintViolationExceptionReasonAlreadyInAnOrganization is a HandshakeConstraintViolationExceptionReason enum value + HandshakeConstraintViolationExceptionReasonAlreadyInAnOrganization = "ALREADY_IN_AN_ORGANIZATION" + + // HandshakeConstraintViolationExceptionReasonOrganizationAlreadyHasAllFeatures is a HandshakeConstraintViolationExceptionReason enum value + HandshakeConstraintViolationExceptionReasonOrganizationAlreadyHasAllFeatures = "ORGANIZATION_ALREADY_HAS_ALL_FEATURES" + + // HandshakeConstraintViolationExceptionReasonInviteDisabledDuringEnableAllFeatures is a HandshakeConstraintViolationExceptionReason enum value + HandshakeConstraintViolationExceptionReasonInviteDisabledDuringEnableAllFeatures = "INVITE_DISABLED_DURING_ENABLE_ALL_FEATURES" + + // HandshakeConstraintViolationExceptionReasonPaymentInstrumentRequired is a HandshakeConstraintViolationExceptionReason enum value + HandshakeConstraintViolationExceptionReasonPaymentInstrumentRequired = "PAYMENT_INSTRUMENT_REQUIRED" + + // HandshakeConstraintViolationExceptionReasonOrganizationFromDifferentSellerOfRecord is a HandshakeConstraintViolationExceptionReason enum value + HandshakeConstraintViolationExceptionReasonOrganizationFromDifferentSellerOfRecord = "ORGANIZATION_FROM_DIFFERENT_SELLER_OF_RECORD" + + // HandshakeConstraintViolationExceptionReasonOrganizationMembershipChangeRateLimitExceeded is a HandshakeConstraintViolationExceptionReason enum value + HandshakeConstraintViolationExceptionReasonOrganizationMembershipChangeRateLimitExceeded = "ORGANIZATION_MEMBERSHIP_CHANGE_RATE_LIMIT_EXCEEDED" +) + +const ( + // HandshakePartyTypeAccount is a HandshakePartyType enum value + HandshakePartyTypeAccount = "ACCOUNT" + + // HandshakePartyTypeOrganization is a HandshakePartyType enum value + HandshakePartyTypeOrganization = "ORGANIZATION" + + // HandshakePartyTypeEmail is a HandshakePartyType enum value + HandshakePartyTypeEmail = "EMAIL" +) + +const ( + // HandshakeResourceTypeAccount is a HandshakeResourceType enum value + HandshakeResourceTypeAccount = "ACCOUNT" + + // HandshakeResourceTypeOrganization is a HandshakeResourceType enum value + HandshakeResourceTypeOrganization = "ORGANIZATION" + + // HandshakeResourceTypeOrganizationFeatureSet is a HandshakeResourceType enum value + HandshakeResourceTypeOrganizationFeatureSet = "ORGANIZATION_FEATURE_SET" + + // HandshakeResourceTypeEmail is a HandshakeResourceType enum value + HandshakeResourceTypeEmail = "EMAIL" + + // HandshakeResourceTypeMasterEmail is a HandshakeResourceType enum value + HandshakeResourceTypeMasterEmail = "MASTER_EMAIL" + + // HandshakeResourceTypeMasterName is a HandshakeResourceType enum value + HandshakeResourceTypeMasterName = "MASTER_NAME" + + // HandshakeResourceTypeNotes is a HandshakeResourceType enum value + HandshakeResourceTypeNotes = "NOTES" + + // HandshakeResourceTypeParentHandshake is a HandshakeResourceType enum value + HandshakeResourceTypeParentHandshake = "PARENT_HANDSHAKE" +) + +const ( + // HandshakeStateRequested is a HandshakeState enum value + HandshakeStateRequested = "REQUESTED" + + // HandshakeStateOpen is a HandshakeState enum value + HandshakeStateOpen = "OPEN" + + // HandshakeStateCanceled is a HandshakeState enum value + HandshakeStateCanceled = "CANCELED" + + // HandshakeStateAccepted is a HandshakeState enum value + HandshakeStateAccepted = "ACCEPTED" + + // HandshakeStateDeclined is a HandshakeState enum value + HandshakeStateDeclined = "DECLINED" + + // HandshakeStateExpired is a HandshakeState enum value + HandshakeStateExpired = "EXPIRED" +) + +const ( + // IAMUserAccessToBillingAllow is a IAMUserAccessToBilling enum value + IAMUserAccessToBillingAllow = "ALLOW" + + // IAMUserAccessToBillingDeny is a IAMUserAccessToBilling enum value + IAMUserAccessToBillingDeny = "DENY" +) + +const ( + // InvalidInputExceptionReasonInvalidPartyTypeTarget is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonInvalidPartyTypeTarget = "INVALID_PARTY_TYPE_TARGET" + + // InvalidInputExceptionReasonInvalidSyntaxOrganizationArn is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonInvalidSyntaxOrganizationArn = "INVALID_SYNTAX_ORGANIZATION_ARN" + + // InvalidInputExceptionReasonInvalidSyntaxPolicyId is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonInvalidSyntaxPolicyId = "INVALID_SYNTAX_POLICY_ID" + + // InvalidInputExceptionReasonInvalidEnum is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonInvalidEnum = "INVALID_ENUM" + + // InvalidInputExceptionReasonInvalidListMember is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonInvalidListMember = "INVALID_LIST_MEMBER" + + // InvalidInputExceptionReasonMaxLengthExceeded is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonMaxLengthExceeded = "MAX_LENGTH_EXCEEDED" + + // InvalidInputExceptionReasonMaxValueExceeded is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonMaxValueExceeded = "MAX_VALUE_EXCEEDED" + + // InvalidInputExceptionReasonMinLengthExceeded is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonMinLengthExceeded = "MIN_LENGTH_EXCEEDED" + + // InvalidInputExceptionReasonMinValueExceeded is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonMinValueExceeded = "MIN_VALUE_EXCEEDED" + + // InvalidInputExceptionReasonImmutablePolicy is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonImmutablePolicy = "IMMUTABLE_POLICY" + + // InvalidInputExceptionReasonInvalidPattern is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonInvalidPattern = "INVALID_PATTERN" + + // InvalidInputExceptionReasonInvalidPatternTargetId is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonInvalidPatternTargetId = "INVALID_PATTERN_TARGET_ID" + + // InvalidInputExceptionReasonInputRequired is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonInputRequired = "INPUT_REQUIRED" + + // InvalidInputExceptionReasonInvalidNextToken is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonInvalidNextToken = "INVALID_NEXT_TOKEN" + + // InvalidInputExceptionReasonMaxLimitExceededFilter is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonMaxLimitExceededFilter = "MAX_LIMIT_EXCEEDED_FILTER" + + // InvalidInputExceptionReasonMovingAccountBetweenDifferentRoots is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonMovingAccountBetweenDifferentRoots = "MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS" + + // InvalidInputExceptionReasonInvalidFullNameTarget is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonInvalidFullNameTarget = "INVALID_FULL_NAME_TARGET" + + // InvalidInputExceptionReasonUnrecognizedServicePrincipal is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonUnrecognizedServicePrincipal = "UNRECOGNIZED_SERVICE_PRINCIPAL" + + // InvalidInputExceptionReasonInvalidRoleName is a InvalidInputExceptionReason enum value + InvalidInputExceptionReasonInvalidRoleName = "INVALID_ROLE_NAME" +) + +const ( + // OrganizationFeatureSetAll is a OrganizationFeatureSet enum value + OrganizationFeatureSetAll = "ALL" + + // OrganizationFeatureSetConsolidatedBilling is a OrganizationFeatureSet enum value + OrganizationFeatureSetConsolidatedBilling = "CONSOLIDATED_BILLING" +) + +const ( + // ParentTypeRoot is a ParentType enum value + ParentTypeRoot = "ROOT" + + // ParentTypeOrganizationalUnit is a ParentType enum value + ParentTypeOrganizationalUnit = "ORGANIZATIONAL_UNIT" +) + +const ( + // PolicyTypeServiceControlPolicy is a PolicyType enum value + PolicyTypeServiceControlPolicy = "SERVICE_CONTROL_POLICY" +) + +const ( + // PolicyTypeStatusEnabled is a PolicyTypeStatus enum value + PolicyTypeStatusEnabled = "ENABLED" + + // PolicyTypeStatusPendingEnable is a PolicyTypeStatus enum value + PolicyTypeStatusPendingEnable = "PENDING_ENABLE" + + // PolicyTypeStatusPendingDisable is a PolicyTypeStatus enum value + PolicyTypeStatusPendingDisable = "PENDING_DISABLE" +) + +const ( + // TargetTypeAccount is a TargetType enum value + TargetTypeAccount = "ACCOUNT" + + // TargetTypeOrganizationalUnit is a TargetType enum value + TargetTypeOrganizationalUnit = "ORGANIZATIONAL_UNIT" + + // TargetTypeRoot is a TargetType enum value + TargetTypeRoot = "ROOT" +) diff --git a/vendor/github.com/aws/aws-sdk-go/service/organizations/doc.go b/vendor/github.com/aws/aws-sdk-go/service/organizations/doc.go new file mode 100644 index 000000000000..7838186af7a4 --- /dev/null +++ b/vendor/github.com/aws/aws-sdk-go/service/organizations/doc.go @@ -0,0 +1,137 @@ +// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. + +// Package organizations provides the client and types for making API +// requests to AWS Organizations. +// +// AWS Organizations is a web service that enables you to consolidate your multiple +// AWS accounts into an organization and centrally manage your accounts and +// their resources. +// +// This guide provides descriptions of the Organizations API. For more information +// about using this service, see the AWS Organizations User Guide (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_introduction.html). +// +// API Version +// +// This version of the Organizations API Reference documents the Organizations +// API version 2016-11-28. +// +// As an alternative to using the API directly, you can use one of the AWS SDKs, +// which 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 AWS Organizations. For +// example, the SDKs take care of cryptographically signing requests, managing +// errors, and retrying requests automatically. 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/). +// +// We recommend that you use the AWS SDKs to make programmatic API calls to +// Organizations. However, you also can use the Organizations Query API to make +// direct calls to the Organizations web service. To learn more about the Organizations +// Query API, see Making Query Requests (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_query-requests.html) +// in the AWS Organizations User Guide. Organizations supports GET and POST +// requests for all actions. That is, the API does not require you to use GET +// for some actions and POST for others. However, GET requests are subject to +// the limitation size of a URL. Therefore, for operations that require larger +// sizes, use a POST request. +// +// Signing Requests +// +// When you send HTTP requests to AWS, you must sign the requests so that AWS +// can identify who sent them. You sign requests with your AWS access key, which +// consists of an access key ID and a secret access key. We strongly recommend +// that you do not create an access key for your root account. Anyone who has +// the access key for your root account has unrestricted access to all the resources +// in your account. Instead, create an access key for an IAM user account that +// has administrative privileges. As another option, use AWS Security Token +// Service to generate temporary security credentials, and use those credentials +// to sign requests. +// +// To sign requests, we recommend that you use Signature Version 4 (http://docs.aws.amazon.com/general/latest/gr/signature-version-4.html). +// If you have an existing application that uses Signature Version 2, you do +// not have to update it to use Signature Version 4. However, some operations +// now require Signature Version 4. The documentation for operations that require +// version 4 indicate this requirement. +// +// When you use the AWS Command Line Interface (AWS CLI) or one of the AWS SDKs +// to make requests to AWS, these tools automatically sign the requests for +// you with the access key that you specify when you configure the tools. +// +// In this release, each organization can have only one root. In a future release, +// a single organization will support multiple roots. +// +// Support and Feedback for AWS Organizations +// +// We welcome your feedback. Send your comments to feedback-awsorganizations@amazon.com +// (mailto:feedback-awsorganizations@amazon.com) or post your feedback and questions +// in the AWS Organizations support forum (http://forums.aws.amazon.com/forum.jspa?forumID=219). +// For more information about the AWS support forums, see Forums Help (http://forums.aws.amazon.com/help.jspa). +// +// Endpoint to Call When Using the CLI or the AWS API +// +// For the current release of Organizations, you must specify the us-east-1 +// region for all AWS API and CLI calls. You can do this in the CLI by using +// these parameters and commands: +// +// * Use the following parameter with each command to specify both the endpoint +// and its region: +// +// --endpoint-url https://organizations.us-east-1.amazonaws.com +// +// * Use the default endpoint, but configure your default region with this +// command: +// +// aws configure set default.region us-east-1 +// +// * Use the following parameter with each command to specify the endpoint: +// +// --region us-east-1 +// +// For the various SDKs used to call the APIs, see the documentation for the +// SDK of interest to learn how to direct the requests to a specific endpoint. +// For more information, see Regions and Endpoints (http://docs.aws.amazon.com/general/latest/gr/rande.html#sts_region) +// in the AWS General Reference. +// +// How examples are presented +// +// The JSON returned by the AWS Organizations service as response to your requests +// is returned as a single long string without line breaks or formatting whitespace. +// Both line breaks and whitespace are included in the examples in this guide +// to improve readability. When example input parameters also would result in +// long strings that would extend beyond the screen, we insert line breaks to +// enhance readability. You should always submit the input as a single JSON +// text string. +// +// Recording API Requests +// +// AWS Organizations supports AWS CloudTrail, a service that records AWS API +// calls for your AWS account and delivers log files to an Amazon S3 bucket. +// By using information collected by AWS CloudTrail, you can determine which +// requests were successfully made to Organizations, who made the request, when +// it was made, and so on. For more about AWS Organizations and its support +// for AWS CloudTrail, see Logging AWS Organizations Events with AWS CloudTrail +// (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_cloudtrail-integration.html) +// in the AWS Organizations User Guide. To learn more about CloudTrail, including +// how to turn it on and find your log files, see the AWS CloudTrail User Guide +// (http://docs.aws.amazon.com/awscloudtrail/latest/userguide/what_is_cloud_trail_top_level.html). +// +// See https://docs.aws.amazon.com/goto/WebAPI/organizations-2016-11-28 for more information on this service. +// +// See organizations package documentation for more information. +// https://docs.aws.amazon.com/sdk-for-go/api/service/organizations/ +// +// Using the Client +// +// To contact AWS Organizations with the SDK use the New function to create +// a new service client. With that client you can make API requests to the service. +// These clients are safe to use concurrently. +// +// See the SDK's documentation for more information on how to use the SDK. +// https://docs.aws.amazon.com/sdk-for-go/api/ +// +// See aws.Config documentation for more information on configuring SDK clients. +// https://docs.aws.amazon.com/sdk-for-go/api/aws/#Config +// +// See the AWS Organizations client Organizations for more +// information on creating client for this service. +// https://docs.aws.amazon.com/sdk-for-go/api/service/organizations/#New +package organizations diff --git a/vendor/github.com/aws/aws-sdk-go/service/organizations/errors.go b/vendor/github.com/aws/aws-sdk-go/service/organizations/errors.go new file mode 100644 index 000000000000..7ccbd82e4474 --- /dev/null +++ b/vendor/github.com/aws/aws-sdk-go/service/organizations/errors.go @@ -0,0 +1,455 @@ +// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. + +package organizations + +const ( + + // ErrCodeAWSOrganizationsNotInUseException for service response error code + // "AWSOrganizationsNotInUseException". + // + // Your account is not a member of an organization. To make this request, you + // must use the credentials of an account that belongs to an organization. + ErrCodeAWSOrganizationsNotInUseException = "AWSOrganizationsNotInUseException" + + // ErrCodeAccessDeniedException for service response error code + // "AccessDeniedException". + // + // You don't have permissions to perform the requested operation. The user or + // role that is making the request must have at least one IAM permissions policy + // attached that grants the required permissions. For more information, see + // Access Management (http://docs.aws.amazon.com/IAM/latest/UserGuide/access.html) + // in the IAM User Guide. + ErrCodeAccessDeniedException = "AccessDeniedException" + + // ErrCodeAccessDeniedForDependencyException for service response error code + // "AccessDeniedForDependencyException". + // + // The operation you attempted requires you to have the iam:CreateServiceLinkedRole + // so that Organizations can create the required service-linked role. You do + // not have that permission. + ErrCodeAccessDeniedForDependencyException = "AccessDeniedForDependencyException" + + // ErrCodeAccountNotFoundException for service response error code + // "AccountNotFoundException". + // + // We can't find an AWS account with the AccountId that you specified, or the + // account whose credentials you used to make this request is not a member of + // an organization. + ErrCodeAccountNotFoundException = "AccountNotFoundException" + + // ErrCodeAlreadyInOrganizationException for service response error code + // "AlreadyInOrganizationException". + // + // This account is already a member of an organization. An account can belong + // to only one organization at a time. + ErrCodeAlreadyInOrganizationException = "AlreadyInOrganizationException" + + // ErrCodeChildNotFoundException for service response error code + // "ChildNotFoundException". + // + // We can't find an organizational unit (OU) or AWS account with the ChildId + // that you specified. + ErrCodeChildNotFoundException = "ChildNotFoundException" + + // ErrCodeConcurrentModificationException for service response error code + // "ConcurrentModificationException". + // + // The target of the operation is currently being modified by a different request. + // Try again later. + ErrCodeConcurrentModificationException = "ConcurrentModificationException" + + // ErrCodeConstraintViolationException for service response error code + // "ConstraintViolationException". + // + // Performing this operation violates a minimum or maximum value limit. For + // example, attempting to removing the last SCP from an OU or root, inviting + // or creating too many accounts to the organization, or attaching too many + // policies to an account, OU, or root. This exception includes a reason that + // contains additional information about the violated limit: + // + // Some of the reasons in the following list might not be applicable to this + // specific API or operation: + // + // ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on the number + // of accounts in an organization. If you need more accounts, contact AWS Support + // to request an increase in your limit. + // + // Or, The number of invitations that you tried to send would cause you to exceed + // the limit of accounts in your organization. Send fewer invitations, or contact + // AWS Support to request an increase in the number of accounts. + // + // Note: deleted and closed accounts still count toward your limit. + // + // If you get an exception that indicates that you exceeded your account limits + // for the organization or that you can"t add an account because your organization + // is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). + // + // * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of + // handshakes you can send in one day. + // + // * OU_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the number of organizational + // units you can have in an organization. + // + // * OU_DEPTH_LIMIT_EXCEEDED: You attempted to create an organizational unit + // tree that is too many levels deep. + // + // * POLICY_NUMBER_LIMIT_EXCEEDED. You attempted to exceed the number of + // policies that you can have in an organization. + // + // * MAX_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to exceed the + // number of policies of a certain type that can be attached to an entity + // at one time. + // + // * MIN_POLICY_TYPE_ATTACHMENT_LIMIT_EXCEEDED: You attempted to detach a + // policy from an entity that would cause the entity to have fewer than the + // minimum number of policies of a certain type required. + // + // * ACCOUNT_CANNOT_LEAVE_WITHOUT_EULA: You attempted to remove an account + // from the organization that does not yet have enough information to exist + // as a stand-alone account. This account requires you to first agree to + // the AWS Customer Agreement. Follow the steps at To leave an organization + // when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) + // in the AWS Organizations User Guide. + // + // * ACCOUNT_CANNOT_LEAVE_WITHOUT_PHONE_VERIFICATION: You attempted to remove + // an account from the organization that does not yet have enough information + // to exist as a stand-alone account. This account requires you to first + // complete phone verification. Follow the steps at To leave an organization + // when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) + // in the AWS Organizations User Guide. + // + // * MASTER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To create an organization + // with this account, you first must associate a payment instrument, such + // as a credit card, with the account. Follow the steps at To leave an organization + // when all required account information has not yet been provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) + // in the AWS Organizations User Guide. + // + // * MEMBER_ACCOUNT_PAYMENT_INSTRUMENT_REQUIRED: To complete this operation + // with this member account, you first must associate a payment instrument, + // such as a credit card, with the account. Follow the steps at To leave + // an organization when all required account information has not yet been + // provided (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_remove.html#leave-without-all-info) + // in the AWS Organizations User Guide. + // + // * ACCOUNT_CREATION_RATE_LIMIT_EXCEEDED: You attempted to exceed the number + // of accounts that you can create in one day. + // + // * MASTER_ACCOUNT_ADDRESS_DOES_NOT_MATCH_MARKETPLACE: To create an account + // in this organization, you first must migrate the organization's master + // account to the marketplace that corresponds to the master account's address. + // For example, accounts with India addresses must be associated with the + // AISPL marketplace. All accounts in an organization must be associated + // with the same marketplace. + // + // * MASTER_ACCOUNT_MISSING_CONTACT_INFO: To complete this operation, you + // must first provide contact a valid address and phone number for the master + // account. Then try the operation again. + ErrCodeConstraintViolationException = "ConstraintViolationException" + + // ErrCodeCreateAccountStatusNotFoundException for service response error code + // "CreateAccountStatusNotFoundException". + // + // We can't find an create account request with the CreateAccountRequestId that + // you specified. + ErrCodeCreateAccountStatusNotFoundException = "CreateAccountStatusNotFoundException" + + // ErrCodeDestinationParentNotFoundException for service response error code + // "DestinationParentNotFoundException". + // + // We can't find the destination container (a root or OU) with the ParentId + // that you specified. + ErrCodeDestinationParentNotFoundException = "DestinationParentNotFoundException" + + // ErrCodeDuplicateAccountException for service response error code + // "DuplicateAccountException". + // + // That account is already present in the specified destination. + ErrCodeDuplicateAccountException = "DuplicateAccountException" + + // ErrCodeDuplicateHandshakeException for service response error code + // "DuplicateHandshakeException". + // + // A handshake with the same action and target already exists. For example, + // if you invited an account to join your organization, the invited account + // might already have a pending invitation from this organization. If you intend + // to resend an invitation to an account, ensure that existing handshakes that + // might be considered duplicates are canceled or declined. + ErrCodeDuplicateHandshakeException = "DuplicateHandshakeException" + + // ErrCodeDuplicateOrganizationalUnitException for service response error code + // "DuplicateOrganizationalUnitException". + // + // An organizational unit (OU) with the same name already exists. + ErrCodeDuplicateOrganizationalUnitException = "DuplicateOrganizationalUnitException" + + // ErrCodeDuplicatePolicyAttachmentException for service response error code + // "DuplicatePolicyAttachmentException". + // + // The selected policy is already attached to the specified target. + ErrCodeDuplicatePolicyAttachmentException = "DuplicatePolicyAttachmentException" + + // ErrCodeDuplicatePolicyException for service response error code + // "DuplicatePolicyException". + // + // A policy with the same name already exists. + ErrCodeDuplicatePolicyException = "DuplicatePolicyException" + + // ErrCodeFinalizingOrganizationException for service response error code + // "FinalizingOrganizationException". + // + // AWS Organizations could not finalize the creation of your organization. Try + // again later. If this persists, contact AWS customer support. + ErrCodeFinalizingOrganizationException = "FinalizingOrganizationException" + + // ErrCodeHandshakeAlreadyInStateException for service response error code + // "HandshakeAlreadyInStateException". + // + // The specified handshake is already in the requested state. For example, you + // can't accept a handshake that was already accepted. + ErrCodeHandshakeAlreadyInStateException = "HandshakeAlreadyInStateException" + + // ErrCodeHandshakeConstraintViolationException for service response error code + // "HandshakeConstraintViolationException". + // + // The requested operation would violate the constraint identified in the reason + // code. + // + // Some of the reasons in the following list might not be applicable to this + // specific API or operation: + // + // * ACCOUNT_NUMBER_LIMIT_EXCEEDED: You attempted to exceed the limit on + // the number of accounts in an organization. Note: deleted and closed accounts + // still count toward your limit. + // + // If you get an exception that indicates that you exceeded your account limits + // for the organization or that you can"t add an account because your organization + // is still initializing, please contact AWS Customer Support (https://console.aws.amazon.com/support/home#/). + // + // * HANDSHAKE_RATE_LIMIT_EXCEEDED: You attempted to exceed the number of + // handshakes you can send in one day. + // + // * ALREADY_IN_AN_ORGANIZATION: The handshake request is invalid because + // the invited account is already a member of an organization. + // + // * ORGANIZATION_ALREADY_HAS_ALL_FEATURES: The handshake request is invalid + // because the organization has already enabled all features. + // + // * INVITE_DISABLED_DURING_ENABLE_ALL_FEATURES: You cannot issue new invitations + // to join an organization while it is in the process of enabling all features. + // You can resume inviting accounts after you finalize the process when all + // accounts have agreed to the change. + // + // * PAYMENT_INSTRUMENT_REQUIRED: You cannot complete the operation with + // an account that does not have a payment instrument, such as a credit card, + // associated with it. + // + // * ORGANIZATION_FROM_DIFFERENT_SELLER_OF_RECORD: The request failed because + // the account is from a different marketplace than the accounts in the organization. + // For example, accounts with India addresses must be associated with the + // AISPL marketplace. All accounts in an organization must be from the same + // marketplace. + // + // * ORGANIZATION_MEMBERSHIP_CHANGE_RATE_LIMIT_EXCEEDED: You attempted to + // change the membership of an account too quickly after its previous change. + ErrCodeHandshakeConstraintViolationException = "HandshakeConstraintViolationException" + + // ErrCodeHandshakeNotFoundException for service response error code + // "HandshakeNotFoundException". + // + // We can't find a handshake with the HandshakeId that you specified. + ErrCodeHandshakeNotFoundException = "HandshakeNotFoundException" + + // ErrCodeInvalidHandshakeTransitionException for service response error code + // "InvalidHandshakeTransitionException". + // + // You can't perform the operation on the handshake in its current state. For + // example, you can't cancel a handshake that was already accepted, or accept + // a handshake that was already declined. + ErrCodeInvalidHandshakeTransitionException = "InvalidHandshakeTransitionException" + + // ErrCodeInvalidInputException for service response error code + // "InvalidInputException". + // + // The requested operation failed because you provided invalid values for one + // or more of the request parameters. This exception includes a reason that + // contains additional information about the violated limit: + // + // Some of the reasons in the following list might not be applicable to this + // specific API or operation: + // + // * IMMUTABLE_POLICY: You specified a policy that is managed by AWS and + // cannot be modified. + // + // * INPUT_REQUIRED: You must include a value for all required parameters. + // + // * INVALID_ENUM: You specified a value that is not valid for that parameter. + // + // * INVALID_FULL_NAME_TARGET: You specified a full name that contains invalid + // characters. + // + // * INVALID_LIST_MEMBER: You provided a list to a parameter that contains + // at least one invalid value. + // + // * INVALID_PARTY_TYPE_TARGET: You specified the wrong type of entity (account, + // organization, or email) as a party. + // + // * INVALID_PAGINATION_TOKEN: Get the value for the NextToken parameter + // from the response to a previous call of the operation. + // + // * INVALID_PATTERN: You provided a value that doesn't match the required + // pattern. + // + // * INVALID_PATTERN_TARGET_ID: You specified a policy target ID that doesn't + // match the required pattern. + // + // * INVALID_ROLE_NAME: You provided a role name that is not valid. A role + // name can’t begin with the reserved prefix 'AWSServiceRoleFor'. + // + // * INVALID_SYNTAX_ORGANIZATION_ARN: You specified an invalid ARN for the + // organization. + // + // * INVALID_SYNTAX_POLICY_ID: You specified an invalid policy ID. + // + // * MAX_FILTER_LIMIT_EXCEEDED: You can specify only one filter parameter + // for the operation. + // + // * MAX_LENGTH_EXCEEDED: You provided a string parameter that is longer + // than allowed. + // + // * MAX_VALUE_EXCEEDED: You provided a numeric parameter that has a larger + // value than allowed. + // + // * MIN_LENGTH_EXCEEDED: You provided a string parameter that is shorter + // than allowed. + // + // * MIN_VALUE_EXCEEDED: You provided a numeric parameter that has a smaller + // value than allowed. + // + // * MOVING_ACCOUNT_BETWEEN_DIFFERENT_ROOTS: You can move an account only + // between entities in the same root. + ErrCodeInvalidInputException = "InvalidInputException" + + // ErrCodeMalformedPolicyDocumentException for service response error code + // "MalformedPolicyDocumentException". + // + // The provided policy document does not meet the requirements of the specified + // policy type. For example, the syntax might be incorrect. For details about + // service control policy syntax, see Service Control Policy Syntax (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_reference_scp-syntax.html) + // in the AWS Organizations User Guide. + ErrCodeMalformedPolicyDocumentException = "MalformedPolicyDocumentException" + + // ErrCodeMasterCannotLeaveOrganizationException for service response error code + // "MasterCannotLeaveOrganizationException". + // + // You can't remove a master account from an organization. If you want the master + // account to become a member account in another organization, you must first + // delete the current organization of the master account. + ErrCodeMasterCannotLeaveOrganizationException = "MasterCannotLeaveOrganizationException" + + // ErrCodeOrganizationNotEmptyException for service response error code + // "OrganizationNotEmptyException". + // + // The organization isn't empty. To delete an organization, you must first remove + // all accounts except the master account, delete all organizational units (OUs), + // and delete all policies. + ErrCodeOrganizationNotEmptyException = "OrganizationNotEmptyException" + + // ErrCodeOrganizationalUnitNotEmptyException for service response error code + // "OrganizationalUnitNotEmptyException". + // + // The specified organizational unit (OU) is not empty. Move all accounts to + // another root or to other OUs, remove all child OUs, and then try the operation + // again. + ErrCodeOrganizationalUnitNotEmptyException = "OrganizationalUnitNotEmptyException" + + // ErrCodeOrganizationalUnitNotFoundException for service response error code + // "OrganizationalUnitNotFoundException". + // + // We can't find an organizational unit (OU) with the OrganizationalUnitId that + // you specified. + ErrCodeOrganizationalUnitNotFoundException = "OrganizationalUnitNotFoundException" + + // ErrCodeParentNotFoundException for service response error code + // "ParentNotFoundException". + // + // We can't find a root or organizational unit (OU) with the ParentId that you + // specified. + ErrCodeParentNotFoundException = "ParentNotFoundException" + + // ErrCodePolicyInUseException for service response error code + // "PolicyInUseException". + // + // The policy is attached to one or more entities. You must detach it from all + // roots, organizational units (OUs), and accounts before performing this operation. + ErrCodePolicyInUseException = "PolicyInUseException" + + // ErrCodePolicyNotAttachedException for service response error code + // "PolicyNotAttachedException". + // + // The policy isn't attached to the specified target in the specified root. + ErrCodePolicyNotAttachedException = "PolicyNotAttachedException" + + // ErrCodePolicyNotFoundException for service response error code + // "PolicyNotFoundException". + // + // We can't find a policy with the PolicyId that you specified. + ErrCodePolicyNotFoundException = "PolicyNotFoundException" + + // ErrCodePolicyTypeAlreadyEnabledException for service response error code + // "PolicyTypeAlreadyEnabledException". + // + // The specified policy type is already enabled in the specified root. + ErrCodePolicyTypeAlreadyEnabledException = "PolicyTypeAlreadyEnabledException" + + // ErrCodePolicyTypeNotAvailableForOrganizationException for service response error code + // "PolicyTypeNotAvailableForOrganizationException". + // + // You can't use the specified policy type with the feature set currently enabled + // for this organization. For example, you can enable service control policies + // (SCPs) only after you enable all features in the organization. For more information, + // see Enabling and Disabling a Policy Type on a Root (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies.html#enable_policies_on_root) + // in the AWS Organizations User Guide. + ErrCodePolicyTypeNotAvailableForOrganizationException = "PolicyTypeNotAvailableForOrganizationException" + + // ErrCodePolicyTypeNotEnabledException for service response error code + // "PolicyTypeNotEnabledException". + // + // The specified policy type is not currently enabled in this root. You cannot + // attach policies of the specified type to entities in a root until you enable + // that type in the root. For more information, see Enabling All Features in + // Your Organization (http://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html) + // in the AWS Organizations User Guide. + ErrCodePolicyTypeNotEnabledException = "PolicyTypeNotEnabledException" + + // ErrCodeRootNotFoundException for service response error code + // "RootNotFoundException". + // + // We can't find a root with the RootId that you specified. + ErrCodeRootNotFoundException = "RootNotFoundException" + + // ErrCodeServiceException for service response error code + // "ServiceException". + // + // AWS Organizations can't complete your request because of an internal service + // error. Try again later. + ErrCodeServiceException = "ServiceException" + + // ErrCodeSourceParentNotFoundException for service response error code + // "SourceParentNotFoundException". + // + // We can't find a source root or OU with the ParentId that you specified. + ErrCodeSourceParentNotFoundException = "SourceParentNotFoundException" + + // ErrCodeTargetNotFoundException for service response error code + // "TargetNotFoundException". + // + // We can't find a root, OU, or account with the TargetId that you specified. + ErrCodeTargetNotFoundException = "TargetNotFoundException" + + // ErrCodeTooManyRequestsException for service response error code + // "TooManyRequestsException". + // + // You've sent too many requests in too short a period of time. The limit helps + // protect against denial-of-service attacks. Try again later. + ErrCodeTooManyRequestsException = "TooManyRequestsException" +) diff --git a/vendor/github.com/aws/aws-sdk-go/service/organizations/service.go b/vendor/github.com/aws/aws-sdk-go/service/organizations/service.go new file mode 100644 index 000000000000..0ca4f04f13d2 --- /dev/null +++ b/vendor/github.com/aws/aws-sdk-go/service/organizations/service.go @@ -0,0 +1,95 @@ +// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. + +package organizations + +import ( + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/client" + "github.com/aws/aws-sdk-go/aws/client/metadata" + "github.com/aws/aws-sdk-go/aws/request" + "github.com/aws/aws-sdk-go/aws/signer/v4" + "github.com/aws/aws-sdk-go/private/protocol/jsonrpc" +) + +// Organizations provides the API operation methods for making requests to +// AWS Organizations. See this package's package overview docs +// for details on the service. +// +// Organizations methods are safe to use concurrently. It is not safe to +// modify mutate any of the struct's properties though. +type Organizations struct { + *client.Client +} + +// Used for custom client initialization logic +var initClient func(*client.Client) + +// Used for custom request initialization logic +var initRequest func(*request.Request) + +// Service information constants +const ( + ServiceName = "organizations" // Service endpoint prefix API calls made to. + EndpointsID = ServiceName // Service ID for Regions and Endpoints metadata. +) + +// New creates a new instance of the Organizations client with a session. +// If additional configuration is needed for the client instance use the optional +// aws.Config parameter to add your extra config. +// +// Example: +// // Create a Organizations client from just a session. +// svc := organizations.New(mySession) +// +// // Create a Organizations client with additional configuration +// svc := organizations.New(mySession, aws.NewConfig().WithRegion("us-west-2")) +func New(p client.ConfigProvider, cfgs ...*aws.Config) *Organizations { + c := p.ClientConfig(EndpointsID, cfgs...) + return newClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion, c.SigningName) +} + +// newClient creates, initializes and returns a new service client instance. +func newClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion, signingName string) *Organizations { + svc := &Organizations{ + Client: client.New( + cfg, + metadata.ClientInfo{ + ServiceName: ServiceName, + SigningName: signingName, + SigningRegion: signingRegion, + Endpoint: endpoint, + APIVersion: "2016-11-28", + JSONVersion: "1.1", + TargetPrefix: "AWSOrganizationsV20161128", + }, + handlers, + ), + } + + // Handlers + svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler) + svc.Handlers.Build.PushBackNamed(jsonrpc.BuildHandler) + svc.Handlers.Unmarshal.PushBackNamed(jsonrpc.UnmarshalHandler) + svc.Handlers.UnmarshalMeta.PushBackNamed(jsonrpc.UnmarshalMetaHandler) + svc.Handlers.UnmarshalError.PushBackNamed(jsonrpc.UnmarshalErrorHandler) + + // Run custom client initialization if present + if initClient != nil { + initClient(svc.Client) + } + + return svc +} + +// newRequest creates a new request for a Organizations operation and runs any +// custom request initialization. +func (c *Organizations) newRequest(op *request.Operation, params, data interface{}) *request.Request { + req := c.NewRequest(op, params, data) + + // Run custom request initialization if present + if initRequest != nil { + initRequest(req) + } + + return req +} diff --git a/vendor/github.com/aws/aws-sdk-go/service/rds/api.go b/vendor/github.com/aws/aws-sdk-go/service/rds/api.go index a378d97c126c..73996cf63e98 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/rds/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/rds/api.go @@ -17,7 +17,7 @@ const opAddRoleToDBCluster = "AddRoleToDBCluster" // AddRoleToDBClusterRequest generates a "aws/request.Request" representing the // client's request for the AddRoleToDBCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -111,7 +111,7 @@ const opAddSourceIdentifierToSubscription = "AddSourceIdentifierToSubscription" // AddSourceIdentifierToSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the AddSourceIdentifierToSubscription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -193,7 +193,7 @@ const opAddTagsToResource = "AddTagsToResource" // AddTagsToResourceRequest generates a "aws/request.Request" representing the // client's request for the AddTagsToResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -285,7 +285,7 @@ const opApplyPendingMaintenanceAction = "ApplyPendingMaintenanceAction" // ApplyPendingMaintenanceActionRequest generates a "aws/request.Request" representing the // client's request for the ApplyPendingMaintenanceAction operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -365,7 +365,7 @@ const opAuthorizeDBSecurityGroupIngress = "AuthorizeDBSecurityGroupIngress" // AuthorizeDBSecurityGroupIngressRequest generates a "aws/request.Request" representing the // client's request for the AuthorizeDBSecurityGroupIngress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -466,7 +466,7 @@ const opCopyDBClusterParameterGroup = "CopyDBClusterParameterGroup" // CopyDBClusterParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the CopyDBClusterParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -552,7 +552,7 @@ const opCopyDBClusterSnapshot = "CopyDBClusterSnapshot" // CopyDBClusterSnapshotRequest generates a "aws/request.Request" representing the // client's request for the CopyDBClusterSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -708,7 +708,7 @@ const opCopyDBParameterGroup = "CopyDBParameterGroup" // CopyDBParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the CopyDBParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -794,7 +794,7 @@ const opCopyDBSnapshot = "CopyDBSnapshot" // CopyDBSnapshotRequest generates a "aws/request.Request" representing the // client's request for the CopyDBSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -841,8 +841,6 @@ func (c *RDS) CopyDBSnapshotRequest(input *CopyDBSnapshotInput) (req *request.Re // AWS Region where you call the CopyDBSnapshot action is the destination AWS // Region for the DB snapshot copy. // -// You can't copy an encrypted, shared DB snapshot from one AWS Region to another. -// // For more information about copying snapshots, see Copying a DB Snapshot (http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_CopyDBSnapshot.html) // in the Amazon RDS User Guide. // @@ -895,7 +893,7 @@ const opCopyOptionGroup = "CopyOptionGroup" // CopyOptionGroupRequest generates a "aws/request.Request" representing the // client's request for the CopyOptionGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -980,7 +978,7 @@ const opCreateDBCluster = "CreateDBCluster" // CreateDBClusterRequest generates a "aws/request.Request" representing the // client's request for the CreateDBCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1117,7 +1115,7 @@ const opCreateDBClusterParameterGroup = "CreateDBClusterParameterGroup" // CreateDBClusterParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateDBClusterParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1227,7 +1225,7 @@ const opCreateDBClusterSnapshot = "CreateDBClusterSnapshot" // CreateDBClusterSnapshotRequest generates a "aws/request.Request" representing the // client's request for the CreateDBClusterSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1320,7 +1318,7 @@ const opCreateDBInstance = "CreateDBInstance" // CreateDBInstanceRequest generates a "aws/request.Request" representing the // client's request for the CreateDBInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1459,7 +1457,7 @@ const opCreateDBInstanceReadReplica = "CreateDBInstanceReadReplica" // CreateDBInstanceReadReplicaRequest generates a "aws/request.Request" representing the // client's request for the CreateDBInstanceReadReplica operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1608,7 +1606,7 @@ const opCreateDBParameterGroup = "CreateDBParameterGroup" // CreateDBParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateDBParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1711,7 +1709,7 @@ const opCreateDBSecurityGroup = "CreateDBSecurityGroup" // CreateDBSecurityGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateDBSecurityGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1799,7 +1797,7 @@ const opCreateDBSnapshot = "CreateDBSnapshot" // CreateDBSnapshotRequest generates a "aws/request.Request" representing the // client's request for the CreateDBSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1887,7 +1885,7 @@ const opCreateDBSubnetGroup = "CreateDBSubnetGroup" // CreateDBSubnetGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateDBSubnetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1982,7 +1980,7 @@ const opCreateEventSubscription = "CreateEventSubscription" // CreateEventSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the CreateEventSubscription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2096,7 +2094,7 @@ const opCreateOptionGroup = "CreateOptionGroup" // CreateOptionGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateOptionGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2178,7 +2176,7 @@ const opDeleteDBCluster = "DeleteDBCluster" // DeleteDBClusterRequest generates a "aws/request.Request" representing the // client's request for the DeleteDBCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2274,7 +2272,7 @@ const opDeleteDBClusterParameterGroup = "DeleteDBClusterParameterGroup" // DeleteDBClusterParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteDBClusterParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2364,7 +2362,7 @@ const opDeleteDBClusterSnapshot = "DeleteDBClusterSnapshot" // DeleteDBClusterSnapshotRequest generates a "aws/request.Request" representing the // client's request for the DeleteDBClusterSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2452,7 +2450,7 @@ const opDeleteDBInstance = "DeleteDBInstance" // DeleteDBInstanceRequest generates a "aws/request.Request" representing the // client's request for the DeleteDBInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2567,7 +2565,7 @@ const opDeleteDBParameterGroup = "DeleteDBParameterGroup" // DeleteDBParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteDBParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2654,7 +2652,7 @@ const opDeleteDBSecurityGroup = "DeleteDBSecurityGroup" // DeleteDBSecurityGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteDBSecurityGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2740,7 +2738,7 @@ const opDeleteDBSnapshot = "DeleteDBSnapshot" // DeleteDBSnapshotRequest generates a "aws/request.Request" representing the // client's request for the DeleteDBSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2825,7 +2823,7 @@ const opDeleteDBSubnetGroup = "DeleteDBSubnetGroup" // DeleteDBSubnetGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteDBSubnetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2914,7 +2912,7 @@ const opDeleteEventSubscription = "DeleteEventSubscription" // DeleteEventSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the DeleteEventSubscription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2997,7 +2995,7 @@ const opDeleteOptionGroup = "DeleteOptionGroup" // DeleteOptionGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteOptionGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3081,7 +3079,7 @@ const opDescribeAccountAttributes = "DescribeAccountAttributes" // DescribeAccountAttributesRequest generates a "aws/request.Request" representing the // client's request for the DescribeAccountAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3160,7 +3158,7 @@ const opDescribeCertificates = "DescribeCertificates" // DescribeCertificatesRequest generates a "aws/request.Request" representing the // client's request for the DescribeCertificates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3239,7 +3237,7 @@ const opDescribeDBClusterParameterGroups = "DescribeDBClusterParameterGroups" // DescribeDBClusterParameterGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeDBClusterParameterGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3323,7 +3321,7 @@ const opDescribeDBClusterParameters = "DescribeDBClusterParameters" // DescribeDBClusterParametersRequest generates a "aws/request.Request" representing the // client's request for the DescribeDBClusterParameters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3406,7 +3404,7 @@ const opDescribeDBClusterSnapshotAttributes = "DescribeDBClusterSnapshotAttribut // DescribeDBClusterSnapshotAttributesRequest generates a "aws/request.Request" representing the // client's request for the DescribeDBClusterSnapshotAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3496,7 +3494,7 @@ const opDescribeDBClusterSnapshots = "DescribeDBClusterSnapshots" // DescribeDBClusterSnapshotsRequest generates a "aws/request.Request" representing the // client's request for the DescribeDBClusterSnapshots operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3579,7 +3577,7 @@ const opDescribeDBClusters = "DescribeDBClusters" // DescribeDBClustersRequest generates a "aws/request.Request" representing the // client's request for the DescribeDBClusters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3662,7 +3660,7 @@ const opDescribeDBEngineVersions = "DescribeDBEngineVersions" // DescribeDBEngineVersionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeDBEngineVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3792,7 +3790,7 @@ const opDescribeDBInstances = "DescribeDBInstances" // DescribeDBInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeDBInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3927,7 +3925,7 @@ const opDescribeDBLogFiles = "DescribeDBLogFiles" // DescribeDBLogFilesRequest generates a "aws/request.Request" representing the // client's request for the DescribeDBLogFiles operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4062,7 +4060,7 @@ const opDescribeDBParameterGroups = "DescribeDBParameterGroups" // DescribeDBParameterGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeDBParameterGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4199,7 +4197,7 @@ const opDescribeDBParameters = "DescribeDBParameters" // DescribeDBParametersRequest generates a "aws/request.Request" representing the // client's request for the DescribeDBParameters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4334,7 +4332,7 @@ const opDescribeDBSecurityGroups = "DescribeDBSecurityGroups" // DescribeDBSecurityGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeDBSecurityGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4471,7 +4469,7 @@ const opDescribeDBSnapshotAttributes = "DescribeDBSnapshotAttributes" // DescribeDBSnapshotAttributesRequest generates a "aws/request.Request" representing the // client's request for the DescribeDBSnapshotAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4561,7 +4559,7 @@ const opDescribeDBSnapshots = "DescribeDBSnapshots" // DescribeDBSnapshotsRequest generates a "aws/request.Request" representing the // client's request for the DescribeDBSnapshots operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4696,7 +4694,7 @@ const opDescribeDBSubnetGroups = "DescribeDBSubnetGroups" // DescribeDBSubnetGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeDBSubnetGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4834,7 +4832,7 @@ const opDescribeEngineDefaultClusterParameters = "DescribeEngineDefaultClusterPa // DescribeEngineDefaultClusterParametersRequest generates a "aws/request.Request" representing the // client's request for the DescribeEngineDefaultClusterParameters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4912,7 +4910,7 @@ const opDescribeEngineDefaultParameters = "DescribeEngineDefaultParameters" // DescribeEngineDefaultParametersRequest generates a "aws/request.Request" representing the // client's request for the DescribeEngineDefaultParameters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5043,7 +5041,7 @@ const opDescribeEventCategories = "DescribeEventCategories" // DescribeEventCategoriesRequest generates a "aws/request.Request" representing the // client's request for the DescribeEventCategories operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5120,7 +5118,7 @@ const opDescribeEventSubscriptions = "DescribeEventSubscriptions" // DescribeEventSubscriptionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEventSubscriptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5259,7 +5257,7 @@ const opDescribeEvents = "DescribeEvents" // DescribeEventsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEvents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5393,7 +5391,7 @@ const opDescribeOptionGroupOptions = "DescribeOptionGroupOptions" // DescribeOptionGroupOptionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeOptionGroupOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5523,7 +5521,7 @@ const opDescribeOptionGroups = "DescribeOptionGroups" // DescribeOptionGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeOptionGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5658,7 +5656,7 @@ const opDescribeOrderableDBInstanceOptions = "DescribeOrderableDBInstanceOptions // DescribeOrderableDBInstanceOptionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeOrderableDBInstanceOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5788,7 +5786,7 @@ const opDescribePendingMaintenanceActions = "DescribePendingMaintenanceActions" // DescribePendingMaintenanceActionsRequest generates a "aws/request.Request" representing the // client's request for the DescribePendingMaintenanceActions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5868,7 +5866,7 @@ const opDescribeReservedDBInstances = "DescribeReservedDBInstances" // DescribeReservedDBInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeReservedDBInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6004,7 +6002,7 @@ const opDescribeReservedDBInstancesOfferings = "DescribeReservedDBInstancesOffer // DescribeReservedDBInstancesOfferingsRequest generates a "aws/request.Request" representing the // client's request for the DescribeReservedDBInstancesOfferings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6139,7 +6137,7 @@ const opDescribeSourceRegions = "DescribeSourceRegions" // DescribeSourceRegionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeSourceRegions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6215,7 +6213,7 @@ const opDescribeValidDBInstanceModifications = "DescribeValidDBInstanceModificat // DescribeValidDBInstanceModificationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeValidDBInstanceModifications operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6299,7 +6297,7 @@ const opDownloadDBLogFilePortion = "DownloadDBLogFilePortion" // DownloadDBLogFilePortionRequest generates a "aws/request.Request" representing the // client's request for the DownloadDBLogFilePortion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6437,7 +6435,7 @@ const opFailoverDBCluster = "FailoverDBCluster" // FailoverDBClusterRequest generates a "aws/request.Request" representing the // client's request for the FailoverDBCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6535,7 +6533,7 @@ const opListTagsForResource = "ListTagsForResource" // ListTagsForResourceRequest generates a "aws/request.Request" representing the // client's request for the ListTagsForResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6623,7 +6621,7 @@ const opModifyDBCluster = "ModifyDBCluster" // ModifyDBClusterRequest generates a "aws/request.Request" representing the // client's request for the ModifyDBCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6740,7 +6738,7 @@ const opModifyDBClusterParameterGroup = "ModifyDBClusterParameterGroup" // ModifyDBClusterParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the ModifyDBClusterParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6844,7 +6842,7 @@ const opModifyDBClusterSnapshotAttribute = "ModifyDBClusterSnapshotAttribute" // ModifyDBClusterSnapshotAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifyDBClusterSnapshotAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6946,7 +6944,7 @@ const opModifyDBInstance = "ModifyDBInstance" // ModifyDBInstanceRequest generates a "aws/request.Request" representing the // client's request for the ModifyDBInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7080,7 +7078,7 @@ const opModifyDBParameterGroup = "ModifyDBParameterGroup" // ModifyDBParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the ModifyDBParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7181,7 +7179,7 @@ const opModifyDBSnapshot = "ModifyDBSnapshot" // ModifyDBSnapshotRequest generates a "aws/request.Request" representing the // client's request for the ModifyDBSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7263,7 +7261,7 @@ const opModifyDBSnapshotAttribute = "ModifyDBSnapshotAttribute" // ModifyDBSnapshotAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifyDBSnapshotAttribute operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7365,7 +7363,7 @@ const opModifyDBSubnetGroup = "ModifyDBSubnetGroup" // ModifyDBSubnetGroupRequest generates a "aws/request.Request" representing the // client's request for the ModifyDBSubnetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7460,7 +7458,7 @@ const opModifyEventSubscription = "ModifyEventSubscription" // ModifyEventSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the ModifyEventSubscription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7562,7 +7560,7 @@ const opModifyOptionGroup = "ModifyOptionGroup" // ModifyOptionGroupRequest generates a "aws/request.Request" representing the // client's request for the ModifyOptionGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7644,7 +7642,7 @@ const opPromoteReadReplica = "PromoteReadReplica" // PromoteReadReplicaRequest generates a "aws/request.Request" representing the // client's request for the PromoteReadReplica operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7686,10 +7684,13 @@ func (c *RDS) PromoteReadReplicaRequest(input *PromoteReadReplicaInput) (req *re // // Promotes a Read Replica DB instance to a standalone DB instance. // -// We recommend that you enable automated backups on your Read Replica before -// promoting the Read Replica. This ensures that no backup is taken during the -// promotion process. Once the instance is promoted to a primary instance, backups -// are taken based on your backup settings. +// Backup duration is a function of the amount of changes to the database since +// the previous backup. If you plan to promote a Read Replica to a standalone +// instance, we recommend that you enable backups and complete at least one +// backup prior to promotion. In addition, a Read Replica cannot be promoted +// to a standalone instance when it is in the backing-up status. If you have +// enabled backups on your Read Replica, configure the automated backup window +// so that daily backups do not interfere with Read Replica promotion. // // This command doesn't apply to Aurora MySQL and Aurora PostgreSQL. // @@ -7733,7 +7734,7 @@ const opPromoteReadReplicaDBCluster = "PromoteReadReplicaDBCluster" // PromoteReadReplicaDBClusterRequest generates a "aws/request.Request" representing the // client's request for the PromoteReadReplicaDBCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7815,7 +7816,7 @@ const opPurchaseReservedDBInstancesOffering = "PurchaseReservedDBInstancesOfferi // PurchaseReservedDBInstancesOfferingRequest generates a "aws/request.Request" representing the // client's request for the PurchaseReservedDBInstancesOffering operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7900,7 +7901,7 @@ const opRebootDBInstance = "RebootDBInstance" // RebootDBInstanceRequest generates a "aws/request.Request" representing the // client's request for the RebootDBInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7991,7 +7992,7 @@ const opRemoveRoleFromDBCluster = "RemoveRoleFromDBCluster" // RemoveRoleFromDBClusterRequest generates a "aws/request.Request" representing the // client's request for the RemoveRoleFromDBCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8081,7 +8082,7 @@ const opRemoveSourceIdentifierFromSubscription = "RemoveSourceIdentifierFromSubs // RemoveSourceIdentifierFromSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the RemoveSourceIdentifierFromSubscription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8163,7 +8164,7 @@ const opRemoveTagsFromResource = "RemoveTagsFromResource" // RemoveTagsFromResourceRequest generates a "aws/request.Request" representing the // client's request for the RemoveTagsFromResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8253,7 +8254,7 @@ const opResetDBClusterParameterGroup = "ResetDBClusterParameterGroup" // ResetDBClusterParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the ResetDBClusterParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8349,7 +8350,7 @@ const opResetDBParameterGroup = "ResetDBParameterGroup" // ResetDBParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the ResetDBParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8439,7 +8440,7 @@ const opRestoreDBClusterFromS3 = "RestoreDBClusterFromS3" // RestoreDBClusterFromS3Request generates a "aws/request.Request" representing the // client's request for the RestoreDBClusterFromS3 operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8566,7 +8567,7 @@ const opRestoreDBClusterFromSnapshot = "RestoreDBClusterFromSnapshot" // RestoreDBClusterFromSnapshotRequest generates a "aws/request.Request" representing the // client's request for the RestoreDBClusterFromSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8711,7 +8712,7 @@ const opRestoreDBClusterToPointInTime = "RestoreDBClusterToPointInTime" // RestoreDBClusterToPointInTimeRequest generates a "aws/request.Request" representing the // client's request for the RestoreDBClusterToPointInTime operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8855,7 +8856,7 @@ const opRestoreDBInstanceFromDBSnapshot = "RestoreDBInstanceFromDBSnapshot" // RestoreDBInstanceFromDBSnapshotRequest generates a "aws/request.Request" representing the // client's request for the RestoreDBInstanceFromDBSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9015,7 +9016,7 @@ const opRestoreDBInstanceFromS3 = "RestoreDBInstanceFromS3" // RestoreDBInstanceFromS3Request generates a "aws/request.Request" representing the // client's request for the RestoreDBInstanceFromS3 operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9155,7 +9156,7 @@ const opRestoreDBInstanceToPointInTime = "RestoreDBInstanceToPointInTime" // RestoreDBInstanceToPointInTimeRequest generates a "aws/request.Request" representing the // client's request for the RestoreDBInstanceToPointInTime operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9312,7 +9313,7 @@ const opRevokeDBSecurityGroupIngress = "RevokeDBSecurityGroupIngress" // RevokeDBSecurityGroupIngressRequest generates a "aws/request.Request" representing the // client's request for the RevokeDBSecurityGroupIngress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9404,7 +9405,7 @@ const opStartDBInstance = "StartDBInstance" // StartDBInstanceRequest generates a "aws/request.Request" representing the // client's request for the StartDBInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9525,7 +9526,7 @@ const opStopDBInstance = "StopDBInstance" // StopDBInstanceRequest generates a "aws/request.Request" representing the // client's request for the StopDBInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -12059,9 +12060,13 @@ type CreateDBInstanceInput struct { // // MariaDB // + // * 10.2.12 (supported in all AWS Regions) + // // * 10.2.11 (supported in all AWS Regions) // - // 10.1.26 (supported in all AWS Regions) + // 10.1.31 (supported in all AWS Regions) + // + // * 10.1.26 (supported in all AWS Regions) // // * 10.1.23 (supported in all AWS Regions) // @@ -12069,6 +12074,8 @@ type CreateDBInstanceInput struct { // // * 10.1.14 (supported in all AWS Regions except us-east-2) // + // * 10.0.34 (supported in all AWS Regions) + // // * 10.0.32 (supported in all AWS Regions) // // * 10.0.31 (supported in all AWS Regions) @@ -12126,12 +12133,16 @@ type CreateDBInstanceInput struct { // // MySQL // + // * 5.7.21 (supported in all AWS regions) + // // * 5.7.19 (supported in all AWS regions) // // * 5.7.17 (supported in all AWS regions) // // * 5.7.16 (supported in all AWS regions) // + // 5.6.39(supported in all AWS Regions) + // // 5.6.37(supported in all AWS Regions) // // 5.6.35(supported in all AWS Regions) @@ -12903,8 +12914,6 @@ type CreateDBInstanceReadReplicaInput struct { // of your replica in another Availability Zone for failover support for the // replica. Creating your Read Replica as a Multi-AZ DB instance is independent // of whether the source database is a Multi-AZ DB instance. - // - // Currently, you can't create PostgreSQL Read Replicas as Multi-AZ DB instances. MultiAZ *bool `type:"boolean"` // The option group the DB instance is associated with. If omitted, the default @@ -14842,6 +14851,9 @@ type DBEngineVersion struct { // log types specified by ExportableLogTypes to CloudWatch Logs. SupportsLogExportsToCloudwatchLogs *bool `type:"boolean"` + // Indicates whether the database engine version supports read replicas. + SupportsReadReplica *bool `type:"boolean"` + // A list of engine versions that this database engine version can be upgraded // to. ValidUpgradeTarget []*UpgradeTarget `locationNameList:"UpgradeTarget" type:"list"` @@ -14917,6 +14929,12 @@ func (s *DBEngineVersion) SetSupportsLogExportsToCloudwatchLogs(v bool) *DBEngin return s } +// SetSupportsReadReplica sets the SupportsReadReplica field's value. +func (s *DBEngineVersion) SetSupportsReadReplica(v bool) *DBEngineVersion { + s.SupportsReadReplica = &v + return s +} + // SetValidUpgradeTarget sets the ValidUpgradeTarget field's value. func (s *DBEngineVersion) SetValidUpgradeTarget(v []*UpgradeTarget) *DBEngineVersion { s.ValidUpgradeTarget = v @@ -25964,7 +25982,7 @@ type RestoreDBClusterFromSnapshotInput struct { // // Constraints: // - // * Must contain from 1 to 255 letters, numbers, or hyphens + // * Must contain from 1 to 63 letters, numbers, or hyphens // // * First character must be a letter // diff --git a/vendor/github.com/aws/aws-sdk-go/service/redshift/api.go b/vendor/github.com/aws/aws-sdk-go/service/redshift/api.go index b1d78ae9844e..7fcc803f10b6 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/redshift/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/redshift/api.go @@ -16,7 +16,7 @@ const opAuthorizeClusterSecurityGroupIngress = "AuthorizeClusterSecurityGroupIng // AuthorizeClusterSecurityGroupIngressRequest generates a "aws/request.Request" representing the // client's request for the AuthorizeClusterSecurityGroupIngress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -125,7 +125,7 @@ const opAuthorizeSnapshotAccess = "AuthorizeSnapshotAccess" // AuthorizeSnapshotAccessRequest generates a "aws/request.Request" representing the // client's request for the AuthorizeSnapshotAccess operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -226,7 +226,7 @@ const opCopyClusterSnapshot = "CopyClusterSnapshot" // CopyClusterSnapshotRequest generates a "aws/request.Request" representing the // client's request for the CopyClusterSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -329,7 +329,7 @@ const opCreateCluster = "CreateCluster" // CreateClusterRequest generates a "aws/request.Request" representing the // client's request for the CreateCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -478,7 +478,7 @@ const opCreateClusterParameterGroup = "CreateClusterParameterGroup" // CreateClusterParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateClusterParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -579,7 +579,7 @@ const opCreateClusterSecurityGroup = "CreateClusterSecurityGroup" // CreateClusterSecurityGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateClusterSecurityGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -675,7 +675,7 @@ const opCreateClusterSnapshot = "CreateClusterSnapshot" // CreateClusterSnapshotRequest generates a "aws/request.Request" representing the // client's request for the CreateClusterSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -776,7 +776,7 @@ const opCreateClusterSubnetGroup = "CreateClusterSubnetGroup" // CreateClusterSubnetGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateClusterSubnetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -890,7 +890,7 @@ const opCreateEventSubscription = "CreateEventSubscription" // CreateEventSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the CreateEventSubscription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1030,7 +1030,7 @@ const opCreateHsmClientCertificate = "CreateHsmClientCertificate" // CreateHsmClientCertificateRequest generates a "aws/request.Request" representing the // client's request for the CreateHsmClientCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1129,7 +1129,7 @@ const opCreateHsmConfiguration = "CreateHsmConfiguration" // CreateHsmConfigurationRequest generates a "aws/request.Request" representing the // client's request for the CreateHsmConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1229,7 +1229,7 @@ const opCreateSnapshotCopyGrant = "CreateSnapshotCopyGrant" // CreateSnapshotCopyGrantRequest generates a "aws/request.Request" representing the // client's request for the CreateSnapshotCopyGrant operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1332,7 +1332,7 @@ const opCreateTags = "CreateTags" // CreateTagsRequest generates a "aws/request.Request" representing the // client's request for the CreateTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1425,7 +1425,7 @@ const opDeleteCluster = "DeleteCluster" // DeleteClusterRequest generates a "aws/request.Request" representing the // client's request for the DeleteCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1531,7 +1531,7 @@ const opDeleteClusterParameterGroup = "DeleteClusterParameterGroup" // DeleteClusterParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteClusterParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1619,7 +1619,7 @@ const opDeleteClusterSecurityGroup = "DeleteClusterSecurityGroup" // DeleteClusterSecurityGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteClusterSecurityGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1711,7 +1711,7 @@ const opDeleteClusterSnapshot = "DeleteClusterSnapshot" // DeleteClusterSnapshotRequest generates a "aws/request.Request" representing the // client's request for the DeleteClusterSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1801,7 +1801,7 @@ const opDeleteClusterSubnetGroup = "DeleteClusterSubnetGroup" // DeleteClusterSubnetGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteClusterSubnetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1889,7 +1889,7 @@ const opDeleteEventSubscription = "DeleteEventSubscription" // DeleteEventSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the DeleteEventSubscription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1975,7 +1975,7 @@ const opDeleteHsmClientCertificate = "DeleteHsmClientCertificate" // DeleteHsmClientCertificateRequest generates a "aws/request.Request" representing the // client's request for the DeleteHsmClientCertificate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2060,7 +2060,7 @@ const opDeleteHsmConfiguration = "DeleteHsmConfiguration" // DeleteHsmConfigurationRequest generates a "aws/request.Request" representing the // client's request for the DeleteHsmConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2145,7 +2145,7 @@ const opDeleteSnapshotCopyGrant = "DeleteSnapshotCopyGrant" // DeleteSnapshotCopyGrantRequest generates a "aws/request.Request" representing the // client's request for the DeleteSnapshotCopyGrant operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2231,7 +2231,7 @@ const opDeleteTags = "DeleteTags" // DeleteTagsRequest generates a "aws/request.Request" representing the // client's request for the DeleteTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2316,7 +2316,7 @@ const opDescribeClusterParameterGroups = "DescribeClusterParameterGroups" // DescribeClusterParameterGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeClusterParameterGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2472,7 +2472,7 @@ const opDescribeClusterParameters = "DescribeClusterParameters" // DescribeClusterParametersRequest generates a "aws/request.Request" representing the // client's request for the DescribeClusterParameters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2618,7 +2618,7 @@ const opDescribeClusterSecurityGroups = "DescribeClusterSecurityGroups" // DescribeClusterSecurityGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeClusterSecurityGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2773,7 +2773,7 @@ const opDescribeClusterSnapshots = "DescribeClusterSnapshots" // DescribeClusterSnapshotsRequest generates a "aws/request.Request" representing the // client's request for the DescribeClusterSnapshots operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2843,6 +2843,9 @@ func (c *Redshift) DescribeClusterSnapshotsRequest(input *DescribeClusterSnapsho // API operation DescribeClusterSnapshots for usage and error information. // // Returned Error Codes: +// * ErrCodeClusterNotFoundFault "ClusterNotFound" +// The ClusterIdentifier parameter does not refer to an existing cluster. +// // * ErrCodeClusterSnapshotNotFoundFault "ClusterSnapshotNotFound" // The snapshot identifier does not refer to an existing cluster snapshot. // @@ -2925,7 +2928,7 @@ const opDescribeClusterSubnetGroups = "DescribeClusterSubnetGroups" // DescribeClusterSubnetGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeClusterSubnetGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3076,7 +3079,7 @@ const opDescribeClusterVersions = "DescribeClusterVersions" // DescribeClusterVersionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeClusterVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3210,7 +3213,7 @@ const opDescribeClusters = "DescribeClusters" // DescribeClustersRequest generates a "aws/request.Request" representing the // client's request for the DescribeClusters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3361,7 +3364,7 @@ const opDescribeDefaultClusterParameters = "DescribeDefaultClusterParameters" // DescribeDefaultClusterParametersRequest generates a "aws/request.Request" representing the // client's request for the DescribeDefaultClusterParameters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3495,7 +3498,7 @@ const opDescribeEventCategories = "DescribeEventCategories" // DescribeEventCategoriesRequest generates a "aws/request.Request" representing the // client's request for the DescribeEventCategories operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3571,7 +3574,7 @@ const opDescribeEventSubscriptions = "DescribeEventSubscriptions" // DescribeEventSubscriptionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEventSubscriptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3722,7 +3725,7 @@ const opDescribeEvents = "DescribeEvents" // DescribeEventsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEvents operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3855,7 +3858,7 @@ const opDescribeHsmClientCertificates = "DescribeHsmClientCertificates" // DescribeHsmClientCertificatesRequest generates a "aws/request.Request" representing the // client's request for the DescribeHsmClientCertificates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4005,7 +4008,7 @@ const opDescribeHsmConfigurations = "DescribeHsmConfigurations" // DescribeHsmConfigurationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeHsmConfigurations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4155,7 +4158,7 @@ const opDescribeLoggingStatus = "DescribeLoggingStatus" // DescribeLoggingStatusRequest generates a "aws/request.Request" representing the // client's request for the DescribeLoggingStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4235,7 +4238,7 @@ const opDescribeOrderableClusterOptions = "DescribeOrderableClusterOptions" // DescribeOrderableClusterOptionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeOrderableClusterOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4373,7 +4376,7 @@ const opDescribeReservedNodeOfferings = "DescribeReservedNodeOfferings" // DescribeReservedNodeOfferingsRequest generates a "aws/request.Request" representing the // client's request for the DescribeReservedNodeOfferings operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4524,7 +4527,7 @@ const opDescribeReservedNodes = "DescribeReservedNodes" // DescribeReservedNodesRequest generates a "aws/request.Request" representing the // client's request for the DescribeReservedNodes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4663,7 +4666,7 @@ const opDescribeResize = "DescribeResize" // DescribeResizeRequest generates a "aws/request.Request" representing the // client's request for the DescribeResize operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4751,7 +4754,7 @@ const opDescribeSnapshotCopyGrants = "DescribeSnapshotCopyGrants" // DescribeSnapshotCopyGrantsRequest generates a "aws/request.Request" representing the // client's request for the DescribeSnapshotCopyGrants operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4839,7 +4842,7 @@ const opDescribeTableRestoreStatus = "DescribeTableRestoreStatus" // DescribeTableRestoreStatusRequest generates a "aws/request.Request" representing the // client's request for the DescribeTableRestoreStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4925,7 +4928,7 @@ const opDescribeTags = "DescribeTags" // DescribeTagsRequest generates a "aws/request.Request" representing the // client's request for the DescribeTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5029,7 +5032,7 @@ const opDisableLogging = "DisableLogging" // DisableLoggingRequest generates a "aws/request.Request" representing the // client's request for the DisableLogging operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5109,7 +5112,7 @@ const opDisableSnapshotCopy = "DisableSnapshotCopy" // DisableSnapshotCopyRequest generates a "aws/request.Request" representing the // client's request for the DisableSnapshotCopy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5202,7 +5205,7 @@ const opEnableLogging = "EnableLogging" // EnableLoggingRequest generates a "aws/request.Request" representing the // client's request for the EnableLogging operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5298,7 +5301,7 @@ const opEnableSnapshotCopy = "EnableSnapshotCopy" // EnableSnapshotCopyRequest generates a "aws/request.Request" representing the // client's request for the EnableSnapshotCopy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5407,7 +5410,7 @@ const opGetClusterCredentials = "GetClusterCredentials" // GetClusterCredentialsRequest generates a "aws/request.Request" representing the // client's request for the GetClusterCredentials operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5512,7 +5515,7 @@ const opModifyCluster = "ModifyCluster" // ModifyClusterRequest generates a "aws/request.Request" representing the // client's request for the ModifyCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5651,7 +5654,7 @@ const opModifyClusterIamRoles = "ModifyClusterIamRoles" // ModifyClusterIamRolesRequest generates a "aws/request.Request" representing the // client's request for the ModifyClusterIamRoles operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5736,7 +5739,7 @@ const opModifyClusterParameterGroup = "ModifyClusterParameterGroup" // ModifyClusterParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the ModifyClusterParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5824,7 +5827,7 @@ const opModifyClusterSubnetGroup = "ModifyClusterSubnetGroup" // ModifyClusterSubnetGroupRequest generates a "aws/request.Request" representing the // client's request for the ModifyClusterSubnetGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5926,7 +5929,7 @@ const opModifyEventSubscription = "ModifyEventSubscription" // ModifyEventSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the ModifyEventSubscription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6037,7 +6040,7 @@ const opModifySnapshotCopyRetentionPeriod = "ModifySnapshotCopyRetentionPeriod" // ModifySnapshotCopyRetentionPeriodRequest generates a "aws/request.Request" representing the // client's request for the ModifySnapshotCopyRetentionPeriod operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6126,7 +6129,7 @@ const opPurchaseReservedNodeOffering = "PurchaseReservedNodeOffering" // PurchaseReservedNodeOfferingRequest generates a "aws/request.Request" representing the // client's request for the PurchaseReservedNodeOffering operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6224,7 +6227,7 @@ const opRebootCluster = "RebootCluster" // RebootClusterRequest generates a "aws/request.Request" representing the // client's request for the RebootCluster operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6312,7 +6315,7 @@ const opResetClusterParameterGroup = "ResetClusterParameterGroup" // ResetClusterParameterGroupRequest generates a "aws/request.Request" representing the // client's request for the ResetClusterParameterGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6399,7 +6402,7 @@ const opRestoreFromClusterSnapshot = "RestoreFromClusterSnapshot" // RestoreFromClusterSnapshotRequest generates a "aws/request.Request" representing the // client's request for the RestoreFromClusterSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6564,7 +6567,7 @@ const opRestoreTableFromClusterSnapshot = "RestoreTableFromClusterSnapshot" // RestoreTableFromClusterSnapshotRequest generates a "aws/request.Request" representing the // client's request for the RestoreTableFromClusterSnapshot operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6676,7 +6679,7 @@ const opRevokeClusterSecurityGroupIngress = "RevokeClusterSecurityGroupIngress" // RevokeClusterSecurityGroupIngressRequest generates a "aws/request.Request" representing the // client's request for the RevokeClusterSecurityGroupIngress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6767,7 +6770,7 @@ const opRevokeSnapshotAccess = "RevokeSnapshotAccess" // RevokeSnapshotAccessRequest generates a "aws/request.Request" representing the // client's request for the RevokeSnapshotAccess operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6860,7 +6863,7 @@ const opRotateEncryptionKey = "RotateEncryptionKey" // RotateEncryptionKeyRequest generates a "aws/request.Request" representing the // client's request for the RotateEncryptionKey operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7163,6 +7166,8 @@ type AvailabilityZone struct { // The name of the availability zone. Name *string `type:"string"` + + SupportedPlatforms []*SupportedPlatform `locationNameList:"SupportedPlatform" type:"list"` } // String returns the string representation @@ -7181,6 +7186,12 @@ func (s *AvailabilityZone) SetName(v string) *AvailabilityZone { return s } +// SetSupportedPlatforms sets the SupportedPlatforms field's value. +func (s *AvailabilityZone) SetSupportedPlatforms(v []*SupportedPlatform) *AvailabilityZone { + s.SupportedPlatforms = v + return s +} + // Describes a cluster. type Cluster struct { _ struct{} `type:"structure"` @@ -8397,7 +8408,7 @@ type CreateClusterInput struct { // // Constraints: // - // * Must be 1 - 128 alphanumeric characters. + // * Must be 1 - 128 alphanumeric characters. The user name can't be PUBLIC. // // * First character must be a letter. // @@ -8412,8 +8423,8 @@ type CreateClusterInput struct { // types, go to Working with Clusters (http://docs.aws.amazon.com/redshift/latest/mgmt/working-with-clusters.html#how-many-nodes) // in the Amazon Redshift Cluster Management Guide. // - // Valid Values: ds1.xlarge | ds1.8xlarge | ds2.xlarge | ds2.8xlarge | dc1.large - // | dc1.8xlarge. + // Valid Values: ds2.xlarge | ds2.8xlarge | ds2.xlarge | ds2.8xlarge | dc1.large + // | dc1.8xlarge | dc2.large | dc2.8xlarge // // NodeType is a required field NodeType *string `type:"string" required:"true"` @@ -10700,6 +10711,12 @@ func (s *DescribeClusterSecurityGroupsOutput) SetMarker(v string) *DescribeClust type DescribeClusterSnapshotsInput struct { _ struct{} `type:"structure"` + // A value that indicates whether to return snapshots only for an existing cluster. + // Table-level restore can be performed only using a snapshot of an existing + // cluster, that is, a cluster that has not been deleted. If ClusterExists is + // set to true, ClusterIdentifier is required. + ClusterExists *bool `type:"boolean"` + // The identifier of the cluster for which information about snapshots is requested. ClusterIdentifier *string `type:"string"` @@ -10777,6 +10794,12 @@ func (s DescribeClusterSnapshotsInput) GoString() string { return s.String() } +// SetClusterExists sets the ClusterExists field's value. +func (s *DescribeClusterSnapshotsInput) SetClusterExists(v bool) *DescribeClusterSnapshotsInput { + s.ClusterExists = &v + return s +} + // SetClusterIdentifier sets the ClusterIdentifier field's value. func (s *DescribeClusterSnapshotsInput) SetClusterIdentifier(v string) *DescribeClusterSnapshotsInput { s.ClusterIdentifier = &v @@ -13542,7 +13565,8 @@ type GetClusterCredentialsInput struct { // // Constraints: // - // * Must be 1 to 64 alphanumeric characters or hyphens + // * Must be 1 to 64 alphanumeric characters or hyphens. The user name can't + // be PUBLIC. // // * Must contain only lowercase letters, numbers, underscore, plus sign, // period (dot), at symbol (@), or hyphen. @@ -14183,8 +14207,8 @@ type ModifyClusterInput struct { // permissions for the cluster are restored. You can use DescribeResize to track // the progress of the resize request. // - // Valid Values: ds1.xlarge | ds1.8xlarge | ds2.xlarge | ds2.8xlarge | dc1.large - // | dc1.8xlarge. + // Valid Values: ds2.xlarge | ds2.8xlarge | dc1.large | dc1.8xlarge | dc2.large + // | dc2.8xlarge NodeType *string `type:"string"` // The new number of nodes of the cluster. If you specify a new number of nodes, @@ -15211,6 +15235,8 @@ type ReservedNode struct { // The identifier for the reserved node offering. ReservedNodeOfferingId *string `type:"string"` + ReservedNodeOfferingType *string `type:"string" enum:"ReservedNodeOfferingType"` + // The time the reservation started. You purchase a reserved node offering for // a duration. This is the start time of that duration. StartTime *time.Time `type:"timestamp" timestampFormat:"iso8601"` @@ -15296,6 +15322,12 @@ func (s *ReservedNode) SetReservedNodeOfferingId(v string) *ReservedNode { return s } +// SetReservedNodeOfferingType sets the ReservedNodeOfferingType field's value. +func (s *ReservedNode) SetReservedNodeOfferingType(v string) *ReservedNode { + s.ReservedNodeOfferingType = &v + return s +} + // SetStartTime sets the StartTime field's value. func (s *ReservedNode) SetStartTime(v time.Time) *ReservedNode { s.StartTime = &v @@ -15343,6 +15375,8 @@ type ReservedNodeOffering struct { // The offering identifier. ReservedNodeOfferingId *string `type:"string"` + ReservedNodeOfferingType *string `type:"string" enum:"ReservedNodeOfferingType"` + // The rate you are charged for each hour the cluster that is using the offering // is running. UsagePrice *float64 `type:"double"` @@ -15400,6 +15434,12 @@ func (s *ReservedNodeOffering) SetReservedNodeOfferingId(v string) *ReservedNode return s } +// SetReservedNodeOfferingType sets the ReservedNodeOfferingType field's value. +func (s *ReservedNodeOffering) SetReservedNodeOfferingType(v string) *ReservedNodeOffering { + s.ReservedNodeOfferingType = &v + return s +} + // SetUsagePrice sets the UsagePrice field's value. func (s *ReservedNodeOffering) SetUsagePrice(v float64) *ReservedNodeOffering { s.UsagePrice = &v @@ -15581,12 +15621,14 @@ type RestoreFromClusterSnapshotInput struct { // Default: The node type of the cluster from which the snapshot was taken. // You can modify this if you are using any DS node type. In that case, you // can choose to restore into another DS node type of the same size. For example, - // you can restore ds1.8xlarge into ds2.8xlarge, or ds2.xlarge into ds1.xlarge. + // you can restore ds1.8xlarge into ds2.8xlarge, or ds1.xlarge into ds2.xlarge. // If you have a DC instance type, you must restore into that same instance // type and size. In other words, you can only restore a dc1.large instance - // type into another dc1.large instance type. For more information about node - // types, see About Clusters and Nodes (http://docs.aws.amazon.com/redshift/latest/mgmt/working-with-clusters.html#rs-about-clusters-and-nodes) - // in the Amazon Redshift Cluster Management Guide + // type into another dc1.large instance type or dc2.large instance type. You + // can't restore dc1.8xlarge to dc2.8xlarge. First restore to a dc1.8xlareg + // cluster, then resize to a dc2.8large cluster. For more information about + // node types, see About Clusters and Nodes (http://docs.aws.amazon.com/redshift/latest/mgmt/working-with-clusters.html#rs-about-clusters-and-nodes) + // in the Amazon Redshift Cluster Management Guide. NodeType *string `type:"string"` // The AWS customer account used to create or copy the snapshot. Required if @@ -16687,6 +16729,29 @@ func (s *Subnet) SetSubnetStatus(v string) *Subnet { return s } +// A list of supported platforms for orderable clusters. +type SupportedPlatform struct { + _ struct{} `type:"structure"` + + Name *string `type:"string"` +} + +// String returns the string representation +func (s SupportedPlatform) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s SupportedPlatform) GoString() string { + return s.String() +} + +// SetName sets the Name field's value. +func (s *SupportedPlatform) SetName(v string) *SupportedPlatform { + s.Name = &v + return s +} + // Describes the status of a RestoreTableFromClusterSnapshot operation. type TableRestoreStatus struct { _ struct{} `type:"structure"` @@ -16973,6 +17038,14 @@ const ( ParameterApplyTypeDynamic = "dynamic" ) +const ( + // ReservedNodeOfferingTypeRegular is a ReservedNodeOfferingType enum value + ReservedNodeOfferingTypeRegular = "Regular" + + // ReservedNodeOfferingTypeUpgradable is a ReservedNodeOfferingType enum value + ReservedNodeOfferingTypeUpgradable = "Upgradable" +) + const ( // SourceTypeCluster is a SourceType enum value SourceTypeCluster = "cluster" diff --git a/vendor/github.com/aws/aws-sdk-go/service/route53/api.go b/vendor/github.com/aws/aws-sdk-go/service/route53/api.go index 90dfe15b4d74..5357821e837b 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/route53/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/route53/api.go @@ -15,7 +15,7 @@ const opAssociateVPCWithHostedZone = "AssociateVPCWithHostedZone" // AssociateVPCWithHostedZoneRequest generates a "aws/request.Request" representing the // client's request for the AssociateVPCWithHostedZone operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -146,7 +146,7 @@ const opChangeResourceRecordSets = "ChangeResourceRecordSets" // ChangeResourceRecordSetsRequest generates a "aws/request.Request" representing the // client's request for the ChangeResourceRecordSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -321,7 +321,7 @@ const opChangeTagsForResource = "ChangeTagsForResource" // ChangeTagsForResourceRequest generates a "aws/request.Request" representing the // client's request for the ChangeTagsForResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -421,7 +421,7 @@ const opCreateHealthCheck = "CreateHealthCheck" // CreateHealthCheckRequest generates a "aws/request.Request" representing the // client's request for the CreateHealthCheck operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -557,7 +557,7 @@ const opCreateHostedZone = "CreateHostedZone" // CreateHostedZoneRequest generates a "aws/request.Request" representing the // client's request for the CreateHostedZone operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -731,7 +731,7 @@ const opCreateQueryLoggingConfig = "CreateQueryLoggingConfig" // CreateQueryLoggingConfigRequest generates a "aws/request.Request" representing the // client's request for the CreateQueryLoggingConfig operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -932,7 +932,7 @@ const opCreateReusableDelegationSet = "CreateReusableDelegationSet" // CreateReusableDelegationSetRequest generates a "aws/request.Request" representing the // client's request for the CreateReusableDelegationSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1084,7 +1084,7 @@ const opCreateTrafficPolicy = "CreateTrafficPolicy" // CreateTrafficPolicyRequest generates a "aws/request.Request" representing the // client's request for the CreateTrafficPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1184,7 +1184,7 @@ const opCreateTrafficPolicyInstance = "CreateTrafficPolicyInstance" // CreateTrafficPolicyInstanceRequest generates a "aws/request.Request" representing the // client's request for the CreateTrafficPolicyInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1289,7 +1289,7 @@ const opCreateTrafficPolicyVersion = "CreateTrafficPolicyVersion" // CreateTrafficPolicyVersionRequest generates a "aws/request.Request" representing the // client's request for the CreateTrafficPolicyVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1396,7 +1396,7 @@ const opCreateVPCAssociationAuthorization = "CreateVPCAssociationAuthorization" // CreateVPCAssociationAuthorizationRequest generates a "aws/request.Request" representing the // client's request for the CreateVPCAssociationAuthorization operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1502,7 +1502,7 @@ const opDeleteHealthCheck = "DeleteHealthCheck" // DeleteHealthCheckRequest generates a "aws/request.Request" representing the // client's request for the DeleteHealthCheck operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1596,7 +1596,7 @@ const opDeleteHostedZone = "DeleteHostedZone" // DeleteHostedZoneRequest generates a "aws/request.Request" representing the // client's request for the DeleteHostedZone operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1720,7 +1720,7 @@ const opDeleteQueryLoggingConfig = "DeleteQueryLoggingConfig" // DeleteQueryLoggingConfigRequest generates a "aws/request.Request" representing the // client's request for the DeleteQueryLoggingConfig operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1810,7 +1810,7 @@ const opDeleteReusableDelegationSet = "DeleteReusableDelegationSet" // DeleteReusableDelegationSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteReusableDelegationSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1906,7 +1906,7 @@ const opDeleteTrafficPolicy = "DeleteTrafficPolicy" // DeleteTrafficPolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteTrafficPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1996,7 +1996,7 @@ const opDeleteTrafficPolicyInstance = "DeleteTrafficPolicyInstance" // DeleteTrafficPolicyInstanceRequest generates a "aws/request.Request" representing the // client's request for the DeleteTrafficPolicyInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2089,7 +2089,7 @@ const opDeleteVPCAssociationAuthorization = "DeleteVPCAssociationAuthorization" // DeleteVPCAssociationAuthorizationRequest generates a "aws/request.Request" representing the // client's request for the DeleteVPCAssociationAuthorization operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2192,7 +2192,7 @@ const opDisassociateVPCFromHostedZone = "DisassociateVPCFromHostedZone" // DisassociateVPCFromHostedZoneRequest generates a "aws/request.Request" representing the // client's request for the DisassociateVPCFromHostedZone operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2292,7 +2292,7 @@ const opGetAccountLimit = "GetAccountLimit" // GetAccountLimitRequest generates a "aws/request.Request" representing the // client's request for the GetAccountLimit operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2376,7 +2376,7 @@ const opGetChange = "GetChange" // GetChangeRequest generates a "aws/request.Request" representing the // client's request for the GetChange operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2466,7 +2466,7 @@ const opGetCheckerIpRanges = "GetCheckerIpRanges" // GetCheckerIpRangesRequest generates a "aws/request.Request" representing the // client's request for the GetCheckerIpRanges operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2543,7 +2543,7 @@ const opGetGeoLocation = "GetGeoLocation" // GetGeoLocationRequest generates a "aws/request.Request" representing the // client's request for the GetGeoLocation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2642,7 +2642,7 @@ const opGetHealthCheck = "GetHealthCheck" // GetHealthCheckRequest generates a "aws/request.Request" representing the // client's request for the GetHealthCheck operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2729,7 +2729,7 @@ const opGetHealthCheckCount = "GetHealthCheckCount" // GetHealthCheckCountRequest generates a "aws/request.Request" representing the // client's request for the GetHealthCheckCount operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2804,7 +2804,7 @@ const opGetHealthCheckLastFailureReason = "GetHealthCheckLastFailureReason" // GetHealthCheckLastFailureReasonRequest generates a "aws/request.Request" representing the // client's request for the GetHealthCheckLastFailureReason operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2887,7 +2887,7 @@ const opGetHealthCheckStatus = "GetHealthCheckStatus" // GetHealthCheckStatusRequest generates a "aws/request.Request" representing the // client's request for the GetHealthCheckStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2970,7 +2970,7 @@ const opGetHostedZone = "GetHostedZone" // GetHostedZoneRequest generates a "aws/request.Request" representing the // client's request for the GetHostedZone operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3053,7 +3053,7 @@ const opGetHostedZoneCount = "GetHostedZoneCount" // GetHostedZoneCountRequest generates a "aws/request.Request" representing the // client's request for the GetHostedZoneCount operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3133,7 +3133,7 @@ const opGetHostedZoneLimit = "GetHostedZoneLimit" // GetHostedZoneLimitRequest generates a "aws/request.Request" representing the // client's request for the GetHostedZoneLimit operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3223,7 +3223,7 @@ const opGetQueryLoggingConfig = "GetQueryLoggingConfig" // GetQueryLoggingConfigRequest generates a "aws/request.Request" representing the // client's request for the GetQueryLoggingConfig operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3308,7 +3308,7 @@ const opGetReusableDelegationSet = "GetReusableDelegationSet" // GetReusableDelegationSetRequest generates a "aws/request.Request" representing the // client's request for the GetReusableDelegationSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3394,7 +3394,7 @@ const opGetReusableDelegationSetLimit = "GetReusableDelegationSetLimit" // GetReusableDelegationSetLimitRequest generates a "aws/request.Request" representing the // client's request for the GetReusableDelegationSetLimit operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3481,7 +3481,7 @@ const opGetTrafficPolicy = "GetTrafficPolicy" // GetTrafficPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetTrafficPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3563,7 +3563,7 @@ const opGetTrafficPolicyInstance = "GetTrafficPolicyInstance" // GetTrafficPolicyInstanceRequest generates a "aws/request.Request" representing the // client's request for the GetTrafficPolicyInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3653,7 +3653,7 @@ const opGetTrafficPolicyInstanceCount = "GetTrafficPolicyInstanceCount" // GetTrafficPolicyInstanceCountRequest generates a "aws/request.Request" representing the // client's request for the GetTrafficPolicyInstanceCount operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3728,7 +3728,7 @@ const opListGeoLocations = "ListGeoLocations" // ListGeoLocationsRequest generates a "aws/request.Request" representing the // client's request for the ListGeoLocations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3812,7 +3812,7 @@ const opListHealthChecks = "ListHealthChecks" // ListHealthChecksRequest generates a "aws/request.Request" representing the // client's request for the ListHealthChecks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3952,7 +3952,7 @@ const opListHostedZones = "ListHostedZones" // ListHostedZonesRequest generates a "aws/request.Request" representing the // client's request for the ListHostedZones operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4099,7 +4099,7 @@ const opListHostedZonesByName = "ListHostedZonesByName" // ListHostedZonesByNameRequest generates a "aws/request.Request" representing the // client's request for the ListHostedZonesByName operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4230,7 +4230,7 @@ const opListQueryLoggingConfigs = "ListQueryLoggingConfigs" // ListQueryLoggingConfigsRequest generates a "aws/request.Request" representing the // client's request for the ListQueryLoggingConfigs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4323,7 +4323,7 @@ const opListResourceRecordSets = "ListResourceRecordSets" // ListResourceRecordSetsRequest generates a "aws/request.Request" representing the // client's request for the ListResourceRecordSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4499,7 +4499,7 @@ const opListReusableDelegationSets = "ListReusableDelegationSets" // ListReusableDelegationSetsRequest generates a "aws/request.Request" representing the // client's request for the ListReusableDelegationSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4579,7 +4579,7 @@ const opListTagsForResource = "ListTagsForResource" // ListTagsForResourceRequest generates a "aws/request.Request" representing the // client's request for the ListTagsForResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4679,7 +4679,7 @@ const opListTagsForResources = "ListTagsForResources" // ListTagsForResourcesRequest generates a "aws/request.Request" representing the // client's request for the ListTagsForResources operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4779,7 +4779,7 @@ const opListTrafficPolicies = "ListTrafficPolicies" // ListTrafficPoliciesRequest generates a "aws/request.Request" representing the // client's request for the ListTrafficPolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4860,7 +4860,7 @@ const opListTrafficPolicyInstances = "ListTrafficPolicyInstances" // ListTrafficPolicyInstancesRequest generates a "aws/request.Request" representing the // client's request for the ListTrafficPolicyInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4952,7 +4952,7 @@ const opListTrafficPolicyInstancesByHostedZone = "ListTrafficPolicyInstancesByHo // ListTrafficPolicyInstancesByHostedZoneRequest generates a "aws/request.Request" representing the // client's request for the ListTrafficPolicyInstancesByHostedZone operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5047,7 +5047,7 @@ const opListTrafficPolicyInstancesByPolicy = "ListTrafficPolicyInstancesByPolicy // ListTrafficPolicyInstancesByPolicyRequest generates a "aws/request.Request" representing the // client's request for the ListTrafficPolicyInstancesByPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5142,7 +5142,7 @@ const opListTrafficPolicyVersions = "ListTrafficPolicyVersions" // ListTrafficPolicyVersionsRequest generates a "aws/request.Request" representing the // client's request for the ListTrafficPolicyVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5226,7 +5226,7 @@ const opListVPCAssociationAuthorizations = "ListVPCAssociationAuthorizations" // ListVPCAssociationAuthorizationsRequest generates a "aws/request.Request" representing the // client's request for the ListVPCAssociationAuthorizations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5317,7 +5317,7 @@ const opTestDNSAnswer = "TestDNSAnswer" // TestDNSAnswerRequest generates a "aws/request.Request" representing the // client's request for the TestDNSAnswer operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5401,7 +5401,7 @@ const opUpdateHealthCheck = "UpdateHealthCheck" // UpdateHealthCheckRequest generates a "aws/request.Request" representing the // client's request for the UpdateHealthCheck operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5492,7 +5492,7 @@ const opUpdateHostedZoneComment = "UpdateHostedZoneComment" // UpdateHostedZoneCommentRequest generates a "aws/request.Request" representing the // client's request for the UpdateHostedZoneComment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5574,7 +5574,7 @@ const opUpdateTrafficPolicyComment = "UpdateTrafficPolicyComment" // UpdateTrafficPolicyCommentRequest generates a "aws/request.Request" representing the // client's request for the UpdateTrafficPolicyComment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5660,7 +5660,7 @@ const opUpdateTrafficPolicyInstance = "UpdateTrafficPolicyInstance" // UpdateTrafficPolicyInstanceRequest generates a "aws/request.Request" representing the // client's request for the UpdateTrafficPolicyInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -14680,6 +14680,9 @@ const ( // CloudWatchRegionApNortheast2 is a CloudWatchRegion enum value CloudWatchRegionApNortheast2 = "ap-northeast-2" + // CloudWatchRegionApNortheast3 is a CloudWatchRegion enum value + CloudWatchRegionApNortheast3 = "ap-northeast-3" + // CloudWatchRegionSaEast1 is a CloudWatchRegion enum value CloudWatchRegionSaEast1 = "sa-east-1" ) @@ -14866,6 +14869,9 @@ const ( // ResourceRecordSetRegionApNortheast2 is a ResourceRecordSetRegion enum value ResourceRecordSetRegionApNortheast2 = "ap-northeast-2" + // ResourceRecordSetRegionApNortheast3 is a ResourceRecordSetRegion enum value + ResourceRecordSetRegionApNortheast3 = "ap-northeast-3" + // ResourceRecordSetRegionSaEast1 is a ResourceRecordSetRegion enum value ResourceRecordSetRegionSaEast1 = "sa-east-1" @@ -14949,6 +14955,9 @@ const ( // VPCRegionApNortheast2 is a VPCRegion enum value VPCRegionApNortheast2 = "ap-northeast-2" + // VPCRegionApNortheast3 is a VPCRegion enum value + VPCRegionApNortheast3 = "ap-northeast-3" + // VPCRegionSaEast1 is a VPCRegion enum value VPCRegionSaEast1 = "sa-east-1" diff --git a/vendor/github.com/aws/aws-sdk-go/service/s3/api.go b/vendor/github.com/aws/aws-sdk-go/service/s3/api.go index 2faeee1ec8f3..a27823fdfb51 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/s3/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/s3/api.go @@ -18,7 +18,7 @@ const opAbortMultipartUpload = "AbortMultipartUpload" // AbortMultipartUploadRequest generates a "aws/request.Request" representing the // client's request for the AbortMultipartUpload operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -101,7 +101,7 @@ const opCompleteMultipartUpload = "CompleteMultipartUpload" // CompleteMultipartUploadRequest generates a "aws/request.Request" representing the // client's request for the CompleteMultipartUpload operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -175,7 +175,7 @@ const opCopyObject = "CopyObject" // CopyObjectRequest generates a "aws/request.Request" representing the // client's request for the CopyObject operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -255,7 +255,7 @@ const opCreateBucket = "CreateBucket" // CreateBucketRequest generates a "aws/request.Request" representing the // client's request for the CreateBucket operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -337,7 +337,7 @@ const opCreateMultipartUpload = "CreateMultipartUpload" // CreateMultipartUploadRequest generates a "aws/request.Request" representing the // client's request for the CreateMultipartUpload operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -417,7 +417,7 @@ const opDeleteBucket = "DeleteBucket" // DeleteBucketRequest generates a "aws/request.Request" representing the // client's request for the DeleteBucket operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -494,7 +494,7 @@ const opDeleteBucketAnalyticsConfiguration = "DeleteBucketAnalyticsConfiguration // DeleteBucketAnalyticsConfigurationRequest generates a "aws/request.Request" representing the // client's request for the DeleteBucketAnalyticsConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -571,7 +571,7 @@ const opDeleteBucketCors = "DeleteBucketCors" // DeleteBucketCorsRequest generates a "aws/request.Request" representing the // client's request for the DeleteBucketCors operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -647,7 +647,7 @@ const opDeleteBucketEncryption = "DeleteBucketEncryption" // DeleteBucketEncryptionRequest generates a "aws/request.Request" representing the // client's request for the DeleteBucketEncryption operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -723,7 +723,7 @@ const opDeleteBucketInventoryConfiguration = "DeleteBucketInventoryConfiguration // DeleteBucketInventoryConfigurationRequest generates a "aws/request.Request" representing the // client's request for the DeleteBucketInventoryConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -800,7 +800,7 @@ const opDeleteBucketLifecycle = "DeleteBucketLifecycle" // DeleteBucketLifecycleRequest generates a "aws/request.Request" representing the // client's request for the DeleteBucketLifecycle operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -876,7 +876,7 @@ const opDeleteBucketMetricsConfiguration = "DeleteBucketMetricsConfiguration" // DeleteBucketMetricsConfigurationRequest generates a "aws/request.Request" representing the // client's request for the DeleteBucketMetricsConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -953,7 +953,7 @@ const opDeleteBucketPolicy = "DeleteBucketPolicy" // DeleteBucketPolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteBucketPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1029,7 +1029,7 @@ const opDeleteBucketReplication = "DeleteBucketReplication" // DeleteBucketReplicationRequest generates a "aws/request.Request" representing the // client's request for the DeleteBucketReplication operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1105,7 +1105,7 @@ const opDeleteBucketTagging = "DeleteBucketTagging" // DeleteBucketTaggingRequest generates a "aws/request.Request" representing the // client's request for the DeleteBucketTagging operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1181,7 +1181,7 @@ const opDeleteBucketWebsite = "DeleteBucketWebsite" // DeleteBucketWebsiteRequest generates a "aws/request.Request" representing the // client's request for the DeleteBucketWebsite operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1257,7 +1257,7 @@ const opDeleteObject = "DeleteObject" // DeleteObjectRequest generates a "aws/request.Request" representing the // client's request for the DeleteObject operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1333,7 +1333,7 @@ const opDeleteObjectTagging = "DeleteObjectTagging" // DeleteObjectTaggingRequest generates a "aws/request.Request" representing the // client's request for the DeleteObjectTagging operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1407,7 +1407,7 @@ const opDeleteObjects = "DeleteObjects" // DeleteObjectsRequest generates a "aws/request.Request" representing the // client's request for the DeleteObjects operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1482,7 +1482,7 @@ const opGetBucketAccelerateConfiguration = "GetBucketAccelerateConfiguration" // GetBucketAccelerateConfigurationRequest generates a "aws/request.Request" representing the // client's request for the GetBucketAccelerateConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1556,7 +1556,7 @@ const opGetBucketAcl = "GetBucketAcl" // GetBucketAclRequest generates a "aws/request.Request" representing the // client's request for the GetBucketAcl operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1630,7 +1630,7 @@ const opGetBucketAnalyticsConfiguration = "GetBucketAnalyticsConfiguration" // GetBucketAnalyticsConfigurationRequest generates a "aws/request.Request" representing the // client's request for the GetBucketAnalyticsConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1705,7 +1705,7 @@ const opGetBucketCors = "GetBucketCors" // GetBucketCorsRequest generates a "aws/request.Request" representing the // client's request for the GetBucketCors operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1779,7 +1779,7 @@ const opGetBucketEncryption = "GetBucketEncryption" // GetBucketEncryptionRequest generates a "aws/request.Request" representing the // client's request for the GetBucketEncryption operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1853,7 +1853,7 @@ const opGetBucketInventoryConfiguration = "GetBucketInventoryConfiguration" // GetBucketInventoryConfigurationRequest generates a "aws/request.Request" representing the // client's request for the GetBucketInventoryConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1928,7 +1928,7 @@ const opGetBucketLifecycle = "GetBucketLifecycle" // GetBucketLifecycleRequest generates a "aws/request.Request" representing the // client's request for the GetBucketLifecycle operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2005,7 +2005,7 @@ const opGetBucketLifecycleConfiguration = "GetBucketLifecycleConfiguration" // GetBucketLifecycleConfigurationRequest generates a "aws/request.Request" representing the // client's request for the GetBucketLifecycleConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2079,7 +2079,7 @@ const opGetBucketLocation = "GetBucketLocation" // GetBucketLocationRequest generates a "aws/request.Request" representing the // client's request for the GetBucketLocation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2153,7 +2153,7 @@ const opGetBucketLogging = "GetBucketLogging" // GetBucketLoggingRequest generates a "aws/request.Request" representing the // client's request for the GetBucketLogging operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2228,7 +2228,7 @@ const opGetBucketMetricsConfiguration = "GetBucketMetricsConfiguration" // GetBucketMetricsConfigurationRequest generates a "aws/request.Request" representing the // client's request for the GetBucketMetricsConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2303,7 +2303,7 @@ const opGetBucketNotification = "GetBucketNotification" // GetBucketNotificationRequest generates a "aws/request.Request" representing the // client's request for the GetBucketNotification operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2380,7 +2380,7 @@ const opGetBucketNotificationConfiguration = "GetBucketNotificationConfiguration // GetBucketNotificationConfigurationRequest generates a "aws/request.Request" representing the // client's request for the GetBucketNotificationConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2454,7 +2454,7 @@ const opGetBucketPolicy = "GetBucketPolicy" // GetBucketPolicyRequest generates a "aws/request.Request" representing the // client's request for the GetBucketPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2528,7 +2528,7 @@ const opGetBucketReplication = "GetBucketReplication" // GetBucketReplicationRequest generates a "aws/request.Request" representing the // client's request for the GetBucketReplication operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2602,7 +2602,7 @@ const opGetBucketRequestPayment = "GetBucketRequestPayment" // GetBucketRequestPaymentRequest generates a "aws/request.Request" representing the // client's request for the GetBucketRequestPayment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2676,7 +2676,7 @@ const opGetBucketTagging = "GetBucketTagging" // GetBucketTaggingRequest generates a "aws/request.Request" representing the // client's request for the GetBucketTagging operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2750,7 +2750,7 @@ const opGetBucketVersioning = "GetBucketVersioning" // GetBucketVersioningRequest generates a "aws/request.Request" representing the // client's request for the GetBucketVersioning operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2824,7 +2824,7 @@ const opGetBucketWebsite = "GetBucketWebsite" // GetBucketWebsiteRequest generates a "aws/request.Request" representing the // client's request for the GetBucketWebsite operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2898,7 +2898,7 @@ const opGetObject = "GetObject" // GetObjectRequest generates a "aws/request.Request" representing the // client's request for the GetObject operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2977,7 +2977,7 @@ const opGetObjectAcl = "GetObjectAcl" // GetObjectAclRequest generates a "aws/request.Request" representing the // client's request for the GetObjectAcl operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3056,7 +3056,7 @@ const opGetObjectTagging = "GetObjectTagging" // GetObjectTaggingRequest generates a "aws/request.Request" representing the // client's request for the GetObjectTagging operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3130,7 +3130,7 @@ const opGetObjectTorrent = "GetObjectTorrent" // GetObjectTorrentRequest generates a "aws/request.Request" representing the // client's request for the GetObjectTorrent operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3204,7 +3204,7 @@ const opHeadBucket = "HeadBucket" // HeadBucketRequest generates a "aws/request.Request" representing the // client's request for the HeadBucket operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3286,7 +3286,7 @@ const opHeadObject = "HeadObject" // HeadObjectRequest generates a "aws/request.Request" representing the // client's request for the HeadObject operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3365,7 +3365,7 @@ const opListBucketAnalyticsConfigurations = "ListBucketAnalyticsConfigurations" // ListBucketAnalyticsConfigurationsRequest generates a "aws/request.Request" representing the // client's request for the ListBucketAnalyticsConfigurations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3439,7 +3439,7 @@ const opListBucketInventoryConfigurations = "ListBucketInventoryConfigurations" // ListBucketInventoryConfigurationsRequest generates a "aws/request.Request" representing the // client's request for the ListBucketInventoryConfigurations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3513,7 +3513,7 @@ const opListBucketMetricsConfigurations = "ListBucketMetricsConfigurations" // ListBucketMetricsConfigurationsRequest generates a "aws/request.Request" representing the // client's request for the ListBucketMetricsConfigurations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3587,7 +3587,7 @@ const opListBuckets = "ListBuckets" // ListBucketsRequest generates a "aws/request.Request" representing the // client's request for the ListBuckets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3661,7 +3661,7 @@ const opListMultipartUploads = "ListMultipartUploads" // ListMultipartUploadsRequest generates a "aws/request.Request" representing the // client's request for the ListMultipartUploads operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3791,7 +3791,7 @@ const opListObjectVersions = "ListObjectVersions" // ListObjectVersionsRequest generates a "aws/request.Request" representing the // client's request for the ListObjectVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3921,7 +3921,7 @@ const opListObjects = "ListObjects" // ListObjectsRequest generates a "aws/request.Request" representing the // client's request for the ListObjects operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4058,7 +4058,7 @@ const opListObjectsV2 = "ListObjectsV2" // ListObjectsV2Request generates a "aws/request.Request" representing the // client's request for the ListObjectsV2 operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4196,7 +4196,7 @@ const opListParts = "ListParts" // ListPartsRequest generates a "aws/request.Request" representing the // client's request for the ListParts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4326,7 +4326,7 @@ const opPutBucketAccelerateConfiguration = "PutBucketAccelerateConfiguration" // PutBucketAccelerateConfigurationRequest generates a "aws/request.Request" representing the // client's request for the PutBucketAccelerateConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4402,7 +4402,7 @@ const opPutBucketAcl = "PutBucketAcl" // PutBucketAclRequest generates a "aws/request.Request" representing the // client's request for the PutBucketAcl operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4478,7 +4478,7 @@ const opPutBucketAnalyticsConfiguration = "PutBucketAnalyticsConfiguration" // PutBucketAnalyticsConfigurationRequest generates a "aws/request.Request" representing the // client's request for the PutBucketAnalyticsConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4555,7 +4555,7 @@ const opPutBucketCors = "PutBucketCors" // PutBucketCorsRequest generates a "aws/request.Request" representing the // client's request for the PutBucketCors operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4631,7 +4631,7 @@ const opPutBucketEncryption = "PutBucketEncryption" // PutBucketEncryptionRequest generates a "aws/request.Request" representing the // client's request for the PutBucketEncryption operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4708,7 +4708,7 @@ const opPutBucketInventoryConfiguration = "PutBucketInventoryConfiguration" // PutBucketInventoryConfigurationRequest generates a "aws/request.Request" representing the // client's request for the PutBucketInventoryConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4785,7 +4785,7 @@ const opPutBucketLifecycle = "PutBucketLifecycle" // PutBucketLifecycleRequest generates a "aws/request.Request" representing the // client's request for the PutBucketLifecycle operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4864,7 +4864,7 @@ const opPutBucketLifecycleConfiguration = "PutBucketLifecycleConfiguration" // PutBucketLifecycleConfigurationRequest generates a "aws/request.Request" representing the // client's request for the PutBucketLifecycleConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4941,7 +4941,7 @@ const opPutBucketLogging = "PutBucketLogging" // PutBucketLoggingRequest generates a "aws/request.Request" representing the // client's request for the PutBucketLogging operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5019,7 +5019,7 @@ const opPutBucketMetricsConfiguration = "PutBucketMetricsConfiguration" // PutBucketMetricsConfigurationRequest generates a "aws/request.Request" representing the // client's request for the PutBucketMetricsConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5096,7 +5096,7 @@ const opPutBucketNotification = "PutBucketNotification" // PutBucketNotificationRequest generates a "aws/request.Request" representing the // client's request for the PutBucketNotification operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5175,7 +5175,7 @@ const opPutBucketNotificationConfiguration = "PutBucketNotificationConfiguration // PutBucketNotificationConfigurationRequest generates a "aws/request.Request" representing the // client's request for the PutBucketNotificationConfiguration operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5251,7 +5251,7 @@ const opPutBucketPolicy = "PutBucketPolicy" // PutBucketPolicyRequest generates a "aws/request.Request" representing the // client's request for the PutBucketPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5328,7 +5328,7 @@ const opPutBucketReplication = "PutBucketReplication" // PutBucketReplicationRequest generates a "aws/request.Request" representing the // client's request for the PutBucketReplication operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5405,7 +5405,7 @@ const opPutBucketRequestPayment = "PutBucketRequestPayment" // PutBucketRequestPaymentRequest generates a "aws/request.Request" representing the // client's request for the PutBucketRequestPayment operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5485,7 +5485,7 @@ const opPutBucketTagging = "PutBucketTagging" // PutBucketTaggingRequest generates a "aws/request.Request" representing the // client's request for the PutBucketTagging operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5561,7 +5561,7 @@ const opPutBucketVersioning = "PutBucketVersioning" // PutBucketVersioningRequest generates a "aws/request.Request" representing the // client's request for the PutBucketVersioning operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5638,7 +5638,7 @@ const opPutBucketWebsite = "PutBucketWebsite" // PutBucketWebsiteRequest generates a "aws/request.Request" representing the // client's request for the PutBucketWebsite operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5714,7 +5714,7 @@ const opPutObject = "PutObject" // PutObjectRequest generates a "aws/request.Request" representing the // client's request for the PutObject operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5788,7 +5788,7 @@ const opPutObjectAcl = "PutObjectAcl" // PutObjectAclRequest generates a "aws/request.Request" representing the // client's request for the PutObjectAcl operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5868,7 +5868,7 @@ const opPutObjectTagging = "PutObjectTagging" // PutObjectTaggingRequest generates a "aws/request.Request" representing the // client's request for the PutObjectTagging operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5942,7 +5942,7 @@ const opRestoreObject = "RestoreObject" // RestoreObjectRequest generates a "aws/request.Request" representing the // client's request for the RestoreObject operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6021,7 +6021,7 @@ const opUploadPart = "UploadPart" // UploadPartRequest generates a "aws/request.Request" representing the // client's request for the UploadPart operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6101,7 +6101,7 @@ const opUploadPartCopy = "UploadPartCopy" // UploadPartCopyRequest generates a "aws/request.Request" representing the // client's request for the UploadPartCopy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6807,6 +6807,9 @@ func (s *BucketLifecycleConfiguration) SetRules(v []*LifecycleRule) *BucketLifec type BucketLoggingStatus struct { _ struct{} `type:"structure"` + // Container for logging information. Presence of this element indicates that + // logging is enabled. Parameters TargetBucket and TargetPrefix are required + // in this case. LoggingEnabled *LoggingEnabled `type:"structure"` } @@ -10720,6 +10723,9 @@ func (s *GetBucketLoggingInput) getBucket() (v string) { type GetBucketLoggingOutput struct { _ struct{} `type:"structure"` + // Container for logging information. Presence of this element indicates that + // logging is enabled. Parameters TargetBucket and TargetPrefix are required + // in this case. LoggingEnabled *LoggingEnabled `type:"structure"` } @@ -12865,6 +12871,13 @@ type InputSerialization struct { // Describes the serialization of a CSV-encoded object. CSV *CSVInput `type:"structure"` + + // Specifies object's compression format. Valid values: NONE, GZIP. Default + // Value: NONE. + CompressionType *string `type:"string" enum:"CompressionType"` + + // Specifies JSON as object's input serialization format. + JSON *JSONInput `type:"structure"` } // String returns the string representation @@ -12883,6 +12896,18 @@ func (s *InputSerialization) SetCSV(v *CSVInput) *InputSerialization { return s } +// SetCompressionType sets the CompressionType field's value. +func (s *InputSerialization) SetCompressionType(v string) *InputSerialization { + s.CompressionType = &v + return s +} + +// SetJSON sets the JSON field's value. +func (s *InputSerialization) SetJSON(v *JSONInput) *InputSerialization { + s.JSON = v + return s +} + type InventoryConfiguration struct { _ struct{} `type:"structure"` @@ -13273,6 +13298,52 @@ func (s *InventorySchedule) SetFrequency(v string) *InventorySchedule { return s } +type JSONInput struct { + _ struct{} `type:"structure"` + + // The type of JSON. Valid values: Document, Lines. + Type *string `type:"string" enum:"JSONType"` +} + +// String returns the string representation +func (s JSONInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s JSONInput) GoString() string { + return s.String() +} + +// SetType sets the Type field's value. +func (s *JSONInput) SetType(v string) *JSONInput { + s.Type = &v + return s +} + +type JSONOutput struct { + _ struct{} `type:"structure"` + + // The value used to separate individual records in the output. + RecordDelimiter *string `type:"string"` +} + +// String returns the string representation +func (s JSONOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s JSONOutput) GoString() string { + return s.String() +} + +// SetRecordDelimiter sets the RecordDelimiter field's value. +func (s *JSONOutput) SetRecordDelimiter(v string) *JSONOutput { + s.RecordDelimiter = &v + return s +} + // Container for object key name prefix and suffix filtering rules. type KeyFilter struct { _ struct{} `type:"structure"` @@ -15397,6 +15468,9 @@ func (s *Location) SetUserMetadata(v []*MetadataEntry) *Location { return s } +// Container for logging information. Presence of this element indicates that +// logging is enabled. Parameters TargetBucket and TargetPrefix are required +// in this case. type LoggingEnabled struct { _ struct{} `type:"structure"` @@ -15406,13 +15480,17 @@ type LoggingEnabled struct { // to deliver their logs to the same target bucket. In this case you should // choose a different TargetPrefix for each source bucket so that the delivered // log files can be distinguished by key. - TargetBucket *string `type:"string"` + // + // TargetBucket is a required field + TargetBucket *string `type:"string" required:"true"` TargetGrants []*TargetGrant `locationNameList:"Grant" type:"list"` // This element lets you specify a prefix for the keys that the log files will // be stored under. - TargetPrefix *string `type:"string"` + // + // TargetPrefix is a required field + TargetPrefix *string `type:"string" required:"true"` } // String returns the string representation @@ -15428,6 +15506,12 @@ func (s LoggingEnabled) GoString() string { // Validate inspects the fields of the type to determine if they are valid. func (s *LoggingEnabled) Validate() error { invalidParams := request.ErrInvalidParams{Context: "LoggingEnabled"} + if s.TargetBucket == nil { + invalidParams.Add(request.NewErrParamRequired("TargetBucket")) + } + if s.TargetPrefix == nil { + invalidParams.Add(request.NewErrParamRequired("TargetPrefix")) + } if s.TargetGrants != nil { for i, v := range s.TargetGrants { if v == nil { @@ -15762,10 +15846,11 @@ func (s *NoncurrentVersionExpiration) SetNoncurrentDays(v int64) *NoncurrentVers } // Container for the transition rule that describes when noncurrent objects -// transition to the STANDARD_IA or GLACIER storage class. If your bucket is -// versioning-enabled (or versioning is suspended), you can set this action -// to request that Amazon S3 transition noncurrent object versions to the STANDARD_IA -// or GLACIER storage class at a specific period in the object's lifetime. +// transition to the STANDARD_IA, ONEZONE_IA or GLACIER storage class. If your +// bucket is versioning-enabled (or versioning is suspended), you can set this +// action to request that Amazon S3 transition noncurrent object versions to +// the STANDARD_IA, ONEZONE_IA or GLACIER storage class at a specific period +// in the object's lifetime. type NoncurrentVersionTransition struct { _ struct{} `type:"structure"` @@ -16187,6 +16272,9 @@ type OutputSerialization struct { // Describes the serialization of CSV-encoded Select results. CSV *CSVOutput `type:"structure"` + + // Specifies JSON as request's output serialization format. + JSON *JSONOutput `type:"structure"` } // String returns the string representation @@ -16205,6 +16293,12 @@ func (s *OutputSerialization) SetCSV(v *CSVOutput) *OutputSerialization { return s } +// SetJSON sets the JSON field's value. +func (s *OutputSerialization) SetJSON(v *JSONOutput) *OutputSerialization { + s.JSON = v + return s +} + type Owner struct { _ struct{} `type:"structure"` @@ -19148,10 +19242,11 @@ type Rule struct { NoncurrentVersionExpiration *NoncurrentVersionExpiration `type:"structure"` // Container for the transition rule that describes when noncurrent objects - // transition to the STANDARD_IA or GLACIER storage class. If your bucket is - // versioning-enabled (or versioning is suspended), you can set this action - // to request that Amazon S3 transition noncurrent object versions to the STANDARD_IA - // or GLACIER storage class at a specific period in the object's lifetime. + // transition to the STANDARD_IA, ONEZONE_IA or GLACIER storage class. If your + // bucket is versioning-enabled (or versioning is suspended), you can set this + // action to request that Amazon S3 transition noncurrent object versions to + // the STANDARD_IA, ONEZONE_IA or GLACIER storage class at a specific period + // in the object's lifetime. NoncurrentVersionTransition *NoncurrentVersionTransition `type:"structure"` // Prefix identifying one or more objects to which the rule applies. @@ -20781,6 +20876,14 @@ const ( BucketVersioningStatusSuspended = "Suspended" ) +const ( + // CompressionTypeNone is a CompressionType enum value + CompressionTypeNone = "NONE" + + // CompressionTypeGzip is a CompressionType enum value + CompressionTypeGzip = "GZIP" +) + // Requests Amazon S3 to encode the object keys in the response and specifies // the encoding method to use. An object key may contain any Unicode character; // however, XML 1.0 parser cannot parse some characters, such as characters @@ -20901,6 +21004,14 @@ const ( InventoryOptionalFieldEncryptionStatus = "EncryptionStatus" ) +const ( + // JSONTypeDocument is a JSONType enum value + JSONTypeDocument = "DOCUMENT" + + // JSONTypeLines is a JSONType enum value + JSONTypeLines = "LINES" +) + const ( // MFADeleteEnabled is a MFADelete enum value MFADeleteEnabled = "Enabled" @@ -20957,6 +21068,12 @@ const ( // ObjectStorageClassGlacier is a ObjectStorageClass enum value ObjectStorageClassGlacier = "GLACIER" + + // ObjectStorageClassStandardIa is a ObjectStorageClass enum value + ObjectStorageClassStandardIa = "STANDARD_IA" + + // ObjectStorageClassOnezoneIa is a ObjectStorageClass enum value + ObjectStorageClassOnezoneIa = "ONEZONE_IA" ) const ( @@ -21078,6 +21195,9 @@ const ( // StorageClassStandardIa is a StorageClass enum value StorageClassStandardIa = "STANDARD_IA" + + // StorageClassOnezoneIa is a StorageClass enum value + StorageClassOnezoneIa = "ONEZONE_IA" ) const ( @@ -21110,6 +21230,9 @@ const ( // TransitionStorageClassStandardIa is a TransitionStorageClass enum value TransitionStorageClassStandardIa = "STANDARD_IA" + + // TransitionStorageClassOnezoneIa is a TransitionStorageClass enum value + TransitionStorageClassOnezoneIa = "ONEZONE_IA" ) const ( diff --git a/vendor/github.com/aws/aws-sdk-go/service/s3/body_hash.go b/vendor/github.com/aws/aws-sdk-go/service/s3/body_hash.go new file mode 100644 index 000000000000..5c8ce5cc8a52 --- /dev/null +++ b/vendor/github.com/aws/aws-sdk-go/service/s3/body_hash.go @@ -0,0 +1,249 @@ +package s3 + +import ( + "bytes" + "crypto/md5" + "crypto/sha256" + "encoding/base64" + "encoding/hex" + "fmt" + "hash" + "io" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/awserr" + "github.com/aws/aws-sdk-go/aws/request" + "github.com/aws/aws-sdk-go/internal/sdkio" +) + +const ( + contentMD5Header = "Content-Md5" + contentSha256Header = "X-Amz-Content-Sha256" + amzTeHeader = "X-Amz-Te" + amzTxEncodingHeader = "X-Amz-Transfer-Encoding" + + appendMD5TxEncoding = "append-md5" +) + +// contentMD5 computes and sets the HTTP Content-MD5 header for requests that +// require it. +func contentMD5(r *request.Request) { + h := md5.New() + + if !aws.IsReaderSeekable(r.Body) { + if r.Config.Logger != nil { + r.Config.Logger.Log(fmt.Sprintf( + "Unable to compute Content-MD5 for unseekable body, S3.%s", + r.Operation.Name)) + } + return + } + + if _, err := copySeekableBody(h, r.Body); err != nil { + r.Error = awserr.New("ContentMD5", "failed to compute body MD5", err) + return + } + + // encode the md5 checksum in base64 and set the request header. + v := base64.StdEncoding.EncodeToString(h.Sum(nil)) + r.HTTPRequest.Header.Set(contentMD5Header, v) +} + +// computeBodyHashes will add Content MD5 and Content Sha256 hashes to the +// request. If the body is not seekable or S3DisableContentMD5Validation set +// this handler will be ignored. +func computeBodyHashes(r *request.Request) { + if aws.BoolValue(r.Config.S3DisableContentMD5Validation) { + return + } + if r.IsPresigned() { + return + } + if r.Error != nil || !aws.IsReaderSeekable(r.Body) { + return + } + + var md5Hash, sha256Hash hash.Hash + hashers := make([]io.Writer, 0, 2) + + // Determine upfront which hashes can be set without overriding user + // provide header data. + if v := r.HTTPRequest.Header.Get(contentMD5Header); len(v) == 0 { + md5Hash = md5.New() + hashers = append(hashers, md5Hash) + } + + if v := r.HTTPRequest.Header.Get(contentSha256Header); len(v) == 0 { + sha256Hash = sha256.New() + hashers = append(hashers, sha256Hash) + } + + // Create the destination writer based on the hashes that are not already + // provided by the user. + var dst io.Writer + switch len(hashers) { + case 0: + return + case 1: + dst = hashers[0] + default: + dst = io.MultiWriter(hashers...) + } + + if _, err := copySeekableBody(dst, r.Body); err != nil { + r.Error = awserr.New("BodyHashError", "failed to compute body hashes", err) + return + } + + // For the hashes created, set the associated headers that the user did not + // already provide. + if md5Hash != nil { + sum := make([]byte, md5.Size) + encoded := make([]byte, md5Base64EncLen) + + base64.StdEncoding.Encode(encoded, md5Hash.Sum(sum[0:0])) + r.HTTPRequest.Header[contentMD5Header] = []string{string(encoded)} + } + + if sha256Hash != nil { + encoded := make([]byte, sha256HexEncLen) + sum := make([]byte, sha256.Size) + + hex.Encode(encoded, sha256Hash.Sum(sum[0:0])) + r.HTTPRequest.Header[contentSha256Header] = []string{string(encoded)} + } +} + +const ( + md5Base64EncLen = (md5.Size + 2) / 3 * 4 // base64.StdEncoding.EncodedLen + sha256HexEncLen = sha256.Size * 2 // hex.EncodedLen +) + +func copySeekableBody(dst io.Writer, src io.ReadSeeker) (int64, error) { + curPos, err := src.Seek(0, sdkio.SeekCurrent) + if err != nil { + return 0, err + } + + // hash the body. seek back to the first position after reading to reset + // the body for transmission. copy errors may be assumed to be from the + // body. + n, err := io.Copy(dst, src) + if err != nil { + return n, err + } + + _, err = src.Seek(curPos, sdkio.SeekStart) + if err != nil { + return n, err + } + + return n, nil +} + +// Adds the x-amz-te: append_md5 header to the request. This requests the service +// responds with a trailing MD5 checksum. +// +// Will not ask for append MD5 if disabled, the request is presigned or, +// or the API operation does not support content MD5 validation. +func askForTxEncodingAppendMD5(r *request.Request) { + if aws.BoolValue(r.Config.S3DisableContentMD5Validation) { + return + } + if r.IsPresigned() { + return + } + r.HTTPRequest.Header.Set(amzTeHeader, appendMD5TxEncoding) +} + +func useMD5ValidationReader(r *request.Request) { + if r.Error != nil { + return + } + + if v := r.HTTPResponse.Header.Get(amzTxEncodingHeader); v != appendMD5TxEncoding { + return + } + + var bodyReader *io.ReadCloser + var contentLen int64 + switch tv := r.Data.(type) { + case *GetObjectOutput: + bodyReader = &tv.Body + contentLen = aws.Int64Value(tv.ContentLength) + // Update ContentLength hiden the trailing MD5 checksum. + tv.ContentLength = aws.Int64(contentLen - md5.Size) + tv.ContentRange = aws.String(r.HTTPResponse.Header.Get("X-Amz-Content-Range")) + default: + r.Error = awserr.New("ChecksumValidationError", + fmt.Sprintf("%s: %s header received on unsupported API, %s", + amzTxEncodingHeader, appendMD5TxEncoding, r.Operation.Name, + ), nil) + return + } + + if contentLen < md5.Size { + r.Error = awserr.New("ChecksumValidationError", + fmt.Sprintf("invalid Content-Length %d for %s %s", + contentLen, appendMD5TxEncoding, amzTxEncodingHeader, + ), nil) + return + } + + // Wrap and swap the response body reader with the validation reader. + *bodyReader = newMD5ValidationReader(*bodyReader, contentLen-md5.Size) +} + +type md5ValidationReader struct { + rawReader io.ReadCloser + payload io.Reader + hash hash.Hash + + payloadLen int64 + read int64 +} + +func newMD5ValidationReader(reader io.ReadCloser, payloadLen int64) *md5ValidationReader { + h := md5.New() + return &md5ValidationReader{ + rawReader: reader, + payload: io.TeeReader(&io.LimitedReader{R: reader, N: payloadLen}, h), + hash: h, + payloadLen: payloadLen, + } +} + +func (v *md5ValidationReader) Read(p []byte) (n int, err error) { + n, err = v.payload.Read(p) + if err != nil && err != io.EOF { + return n, err + } + + v.read += int64(n) + + if err == io.EOF { + if v.read != v.payloadLen { + return n, io.ErrUnexpectedEOF + } + expectSum := make([]byte, md5.Size) + actualSum := make([]byte, md5.Size) + if _, sumReadErr := io.ReadFull(v.rawReader, expectSum); sumReadErr != nil { + return n, sumReadErr + } + actualSum = v.hash.Sum(actualSum[0:0]) + if !bytes.Equal(expectSum, actualSum) { + return n, awserr.New("InvalidChecksum", + fmt.Sprintf("expected MD5 checksum %s, got %s", + hex.EncodeToString(expectSum), + hex.EncodeToString(actualSum), + ), + nil) + } + } + + return n, err +} + +func (v *md5ValidationReader) Close() error { + return v.rawReader.Close() +} diff --git a/vendor/github.com/aws/aws-sdk-go/service/s3/content_md5.go b/vendor/github.com/aws/aws-sdk-go/service/s3/content_md5.go deleted file mode 100644 index 9fc5df94d335..000000000000 --- a/vendor/github.com/aws/aws-sdk-go/service/s3/content_md5.go +++ /dev/null @@ -1,36 +0,0 @@ -package s3 - -import ( - "crypto/md5" - "encoding/base64" - "io" - - "github.com/aws/aws-sdk-go/aws/awserr" - "github.com/aws/aws-sdk-go/aws/request" -) - -// contentMD5 computes and sets the HTTP Content-MD5 header for requests that -// require it. -func contentMD5(r *request.Request) { - h := md5.New() - - // hash the body. seek back to the first position after reading to reset - // the body for transmission. copy errors may be assumed to be from the - // body. - _, err := io.Copy(h, r.Body) - if err != nil { - r.Error = awserr.New("ContentMD5", "failed to read body", err) - return - } - _, err = r.Body.Seek(0, 0) - if err != nil { - r.Error = awserr.New("ContentMD5", "failed to seek body", err) - return - } - - // encode the md5 checksum in base64 and set the request header. - sum := h.Sum(nil) - sum64 := make([]byte, base64.StdEncoding.EncodedLen(len(sum))) - base64.StdEncoding.Encode(sum64, sum) - r.HTTPRequest.Header.Set("Content-MD5", string(sum64)) -} diff --git a/vendor/github.com/aws/aws-sdk-go/service/s3/customizations.go b/vendor/github.com/aws/aws-sdk-go/service/s3/customizations.go index 899d5e8d108b..a55beab96db5 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/s3/customizations.go +++ b/vendor/github.com/aws/aws-sdk-go/service/s3/customizations.go @@ -42,6 +42,12 @@ func defaultInitRequestFn(r *request.Request) { r.Handlers.Validate.PushFront(populateLocationConstraint) case opCopyObject, opUploadPartCopy, opCompleteMultipartUpload: r.Handlers.Unmarshal.PushFront(copyMultipartStatusOKUnmarhsalError) + case opPutObject, opUploadPart: + r.Handlers.Build.PushBack(computeBodyHashes) + // Disabled until #1837 root issue is resolved. + // case opGetObject: + // r.Handlers.Build.PushBack(askForTxEncodingAppendMD5) + // r.Handlers.Unmarshal.PushBack(useMD5ValidationReader) } } diff --git a/vendor/github.com/aws/aws-sdk-go/service/s3/statusok_error.go b/vendor/github.com/aws/aws-sdk-go/service/s3/statusok_error.go index 5a78fd33703d..9f33efc6ca82 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/s3/statusok_error.go +++ b/vendor/github.com/aws/aws-sdk-go/service/s3/statusok_error.go @@ -7,6 +7,7 @@ import ( "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/aws/request" + "github.com/aws/aws-sdk-go/internal/sdkio" ) func copyMultipartStatusOKUnmarhsalError(r *request.Request) { @@ -17,7 +18,7 @@ func copyMultipartStatusOKUnmarhsalError(r *request.Request) { } body := bytes.NewReader(b) r.HTTPResponse.Body = ioutil.NopCloser(body) - defer body.Seek(0, 0) + defer body.Seek(0, sdkio.SeekStart) if body.Len() == 0 { // If there is no body don't attempt to parse the body. diff --git a/vendor/github.com/aws/aws-sdk-go/service/servicecatalog/api.go b/vendor/github.com/aws/aws-sdk-go/service/servicecatalog/api.go index 3ea8c14b7e25..9c32b8535e6f 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/servicecatalog/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/servicecatalog/api.go @@ -15,7 +15,7 @@ const opAcceptPortfolioShare = "AcceptPortfolioShare" // AcceptPortfolioShareRequest generates a "aws/request.Request" representing the // client's request for the AcceptPortfolioShare operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -102,7 +102,7 @@ const opAssociatePrincipalWithPortfolio = "AssociatePrincipalWithPortfolio" // AssociatePrincipalWithPortfolioRequest generates a "aws/request.Request" representing the // client's request for the AssociatePrincipalWithPortfolio operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -189,7 +189,7 @@ const opAssociateProductWithPortfolio = "AssociateProductWithPortfolio" // AssociateProductWithPortfolioRequest generates a "aws/request.Request" representing the // client's request for the AssociateProductWithPortfolio operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -276,7 +276,7 @@ const opAssociateTagOptionWithResource = "AssociateTagOptionWithResource" // AssociateTagOptionWithResourceRequest generates a "aws/request.Request" representing the // client's request for the AssociateTagOptionWithResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -376,7 +376,7 @@ const opCopyProduct = "CopyProduct" // CopyProductRequest generates a "aws/request.Request" representing the // client's request for the CopyProduct operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -465,7 +465,7 @@ const opCreateConstraint = "CreateConstraint" // CreateConstraintRequest generates a "aws/request.Request" representing the // client's request for the CreateConstraint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -555,7 +555,7 @@ const opCreatePortfolio = "CreatePortfolio" // CreatePortfolioRequest generates a "aws/request.Request" representing the // client's request for the CreatePortfolio operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -644,7 +644,7 @@ const opCreatePortfolioShare = "CreatePortfolioShare" // CreatePortfolioShareRequest generates a "aws/request.Request" representing the // client's request for the CreatePortfolioShare operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -731,7 +731,7 @@ const opCreateProduct = "CreateProduct" // CreateProductRequest generates a "aws/request.Request" representing the // client's request for the CreateProduct operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -820,7 +820,7 @@ const opCreateProvisionedProductPlan = "CreateProvisionedProductPlan" // CreateProvisionedProductPlanRequest generates a "aws/request.Request" representing the // client's request for the CreateProvisionedProductPlan operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -860,12 +860,12 @@ func (c *ServiceCatalog) CreateProvisionedProductPlanRequest(input *CreateProvis // CreateProvisionedProductPlan API operation for AWS Service Catalog. // -// Creates a plan. A plan includes the list of resources that will be created -// (when provisioning a new product) or modified (when updating a provisioned -// product) when the plan is executed. +// Creates a plan. A plan includes the list of resources to be created (when +// provisioning a new product) or modified (when updating a provisioned product) +// when the plan is executed. // // You can create one plan per provisioned product. To create a plan for an -// existing provisioned product, it's status must be AVAILBLE or TAINTED. +// existing provisioned product, the product status must be AVAILBLE or TAINTED. // // To view the resource changes in the change set, use DescribeProvisionedProductPlan. // To create or modify the provisioned product, use ExecuteProvisionedProductPlan. @@ -915,7 +915,7 @@ const opCreateProvisioningArtifact = "CreateProvisioningArtifact" // CreateProvisioningArtifactRequest generates a "aws/request.Request" representing the // client's request for the CreateProvisioningArtifact operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1006,7 +1006,7 @@ const opCreateTagOption = "CreateTagOption" // CreateTagOptionRequest generates a "aws/request.Request" representing the // client's request for the CreateTagOption operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1095,7 +1095,7 @@ const opDeleteConstraint = "DeleteConstraint" // DeleteConstraintRequest generates a "aws/request.Request" representing the // client's request for the DeleteConstraint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1177,7 +1177,7 @@ const opDeletePortfolio = "DeletePortfolio" // DeletePortfolioRequest generates a "aws/request.Request" representing the // client's request for the DeletePortfolio operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1271,7 +1271,7 @@ const opDeletePortfolioShare = "DeletePortfolioShare" // DeletePortfolioShareRequest generates a "aws/request.Request" representing the // client's request for the DeletePortfolioShare operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1350,7 +1350,7 @@ const opDeleteProduct = "DeleteProduct" // DeleteProductRequest generates a "aws/request.Request" representing the // client's request for the DeleteProduct operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1444,7 +1444,7 @@ const opDeleteProvisionedProductPlan = "DeleteProvisionedProductPlan" // DeleteProvisionedProductPlanRequest generates a "aws/request.Request" representing the // client's request for the DeleteProvisionedProductPlan operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1526,7 +1526,7 @@ const opDeleteProvisioningArtifact = "DeleteProvisioningArtifact" // DeleteProvisioningArtifactRequest generates a "aws/request.Request" representing the // client's request for the DeleteProvisioningArtifact operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1613,11 +1613,101 @@ func (c *ServiceCatalog) DeleteProvisioningArtifactWithContext(ctx aws.Context, return out, req.Send() } +const opDeleteTagOption = "DeleteTagOption" + +// DeleteTagOptionRequest generates a "aws/request.Request" representing the +// client's request for the DeleteTagOption operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeleteTagOption for more information on using the DeleteTagOption +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeleteTagOptionRequest method. +// req, resp := client.DeleteTagOptionRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/servicecatalog-2015-12-10/DeleteTagOption +func (c *ServiceCatalog) DeleteTagOptionRequest(input *DeleteTagOptionInput) (req *request.Request, output *DeleteTagOptionOutput) { + op := &request.Operation{ + Name: opDeleteTagOption, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DeleteTagOptionInput{} + } + + output = &DeleteTagOptionOutput{} + req = c.newRequest(op, input, output) + return +} + +// DeleteTagOption API operation for AWS Service Catalog. +// +// Deletes the specified TagOption. +// +// You cannot delete a TagOption if it is associated with a product or portfolio. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS Service Catalog's +// API operation DeleteTagOption for usage and error information. +// +// Returned Error Codes: +// * ErrCodeTagOptionNotMigratedException "TagOptionNotMigratedException" +// An operation requiring TagOptions failed because the TagOptions migration +// process has not been performed for this account. Please use the AWS console +// to perform the migration process before retrying the operation. +// +// * ErrCodeResourceInUseException "ResourceInUseException" +// A resource that is currently in use. Ensure that the resource is not in use +// and retry the operation. +// +// * ErrCodeResourceNotFoundException "ResourceNotFoundException" +// The specified resource was not found. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/servicecatalog-2015-12-10/DeleteTagOption +func (c *ServiceCatalog) DeleteTagOption(input *DeleteTagOptionInput) (*DeleteTagOptionOutput, error) { + req, out := c.DeleteTagOptionRequest(input) + return out, req.Send() +} + +// DeleteTagOptionWithContext is the same as DeleteTagOption with the addition of +// the ability to pass a context and additional request options. +// +// See DeleteTagOption for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ServiceCatalog) DeleteTagOptionWithContext(ctx aws.Context, input *DeleteTagOptionInput, opts ...request.Option) (*DeleteTagOptionOutput, error) { + req, out := c.DeleteTagOptionRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opDescribeConstraint = "DescribeConstraint" // DescribeConstraintRequest generates a "aws/request.Request" representing the // client's request for the DescribeConstraint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1696,7 +1786,7 @@ const opDescribeCopyProductStatus = "DescribeCopyProductStatus" // DescribeCopyProductStatusRequest generates a "aws/request.Request" representing the // client's request for the DescribeCopyProductStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1775,7 +1865,7 @@ const opDescribePortfolio = "DescribePortfolio" // DescribePortfolioRequest generates a "aws/request.Request" representing the // client's request for the DescribePortfolio operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1854,7 +1944,7 @@ const opDescribeProduct = "DescribeProduct" // DescribeProductRequest generates a "aws/request.Request" representing the // client's request for the DescribeProduct operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1936,7 +2026,7 @@ const opDescribeProductAsAdmin = "DescribeProductAsAdmin" // DescribeProductAsAdminRequest generates a "aws/request.Request" representing the // client's request for the DescribeProductAsAdmin operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2016,7 +2106,7 @@ const opDescribeProductView = "DescribeProductView" // DescribeProductViewRequest generates a "aws/request.Request" representing the // client's request for the DescribeProductView operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2098,7 +2188,7 @@ const opDescribeProvisionedProduct = "DescribeProvisionedProduct" // DescribeProvisionedProductRequest generates a "aws/request.Request" representing the // client's request for the DescribeProvisionedProduct operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2177,7 +2267,7 @@ const opDescribeProvisionedProductPlan = "DescribeProvisionedProductPlan" // DescribeProvisionedProductPlanRequest generates a "aws/request.Request" representing the // client's request for the DescribeProvisionedProductPlan operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2259,7 +2349,7 @@ const opDescribeProvisioningArtifact = "DescribeProvisioningArtifact" // DescribeProvisioningArtifactRequest generates a "aws/request.Request" representing the // client's request for the DescribeProvisioningArtifact operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2339,7 +2429,7 @@ const opDescribeProvisioningParameters = "DescribeProvisioningParameters" // DescribeProvisioningParametersRequest generates a "aws/request.Request" representing the // client's request for the DescribeProvisioningParameters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2429,7 +2519,7 @@ const opDescribeRecord = "DescribeRecord" // DescribeRecordRequest generates a "aws/request.Request" representing the // client's request for the DescribeRecord operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2511,7 +2601,7 @@ const opDescribeTagOption = "DescribeTagOption" // DescribeTagOptionRequest generates a "aws/request.Request" representing the // client's request for the DescribeTagOption operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2595,7 +2685,7 @@ const opDisassociatePrincipalFromPortfolio = "DisassociatePrincipalFromPortfolio // DisassociatePrincipalFromPortfolioRequest generates a "aws/request.Request" representing the // client's request for the DisassociatePrincipalFromPortfolio operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2677,7 +2767,7 @@ const opDisassociateProductFromPortfolio = "DisassociateProductFromPortfolio" // DisassociateProductFromPortfolioRequest generates a "aws/request.Request" representing the // client's request for the DisassociateProductFromPortfolio operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2763,7 +2853,7 @@ const opDisassociateTagOptionFromResource = "DisassociateTagOptionFromResource" // DisassociateTagOptionFromResourceRequest generates a "aws/request.Request" representing the // client's request for the DisassociateTagOptionFromResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2847,7 +2937,7 @@ const opExecuteProvisionedProductPlan = "ExecuteProvisionedProductPlan" // ExecuteProvisionedProductPlanRequest generates a "aws/request.Request" representing the // client's request for the ExecuteProvisionedProductPlan operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2935,7 +3025,7 @@ const opListAcceptedPortfolioShares = "ListAcceptedPortfolioShares" // ListAcceptedPortfolioSharesRequest generates a "aws/request.Request" representing the // client's request for the ListAcceptedPortfolioShares operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3070,7 +3160,7 @@ const opListConstraintsForPortfolio = "ListConstraintsForPortfolio" // ListConstraintsForPortfolioRequest generates a "aws/request.Request" representing the // client's request for the ListConstraintsForPortfolio operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3208,7 +3298,7 @@ const opListLaunchPaths = "ListLaunchPaths" // ListLaunchPathsRequest generates a "aws/request.Request" representing the // client's request for the ListLaunchPaths operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3348,7 +3438,7 @@ const opListPortfolioAccess = "ListPortfolioAccess" // ListPortfolioAccessRequest generates a "aws/request.Request" representing the // client's request for the ListPortfolioAccess operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3427,7 +3517,7 @@ const opListPortfolios = "ListPortfolios" // ListPortfoliosRequest generates a "aws/request.Request" representing the // client's request for the ListPortfolios operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3562,7 +3652,7 @@ const opListPortfoliosForProduct = "ListPortfoliosForProduct" // ListPortfoliosForProductRequest generates a "aws/request.Request" representing the // client's request for the ListPortfoliosForProduct operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3700,7 +3790,7 @@ const opListPrincipalsForPortfolio = "ListPrincipalsForPortfolio" // ListPrincipalsForPortfolioRequest generates a "aws/request.Request" representing the // client's request for the ListPrincipalsForPortfolio operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3838,7 +3928,7 @@ const opListProvisionedProductPlans = "ListProvisionedProductPlans" // ListProvisionedProductPlansRequest generates a "aws/request.Request" representing the // client's request for the ListProvisionedProductPlans operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3878,8 +3968,8 @@ func (c *ServiceCatalog) ListProvisionedProductPlansRequest(input *ListProvision // ListProvisionedProductPlans API operation for AWS Service Catalog. // -// Lists the plans for the specified provisioned product or all plans the user -// has access to. +// Lists the plans for the specified provisioned product or all plans to which +// the user has access. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -3921,7 +4011,7 @@ const opListProvisioningArtifacts = "ListProvisioningArtifacts" // ListProvisioningArtifactsRequest generates a "aws/request.Request" representing the // client's request for the ListProvisioningArtifacts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4004,7 +4094,7 @@ const opListRecordHistory = "ListRecordHistory" // ListRecordHistoryRequest generates a "aws/request.Request" representing the // client's request for the ListRecordHistory operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4083,7 +4173,7 @@ const opListResourcesForTagOption = "ListResourcesForTagOption" // ListResourcesForTagOptionRequest generates a "aws/request.Request" representing the // client's request for the ListResourcesForTagOption operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4226,7 +4316,7 @@ const opListTagOptions = "ListTagOptions" // ListTagOptionsRequest generates a "aws/request.Request" representing the // client's request for the ListTagOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4366,7 +4456,7 @@ const opProvisionProduct = "ProvisionProduct" // ProvisionProductRequest generates a "aws/request.Request" representing the // client's request for the ProvisionProduct operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4461,7 +4551,7 @@ const opRejectPortfolioShare = "RejectPortfolioShare" // RejectPortfolioShareRequest generates a "aws/request.Request" representing the // client's request for the RejectPortfolioShare operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4540,7 +4630,7 @@ const opScanProvisionedProducts = "ScanProvisionedProducts" // ScanProvisionedProductsRequest generates a "aws/request.Request" representing the // client's request for the ScanProvisionedProducts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4621,7 +4711,7 @@ const opSearchProducts = "SearchProducts" // SearchProductsRequest generates a "aws/request.Request" representing the // client's request for the SearchProducts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4756,7 +4846,7 @@ const opSearchProductsAsAdmin = "SearchProductsAsAdmin" // SearchProductsAsAdminRequest generates a "aws/request.Request" representing the // client's request for the SearchProductsAsAdmin operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4894,7 +4984,7 @@ const opSearchProvisionedProducts = "SearchProvisionedProducts" // SearchProvisionedProductsRequest generates a "aws/request.Request" representing the // client's request for the SearchProvisionedProducts operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5029,7 +5119,7 @@ const opTerminateProvisionedProduct = "TerminateProvisionedProduct" // TerminateProvisionedProductRequest generates a "aws/request.Request" representing the // client's request for the TerminateProvisionedProduct operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5113,7 +5203,7 @@ const opUpdateConstraint = "UpdateConstraint" // UpdateConstraintRequest generates a "aws/request.Request" representing the // client's request for the UpdateConstraint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5195,7 +5285,7 @@ const opUpdatePortfolio = "UpdatePortfolio" // UpdatePortfolioRequest generates a "aws/request.Request" representing the // client's request for the UpdatePortfolio operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5289,7 +5379,7 @@ const opUpdateProduct = "UpdateProduct" // UpdateProductRequest generates a "aws/request.Request" representing the // client's request for the UpdateProduct operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5376,7 +5466,7 @@ const opUpdateProvisionedProduct = "UpdateProvisionedProduct" // UpdateProvisionedProductRequest generates a "aws/request.Request" representing the // client's request for the UpdateProvisionedProduct operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5465,7 +5555,7 @@ const opUpdateProvisioningArtifact = "UpdateProvisioningArtifact" // UpdateProvisioningArtifactRequest generates a "aws/request.Request" representing the // client's request for the UpdateProvisioningArtifact operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5551,7 +5641,7 @@ const opUpdateTagOption = "UpdateTagOption" // UpdateTagOptionRequest generates a "aws/request.Request" representing the // client's request for the UpdateTagOption operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7862,6 +7952,61 @@ func (s DeleteProvisioningArtifactOutput) GoString() string { return s.String() } +type DeleteTagOptionInput struct { + _ struct{} `type:"structure"` + + // The TagOption identifier. + // + // Id is a required field + Id *string `min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s DeleteTagOptionInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteTagOptionInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteTagOptionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteTagOptionInput"} + if s.Id == nil { + invalidParams.Add(request.NewErrParamRequired("Id")) + } + if s.Id != nil && len(*s.Id) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Id", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetId sets the Id field's value. +func (s *DeleteTagOptionInput) SetId(v string) *DeleteTagOptionInput { + s.Id = &v + return s +} + +type DeleteTagOptionOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeleteTagOptionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeleteTagOptionOutput) GoString() string { + return s.String() +} + type DescribeConstraintInput struct { _ struct{} `type:"structure"` @@ -8609,8 +8754,7 @@ type DescribeProvisionedProductPlanOutput struct { // Information about the plan. ProvisionedProductPlanDetails *ProvisionedProductPlanDetails `type:"structure"` - // Information about the resources changes that will occur when the plan is - // executed. + // Information about the resource changes that will occur when the plan is executed. ResourceChanges []*ResourceChange `type:"list"` } @@ -12610,12 +12754,12 @@ type ResourceChangeDetail struct { // The ID of the entity that caused the change. CausingEntity *string `type:"string"` - // For static evaluations, the value the resource attribute will change and + // For static evaluations, the value of the resource attribute will change and // the new value is known. For dynamic evaluations, the value might change, // and any new value will be determined when the plan is updated. Evaluation *string `type:"string" enum:"EvaluationType"` - // Information about the resource attribute that will be modified. + // Information about the resource attribute to be modified. Target *ResourceTargetDefinition `type:"structure"` } @@ -12711,7 +12855,7 @@ func (s *ResourceDetail) SetName(v string) *ResourceDetail { type ResourceTargetDefinition struct { _ struct{} `type:"structure"` - // The attribute that will change. + // The attribute to be changed. Attribute *string `type:"string" enum:"ResourceAttribute"` // If the attribute is Properties, the value is the name of the property. Otherwise, @@ -12719,7 +12863,7 @@ type ResourceTargetDefinition struct { Name *string `type:"string"` // If the attribute is Properties, indicates whether a change to this property - // causes the resource to be recreated. + // causes the resource to be re-created. RequiresRecreation *string `type:"string" enum:"RequiresRecreation"` } diff --git a/vendor/github.com/aws/aws-sdk-go/service/servicediscovery/api.go b/vendor/github.com/aws/aws-sdk-go/service/servicediscovery/api.go index 197246706280..a76d05b57bed 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/servicediscovery/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/servicediscovery/api.go @@ -9,13 +9,15 @@ import ( "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awsutil" "github.com/aws/aws-sdk-go/aws/request" + "github.com/aws/aws-sdk-go/private/protocol" + "github.com/aws/aws-sdk-go/private/protocol/jsonrpc" ) const opCreatePrivateDnsNamespace = "CreatePrivateDnsNamespace" // CreatePrivateDnsNamespaceRequest generates a "aws/request.Request" representing the // client's request for the CreatePrivateDnsNamespace operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -59,7 +61,9 @@ func (c *ServiceDiscovery) CreatePrivateDnsNamespaceRequest(input *CreatePrivate // a specified Amazon VPC. The namespace defines your service naming scheme. // For example, if you name your namespace example.com and name your service // backend, the resulting DNS name for the service will be backend.example.com. -// You can associate more than one service with the same namespace. +// For the current limit on the number of namespaces that you can create using +// the same AWS account, see Limits on Auto Naming (http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/DNSLimitations.html#limits-api-entities-autonaming) +// in the Route 53 Developer Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -109,7 +113,7 @@ const opCreatePublicDnsNamespace = "CreatePublicDnsNamespace" // CreatePublicDnsNamespaceRequest generates a "aws/request.Request" representing the // client's request for the CreatePublicDnsNamespace operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -152,8 +156,10 @@ func (c *ServiceDiscovery) CreatePublicDnsNamespaceRequest(input *CreatePublicDn // Creates a public namespace based on DNS, which will be visible on the internet. // The namespace defines your service naming scheme. For example, if you name // your namespace example.com and name your service backend, the resulting DNS -// name for the service will be backend.example.com. You can associate more -// than one service with the same namespace. +// name for the service will be backend.example.com. For the current limit on +// the number of namespaces that you can create using the same AWS account, +// see Limits on Auto Naming (http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/DNSLimitations.html#limits-api-entities-autonaming) +// in the Route 53 Developer Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -203,7 +209,7 @@ const opCreateService = "CreateService" // CreateServiceRequest generates a "aws/request.Request" representing the // client's request for the CreateService operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -253,6 +259,11 @@ func (c *ServiceDiscovery) CreateServiceRequest(input *CreateServiceInput) (req // and Amazon Route 53 uses the values in the configuration to create the specified // entities. // +// For the current limit on the number of instances that you can register using +// the same namespace and using the same service, see Limits on Auto Naming +// (http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/DNSLimitations.html#limits-api-entities-autonaming) +// in the Route 53 Developer Guide. +// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -302,7 +313,7 @@ const opDeleteNamespace = "DeleteNamespace" // DeleteNamespaceRequest generates a "aws/request.Request" representing the // client's request for the DeleteNamespace operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -393,7 +404,7 @@ const opDeleteService = "DeleteService" // DeleteServiceRequest generates a "aws/request.Request" representing the // client's request for the DeleteService operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -481,7 +492,7 @@ const opDeregisterInstance = "DeregisterInstance" // DeregisterInstanceRequest generates a "aws/request.Request" representing the // client's request for the DeregisterInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -576,7 +587,7 @@ const opGetInstance = "GetInstance" // GetInstanceRequest generates a "aws/request.Request" representing the // client's request for the GetInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -663,7 +674,7 @@ const opGetInstancesHealthStatus = "GetInstancesHealthStatus" // GetInstancesHealthStatusRequest generates a "aws/request.Request" representing the // client's request for the GetInstancesHealthStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -810,7 +821,7 @@ const opGetNamespace = "GetNamespace" // GetNamespaceRequest generates a "aws/request.Request" representing the // client's request for the GetNamespace operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -893,7 +904,7 @@ const opGetOperation = "GetOperation" // GetOperationRequest generates a "aws/request.Request" representing the // client's request for the GetOperation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -975,7 +986,7 @@ const opGetService = "GetService" // GetServiceRequest generates a "aws/request.Request" representing the // client's request for the GetService operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1058,7 +1069,7 @@ const opListInstances = "ListInstances" // ListInstancesRequest generates a "aws/request.Request" representing the // client's request for the ListInstances operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1198,7 +1209,7 @@ const opListNamespaces = "ListNamespaces" // ListNamespacesRequest generates a "aws/request.Request" representing the // client's request for the ListNamespaces operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1335,7 +1346,7 @@ const opListOperations = "ListOperations" // ListOperationsRequest generates a "aws/request.Request" representing the // client's request for the ListOperations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1471,7 +1482,7 @@ const opListServices = "ListServices" // ListServicesRequest generates a "aws/request.Request" representing the // client's request for the ListServices operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1608,7 +1619,7 @@ const opRegisterInstance = "RegisterInstance" // RegisterInstanceRequest generates a "aws/request.Request" representing the // client's request for the RegisterInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1656,8 +1667,8 @@ func (c *ServiceDiscovery) RegisterInstanceRequest(input *RegisterInstanceInput) // creates or updates a record in the hosted zone that is associated with // the corresponding namespace // -// * Creates or updates a health check based on the settings in the health -// check configuration, if any, for the service +// * If the service includes HealthCheckConfig, creates or updates a health +// check based on the settings in the health check configuration // // * Associates the health check, if any, with each of the records // @@ -1671,12 +1682,17 @@ func (c *ServiceDiscovery) RegisterInstanceRequest(input *RegisterInstanceInput) // // * If the health check is healthy: returns all the records // -// * If the health check is unhealthy: returns the IP address of the last -// healthy instance +// * If the health check is unhealthy: returns the applicable value for the +// last healthy instance // // * If you didn't specify a health check configuration: returns all the // records // +// For the current limit on the number of instances that you can register using +// the same namespace and using the same service, see Limits on Auto Naming +// (http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/DNSLimitations.html#limits-api-entities-autonaming) +// in the Route 53 Developer Guide. +// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -1725,11 +1741,100 @@ func (c *ServiceDiscovery) RegisterInstanceWithContext(ctx aws.Context, input *R return out, req.Send() } +const opUpdateInstanceCustomHealthStatus = "UpdateInstanceCustomHealthStatus" + +// UpdateInstanceCustomHealthStatusRequest generates a "aws/request.Request" representing the +// client's request for the UpdateInstanceCustomHealthStatus operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateInstanceCustomHealthStatus for more information on using the UpdateInstanceCustomHealthStatus +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the UpdateInstanceCustomHealthStatusRequest method. +// req, resp := client.UpdateInstanceCustomHealthStatusRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/UpdateInstanceCustomHealthStatus +func (c *ServiceDiscovery) UpdateInstanceCustomHealthStatusRequest(input *UpdateInstanceCustomHealthStatusInput) (req *request.Request, output *UpdateInstanceCustomHealthStatusOutput) { + op := &request.Operation{ + Name: opUpdateInstanceCustomHealthStatus, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &UpdateInstanceCustomHealthStatusInput{} + } + + output = &UpdateInstanceCustomHealthStatusOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(jsonrpc.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) + return +} + +// UpdateInstanceCustomHealthStatus API operation for Amazon Route 53 Auto Naming. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon Route 53 Auto Naming's +// API operation UpdateInstanceCustomHealthStatus for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInstanceNotFound "InstanceNotFound" +// No instance exists with the specified ID, or the instance was recently registered, +// and information about the instance hasn't propagated yet. +// +// * ErrCodeServiceNotFound "ServiceNotFound" +// No service exists with the specified ID. +// +// * ErrCodeCustomHealthNotFound "CustomHealthNotFound" +// +// * ErrCodeInvalidInput "InvalidInput" +// One or more specified values aren't valid. For example, when you're creating +// a namespace, the value of Name might not be a valid DNS name. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/UpdateInstanceCustomHealthStatus +func (c *ServiceDiscovery) UpdateInstanceCustomHealthStatus(input *UpdateInstanceCustomHealthStatusInput) (*UpdateInstanceCustomHealthStatusOutput, error) { + req, out := c.UpdateInstanceCustomHealthStatusRequest(input) + return out, req.Send() +} + +// UpdateInstanceCustomHealthStatusWithContext is the same as UpdateInstanceCustomHealthStatus with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateInstanceCustomHealthStatus for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ServiceDiscovery) UpdateInstanceCustomHealthStatusWithContext(ctx aws.Context, input *UpdateInstanceCustomHealthStatusInput, opts ...request.Option) (*UpdateInstanceCustomHealthStatusOutput, error) { + req, out := c.UpdateInstanceCustomHealthStatusRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opUpdateService = "UpdateService" // UpdateServiceRequest generates a "aws/request.Request" representing the // client's request for the UpdateService operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1777,10 +1882,13 @@ func (c *ServiceDiscovery) UpdateServiceRequest(input *UpdateServiceInput) (req // // * Add, update, or delete HealthCheckConfig for a specified service // -// * +// You must specify all DnsRecords configurations (and, optionally, HealthCheckConfig) +// that you want to appear in the updated service. Any current configurations +// that don't appear in an UpdateService request are deleted. // -// You must specify all DnsRecordsconfigurations (and, optionally, HealthCheckConfig) that you want to appear in the updated service. Any current configurations -// that don't appear in an UpdateService +// When you update the TTL setting for a service, Amazon Route 53 also updates +// the corresponding settings in all the records and health checks that were +// created by using the specified service. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -2027,6 +2135,8 @@ type CreateServiceInput struct { // (http://aws.amazon.com/route53/pricing). HealthCheckConfig *HealthCheckConfig `type:"structure"` + HealthCheckCustomConfig *HealthCheckCustomConfig `type:"structure"` + // The name that you want to assign to the service. // // Name is a required field @@ -2062,6 +2172,11 @@ func (s *CreateServiceInput) Validate() error { invalidParams.AddNested("HealthCheckConfig", err.(request.ErrInvalidParams)) } } + if s.HealthCheckCustomConfig != nil { + if err := s.HealthCheckCustomConfig.Validate(); err != nil { + invalidParams.AddNested("HealthCheckCustomConfig", err.(request.ErrInvalidParams)) + } + } if invalidParams.Len() > 0 { return invalidParams @@ -2093,6 +2208,12 @@ func (s *CreateServiceInput) SetHealthCheckConfig(v *HealthCheckConfig) *CreateS return s } +// SetHealthCheckCustomConfig sets the HealthCheckCustomConfig field's value. +func (s *CreateServiceInput) SetHealthCheckCustomConfig(v *HealthCheckCustomConfig) *CreateServiceInput { + s.HealthCheckCustomConfig = v + return s +} + // SetName sets the Name field's value. func (s *CreateServiceInput) SetName(v string) *CreateServiceInput { s.Name = &v @@ -3108,9 +3229,7 @@ type HealthCheckConfig struct { // For more information, see How Route 53 Determines Whether an Endpoint Is // Healthy (http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-determining-health-of-endpoints.html) // in the Route 53 Developer Guide. - // - // Type is a required field - Type *string `type:"string" required:"true" enum:"HealthCheckType"` + Type *string `type:"string" enum:"HealthCheckType"` } // String returns the string representation @@ -3129,9 +3248,6 @@ func (s *HealthCheckConfig) Validate() error { if s.FailureThreshold != nil && *s.FailureThreshold < 1 { invalidParams.Add(request.NewErrParamMinValue("FailureThreshold", 1)) } - if s.Type == nil { - invalidParams.Add(request.NewErrParamRequired("Type")) - } if invalidParams.Len() > 0 { return invalidParams @@ -3157,6 +3273,41 @@ func (s *HealthCheckConfig) SetType(v string) *HealthCheckConfig { return s } +type HealthCheckCustomConfig struct { + _ struct{} `type:"structure"` + + FailureThreshold *int64 `min:"1" type:"integer"` +} + +// String returns the string representation +func (s HealthCheckCustomConfig) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s HealthCheckCustomConfig) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *HealthCheckCustomConfig) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "HealthCheckCustomConfig"} + if s.FailureThreshold != nil && *s.FailureThreshold < 1 { + invalidParams.Add(request.NewErrParamMinValue("FailureThreshold", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetFailureThreshold sets the FailureThreshold field's value. +func (s *HealthCheckCustomConfig) SetFailureThreshold(v int64) *HealthCheckCustomConfig { + s.FailureThreshold = &v + return s +} + // A complex type that contains information about an instance that Amazon Route // 53 creates when you submit a RegisterInstance request. type Instance struct { @@ -3172,59 +3323,60 @@ type Instance struct { // // Supported attribute keys include the following: // - // * AWS_ALIAS_DNS_NAME: If you want Route 53 to create an alias record that - // routes traffic to an Elastic Load Balancing load balancer, specify the - // DNS name that is associated with the load balancer. For information about - // how to get the DNS name, see "DNSName" in the topic AliasTarget (http://docs.aws.amazon.com/http:/docs.aws.amazon.com/Route53/latest/APIReference/API_AliasTarget.html). + // AWS_ALIAS_DNS_NAME + // + // If you want Route 53 to create an alias record that routes traffic to an + // Elastic Load Balancing load balancer, specify the DNS name that is associated + // with the load balancer. For information about how to get the DNS name, see + // "DNSName" in the topic AliasTarget (http://docs.aws.amazon.com/http:/docs.aws.amazon.com/Route53/latest/APIReference/API_AliasTarget.html). // // Note the following: // // The configuration for the service that is specified by ServiceId must include - // settings for an A record, an AAAA record, or both. + // settings for an A record, an AAAA record, or both. // - // In the service that is specified by ServiceId, the value of RoutingPolicy + // * In the service that is specified by ServiceId, the value of RoutingPolicy // must be WEIGHTED. // - // If the service that is specified by ServiceId includes HealthCheckConfig + // * If the service that is specified by ServiceId includes HealthCheckConfig // settings, Route 53 will create the health check, but it won't associate // the health check with the alias record. // - // Auto naming currently doesn't support creating alias records that route traffic - // to AWS resources other than ELB load balancers. + // * Auto naming currently doesn't support creating alias records that route + // traffic to AWS resources other than ELB load balancers. // - // If you specify a value for AWS_ALIAS_DNS_NAME, don't specify values for any - // of the AWS_INSTANCE attributes. + // * If you specify a value for AWS_ALIAS_DNS_NAME, don't specify values + // for any of the AWS_INSTANCE attributes. // - // * AWS_INSTANCE_CNAME: If the service configuration includes a CNAME record, - // the domain name that you want Route 53 to return in response to DNS queries, - // for example, example.com. + // AWS_INSTANCE_CNAME // - // This value is required if the service specified by ServiceId includes settings - // for an CNAME record. + // If the service configuration includes a CNAME record, the domain name that + // you want Route 53 to return in response to DNS queries, for example, example.com. // - // * AWS_INSTANCE_IPV4: If the service configuration includes an A record, - // the IPv4 address that you want Route 53 to return in response to DNS queries, - // for example, 192.0.2.44. + // This value is required if the service specified by ServiceIdincludes settings for an CNAME record. // - // This value is required if the service specified by ServiceId includes settings - // for an A record. Either AWS_INSTANCE_IPV4 or AWS_INSTANCE_IPV6 is required - // if the service includes settings for an SRV record. + // AWS_INSTANCE_IPV4 // - // * AWS_INSTANCE_IPV6: If the service configuration includes an AAAA record, - // the IPv6 address that you want Route 53 to return in response to DNS queries, - // for example, 2001:0db8:85a3:0000:0000:abcd:0001:2345. + // If the service configuration includes an A record, the IPv4 address that + // you want Route 53 to return in response to DNS queries, for example, 192.0.2.44. // - // This value is required if the service specified by ServiceId includes settings - // for an AAAA record. Either AWS_INSTANCE_IPV4 or AWS_INSTANCE_IPV6 is required - // if the service includes settings for an SRV record. + // This value is required if the service specified by ServiceIdincludes settings for an A record. If the service includes settings for an + // SRV record, you must specify a value for AWS_INSTANCE_IPV4, AWS_INSTANCE_IPV6, or both. // - // * AWS_INSTANCE_PORT: If the service includes an SRV record, the value - // that you want Route 53 to return for the port. In addition, if the service - // includes HealthCheckConfig, the port on the endpoint that you want Route - // 53 to send requests to. For more information, see CreateService. + // AWS_INSTANCE_IPV6 // - // This value is required if you specified settings for an SRV record when you - // created the service. + // If the service configuration includes an AAAA record, the IPv6 address that + // you want Route 53 to return in response to DNS queries, for example, 2001:0db8:85a3:0000:0000:abcd:0001:2345. + // + // This value is required if the service specified by ServiceIdincludes settings for an AAAA record. If the service includes settings for + // an SRV record, you must specify a value for AWS_INSTANCE_IPV4, AWS_INSTANCE_IPV6, or both. + // + // AWS_INSTANCE_PORT + // + // If the service includes an SRV record, the value that you want Route 53 to + // return for the port. + // + // If the service includes HealthCheckConfig Attributes map[string]*string `type:"map"` // A unique string that identifies the request and that allows failed RegisterInstance @@ -4372,14 +4524,16 @@ type RegisterInstanceInput struct { // If the service configuration includes an A record, the IPv4 address that // you want Route 53 to return in response to DNS queries, for example, 192.0.2.44. // - // This value is required if the service specified by ServiceIdincludes settings for an A record. Either AWS_INSTANCE_IPV4or AWS_INSTANCE_IPV6is required if the service includes settings for an SRV record. + // This value is required if the service specified by ServiceIdincludes settings for an A record. If the service includes settings for an + // SRV record, you must specify a value for AWS_INSTANCE_IPV4, AWS_INSTANCE_IPV6, or both. // // AWS_INSTANCE_IPV6 // // If the service configuration includes an AAAA record, the IPv6 address that // you want Route 53 to return in response to DNS queries, for example, 2001:0db8:85a3:0000:0000:abcd:0001:2345. // - // This value is required if the service specified by ServiceIdincludes settings for an AAAA record. Either AWS_INSTANCE_IPV4or AWS_INSTANCE_IPV6is required if the service includes settings for an SRV record. + // This value is required if the service specified by ServiceIdincludes settings for an AAAA record. If the service includes settings for + // an SRV record, you must specify a value for AWS_INSTANCE_IPV4, AWS_INSTANCE_IPV6, or both. // // AWS_INSTANCE_PORT // @@ -4538,6 +4692,8 @@ type Service struct { // (http://aws.amazon.com/route53/pricing). HealthCheckConfig *HealthCheckConfig `type:"structure"` + HealthCheckCustomConfig *HealthCheckCustomConfig `type:"structure"` + // The ID that Route 53 assigned to the service when you created it. Id *string `type:"string"` @@ -4596,6 +4752,12 @@ func (s *Service) SetHealthCheckConfig(v *HealthCheckConfig) *Service { return s } +// SetHealthCheckCustomConfig sets the HealthCheckCustomConfig field's value. +func (s *Service) SetHealthCheckCustomConfig(v *HealthCheckCustomConfig) *Service { + s.HealthCheckCustomConfig = v + return s +} + // SetId sets the Id field's value. func (s *Service) SetId(v string) *Service { s.Id = &v @@ -4867,6 +5029,80 @@ func (s *ServiceSummary) SetName(v string) *ServiceSummary { return s } +type UpdateInstanceCustomHealthStatusInput struct { + _ struct{} `type:"structure"` + + // InstanceId is a required field + InstanceId *string `type:"string" required:"true"` + + // ServiceId is a required field + ServiceId *string `type:"string" required:"true"` + + // Status is a required field + Status *string `type:"string" required:"true" enum:"CustomHealthStatus"` +} + +// String returns the string representation +func (s UpdateInstanceCustomHealthStatusInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateInstanceCustomHealthStatusInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *UpdateInstanceCustomHealthStatusInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdateInstanceCustomHealthStatusInput"} + if s.InstanceId == nil { + invalidParams.Add(request.NewErrParamRequired("InstanceId")) + } + if s.ServiceId == nil { + invalidParams.Add(request.NewErrParamRequired("ServiceId")) + } + if s.Status == nil { + invalidParams.Add(request.NewErrParamRequired("Status")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetInstanceId sets the InstanceId field's value. +func (s *UpdateInstanceCustomHealthStatusInput) SetInstanceId(v string) *UpdateInstanceCustomHealthStatusInput { + s.InstanceId = &v + return s +} + +// SetServiceId sets the ServiceId field's value. +func (s *UpdateInstanceCustomHealthStatusInput) SetServiceId(v string) *UpdateInstanceCustomHealthStatusInput { + s.ServiceId = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *UpdateInstanceCustomHealthStatusInput) SetStatus(v string) *UpdateInstanceCustomHealthStatusInput { + s.Status = &v + return s +} + +type UpdateInstanceCustomHealthStatusOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s UpdateInstanceCustomHealthStatusOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UpdateInstanceCustomHealthStatusOutput) GoString() string { + return s.String() +} + type UpdateServiceInput struct { _ struct{} `type:"structure"` @@ -4948,6 +5184,14 @@ func (s *UpdateServiceOutput) SetOperationId(v string) *UpdateServiceOutput { return s } +const ( + // CustomHealthStatusHealthy is a CustomHealthStatus enum value + CustomHealthStatusHealthy = "HEALTHY" + + // CustomHealthStatusUnhealthy is a CustomHealthStatus enum value + CustomHealthStatusUnhealthy = "UNHEALTHY" +) + const ( // FilterConditionEq is a FilterCondition enum value FilterConditionEq = "EQ" diff --git a/vendor/github.com/aws/aws-sdk-go/service/servicediscovery/errors.go b/vendor/github.com/aws/aws-sdk-go/service/servicediscovery/errors.go index 7b24d6e99404..d1f9f8dcd9b3 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/servicediscovery/errors.go +++ b/vendor/github.com/aws/aws-sdk-go/service/servicediscovery/errors.go @@ -4,6 +4,10 @@ package servicediscovery const ( + // ErrCodeCustomHealthNotFound for service response error code + // "CustomHealthNotFound". + ErrCodeCustomHealthNotFound = "CustomHealthNotFound" + // ErrCodeDuplicateRequest for service response error code // "DuplicateRequest". // diff --git a/vendor/github.com/aws/aws-sdk-go/service/ses/api.go b/vendor/github.com/aws/aws-sdk-go/service/ses/api.go index 5325ba8fd1b4..88c520d0a4af 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/ses/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/ses/api.go @@ -17,7 +17,7 @@ const opCloneReceiptRuleSet = "CloneReceiptRuleSet" // CloneReceiptRuleSetRequest generates a "aws/request.Request" representing the // client's request for the CloneReceiptRuleSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -110,7 +110,7 @@ const opCreateConfigurationSet = "CreateConfigurationSet" // CreateConfigurationSetRequest generates a "aws/request.Request" representing the // client's request for the CreateConfigurationSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -203,7 +203,7 @@ const opCreateConfigurationSetEventDestination = "CreateConfigurationSetEventDes // CreateConfigurationSetEventDestinationRequest generates a "aws/request.Request" representing the // client's request for the CreateConfigurationSetEventDestination operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -312,7 +312,7 @@ const opCreateConfigurationSetTrackingOptions = "CreateConfigurationSetTrackingO // CreateConfigurationSetTrackingOptionsRequest generates a "aws/request.Request" representing the // client's request for the CreateConfigurationSetTrackingOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -410,7 +410,7 @@ const opCreateCustomVerificationEmailTemplate = "CreateCustomVerificationEmailTe // CreateCustomVerificationEmailTemplateRequest generates a "aws/request.Request" representing the // client's request for the CreateCustomVerificationEmailTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -510,7 +510,7 @@ const opCreateReceiptFilter = "CreateReceiptFilter" // CreateReceiptFilterRequest generates a "aws/request.Request" representing the // client's request for the CreateReceiptFilter operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -598,7 +598,7 @@ const opCreateReceiptRule = "CreateReceiptRule" // CreateReceiptRuleRequest generates a "aws/request.Request" representing the // client's request for the CreateReceiptRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -709,7 +709,7 @@ const opCreateReceiptRuleSet = "CreateReceiptRuleSet" // CreateReceiptRuleSetRequest generates a "aws/request.Request" representing the // client's request for the CreateReceiptRuleSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -797,7 +797,7 @@ const opCreateTemplate = "CreateTemplate" // CreateTemplateRequest generates a "aws/request.Request" representing the // client's request for the CreateTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -888,7 +888,7 @@ const opDeleteConfigurationSet = "DeleteConfigurationSet" // DeleteConfigurationSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteConfigurationSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -971,7 +971,7 @@ const opDeleteConfigurationSetEventDestination = "DeleteConfigurationSetEventDes // DeleteConfigurationSetEventDestinationRequest generates a "aws/request.Request" representing the // client's request for the DeleteConfigurationSetEventDestination operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1058,7 +1058,7 @@ const opDeleteConfigurationSetTrackingOptions = "DeleteConfigurationSetTrackingO // DeleteConfigurationSetTrackingOptionsRequest generates a "aws/request.Request" representing the // client's request for the DeleteConfigurationSetTrackingOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1151,7 +1151,7 @@ const opDeleteCustomVerificationEmailTemplate = "DeleteCustomVerificationEmailTe // DeleteCustomVerificationEmailTemplateRequest generates a "aws/request.Request" representing the // client's request for the DeleteCustomVerificationEmailTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1233,7 +1233,7 @@ const opDeleteIdentity = "DeleteIdentity" // DeleteIdentityRequest generates a "aws/request.Request" representing the // client's request for the DeleteIdentity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1310,7 +1310,7 @@ const opDeleteIdentityPolicy = "DeleteIdentityPolicy" // DeleteIdentityPolicyRequest generates a "aws/request.Request" representing the // client's request for the DeleteIdentityPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1395,7 +1395,7 @@ const opDeleteReceiptFilter = "DeleteReceiptFilter" // DeleteReceiptFilterRequest generates a "aws/request.Request" representing the // client's request for the DeleteReceiptFilter operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1474,7 +1474,7 @@ const opDeleteReceiptRule = "DeleteReceiptRule" // DeleteReceiptRuleRequest generates a "aws/request.Request" representing the // client's request for the DeleteReceiptRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1558,7 +1558,7 @@ const opDeleteReceiptRuleSet = "DeleteReceiptRuleSet" // DeleteReceiptRuleSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteReceiptRuleSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1644,7 +1644,7 @@ const opDeleteTemplate = "DeleteTemplate" // DeleteTemplateRequest generates a "aws/request.Request" representing the // client's request for the DeleteTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1720,7 +1720,7 @@ const opDeleteVerifiedEmailAddress = "DeleteVerifiedEmailAddress" // DeleteVerifiedEmailAddressRequest generates a "aws/request.Request" representing the // client's request for the DeleteVerifiedEmailAddress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1797,7 +1797,7 @@ const opDescribeActiveReceiptRuleSet = "DescribeActiveReceiptRuleSet" // DescribeActiveReceiptRuleSetRequest generates a "aws/request.Request" representing the // client's request for the DescribeActiveReceiptRuleSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1877,7 +1877,7 @@ const opDescribeConfigurationSet = "DescribeConfigurationSet" // DescribeConfigurationSetRequest generates a "aws/request.Request" representing the // client's request for the DescribeConfigurationSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1959,7 +1959,7 @@ const opDescribeReceiptRule = "DescribeReceiptRule" // DescribeReceiptRuleRequest generates a "aws/request.Request" representing the // client's request for the DescribeReceiptRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2046,7 +2046,7 @@ const opDescribeReceiptRuleSet = "DescribeReceiptRuleSet" // DescribeReceiptRuleSetRequest generates a "aws/request.Request" representing the // client's request for the DescribeReceiptRuleSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2130,7 +2130,7 @@ const opGetAccountSendingEnabled = "GetAccountSendingEnabled" // GetAccountSendingEnabledRequest generates a "aws/request.Request" representing the // client's request for the GetAccountSendingEnabled operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2206,7 +2206,7 @@ const opGetCustomVerificationEmailTemplate = "GetCustomVerificationEmailTemplate // GetCustomVerificationEmailTemplateRequest generates a "aws/request.Request" representing the // client's request for the GetCustomVerificationEmailTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2293,7 +2293,7 @@ const opGetIdentityDkimAttributes = "GetIdentityDkimAttributes" // GetIdentityDkimAttributesRequest generates a "aws/request.Request" representing the // client's request for the GetIdentityDkimAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2388,7 +2388,7 @@ const opGetIdentityMailFromDomainAttributes = "GetIdentityMailFromDomainAttribut // GetIdentityMailFromDomainAttributesRequest generates a "aws/request.Request" representing the // client's request for the GetIdentityMailFromDomainAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2466,7 +2466,7 @@ const opGetIdentityNotificationAttributes = "GetIdentityNotificationAttributes" // GetIdentityNotificationAttributesRequest generates a "aws/request.Request" representing the // client's request for the GetIdentityNotificationAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2547,7 +2547,7 @@ const opGetIdentityPolicies = "GetIdentityPolicies" // GetIdentityPoliciesRequest generates a "aws/request.Request" representing the // client's request for the GetIdentityPolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2633,7 +2633,7 @@ const opGetIdentityVerificationAttributes = "GetIdentityVerificationAttributes" // GetIdentityVerificationAttributesRequest generates a "aws/request.Request" representing the // client's request for the GetIdentityVerificationAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2728,7 +2728,7 @@ const opGetSendQuota = "GetSendQuota" // GetSendQuotaRequest generates a "aws/request.Request" representing the // client's request for the GetSendQuota operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2804,7 +2804,7 @@ const opGetSendStatistics = "GetSendStatistics" // GetSendStatisticsRequest generates a "aws/request.Request" representing the // client's request for the GetSendStatistics operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2882,7 +2882,7 @@ const opGetTemplate = "GetTemplate" // GetTemplateRequest generates a "aws/request.Request" representing the // client's request for the GetTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2965,7 +2965,7 @@ const opListConfigurationSets = "ListConfigurationSets" // ListConfigurationSetsRequest generates a "aws/request.Request" representing the // client's request for the ListConfigurationSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3049,7 +3049,7 @@ const opListCustomVerificationEmailTemplates = "ListCustomVerificationEmailTempl // ListCustomVerificationEmailTemplatesRequest generates a "aws/request.Request" representing the // client's request for the ListCustomVerificationEmailTemplates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3185,7 +3185,7 @@ const opListIdentities = "ListIdentities" // ListIdentitiesRequest generates a "aws/request.Request" representing the // client's request for the ListIdentities operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3318,7 +3318,7 @@ const opListIdentityPolicies = "ListIdentityPolicies" // ListIdentityPoliciesRequest generates a "aws/request.Request" representing the // client's request for the ListIdentityPolicies operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3403,7 +3403,7 @@ const opListReceiptFilters = "ListReceiptFilters" // ListReceiptFiltersRequest generates a "aws/request.Request" representing the // client's request for the ListReceiptFilters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3482,7 +3482,7 @@ const opListReceiptRuleSets = "ListReceiptRuleSets" // ListReceiptRuleSetsRequest generates a "aws/request.Request" representing the // client's request for the ListReceiptRuleSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3564,7 +3564,7 @@ const opListTemplates = "ListTemplates" // ListTemplatesRequest generates a "aws/request.Request" representing the // client's request for the ListTemplates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3640,7 +3640,7 @@ const opListVerifiedEmailAddresses = "ListVerifiedEmailAddresses" // ListVerifiedEmailAddressesRequest generates a "aws/request.Request" representing the // client's request for the ListVerifiedEmailAddresses operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3715,7 +3715,7 @@ const opPutIdentityPolicy = "PutIdentityPolicy" // PutIdentityPolicyRequest generates a "aws/request.Request" representing the // client's request for the PutIdentityPolicy operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3805,7 +3805,7 @@ const opReorderReceiptRuleSet = "ReorderReceiptRuleSet" // ReorderReceiptRuleSetRequest generates a "aws/request.Request" representing the // client's request for the ReorderReceiptRuleSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3896,7 +3896,7 @@ const opSendBounce = "SendBounce" // SendBounceRequest generates a "aws/request.Request" representing the // client's request for the SendBounce operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3986,7 +3986,7 @@ const opSendBulkTemplatedEmail = "SendBulkTemplatedEmail" // SendBulkTemplatedEmailRequest generates a "aws/request.Request" representing the // client's request for the SendBulkTemplatedEmail operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4115,7 +4115,7 @@ const opSendCustomVerificationEmail = "SendCustomVerificationEmail" // SendCustomVerificationEmailRequest generates a "aws/request.Request" representing the // client's request for the SendCustomVerificationEmail operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4219,7 +4219,7 @@ const opSendEmail = "SendEmail" // SendEmailRequest generates a "aws/request.Request" representing the // client's request for the SendEmail operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4353,7 +4353,7 @@ const opSendRawEmail = "SendRawEmail" // SendRawEmailRequest generates a "aws/request.Request" representing the // client's request for the SendRawEmail operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4523,7 +4523,7 @@ const opSendTemplatedEmail = "SendTemplatedEmail" // SendTemplatedEmailRequest generates a "aws/request.Request" representing the // client's request for the SendTemplatedEmail operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4657,7 +4657,7 @@ const opSetActiveReceiptRuleSet = "SetActiveReceiptRuleSet" // SetActiveReceiptRuleSetRequest generates a "aws/request.Request" representing the // client's request for the SetActiveReceiptRuleSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4744,7 +4744,7 @@ const opSetIdentityDkimEnabled = "SetIdentityDkimEnabled" // SetIdentityDkimEnabledRequest generates a "aws/request.Request" representing the // client's request for the SetIdentityDkimEnabled operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4835,7 +4835,7 @@ const opSetIdentityFeedbackForwardingEnabled = "SetIdentityFeedbackForwardingEna // SetIdentityFeedbackForwardingEnabledRequest generates a "aws/request.Request" representing the // client's request for the SetIdentityFeedbackForwardingEnabled operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4920,7 +4920,7 @@ const opSetIdentityHeadersInNotificationsEnabled = "SetIdentityHeadersInNotifica // SetIdentityHeadersInNotificationsEnabledRequest generates a "aws/request.Request" representing the // client's request for the SetIdentityHeadersInNotificationsEnabled operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5001,7 +5001,7 @@ const opSetIdentityMailFromDomain = "SetIdentityMailFromDomain" // SetIdentityMailFromDomainRequest generates a "aws/request.Request" representing the // client's request for the SetIdentityMailFromDomain operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5083,7 +5083,7 @@ const opSetIdentityNotificationTopic = "SetIdentityNotificationTopic" // SetIdentityNotificationTopicRequest generates a "aws/request.Request" representing the // client's request for the SetIdentityNotificationTopic operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5168,7 +5168,7 @@ const opSetReceiptRulePosition = "SetReceiptRulePosition" // SetReceiptRulePositionRequest generates a "aws/request.Request" representing the // client's request for the SetReceiptRulePosition operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5255,7 +5255,7 @@ const opTestRenderTemplate = "TestRenderTemplate" // TestRenderTemplateRequest generates a "aws/request.Request" representing the // client's request for the TestRenderTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5347,7 +5347,7 @@ const opUpdateAccountSendingEnabled = "UpdateAccountSendingEnabled" // UpdateAccountSendingEnabledRequest generates a "aws/request.Request" representing the // client's request for the UpdateAccountSendingEnabled operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5428,7 +5428,7 @@ const opUpdateConfigurationSetEventDestination = "UpdateConfigurationSetEventDes // UpdateConfigurationSetEventDestinationRequest generates a "aws/request.Request" representing the // client's request for the UpdateConfigurationSetEventDestination operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5533,7 +5533,7 @@ const opUpdateConfigurationSetReputationMetricsEnabled = "UpdateConfigurationSet // UpdateConfigurationSetReputationMetricsEnabledRequest generates a "aws/request.Request" representing the // client's request for the UpdateConfigurationSetReputationMetricsEnabled operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5620,7 +5620,7 @@ const opUpdateConfigurationSetSendingEnabled = "UpdateConfigurationSetSendingEna // UpdateConfigurationSetSendingEnabledRequest generates a "aws/request.Request" representing the // client's request for the UpdateConfigurationSetSendingEnabled operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5707,7 +5707,7 @@ const opUpdateConfigurationSetTrackingOptions = "UpdateConfigurationSetTrackingO // UpdateConfigurationSetTrackingOptionsRequest generates a "aws/request.Request" representing the // client's request for the UpdateConfigurationSetTrackingOptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5804,7 +5804,7 @@ const opUpdateCustomVerificationEmailTemplate = "UpdateCustomVerificationEmailTe // UpdateCustomVerificationEmailTemplateRequest generates a "aws/request.Request" representing the // client's request for the UpdateCustomVerificationEmailTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5900,7 +5900,7 @@ const opUpdateReceiptRule = "UpdateReceiptRule" // UpdateReceiptRuleRequest generates a "aws/request.Request" representing the // client's request for the UpdateReceiptRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6008,7 +6008,7 @@ const opUpdateTemplate = "UpdateTemplate" // UpdateTemplateRequest generates a "aws/request.Request" representing the // client's request for the UpdateTemplate operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6096,7 +6096,7 @@ const opVerifyDomainDkim = "VerifyDomainDkim" // VerifyDomainDkimRequest generates a "aws/request.Request" representing the // client's request for the VerifyDomainDkim operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6184,7 +6184,7 @@ const opVerifyDomainIdentity = "VerifyDomainIdentity" // VerifyDomainIdentityRequest generates a "aws/request.Request" representing the // client's request for the VerifyDomainIdentity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6263,7 +6263,7 @@ const opVerifyEmailAddress = "VerifyEmailAddress" // VerifyEmailAddressRequest generates a "aws/request.Request" representing the // client's request for the VerifyEmailAddress operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6339,7 +6339,7 @@ const opVerifyEmailIdentity = "VerifyEmailIdentity" // VerifyEmailIdentityRequest generates a "aws/request.Request" representing the // client's request for the VerifyEmailIdentity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/ses/service.go b/vendor/github.com/aws/aws-sdk-go/service/ses/service.go index b078893079f3..b71b2322e116 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/ses/service.go +++ b/vendor/github.com/aws/aws-sdk-go/service/ses/service.go @@ -45,14 +45,14 @@ const ( // svc := ses.New(mySession, aws.NewConfig().WithRegion("us-west-2")) func New(p client.ConfigProvider, cfgs ...*aws.Config) *SES { c := p.ClientConfig(EndpointsID, cfgs...) + if c.SigningNameDerived || len(c.SigningName) == 0 { + c.SigningName = "ses" + } return newClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion, c.SigningName) } // newClient creates, initializes and returns a new service client instance. func newClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion, signingName string) *SES { - if len(signingName) == 0 { - signingName = "ses" - } svc := &SES{ Client: client.New( cfg, diff --git a/vendor/github.com/aws/aws-sdk-go/service/sfn/api.go b/vendor/github.com/aws/aws-sdk-go/service/sfn/api.go index f6119da2bdf2..2f6f75f4c32f 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/sfn/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/sfn/api.go @@ -14,7 +14,7 @@ const opCreateActivity = "CreateActivity" // CreateActivityRequest generates a "aws/request.Request" representing the // client's request for the CreateActivity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -102,7 +102,7 @@ const opCreateStateMachine = "CreateStateMachine" // CreateStateMachineRequest generates a "aws/request.Request" representing the // client's request for the CreateStateMachine operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -201,7 +201,7 @@ const opDeleteActivity = "DeleteActivity" // DeleteActivityRequest generates a "aws/request.Request" representing the // client's request for the DeleteActivity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -280,7 +280,7 @@ const opDeleteStateMachine = "DeleteStateMachine" // DeleteStateMachineRequest generates a "aws/request.Request" representing the // client's request for the DeleteStateMachine operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -364,7 +364,7 @@ const opDescribeActivity = "DescribeActivity" // DescribeActivityRequest generates a "aws/request.Request" representing the // client's request for the DescribeActivity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -446,7 +446,7 @@ const opDescribeExecution = "DescribeExecution" // DescribeExecutionRequest generates a "aws/request.Request" representing the // client's request for the DescribeExecution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -528,7 +528,7 @@ const opDescribeStateMachine = "DescribeStateMachine" // DescribeStateMachineRequest generates a "aws/request.Request" representing the // client's request for the DescribeStateMachine operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -610,7 +610,7 @@ const opDescribeStateMachineForExecution = "DescribeStateMachineForExecution" // DescribeStateMachineForExecutionRequest generates a "aws/request.Request" representing the // client's request for the DescribeStateMachineForExecution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -692,7 +692,7 @@ const opGetActivityTask = "GetActivityTask" // GetActivityTaskRequest generates a "aws/request.Request" representing the // client's request for the GetActivityTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -787,7 +787,7 @@ const opGetExecutionHistory = "GetExecutionHistory" // GetExecutionHistoryRequest generates a "aws/request.Request" representing the // client's request for the GetExecutionHistory operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -934,7 +934,7 @@ const opListActivities = "ListActivities" // ListActivitiesRequest generates a "aws/request.Request" representing the // client's request for the ListActivities operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1073,7 +1073,7 @@ const opListExecutions = "ListExecutions" // ListExecutionsRequest generates a "aws/request.Request" representing the // client's request for the ListExecutions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1218,7 +1218,7 @@ const opListStateMachines = "ListStateMachines" // ListStateMachinesRequest generates a "aws/request.Request" representing the // client's request for the ListStateMachines operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1357,7 +1357,7 @@ const opSendTaskFailure = "SendTaskFailure" // SendTaskFailureRequest generates a "aws/request.Request" representing the // client's request for the SendTaskFailure operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1440,7 +1440,7 @@ const opSendTaskHeartbeat = "SendTaskHeartbeat" // SendTaskHeartbeatRequest generates a "aws/request.Request" representing the // client's request for the SendTaskHeartbeat operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1535,7 +1535,7 @@ const opSendTaskSuccess = "SendTaskSuccess" // SendTaskSuccessRequest generates a "aws/request.Request" representing the // client's request for the SendTaskSuccess operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1622,7 +1622,7 @@ const opStartExecution = "StartExecution" // StartExecutionRequest generates a "aws/request.Request" representing the // client's request for the StartExecution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1722,7 +1722,7 @@ const opStopExecution = "StopExecution" // StopExecutionRequest generates a "aws/request.Request" representing the // client's request for the StopExecution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1804,7 +1804,7 @@ const opUpdateStateMachine = "UpdateStateMachine" // UpdateStateMachineRequest generates a "aws/request.Request" representing the // client's request for the UpdateStateMachine operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/simpledb/api.go b/vendor/github.com/aws/aws-sdk-go/service/simpledb/api.go index 24dc68744dcd..ea395b956e92 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/simpledb/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/simpledb/api.go @@ -16,7 +16,7 @@ const opBatchDeleteAttributes = "BatchDeleteAttributes" // BatchDeleteAttributesRequest generates a "aws/request.Request" representing the // client's request for the BatchDeleteAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -112,7 +112,7 @@ const opBatchPutAttributes = "BatchPutAttributes" // BatchPutAttributesRequest generates a "aws/request.Request" representing the // client's request for the BatchPutAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -256,7 +256,7 @@ const opCreateDomain = "CreateDomain" // CreateDomainRequest generates a "aws/request.Request" representing the // client's request for the CreateDomain operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -348,7 +348,7 @@ const opDeleteAttributes = "DeleteAttributes" // DeleteAttributesRequest generates a "aws/request.Request" representing the // client's request for the DeleteAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -445,7 +445,7 @@ const opDeleteDomain = "DeleteDomain" // DeleteDomainRequest generates a "aws/request.Request" representing the // client's request for the DeleteDomain operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -528,7 +528,7 @@ const opDomainMetadata = "DomainMetadata" // DomainMetadataRequest generates a "aws/request.Request" representing the // client's request for the DomainMetadata operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -609,7 +609,7 @@ const opGetAttributes = "GetAttributes" // GetAttributesRequest generates a "aws/request.Request" representing the // client's request for the GetAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -700,7 +700,7 @@ const opListDomains = "ListDomains" // ListDomainsRequest generates a "aws/request.Request" representing the // client's request for the ListDomains operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -840,7 +840,7 @@ const opPutAttributes = "PutAttributes" // PutAttributesRequest generates a "aws/request.Request" representing the // client's request for the PutAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -966,7 +966,7 @@ const opSelect = "Select" // SelectRequest generates a "aws/request.Request" representing the // client's request for the Select operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/sns/api.go b/vendor/github.com/aws/aws-sdk-go/service/sns/api.go index 8f658a430344..41ea5fcbc7f4 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/sns/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/sns/api.go @@ -16,7 +16,7 @@ const opAddPermission = "AddPermission" // AddPermissionRequest generates a "aws/request.Request" representing the // client's request for the AddPermission operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -107,7 +107,7 @@ const opCheckIfPhoneNumberIsOptedOut = "CheckIfPhoneNumberIsOptedOut" // CheckIfPhoneNumberIsOptedOutRequest generates a "aws/request.Request" representing the // client's request for the CheckIfPhoneNumberIsOptedOut operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -201,7 +201,7 @@ const opConfirmSubscription = "ConfirmSubscription" // ConfirmSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the ConfirmSubscription operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -296,7 +296,7 @@ const opCreatePlatformApplication = "CreatePlatformApplication" // CreatePlatformApplicationRequest generates a "aws/request.Request" representing the // client's request for the CreatePlatformApplication operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -406,7 +406,7 @@ const opCreatePlatformEndpoint = "CreatePlatformEndpoint" // CreatePlatformEndpointRequest generates a "aws/request.Request" representing the // client's request for the CreatePlatformEndpoint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -507,7 +507,7 @@ const opCreateTopic = "CreateTopic" // CreateTopicRequest generates a "aws/request.Request" representing the // client's request for the CreateTopic operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -599,7 +599,7 @@ const opDeleteEndpoint = "DeleteEndpoint" // DeleteEndpointRequest generates a "aws/request.Request" representing the // client's request for the DeleteEndpoint operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -691,7 +691,7 @@ const opDeletePlatformApplication = "DeletePlatformApplication" // DeletePlatformApplicationRequest generates a "aws/request.Request" representing the // client's request for the DeletePlatformApplication operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -780,7 +780,7 @@ const opDeleteTopic = "DeleteTopic" // DeleteTopicRequest generates a "aws/request.Request" representing the // client's request for the DeleteTopic operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -873,7 +873,7 @@ const opGetEndpointAttributes = "GetEndpointAttributes" // GetEndpointAttributesRequest generates a "aws/request.Request" representing the // client's request for the GetEndpointAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -963,7 +963,7 @@ const opGetPlatformApplicationAttributes = "GetPlatformApplicationAttributes" // GetPlatformApplicationAttributesRequest generates a "aws/request.Request" representing the // client's request for the GetPlatformApplicationAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1053,7 +1053,7 @@ const opGetSMSAttributes = "GetSMSAttributes" // GetSMSAttributesRequest generates a "aws/request.Request" representing the // client's request for the GetSMSAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1144,7 +1144,7 @@ const opGetSubscriptionAttributes = "GetSubscriptionAttributes" // GetSubscriptionAttributesRequest generates a "aws/request.Request" representing the // client's request for the GetSubscriptionAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1232,7 +1232,7 @@ const opGetTopicAttributes = "GetTopicAttributes" // GetTopicAttributesRequest generates a "aws/request.Request" representing the // client's request for the GetTopicAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1321,7 +1321,7 @@ const opListEndpointsByPlatformApplication = "ListEndpointsByPlatformApplication // ListEndpointsByPlatformApplicationRequest generates a "aws/request.Request" representing the // client's request for the ListEndpointsByPlatformApplication operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1472,7 +1472,7 @@ const opListPhoneNumbersOptedOut = "ListPhoneNumbersOptedOut" // ListPhoneNumbersOptedOutRequest generates a "aws/request.Request" representing the // client's request for the ListPhoneNumbersOptedOut operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1569,7 +1569,7 @@ const opListPlatformApplications = "ListPlatformApplications" // ListPlatformApplicationsRequest generates a "aws/request.Request" representing the // client's request for the ListPlatformApplications operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1717,7 +1717,7 @@ const opListSubscriptions = "ListSubscriptions" // ListSubscriptionsRequest generates a "aws/request.Request" representing the // client's request for the ListSubscriptions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1861,7 +1861,7 @@ const opListSubscriptionsByTopic = "ListSubscriptionsByTopic" // ListSubscriptionsByTopicRequest generates a "aws/request.Request" representing the // client's request for the ListSubscriptionsByTopic operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2008,7 +2008,7 @@ const opListTopics = "ListTopics" // ListTopicsRequest generates a "aws/request.Request" representing the // client's request for the ListTopics operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2151,7 +2151,7 @@ const opOptInPhoneNumber = "OptInPhoneNumber" // OptInPhoneNumberRequest generates a "aws/request.Request" representing the // client's request for the OptInPhoneNumber operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2243,7 +2243,7 @@ const opPublish = "Publish" // PublishRequest generates a "aws/request.Request" representing the // client's request for the Publish operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2351,7 +2351,7 @@ const opRemovePermission = "RemovePermission" // RemovePermissionRequest generates a "aws/request.Request" representing the // client's request for the RemovePermission operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2441,7 +2441,7 @@ const opSetEndpointAttributes = "SetEndpointAttributes" // SetEndpointAttributesRequest generates a "aws/request.Request" representing the // client's request for the SetEndpointAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2533,7 +2533,7 @@ const opSetPlatformApplicationAttributes = "SetPlatformApplicationAttributes" // SetPlatformApplicationAttributesRequest generates a "aws/request.Request" representing the // client's request for the SetPlatformApplicationAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2627,7 +2627,7 @@ const opSetSMSAttributes = "SetSMSAttributes" // SetSMSAttributesRequest generates a "aws/request.Request" representing the // client's request for the SetSMSAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2722,7 +2722,7 @@ const opSetSubscriptionAttributes = "SetSubscriptionAttributes" // SetSubscriptionAttributesRequest generates a "aws/request.Request" representing the // client's request for the SetSubscriptionAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2812,7 +2812,7 @@ const opSetTopicAttributes = "SetTopicAttributes" // SetTopicAttributesRequest generates a "aws/request.Request" representing the // client's request for the SetTopicAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2902,7 +2902,7 @@ const opSubscribe = "Subscribe" // SubscribeRequest generates a "aws/request.Request" representing the // client's request for the Subscribe operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2996,7 +2996,7 @@ const opUnsubscribe = "Unsubscribe" // UnsubscribeRequest generates a "aws/request.Request" representing the // client's request for the Unsubscribe operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/sqs/api.go b/vendor/github.com/aws/aws-sdk-go/service/sqs/api.go index c6997da87117..1b42a7dd6861 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/sqs/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/sqs/api.go @@ -16,7 +16,7 @@ const opAddPermission = "AddPermission" // AddPermissionRequest generates a "aws/request.Request" representing the // client's request for the AddPermission operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -119,7 +119,7 @@ const opChangeMessageVisibility = "ChangeMessageVisibility" // ChangeMessageVisibilityRequest generates a "aws/request.Request" representing the // client's request for the ChangeMessageVisibility operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -238,7 +238,7 @@ const opChangeMessageVisibilityBatch = "ChangeMessageVisibilityBatch" // ChangeMessageVisibilityBatchRequest generates a "aws/request.Request" representing the // client's request for the ChangeMessageVisibilityBatch operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -341,7 +341,7 @@ const opCreateQueue = "CreateQueue" // CreateQueueRequest generates a "aws/request.Request" representing the // client's request for the CreateQueue operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -465,7 +465,7 @@ const opDeleteMessage = "DeleteMessage" // DeleteMessageRequest generates a "aws/request.Request" representing the // client's request for the DeleteMessage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -568,7 +568,7 @@ const opDeleteMessageBatch = "DeleteMessageBatch" // DeleteMessageBatchRequest generates a "aws/request.Request" representing the // client's request for the DeleteMessageBatch operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -670,7 +670,7 @@ const opDeleteQueue = "DeleteQueue" // DeleteQueueRequest generates a "aws/request.Request" representing the // client's request for the DeleteQueue operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -758,7 +758,7 @@ const opGetQueueAttributes = "GetQueueAttributes" // GetQueueAttributesRequest generates a "aws/request.Request" representing the // client's request for the GetQueueAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -848,7 +848,7 @@ const opGetQueueUrl = "GetQueueUrl" // GetQueueUrlRequest generates a "aws/request.Request" representing the // client's request for the GetQueueUrl operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -934,7 +934,7 @@ const opListDeadLetterSourceQueues = "ListDeadLetterSourceQueues" // ListDeadLetterSourceQueuesRequest generates a "aws/request.Request" representing the // client's request for the ListDeadLetterSourceQueues operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1018,7 +1018,7 @@ const opListQueueTags = "ListQueueTags" // ListQueueTagsRequest generates a "aws/request.Request" representing the // client's request for the ListQueueTags operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1112,7 +1112,7 @@ const opListQueues = "ListQueues" // ListQueuesRequest generates a "aws/request.Request" representing the // client's request for the ListQueues operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1188,7 +1188,7 @@ const opPurgeQueue = "PurgeQueue" // PurgeQueueRequest generates a "aws/request.Request" representing the // client's request for the PurgeQueue operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1283,7 +1283,7 @@ const opReceiveMessage = "ReceiveMessage" // ReceiveMessageRequest generates a "aws/request.Request" representing the // client's request for the ReceiveMessage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1411,7 +1411,7 @@ const opRemovePermission = "RemovePermission" // RemovePermissionRequest generates a "aws/request.Request" representing the // client's request for the RemovePermission operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1488,7 +1488,7 @@ const opSendMessage = "SendMessage" // SendMessageRequest generates a "aws/request.Request" representing the // client's request for the SendMessage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1578,7 +1578,7 @@ const opSendMessageBatch = "SendMessageBatch" // SendMessageBatchRequest generates a "aws/request.Request" representing the // client's request for the SendMessageBatch operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1702,7 +1702,7 @@ const opSetQueueAttributes = "SetQueueAttributes" // SetQueueAttributesRequest generates a "aws/request.Request" representing the // client's request for the SetQueueAttributes operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1790,7 +1790,7 @@ const opTagQueue = "TagQueue" // TagQueueRequest generates a "aws/request.Request" representing the // client's request for the TagQueue operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1886,7 +1886,7 @@ const opUntagQueue = "UntagQueue" // UntagQueueRequest generates a "aws/request.Request" representing the // client's request for the UntagQueue operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/ssm/api.go b/vendor/github.com/aws/aws-sdk-go/service/ssm/api.go index 2d941d74f96e..a42c79cb5d50 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/ssm/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/ssm/api.go @@ -15,7 +15,7 @@ const opAddTagsToResource = "AddTagsToResource" // AddTagsToResourceRequest generates a "aws/request.Request" representing the // client's request for the AddTagsToResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -125,7 +125,7 @@ const opCancelCommand = "CancelCommand" // CancelCommandRequest generates a "aws/request.Request" representing the // client's request for the CancelCommand operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -225,7 +225,7 @@ const opCreateActivation = "CreateActivation" // CreateActivationRequest generates a "aws/request.Request" representing the // client's request for the CreateActivation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -308,7 +308,7 @@ const opCreateAssociation = "CreateAssociation" // CreateAssociationRequest generates a "aws/request.Request" representing the // client's request for the CreateAssociation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -441,7 +441,7 @@ const opCreateAssociationBatch = "CreateAssociationBatch" // CreateAssociationBatchRequest generates a "aws/request.Request" representing the // client's request for the CreateAssociationBatch operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -574,7 +574,7 @@ const opCreateDocument = "CreateDocument" // CreateDocumentRequest generates a "aws/request.Request" representing the // client's request for the CreateDocument operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -671,7 +671,7 @@ const opCreateMaintenanceWindow = "CreateMaintenanceWindow" // CreateMaintenanceWindowRequest generates a "aws/request.Request" representing the // client's request for the CreateMaintenanceWindow operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -761,7 +761,7 @@ const opCreatePatchBaseline = "CreatePatchBaseline" // CreatePatchBaselineRequest generates a "aws/request.Request" representing the // client's request for the CreatePatchBaseline operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -854,7 +854,7 @@ const opCreateResourceDataSync = "CreateResourceDataSync" // CreateResourceDataSyncRequest generates a "aws/request.Request" representing the // client's request for the CreateResourceDataSync operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -952,7 +952,7 @@ const opDeleteActivation = "DeleteActivation" // DeleteActivationRequest generates a "aws/request.Request" representing the // client's request for the DeleteActivation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1046,7 +1046,7 @@ const opDeleteAssociation = "DeleteAssociation" // DeleteAssociationRequest generates a "aws/request.Request" representing the // client's request for the DeleteAssociation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1155,7 +1155,7 @@ const opDeleteDocument = "DeleteDocument" // DeleteDocumentRequest generates a "aws/request.Request" representing the // client's request for the DeleteDocument operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1249,7 +1249,7 @@ const opDeleteMaintenanceWindow = "DeleteMaintenanceWindow" // DeleteMaintenanceWindowRequest generates a "aws/request.Request" representing the // client's request for the DeleteMaintenanceWindow operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1328,7 +1328,7 @@ const opDeleteParameter = "DeleteParameter" // DeleteParameterRequest generates a "aws/request.Request" representing the // client's request for the DeleteParameter operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1410,7 +1410,7 @@ const opDeleteParameters = "DeleteParameters" // DeleteParametersRequest generates a "aws/request.Request" representing the // client's request for the DeleteParameters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1490,7 +1490,7 @@ const opDeletePatchBaseline = "DeletePatchBaseline" // DeletePatchBaselineRequest generates a "aws/request.Request" representing the // client's request for the DeletePatchBaseline operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1573,7 +1573,7 @@ const opDeleteResourceDataSync = "DeleteResourceDataSync" // DeleteResourceDataSyncRequest generates a "aws/request.Request" representing the // client's request for the DeleteResourceDataSync operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1658,7 +1658,7 @@ const opDeregisterManagedInstance = "DeregisterManagedInstance" // DeregisterManagedInstanceRequest generates a "aws/request.Request" representing the // client's request for the DeregisterManagedInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1754,7 +1754,7 @@ const opDeregisterPatchBaselineForPatchGroup = "DeregisterPatchBaselineForPatchG // DeregisterPatchBaselineForPatchGroupRequest generates a "aws/request.Request" representing the // client's request for the DeregisterPatchBaselineForPatchGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1837,7 +1837,7 @@ const opDeregisterTargetFromMaintenanceWindow = "DeregisterTargetFromMaintenance // DeregisterTargetFromMaintenanceWindowRequest generates a "aws/request.Request" representing the // client's request for the DeregisterTargetFromMaintenanceWindow operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1927,7 +1927,7 @@ const opDeregisterTaskFromMaintenanceWindow = "DeregisterTaskFromMaintenanceWind // DeregisterTaskFromMaintenanceWindowRequest generates a "aws/request.Request" representing the // client's request for the DeregisterTaskFromMaintenanceWindow operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2013,7 +2013,7 @@ const opDescribeActivations = "DescribeActivations" // DescribeActivationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeActivations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2157,7 +2157,7 @@ const opDescribeAssociation = "DescribeAssociation" // DescribeAssociationRequest generates a "aws/request.Request" representing the // client's request for the DescribeAssociation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2266,7 +2266,7 @@ const opDescribeAutomationExecutions = "DescribeAutomationExecutions" // DescribeAutomationExecutionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeAutomationExecutions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2354,7 +2354,7 @@ const opDescribeAutomationStepExecutions = "DescribeAutomationStepExecutions" // DescribeAutomationStepExecutionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeAutomationStepExecutions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2447,7 +2447,7 @@ const opDescribeAvailablePatches = "DescribeAvailablePatches" // DescribeAvailablePatchesRequest generates a "aws/request.Request" representing the // client's request for the DescribeAvailablePatches operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2526,7 +2526,7 @@ const opDescribeDocument = "DescribeDocument" // DescribeDocumentRequest generates a "aws/request.Request" representing the // client's request for the DescribeDocument operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2611,7 +2611,7 @@ const opDescribeDocumentPermission = "DescribeDocumentPermission" // DescribeDocumentPermissionRequest generates a "aws/request.Request" representing the // client's request for the DescribeDocumentPermission operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2699,7 +2699,7 @@ const opDescribeEffectiveInstanceAssociations = "DescribeEffectiveInstanceAssoci // DescribeEffectiveInstanceAssociationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeEffectiveInstanceAssociations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2796,7 +2796,7 @@ const opDescribeEffectivePatchesForPatchBaseline = "DescribeEffectivePatchesForP // DescribeEffectivePatchesForPatchBaselineRequest generates a "aws/request.Request" representing the // client's request for the DescribeEffectivePatchesForPatchBaseline operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2893,7 +2893,7 @@ const opDescribeInstanceAssociationsStatus = "DescribeInstanceAssociationsStatus // DescribeInstanceAssociationsStatusRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstanceAssociationsStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2990,7 +2990,7 @@ const opDescribeInstanceInformation = "DescribeInstanceInformation" // DescribeInstanceInformationRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstanceInformation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3154,7 +3154,7 @@ const opDescribeInstancePatchStates = "DescribeInstancePatchStates" // DescribeInstancePatchStatesRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstancePatchStates operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3236,7 +3236,7 @@ const opDescribeInstancePatchStatesForPatchGroup = "DescribeInstancePatchStatesF // DescribeInstancePatchStatesForPatchGroupRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstancePatchStatesForPatchGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3323,7 +3323,7 @@ const opDescribeInstancePatches = "DescribeInstancePatches" // DescribeInstancePatchesRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstancePatches operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3425,7 +3425,7 @@ const opDescribeMaintenanceWindowExecutionTaskInvocations = "DescribeMaintenance // DescribeMaintenanceWindowExecutionTaskInvocationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeMaintenanceWindowExecutionTaskInvocations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3512,7 +3512,7 @@ const opDescribeMaintenanceWindowExecutionTasks = "DescribeMaintenanceWindowExec // DescribeMaintenanceWindowExecutionTasksRequest generates a "aws/request.Request" representing the // client's request for the DescribeMaintenanceWindowExecutionTasks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3598,7 +3598,7 @@ const opDescribeMaintenanceWindowExecutions = "DescribeMaintenanceWindowExecutio // DescribeMaintenanceWindowExecutionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeMaintenanceWindowExecutions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3679,7 +3679,7 @@ const opDescribeMaintenanceWindowTargets = "DescribeMaintenanceWindowTargets" // DescribeMaintenanceWindowTargetsRequest generates a "aws/request.Request" representing the // client's request for the DescribeMaintenanceWindowTargets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3765,7 +3765,7 @@ const opDescribeMaintenanceWindowTasks = "DescribeMaintenanceWindowTasks" // DescribeMaintenanceWindowTasksRequest generates a "aws/request.Request" representing the // client's request for the DescribeMaintenanceWindowTasks operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3851,7 +3851,7 @@ const opDescribeMaintenanceWindows = "DescribeMaintenanceWindows" // DescribeMaintenanceWindowsRequest generates a "aws/request.Request" representing the // client's request for the DescribeMaintenanceWindows operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3930,7 +3930,7 @@ const opDescribeParameters = "DescribeParameters" // DescribeParametersRequest generates a "aws/request.Request" representing the // client's request for the DescribeParameters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4086,7 +4086,7 @@ const opDescribePatchBaselines = "DescribePatchBaselines" // DescribePatchBaselinesRequest generates a "aws/request.Request" representing the // client's request for the DescribePatchBaselines operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4165,7 +4165,7 @@ const opDescribePatchGroupState = "DescribePatchGroupState" // DescribePatchGroupStateRequest generates a "aws/request.Request" representing the // client's request for the DescribePatchGroupState operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4247,7 +4247,7 @@ const opDescribePatchGroups = "DescribePatchGroups" // DescribePatchGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribePatchGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4326,7 +4326,7 @@ const opGetAutomationExecution = "GetAutomationExecution" // GetAutomationExecutionRequest generates a "aws/request.Request" representing the // client's request for the GetAutomationExecution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4409,7 +4409,7 @@ const opGetCommandInvocation = "GetCommandInvocation" // GetCommandInvocationRequest generates a "aws/request.Request" representing the // client's request for the GetCommandInvocation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4513,7 +4513,7 @@ const opGetDefaultPatchBaseline = "GetDefaultPatchBaseline" // GetDefaultPatchBaselineRequest generates a "aws/request.Request" representing the // client's request for the GetDefaultPatchBaseline operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4594,7 +4594,7 @@ const opGetDeployablePatchSnapshotForInstance = "GetDeployablePatchSnapshotForIn // GetDeployablePatchSnapshotForInstanceRequest generates a "aws/request.Request" representing the // client's request for the GetDeployablePatchSnapshotForInstance operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4679,7 +4679,7 @@ const opGetDocument = "GetDocument" // GetDocumentRequest generates a "aws/request.Request" representing the // client's request for the GetDocument operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4764,7 +4764,7 @@ const opGetInventory = "GetInventory" // GetInventoryRequest generates a "aws/request.Request" representing the // client's request for the GetInventory operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4856,7 +4856,7 @@ const opGetInventorySchema = "GetInventorySchema" // GetInventorySchemaRequest generates a "aws/request.Request" representing the // client's request for the GetInventorySchema operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4942,7 +4942,7 @@ const opGetMaintenanceWindow = "GetMaintenanceWindow" // GetMaintenanceWindowRequest generates a "aws/request.Request" representing the // client's request for the GetMaintenanceWindow operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5028,7 +5028,7 @@ const opGetMaintenanceWindowExecution = "GetMaintenanceWindowExecution" // GetMaintenanceWindowExecutionRequest generates a "aws/request.Request" representing the // client's request for the GetMaintenanceWindowExecution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5115,7 +5115,7 @@ const opGetMaintenanceWindowExecutionTask = "GetMaintenanceWindowExecutionTask" // GetMaintenanceWindowExecutionTaskRequest generates a "aws/request.Request" representing the // client's request for the GetMaintenanceWindowExecutionTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5202,7 +5202,7 @@ const opGetMaintenanceWindowExecutionTaskInvocation = "GetMaintenanceWindowExecu // GetMaintenanceWindowExecutionTaskInvocationRequest generates a "aws/request.Request" representing the // client's request for the GetMaintenanceWindowExecutionTaskInvocation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5289,7 +5289,7 @@ const opGetMaintenanceWindowTask = "GetMaintenanceWindowTask" // GetMaintenanceWindowTaskRequest generates a "aws/request.Request" representing the // client's request for the GetMaintenanceWindowTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5375,7 +5375,7 @@ const opGetParameter = "GetParameter" // GetParameterRequest generates a "aws/request.Request" representing the // client's request for the GetParameter operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5464,7 +5464,7 @@ const opGetParameterHistory = "GetParameterHistory" // GetParameterHistoryRequest generates a "aws/request.Request" representing the // client's request for the GetParameterHistory operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5608,7 +5608,7 @@ const opGetParameters = "GetParameters" // GetParametersRequest generates a "aws/request.Request" representing the // client's request for the GetParameters operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5690,7 +5690,7 @@ const opGetParametersByPath = "GetParametersByPath" // GetParametersByPathRequest generates a "aws/request.Request" representing the // client's request for the GetParametersByPath operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5852,7 +5852,7 @@ const opGetPatchBaseline = "GetPatchBaseline" // GetPatchBaselineRequest generates a "aws/request.Request" representing the // client's request for the GetPatchBaseline operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5942,7 +5942,7 @@ const opGetPatchBaselineForPatchGroup = "GetPatchBaselineForPatchGroup" // GetPatchBaselineForPatchGroupRequest generates a "aws/request.Request" representing the // client's request for the GetPatchBaselineForPatchGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6022,7 +6022,7 @@ const opListAssociationVersions = "ListAssociationVersions" // ListAssociationVersionsRequest generates a "aws/request.Request" representing the // client's request for the ListAssociationVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6107,7 +6107,7 @@ const opListAssociations = "ListAssociations" // ListAssociationsRequest generates a "aws/request.Request" representing the // client's request for the ListAssociations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6245,7 +6245,7 @@ const opListCommandInvocations = "ListCommandInvocations" // ListCommandInvocationsRequest generates a "aws/request.Request" representing the // client's request for the ListCommandInvocations operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6407,7 +6407,7 @@ const opListCommands = "ListCommands" // ListCommandsRequest generates a "aws/request.Request" representing the // client's request for the ListCommands operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6565,7 +6565,7 @@ const opListComplianceItems = "ListComplianceItems" // ListComplianceItemsRequest generates a "aws/request.Request" representing the // client's request for the ListComplianceItems operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6662,7 +6662,7 @@ const opListComplianceSummaries = "ListComplianceSummaries" // ListComplianceSummariesRequest generates a "aws/request.Request" representing the // client's request for the ListComplianceSummaries operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6750,7 +6750,7 @@ const opListDocumentVersions = "ListDocumentVersions" // ListDocumentVersionsRequest generates a "aws/request.Request" representing the // client's request for the ListDocumentVersions operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6835,7 +6835,7 @@ const opListDocuments = "ListDocuments" // ListDocumentsRequest generates a "aws/request.Request" representing the // client's request for the ListDocuments operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6976,7 +6976,7 @@ const opListInventoryEntries = "ListInventoryEntries" // ListInventoryEntriesRequest generates a "aws/request.Request" representing the // client's request for the ListInventoryEntries operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7080,7 +7080,7 @@ const opListResourceComplianceSummaries = "ListResourceComplianceSummaries" // ListResourceComplianceSummariesRequest generates a "aws/request.Request" representing the // client's request for the ListResourceComplianceSummaries operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7168,7 +7168,7 @@ const opListResourceDataSync = "ListResourceDataSync" // ListResourceDataSyncRequest generates a "aws/request.Request" representing the // client's request for the ListResourceDataSync operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7259,7 +7259,7 @@ const opListTagsForResource = "ListTagsForResource" // ListTagsForResourceRequest generates a "aws/request.Request" representing the // client's request for the ListTagsForResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7346,7 +7346,7 @@ const opModifyDocumentPermission = "ModifyDocumentPermission" // ModifyDocumentPermissionRequest generates a "aws/request.Request" representing the // client's request for the ModifyDocumentPermission operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7443,7 +7443,7 @@ const opPutComplianceItems = "PutComplianceItems" // PutComplianceItemsRequest generates a "aws/request.Request" representing the // client's request for the PutComplianceItems operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7584,7 +7584,7 @@ const opPutInventory = "PutInventory" // PutInventoryRequest generates a "aws/request.Request" representing the // client's request for the PutInventory operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7716,7 +7716,7 @@ const opPutParameter = "PutParameter" // PutParameterRequest generates a "aws/request.Request" representing the // client's request for the PutParameter operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7830,7 +7830,7 @@ const opRegisterDefaultPatchBaseline = "RegisterDefaultPatchBaseline" // RegisterDefaultPatchBaselineRequest generates a "aws/request.Request" representing the // client's request for the RegisterDefaultPatchBaseline operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7920,7 +7920,7 @@ const opRegisterPatchBaselineForPatchGroup = "RegisterPatchBaselineForPatchGroup // RegisterPatchBaselineForPatchGroupRequest generates a "aws/request.Request" representing the // client's request for the RegisterPatchBaselineForPatchGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8021,7 +8021,7 @@ const opRegisterTargetWithMaintenanceWindow = "RegisterTargetWithMaintenanceWind // RegisterTargetWithMaintenanceWindowRequest generates a "aws/request.Request" representing the // client's request for the RegisterTargetWithMaintenanceWindow operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8118,7 +8118,7 @@ const opRegisterTaskWithMaintenanceWindow = "RegisterTaskWithMaintenanceWindow" // RegisterTaskWithMaintenanceWindowRequest generates a "aws/request.Request" representing the // client's request for the RegisterTaskWithMaintenanceWindow operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8219,7 +8219,7 @@ const opRemoveTagsFromResource = "RemoveTagsFromResource" // RemoveTagsFromResourceRequest generates a "aws/request.Request" representing the // client's request for the RemoveTagsFromResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8306,7 +8306,7 @@ const opSendAutomationSignal = "SendAutomationSignal" // SendAutomationSignalRequest generates a "aws/request.Request" representing the // client's request for the SendAutomationSignal operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8397,7 +8397,7 @@ const opSendCommand = "SendCommand" // SendCommandRequest generates a "aws/request.Request" representing the // client's request for the SendCommand operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8523,7 +8523,7 @@ const opStartAutomationExecution = "StartAutomationExecution" // StartAutomationExecutionRequest generates a "aws/request.Request" representing the // client's request for the StartAutomationExecution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8625,7 +8625,7 @@ const opStopAutomationExecution = "StopAutomationExecution" // StopAutomationExecutionRequest generates a "aws/request.Request" representing the // client's request for the StopAutomationExecution operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8711,7 +8711,7 @@ const opUpdateAssociation = "UpdateAssociation" // UpdateAssociationRequest generates a "aws/request.Request" representing the // client's request for the UpdateAssociation operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8831,7 +8831,7 @@ const opUpdateAssociationStatus = "UpdateAssociationStatus" // UpdateAssociationStatusRequest generates a "aws/request.Request" representing the // client's request for the UpdateAssociationStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8939,7 +8939,7 @@ const opUpdateDocument = "UpdateDocument" // UpdateDocumentRequest generates a "aws/request.Request" representing the // client's request for the UpdateDocument operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9041,7 +9041,7 @@ const opUpdateDocumentDefaultVersion = "UpdateDocumentDefaultVersion" // UpdateDocumentDefaultVersionRequest generates a "aws/request.Request" representing the // client's request for the UpdateDocumentDefaultVersion operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9129,7 +9129,7 @@ const opUpdateMaintenanceWindow = "UpdateMaintenanceWindow" // UpdateMaintenanceWindowRequest generates a "aws/request.Request" representing the // client's request for the UpdateMaintenanceWindow operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9215,7 +9215,7 @@ const opUpdateMaintenanceWindowTarget = "UpdateMaintenanceWindowTarget" // UpdateMaintenanceWindowTargetRequest generates a "aws/request.Request" representing the // client's request for the UpdateMaintenanceWindowTarget operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9317,7 +9317,7 @@ const opUpdateMaintenanceWindowTask = "UpdateMaintenanceWindowTask" // UpdateMaintenanceWindowTaskRequest generates a "aws/request.Request" representing the // client's request for the UpdateMaintenanceWindowTask operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9422,7 +9422,7 @@ const opUpdateManagedInstanceRole = "UpdateManagedInstanceRole" // UpdateManagedInstanceRoleRequest generates a "aws/request.Request" representing the // client's request for the UpdateManagedInstanceRole operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -9517,7 +9517,7 @@ const opUpdatePatchBaseline = "UpdatePatchBaseline" // UpdatePatchBaselineRequest generates a "aws/request.Request" representing the // client's request for the UpdatePatchBaseline operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -10937,9 +10937,9 @@ type Command struct { // The maximum number of errors allowed before the system stops sending the // command to additional targets. You can specify a number of errors, such as - // 10, or a percentage or errors, such as 10%. The default value is 50. For - // more information about how to use MaxErrors, see Executing a Command Using - // Systems Manager Run Command (http://docs.aws.amazon.com/systems-manager/latest/userguide/run-command.html). + // 10, or a percentage or errors, such as 10%. The default value is 0. For more + // information about how to use MaxErrors, see Executing a Command Using Systems + // Manager Run Command (http://docs.aws.amazon.com/systems-manager/latest/userguide/run-command.html). MaxErrors *string `min:"1" type:"string"` // Configurations for sending notifications about command status changes. @@ -19783,6 +19783,9 @@ type InstanceInformation struct { InstanceId *string `type:"string"` // Indicates whether latest version of the SSM Agent is running on your instance. + // Some older versions of Windows Server use the EC2Config service to process + // SSM requests. For this reason, this field does not indicate whether or not + // the latest version is installed on Windows managed instances. IsLatestVersion *bool `type:"boolean"` // The date the association was last executed. @@ -25827,6 +25830,9 @@ type ResourceDataSyncItem struct { // The last time the sync operations returned a status of SUCCESSFUL (UTC). LastSuccessfulSyncTime *time.Time `type:"timestamp" timestampFormat:"unix"` + // The status message details reported by the last sync. + LastSyncStatusMessage *string `type:"string"` + // The last time the configuration attempted to sync (UTC). LastSyncTime *time.Time `type:"timestamp" timestampFormat:"unix"` @@ -25862,6 +25868,12 @@ func (s *ResourceDataSyncItem) SetLastSuccessfulSyncTime(v time.Time) *ResourceD return s } +// SetLastSyncStatusMessage sets the LastSyncStatusMessage field's value. +func (s *ResourceDataSyncItem) SetLastSyncStatusMessage(v string) *ResourceDataSyncItem { + s.LastSyncStatusMessage = &v + return s +} + // SetLastSyncTime sets the LastSyncTime field's value. func (s *ResourceDataSyncItem) SetLastSyncTime(v time.Time) *ResourceDataSyncItem { s.LastSyncTime = &v @@ -26236,7 +26248,7 @@ type SendCommandInput struct { // The maximum number of errors allowed without the command failing. When the // command fails one more time beyond the value of MaxErrors, the systems stops // sending the command to additional targets. You can specify a number like - // 10 or a percentage like 10%. The default value is 50. For more information + // 10 or a percentage like 10%. The default value is 0. For more information // about how to use MaxErrors, see Using Error Controls (http://docs.aws.amazon.com/systems-manager/latest/userguide/send-commands-maxerrors.html). MaxErrors *string `min:"1" type:"string"` @@ -29116,6 +29128,9 @@ const ( // OperatingSystemSuse is a OperatingSystem enum value OperatingSystemSuse = "SUSE" + + // OperatingSystemCentos is a OperatingSystem enum value + OperatingSystemCentos = "CENTOS" ) const ( diff --git a/vendor/github.com/aws/aws-sdk-go/service/sts/api.go b/vendor/github.com/aws/aws-sdk-go/service/sts/api.go index 22a0a12856fe..b46da12ca3de 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/sts/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/sts/api.go @@ -14,7 +14,7 @@ const opAssumeRole = "AssumeRole" // AssumeRoleRequest generates a "aws/request.Request" representing the // client's request for the AssumeRole operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -88,9 +88,18 @@ func (c *STS) AssumeRoleRequest(input *AssumeRoleInput) (req *request.Request, o // Scenarios for Temporary Credentials (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp.html#sts-introduction) // in the IAM User Guide. // -// The temporary security credentials are valid for the duration that you specified -// when calling AssumeRole, which can be from 900 seconds (15 minutes) to a -// maximum of 3600 seconds (1 hour). The default is 1 hour. +// By default, the temporary security credentials created by AssumeRole last +// for one hour. However, you can use the optional DurationSeconds parameter +// to specify the duration of your session. You can provide a value from 900 +// seconds (15 minutes) up to the maximum session duration setting for the role. +// This setting can have a value from 1 hour to 12 hours. To learn how to view +// the maximum value for your role, see View the Maximum Session Duration Setting +// for a Role (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) +// in the IAM User Guide. The maximum session duration limit applies when you +// use the AssumeRole* API operations or the assume-role* CLI operations but +// does not apply when you use those operations to create a console URL. For +// more information, see Using IAM Roles (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html) +// in the IAM User Guide. // // The temporary security credentials created by AssumeRole can be used to make // API calls to any AWS service with the following exception: you cannot call @@ -121,7 +130,12 @@ func (c *STS) AssumeRoleRequest(input *AssumeRoleInput) (req *request.Request, o // the user to call AssumeRole on the ARN of the role in the other account. // If the user is in the same account as the role, then you can either attach // a policy to the user (identical to the previous different account user), -// or you can add the user as a principal directly in the role's trust policy +// or you can add the user as a principal directly in the role's trust policy. +// In this case, the trust policy acts as the only resource-based policy in +// IAM, and users in the same account as the role do not need explicit permission +// to assume the role. For more information about trust policies and resource-based +// policies, see IAM Policies (http://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html) +// in the IAM User Guide. // // Using MFA with AssumeRole // @@ -194,7 +208,7 @@ const opAssumeRoleWithSAML = "AssumeRoleWithSAML" // AssumeRoleWithSAMLRequest generates a "aws/request.Request" representing the // client's request for the AssumeRoleWithSAML operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -247,11 +261,20 @@ func (c *STS) AssumeRoleWithSAMLRequest(input *AssumeRoleWithSAMLInput) (req *re // an access key ID, a secret access key, and a security token. Applications // can use these temporary security credentials to sign calls to AWS services. // -// The temporary security credentials are valid for the duration that you specified -// when calling AssumeRole, or until the time specified in the SAML authentication -// response's SessionNotOnOrAfter value, whichever is shorter. The duration -// can be from 900 seconds (15 minutes) to a maximum of 3600 seconds (1 hour). -// The default is 1 hour. +// By default, the temporary security credentials created by AssumeRoleWithSAML +// last for one hour. However, you can use the optional DurationSeconds parameter +// to specify the duration of your session. Your role session lasts for the +// duration that you specify, or until the time specified in the SAML authentication +// response's SessionNotOnOrAfter value, whichever is shorter. You can provide +// a DurationSeconds value from 900 seconds (15 minutes) up to the maximum session +// duration setting for the role. This setting can have a value from 1 hour +// to 12 hours. To learn how to view the maximum value for your role, see View +// the Maximum Session Duration Setting for a Role (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) +// in the IAM User Guide. The maximum session duration limit applies when you +// use the AssumeRole* API operations or the assume-role* CLI operations but +// does not apply when you use those operations to create a console URL. For +// more information, see Using IAM Roles (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html) +// in the IAM User Guide. // // The temporary security credentials created by AssumeRoleWithSAML can be used // to make API calls to any AWS service with the following exception: you cannot @@ -367,7 +390,7 @@ const opAssumeRoleWithWebIdentity = "AssumeRoleWithWebIdentity" // AssumeRoleWithWebIdentityRequest generates a "aws/request.Request" representing the // client's request for the AssumeRoleWithWebIdentity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -438,9 +461,18 @@ func (c *STS) AssumeRoleWithWebIdentityRequest(input *AssumeRoleWithWebIdentityI // key ID, a secret access key, and a security token. Applications can use these // temporary security credentials to sign calls to AWS service APIs. // -// The credentials are valid for the duration that you specified when calling -// AssumeRoleWithWebIdentity, which can be from 900 seconds (15 minutes) to -// a maximum of 3600 seconds (1 hour). The default is 1 hour. +// By default, the temporary security credentials created by AssumeRoleWithWebIdentity +// last for one hour. However, you can use the optional DurationSeconds parameter +// to specify the duration of your session. You can provide a value from 900 +// seconds (15 minutes) up to the maximum session duration setting for the role. +// This setting can have a value from 1 hour to 12 hours. To learn how to view +// the maximum value for your role, see View the Maximum Session Duration Setting +// for a Role (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) +// in the IAM User Guide. The maximum session duration limit applies when you +// use the AssumeRole* API operations or the assume-role* CLI operations but +// does not apply when you use those operations to create a console URL. For +// more information, see Using IAM Roles (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html) +// in the IAM User Guide. // // The temporary security credentials created by AssumeRoleWithWebIdentity can // be used to make API calls to any AWS service with the following exception: @@ -492,7 +524,7 @@ func (c *STS) AssumeRoleWithWebIdentityRequest(input *AssumeRoleWithWebIdentityI // the information from these providers to get and use temporary security // credentials. // -// * Web Identity Federation with Mobile Applications (http://aws.amazon.com/articles/4617974389850313). +// * Web Identity Federation with Mobile Applications (http://aws.amazon.com/articles/web-identity-federation-with-mobile-applications). // This article discusses web identity federation and shows an example of // how to use web identity federation to get access to content in Amazon // S3. @@ -569,7 +601,7 @@ const opDecodeAuthorizationMessage = "DecodeAuthorizationMessage" // DecodeAuthorizationMessageRequest generates a "aws/request.Request" representing the // client's request for the DecodeAuthorizationMessage operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -681,7 +713,7 @@ const opGetCallerIdentity = "GetCallerIdentity" // GetCallerIdentityRequest generates a "aws/request.Request" representing the // client's request for the GetCallerIdentity operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -756,7 +788,7 @@ const opGetFederationToken = "GetFederationToken" // GetFederationTokenRequest generates a "aws/request.Request" representing the // client's request for the GetFederationToken operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -925,7 +957,7 @@ const opGetSessionToken = "GetSessionToken" // GetSessionTokenRequest generates a "aws/request.Request" representing the // client's request for the GetSessionToken operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1053,15 +1085,23 @@ type AssumeRoleInput struct { _ struct{} `type:"structure"` // The duration, in seconds, of the role session. The value can range from 900 - // seconds (15 minutes) to 3600 seconds (1 hour). By default, the value is set - // to 3600 seconds. + // seconds (15 minutes) up to the maximum session duration setting for the role. + // This setting can have a value from 1 hour to 12 hours. If you specify a value + // higher than this setting, the operation fails. For example, if you specify + // a session duration of 12 hours, but your administrator set the maximum session + // duration to 6 hours, your operation fails. To learn how to view the maximum + // value for your role, see View the Maximum Session Duration Setting for a + // Role (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) + // in the IAM User Guide. + // + // By default, the value is set to 3600 seconds. // - // This is separate from the duration of a console session that you might request - // using the returned credentials. The request to the federation endpoint for - // a console sign-in token takes a SessionDuration parameter that specifies - // the maximum length of the console session, separately from the DurationSeconds - // parameter on this API. For more information, see Creating a URL that Enables - // Federated Users to Access the AWS Management Console (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html) + // The DurationSeconds parameter is separate from the duration of a console + // session that you might request using the returned credentials. The request + // to the federation endpoint for a console sign-in token takes a SessionDuration + // parameter that specifies the maximum length of the console session. For more + // information, see Creating a URL that Enables Federated Users to Access the + // AWS Management Console (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html) // in the IAM User Guide. DurationSeconds *int64 `min:"900" type:"integer"` @@ -1296,18 +1336,27 @@ func (s *AssumeRoleOutput) SetPackedPolicySize(v int64) *AssumeRoleOutput { type AssumeRoleWithSAMLInput struct { _ struct{} `type:"structure"` - // The duration, in seconds, of the role session. The value can range from 900 - // seconds (15 minutes) to 3600 seconds (1 hour). By default, the value is set - // to 3600 seconds. An expiration can also be specified in the SAML authentication - // response's SessionNotOnOrAfter value. The actual expiration time is whichever - // value is shorter. + // The duration, in seconds, of the role session. Your role session lasts for + // the duration that you specify for the DurationSeconds parameter, or until + // the time specified in the SAML authentication response's SessionNotOnOrAfter + // value, whichever is shorter. You can provide a DurationSeconds value from + // 900 seconds (15 minutes) up to the maximum session duration setting for the + // role. This setting can have a value from 1 hour to 12 hours. If you specify + // a value higher than this setting, the operation fails. For example, if you + // specify a session duration of 12 hours, but your administrator set the maximum + // session duration to 6 hours, your operation fails. To learn how to view the + // maximum value for your role, see View the Maximum Session Duration Setting + // for a Role (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) + // in the IAM User Guide. + // + // By default, the value is set to 3600 seconds. // - // This is separate from the duration of a console session that you might request - // using the returned credentials. The request to the federation endpoint for - // a console sign-in token takes a SessionDuration parameter that specifies - // the maximum length of the console session, separately from the DurationSeconds - // parameter on this API. For more information, see Enabling SAML 2.0 Federated - // Users to Access the AWS Management Console (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-saml.html) + // The DurationSeconds parameter is separate from the duration of a console + // session that you might request using the returned credentials. The request + // to the federation endpoint for a console sign-in token takes a SessionDuration + // parameter that specifies the maximum length of the console session. For more + // information, see Creating a URL that Enables Federated Users to Access the + // AWS Management Console (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html) // in the IAM User Guide. DurationSeconds *int64 `min:"900" type:"integer"` @@ -1548,15 +1597,23 @@ type AssumeRoleWithWebIdentityInput struct { _ struct{} `type:"structure"` // The duration, in seconds, of the role session. The value can range from 900 - // seconds (15 minutes) to 3600 seconds (1 hour). By default, the value is set - // to 3600 seconds. + // seconds (15 minutes) up to the maximum session duration setting for the role. + // This setting can have a value from 1 hour to 12 hours. If you specify a value + // higher than this setting, the operation fails. For example, if you specify + // a session duration of 12 hours, but your administrator set the maximum session + // duration to 6 hours, your operation fails. To learn how to view the maximum + // value for your role, see View the Maximum Session Duration Setting for a + // Role (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) + // in the IAM User Guide. + // + // By default, the value is set to 3600 seconds. // - // This is separate from the duration of a console session that you might request - // using the returned credentials. The request to the federation endpoint for - // a console sign-in token takes a SessionDuration parameter that specifies - // the maximum length of the console session, separately from the DurationSeconds - // parameter on this API. For more information, see Creating a URL that Enables - // Federated Users to Access the AWS Management Console (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html) + // The DurationSeconds parameter is separate from the duration of a console + // session that you might request using the returned credentials. The request + // to the federation endpoint for a console sign-in token takes a SessionDuration + // parameter that specifies the maximum length of the console session. For more + // information, see Creating a URL that Enables Federated Users to Access the + // AWS Management Console (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html) // in the IAM User Guide. DurationSeconds *int64 `min:"900" type:"integer"` diff --git a/vendor/github.com/aws/aws-sdk-go/service/waf/api.go b/vendor/github.com/aws/aws-sdk-go/service/waf/api.go index a95132d8de06..3fd63c681058 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/waf/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/waf/api.go @@ -15,7 +15,7 @@ const opCreateByteMatchSet = "CreateByteMatchSet" // CreateByteMatchSetRequest generates a "aws/request.Request" representing the // client's request for the CreateByteMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -162,7 +162,7 @@ const opCreateGeoMatchSet = "CreateGeoMatchSet" // CreateGeoMatchSetRequest generates a "aws/request.Request" representing the // client's request for the CreateGeoMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -308,7 +308,7 @@ const opCreateIPSet = "CreateIPSet" // CreateIPSetRequest generates a "aws/request.Request" representing the // client's request for the CreateIPSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -455,7 +455,7 @@ const opCreateRateBasedRule = "CreateRateBasedRule" // CreateRateBasedRuleRequest generates a "aws/request.Request" representing the // client's request for the CreateRateBasedRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -637,7 +637,7 @@ const opCreateRegexMatchSet = "CreateRegexMatchSet" // CreateRegexMatchSetRequest generates a "aws/request.Request" representing the // client's request for the CreateRegexMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -752,7 +752,7 @@ const opCreateRegexPatternSet = "CreateRegexPatternSet" // CreateRegexPatternSetRequest generates a "aws/request.Request" representing the // client's request for the CreateRegexPatternSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -863,7 +863,7 @@ const opCreateRule = "CreateRule" // CreateRuleRequest generates a "aws/request.Request" representing the // client's request for the CreateRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1020,7 +1020,7 @@ const opCreateRuleGroup = "CreateRuleGroup" // CreateRuleGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateRuleGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1126,7 +1126,7 @@ const opCreateSizeConstraintSet = "CreateSizeConstraintSet" // CreateSizeConstraintSetRequest generates a "aws/request.Request" representing the // client's request for the CreateSizeConstraintSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1274,7 +1274,7 @@ const opCreateSqlInjectionMatchSet = "CreateSqlInjectionMatchSet" // CreateSqlInjectionMatchSetRequest generates a "aws/request.Request" representing the // client's request for the CreateSqlInjectionMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1418,7 +1418,7 @@ const opCreateWebACL = "CreateWebACL" // CreateWebACLRequest generates a "aws/request.Request" representing the // client's request for the CreateWebACL operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1574,7 +1574,7 @@ const opCreateXssMatchSet = "CreateXssMatchSet" // CreateXssMatchSetRequest generates a "aws/request.Request" representing the // client's request for the CreateXssMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1719,7 +1719,7 @@ const opDeleteByteMatchSet = "DeleteByteMatchSet" // DeleteByteMatchSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteByteMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1846,7 +1846,7 @@ const opDeleteGeoMatchSet = "DeleteGeoMatchSet" // DeleteGeoMatchSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteGeoMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1972,7 +1972,7 @@ const opDeleteIPSet = "DeleteIPSet" // DeleteIPSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteIPSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2094,11 +2094,100 @@ func (c *WAF) DeleteIPSetWithContext(ctx aws.Context, input *DeleteIPSetInput, o return out, req.Send() } +const opDeletePermissionPolicy = "DeletePermissionPolicy" + +// DeletePermissionPolicyRequest generates a "aws/request.Request" representing the +// client's request for the DeletePermissionPolicy operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeletePermissionPolicy for more information on using the DeletePermissionPolicy +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeletePermissionPolicyRequest method. +// req, resp := client.DeletePermissionPolicyRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/waf-2015-08-24/DeletePermissionPolicy +func (c *WAF) DeletePermissionPolicyRequest(input *DeletePermissionPolicyInput) (req *request.Request, output *DeletePermissionPolicyOutput) { + op := &request.Operation{ + Name: opDeletePermissionPolicy, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &DeletePermissionPolicyInput{} + } + + output = &DeletePermissionPolicyOutput{} + req = c.newRequest(op, input, output) + return +} + +// DeletePermissionPolicy API operation for AWS WAF. +// +// Permanently deletes an IAM policy from the specified RuleGroup. +// +// The user making the request must be the owner of the RuleGroup. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS WAF's +// API operation DeletePermissionPolicy for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInternalErrorException "InternalErrorException" +// The operation failed because of a system problem, even though the request +// was valid. Retry your request. +// +// * ErrCodeStaleDataException "StaleDataException" +// The operation failed because you tried to create, update, or delete an object +// by using a change token that has already been used. +// +// * ErrCodeNonexistentItemException "NonexistentItemException" +// The operation failed because the referenced object doesn't exist. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/waf-2015-08-24/DeletePermissionPolicy +func (c *WAF) DeletePermissionPolicy(input *DeletePermissionPolicyInput) (*DeletePermissionPolicyOutput, error) { + req, out := c.DeletePermissionPolicyRequest(input) + return out, req.Send() +} + +// DeletePermissionPolicyWithContext is the same as DeletePermissionPolicy with the addition of +// the ability to pass a context and additional request options. +// +// See DeletePermissionPolicy for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *WAF) DeletePermissionPolicyWithContext(ctx aws.Context, input *DeletePermissionPolicyInput, opts ...request.Option) (*DeletePermissionPolicyOutput, error) { + req, out := c.DeletePermissionPolicyRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opDeleteRateBasedRule = "DeleteRateBasedRule" // DeleteRateBasedRuleRequest generates a "aws/request.Request" representing the // client's request for the DeleteRateBasedRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2226,7 +2315,7 @@ const opDeleteRegexMatchSet = "DeleteRegexMatchSet" // DeleteRegexMatchSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteRegexMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2353,7 +2442,7 @@ const opDeleteRegexPatternSet = "DeleteRegexPatternSet" // DeleteRegexPatternSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteRegexPatternSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2468,7 +2557,7 @@ const opDeleteRule = "DeleteRule" // DeleteRuleRequest generates a "aws/request.Request" representing the // client's request for the DeleteRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2594,7 +2683,7 @@ const opDeleteRuleGroup = "DeleteRuleGroup" // DeleteRuleGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteRuleGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2715,7 +2804,7 @@ const opDeleteSizeConstraintSet = "DeleteSizeConstraintSet" // DeleteSizeConstraintSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteSizeConstraintSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2842,7 +2931,7 @@ const opDeleteSqlInjectionMatchSet = "DeleteSqlInjectionMatchSet" // DeleteSqlInjectionMatchSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteSqlInjectionMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2970,7 +3059,7 @@ const opDeleteWebACL = "DeleteWebACL" // DeleteWebACLRequest generates a "aws/request.Request" representing the // client's request for the DeleteWebACL operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3093,7 +3182,7 @@ const opDeleteXssMatchSet = "DeleteXssMatchSet" // DeleteXssMatchSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteXssMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3220,7 +3309,7 @@ const opGetByteMatchSet = "GetByteMatchSet" // GetByteMatchSetRequest generates a "aws/request.Request" representing the // client's request for the GetByteMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3307,7 +3396,7 @@ const opGetChangeToken = "GetChangeToken" // GetChangeTokenRequest generates a "aws/request.Request" representing the // client's request for the GetChangeToken operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3401,7 +3490,7 @@ const opGetChangeTokenStatus = "GetChangeTokenStatus" // GetChangeTokenStatusRequest generates a "aws/request.Request" representing the // client's request for the GetChangeTokenStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3494,7 +3583,7 @@ const opGetGeoMatchSet = "GetGeoMatchSet" // GetGeoMatchSetRequest generates a "aws/request.Request" representing the // client's request for the GetGeoMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3581,7 +3670,7 @@ const opGetIPSet = "GetIPSet" // GetIPSetRequest generates a "aws/request.Request" representing the // client's request for the GetIPSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3664,11 +3753,94 @@ func (c *WAF) GetIPSetWithContext(ctx aws.Context, input *GetIPSetInput, opts .. return out, req.Send() } +const opGetPermissionPolicy = "GetPermissionPolicy" + +// GetPermissionPolicyRequest generates a "aws/request.Request" representing the +// client's request for the GetPermissionPolicy operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetPermissionPolicy for more information on using the GetPermissionPolicy +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetPermissionPolicyRequest method. +// req, resp := client.GetPermissionPolicyRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/waf-2015-08-24/GetPermissionPolicy +func (c *WAF) GetPermissionPolicyRequest(input *GetPermissionPolicyInput) (req *request.Request, output *GetPermissionPolicyOutput) { + op := &request.Operation{ + Name: opGetPermissionPolicy, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &GetPermissionPolicyInput{} + } + + output = &GetPermissionPolicyOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetPermissionPolicy API operation for AWS WAF. +// +// Returns the IAM policy attached to the RuleGroup. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS WAF's +// API operation GetPermissionPolicy for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInternalErrorException "InternalErrorException" +// The operation failed because of a system problem, even though the request +// was valid. Retry your request. +// +// * ErrCodeNonexistentItemException "NonexistentItemException" +// The operation failed because the referenced object doesn't exist. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/waf-2015-08-24/GetPermissionPolicy +func (c *WAF) GetPermissionPolicy(input *GetPermissionPolicyInput) (*GetPermissionPolicyOutput, error) { + req, out := c.GetPermissionPolicyRequest(input) + return out, req.Send() +} + +// GetPermissionPolicyWithContext is the same as GetPermissionPolicy with the addition of +// the ability to pass a context and additional request options. +// +// See GetPermissionPolicy for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *WAF) GetPermissionPolicyWithContext(ctx aws.Context, input *GetPermissionPolicyInput, opts ...request.Option) (*GetPermissionPolicyOutput, error) { + req, out := c.GetPermissionPolicyRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opGetRateBasedRule = "GetRateBasedRule" // GetRateBasedRuleRequest generates a "aws/request.Request" representing the // client's request for the GetRateBasedRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3756,7 +3928,7 @@ const opGetRateBasedRuleManagedKeys = "GetRateBasedRuleManagedKeys" // GetRateBasedRuleManagedKeysRequest generates a "aws/request.Request" representing the // client's request for the GetRateBasedRuleManagedKeys operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3875,7 +4047,7 @@ const opGetRegexMatchSet = "GetRegexMatchSet" // GetRegexMatchSetRequest generates a "aws/request.Request" representing the // client's request for the GetRegexMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3962,7 +4134,7 @@ const opGetRegexPatternSet = "GetRegexPatternSet" // GetRegexPatternSetRequest generates a "aws/request.Request" representing the // client's request for the GetRegexPatternSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4049,7 +4221,7 @@ const opGetRule = "GetRule" // GetRuleRequest generates a "aws/request.Request" representing the // client's request for the GetRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4137,7 +4309,7 @@ const opGetRuleGroup = "GetRuleGroup" // GetRuleGroupRequest generates a "aws/request.Request" representing the // client's request for the GetRuleGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4223,7 +4395,7 @@ const opGetSampledRequests = "GetSampledRequests" // GetSampledRequestsRequest generates a "aws/request.Request" representing the // client's request for the GetSampledRequests operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4316,7 +4488,7 @@ const opGetSizeConstraintSet = "GetSizeConstraintSet" // GetSizeConstraintSetRequest generates a "aws/request.Request" representing the // client's request for the GetSizeConstraintSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4403,7 +4575,7 @@ const opGetSqlInjectionMatchSet = "GetSqlInjectionMatchSet" // GetSqlInjectionMatchSetRequest generates a "aws/request.Request" representing the // client's request for the GetSqlInjectionMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4490,7 +4662,7 @@ const opGetWebACL = "GetWebACL" // GetWebACLRequest generates a "aws/request.Request" representing the // client's request for the GetWebACL operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4577,7 +4749,7 @@ const opGetXssMatchSet = "GetXssMatchSet" // GetXssMatchSetRequest generates a "aws/request.Request" representing the // client's request for the GetXssMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4664,7 +4836,7 @@ const opListActivatedRulesInRuleGroup = "ListActivatedRulesInRuleGroup" // ListActivatedRulesInRuleGroupRequest generates a "aws/request.Request" representing the // client's request for the ListActivatedRulesInRuleGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4776,7 +4948,7 @@ const opListByteMatchSets = "ListByteMatchSets" // ListByteMatchSetsRequest generates a "aws/request.Request" representing the // client's request for the ListByteMatchSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4860,7 +5032,7 @@ const opListGeoMatchSets = "ListGeoMatchSets" // ListGeoMatchSetsRequest generates a "aws/request.Request" representing the // client's request for the ListGeoMatchSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4944,7 +5116,7 @@ const opListIPSets = "ListIPSets" // ListIPSetsRequest generates a "aws/request.Request" representing the // client's request for the ListIPSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5028,7 +5200,7 @@ const opListRateBasedRules = "ListRateBasedRules" // ListRateBasedRulesRequest generates a "aws/request.Request" representing the // client's request for the ListRateBasedRules operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5112,7 +5284,7 @@ const opListRegexMatchSets = "ListRegexMatchSets" // ListRegexMatchSetsRequest generates a "aws/request.Request" representing the // client's request for the ListRegexMatchSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5196,7 +5368,7 @@ const opListRegexPatternSets = "ListRegexPatternSets" // ListRegexPatternSetsRequest generates a "aws/request.Request" representing the // client's request for the ListRegexPatternSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5280,7 +5452,7 @@ const opListRuleGroups = "ListRuleGroups" // ListRuleGroupsRequest generates a "aws/request.Request" representing the // client's request for the ListRuleGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5360,7 +5532,7 @@ const opListRules = "ListRules" // ListRulesRequest generates a "aws/request.Request" representing the // client's request for the ListRules operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5444,7 +5616,7 @@ const opListSizeConstraintSets = "ListSizeConstraintSets" // ListSizeConstraintSetsRequest generates a "aws/request.Request" representing the // client's request for the ListSizeConstraintSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5528,7 +5700,7 @@ const opListSqlInjectionMatchSets = "ListSqlInjectionMatchSets" // ListSqlInjectionMatchSetsRequest generates a "aws/request.Request" representing the // client's request for the ListSqlInjectionMatchSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5612,7 +5784,7 @@ const opListSubscribedRuleGroups = "ListSubscribedRuleGroups" // ListSubscribedRuleGroupsRequest generates a "aws/request.Request" representing the // client's request for the ListSubscribedRuleGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5695,7 +5867,7 @@ const opListWebACLs = "ListWebACLs" // ListWebACLsRequest generates a "aws/request.Request" representing the // client's request for the ListWebACLs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5779,7 +5951,7 @@ const opListXssMatchSets = "ListXssMatchSets" // ListXssMatchSetsRequest generates a "aws/request.Request" representing the // client's request for the ListXssMatchSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5859,11 +6031,146 @@ func (c *WAF) ListXssMatchSetsWithContext(ctx aws.Context, input *ListXssMatchSe return out, req.Send() } +const opPutPermissionPolicy = "PutPermissionPolicy" + +// PutPermissionPolicyRequest generates a "aws/request.Request" representing the +// client's request for the PutPermissionPolicy operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See PutPermissionPolicy for more information on using the PutPermissionPolicy +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the PutPermissionPolicyRequest method. +// req, resp := client.PutPermissionPolicyRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/waf-2015-08-24/PutPermissionPolicy +func (c *WAF) PutPermissionPolicyRequest(input *PutPermissionPolicyInput) (req *request.Request, output *PutPermissionPolicyOutput) { + op := &request.Operation{ + Name: opPutPermissionPolicy, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &PutPermissionPolicyInput{} + } + + output = &PutPermissionPolicyOutput{} + req = c.newRequest(op, input, output) + return +} + +// PutPermissionPolicy API operation for AWS WAF. +// +// Attaches a IAM policy to the specified resource. The only supported use for +// this action is to share a RuleGroup across accounts. +// +// The PutPermissionPolicy is subject to the following restrictions: +// +// * You can attach only one policy with each PutPermissionPolicy request. +// +// * The policy must include an Effect, Action and Principal. +// +// * Effect must specify Allow. +// +// * The Action in the policy must be waf:UpdateWebACL and waf-regional:UpdateWebACL. +// Any extra or wildcard actions in the policy will be rejected. +// +// * The policy cannot include a Resource parameter. +// +// * The ARN in the request must be a valid WAF RuleGroup ARN and the RuleGroup +// must exist in the same region. +// +// * The user making the request must be the owner of the RuleGroup. +// +// * Your policy must be composed using IAM Policy version 2012-10-17. +// +// For more information, see IAM Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html). +// +// An example of a valid policy parameter is shown in the Examples section below. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS WAF's +// API operation PutPermissionPolicy for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInternalErrorException "InternalErrorException" +// The operation failed because of a system problem, even though the request +// was valid. Retry your request. +// +// * ErrCodeStaleDataException "StaleDataException" +// The operation failed because you tried to create, update, or delete an object +// by using a change token that has already been used. +// +// * ErrCodeNonexistentItemException "NonexistentItemException" +// The operation failed because the referenced object doesn't exist. +// +// * ErrCodeInvalidPermissionPolicyException "InvalidPermissionPolicyException" +// The operation failed because the specified policy is not in the proper format. +// +// The policy is subject to the following restrictions: +// +// * You can attach only one policy with each PutPermissionPolicy request. +// +// * The policy must include an Effect, Action and Principal. +// +// * Effect must specify Allow. +// +// * The Action in the policy must be waf:UpdateWebACL or waf-regional:UpdateWebACL. +// Any extra or wildcard actions in the policy will be rejected. +// +// * The policy cannot include a Resource parameter. +// +// * The ARN in the request must be a valid WAF RuleGroup ARN and the RuleGroup +// must exist in the same region. +// +// * The user making the request must be the owner of the RuleGroup. +// +// * Your policy must be composed using IAM Policy version 2012-10-17. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/waf-2015-08-24/PutPermissionPolicy +func (c *WAF) PutPermissionPolicy(input *PutPermissionPolicyInput) (*PutPermissionPolicyOutput, error) { + req, out := c.PutPermissionPolicyRequest(input) + return out, req.Send() +} + +// PutPermissionPolicyWithContext is the same as PutPermissionPolicy with the addition of +// the ability to pass a context and additional request options. +// +// See PutPermissionPolicy for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *WAF) PutPermissionPolicyWithContext(ctx aws.Context, input *PutPermissionPolicyInput, opts ...request.Option) (*PutPermissionPolicyOutput, error) { + req, out := c.PutPermissionPolicyRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opUpdateByteMatchSet = "UpdateByteMatchSet" // UpdateByteMatchSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateByteMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6062,7 +6369,7 @@ const opUpdateGeoMatchSet = "UpdateGeoMatchSet" // UpdateGeoMatchSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateGeoMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6260,7 +6567,7 @@ const opUpdateIPSet = "UpdateIPSet" // UpdateIPSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateIPSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6479,7 +6786,7 @@ const opUpdateRateBasedRule = "UpdateRateBasedRule" // UpdateRateBasedRuleRequest generates a "aws/request.Request" representing the // client's request for the UpdateRateBasedRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6687,7 +6994,7 @@ const opUpdateRegexMatchSet = "UpdateRegexMatchSet" // UpdateRegexMatchSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateRegexMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6857,7 +7164,7 @@ const opUpdateRegexPatternSet = "UpdateRegexPatternSet" // UpdateRegexPatternSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateRegexPatternSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7024,7 +7331,7 @@ const opUpdateRule = "UpdateRule" // UpdateRuleRequest generates a "aws/request.Request" representing the // client's request for the UpdateRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7227,7 +7534,7 @@ const opUpdateRuleGroup = "UpdateRuleGroup" // UpdateRuleGroupRequest generates a "aws/request.Request" representing the // client's request for the UpdateRuleGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7408,7 +7715,7 @@ const opUpdateSizeConstraintSet = "UpdateSizeConstraintSet" // UpdateSizeConstraintSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateSizeConstraintSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7617,7 +7924,7 @@ const opUpdateSqlInjectionMatchSet = "UpdateSqlInjectionMatchSet" // UpdateSqlInjectionMatchSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateSqlInjectionMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7811,7 +8118,7 @@ const opUpdateWebACL = "UpdateWebACL" // UpdateWebACLRequest generates a "aws/request.Request" representing the // client's request for the UpdateWebACL operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8032,7 +8339,7 @@ const opUpdateXssMatchSet = "UpdateXssMatchSet" // UpdateXssMatchSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateXssMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8243,9 +8550,9 @@ type ActivatedRule struct { // in the rule and then continues to inspect the web request based on the // remaining rules in the web ACL. // - // The Action data type within ActivatedRule is used only when submitting an - // UpdateWebACL request. ActivatedRule|Action is not applicable and therefore - // not available for UpdateRuleGroup. + // ActivatedRule|OverrideAction applies only when updating or adding a RuleGroup + // to a WebACL. In this case you do not use ActivatedRule|Action. For all other + // update requests, ActivatedRule|Action is used instead of ActivatedRule|OverrideAction. Action *WafAction `type:"structure"` // Use the OverrideAction to test your RuleGroup. @@ -8259,9 +8566,9 @@ type ActivatedRule struct { // those requests will be counted. You can view a record of counted requests // using GetSampledRequests. // - // The OverrideAction data type within ActivatedRule is used only when submitting - // an UpdateRuleGroup request. ActivatedRule|OverrideAction is not applicable - // and therefore not available for UpdateWebACL. + // ActivatedRule|OverrideAction applies only when updating or adding a RuleGroup + // to a WebACL. In this case you do not use ActivatedRule|Action. For all other + // update requests, ActivatedRule|Action is used instead of ActivatedRule|OverrideAction. OverrideAction *WafOverrideAction `type:"structure"` // Specifies the order in which the Rules in a WebACL are evaluated. Rules with @@ -10276,6 +10583,64 @@ func (s *DeleteIPSetOutput) SetChangeToken(v string) *DeleteIPSetOutput { return s } +type DeletePermissionPolicyInput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the RuleGroup from which you want to delete + // the policy. + // + // The user making the request must be the owner of the RuleGroup. + // + // ResourceArn is a required field + ResourceArn *string `min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s DeletePermissionPolicyInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeletePermissionPolicyInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeletePermissionPolicyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeletePermissionPolicyInput"} + if s.ResourceArn == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceArn")) + } + if s.ResourceArn != nil && len(*s.ResourceArn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetResourceArn sets the ResourceArn field's value. +func (s *DeletePermissionPolicyInput) SetResourceArn(v string) *DeletePermissionPolicyInput { + s.ResourceArn = &v + return s +} + +type DeletePermissionPolicyOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s DeletePermissionPolicyOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s DeletePermissionPolicyOutput) GoString() string { + return s.String() +} + type DeleteRateBasedRuleInput struct { _ struct{} `type:"structure"` @@ -11632,6 +11997,71 @@ func (s *GetIPSetOutput) SetIPSet(v *IPSet) *GetIPSetOutput { return s } +type GetPermissionPolicyInput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the RuleGroup for which you want to get + // the policy. + // + // ResourceArn is a required field + ResourceArn *string `min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s GetPermissionPolicyInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetPermissionPolicyInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetPermissionPolicyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetPermissionPolicyInput"} + if s.ResourceArn == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceArn")) + } + if s.ResourceArn != nil && len(*s.ResourceArn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetResourceArn sets the ResourceArn field's value. +func (s *GetPermissionPolicyInput) SetResourceArn(v string) *GetPermissionPolicyInput { + s.ResourceArn = &v + return s +} + +type GetPermissionPolicyOutput struct { + _ struct{} `type:"structure"` + + // The IAM policy attached to the specified RuleGroup. + Policy *string `min:"1" type:"string"` +} + +// String returns the string representation +func (s GetPermissionPolicyOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s GetPermissionPolicyOutput) GoString() string { + return s.String() +} + +// SetPolicy sets the Policy field's value. +func (s *GetPermissionPolicyOutput) SetPolicy(v string) *GetPermissionPolicyOutput { + s.Policy = &v + return s +} + type GetRateBasedRuleInput struct { _ struct{} `type:"structure"` @@ -14192,6 +14622,79 @@ func (s *Predicate) SetType(v string) *Predicate { return s } +type PutPermissionPolicyInput struct { + _ struct{} `type:"structure"` + + // The policy to attach to the specified RuleGroup. + // + // Policy is a required field + Policy *string `min:"1" type:"string" required:"true"` + + // The Amazon Resource Name (ARN) of the RuleGroup to which you want to attach + // the policy. + // + // ResourceArn is a required field + ResourceArn *string `min:"1" type:"string" required:"true"` +} + +// String returns the string representation +func (s PutPermissionPolicyInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PutPermissionPolicyInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *PutPermissionPolicyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PutPermissionPolicyInput"} + if s.Policy == nil { + invalidParams.Add(request.NewErrParamRequired("Policy")) + } + if s.Policy != nil && len(*s.Policy) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Policy", 1)) + } + if s.ResourceArn == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceArn")) + } + if s.ResourceArn != nil && len(*s.ResourceArn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetPolicy sets the Policy field's value. +func (s *PutPermissionPolicyInput) SetPolicy(v string) *PutPermissionPolicyInput { + s.Policy = &v + return s +} + +// SetResourceArn sets the ResourceArn field's value. +func (s *PutPermissionPolicyInput) SetResourceArn(v string) *PutPermissionPolicyInput { + s.ResourceArn = &v + return s +} + +type PutPermissionPolicyOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s PutPermissionPolicyOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s PutPermissionPolicyOutput) GoString() string { + return s.String() +} + // A RateBasedRule is identical to a regular Rule, with one addition: a RateBasedRule // counts the number of requests that arrive from a specified IP address every // five minutes. For example, based on recent requests that you've seen from @@ -16697,9 +17200,9 @@ type UpdateRuleGroupInput struct { // // You can only insert REGULAR rules into a rule group. // - // The Action data type within ActivatedRule is used only when submitting an - // UpdateWebACL request. ActivatedRule|Action is not applicable and therefore - // not available for UpdateRuleGroup. + // ActivatedRule|OverrideAction applies only when updating or adding a RuleGroup + // to a WebACL. In this case you do not use ActivatedRule|Action. For all other + // update requests, ActivatedRule|Action is used instead of ActivatedRule|OverrideAction. // // Updates is a required field Updates []*RuleGroupUpdate `min:"1" type:"list" required:"true"` @@ -17172,10 +17675,11 @@ type UpdateWebACLInput struct { // // * WebACLUpdate: Contains Action and ActivatedRule // - // * ActivatedRule: Contains Action, Priority, RuleId, and Type. The OverrideAction - // data type within ActivatedRule is used only when submitting an UpdateRuleGroup - // request. ActivatedRule|OverrideAction is not applicable and therefore - // not available for UpdateWebACL. + // * ActivatedRule: Contains Action, OverrideAction, Priority, RuleId, and + // Type. ActivatedRule|OverrideAction applies only when updating or adding + // a RuleGroup to a WebACL. In this case you do not use ActivatedRule|Action. + // For all other update requests, ActivatedRule|Action is used instead of + // ActivatedRule|OverrideAction. // // * WafAction: Contains Type Updates []*WebACLUpdate `type:"list"` diff --git a/vendor/github.com/aws/aws-sdk-go/service/waf/errors.go b/vendor/github.com/aws/aws-sdk-go/service/waf/errors.go index 0e429fbf19ec..1e85bed52a46 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/waf/errors.go +++ b/vendor/github.com/aws/aws-sdk-go/service/waf/errors.go @@ -80,6 +80,32 @@ const ( // a resource with which a web ACL cannot be associated. ErrCodeInvalidParameterException = "InvalidParameterException" + // ErrCodeInvalidPermissionPolicyException for service response error code + // "InvalidPermissionPolicyException". + // + // The operation failed because the specified policy is not in the proper format. + // + // The policy is subject to the following restrictions: + // + // * You can attach only one policy with each PutPermissionPolicy request. + // + // * The policy must include an Effect, Action and Principal. + // + // * Effect must specify Allow. + // + // * The Action in the policy must be waf:UpdateWebACL or waf-regional:UpdateWebACL. + // Any extra or wildcard actions in the policy will be rejected. + // + // * The policy cannot include a Resource parameter. + // + // * The ARN in the request must be a valid WAF RuleGroup ARN and the RuleGroup + // must exist in the same region. + // + // * The user making the request must be the owner of the RuleGroup. + // + // * Your policy must be composed using IAM Policy version 2012-10-17. + ErrCodeInvalidPermissionPolicyException = "InvalidPermissionPolicyException" + // ErrCodeInvalidRegexPatternException for service response error code // "InvalidRegexPatternException". // diff --git a/vendor/github.com/aws/aws-sdk-go/service/wafregional/api.go b/vendor/github.com/aws/aws-sdk-go/service/wafregional/api.go index e46b3e9d0efe..cd5c09e23a52 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/wafregional/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/wafregional/api.go @@ -13,7 +13,7 @@ const opAssociateWebACL = "AssociateWebACL" // AssociateWebACLRequest generates a "aws/request.Request" representing the // client's request for the AssociateWebACL operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -133,7 +133,7 @@ const opCreateByteMatchSet = "CreateByteMatchSet" // CreateByteMatchSetRequest generates a "aws/request.Request" representing the // client's request for the CreateByteMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -280,7 +280,7 @@ const opCreateGeoMatchSet = "CreateGeoMatchSet" // CreateGeoMatchSetRequest generates a "aws/request.Request" representing the // client's request for the CreateGeoMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -426,7 +426,7 @@ const opCreateIPSet = "CreateIPSet" // CreateIPSetRequest generates a "aws/request.Request" representing the // client's request for the CreateIPSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -573,7 +573,7 @@ const opCreateRateBasedRule = "CreateRateBasedRule" // CreateRateBasedRuleRequest generates a "aws/request.Request" representing the // client's request for the CreateRateBasedRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -755,7 +755,7 @@ const opCreateRegexMatchSet = "CreateRegexMatchSet" // CreateRegexMatchSetRequest generates a "aws/request.Request" representing the // client's request for the CreateRegexMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -870,7 +870,7 @@ const opCreateRegexPatternSet = "CreateRegexPatternSet" // CreateRegexPatternSetRequest generates a "aws/request.Request" representing the // client's request for the CreateRegexPatternSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -981,7 +981,7 @@ const opCreateRule = "CreateRule" // CreateRuleRequest generates a "aws/request.Request" representing the // client's request for the CreateRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1138,7 +1138,7 @@ const opCreateRuleGroup = "CreateRuleGroup" // CreateRuleGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateRuleGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1244,7 +1244,7 @@ const opCreateSizeConstraintSet = "CreateSizeConstraintSet" // CreateSizeConstraintSetRequest generates a "aws/request.Request" representing the // client's request for the CreateSizeConstraintSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1392,7 +1392,7 @@ const opCreateSqlInjectionMatchSet = "CreateSqlInjectionMatchSet" // CreateSqlInjectionMatchSetRequest generates a "aws/request.Request" representing the // client's request for the CreateSqlInjectionMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1536,7 +1536,7 @@ const opCreateWebACL = "CreateWebACL" // CreateWebACLRequest generates a "aws/request.Request" representing the // client's request for the CreateWebACL operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1692,7 +1692,7 @@ const opCreateXssMatchSet = "CreateXssMatchSet" // CreateXssMatchSetRequest generates a "aws/request.Request" representing the // client's request for the CreateXssMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1837,7 +1837,7 @@ const opDeleteByteMatchSet = "DeleteByteMatchSet" // DeleteByteMatchSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteByteMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -1964,7 +1964,7 @@ const opDeleteGeoMatchSet = "DeleteGeoMatchSet" // DeleteGeoMatchSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteGeoMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2090,7 +2090,7 @@ const opDeleteIPSet = "DeleteIPSet" // DeleteIPSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteIPSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2212,11 +2212,100 @@ func (c *WAFRegional) DeleteIPSetWithContext(ctx aws.Context, input *waf.DeleteI return out, req.Send() } +const opDeletePermissionPolicy = "DeletePermissionPolicy" + +// DeletePermissionPolicyRequest generates a "aws/request.Request" representing the +// client's request for the DeletePermissionPolicy operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeletePermissionPolicy for more information on using the DeletePermissionPolicy +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the DeletePermissionPolicyRequest method. +// req, resp := client.DeletePermissionPolicyRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/waf-regional-2016-11-28/DeletePermissionPolicy +func (c *WAFRegional) DeletePermissionPolicyRequest(input *waf.DeletePermissionPolicyInput) (req *request.Request, output *waf.DeletePermissionPolicyOutput) { + op := &request.Operation{ + Name: opDeletePermissionPolicy, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &waf.DeletePermissionPolicyInput{} + } + + output = &waf.DeletePermissionPolicyOutput{} + req = c.newRequest(op, input, output) + return +} + +// DeletePermissionPolicy API operation for AWS WAF Regional. +// +// Permanently deletes an IAM policy from the specified RuleGroup. +// +// The user making the request must be the owner of the RuleGroup. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS WAF Regional's +// API operation DeletePermissionPolicy for usage and error information. +// +// Returned Error Codes: +// * ErrCodeWAFInternalErrorException "WAFInternalErrorException" +// The operation failed because of a system problem, even though the request +// was valid. Retry your request. +// +// * ErrCodeWAFStaleDataException "WAFStaleDataException" +// The operation failed because you tried to create, update, or delete an object +// by using a change token that has already been used. +// +// * ErrCodeWAFNonexistentItemException "WAFNonexistentItemException" +// The operation failed because the referenced object doesn't exist. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/waf-regional-2016-11-28/DeletePermissionPolicy +func (c *WAFRegional) DeletePermissionPolicy(input *waf.DeletePermissionPolicyInput) (*waf.DeletePermissionPolicyOutput, error) { + req, out := c.DeletePermissionPolicyRequest(input) + return out, req.Send() +} + +// DeletePermissionPolicyWithContext is the same as DeletePermissionPolicy with the addition of +// the ability to pass a context and additional request options. +// +// See DeletePermissionPolicy for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *WAFRegional) DeletePermissionPolicyWithContext(ctx aws.Context, input *waf.DeletePermissionPolicyInput, opts ...request.Option) (*waf.DeletePermissionPolicyOutput, error) { + req, out := c.DeletePermissionPolicyRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opDeleteRateBasedRule = "DeleteRateBasedRule" // DeleteRateBasedRuleRequest generates a "aws/request.Request" representing the // client's request for the DeleteRateBasedRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2344,7 +2433,7 @@ const opDeleteRegexMatchSet = "DeleteRegexMatchSet" // DeleteRegexMatchSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteRegexMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2471,7 +2560,7 @@ const opDeleteRegexPatternSet = "DeleteRegexPatternSet" // DeleteRegexPatternSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteRegexPatternSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2586,7 +2675,7 @@ const opDeleteRule = "DeleteRule" // DeleteRuleRequest generates a "aws/request.Request" representing the // client's request for the DeleteRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2712,7 +2801,7 @@ const opDeleteRuleGroup = "DeleteRuleGroup" // DeleteRuleGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteRuleGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2833,7 +2922,7 @@ const opDeleteSizeConstraintSet = "DeleteSizeConstraintSet" // DeleteSizeConstraintSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteSizeConstraintSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -2960,7 +3049,7 @@ const opDeleteSqlInjectionMatchSet = "DeleteSqlInjectionMatchSet" // DeleteSqlInjectionMatchSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteSqlInjectionMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3088,7 +3177,7 @@ const opDeleteWebACL = "DeleteWebACL" // DeleteWebACLRequest generates a "aws/request.Request" representing the // client's request for the DeleteWebACL operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3211,7 +3300,7 @@ const opDeleteXssMatchSet = "DeleteXssMatchSet" // DeleteXssMatchSetRequest generates a "aws/request.Request" representing the // client's request for the DeleteXssMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3338,7 +3427,7 @@ const opDisassociateWebACL = "DisassociateWebACL" // DisassociateWebACLRequest generates a "aws/request.Request" representing the // client's request for the DisassociateWebACL operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3454,7 +3543,7 @@ const opGetByteMatchSet = "GetByteMatchSet" // GetByteMatchSetRequest generates a "aws/request.Request" representing the // client's request for the GetByteMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3541,7 +3630,7 @@ const opGetChangeToken = "GetChangeToken" // GetChangeTokenRequest generates a "aws/request.Request" representing the // client's request for the GetChangeToken operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3635,7 +3724,7 @@ const opGetChangeTokenStatus = "GetChangeTokenStatus" // GetChangeTokenStatusRequest generates a "aws/request.Request" representing the // client's request for the GetChangeTokenStatus operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3728,7 +3817,7 @@ const opGetGeoMatchSet = "GetGeoMatchSet" // GetGeoMatchSetRequest generates a "aws/request.Request" representing the // client's request for the GetGeoMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3815,7 +3904,7 @@ const opGetIPSet = "GetIPSet" // GetIPSetRequest generates a "aws/request.Request" representing the // client's request for the GetIPSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3898,11 +3987,94 @@ func (c *WAFRegional) GetIPSetWithContext(ctx aws.Context, input *waf.GetIPSetIn return out, req.Send() } +const opGetPermissionPolicy = "GetPermissionPolicy" + +// GetPermissionPolicyRequest generates a "aws/request.Request" representing the +// client's request for the GetPermissionPolicy operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetPermissionPolicy for more information on using the GetPermissionPolicy +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the GetPermissionPolicyRequest method. +// req, resp := client.GetPermissionPolicyRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/waf-regional-2016-11-28/GetPermissionPolicy +func (c *WAFRegional) GetPermissionPolicyRequest(input *waf.GetPermissionPolicyInput) (req *request.Request, output *waf.GetPermissionPolicyOutput) { + op := &request.Operation{ + Name: opGetPermissionPolicy, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &waf.GetPermissionPolicyInput{} + } + + output = &waf.GetPermissionPolicyOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetPermissionPolicy API operation for AWS WAF Regional. +// +// Returns the IAM policy attached to the RuleGroup. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS WAF Regional's +// API operation GetPermissionPolicy for usage and error information. +// +// Returned Error Codes: +// * ErrCodeWAFInternalErrorException "WAFInternalErrorException" +// The operation failed because of a system problem, even though the request +// was valid. Retry your request. +// +// * ErrCodeWAFNonexistentItemException "WAFNonexistentItemException" +// The operation failed because the referenced object doesn't exist. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/waf-regional-2016-11-28/GetPermissionPolicy +func (c *WAFRegional) GetPermissionPolicy(input *waf.GetPermissionPolicyInput) (*waf.GetPermissionPolicyOutput, error) { + req, out := c.GetPermissionPolicyRequest(input) + return out, req.Send() +} + +// GetPermissionPolicyWithContext is the same as GetPermissionPolicy with the addition of +// the ability to pass a context and additional request options. +// +// See GetPermissionPolicy for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *WAFRegional) GetPermissionPolicyWithContext(ctx aws.Context, input *waf.GetPermissionPolicyInput, opts ...request.Option) (*waf.GetPermissionPolicyOutput, error) { + req, out := c.GetPermissionPolicyRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opGetRateBasedRule = "GetRateBasedRule" // GetRateBasedRuleRequest generates a "aws/request.Request" representing the // client's request for the GetRateBasedRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -3990,7 +4162,7 @@ const opGetRateBasedRuleManagedKeys = "GetRateBasedRuleManagedKeys" // GetRateBasedRuleManagedKeysRequest generates a "aws/request.Request" representing the // client's request for the GetRateBasedRuleManagedKeys operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4109,7 +4281,7 @@ const opGetRegexMatchSet = "GetRegexMatchSet" // GetRegexMatchSetRequest generates a "aws/request.Request" representing the // client's request for the GetRegexMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4196,7 +4368,7 @@ const opGetRegexPatternSet = "GetRegexPatternSet" // GetRegexPatternSetRequest generates a "aws/request.Request" representing the // client's request for the GetRegexPatternSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4283,7 +4455,7 @@ const opGetRule = "GetRule" // GetRuleRequest generates a "aws/request.Request" representing the // client's request for the GetRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4371,7 +4543,7 @@ const opGetRuleGroup = "GetRuleGroup" // GetRuleGroupRequest generates a "aws/request.Request" representing the // client's request for the GetRuleGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4457,7 +4629,7 @@ const opGetSampledRequests = "GetSampledRequests" // GetSampledRequestsRequest generates a "aws/request.Request" representing the // client's request for the GetSampledRequests operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4550,7 +4722,7 @@ const opGetSizeConstraintSet = "GetSizeConstraintSet" // GetSizeConstraintSetRequest generates a "aws/request.Request" representing the // client's request for the GetSizeConstraintSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4637,7 +4809,7 @@ const opGetSqlInjectionMatchSet = "GetSqlInjectionMatchSet" // GetSqlInjectionMatchSetRequest generates a "aws/request.Request" representing the // client's request for the GetSqlInjectionMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4724,7 +4896,7 @@ const opGetWebACL = "GetWebACL" // GetWebACLRequest generates a "aws/request.Request" representing the // client's request for the GetWebACL operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4811,7 +4983,7 @@ const opGetWebACLForResource = "GetWebACLForResource" // GetWebACLForResourceRequest generates a "aws/request.Request" representing the // client's request for the GetWebACLForResource operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -4931,7 +5103,7 @@ const opGetXssMatchSet = "GetXssMatchSet" // GetXssMatchSetRequest generates a "aws/request.Request" representing the // client's request for the GetXssMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5018,7 +5190,7 @@ const opListActivatedRulesInRuleGroup = "ListActivatedRulesInRuleGroup" // ListActivatedRulesInRuleGroupRequest generates a "aws/request.Request" representing the // client's request for the ListActivatedRulesInRuleGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5130,7 +5302,7 @@ const opListByteMatchSets = "ListByteMatchSets" // ListByteMatchSetsRequest generates a "aws/request.Request" representing the // client's request for the ListByteMatchSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5214,7 +5386,7 @@ const opListGeoMatchSets = "ListGeoMatchSets" // ListGeoMatchSetsRequest generates a "aws/request.Request" representing the // client's request for the ListGeoMatchSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5298,7 +5470,7 @@ const opListIPSets = "ListIPSets" // ListIPSetsRequest generates a "aws/request.Request" representing the // client's request for the ListIPSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5382,7 +5554,7 @@ const opListRateBasedRules = "ListRateBasedRules" // ListRateBasedRulesRequest generates a "aws/request.Request" representing the // client's request for the ListRateBasedRules operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5466,7 +5638,7 @@ const opListRegexMatchSets = "ListRegexMatchSets" // ListRegexMatchSetsRequest generates a "aws/request.Request" representing the // client's request for the ListRegexMatchSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5550,7 +5722,7 @@ const opListRegexPatternSets = "ListRegexPatternSets" // ListRegexPatternSetsRequest generates a "aws/request.Request" representing the // client's request for the ListRegexPatternSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5634,7 +5806,7 @@ const opListResourcesForWebACL = "ListResourcesForWebACL" // ListResourcesForWebACLRequest generates a "aws/request.Request" representing the // client's request for the ListResourcesForWebACL operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5721,7 +5893,7 @@ const opListRuleGroups = "ListRuleGroups" // ListRuleGroupsRequest generates a "aws/request.Request" representing the // client's request for the ListRuleGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5801,7 +5973,7 @@ const opListRules = "ListRules" // ListRulesRequest generates a "aws/request.Request" representing the // client's request for the ListRules operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5885,7 +6057,7 @@ const opListSizeConstraintSets = "ListSizeConstraintSets" // ListSizeConstraintSetsRequest generates a "aws/request.Request" representing the // client's request for the ListSizeConstraintSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -5969,7 +6141,7 @@ const opListSqlInjectionMatchSets = "ListSqlInjectionMatchSets" // ListSqlInjectionMatchSetsRequest generates a "aws/request.Request" representing the // client's request for the ListSqlInjectionMatchSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6053,7 +6225,7 @@ const opListSubscribedRuleGroups = "ListSubscribedRuleGroups" // ListSubscribedRuleGroupsRequest generates a "aws/request.Request" representing the // client's request for the ListSubscribedRuleGroups operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6136,7 +6308,7 @@ const opListWebACLs = "ListWebACLs" // ListWebACLsRequest generates a "aws/request.Request" representing the // client's request for the ListWebACLs operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6220,7 +6392,7 @@ const opListXssMatchSets = "ListXssMatchSets" // ListXssMatchSetsRequest generates a "aws/request.Request" representing the // client's request for the ListXssMatchSets operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6300,11 +6472,146 @@ func (c *WAFRegional) ListXssMatchSetsWithContext(ctx aws.Context, input *waf.Li return out, req.Send() } +const opPutPermissionPolicy = "PutPermissionPolicy" + +// PutPermissionPolicyRequest generates a "aws/request.Request" representing the +// client's request for the PutPermissionPolicy operation. The "output" return +// value will be populated with the request's response once the request completes +// successfuly. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See PutPermissionPolicy for more information on using the PutPermissionPolicy +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the PutPermissionPolicyRequest method. +// req, resp := client.PutPermissionPolicyRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/waf-regional-2016-11-28/PutPermissionPolicy +func (c *WAFRegional) PutPermissionPolicyRequest(input *waf.PutPermissionPolicyInput) (req *request.Request, output *waf.PutPermissionPolicyOutput) { + op := &request.Operation{ + Name: opPutPermissionPolicy, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &waf.PutPermissionPolicyInput{} + } + + output = &waf.PutPermissionPolicyOutput{} + req = c.newRequest(op, input, output) + return +} + +// PutPermissionPolicy API operation for AWS WAF Regional. +// +// Attaches a IAM policy to the specified resource. The only supported use for +// this action is to share a RuleGroup across accounts. +// +// The PutPermissionPolicy is subject to the following restrictions: +// +// * You can attach only one policy with each PutPermissionPolicy request. +// +// * The policy must include an Effect, Action and Principal. +// +// * Effect must specify Allow. +// +// * The Action in the policy must be waf:UpdateWebACL and waf-regional:UpdateWebACL. +// Any extra or wildcard actions in the policy will be rejected. +// +// * The policy cannot include a Resource parameter. +// +// * The ARN in the request must be a valid WAF RuleGroup ARN and the RuleGroup +// must exist in the same region. +// +// * The user making the request must be the owner of the RuleGroup. +// +// * Your policy must be composed using IAM Policy version 2012-10-17. +// +// For more information, see IAM Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html). +// +// An example of a valid policy parameter is shown in the Examples section below. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for AWS WAF Regional's +// API operation PutPermissionPolicy for usage and error information. +// +// Returned Error Codes: +// * ErrCodeWAFInternalErrorException "WAFInternalErrorException" +// The operation failed because of a system problem, even though the request +// was valid. Retry your request. +// +// * ErrCodeWAFStaleDataException "WAFStaleDataException" +// The operation failed because you tried to create, update, or delete an object +// by using a change token that has already been used. +// +// * ErrCodeWAFNonexistentItemException "WAFNonexistentItemException" +// The operation failed because the referenced object doesn't exist. +// +// * ErrCodeWAFInvalidPermissionPolicyException "WAFInvalidPermissionPolicyException" +// The operation failed because the specified policy is not in the proper format. +// +// The policy is subject to the following restrictions: +// +// * You can attach only one policy with each PutPermissionPolicy request. +// +// * The policy must include an Effect, Action and Principal. +// +// * Effect must specify Allow. +// +// * The Action in the policy must be waf:UpdateWebACL or waf-regional:UpdateWebACL. +// Any extra or wildcard actions in the policy will be rejected. +// +// * The policy cannot include a Resource parameter. +// +// * The ARN in the request must be a valid WAF RuleGroup ARN and the RuleGroup +// must exist in the same region. +// +// * The user making the request must be the owner of the RuleGroup. +// +// * Your policy must be composed using IAM Policy version 2012-10-17. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/waf-regional-2016-11-28/PutPermissionPolicy +func (c *WAFRegional) PutPermissionPolicy(input *waf.PutPermissionPolicyInput) (*waf.PutPermissionPolicyOutput, error) { + req, out := c.PutPermissionPolicyRequest(input) + return out, req.Send() +} + +// PutPermissionPolicyWithContext is the same as PutPermissionPolicy with the addition of +// the ability to pass a context and additional request options. +// +// See PutPermissionPolicy for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *WAFRegional) PutPermissionPolicyWithContext(ctx aws.Context, input *waf.PutPermissionPolicyInput, opts ...request.Option) (*waf.PutPermissionPolicyOutput, error) { + req, out := c.PutPermissionPolicyRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opUpdateByteMatchSet = "UpdateByteMatchSet" // UpdateByteMatchSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateByteMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6503,7 +6810,7 @@ const opUpdateGeoMatchSet = "UpdateGeoMatchSet" // UpdateGeoMatchSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateGeoMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6701,7 +7008,7 @@ const opUpdateIPSet = "UpdateIPSet" // UpdateIPSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateIPSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -6920,7 +7227,7 @@ const opUpdateRateBasedRule = "UpdateRateBasedRule" // UpdateRateBasedRuleRequest generates a "aws/request.Request" representing the // client's request for the UpdateRateBasedRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7128,7 +7435,7 @@ const opUpdateRegexMatchSet = "UpdateRegexMatchSet" // UpdateRegexMatchSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateRegexMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7298,7 +7605,7 @@ const opUpdateRegexPatternSet = "UpdateRegexPatternSet" // UpdateRegexPatternSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateRegexPatternSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7465,7 +7772,7 @@ const opUpdateRule = "UpdateRule" // UpdateRuleRequest generates a "aws/request.Request" representing the // client's request for the UpdateRule operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7668,7 +7975,7 @@ const opUpdateRuleGroup = "UpdateRuleGroup" // UpdateRuleGroupRequest generates a "aws/request.Request" representing the // client's request for the UpdateRuleGroup operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -7849,7 +8156,7 @@ const opUpdateSizeConstraintSet = "UpdateSizeConstraintSet" // UpdateSizeConstraintSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateSizeConstraintSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8058,7 +8365,7 @@ const opUpdateSqlInjectionMatchSet = "UpdateSqlInjectionMatchSet" // UpdateSqlInjectionMatchSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateSqlInjectionMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8252,7 +8559,7 @@ const opUpdateWebACL = "UpdateWebACL" // UpdateWebACLRequest generates a "aws/request.Request" representing the // client's request for the UpdateWebACL operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. @@ -8473,7 +8780,7 @@ const opUpdateXssMatchSet = "UpdateXssMatchSet" // UpdateXssMatchSetRequest generates a "aws/request.Request" representing the // client's request for the UpdateXssMatchSet operation. The "output" return -// value will be populated with the request's response once the request complets +// value will be populated with the request's response once the request completes // successfuly. // // Use "Send" method on the returned Request to send the API call to the service. diff --git a/vendor/github.com/aws/aws-sdk-go/service/wafregional/errors.go b/vendor/github.com/aws/aws-sdk-go/service/wafregional/errors.go index 677099c70ae2..793dbc2fcae0 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/wafregional/errors.go +++ b/vendor/github.com/aws/aws-sdk-go/service/wafregional/errors.go @@ -80,6 +80,32 @@ const ( // a resource with which a web ACL cannot be associated. ErrCodeWAFInvalidParameterException = "WAFInvalidParameterException" + // ErrCodeWAFInvalidPermissionPolicyException for service response error code + // "WAFInvalidPermissionPolicyException". + // + // The operation failed because the specified policy is not in the proper format. + // + // The policy is subject to the following restrictions: + // + // * You can attach only one policy with each PutPermissionPolicy request. + // + // * The policy must include an Effect, Action and Principal. + // + // * Effect must specify Allow. + // + // * The Action in the policy must be waf:UpdateWebACL or waf-regional:UpdateWebACL. + // Any extra or wildcard actions in the policy will be rejected. + // + // * The policy cannot include a Resource parameter. + // + // * The ARN in the request must be a valid WAF RuleGroup ARN and the RuleGroup + // must exist in the same region. + // + // * The user making the request must be the owner of the RuleGroup. + // + // * Your policy must be composed using IAM Policy version 2012-10-17. + ErrCodeWAFInvalidPermissionPolicyException = "WAFInvalidPermissionPolicyException" + // ErrCodeWAFInvalidRegexPatternException for service response error code // "WAFInvalidRegexPatternException". // diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/CHANGELOG.md b/vendor/github.com/terraform-providers/terraform-provider-aws/CHANGELOG.md index 2e140809fc49..7139fb0f816d 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/CHANGELOG.md +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/CHANGELOG.md @@ -1,3 +1,205 @@ +## 1.14.1 (April 11, 2018) + +ENHANCEMENTS: + +* resource/aws_db_event_subscription: Add `arn` attribute ([#4151](https://github.com/terraform-providers/terraform-provider-aws/issues/4151)) +* resource/aws_db_event_subscription: Support configurable timeouts ([#4151](https://github.com/terraform-providers/terraform-provider-aws/issues/4151)) + +BUG FIXES: + +* resource/aws_codebuild_project: Properly handle setting cache type `NO_CACHE` ([#4134](https://github.com/terraform-providers/terraform-provider-aws/issues/4134)) +* resource/aws_db_event_subscription: Fix `tag` ARN handling ([#4151](https://github.com/terraform-providers/terraform-provider-aws/issues/4151)) +* resource/aws_dynamodb_table_item: Trigger destructive update if range_key has changed ([#3821](https://github.com/terraform-providers/terraform-provider-aws/issues/3821)) +* resource/aws_elb: Return any errors when updating listeners ([#4159](https://github.com/terraform-providers/terraform-provider-aws/issues/4159)) +* resource/aws_emr_cluster: Prevent crash with missing StateChangeReason ([#4165](https://github.com/terraform-providers/terraform-provider-aws/issues/4165)) +* resource/aws_iam_user: Retry user login profile deletion on `EntityTemporarilyUnmodifiable` ([#4143](https://github.com/terraform-providers/terraform-provider-aws/issues/4143)) +* resource/aws_kinesis_firehose_delivery_stream: Prevent crash with missing CloudWatch logging options ([#4148](https://github.com/terraform-providers/terraform-provider-aws/issues/4148)) +* resource/aws_lambda_alias: Force new resource on `name` change ([#4106](https://github.com/terraform-providers/terraform-provider-aws/issues/4106)) +* resource/aws_lambda_function: Prevent perpetual difference when removing `dead_letter_config` ([#2684](https://github.com/terraform-providers/terraform-provider-aws/issues/2684)) +* resource/aws_launch_configuration: Properly read `security_groups`, `user_data`, and `vpc_classic_link_security_groups` attributes into Terraform state ([#2800](https://github.com/terraform-providers/terraform-provider-aws/issues/2800)) +* resource/aws_network_acl: Prevent error on deletion with already deleted subnets ([#4119](https://github.com/terraform-providers/terraform-provider-aws/issues/4119)) +* resource/aws_network_acl: Prevent error on update with removing associations for already deleted subnets ([#4119](https://github.com/terraform-providers/terraform-provider-aws/issues/4119)) +* resource/aws_rds_cluster: Properly handle `engine_version` during regular creation ([#4139](https://github.com/terraform-providers/terraform-provider-aws/issues/4139)) +* resource/aws_rds_cluster: Set `port` updates to force new resource ([#4144](https://github.com/terraform-providers/terraform-provider-aws/issues/4144)) +* resource/aws_route53_zone: Suppress `name` difference with trailing period ([#3982](https://github.com/terraform-providers/terraform-provider-aws/issues/3982)) +* resource/aws_vpc_peering_connection: Allow active pending state during deletion for eventual consistency ([#4140](https://github.com/terraform-providers/terraform-provider-aws/issues/4140)) + +## 1.14.0 (April 06, 2018) + +NOTES: + +* resource/aws_organizations_account: As noted in the resource documentation, resource deletion from Terraform will _not_ automatically close AWS accounts due to the behavior of the AWS Organizations service. There are also various manual steps required by AWS before the account can be removed from an organization and made into a standalone account, then manually closed if desired. + +FEATURES: + +* **New Resource:** `aws_organizations_account` ([#3524](https://github.com/terraform-providers/terraform-provider-aws/issues/3524)) +* **New Resource:** `aws_ses_identity_notification_topic` ([#2640](https://github.com/terraform-providers/terraform-provider-aws/issues/2640)) + +ENHANCEMENTS: + +* provider: Fallback to SDK default credential chain if credentials not found using provider credential chain ([#2883](https://github.com/terraform-providers/terraform-provider-aws/issues/2883)) +* data-source/aws_iam_role: Add `max_session_duration` attribute ([#4092](https://github.com/terraform-providers/terraform-provider-aws/issues/4092)) +* resource/aws_cloudfront_distribution: Add cache_behavior `field_level_encryption_id` attribute ([#4102](https://github.com/terraform-providers/terraform-provider-aws/issues/4102)) +* resource/aws_codebuild_project: Support `cache` configuration ([#2860](https://github.com/terraform-providers/terraform-provider-aws/issues/2860)) +* resource/aws_elasticache_replication_group: Support Cluster Mode Enabled online shard reconfiguration ([#3932](https://github.com/terraform-providers/terraform-provider-aws/issues/3932)) +* resource/aws_elasticache_replication_group: Configurable create, update, and delete timeouts ([#3932](https://github.com/terraform-providers/terraform-provider-aws/issues/3932)) +* resource/aws_iam_role: Add `max_session_duration` argument ([#3977](https://github.com/terraform-providers/terraform-provider-aws/issues/3977)) +* resource/aws_kinesis_firehose_delivery_stream: Add Elasticsearch destination processing configuration support ([#3621](https://github.com/terraform-providers/terraform-provider-aws/issues/3621)) +* resource/aws_kinesis_firehose_delivery_stream: Add Extended S3 destination backup mode support ([#2987](https://github.com/terraform-providers/terraform-provider-aws/issues/2987)) +* resource/aws_kinesis_firehose_delivery_stream: Add Splunk destination processing configuration support ([#3944](https://github.com/terraform-providers/terraform-provider-aws/issues/3944)) +* resource/aws_lambda_function: Support `nodejs8.10` runtime ([#4020](https://github.com/terraform-providers/terraform-provider-aws/issues/4020)) +* resource/aws_launch_configuration: Add support for `ebs_block_device.*.no_device` ([#4070](https://github.com/terraform-providers/terraform-provider-aws/issues/4070)) +* resource/aws_ssm_maintenance_window_target: Make resource updatable ([#4074](https://github.com/terraform-providers/terraform-provider-aws/issues/4074)) +* resource/aws_wafregional_rule: Validate all predicate types ([#4046](https://github.com/terraform-providers/terraform-provider-aws/issues/4046)) + +BUG FIXES: + +* resource/aws_cognito_user_pool: Trim `custom:` prefix of `developer_only_attribute = false` schema attributes ([#4041](https://github.com/terraform-providers/terraform-provider-aws/issues/4041)) +* resource/aws_cognito_user_pool: Fix `email_message_by_link` max length validation ([#4051](https://github.com/terraform-providers/terraform-provider-aws/issues/4051)) +* resource/aws_elasticache_replication_group: Properly set `cluster_mode` in state ([#3932](https://github.com/terraform-providers/terraform-provider-aws/issues/3932)) +* resource/aws_iam_user_login_profile: Changed password generation to use `crypto/rand` ([#3989](https://github.com/terraform-providers/terraform-provider-aws/issues/3989)) +* resource/aws_kinesis_firehose_delivery_stream: Prevent additional crash scenarios with optional configurations ([#4047](https://github.com/terraform-providers/terraform-provider-aws/issues/4047)) +* resource/aws_lambda_function: IAM retry for "The role defined for the function cannot be assumed by Lambda" on update ([#3988](https://github.com/terraform-providers/terraform-provider-aws/issues/3988)) +* resource/aws_lb: Suppress differences for non-applicable attributes ([#4032](https://github.com/terraform-providers/terraform-provider-aws/issues/4032)) +* resource/aws_rds_cluster_instance: Prevent crash on importing non-cluster instances ([#3961](https://github.com/terraform-providers/terraform-provider-aws/issues/3961)) +* resource/aws_route53_record: Fix ListResourceRecordSet pagination ([#3900](https://github.com/terraform-providers/terraform-provider-aws/issues/3900)) + +## 1.13.0 (March 28, 2018) + +NOTES: + +This release is happening outside the normal release schedule to accomodate a crash fix for the `aws_lb_target_group` resource. It appears an ELBv2 service update rolling out currently is the root cause. The potential for this crash has been present since the initial resource in Terraform 0.7.7 and all versions of the AWS provider up to v1.13.0. + +FEATURES: + +* **New Resource:** `aws_appsync_datasource` ([#2758](https://github.com/terraform-providers/terraform-provider-aws/issues/2758)) +* **New Resource:** `aws_waf_regex_match_set` ([#3947](https://github.com/terraform-providers/terraform-provider-aws/issues/3947)) +* **New Resource:** `aws_waf_regex_pattern_set` ([#3913](https://github.com/terraform-providers/terraform-provider-aws/issues/3913)) +* **New Resource:** `aws_waf_rule_group` ([#3898](https://github.com/terraform-providers/terraform-provider-aws/issues/3898)) +* **New Resource:** `aws_wafregional_geo_match_set` ([#3915](https://github.com/terraform-providers/terraform-provider-aws/issues/3915)) +* **New Resource:** `aws_wafregional_rate_based_rule` ([#3871](https://github.com/terraform-providers/terraform-provider-aws/issues/3871)) +* **New Resource:** `aws_wafregional_regex_match_set` ([#3950](https://github.com/terraform-providers/terraform-provider-aws/issues/3950)) +* **New Resource:** `aws_wafregional_regex_pattern_set` ([#3933](https://github.com/terraform-providers/terraform-provider-aws/issues/3933)) +* **New Resource:** `aws_wafregional_rule_group` ([#3948](https://github.com/terraform-providers/terraform-provider-aws/issues/3948)) + +ENHANCEMENTS: + +* provider: Support custom Elasticsearch endpoint ([#3941](https://github.com/terraform-providers/terraform-provider-aws/issues/3941)) +* resource/aws_appsync_graphql_api: Support import ([#3500](https://github.com/terraform-providers/terraform-provider-aws/issues/3500)) +* resource/aws_elasticache_cluster: Allow port to be optional ([#3835](https://github.com/terraform-providers/terraform-provider-aws/issues/3835)) +* resource/aws_elasticache_cluster: Add `replication_group_id` argument ([#3869](https://github.com/terraform-providers/terraform-provider-aws/issues/3869)) +* resource/aws_elasticache_replication_group: Allow port to be optional ([#3835](https://github.com/terraform-providers/terraform-provider-aws/issues/3835)) + +BUG FIXES: + +* resource/aws_autoscaling_group: Fix updating of `service_linked_role` ([#3942](https://github.com/terraform-providers/terraform-provider-aws/issues/3942)) +* resource/aws_autoscaling_group: Properly set empty `enabled_metrics` in the state during read ([#3899](https://github.com/terraform-providers/terraform-provider-aws/issues/3899)) +* resource/aws_autoscaling_policy: Fix conditional logic based on `policy_type` ([#3739](https://github.com/terraform-providers/terraform-provider-aws/issues/3739)) +* resource/aws_batch_compute_environment: Correctly set `compute_resources` in state ([#3824](https://github.com/terraform-providers/terraform-provider-aws/issues/3824)) +* resource/aws_cognito_user_pool: Correctly set `schema` in state ([#3789](https://github.com/terraform-providers/terraform-provider-aws/issues/3789)) +* resource/aws_iam_user_login_profile: Fix `password_length` validation function regression from 1.12.0 ([#3919](https://github.com/terraform-providers/terraform-provider-aws/issues/3919)) +* resource/aws_lb: Store correct state for http2 and ensure attributes are set on create ([#3854](https://github.com/terraform-providers/terraform-provider-aws/issues/3854)) +* resource/aws_lb: Correctly set `subnet_mappings` in state ([#3822](https://github.com/terraform-providers/terraform-provider-aws/issues/3822)) +* resource/aws_lb_listener: Retry CertificateNotFound errors on update for IAM eventual consistency ([#3901](https://github.com/terraform-providers/terraform-provider-aws/issues/3901)) +* resource/aws_lb_target_group: Prevent crash from missing matcher during read ([#3954](https://github.com/terraform-providers/terraform-provider-aws/issues/3954)) +* resource/aws_security_group: Retry read on creation for EC2 eventual consistency ([#3892](https://github.com/terraform-providers/terraform-provider-aws/issues/3892)) + + +## 1.12.0 (March 23, 2018) + +NOTES: + +* provider: For resources implementing the IAM policy equivalence library (https://github.com/jen20/awspolicyequivalence/) on an attribute via `suppressEquivalentAwsPolicyDiffs`, the dependency has been updated, which should mark additional IAM policies as equivalent. ([#3832](https://github.com/terraform-providers/terraform-provider-aws/issues/3832)) + +FEATURES: + +* **New Resource:** `aws_kms_grant` ([#3038](https://github.com/terraform-providers/terraform-provider-aws/issues/3038)) +* **New Resource:** `aws_waf_geo_match_set` ([#3275](https://github.com/terraform-providers/terraform-provider-aws/issues/3275)) +* **New Resource:** `aws_wafregional_rule` ([#3756](https://github.com/terraform-providers/terraform-provider-aws/issues/3756)) +* **New Resource:** `aws_wafregional_size_constraint_set` ([#3796](https://github.com/terraform-providers/terraform-provider-aws/issues/3796)) +* **New Resource:** `aws_wafregional_sql_injection_match_set` ([#1013](https://github.com/terraform-providers/terraform-provider-aws/issues/1013)) +* **New Resource:** `aws_wafregional_web_acl` ([#3754](https://github.com/terraform-providers/terraform-provider-aws/issues/3754)) +* **New Resource:** `aws_wafregional_web_acl_association` ([#3755](https://github.com/terraform-providers/terraform-provider-aws/issues/3755)) +* **New Resource:** `aws_wafregional_xss_match_set` ([#1014](https://github.com/terraform-providers/terraform-provider-aws/issues/1014)) + +ENHANCEMENTS: + +* provider: Treat IAM policies with account ID principals as equivalent to IAM account root ARN ([#3832](https://github.com/terraform-providers/terraform-provider-aws/issues/3832)) +* provider: Treat additional IAM policy scenarios with empty principal trees as equivalent ([#3832](https://github.com/terraform-providers/terraform-provider-aws/issues/3832)) +* resource/aws_acm_certificate: Retry on ResourceInUseException during deletion for eventual consistency ([#3868](https://github.com/terraform-providers/terraform-provider-aws/issues/3868)) +* resource/aws_api_gateway_rest_api: Add support for content encoding ([#3642](https://github.com/terraform-providers/terraform-provider-aws/issues/3642)) +* resource/aws_autoscaling_group: Add `service_linked_role_arn` argument ([#3812](https://github.com/terraform-providers/terraform-provider-aws/issues/3812)) +* resource/aws_cloudfront_distribution: Validate origin `domain_name` and `origin_id` at plan time ([#3767](https://github.com/terraform-providers/terraform-provider-aws/issues/3767)) +* resource/aws_eip: Support configurable timeouts ([#3769](https://github.com/terraform-providers/terraform-provider-aws/issues/3769)) +* resource/aws_elasticache_cluster: Support plan time validation of az_mode ([#3857](https://github.com/terraform-providers/terraform-provider-aws/issues/3857)) +* resource/aws_elasticache_cluster: Support plan time validation of node_type requiring VPC for cache.t2 instances ([#3857](https://github.com/terraform-providers/terraform-provider-aws/issues/3857)) +* resource/aws_elasticache_cluster: Support plan time validation of num_cache_nodes > 1 for redis ([#3857](https://github.com/terraform-providers/terraform-provider-aws/issues/3857)) +* resource/aws_elasticache_cluster: ForceNew on node_type changes for memcached engine ([#3857](https://github.com/terraform-providers/terraform-provider-aws/issues/3857)) +* resource/aws_elasticache_cluster: ForceNew on engine_version downgrades ([#3857](https://github.com/terraform-providers/terraform-provider-aws/issues/3857)) +* resource/aws_emr_cluster: Add step support ([#3673](https://github.com/terraform-providers/terraform-provider-aws/issues/3673)) +* resource/aws_instance: Support optionally fetching encrypted Windows password data ([#2219](https://github.com/terraform-providers/terraform-provider-aws/issues/2219)) +* resource/aws_launch_configuration: Validate `user_data` length during plan ([#2973](https://github.com/terraform-providers/terraform-provider-aws/issues/2973)) +* resource/aws_lb_target_group: Validate health check threshold for TCP protocol during plan ([#3782](https://github.com/terraform-providers/terraform-provider-aws/issues/3782)) +* resource/aws_security_group: Add arn attribute ([#3751](https://github.com/terraform-providers/terraform-provider-aws/issues/3751)) +* resource/aws_ses_domain_identity: Support trailing period in domain name ([#3840](https://github.com/terraform-providers/terraform-provider-aws/issues/3840)) +* resource/aws_sqs_queue: Support lack of ListQueueTags for all non-standard AWS implementations ([#3794](https://github.com/terraform-providers/terraform-provider-aws/issues/3794)) +* resource/aws_ssm_document: Add `document_format` argument to support YAML ([#3814](https://github.com/terraform-providers/terraform-provider-aws/issues/3814)) +* resource/aws_s3_bucket_object: New `content_base64` argument allows uploading raw binary data created in-memory, rather than reading from disk as with `source`. ([#3788](https://github.com/terraform-providers/terraform-provider-aws/issues/3788)) + +BUG FIXES: + +* resource/aws_api_gateway_client_certificate: Export `*_date` fields correctly ([#3805](https://github.com/terraform-providers/terraform-provider-aws/issues/3805)) +* resource/aws_cognito_user_pool: Detect `auto_verified_attributes` changes ([#3786](https://github.com/terraform-providers/terraform-provider-aws/issues/3786)) +* resource/aws_cognito_user_pool_client: Fix `callback_urls` updates ([#3404](https://github.com/terraform-providers/terraform-provider-aws/issues/3404)) +* resource/aws_db_instance: Support `incompatible-parameters` and `storage-full` state ([#3708](https://github.com/terraform-providers/terraform-provider-aws/issues/3708)) +* resource/aws_dynamodb_table: Update and validate attributes correctly ([#3194](https://github.com/terraform-providers/terraform-provider-aws/issues/3194)) +* resource/aws_ecs_task_definition: Correctly read `volume` attribute into Terraform state ([#3823](https://github.com/terraform-providers/terraform-provider-aws/issues/3823)) +* resource/aws_kinesis_firehose_delivery_stream: Prevent crash on malformed ID for import ([#3834](https://github.com/terraform-providers/terraform-provider-aws/issues/3834)) +* resource/aws_lambda_function: Only retry IAM eventual consistency errors for one minute ([#3765](https://github.com/terraform-providers/terraform-provider-aws/issues/3765)) +* resource/aws_ssm_association: Prevent AssociationDoesNotExist error ([#3776](https://github.com/terraform-providers/terraform-provider-aws/issues/3776)) +* resource/aws_vpc_endpoint: Prevent perpertual diff in non-standard partitions ([#3317](https://github.com/terraform-providers/terraform-provider-aws/issues/3317)) + +## 1.11.0 (March 09, 2018) + +FEATURES: + +* **New Data Source:** `aws_kms_key` ([#2224](https://github.com/terraform-providers/terraform-provider-aws/issues/2224)) +* **New Resource:** `aws_organizations_organization` ([#903](https://github.com/terraform-providers/terraform-provider-aws/issues/903)) +* **New Resource:** `aws_iot_thing` ([#3521](https://github.com/terraform-providers/terraform-provider-aws/issues/3521)) + +ENHANCEMENTS: + +* resource/aws_api_gateway_authorizer: Support COGNITO_USER_POOLS type ([#3156](https://github.com/terraform-providers/terraform-provider-aws/issues/3156)) +* resource/aws_cloud9_environment_ec2: Retry creation for IAM eventual consistency ([#3651](https://github.com/terraform-providers/terraform-provider-aws/issues/3651)) +* resource/aws_cloudfront_distribution: Make `default_ttl`, `max_ttl`, and `min_ttl` arguments optional ([#3571](https://github.com/terraform-providers/terraform-provider-aws/issues/3571)) +* resource/aws_dms_endpoint: Add aurora-postgresql as a target ([#2615](https://github.com/terraform-providers/terraform-provider-aws/issues/2615)) +* resource/aws_dynamodb_table: Support Server Side Encryption ([#3303](https://github.com/terraform-providers/terraform-provider-aws/issues/3303)) +* resource/aws_elastic_beanstalk_environment: Support modifying `tags` ([#3513](https://github.com/terraform-providers/terraform-provider-aws/issues/3513)) +* resource/aws_emr_cluster: Add Kerberos support ([#3553](https://github.com/terraform-providers/terraform-provider-aws/issues/3553)) +* resource/aws_iam_account_alias: Improve error messages to include API errors ([#3590](https://github.com/terraform-providers/terraform-provider-aws/issues/3590)) +* resource/aws_iam_user_policy: Add support for import ([#3198](https://github.com/terraform-providers/terraform-provider-aws/issues/3198)) +* resource/aws_lb: Add `enable_cross_zone_load_balancing` argument for NLBs ([#3537](https://github.com/terraform-providers/terraform-provider-aws/issues/3537)) +* resource/aws_lb: Add `enable_http2` argument for ALBs ([#3609](https://github.com/terraform-providers/terraform-provider-aws/issues/3609)) +* resource/aws_route: Add configurable timeouts ([#3639](https://github.com/terraform-providers/terraform-provider-aws/issues/3639)) +* resource/aws_security_group: Add configurable timeouts ([#3599](https://github.com/terraform-providers/terraform-provider-aws/issues/3599)) +* resource/aws_spot_fleet_request: Add `load_balancers` and `target_group_arns` arguments ([#2564](https://github.com/terraform-providers/terraform-provider-aws/issues/2564)) +* resource/aws_ssm_parameter: Add `allowed_pattern`, `description`, and `tags` arguments ([#1520](https://github.com/terraform-providers/terraform-provider-aws/issues/1520)) +* resource/aws_ssm_parameter: Allow `key_id` updates ([#1520](https://github.com/terraform-providers/terraform-provider-aws/issues/1520)) + +BUG FIXES: + +* data-source/aws_db_instance: Prevent crash with EC2 Classic ([#3619](https://github.com/terraform-providers/terraform-provider-aws/issues/3619)) +* data-source/aws_vpc_endpoint_service: Fix aws-us-gov partition handling ([#3514](https://github.com/terraform-providers/terraform-provider-aws/issues/3514)) +* resource/aws_api_gateway_vpc_link: Ensure `target_arns` is properly read ([#3569](https://github.com/terraform-providers/terraform-provider-aws/issues/3569)) +* resource/aws_batch_compute_environment: Fix `state` updates ([#3508](https://github.com/terraform-providers/terraform-provider-aws/issues/3508)) +* resource/aws_ebs_snapshot: Prevent crash with outside snapshot deletion ([#3462](https://github.com/terraform-providers/terraform-provider-aws/issues/3462)) +* resource/aws_ecs_service: Prevent crash when importing non-existent service ([#3672](https://github.com/terraform-providers/terraform-provider-aws/issues/3672)) +* resource/aws_eip_association: Prevent deletion error InvalidAssociationID.NotFound ([#3653](https://github.com/terraform-providers/terraform-provider-aws/issues/3653)) +* resource/aws_instance: Ensure at least one security group is being attached when modifying vpc_security_group_ids ([#2850](https://github.com/terraform-providers/terraform-provider-aws/issues/2850)) +* resource/aws_lambda_function: Allow PutFunctionConcurrency retries on creation ([#3570](https://github.com/terraform-providers/terraform-provider-aws/issues/3570)) +* resource/aws_spot_instance_request: Retry for 1 minute instead of 15 seconds for IAM eventual consistency ([#3561](https://github.com/terraform-providers/terraform-provider-aws/issues/3561)) +* resource/aws_ssm_activation: Prevent crash with expiration_date ([#3597](https://github.com/terraform-providers/terraform-provider-aws/issues/3597)) + ## 1.10.0 (February 24, 2018) NOTES: diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/arn.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/arn.go deleted file mode 100644 index de72a23eb70e..000000000000 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/arn.go +++ /dev/null @@ -1,26 +0,0 @@ -package aws - -import ( - "github.com/aws/aws-sdk-go/aws/arn" - "github.com/aws/aws-sdk-go/service/iam" -) - -func arnString(partition, region, service, accountId, resource string) string { - return arn.ARN{ - Partition: partition, - Region: region, - Service: service, - AccountID: accountId, - Resource: resource, - }.String() -} - -// See http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#arn-syntax-iam -func iamArnString(partition, accountId, resource string) string { - return arnString( - partition, - "", - iam.ServiceName, - accountId, - resource) -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/cloudfront_distribution_configuration_structure.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/cloudfront_distribution_configuration_structure.go index 64c440247b92..a4f3f9863040 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/cloudfront_distribution_configuration_structure.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/cloudfront_distribution_configuration_structure.go @@ -204,6 +204,9 @@ func defaultCacheBehaviorHash(v interface{}) int { buf.WriteString(fmt.Sprintf("%s-", m["target_origin_id"].(string))) buf.WriteString(fmt.Sprintf("%d-", forwardedValuesHash(m["forwarded_values"].(*schema.Set).List()[0].(map[string]interface{})))) buf.WriteString(fmt.Sprintf("%d-", m["min_ttl"].(int))) + if d, ok := m["field_level_encryption_id"]; ok && d.(string) != "" { + buf.WriteString(fmt.Sprintf("%s-", d.(string))) + } if d, ok := m["trusted_signers"]; ok { for _, e := range sortInterfaceSlice(d.([]interface{})) { buf.WriteString(fmt.Sprintf("%s-", e.(string))) @@ -266,14 +269,16 @@ func flattenCacheBehaviors(cbs *cloudfront.CacheBehaviors) *schema.Set { func expandCacheBehavior(m map[string]interface{}) *cloudfront.CacheBehavior { cb := &cloudfront.CacheBehavior{ - Compress: aws.Bool(m["compress"].(bool)), - ViewerProtocolPolicy: aws.String(m["viewer_protocol_policy"].(string)), - TargetOriginId: aws.String(m["target_origin_id"].(string)), - ForwardedValues: expandForwardedValues(m["forwarded_values"].(*schema.Set).List()[0].(map[string]interface{})), - MinTTL: aws.Int64(int64(m["min_ttl"].(int))), - MaxTTL: aws.Int64(int64(m["max_ttl"].(int))), - DefaultTTL: aws.Int64(int64(m["default_ttl"].(int))), + Compress: aws.Bool(m["compress"].(bool)), + FieldLevelEncryptionId: aws.String(m["field_level_encryption_id"].(string)), + ViewerProtocolPolicy: aws.String(m["viewer_protocol_policy"].(string)), + TargetOriginId: aws.String(m["target_origin_id"].(string)), + ForwardedValues: expandForwardedValues(m["forwarded_values"].(*schema.Set).List()[0].(map[string]interface{})), + DefaultTTL: aws.Int64(int64(m["default_ttl"].(int))), + MaxTTL: aws.Int64(int64(m["max_ttl"].(int))), + MinTTL: aws.Int64(int64(m["min_ttl"].(int))), } + if v, ok := m["trusted_signers"]; ok { cb.TrustedSigners = expandTrustedSigners(v.([]interface{})) } else { @@ -303,6 +308,7 @@ func flattenCacheBehavior(cb *cloudfront.CacheBehavior) map[string]interface{} { m := make(map[string]interface{}) m["compress"] = *cb.Compress + m["field_level_encryption_id"] = aws.StringValue(cb.FieldLevelEncryptionId) m["viewer_protocol_policy"] = *cb.ViewerProtocolPolicy m["target_origin_id"] = *cb.TargetOriginId m["forwarded_values"] = schema.NewSet(forwardedValuesHash, []interface{}{flattenForwardedValues(cb.ForwardedValues)}) @@ -345,6 +351,9 @@ func cacheBehaviorHash(v interface{}) int { buf.WriteString(fmt.Sprintf("%s-", m["target_origin_id"].(string))) buf.WriteString(fmt.Sprintf("%d-", forwardedValuesHash(m["forwarded_values"].(*schema.Set).List()[0].(map[string]interface{})))) buf.WriteString(fmt.Sprintf("%d-", m["min_ttl"].(int))) + if d, ok := m["field_level_encryption_id"]; ok && d.(string) != "" { + buf.WriteString(fmt.Sprintf("%s-", d.(string))) + } if d, ok := m["trusted_signers"]; ok { for _, e := range sortInterfaceSlice(d.([]interface{})) { buf.WriteString(fmt.Sprintf("%s-", e.(string))) diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/config.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/config.go index fa00b95a3321..71833acf7427 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/config.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/config.go @@ -64,10 +64,12 @@ import ( "github.com/aws/aws-sdk-go/service/kinesis" "github.com/aws/aws-sdk-go/service/kms" "github.com/aws/aws-sdk-go/service/lambda" + "github.com/aws/aws-sdk-go/service/lexmodelbuildingservice" "github.com/aws/aws-sdk-go/service/lightsail" "github.com/aws/aws-sdk-go/service/mediastore" "github.com/aws/aws-sdk-go/service/mq" "github.com/aws/aws-sdk-go/service/opsworks" + "github.com/aws/aws-sdk-go/service/organizations" "github.com/aws/aws-sdk-go/service/rds" "github.com/aws/aws-sdk-go/service/redshift" "github.com/aws/aws-sdk-go/service/route53" @@ -118,6 +120,7 @@ type Config struct { Ec2Endpoint string EcsEndpoint string EcrEndpoint string + EsEndpoint string ElbEndpoint string IamEndpoint string KinesisEndpoint string @@ -194,6 +197,7 @@ type AWSClient struct { lightsailconn *lightsail.Lightsail mqconn *mq.MQ opsworksconn *opsworks.OpsWorks + organizationsconn *organizations.Organizations glacierconn *glacier.Glacier guarddutyconn *guardduty.GuardDuty codebuildconn *codebuild.CodeBuild @@ -212,6 +216,7 @@ type AWSClient struct { dxconn *directconnect.DirectConnect mediastoreconn *mediastore.MediaStore appsyncconn *appsync.AppSync + lexmodelconn *lexmodelbuildingservice.LexModelBuildingService } func (c *AWSClient) S3() *s3.S3 { @@ -274,16 +279,27 @@ func (c *Config) Client() (interface{}, error) { cp, err := creds.Get() if err != nil { if awsErr, ok := err.(awserr.Error); ok && awsErr.Code() == "NoCredentialProviders" { - // If a profile wasn't specified then error out + // If a profile wasn't specified, the session may still be able to resolve credentials from shared config. if c.Profile == "" { - return nil, errors.New(`No valid credential sources found for AWS Provider. - Please see https://terraform.io/docs/providers/aws/index.html for more information on - providing credentials for the AWS Provider`) + sess, err := session.NewSession() + if err != nil { + return nil, errors.New(`No valid credential sources found for AWS Provider. + Please see https://terraform.io/docs/providers/aws/index.html for more information on + providing credentials for the AWS Provider`) + } + _, err = sess.Config.Credentials.Get() + if err != nil { + return nil, errors.New(`No valid credential sources found for AWS Provider. + Please see https://terraform.io/docs/providers/aws/index.html for more information on + providing credentials for the AWS Provider`) + } + log.Printf("[INFO] Using session-derived AWS Auth") + opt.Config.Credentials = sess.Config.Credentials + } else { + log.Printf("[INFO] AWS Auth using Profile: %q", c.Profile) + opt.Profile = c.Profile + opt.SharedConfigState = session.SharedConfigEnable } - // add the profile and enable share config file usage - log.Printf("[INFO] AWS Auth using Profile: %q", c.Profile) - opt.Profile = c.Profile - opt.SharedConfigState = session.SharedConfigEnable } else { return nil, fmt.Errorf("Error loading credentials for AWS Provider: %s", err) } @@ -345,6 +361,7 @@ func (c *Config) Client() (interface{}, error) { awsEcrSess := sess.Copy(&aws.Config{Endpoint: aws.String(c.EcrEndpoint)}) awsEcsSess := sess.Copy(&aws.Config{Endpoint: aws.String(c.EcsEndpoint)}) awsElbSess := sess.Copy(&aws.Config{Endpoint: aws.String(c.ElbEndpoint)}) + awsEsSess := sess.Copy(&aws.Config{Endpoint: aws.String(c.EsEndpoint)}) awsIamSess := sess.Copy(&aws.Config{Endpoint: aws.String(c.IamEndpoint)}) awsLambdaSess := sess.Copy(&aws.Config{Endpoint: aws.String(c.LambdaEndpoint)}) awsKinesisSess := sess.Copy(&aws.Config{Endpoint: aws.String(c.KinesisEndpoint)}) @@ -431,7 +448,7 @@ func (c *Config) Client() (interface{}, error) { client.elbconn = elb.New(awsElbSess) client.elbv2conn = elbv2.New(awsElbSess) client.emrconn = emr.New(sess) - client.esconn = elasticsearch.New(sess) + client.esconn = elasticsearch.New(awsEsSess) client.firehoseconn = firehose.New(sess) client.inspectorconn = inspector.New(sess) client.gameliftconn = gamelift.New(sess) @@ -441,9 +458,11 @@ func (c *Config) Client() (interface{}, error) { client.kinesisconn = kinesis.New(awsKinesisSess) client.kmsconn = kms.New(awsKmsSess) client.lambdaconn = lambda.New(awsLambdaSess) + client.lexmodelconn = lexmodelbuildingservice.New(sess) client.lightsailconn = lightsail.New(sess) client.mqconn = mq.New(sess) client.opsworksconn = opsworks.New(sess) + client.organizationsconn = organizations.New(sess) client.r53conn = route53.New(r53Sess) client.rdsconn = rds.New(awsRdsSess) client.redshiftconn = redshift.New(sess) diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_ami.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_ami.go index 7a1fbecd2b0c..686b6c731e97 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_ami.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_ami.go @@ -9,6 +9,7 @@ import ( "github.com/aws/aws-sdk-go/service/ec2" "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func dataSourceAwsAmi() *schema.Resource { @@ -27,7 +28,7 @@ func dataSourceAwsAmi() *schema.Resource { Type: schema.TypeString, Optional: true, ForceNew: true, - ValidateFunc: validateNameRegex, + ValidateFunc: validation.ValidateRegexp, }, "most_recent": { Type: schema.TypeBool, @@ -432,14 +433,3 @@ func amiProductCodesHash(v interface{}) int { buf.WriteString(fmt.Sprintf("%s-", m["product_code_type"].(string))) return hashcode.String(buf.String()) } - -func validateNameRegex(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - - if _, err := regexp.Compile(value); err != nil { - errors = append(errors, fmt.Errorf( - "%q contains an invalid regular expression: %s", - k, err)) - } - return -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_ami_ids.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_ami_ids.go index 73ed09d28a2f..af9e11ca2a2e 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_ami_ids.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_ami_ids.go @@ -8,6 +8,7 @@ import ( "github.com/aws/aws-sdk-go/service/ec2" "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func dataSourceAwsAmiIds() *schema.Resource { @@ -26,7 +27,7 @@ func dataSourceAwsAmiIds() *schema.Resource { Type: schema.TypeString, Optional: true, ForceNew: true, - ValidateFunc: validateNameRegex, + ValidateFunc: validation.ValidateRegexp, }, "owners": { Type: schema.TypeList, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_availability_zones.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_availability_zones.go index 3cdc3221e02d..3a6f3876433d 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_availability_zones.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_availability_zones.go @@ -9,6 +9,7 @@ import ( "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/service/ec2" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func dataSourceAwsAvailabilityZones() *schema.Resource { @@ -22,9 +23,14 @@ func dataSourceAwsAvailabilityZones() *schema.Resource { Elem: &schema.Schema{Type: schema.TypeString}, }, "state": { - Type: schema.TypeString, - Optional: true, - ValidateFunc: validateStateType, + Type: schema.TypeString, + Optional: true, + ValidateFunc: validation.StringInSlice([]string{ + ec2.AvailabilityZoneStateAvailable, + ec2.AvailabilityZoneStateInformation, + ec2.AvailabilityZoneStateImpaired, + ec2.AvailabilityZoneStateUnavailable, + }, false), }, }, } @@ -66,21 +72,3 @@ func dataSourceAwsAvailabilityZonesRead(d *schema.ResourceData, meta interface{} return nil } - -func validateStateType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - - validState := map[string]bool{ - "available": true, - "information": true, - "impaired": true, - "unavailable": true, - } - - if !validState[value] { - errors = append(errors, fmt.Errorf( - "%q contains an invalid Availability Zone state %q. Valid states are: %q, %q, %q and %q.", - k, value, "available", "information", "impaired", "unavailable")) - } - return -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_billing_service_account.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_billing_service_account.go index e1425c4ffe51..03ec2f7c44e3 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_billing_service_account.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_billing_service_account.go @@ -1,8 +1,7 @@ package aws import ( - "fmt" - + "github.com/aws/aws-sdk-go/aws/arn" "github.com/hashicorp/terraform/helper/schema" ) @@ -24,7 +23,13 @@ func dataSourceAwsBillingServiceAccount() *schema.Resource { func dataSourceAwsBillingServiceAccountRead(d *schema.ResourceData, meta interface{}) error { d.SetId(billingAccountId) - d.Set("arn", fmt.Sprintf("arn:%s:iam::%s:root", meta.(*AWSClient).partition, billingAccountId)) + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "iam", + AccountID: billingAccountId, + Resource: "root", + }.String() + d.Set("arn", arn) return nil } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_cloudtrail_service_account.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_cloudtrail_service_account.go index b7129bbfa97f..33574a033f3f 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_cloudtrail_service_account.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_cloudtrail_service_account.go @@ -3,6 +3,7 @@ package aws import ( "fmt" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/hashicorp/terraform/helper/schema" ) @@ -51,7 +52,14 @@ func dataSourceAwsCloudTrailServiceAccountRead(d *schema.ResourceData, meta inte if accid, ok := cloudTrailServiceAccountPerRegionMap[region]; ok { d.SetId(accid) - d.Set("arn", iamArnString(meta.(*AWSClient).partition, accid, "root")) + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "iam", + AccountID: accid, + Resource: "root", + }.String() + d.Set("arn", arn) + return nil } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_db_instance.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_db_instance.go index 4e93681be06b..bf8df80ec929 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_db_instance.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_db_instance.go @@ -252,7 +252,12 @@ func dataSourceAwsDbInstanceRead(d *schema.ResourceData, meta interface{}) error return fmt.Errorf("[DEBUG] Error setting db_security_groups attribute: %#v, error: %#v", dbSecurityGroups, err) } - d.Set("db_subnet_group", dbInstance.DBSubnetGroup.DBSubnetGroupName) + if dbInstance.DBSubnetGroup != nil { + d.Set("db_subnet_group", dbInstance.DBSubnetGroup.DBSubnetGroupName) + } else { + d.Set("db_subnet_group", "") + } + d.Set("db_instance_port", dbInstance.DbInstancePort) d.Set("engine", dbInstance.Engine) d.Set("engine_version", dbInstance.EngineVersion) diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_dynamodb_table.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_dynamodb_table.go index 1845b7c361f3..0df305d5133a 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_dynamodb_table.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_dynamodb_table.go @@ -167,6 +167,20 @@ func dataSourceAwsDynamoDbTable() *schema.Resource { Type: schema.TypeInt, Computed: true, }, + "server_side_encryption": { + Type: schema.TypeList, + Optional: true, + Computed: true, + MaxItems: 1, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "enabled": { + Type: schema.TypeBool, + Computed: true, + }, + }, + }, + }, }, } } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_elastic_beanstalk_solution_stack.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_elastic_beanstalk_solution_stack.go index 962aebf10849..b41f67568d6f 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_elastic_beanstalk_solution_stack.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_elastic_beanstalk_solution_stack.go @@ -7,6 +7,7 @@ import ( "github.com/aws/aws-sdk-go/service/elasticbeanstalk" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func dataSourceAwsElasticBeanstalkSolutionStack() *schema.Resource { @@ -18,7 +19,7 @@ func dataSourceAwsElasticBeanstalkSolutionStack() *schema.Resource { Type: schema.TypeString, Required: true, ForceNew: true, - ValidateFunc: validateSolutionStackNameRegex, + ValidateFunc: validation.ValidateRegexp, }, "most_recent": { Type: schema.TypeBool, @@ -93,14 +94,3 @@ func solutionStackDescriptionAttributes(d *schema.ResourceData, solutionStack *s d.Set("name", solutionStack) return nil } - -func validateSolutionStackNameRegex(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - - if _, err := regexp.Compile(value); err != nil { - errors = append(errors, fmt.Errorf( - "%q contains an invalid regular expression: %s", - k, err)) - } - return -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_elasticache_cluster.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_elasticache_cluster.go index b50c65afb24b..217530767c51 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_elasticache_cluster.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_elasticache_cluster.go @@ -6,6 +6,7 @@ import ( "strings" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/service/elasticache" "github.com/hashicorp/terraform/helper/schema" ) @@ -212,10 +213,13 @@ func dataSourceAwsElastiCacheClusterRead(d *schema.ResourceData, meta interface{ return err } - arn, err := buildECARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region) - if err != nil { - log.Printf("[DEBUG] Error building ARN for ElastiCache Cluster %s", *cluster.CacheClusterId) - } + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "elasticache", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("cluster:%s", d.Id()), + }.String() d.Set("arn", arn) tagResp, err := conn.ListTagsForResource(&elasticache.ListTagsForResourceInput{ diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_elb_service_account.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_elb_service_account.go index 795b41bd6749..639ad733922a 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_elb_service_account.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_elb_service_account.go @@ -3,6 +3,7 @@ package aws import ( "fmt" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/hashicorp/terraform/helper/schema" ) @@ -53,8 +54,13 @@ func dataSourceAwsElbServiceAccountRead(d *schema.ResourceData, meta interface{} if accid, ok := elbAccountIdPerRegionMap[region]; ok { d.SetId(accid) - - d.Set("arn", fmt.Sprintf("arn:%s:iam::%s:root", meta.(*AWSClient).partition, accid)) + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "iam", + AccountID: accid, + Resource: "root", + }.String() + d.Set("arn", arn) return nil } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_iam_policy_document.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_iam_policy_document.go index 0c7de6448552..4f5c644317b0 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_iam_policy_document.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_iam_policy_document.go @@ -2,12 +2,12 @@ package aws import ( "encoding/json" - "fmt" "strconv" "strings" "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) var dataSourceAwsIamPolicyDocumentVarReplacer = strings.NewReplacer("&{", "${") @@ -47,18 +47,10 @@ func dataSourceAwsIamPolicyDocument() *schema.Resource { Optional: true, }, "effect": { - Type: schema.TypeString, - Optional: true, - Default: "Allow", - ValidateFunc: func(v interface{}, k string) (ws []string, es []error) { - switch v.(string) { - case "Allow", "Deny": - return - default: - es = append(es, fmt.Errorf("%q must be either \"Allow\" or \"Deny\"", k)) - return - } - }, + Type: schema.TypeString, + Optional: true, + Default: "Allow", + ValidateFunc: validation.StringInSlice([]string{"Allow", "Deny"}, false), }, "actions": setOfString, "not_actions": setOfString, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_iam_role.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_iam_role.go index 7de37708b240..fe4f6f657c47 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_iam_role.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_iam_role.go @@ -2,6 +2,7 @@ package aws import ( "fmt" + "github.com/hashicorp/terraform/helper/schema" ) @@ -53,6 +54,10 @@ func dataSourceAwsIAMRole() *schema.Resource { Type: schema.TypeString, Computed: true, }, + "max_session_duration": { + Type: schema.TypeInt, + Computed: true, + }, }, } } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_iam_server_certificate.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_iam_server_certificate.go index 1ec63c52aad7..29321ef43be7 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_iam_server_certificate.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_iam_server_certificate.go @@ -10,6 +10,7 @@ import ( "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/service/iam" "github.com/hashicorp/errwrap" + "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" ) @@ -24,28 +25,15 @@ func dataSourceAwsIAMServerCertificate() *schema.Resource { Computed: true, ForceNew: true, ConflictsWith: []string{"name_prefix"}, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 128 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 128 characters", k)) - } - return - }, + ValidateFunc: validateMaxLength(128), }, "name_prefix": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 102 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 102 characters, name is limited to 128", k)) - } - return - }, + Type: schema.TypeString, + Optional: true, + ForceNew: true, + ConflictsWith: []string{"name"}, + ValidateFunc: validateMaxLength(128 - resource.UniqueIDSuffixLength), }, "latest": { @@ -114,7 +102,7 @@ func dataSourceAwsIAMServerCertificateRead(d *schema.ResourceData, meta interfac } } - var metadatas = []*iam.ServerCertificateMetadata{} + var metadatas []*iam.ServerCertificateMetadata log.Printf("[DEBUG] Reading IAM Server Certificate") err := iamconn.ListServerCertificatesPages(&iam.ListServerCertificatesInput{}, func(p *iam.ListServerCertificatesOutput, lastPage bool) bool { for _, cert := range p.ServerCertificateMetadataList { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_instance.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_instance.go index fcf7d76531e6..23a8fac24c32 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_instance.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_instance.go @@ -50,6 +50,15 @@ func dataSourceAwsInstance() *schema.Resource { Type: schema.TypeString, Computed: true, }, + "get_password_data": { + Type: schema.TypeBool, + Optional: true, + Default: false, + }, + "password_data": { + Type: schema.TypeString, + Computed: true, + }, "public_dns": { Type: schema.TypeString, Computed: true, @@ -280,7 +289,19 @@ func dataSourceAwsInstanceRead(d *schema.ResourceData, meta interface{}) error { } log.Printf("[DEBUG] aws_instance - Single Instance ID found: %s", *instance.InstanceId) - return instanceDescriptionAttributes(d, instance, conn) + if err := instanceDescriptionAttributes(d, instance, conn); err != nil { + return err + } + + if d.Get("get_password_data").(bool) { + passwordData, err := getAwsEc2InstancePasswordData(*instance.InstanceId, conn) + if err != nil { + return err + } + d.Set("password_data", passwordData) + } + + return nil } // Populate instance attribute fields with the returned instance diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_kms_key.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_kms_key.go new file mode 100644 index 000000000000..35c231ead105 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_kms_key.go @@ -0,0 +1,110 @@ +package aws + +import ( + "fmt" + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/kms" + "github.com/hashicorp/terraform/helper/schema" + "time" +) + +func dataSourceAwsKmsKey() *schema.Resource { + return &schema.Resource{ + Read: dataSourceAwsKmsKeyRead, + Schema: map[string]*schema.Schema{ + "key_id": { + Type: schema.TypeString, + Required: true, + ValidateFunc: validateKmsKey, + }, + "grant_tokens": { + Type: schema.TypeList, + Optional: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "arn": { + Type: schema.TypeString, + Computed: true, + }, + "aws_account_id": { + Type: schema.TypeString, + Computed: true, + }, + "creation_date": { + Type: schema.TypeString, + Computed: true, + }, + "deletion_date": { + Type: schema.TypeString, + Computed: true, + }, + "description": { + Type: schema.TypeString, + Computed: true, + }, + "enabled": { + Type: schema.TypeBool, + Computed: true, + }, + "expiration_model": { + Type: schema.TypeString, + Computed: true, + }, + "key_manager": { + Type: schema.TypeString, + Computed: true, + }, + "key_state": { + Type: schema.TypeString, + Computed: true, + }, + "key_usage": { + Type: schema.TypeString, + Computed: true, + }, + "origin": { + Type: schema.TypeString, + Computed: true, + }, + "valid_to": { + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func dataSourceAwsKmsKeyRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).kmsconn + keyId := d.Get("key_id") + var grantTokens []*string + if v, ok := d.GetOk("grant_tokens"); ok { + grantTokens = aws.StringSlice(v.([]string)) + } + input := &kms.DescribeKeyInput{ + KeyId: aws.String(keyId.(string)), + GrantTokens: grantTokens, + } + output, err := conn.DescribeKey(input) + if err != nil { + return fmt.Errorf("error while describing key [%s]: %s", keyId, err) + } + d.SetId(aws.StringValue(output.KeyMetadata.KeyId)) + d.Set("arn", output.KeyMetadata.Arn) + d.Set("aws_account_id", output.KeyMetadata.AWSAccountId) + d.Set("creation_date", aws.TimeValue(output.KeyMetadata.CreationDate).Format(time.RFC3339)) + if output.KeyMetadata.DeletionDate != nil { + d.Set("deletion_date", aws.TimeValue(output.KeyMetadata.DeletionDate).Format(time.RFC3339)) + } + d.Set("description", output.KeyMetadata.Description) + d.Set("enabled", output.KeyMetadata.Enabled) + d.Set("expiration_model", output.KeyMetadata.ExpirationModel) + d.Set("key_manager", output.KeyMetadata.KeyManager) + d.Set("key_state", output.KeyMetadata.KeyState) + d.Set("key_usage", output.KeyMetadata.KeyUsage) + d.Set("origin", output.KeyMetadata.Origin) + if output.KeyMetadata.ValidTo != nil { + d.Set("valid_to", aws.TimeValue(output.KeyMetadata.ValidTo).Format(time.RFC3339)) + } + return nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_redshift_service_account.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_redshift_service_account.go index d5db68d55023..b9a39c28af68 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_redshift_service_account.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_redshift_service_account.go @@ -3,6 +3,7 @@ package aws import ( "fmt" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/hashicorp/terraform/helper/schema" ) @@ -51,7 +52,14 @@ func dataSourceAwsRedshiftServiceAccountRead(d *schema.ResourceData, meta interf if accid, ok := redshiftServiceAccountPerRegionMap[region]; ok { d.SetId(accid) - d.Set("arn", iamArnString(meta.(*AWSClient).partition, accid, "user/logs")) + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "iam", + AccountID: accid, + Resource: "user/logs", + }.String() + d.Set("arn", arn) + return nil } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_s3_bucket.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_s3_bucket.go index 1303ae35a67e..6a678a75b5be 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_s3_bucket.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_s3_bucket.go @@ -5,6 +5,7 @@ import ( "log" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/service/s3" "github.com/hashicorp/terraform/helper/schema" ) @@ -63,7 +64,12 @@ func dataSourceAwsS3BucketRead(d *schema.ResourceData, meta interface{}) error { } d.SetId(bucket) - d.Set("arn", fmt.Sprintf("arn:%s:s3:::%s", meta.(*AWSClient).partition, bucket)) + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "s3", + Resource: bucket, + }.String() + d.Set("arn", arn) d.Set("bucket_domain_name", bucketDomainName(bucket)) if err := bucketLocation(d, bucket, conn); err != nil { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_security_group.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_security_group.go index 7402c0ace88a..80207dd1a6ae 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_security_group.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_security_group.go @@ -5,6 +5,7 @@ import ( "log" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/service/ec2" "github.com/hashicorp/terraform/helper/schema" ) @@ -91,8 +92,14 @@ func dataSourceAwsSecurityGroupRead(d *schema.ResourceData, meta interface{}) er d.Set("description", sg.Description) d.Set("vpc_id", sg.VpcId) d.Set("tags", tagsToMap(sg.Tags)) - d.Set("arn", fmt.Sprintf("arn:%s:ec2:%s:%s:security-group/%s", - meta.(*AWSClient).partition, meta.(*AWSClient).region, *sg.OwnerId, *sg.GroupId)) + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "ec2", + Region: meta.(*AWSClient).region, + AccountID: *sg.OwnerId, + Resource: fmt.Sprintf("security-group/%s", *sg.GroupId), + }.String() + d.Set("arn", arn) return nil } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_vpc_endpoint_service.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_vpc_endpoint_service.go index 428747cca61c..62a5d342b52c 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_vpc_endpoint_service.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/data_source_aws_vpc_endpoint_service.go @@ -85,13 +85,23 @@ func dataSourceAwsVpcEndpointServiceRead(d *schema.ResourceData, meta interface{ if err != nil { return fmt.Errorf("Error fetching VPC Endpoint Services: %s", err) } - if resp == nil || len(resp.ServiceDetails) == 0 { + + if resp == nil || len(resp.ServiceNames) == 0 { return fmt.Errorf("no matching VPC Endpoint Service found") } - if len(resp.ServiceDetails) > 1 { + + if len(resp.ServiceNames) > 1 { return fmt.Errorf("multiple VPC Endpoint Services matched; use additional constraints to reduce matches to a single VPC Endpoint Service") } + // Note: AWS Commercial now returns a response with `ServiceNames` and + // `ServiceDetails`, but GovCloud responses only include `ServiceNames` + if len(resp.ServiceDetails) == 0 { + d.SetId(strconv.Itoa(hashcode.String(*resp.ServiceNames[0]))) + d.Set("service_name", resp.ServiceNames[0]) + return nil + } + sd := resp.ServiceDetails[0] serviceName = aws.StringValue(sd.ServiceName) d.SetId(strconv.Itoa(hashcode.String(serviceName))) diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/diff_suppress_funcs.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/diff_suppress_funcs.go index d891708b9187..cc33eab36b44 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/diff_suppress_funcs.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/diff_suppress_funcs.go @@ -85,3 +85,7 @@ func suppressAutoscalingGroupAvailabilityZoneDiffs(k, old, new string, d *schema return false } + +func suppressRoute53ZoneNameWithTrailingDot(k, old, new string, d *schema.ResourceData) bool { + return strings.TrimSuffix(old, ".") == strings.TrimSuffix(new, ".") +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/provider.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/provider.go index 81bd9ffc8775..682ed272fdba 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/provider.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/provider.go @@ -207,6 +207,7 @@ func Provider() terraform.ResourceProvider { "aws_kinesis_stream": dataSourceAwsKinesisStream(), "aws_kms_alias": dataSourceAwsKmsAlias(), "aws_kms_ciphertext": dataSourceAwsKmsCiphertext(), + "aws_kms_key": dataSourceAwsKmsKey(), "aws_kms_secret": dataSourceAwsKmsSecret(), "aws_nat_gateway": dataSourceAwsNatGateway(), "aws_network_interface": dataSourceAwsNetworkInterface(), @@ -273,6 +274,7 @@ func Provider() terraform.ResourceProvider { "aws_appautoscaling_target": resourceAwsAppautoscalingTarget(), "aws_appautoscaling_policy": resourceAwsAppautoscalingPolicy(), "aws_appautoscaling_scheduled_action": resourceAwsAppautoscalingScheduledAction(), + "aws_appsync_datasource": resourceAwsAppsyncDatasource(), "aws_appsync_graphql_api": resourceAwsAppsyncGraphqlApi(), "aws_athena_database": resourceAwsAthenaDatabase(), "aws_athena_named_query": resourceAwsAthenaNamedQuery(), @@ -407,12 +409,14 @@ func Provider() terraform.ResourceProvider { "aws_internet_gateway": resourceAwsInternetGateway(), "aws_iot_certificate": resourceAwsIotCertificate(), "aws_iot_policy": resourceAwsIotPolicy(), + "aws_iot_thing": resourceAwsIotThing(), "aws_iot_thing_type": resourceAwsIotThingType(), "aws_iot_topic_rule": resourceAwsIotTopicRule(), "aws_key_pair": resourceAwsKeyPair(), "aws_kinesis_firehose_delivery_stream": resourceAwsKinesisFirehoseDeliveryStream(), "aws_kinesis_stream": resourceAwsKinesisStream(), "aws_kms_alias": resourceAwsKmsAlias(), + "aws_kms_grant": resourceAwsKmsGrant(), "aws_kms_key": resourceAwsKmsKey(), "aws_lambda_function": resourceAwsLambdaFunction(), "aws_lambda_event_source_mapping": resourceAwsLambdaEventSourceMapping(), @@ -455,6 +459,8 @@ func Provider() terraform.ResourceProvider { "aws_opsworks_user_profile": resourceAwsOpsworksUserProfile(), "aws_opsworks_permission": resourceAwsOpsworksPermission(), "aws_opsworks_rds_db_instance": resourceAwsOpsworksRdsDbInstance(), + "aws_organizations_organization": resourceAwsOrganizationsOrganization(), + "aws_organizations_account": resourceAwsOrganizationsAccount(), "aws_placement_group": resourceAwsPlacementGroup(), "aws_proxy_protocol_policy": resourceAwsProxyProtocolPolicy(), "aws_rds_cluster": resourceAwsRDSCluster(), @@ -483,6 +489,7 @@ func Provider() terraform.ResourceProvider { "aws_ses_receipt_rule_set": resourceAwsSesReceiptRuleSet(), "aws_ses_configuration_set": resourceAwsSesConfigurationSet(), "aws_ses_event_destination": resourceAwsSesEventDestination(), + "aws_ses_identity_notification_topic": resourceAwsSesNotificationTopic(), "aws_ses_template": resourceAwsSesTemplate(), "aws_s3_bucket": resourceAwsS3Bucket(), "aws_s3_bucket_policy": resourceAwsS3BucketPolicy(), @@ -543,14 +550,29 @@ func Provider() terraform.ResourceProvider { "aws_vpn_gateway_route_propagation": resourceAwsVpnGatewayRoutePropagation(), "aws_waf_byte_match_set": resourceAwsWafByteMatchSet(), "aws_waf_ipset": resourceAwsWafIPSet(), - "aws_waf_rule": resourceAwsWafRule(), "aws_waf_rate_based_rule": resourceAwsWafRateBasedRule(), + "aws_waf_regex_match_set": resourceAwsWafRegexMatchSet(), + "aws_waf_regex_pattern_set": resourceAwsWafRegexPatternSet(), + "aws_waf_rule": resourceAwsWafRule(), + "aws_waf_rule_group": resourceAwsWafRuleGroup(), "aws_waf_size_constraint_set": resourceAwsWafSizeConstraintSet(), "aws_waf_web_acl": resourceAwsWafWebAcl(), "aws_waf_xss_match_set": resourceAwsWafXssMatchSet(), "aws_waf_sql_injection_match_set": resourceAwsWafSqlInjectionMatchSet(), + "aws_waf_geo_match_set": resourceAwsWafGeoMatchSet(), "aws_wafregional_byte_match_set": resourceAwsWafRegionalByteMatchSet(), + "aws_wafregional_geo_match_set": resourceAwsWafRegionalGeoMatchSet(), "aws_wafregional_ipset": resourceAwsWafRegionalIPSet(), + "aws_wafregional_rate_based_rule": resourceAwsWafRegionalRateBasedRule(), + "aws_wafregional_regex_match_set": resourceAwsWafRegionalRegexMatchSet(), + "aws_wafregional_regex_pattern_set": resourceAwsWafRegionalRegexPatternSet(), + "aws_wafregional_rule": resourceAwsWafRegionalRule(), + "aws_wafregional_rule_group": resourceAwsWafRegionalRuleGroup(), + "aws_wafregional_size_constraint_set": resourceAwsWafRegionalSizeConstraintSet(), + "aws_wafregional_sql_injection_match_set": resourceAwsWafRegionalSqlInjectionMatchSet(), + "aws_wafregional_xss_match_set": resourceAwsWafRegionalXssMatchSet(), + "aws_wafregional_web_acl": resourceAwsWafRegionalWebAcl(), + "aws_wafregional_web_acl_association": resourceAwsWafRegionalWebAclAssociation(), "aws_batch_compute_environment": resourceAwsBatchComputeEnvironment(), "aws_batch_job_definition": resourceAwsBatchJobDefinition(), "aws_batch_job_queue": resourceAwsBatchJobQueue(), @@ -630,6 +652,8 @@ func init() { "elb_endpoint": "Use this to override the default endpoint URL constructed from the `region`.\n", + "es_endpoint": "Use this to override the default endpoint URL constructed from the `region`.\n", + "rds_endpoint": "Use this to override the default endpoint URL constructed from the `region`.\n", "s3_endpoint": "Use this to override the default endpoint URL constructed from the `region`.\n", @@ -732,6 +756,7 @@ func providerConfigure(d *schema.ResourceData) (interface{}, error) { config.EcrEndpoint = endpoints["ecr"].(string) config.EcsEndpoint = endpoints["ecs"].(string) config.ElbEndpoint = endpoints["elb"].(string) + config.EsEndpoint = endpoints["es"].(string) config.IamEndpoint = endpoints["iam"].(string) config.KinesisEndpoint = endpoints["kinesis"].(string) config.KmsEndpoint = endpoints["kms"].(string) @@ -881,6 +906,12 @@ func endpointsSchema() *schema.Schema { Default: "", Description: descriptions["elb_endpoint"], }, + "es": { + Type: schema.TypeString, + Optional: true, + Default: "", + Description: descriptions["es_endpoint"], + }, "kinesis": { Type: schema.TypeString, Optional: true, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_acm_certificate.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_acm_certificate.go index 4b2c06b36240..c045f62d7b6b 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_acm_certificate.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_acm_certificate.go @@ -229,11 +229,23 @@ func convertValidationOptions(certificate *acm.CertificateDetail) ([]map[string] func resourceAwsAcmCertificateDelete(d *schema.ResourceData, meta interface{}) error { acmconn := meta.(*AWSClient).acmconn + log.Printf("[INFO] Deleting ACM Certificate: %s", d.Id()) + params := &acm.DeleteCertificateInput{ CertificateArn: aws.String(d.Id()), } - _, err := acmconn.DeleteCertificate(params) + err := resource.Retry(10*time.Minute, func() *resource.RetryError { + _, err := acmconn.DeleteCertificate(params) + if err != nil { + if isAWSErr(err, acm.ErrCodeResourceInUseException, "") { + log.Printf("[WARN] Conflict deleting certificate in use: %s, retrying", err.Error()) + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) if err != nil && !isAWSErr(err, acm.ErrCodeResourceNotFoundException, "") { return fmt.Errorf("Error deleting certificate: %s", err) diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ami.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ami.go index 7e89d4286d0f..bab340bf761a 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ami.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ami.go @@ -116,10 +116,6 @@ func resourceAwsAmiCreate(d *schema.ResourceData, meta interface{}) error { id := *res.ImageId d.SetId(id) - d.Partial(true) - d.Set("manage_ebs_block_devices", false) - d.SetPartial("manage_ebs_block_devices") - d.Partial(false) _, err = resourceAwsAmiWaitForAvailable(d.Timeout(schema.TimeoutCreate), id, client) if err != nil { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_api_key.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_api_key.go index 76684cc52246..ec8b151a6464 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_api_key.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_api_key.go @@ -10,6 +10,7 @@ import ( "github.com/aws/aws-sdk-go/service/apigateway" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsApiGatewayApiKey() *schema.Resource { @@ -76,7 +77,7 @@ func resourceAwsApiGatewayApiKey() *schema.Resource { Computed: true, ForceNew: true, Sensitive: true, - ValidateFunc: validateApiGatewayApiKeyValue, + ValidateFunc: validation.StringLenBetween(30, 128), }, }, } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_authorizer.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_authorizer.go index 8f881e185ccf..ef069d6a7afc 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_authorizer.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_authorizer.go @@ -9,52 +9,64 @@ import ( "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/apigateway" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsApiGatewayAuthorizer() *schema.Resource { return &schema.Resource{ - Create: resourceAwsApiGatewayAuthorizerCreate, - Read: resourceAwsApiGatewayAuthorizerRead, - Update: resourceAwsApiGatewayAuthorizerUpdate, - Delete: resourceAwsApiGatewayAuthorizerDelete, + Create: resourceAwsApiGatewayAuthorizerCreate, + Read: resourceAwsApiGatewayAuthorizerRead, + Update: resourceAwsApiGatewayAuthorizerUpdate, + Delete: resourceAwsApiGatewayAuthorizerDelete, + CustomizeDiff: resourceAwsApiGatewayAuthorizerCustomizeDiff, Schema: map[string]*schema.Schema{ - "authorizer_uri": &schema.Schema{ + "authorizer_uri": { Type: schema.TypeString, - Required: true, + Optional: true, // authorizer_uri is required for authorizer TOKEN/REQUEST }, - "identity_source": &schema.Schema{ + "identity_source": { Type: schema.TypeString, Optional: true, Default: "method.request.header.Authorization", }, - "name": &schema.Schema{ + "name": { Type: schema.TypeString, Required: true, }, - "rest_api_id": &schema.Schema{ + "rest_api_id": { Type: schema.TypeString, Required: true, ForceNew: true, }, - "type": &schema.Schema{ + "type": { Type: schema.TypeString, Optional: true, Default: "TOKEN", + ValidateFunc: validation.StringInSlice([]string{ + apigateway.AuthorizerTypeCognitoUserPools, + apigateway.AuthorizerTypeRequest, + apigateway.AuthorizerTypeToken, + }, false), }, - "authorizer_credentials": &schema.Schema{ + "authorizer_credentials": { Type: schema.TypeString, Optional: true, }, - "authorizer_result_ttl_in_seconds": &schema.Schema{ + "authorizer_result_ttl_in_seconds": { Type: schema.TypeInt, Optional: true, - ValidateFunc: validateIntegerInRange(0, 3600), + ValidateFunc: validation.IntBetween(0, 3600), }, - "identity_validation_expression": &schema.Schema{ + "identity_validation_expression": { Type: schema.TypeString, Optional: true, }, + "provider_arns": { + Type: schema.TypeSet, + Optional: true, // provider_arns is required for authorizer COGNITO_USER_POOLS. + Elem: &schema.Schema{Type: schema.TypeString}, + }, }, } } @@ -63,13 +75,18 @@ func resourceAwsApiGatewayAuthorizerCreate(d *schema.ResourceData, meta interfac conn := meta.(*AWSClient).apigateway input := apigateway.CreateAuthorizerInput{ - AuthorizerUri: aws.String(d.Get("authorizer_uri").(string)), IdentitySource: aws.String(d.Get("identity_source").(string)), Name: aws.String(d.Get("name").(string)), RestApiId: aws.String(d.Get("rest_api_id").(string)), Type: aws.String(d.Get("type").(string)), } + if err := validateAuthorizerType(d); err != nil { + return err + } + if v, ok := d.GetOk("authorizer_uri"); ok { + input.AuthorizerUri = aws.String(v.(string)) + } if v, ok := d.GetOk("authorizer_credentials"); ok { input.AuthorizerCredentials = aws.String(v.(string)) } @@ -79,6 +96,9 @@ func resourceAwsApiGatewayAuthorizerCreate(d *schema.ResourceData, meta interfac if v, ok := d.GetOk("identity_validation_expression"); ok { input.IdentityValidationExpression = aws.String(v.(string)) } + if v, ok := d.GetOk("provider_arns"); ok { + input.ProviderARNs = expandStringList(v.(*schema.Set).List()) + } log.Printf("[INFO] Creating API Gateway Authorizer: %s", input) out, err := conn.CreateAuthorizer(&input) @@ -118,6 +138,7 @@ func resourceAwsApiGatewayAuthorizerRead(d *schema.ResourceData, meta interface{ d.Set("identity_validation_expression", authorizer.IdentityValidationExpression) d.Set("name", authorizer.Name) d.Set("type", authorizer.Type) + d.Set("provider_arns", flattenStringList(authorizer.ProviderARNs)) return nil } @@ -181,6 +202,29 @@ func resourceAwsApiGatewayAuthorizerUpdate(d *schema.ResourceData, meta interfac Value: aws.String(d.Get("identity_validation_expression").(string)), }) } + if d.HasChange("provider_arns") { + old, new := d.GetChange("provider_arns") + os := old.(*schema.Set) + ns := new.(*schema.Set) + // providerARNs can't be empty, so add first and then remove + additionList := ns.Difference(os) + for _, v := range additionList.List() { + operations = append(operations, &apigateway.PatchOperation{ + Op: aws.String("add"), + Path: aws.String("/providerARNs"), + Value: aws.String(v.(string)), + }) + } + removalList := os.Difference(ns) + for _, v := range removalList.List() { + operations = append(operations, &apigateway.PatchOperation{ + Op: aws.String("remove"), + Path: aws.String("/providerARNs"), + Value: aws.String(v.(string)), + }) + } + } + input.PatchOperations = operations log.Printf("[INFO] Updating API Gateway Authorizer: %s", input) @@ -210,3 +254,35 @@ func resourceAwsApiGatewayAuthorizerDelete(d *schema.ResourceData, meta interfac return nil } + +func resourceAwsApiGatewayAuthorizerCustomizeDiff(diff *schema.ResourceDiff, v interface{}) error { + // switch type between COGNITO_USER_POOLS and TOKEN/REQUEST will create new resource. + if diff.HasChange("type") { + o, n := diff.GetChange("type") + if o.(string) == apigateway.AuthorizerTypeCognitoUserPools || n.(string) == apigateway.AuthorizerTypeCognitoUserPools { + if err := diff.ForceNew("type"); err != nil { + return err + } + } + } + + return nil +} + +func validateAuthorizerType(d *schema.ResourceData) error { + authType := d.Get("type").(string) + // authorizer_uri is required for authorizer TOKEN/REQUEST + if authType == apigateway.AuthorizerTypeRequest || authType == apigateway.AuthorizerTypeToken { + if v, ok := d.GetOk("authorizer_uri"); !ok || v.(string) == "" { + return fmt.Errorf("authorizer_uri must be set non-empty when authorizer type is %s", authType) + } + } + // provider_arns is required for authorizer COGNITO_USER_POOLS. + if authType == apigateway.AuthorizerTypeCognitoUserPools { + if v, ok := d.GetOk("provider_arns"); !ok || len(v.(*schema.Set).List()) == 0 { + return fmt.Errorf("provider_arns must be set non-empty when authorizer type is %s", authType) + } + } + + return nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_client_certificate.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_client_certificate.go index 77bb7f600113..e5ab97385083 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_client_certificate.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_client_certificate.go @@ -77,8 +77,8 @@ func resourceAwsApiGatewayClientCertificateRead(d *schema.ResourceData, meta int log.Printf("[DEBUG] Received API Gateway Client Certificate: %s", out) d.Set("description", out.Description) - d.Set("created_date", out.CreatedDate) - d.Set("expiration_date", out.ExpirationDate) + d.Set("created_date", out.CreatedDate.String()) + d.Set("expiration_date", out.ExpirationDate.String()) d.Set("pem_encoded_certificate", out.PemEncodedCertificate) return nil diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_deployment.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_deployment.go index 4e291b780e83..2e9c557c357d 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_deployment.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_deployment.go @@ -6,6 +6,7 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/apigateway" "github.com/hashicorp/terraform/helper/resource" @@ -121,12 +122,14 @@ func resourceAwsApiGatewayDeploymentRead(d *schema.ResourceData, meta interface{ d.Set("invoke_url", buildApiGatewayInvokeURL(restApiId, region, stageName)) - accountId := meta.(*AWSClient).accountid - arn, err := buildApiGatewayExecutionARN(restApiId, region, accountId) - if err != nil { - return err - } - d.Set("execution_arn", arn+"/"+stageName) + executionArn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "execute-api", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("%s/%s", restApiId, stageName), + }.String() + d.Set("execution_arn", executionArn) if err := d.Set("created_date", out.CreatedDate.Format(time.RFC3339)); err != nil { log.Printf("[DEBUG] Error setting created_date: %s", err) diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_integration.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_integration.go index 64622c319e05..bfbfb05dd545 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_integration.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_integration.go @@ -4,6 +4,7 @@ import ( "encoding/json" "fmt" "log" + "strings" "time" "github.com/aws/aws-sdk-go/aws" @@ -11,7 +12,7 @@ import ( "github.com/aws/aws-sdk-go/service/apigateway" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" - "strings" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsApiGatewayIntegration() *schema.Resource { @@ -38,14 +39,20 @@ func resourceAwsApiGatewayIntegration() *schema.Resource { Type: schema.TypeString, Required: true, ForceNew: true, - ValidateFunc: validateHTTPMethod, + ValidateFunc: validateHTTPMethod(), }, "type": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - ValidateFunc: validateApiGatewayIntegrationType, + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validation.StringInSlice([]string{ + apigateway.IntegrationTypeHttp, + apigateway.IntegrationTypeAws, + apigateway.IntegrationTypeMock, + apigateway.IntegrationTypeHttpProxy, + apigateway.IntegrationTypeAwsProxy, + }, false), }, "uri": { @@ -63,7 +70,7 @@ func resourceAwsApiGatewayIntegration() *schema.Resource { Type: schema.TypeString, Optional: true, ForceNew: true, - ValidateFunc: validateHTTPMethod, + ValidateFunc: validateHTTPMethod(), }, "request_templates": { @@ -89,15 +96,19 @@ func resourceAwsApiGatewayIntegration() *schema.Resource { "content_handling": { Type: schema.TypeString, Optional: true, - ValidateFunc: validateApiGatewayIntegrationContentHandling, + ValidateFunc: validateApiGatewayIntegrationContentHandling(), }, "passthrough_behavior": { - Type: schema.TypeString, - Optional: true, - Computed: true, - ForceNew: true, - ValidateFunc: validateApiGatewayIntegrationPassthroughBehavior, + Type: schema.TypeString, + Optional: true, + Computed: true, + ForceNew: true, + ValidateFunc: validation.StringInSlice([]string{ + "WHEN_NO_MATCH", + "WHEN_NO_TEMPLATES", + "NEVER", + }, false), }, "cache_key_parameters": { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_integration_response.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_integration_response.go index 88cf85176bbc..5462d92d7aac 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_integration_response.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_integration_response.go @@ -37,7 +37,7 @@ func resourceAwsApiGatewayIntegrationResponse() *schema.Resource { Type: schema.TypeString, Required: true, ForceNew: true, - ValidateFunc: validateHTTPMethod, + ValidateFunc: validateHTTPMethod(), }, "status_code": { @@ -73,7 +73,7 @@ func resourceAwsApiGatewayIntegrationResponse() *schema.Resource { "content_handling": { Type: schema.TypeString, Optional: true, - ValidateFunc: validateApiGatewayIntegrationContentHandling, + ValidateFunc: validateApiGatewayIntegrationContentHandling(), }, }, } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_method.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_method.go index fdbc451098a5..d35fb20ebc2f 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_method.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_method.go @@ -38,7 +38,7 @@ func resourceAwsApiGatewayMethod() *schema.Resource { Type: schema.TypeString, Required: true, ForceNew: true, - ValidateFunc: validateHTTPMethod, + ValidateFunc: validateHTTPMethod(), }, "authorization": &schema.Schema{ diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_method_response.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_method_response.go index caedc77d3d85..8c4ab7af3cc5 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_method_response.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_method_response.go @@ -41,7 +41,7 @@ func resourceAwsApiGatewayMethodResponse() *schema.Resource { Type: schema.TypeString, Required: true, ForceNew: true, - ValidateFunc: validateHTTPMethod, + ValidateFunc: validateHTTPMethod(), }, "status_code": &schema.Schema{ diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_rest_api.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_rest_api.go index 0d5ae48e3e4a..377b631306ac 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_rest_api.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_rest_api.go @@ -3,6 +3,7 @@ package aws import ( "fmt" "log" + "strconv" "time" "github.com/aws/aws-sdk-go/aws" @@ -42,6 +43,13 @@ func resourceAwsApiGatewayRestApi() *schema.Resource { Optional: true, }, + "minimum_compression_size": { + Type: schema.TypeInt, + Optional: true, + Default: -1, + ValidateFunc: validateIntegerInRange(-1, 10485760), + }, + "root_resource_id": { Type: schema.TypeString, Computed: true, @@ -74,6 +82,11 @@ func resourceAwsApiGatewayRestApiCreate(d *schema.ResourceData, meta interface{} params.BinaryMediaTypes = expandStringList(binaryMediaTypes.([]interface{})) } + minimumCompressionSize := d.Get("minimum_compression_size").(int) + if minimumCompressionSize > -1 { + params.MinimumCompressionSize = aws.Int64(int64(minimumCompressionSize)) + } + gateway, err := conn.CreateRestApi(params) if err != nil { return fmt.Errorf("Error creating API Gateway: %s", err) @@ -139,7 +152,11 @@ func resourceAwsApiGatewayRestApiRead(d *schema.ResourceData, meta interface{}) d.Set("name", api.Name) d.Set("description", api.Description) d.Set("binary_media_types", api.BinaryMediaTypes) - + if api.MinimumCompressionSize == nil { + d.Set("minimum_compression_size", -1) + } else { + d.Set("minimum_compression_size", api.MinimumCompressionSize) + } if err := d.Set("created_date", api.CreatedDate.Format(time.RFC3339)); err != nil { log.Printf("[DEBUG] Error setting created_date: %s", err) } @@ -166,6 +183,19 @@ func resourceAwsApiGatewayRestApiUpdateOperations(d *schema.ResourceData) []*api }) } + if d.HasChange("minimum_compression_size") { + minimumCompressionSize := d.Get("minimum_compression_size").(int) + var value string + if minimumCompressionSize > -1 { + value = strconv.Itoa(minimumCompressionSize) + } + operations = append(operations, &apigateway.PatchOperation{ + Op: aws.String("replace"), + Path: aws.String("/minimumCompressionSize"), + Value: aws.String(value), + }) + } + if d.HasChange("binary_media_types") { o, n := d.GetChange("binary_media_types") prefix := "binaryMediaTypes" diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_usage_plan.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_usage_plan.go index 4fe7164b3cf6..e7786b0458d7 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_usage_plan.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_usage_plan.go @@ -12,6 +12,7 @@ import ( "github.com/aws/aws-sdk-go/service/apigateway" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsApiGatewayUsagePlan() *schema.Resource { @@ -71,9 +72,13 @@ func resourceAwsApiGatewayUsagePlan() *schema.Resource { }, "period": { - Type: schema.TypeString, - Required: true, // Required as not removable - ValidateFunc: validateApiGatewayUsagePlanQuotaSettingsPeriod, + Type: schema.TypeString, + Required: true, // Required as not removable + ValidateFunc: validation.StringInSlice([]string{ + apigateway.QuotaPeriodTypeDay, + apigateway.QuotaPeriodTypeWeek, + apigateway.QuotaPeriodTypeMonth, + }, false), }, }, }, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_vpc_link.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_vpc_link.go index 8911e5dcbba1..62f10d8a5029 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_vpc_link.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_api_gateway_vpc_link.go @@ -92,7 +92,7 @@ func resourceAwsApiGatewayVpcLinkRead(d *schema.ResourceData, meta interface{}) d.Set("name", resp.Name) d.Set("description", resp.Description) - d.Set("target_arn", flattenStringList(resp.TargetArns)) + d.Set("target_arns", flattenStringList(resp.TargetArns)) return nil } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_appautoscaling_policy.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_appautoscaling_policy.go index e56c09760e29..8e885662ebf4 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_appautoscaling_policy.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_appautoscaling_policy.go @@ -12,6 +12,7 @@ import ( "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsAppautoscalingPolicy() *schema.Resource { @@ -26,14 +27,8 @@ func resourceAwsAppautoscalingPolicy() *schema.Resource { Type: schema.TypeString, Required: true, ForceNew: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - // https://github.com/boto/botocore/blob/9f322b1/botocore/data/autoscaling/2011-01-01/service-2.json#L1862-L1873 - value := v.(string) - if len(value) > 255 { - errors = append(errors, fmt.Errorf("%s cannot be longer than 255 characters", k)) - } - return - }, + // https://github.com/boto/botocore/blob/9f322b1/botocore/data/autoscaling/2011-01-01/service-2.json#L1862-L1873 + ValidateFunc: validateMaxLength(255), }, "arn": &schema.Schema{ Type: schema.TypeString, @@ -191,9 +186,15 @@ func resourceAwsAppautoscalingPolicy() *schema.Resource { Required: true, }, "statistic": &schema.Schema{ - Type: schema.TypeString, - Required: true, - ValidateFunc: validateAppautoscalingCustomizedMetricSpecificationStatistic, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + applicationautoscaling.MetricStatisticAverage, + applicationautoscaling.MetricStatisticMinimum, + applicationautoscaling.MetricStatisticMaximum, + applicationautoscaling.MetricStatisticSampleCount, + applicationautoscaling.MetricStatisticSum, + }, false), }, "unit": &schema.Schema{ Type: schema.TypeString, @@ -216,7 +217,7 @@ func resourceAwsAppautoscalingPolicy() *schema.Resource { "resource_label": &schema.Schema{ Type: schema.TypeString, Optional: true, - ValidateFunc: validateAppautoscalingPredefinedResourceLabel, + ValidateFunc: validateMaxLength(1023), }, }, }, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_appsync_datasource.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_appsync_datasource.go new file mode 100644 index 000000000000..9d8d0bbd1e32 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_appsync_datasource.go @@ -0,0 +1,323 @@ +package aws + +import ( + "fmt" + "log" + "regexp" + "strings" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/appsync" + "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" +) + +func resourceAwsAppsyncDatasource() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsAppsyncDatasourceCreate, + Read: resourceAwsAppsyncDatasourceRead, + Update: resourceAwsAppsyncDatasourceUpdate, + Delete: resourceAwsAppsyncDatasourceDelete, + + Schema: map[string]*schema.Schema{ + "api_id": { + Type: schema.TypeString, + Required: true, + }, + "name": { + Type: schema.TypeString, + Required: true, + ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { + value := v.(string) + if !regexp.MustCompile(`[_A-Za-z][_0-9A-Za-z]*`).MatchString(value) { + errors = append(errors, fmt.Errorf("%q must match [_A-Za-z][_0-9A-Za-z]*", k)) + } + return + }, + }, + "type": { + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + appsync.DataSourceTypeAwsLambda, + appsync.DataSourceTypeAmazonDynamodb, + appsync.DataSourceTypeAmazonElasticsearch, + appsync.DataSourceTypeNone, + }, true), + StateFunc: func(v interface{}) string { + return strings.ToUpper(v.(string)) + }, + }, + "description": { + Type: schema.TypeString, + Optional: true, + }, + "dynamodb_config": { + Type: schema.TypeList, + Optional: true, + MaxItems: 1, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "region": { + Type: schema.TypeString, + Required: true, + }, + "table_name": { + Type: schema.TypeString, + Required: true, + }, + "use_caller_credentials": { + Type: schema.TypeBool, + Optional: true, + }, + }, + }, + ConflictsWith: []string{"elasticsearch_config", "lambda_config"}, + }, + "elasticsearch_config": { + Type: schema.TypeList, + Optional: true, + MaxItems: 1, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "region": { + Type: schema.TypeString, + Required: true, + }, + "endpoint": { + Type: schema.TypeString, + Required: true, + }, + }, + }, + ConflictsWith: []string{"dynamodb_config", "lambda_config"}, + }, + "lambda_config": { + Type: schema.TypeList, + Optional: true, + MaxItems: 1, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "function_arn": { + Type: schema.TypeString, + Required: true, + }, + }, + }, + ConflictsWith: []string{"dynamodb_config", "elasticsearch_config"}, + }, + "service_role_arn": { + Type: schema.TypeString, + Optional: true, + }, + "arn": { + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func resourceAwsAppsyncDatasourceCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).appsyncconn + + input := &appsync.CreateDataSourceInput{ + ApiId: aws.String(d.Get("api_id").(string)), + Name: aws.String(d.Get("name").(string)), + Type: aws.String(d.Get("type").(string)), + } + + if v, ok := d.GetOk("description"); ok { + input.Description = aws.String(v.(string)) + } + + if v, ok := d.GetOk("service_role_arn"); ok { + input.ServiceRoleArn = aws.String(v.(string)) + } + + ddbconfig := d.Get("dynamodb_config").([]interface{}) + if len(ddbconfig) > 0 { + input.DynamodbConfig = expandAppsyncDynamodbDataSourceConfig(ddbconfig[0].(map[string]interface{})) + } + esconfig := d.Get("elasticsearch_config").([]interface{}) + if len(esconfig) > 0 { + input.ElasticsearchConfig = expandAppsyncElasticsearchDataSourceConfig(esconfig[0].(map[string]interface{})) + } + lambdaconfig := d.Get("lambda_config").([]interface{}) + if len(lambdaconfig) > 0 { + input.LambdaConfig = expandAppsyncLambdaDataSourceConfig(lambdaconfig[0].(map[string]interface{})) + } + + resp, err := conn.CreateDataSource(input) + if err != nil { + return err + } + + d.SetId(d.Get("api_id").(string) + "-" + d.Get("name").(string)) + d.Set("arn", resp.DataSource.DataSourceArn) + return nil +} + +func resourceAwsAppsyncDatasourceRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).appsyncconn + + input := &appsync.GetDataSourceInput{ + ApiId: aws.String(d.Get("api_id").(string)), + Name: aws.String(d.Get("name").(string)), + } + + resp, err := conn.GetDataSource(input) + if err != nil { + if isAWSErr(err, appsync.ErrCodeNotFoundException, "") { + log.Printf("[WARN] AppSync Datasource %q not found, removing from state", d.Id()) + d.SetId("") + return nil + } + return err + } + + d.Set("arn", resp.DataSource.DataSourceArn) + d.Set("description", resp.DataSource.Description) + d.Set("dynamodb_config", flattenAppsyncDynamodbDataSourceConfig(resp.DataSource.DynamodbConfig)) + d.Set("elasticsearch_config", flattenAppsyncElasticsearchDataSourceConfig(resp.DataSource.ElasticsearchConfig)) + d.Set("lambda_config", flattenAppsyncLambdaDataSourceConfig(resp.DataSource.LambdaConfig)) + d.Set("name", resp.DataSource.Name) + d.Set("service_role_arn", resp.DataSource.ServiceRoleArn) + d.Set("type", resp.DataSource.Type) + + return nil +} + +func resourceAwsAppsyncDatasourceUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).appsyncconn + + input := &appsync.UpdateDataSourceInput{ + ApiId: aws.String(d.Get("api_id").(string)), + Name: aws.String(d.Get("name").(string)), + } + + if d.HasChange("description") { + input.Description = aws.String(d.Get("description").(string)) + } + if d.HasChange("service_role_arn") { + input.ServiceRoleArn = aws.String(d.Get("service_role_arn").(string)) + } + if d.HasChange("type") { + input.Type = aws.String(d.Get("type").(string)) + } + + if d.HasChange("dynamodb_config") { + ddbconfig := d.Get("dynamodb_config").([]interface{}) + if len(ddbconfig) > 0 { + input.DynamodbConfig = expandAppsyncDynamodbDataSourceConfig(ddbconfig[0].(map[string]interface{})) + } + } + if d.HasChange("elasticsearch_config") { + esconfig := d.Get("elasticsearch_config").([]interface{}) + if len(esconfig) > 0 { + input.ElasticsearchConfig = expandAppsyncElasticsearchDataSourceConfig(esconfig[0].(map[string]interface{})) + } + } + if d.HasChange("lambda_config") { + lambdaconfig := d.Get("lambda_config").([]interface{}) + if len(lambdaconfig) > 0 { + input.LambdaConfig = expandAppsyncLambdaDataSourceConfig(lambdaconfig[0].(map[string]interface{})) + } + } + + _, err := conn.UpdateDataSource(input) + if err != nil { + return err + } + return resourceAwsAppsyncDatasourceRead(d, meta) +} + +func resourceAwsAppsyncDatasourceDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).appsyncconn + + input := &appsync.DeleteDataSourceInput{ + ApiId: aws.String(d.Get("api_id").(string)), + Name: aws.String(d.Get("name").(string)), + } + + _, err := conn.DeleteDataSource(input) + if err != nil { + if isAWSErr(err, appsync.ErrCodeNotFoundException, "") { + return nil + } + return err + } + + return nil +} + +func expandAppsyncDynamodbDataSourceConfig(configured map[string]interface{}) *appsync.DynamodbDataSourceConfig { + result := &appsync.DynamodbDataSourceConfig{ + AwsRegion: aws.String(configured["region"].(string)), + TableName: aws.String(configured["table_name"].(string)), + } + + if v, ok := configured["use_caller_credentials"]; ok { + result.UseCallerCredentials = aws.Bool(v.(bool)) + } + + return result +} + +func flattenAppsyncDynamodbDataSourceConfig(config *appsync.DynamodbDataSourceConfig) []map[string]interface{} { + if config == nil { + return nil + } + + result := map[string]interface{}{} + + result["region"] = *config.AwsRegion + result["table_name"] = *config.TableName + if config.UseCallerCredentials != nil { + result["use_caller_credentials"] = *config.UseCallerCredentials + } + + return []map[string]interface{}{result} +} + +func expandAppsyncElasticsearchDataSourceConfig(configured map[string]interface{}) *appsync.ElasticsearchDataSourceConfig { + result := &appsync.ElasticsearchDataSourceConfig{ + AwsRegion: aws.String(configured["region"].(string)), + Endpoint: aws.String(configured["endpoint"].(string)), + } + + return result +} + +func flattenAppsyncElasticsearchDataSourceConfig(config *appsync.ElasticsearchDataSourceConfig) []map[string]interface{} { + if config == nil { + return nil + } + + result := map[string]interface{}{} + + result["region"] = *config.AwsRegion + result["endpoint"] = *config.Endpoint + + return []map[string]interface{}{result} +} + +func expandAppsyncLambdaDataSourceConfig(configured map[string]interface{}) *appsync.LambdaDataSourceConfig { + result := &appsync.LambdaDataSourceConfig{ + LambdaFunctionArn: aws.String(configured["function_arn"].(string)), + } + + return result +} + +func flattenAppsyncLambdaDataSourceConfig(config *appsync.LambdaDataSourceConfig) []map[string]interface{} { + if config == nil { + return nil + } + + result := map[string]interface{}{} + + result["function_arn"] = *config.LambdaFunctionArn + + return []map[string]interface{}{result} +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_appsync_graphql_api.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_appsync_graphql_api.go index 0031c65b6147..5a6b8a1e5fa6 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_appsync_graphql_api.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_appsync_graphql_api.go @@ -18,6 +18,10 @@ func resourceAwsAppsyncGraphqlApi() *schema.Resource { Update: resourceAwsAppsyncGraphqlApiUpdate, Delete: resourceAwsAppsyncGraphqlApiDelete, + Importer: &schema.ResourceImporter{ + State: schema.ImportStatePassthrough, + }, + Schema: map[string]*schema.Schema{ "authentication_type": { Type: schema.TypeString, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_autoscaling_group.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_autoscaling_group.go index f67ed63cd80b..f7299cbcf04d 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_autoscaling_group.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_autoscaling_group.go @@ -38,28 +38,13 @@ func resourceAwsAutoscalingGroup() *schema.Resource { Computed: true, ForceNew: true, ConflictsWith: []string{"name_prefix"}, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - // https://github.com/boto/botocore/blob/9f322b1/botocore/data/autoscaling/2011-01-01/service-2.json#L1862-L1873 - value := v.(string) - if len(value) > 255 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 255 characters", k)) - } - return - }, + ValidateFunc: validateMaxLength(255), }, "name_prefix": &schema.Schema{ - Type: schema.TypeString, - Optional: true, - ForceNew: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 229 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 229 characters, name is limited to 255", k)) - } - return - }, + Type: schema.TypeString, + Optional: true, + ForceNew: true, + ValidateFunc: validateMaxLength(255 - resource.UniqueIDSuffixLength), }, "launch_configuration": { @@ -257,6 +242,12 @@ func resourceAwsAutoscalingGroup() *schema.Resource { Elem: &schema.Schema{Type: schema.TypeMap}, ConflictsWith: []string{"tag"}, }, + + "service_linked_role_arn": { + Type: schema.TypeString, + Optional: true, + Computed: true, + }, }, } } @@ -408,6 +399,10 @@ func resourceAwsAutoscalingGroupCreate(d *schema.ResourceData, meta interface{}) createOpts.TargetGroupARNs = expandStringList(v.(*schema.Set).List()) } + if v, ok := d.GetOk("service_linked_role_arn"); ok { + createOpts.ServiceLinkedRoleARN = aws.String(v.(string)) + } + log.Printf("[DEBUG] AutoScaling Group create configuration: %#v", createOpts) _, err := conn.CreateAutoScalingGroup(&createOpts) if err != nil { @@ -483,6 +478,7 @@ func resourceAwsAutoscalingGroupRead(d *schema.ResourceData, meta interface{}) e d.Set("max_size", g.MaxSize) d.Set("placement_group", g.PlacementGroup) d.Set("name", g.AutoScalingGroupName) + d.Set("service_linked_role_arn", g.ServiceLinkedRoleARN) var tagList, tagsList []*autoscaling.TagDescription var tagOk, tagsOk bool @@ -549,6 +545,8 @@ func resourceAwsAutoscalingGroupRead(d *schema.ResourceData, meta interface{}) e log.Printf("[WARN] Error setting metrics for (%s): %s", d.Id(), err) } d.Set("metrics_granularity", g.EnabledMetrics[0].Granularity) + } else { + d.Set("enabled_metrics", nil) } return nil @@ -620,6 +618,10 @@ func resourceAwsAutoscalingGroupUpdate(d *schema.ResourceData, meta interface{}) } } + if d.HasChange("service_linked_role_arn") { + opts.ServiceLinkedRoleARN = aws.String(d.Get("service_linked_role_arn").(string)) + } + if err := setAutoscalingTags(conn, d); err != nil { return err } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_autoscaling_policy.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_autoscaling_policy.go index 303c863b1794..1289667cbc8c 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_autoscaling_policy.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_autoscaling_policy.go @@ -21,73 +21,78 @@ func resourceAwsAutoscalingPolicy() *schema.Resource { Delete: resourceAwsAutoscalingPolicyDelete, Schema: map[string]*schema.Schema{ - "arn": &schema.Schema{ + "arn": { Type: schema.TypeString, Computed: true, }, - "name": &schema.Schema{ + "name": { Type: schema.TypeString, Required: true, ForceNew: true, }, - "adjustment_type": &schema.Schema{ + "adjustment_type": { Type: schema.TypeString, Optional: true, }, - "autoscaling_group_name": &schema.Schema{ + "autoscaling_group_name": { Type: schema.TypeString, Required: true, ForceNew: true, }, - "policy_type": &schema.Schema{ + "policy_type": { Type: schema.TypeString, Optional: true, Default: "SimpleScaling", // preserve AWS's default to make validation easier. + ValidateFunc: validation.StringInSlice([]string{ + "SimpleScaling", + "StepScaling", + "TargetTrackingScaling", + }, false), }, - "cooldown": &schema.Schema{ + "cooldown": { Type: schema.TypeInt, Optional: true, }, - "estimated_instance_warmup": &schema.Schema{ + "estimated_instance_warmup": { Type: schema.TypeInt, Optional: true, }, - "metric_aggregation_type": &schema.Schema{ + "metric_aggregation_type": { Type: schema.TypeString, Optional: true, Computed: true, }, - "min_adjustment_magnitude": &schema.Schema{ + "min_adjustment_magnitude": { Type: schema.TypeInt, Optional: true, ValidateFunc: validation.IntAtLeast(1), }, - "min_adjustment_step": &schema.Schema{ + "min_adjustment_step": { Type: schema.TypeInt, Optional: true, Deprecated: "Use min_adjustment_magnitude instead, otherwise you may see a perpetual diff on this resource.", ConflictsWith: []string{"min_adjustment_magnitude"}, }, - "scaling_adjustment": &schema.Schema{ + "scaling_adjustment": { Type: schema.TypeInt, Optional: true, ConflictsWith: []string{"step_adjustment"}, }, - "step_adjustment": &schema.Schema{ + "step_adjustment": { Type: schema.TypeSet, Optional: true, ConflictsWith: []string{"scaling_adjustment"}, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "metric_interval_lower_bound": &schema.Schema{ + "metric_interval_lower_bound": { Type: schema.TypeString, Optional: true, }, - "metric_interval_upper_bound": &schema.Schema{ + "metric_interval_upper_bound": { Type: schema.TypeString, Optional: true, }, - "scaling_adjustment": &schema.Schema{ + "scaling_adjustment": { Type: schema.TypeInt, Required: true, }, @@ -95,77 +100,77 @@ func resourceAwsAutoscalingPolicy() *schema.Resource { }, Set: resourceAwsAutoscalingScalingAdjustmentHash, }, - "target_tracking_configuration": &schema.Schema{ + "target_tracking_configuration": { Type: schema.TypeList, Optional: true, MaxItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "predefined_metric_specification": &schema.Schema{ + "predefined_metric_specification": { Type: schema.TypeList, Optional: true, MaxItems: 1, ConflictsWith: []string{"target_tracking_configuration.0.customized_metric_specification"}, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "predefined_metric_type": &schema.Schema{ + "predefined_metric_type": { Type: schema.TypeString, Required: true, }, - "resource_label": &schema.Schema{ + "resource_label": { Type: schema.TypeString, Optional: true, }, }, }, }, - "customized_metric_specification": &schema.Schema{ + "customized_metric_specification": { Type: schema.TypeList, Optional: true, MaxItems: 1, ConflictsWith: []string{"target_tracking_configuration.0.predefined_metric_specification"}, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "metric_dimension": &schema.Schema{ + "metric_dimension": { Type: schema.TypeList, Optional: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "name": &schema.Schema{ + "name": { Type: schema.TypeString, Required: true, }, - "value": &schema.Schema{ + "value": { Type: schema.TypeString, Required: true, }, }, }, }, - "metric_name": &schema.Schema{ + "metric_name": { Type: schema.TypeString, Required: true, }, - "namespace": &schema.Schema{ + "namespace": { Type: schema.TypeString, Required: true, }, - "statistic": &schema.Schema{ + "statistic": { Type: schema.TypeString, Required: true, }, - "unit": &schema.Schema{ + "unit": { Type: schema.TypeString, Optional: true, }, }, }, }, - "target_value": &schema.Schema{ + "target_value": { Type: schema.TypeFloat, Required: true, }, - "disable_scale_in": &schema.Schema{ + "disable_scale_in": { Type: schema.TypeBool, Optional: true, Default: false, @@ -181,11 +186,11 @@ func resourceAwsAutoscalingPolicyCreate(d *schema.ResourceData, meta interface{} autoscalingconn := meta.(*AWSClient).autoscalingconn params, err := getAwsAutoscalingPutScalingPolicyInput(d) + log.Printf("[DEBUG] AutoScaling PutScalingPolicy on Create: %#v", params) if err != nil { return err } - log.Printf("[DEBUG] AutoScaling PutScalingPolicy: %#v", params) resp, err := autoscalingconn.PutScalingPolicy(¶ms) if err != nil { return fmt.Errorf("Error putting scaling policy: %s", err) @@ -236,11 +241,11 @@ func resourceAwsAutoscalingPolicyUpdate(d *schema.ResourceData, meta interface{} autoscalingconn := meta.(*AWSClient).autoscalingconn params, inputErr := getAwsAutoscalingPutScalingPolicyInput(d) + log.Printf("[DEBUG] AutoScaling PutScalingPolicy on Update: %#v", params) if inputErr != nil { return inputErr } - log.Printf("[DEBUG] Autoscaling Update Scaling Policy: %#v", params) _, err := autoscalingconn.PutScalingPolicy(¶ms) if err != nil { return err @@ -281,95 +286,84 @@ func getAwsAutoscalingPutScalingPolicyInput(d *schema.ResourceData) (autoscaling PolicyName: aws.String(d.Get("name").(string)), } - if v, ok := d.GetOk("adjustment_type"); ok { + // get policy_type first as parameter support depends on policy type + policyType := d.Get("policy_type") + params.PolicyType = aws.String(policyType.(string)) + + // This parameter is supported if the policy type is SimpleScaling or StepScaling. + if v, ok := d.GetOk("adjustment_type"); ok && (policyType == "SimpleScaling" || policyType == "StepScaling") { params.AdjustmentType = aws.String(v.(string)) } + // This parameter is supported if the policy type is SimpleScaling. if v, ok := d.GetOkExists("cooldown"); ok { + // 0 is allowed as placeholder even if policyType is not supported params.Cooldown = aws.Int64(int64(v.(int))) + if v.(int) != 0 && policyType != "SimpleScaling" { + return params, fmt.Errorf("cooldown is only supported for policy type SimpleScaling") + } } + // This parameter is supported if the policy type is StepScaling or TargetTrackingScaling. if v, ok := d.GetOkExists("estimated_instance_warmup"); ok { - params.EstimatedInstanceWarmup = aws.Int64(int64(v.(int))) + // 0 is NOT allowed as placeholder if policyType is not supported + if policyType == "StepScaling" || policyType == "TargetTrackingScaling" { + params.EstimatedInstanceWarmup = aws.Int64(int64(v.(int))) + } + if v.(int) != 0 && policyType != "StepScaling" && policyType != "TargetTrackingScaling" { + return params, fmt.Errorf("estimated_instance_warmup is only supported for policy type StepScaling and TargetTrackingScaling") + } } - if v, ok := d.GetOk("metric_aggregation_type"); ok { + // This parameter is supported if the policy type is StepScaling. + if v, ok := d.GetOk("metric_aggregation_type"); ok && policyType == "StepScaling" { params.MetricAggregationType = aws.String(v.(string)) } - if v, ok := d.GetOk("policy_type"); ok { - params.PolicyType = aws.String(v.(string)) + // MinAdjustmentMagnitude is supported if the policy type is SimpleScaling or StepScaling. + // MinAdjustmentStep is available for backward compatibility. Use MinAdjustmentMagnitude instead. + if v, ok := d.GetOkExists("min_adjustment_magnitude"); ok && v.(int) != 0 && (policyType == "SimpleScaling" || policyType == "StepScaling") { + params.MinAdjustmentMagnitude = aws.Int64(int64(v.(int))) + } else if v, ok := d.GetOkExists("min_adjustment_step"); ok && v.(int) != 0 && (policyType == "SimpleScaling" || policyType == "StepScaling") { + params.MinAdjustmentStep = aws.Int64(int64(v.(int))) } + // This parameter is required if the policy type is SimpleScaling and not supported otherwise. //if policy_type=="SimpleScaling" then scaling_adjustment is required and 0 is allowed - if v, ok := d.GetOkExists("scaling_adjustment"); ok || *params.PolicyType == "SimpleScaling" { - params.ScalingAdjustment = aws.Int64(int64(v.(int))) + if v, ok := d.GetOkExists("scaling_adjustment"); ok { + // 0 is NOT allowed as placeholder if policyType is not supported + if policyType == "SimpleScaling" { + params.ScalingAdjustment = aws.Int64(int64(v.(int))) + } + if v.(int) != 0 && policyType != "SimpleScaling" { + return params, fmt.Errorf("scaling_adjustment is only supported for policy type SimpleScaling") + } + } else if !ok && policyType == "SimpleScaling" { + return params, fmt.Errorf("scaling_adjustment is required for policy type SimpleScaling") } + // This parameter is required if the policy type is StepScaling and not supported otherwise. if v, ok := d.GetOk("step_adjustment"); ok { steps, err := expandStepAdjustments(v.(*schema.Set).List()) if err != nil { return params, fmt.Errorf("metric_interval_lower_bound and metric_interval_upper_bound must be strings!") } params.StepAdjustments = steps + if len(steps) != 0 && policyType != "StepScaling" { + return params, fmt.Errorf("step_adjustment is only supported for policy type StepScaling") + } + } else if !ok && policyType == "StepScaling" { + return params, fmt.Errorf("step_adjustment is required for policy type StepScaling") } - if v, ok := d.GetOkExists("min_adjustment_magnitude"); ok { - // params.MinAdjustmentMagnitude = aws.Int64(int64(d.Get("min_adjustment_magnitude").(int))) - params.MinAdjustmentMagnitude = aws.Int64(int64(v.(int))) - } else if v, ok := d.GetOkExists("min_adjustment_step"); ok { - // params.MinAdjustmentStep = aws.Int64(int64(d.Get("min_adjustment_step").(int))) - params.MinAdjustmentStep = aws.Int64(int64(v.(int))) - } - + // This parameter is required if the policy type is TargetTrackingScaling and not supported otherwise. if v, ok := d.GetOk("target_tracking_configuration"); ok { params.TargetTrackingConfiguration = expandTargetTrackingConfiguration(v.([]interface{})) - } - - // Validate our final input to confirm it won't error when sent to AWS. - // First, SimpleScaling policy types... - if *params.PolicyType == "SimpleScaling" && params.StepAdjustments != nil { - return params, fmt.Errorf("SimpleScaling policy types cannot use step_adjustments!") - } - if *params.PolicyType == "SimpleScaling" && params.MetricAggregationType != nil { - return params, fmt.Errorf("SimpleScaling policy types cannot use metric_aggregation_type!") - } - if *params.PolicyType == "SimpleScaling" && params.EstimatedInstanceWarmup != nil { - return params, fmt.Errorf("SimpleScaling policy types cannot use estimated_instance_warmup!") - } - if *params.PolicyType == "SimpleScaling" && params.TargetTrackingConfiguration != nil { - return params, fmt.Errorf("SimpleScaling policy types cannot use target_tracking_configuration!") - } - - // Second, StepScaling policy types... - if *params.PolicyType == "StepScaling" && params.ScalingAdjustment != nil { - return params, fmt.Errorf("StepScaling policy types cannot use scaling_adjustment!") - } - if *params.PolicyType == "StepScaling" && params.Cooldown != nil { - return params, fmt.Errorf("StepScaling policy types cannot use cooldown!") - } - if *params.PolicyType == "StepScaling" && params.TargetTrackingConfiguration != nil { - return params, fmt.Errorf("StepScaling policy types cannot use target_tracking_configuration!") - } - - // Third, TargetTrackingScaling policy types... - if *params.PolicyType == "TargetTrackingScaling" && params.AdjustmentType != nil { - return params, fmt.Errorf("TargetTrackingScaling policy types cannot use adjustment_type!") - } - if *params.PolicyType == "TargetTrackingScaling" && params.Cooldown != nil { - return params, fmt.Errorf("TargetTrackingScaling policy types cannot use cooldown!") - } - if *params.PolicyType == "TargetTrackingScaling" && params.MetricAggregationType != nil { - return params, fmt.Errorf("TargetTrackingScaling policy types cannot use metric_aggregation_type!") - } - if *params.PolicyType == "TargetTrackingScaling" && params.MinAdjustmentMagnitude != nil { - return params, fmt.Errorf("TargetTrackingScaling policy types cannot use min_adjustment_magnitude!") - } - if *params.PolicyType == "TargetTrackingScaling" && params.ScalingAdjustment != nil { - return params, fmt.Errorf("TargetTrackingScaling policy types cannot use scaling_adjustment!") - } - if *params.PolicyType == "TargetTrackingScaling" && params.StepAdjustments != nil { - return params, fmt.Errorf("TargetTrackingScaling policy types cannot use step_adjustments!") + if policyType != "TargetTrackingScaling" { + return params, fmt.Errorf("target_tracking_configuration is only supported for policy type TargetTrackingScaling") + } + } else if !ok && policyType == "TargetTrackingScaling" { + return params, fmt.Errorf("target_tracking_configuration is required for policy type TargetTrackingScaling") } return params, nil diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_batch_compute_environment.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_batch_compute_environment.go index 859280bf1997..3d2e7c719c0c 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_batch_compute_environment.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_batch_compute_environment.go @@ -228,7 +228,7 @@ func resourceAwsBatchComputeEnvironmentCreate(d *schema.ResourceData, meta inter stateConf := &resource.StateChangeConf{ Pending: []string{batch.CEStatusCreating}, Target: []string{batch.CEStatusValid}, - Refresh: resourceAwsBatchComputeEnvironmentStatusRefreshFunc(d, meta), + Refresh: resourceAwsBatchComputeEnvironmentStatusRefreshFunc(computeEnvironmentName, conn), Timeout: d.Timeout(schema.TimeoutCreate), MinTimeout: 5 * time.Second, } @@ -266,8 +266,10 @@ func resourceAwsBatchComputeEnvironmentRead(d *schema.ResourceData, meta interfa d.Set("state", computeEnvironment.State) d.Set("type", computeEnvironment.Type) - if *(computeEnvironment.Type) == "MANAGED" { - d.Set("compute_resources", flattenComputeResources(computeEnvironment.ComputeResources)) + if aws.StringValue(computeEnvironment.Type) == batch.CETypeManaged { + if err := d.Set("compute_resources", flattenBatchComputeResources(computeEnvironment.ComputeResources)); err != nil { + return fmt.Errorf("error setting compute_resources: %s", err) + } } d.Set("arn", computeEnvironment.ComputeEnvironmentArn) @@ -279,23 +281,23 @@ func resourceAwsBatchComputeEnvironmentRead(d *schema.ResourceData, meta interfa return nil } -func flattenComputeResources(computeResource *batch.ComputeResource) []map[string]interface{} { +func flattenBatchComputeResources(computeResource *batch.ComputeResource) []map[string]interface{} { result := make([]map[string]interface{}, 0) m := make(map[string]interface{}) - m["bid_percentage"] = computeResource.BidPercentage - m["desired_vcpus"] = computeResource.DesiredvCpus - m["ec2_key_pair"] = computeResource.Ec2KeyPair - m["image_id"] = computeResource.ImageId - m["instance_role"] = computeResource.InstanceRole + m["bid_percentage"] = int(aws.Int64Value(computeResource.BidPercentage)) + m["desired_vcpus"] = int(aws.Int64Value(computeResource.DesiredvCpus)) + m["ec2_key_pair"] = aws.StringValue(computeResource.Ec2KeyPair) + m["image_id"] = aws.StringValue(computeResource.ImageId) + m["instance_role"] = aws.StringValue(computeResource.InstanceRole) m["instance_type"] = schema.NewSet(schema.HashString, flattenStringList(computeResource.InstanceTypes)) - m["max_vcpus"] = computeResource.MaxvCpus - m["min_vcpus"] = computeResource.MinvCpus + m["max_vcpus"] = int(aws.Int64Value(computeResource.MaxvCpus)) + m["min_vcpus"] = int(aws.Int64Value(computeResource.MinvCpus)) m["security_group_ids"] = schema.NewSet(schema.HashString, flattenStringList(computeResource.SecurityGroupIds)) - m["spot_iam_fleet_role"] = computeResource.SpotIamFleetRole + m["spot_iam_fleet_role"] = aws.StringValue(computeResource.SpotIamFleetRole) m["subnets"] = schema.NewSet(schema.HashString, flattenStringList(computeResource.Subnets)) m["tags"] = tagsToMapGeneric(computeResource.Tags) - m["type"] = computeResource.Type + m["type"] = aws.StringValue(computeResource.Type) result = append(result, m) return result @@ -303,52 +305,20 @@ func flattenComputeResources(computeResource *batch.ComputeResource) []map[strin func resourceAwsBatchComputeEnvironmentDelete(d *schema.ResourceData, meta interface{}) error { conn := meta.(*AWSClient).batchconn - computeEnvironmentName := d.Get("compute_environment_name").(string) - updateInput := &batch.UpdateComputeEnvironmentInput{ - ComputeEnvironment: aws.String(computeEnvironmentName), - State: aws.String(batch.CEStateDisabled), - } - - log.Printf("[DEBUG] Delete compute environment %s.\n", updateInput) - - if _, err := conn.UpdateComputeEnvironment(updateInput); err != nil { - return err - } - - stateConf := &resource.StateChangeConf{ - Pending: []string{batch.CEStatusUpdating}, - Target: []string{batch.CEStatusValid}, - Refresh: resourceAwsBatchComputeEnvironmentStatusRefreshFunc(d, meta), - Timeout: d.Timeout(schema.TimeoutDelete), - MinTimeout: 5 * time.Second, - } - if _, err := stateConf.WaitForState(); err != nil { - return err - } - - input := &batch.DeleteComputeEnvironmentInput{ - ComputeEnvironment: aws.String(computeEnvironmentName), - } - - if _, err := conn.DeleteComputeEnvironment(input); err != nil { - return err + log.Printf("[DEBUG] Disabling Batch Compute Environment: %s", computeEnvironmentName) + err := disableBatchComputeEnvironment(computeEnvironmentName, d.Timeout(schema.TimeoutDelete), conn) + if err != nil { + return fmt.Errorf("error disabling Batch Compute Environment (%s): %s", computeEnvironmentName, err) } - stateConfForDelete := &resource.StateChangeConf{ - Pending: []string{batch.CEStatusDeleting}, - Target: []string{batch.CEStatusDeleted}, - Refresh: resourceAwsBatchComputeEnvironmentDeleteRefreshFunc(d, meta), - Timeout: d.Timeout(schema.TimeoutDelete), - MinTimeout: 5 * time.Second, - } - if _, err := stateConfForDelete.WaitForState(); err != nil { - return err + log.Printf("[DEBUG] Deleting Batch Compute Environment: %s", computeEnvironmentName) + err = deleteBatchComputeEnvironment(computeEnvironmentName, d.Timeout(schema.TimeoutDelete), conn) + if err != nil { + return fmt.Errorf("error deleting Batch Compute Environment (%s): %s", computeEnvironmentName, err) } - d.SetId("") - return nil } @@ -366,7 +336,7 @@ func resourceAwsBatchComputeEnvironmentUpdate(d *schema.ResourceData, meta inter input.ServiceRole = aws.String(d.Get("service_role").(string)) } if d.HasChange("state") { - input.ServiceRole = aws.String(d.Get("state").(string)) + input.State = aws.String(d.Get("state").(string)) } if d.HasChange("compute_resources") { @@ -390,12 +360,8 @@ func resourceAwsBatchComputeEnvironmentUpdate(d *schema.ResourceData, meta inter return resourceAwsBatchComputeEnvironmentRead(d, meta) } -func resourceAwsBatchComputeEnvironmentStatusRefreshFunc(d *schema.ResourceData, meta interface{}) resource.StateRefreshFunc { +func resourceAwsBatchComputeEnvironmentStatusRefreshFunc(computeEnvironmentName string, conn *batch.Batch) resource.StateRefreshFunc { return func() (interface{}, string, error) { - conn := meta.(*AWSClient).batchconn - - computeEnvironmentName := d.Get("compute_environment_name").(string) - result, err := conn.DescribeComputeEnvironments(&batch.DescribeComputeEnvironmentsInput{ ComputeEnvironments: []*string{ aws.String(computeEnvironmentName), @@ -414,12 +380,8 @@ func resourceAwsBatchComputeEnvironmentStatusRefreshFunc(d *schema.ResourceData, } } -func resourceAwsBatchComputeEnvironmentDeleteRefreshFunc(d *schema.ResourceData, meta interface{}) resource.StateRefreshFunc { +func resourceAwsBatchComputeEnvironmentDeleteRefreshFunc(computeEnvironmentName string, conn *batch.Batch) resource.StateRefreshFunc { return func() (interface{}, string, error) { - conn := meta.(*AWSClient).batchconn - - computeEnvironmentName := d.Get("compute_environment_name").(string) - result, err := conn.DescribeComputeEnvironments(&batch.DescribeComputeEnvironmentsInput{ ComputeEnvironments: []*string{ aws.String(computeEnvironmentName), @@ -437,3 +399,44 @@ func resourceAwsBatchComputeEnvironmentDeleteRefreshFunc(d *schema.ResourceData, return result, *(computeEnvironment.Status), nil } } + +func deleteBatchComputeEnvironment(computeEnvironment string, timeout time.Duration, conn *batch.Batch) error { + input := &batch.DeleteComputeEnvironmentInput{ + ComputeEnvironment: aws.String(computeEnvironment), + } + + if _, err := conn.DeleteComputeEnvironment(input); err != nil { + return err + } + + stateChangeConf := &resource.StateChangeConf{ + Pending: []string{batch.CEStatusDeleting}, + Target: []string{batch.CEStatusDeleted}, + Refresh: resourceAwsBatchComputeEnvironmentDeleteRefreshFunc(computeEnvironment, conn), + Timeout: timeout, + MinTimeout: 5 * time.Second, + } + _, err := stateChangeConf.WaitForState() + return err +} + +func disableBatchComputeEnvironment(computeEnvironment string, timeout time.Duration, conn *batch.Batch) error { + input := &batch.UpdateComputeEnvironmentInput{ + ComputeEnvironment: aws.String(computeEnvironment), + State: aws.String(batch.CEStateDisabled), + } + + if _, err := conn.UpdateComputeEnvironment(input); err != nil { + return err + } + + stateChangeConf := &resource.StateChangeConf{ + Pending: []string{batch.CEStatusUpdating}, + Target: []string{batch.CEStatusValid}, + Refresh: resourceAwsBatchComputeEnvironmentStatusRefreshFunc(computeEnvironment, conn), + Timeout: timeout, + MinTimeout: 5 * time.Second, + } + _, err := stateChangeConf.WaitForState() + return err +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_batch_job_queue.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_batch_job_queue.go index 5b215b210a1f..ab15da86c5f2 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_batch_job_queue.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_batch_job_queue.go @@ -133,64 +133,73 @@ func resourceAwsBatchJobQueueUpdate(d *schema.ResourceData, meta interface{}) er func resourceAwsBatchJobQueueDelete(d *schema.ResourceData, meta interface{}) error { conn := meta.(*AWSClient).batchconn - sn := d.Get("name").(string) - _, err := conn.UpdateJobQueue(&batch.UpdateJobQueueInput{ - JobQueue: aws.String(sn), - State: aws.String(batch.JQStateDisabled), - }) + name := d.Get("name").(string) + + log.Printf("[DEBUG] Disabling Batch Job Queue %s", name) + err := disableBatchJobQueue(name, 10*time.Minute, conn) if err != nil { - return err + return fmt.Errorf("error disabling Batch Job Queue (%s): %s", name, err) } - // Wait until the Job Queue is disabled before deleting - stateConf := &resource.StateChangeConf{ - Pending: []string{batch.JQStatusUpdating}, - Target: []string{batch.JQStatusValid}, - Refresh: batchJobQueueRefreshStatusFunc(conn, sn), - Timeout: 10 * time.Minute, - Delay: 10 * time.Second, - MinTimeout: 3 * time.Second, - } - _, err = stateConf.WaitForState() + log.Printf("[DEBUG] Deleting Batch Job Queue %s", name) + err = deleteBatchJobQueue(name, 10*time.Minute, conn) if err != nil { - return err + return fmt.Errorf("error deleting Batch Job Queue (%s): %s", name, err) + } + + return nil +} + +func createComputeEnvironmentOrder(order []interface{}) (envs []*batch.ComputeEnvironmentOrder) { + for i, env := range order { + envs = append(envs, &batch.ComputeEnvironmentOrder{ + Order: aws.Int64(int64(i)), + ComputeEnvironment: aws.String(env.(string)), + }) } + return +} - log.Printf("[DEBUG] Trying to delete Job Queue %s", sn) - _, err = conn.DeleteJobQueue(&batch.DeleteJobQueueInput{ - JobQueue: aws.String(sn), +func deleteBatchJobQueue(jobQueue string, timeout time.Duration, conn *batch.Batch) error { + _, err := conn.DeleteJobQueue(&batch.DeleteJobQueueInput{ + JobQueue: aws.String(jobQueue), }) if err != nil { return err } - deleteStateConf := &resource.StateChangeConf{ + stateChangeConf := &resource.StateChangeConf{ Pending: []string{batch.JQStateDisabled, batch.JQStatusDeleting}, Target: []string{batch.JQStatusDeleted}, - Refresh: batchJobQueueRefreshStatusFunc(conn, sn), - Timeout: 10 * time.Minute, + Refresh: batchJobQueueRefreshStatusFunc(conn, jobQueue), + Timeout: timeout, Delay: 10 * time.Second, MinTimeout: 3 * time.Second, } - _, err = deleteStateConf.WaitForState() + _, err = stateChangeConf.WaitForState() + return err +} + +func disableBatchJobQueue(jobQueue string, timeout time.Duration, conn *batch.Batch) error { + _, err := conn.UpdateJobQueue(&batch.UpdateJobQueueInput{ + JobQueue: aws.String(jobQueue), + State: aws.String(batch.JQStateDisabled), + }) if err != nil { - return fmt.Errorf( - "Error waiting for Job Queue (%s) to be deleted: %s", - sn, err) + return err } - d.SetId("") - return nil -} -func createComputeEnvironmentOrder(order []interface{}) (envs []*batch.ComputeEnvironmentOrder) { - for i, env := range order { - envs = append(envs, &batch.ComputeEnvironmentOrder{ - Order: aws.Int64(int64(i)), - ComputeEnvironment: aws.String(env.(string)), - }) + stateChangeConf := &resource.StateChangeConf{ + Pending: []string{batch.JQStatusUpdating}, + Target: []string{batch.JQStatusValid}, + Refresh: batchJobQueueRefreshStatusFunc(conn, jobQueue), + Timeout: timeout, + Delay: 10 * time.Second, + MinTimeout: 3 * time.Second, } - return + _, err = stateChangeConf.WaitForState() + return err } func getJobQueue(conn *batch.Batch, sn string) (*batch.JobQueueDetail, error) { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cloud9_environment_ec2.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cloud9_environment_ec2.go index 84d67fd62aa9..df08d221b77d 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cloud9_environment_ec2.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cloud9_environment_ec2.go @@ -87,7 +87,20 @@ func resourceAwsCloud9EnvironmentEc2Create(d *schema.ResourceData, meta interfac params.SubnetId = aws.String(v.(string)) } - out, err := conn.CreateEnvironmentEC2(params) + var out *cloud9.CreateEnvironmentEC2Output + err := resource.Retry(1*time.Minute, func() *resource.RetryError { + var err error + out, err = conn.CreateEnvironmentEC2(params) + if err != nil { + // NotFoundException: User arn:aws:iam::*******:user/****** does not exist. + if isAWSErr(err, cloud9.ErrCodeNotFoundException, "User") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + if err != nil { return err } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cloudformation_stack.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cloudformation_stack.go index c6a17a703c8c..43e9472e8422 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cloudformation_stack.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cloudformation_stack.go @@ -308,7 +308,6 @@ func resourceAwsCloudFormationStackRead(d *schema.ResourceData, meta interface{} log.Printf("[DEBUG] Received CloudFormation stack: %s", stack) d.Set("name", stack.StackName) - d.Set("arn", stack.StackId) d.Set("iam_role_arn", stack.RoleARN) if stack.TimeoutInMinutes != nil { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cloudfront_distribution.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cloudfront_distribution.go index e7ecb3de4654..216f46695f33 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cloudfront_distribution.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cloudfront_distribution.go @@ -11,6 +11,7 @@ import ( "github.com/hashicorp/errwrap" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsCloudFrontDistribution() *schema.Resource { @@ -57,7 +58,12 @@ func resourceAwsCloudFrontDistribution() *schema.Resource { }, "default_ttl": { Type: schema.TypeInt, - Required: true, + Optional: true, + Default: 86400, + }, + "field_level_encryption_id": { + Type: schema.TypeString, + Optional: true, }, "forwarded_values": { Type: schema.TypeSet, @@ -122,11 +128,13 @@ func resourceAwsCloudFrontDistribution() *schema.Resource { }, "max_ttl": { Type: schema.TypeInt, - Required: true, + Optional: true, + Default: 31536000, }, "min_ttl": { Type: schema.TypeInt, - Required: true, + Optional: true, + Default: 0, }, "path_pattern": { Type: schema.TypeString, @@ -205,7 +213,12 @@ func resourceAwsCloudFrontDistribution() *schema.Resource { }, "default_ttl": { Type: schema.TypeInt, - Required: true, + Optional: true, + Default: 86400, + }, + "field_level_encryption_id": { + Type: schema.TypeString, + Optional: true, }, "forwarded_values": { Type: schema.TypeSet, @@ -270,11 +283,13 @@ func resourceAwsCloudFrontDistribution() *schema.Resource { }, "max_ttl": { Type: schema.TypeInt, - Required: true, + Optional: true, + Default: 31536000, }, "min_ttl": { Type: schema.TypeInt, - Required: true, + Optional: true, + Default: 0, }, "smooth_streaming": { Type: schema.TypeBool, @@ -308,7 +323,7 @@ func resourceAwsCloudFrontDistribution() *schema.Resource { Type: schema.TypeString, Optional: true, Default: "http2", - ValidateFunc: validateHTTP, + ValidateFunc: validation.StringInSlice([]string{"http1.1", "http2"}, false), }, "logging_config": { Type: schema.TypeSet, @@ -379,8 +394,9 @@ func resourceAwsCloudFrontDistribution() *schema.Resource { }, }, "domain_name": { - Type: schema.TypeString, - Required: true, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.NoZeroValues, }, "custom_header": { Type: schema.TypeSet, @@ -400,8 +416,9 @@ func resourceAwsCloudFrontDistribution() *schema.Resource { }, }, "origin_id": { - Type: schema.TypeString, - Required: true, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.NoZeroValues, }, "origin_path": { Type: schema.TypeString, @@ -724,16 +741,3 @@ func resourceAwsCloudFrontWebDistributionStateRefreshFunc(id string, meta interf return resp.Distribution, *resp.Distribution.Status, nil } } - -// validateHTTP ensures that the http_version resource parameter is -// correct. -func validateHTTP(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - - if value != "http1.1" && value != "http2" { - errors = append(errors, fmt.Errorf( - "%q contains an invalid HTTP version parameter %q. Valid parameters are either %q or %q.", - k, value, "http1.1", "http2")) - } - return -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cloudfront_origin_access_identity.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cloudfront_origin_access_identity.go index 2c405374143d..55585b0ff574 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cloudfront_origin_access_identity.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cloudfront_origin_access_identity.go @@ -5,6 +5,7 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/service/cloudfront" "github.com/hashicorp/terraform/helper/schema" ) @@ -81,8 +82,13 @@ func resourceAwsCloudFrontOriginAccessIdentityRead(d *schema.ResourceData, meta d.Set("etag", resp.ETag) d.Set("s3_canonical_user_id", resp.CloudFrontOriginAccessIdentity.S3CanonicalUserId) d.Set("cloudfront_access_identity_path", fmt.Sprintf("origin-access-identity/cloudfront/%s", *resp.CloudFrontOriginAccessIdentity.Id)) - d.Set("iam_arn", fmt.Sprintf("arn:%s:iam::cloudfront:user/CloudFront Origin Access Identity %s", - meta.(*AWSClient).partition, *resp.CloudFrontOriginAccessIdentity.Id)) + iamArn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "iam", + AccountID: "cloudfront", + Resource: fmt.Sprintf("user/CloudFront Origin Access Identity %s", *resp.CloudFrontOriginAccessIdentity.Id), + }.String() + d.Set("iam_arn", iamArn) return nil } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codebuild_project.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codebuild_project.go index eb6afb70b6d9..95724b9b66d6 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codebuild_project.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codebuild_project.go @@ -5,14 +5,15 @@ import ( "fmt" "log" "regexp" - "strings" "time" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/service/codebuild" + "github.com/hashicorp/terraform/helper/customdiff" "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsCodeBuildProject() *schema.Resource { @@ -38,9 +39,12 @@ func resourceAwsCodeBuildProject() *schema.Resource { Optional: true, }, "namespace_type": { - Type: schema.TypeString, - Optional: true, - ValidateFunc: validateAwsCodeBuildArifactsNamespaceType, + Type: schema.TypeString, + Optional: true, + ValidateFunc: validation.StringInSlice([]string{ + codebuild.ArtifactNamespaceNone, + codebuild.ArtifactNamespaceBuildId, + }, false), }, "packaging": { Type: schema.TypeString, @@ -51,19 +55,51 @@ func resourceAwsCodeBuildProject() *schema.Resource { Optional: true, }, "type": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateAwsCodeBuildArifactsType, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + codebuild.ArtifactsTypeCodepipeline, + codebuild.ArtifactsTypeS3, + codebuild.ArtifactsTypeNoArtifacts, + }, false), }, }, }, Set: resourceAwsCodeBuildProjectArtifactsHash, }, + "cache": { + Type: schema.TypeList, + Optional: true, + MaxItems: 1, + DiffSuppressFunc: func(k, old, new string, d *schema.ResourceData) bool { + if old == "1" && new == "0" { + return true + } + return false + }, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "type": { + Type: schema.TypeString, + Optional: true, + Default: codebuild.CacheTypeNoCache, + ValidateFunc: validation.StringInSlice([]string{ + codebuild.CacheTypeNoCache, + codebuild.CacheTypeS3, + }, false), + }, + "location": { + Type: schema.TypeString, + Optional: true, + }, + }, + }, + }, "description": { Type: schema.TypeString, Optional: true, Computed: true, - ValidateFunc: validateAwsCodeBuildProjectDescription, + ValidateFunc: validateMaxLength(255), }, "encryption_key": { Type: schema.TypeString, @@ -77,9 +113,13 @@ func resourceAwsCodeBuildProject() *schema.Resource { Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "compute_type": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateAwsCodeBuildEnvironmentComputeType, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + codebuild.ComputeTypeBuildGeneral1Small, + codebuild.ComputeTypeBuildGeneral1Medium, + codebuild.ComputeTypeBuildGeneral1Large, + }, false), }, "environment_variable": { Type: schema.TypeList, @@ -103,9 +143,11 @@ func resourceAwsCodeBuildProject() *schema.Resource { Required: true, }, "type": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateAwsCodeBuildEnvironmentType, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + codebuild.EnvironmentTypeLinuxContainer, + }, false), }, "privileged_mode": { Type: schema.TypeBool, @@ -140,9 +182,11 @@ func resourceAwsCodeBuildProject() *schema.Resource { Optional: true, }, "type": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateAwsCodeBuildSourceAuthType, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + codebuild.SourceAuthTypeOauth, + }, false), }, }, }, @@ -158,9 +202,16 @@ func resourceAwsCodeBuildProject() *schema.Resource { Optional: true, }, "type": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateAwsCodeBuildSourceType, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + codebuild.SourceTypeCodecommit, + codebuild.SourceTypeCodepipeline, + codebuild.SourceTypeGithub, + codebuild.SourceTypeS3, + codebuild.SourceTypeBitbucket, + codebuild.SourceTypeGithubEnterprise, + }, false), }, }, }, @@ -171,14 +222,14 @@ func resourceAwsCodeBuildProject() *schema.Resource { "timeout": { Type: schema.TypeInt, Optional: true, - ValidateFunc: validateAwsCodeBuildTimeout, + ValidateFunc: validation.IntBetween(5, 480), Removed: "This field has been removed. Please use build_timeout instead", }, "build_timeout": { Type: schema.TypeInt, Optional: true, Default: "60", - ValidateFunc: validateAwsCodeBuildTimeout, + ValidateFunc: validation.IntBetween(5, 480), }, "tags": tagsSchema(), "vpc_config": { @@ -209,6 +260,20 @@ func resourceAwsCodeBuildProject() *schema.Resource { }, }, }, + + CustomizeDiff: customdiff.Sequence( + func(diff *schema.ResourceDiff, v interface{}) error { + // Plan time validation for cache location + cacheType, cacheTypeOk := diff.GetOk("cache.0.type") + if !cacheTypeOk || cacheType.(string) == codebuild.CacheTypeNoCache { + return nil + } + if v, ok := diff.GetOk("cache.0.location"); ok && v.(string) != "" { + return nil + } + return fmt.Errorf(`cache location is required when cache type is %q`, cacheType.(string)) + }, + ), } } @@ -226,6 +291,10 @@ func resourceAwsCodeBuildProjectCreate(d *schema.ResourceData, meta interface{}) Artifacts: &projectArtifacts, } + if v, ok := d.GetOk("cache"); ok { + params.Cache = expandProjectCache(v.([]interface{})) + } + if v, ok := d.GetOk("description"); ok { params.Description = aws.String(v.(string)) } @@ -312,6 +381,22 @@ func expandProjectArtifacts(d *schema.ResourceData) codebuild.ProjectArtifacts { return projectArtifacts } +func expandProjectCache(s []interface{}) *codebuild.ProjectCache { + var projectCache *codebuild.ProjectCache + + data := s[0].(map[string]interface{}) + + projectCache = &codebuild.ProjectCache{ + Type: aws.String(data["type"].(string)), + } + + if v, ok := data["location"]; ok { + projectCache.Location = aws.String(v.(string)) + } + + return projectCache +} + func expandProjectEnvironment(d *schema.ResourceData) *codebuild.ProjectEnvironment { configs := d.Get("environment").(*schema.Set).List() @@ -438,6 +523,10 @@ func resourceAwsCodeBuildProjectRead(d *schema.ResourceData, meta interface{}) e return err } + if err := d.Set("cache", flattenAwsCodebuildProjectCache(project.Cache)); err != nil { + return err + } + if err := d.Set("source", flattenAwsCodeBuildProjectSource(project.Source)); err != nil { return err } @@ -485,6 +574,16 @@ func resourceAwsCodeBuildProjectUpdate(d *schema.ResourceData, meta interface{}) params.VpcConfig = expandCodeBuildVpcConfig(d.Get("vpc_config").([]interface{})) } + if d.HasChange("cache") { + if v, ok := d.GetOk("cache"); ok { + params.Cache = expandProjectCache(v.([]interface{})) + } else { + params.Cache = &codebuild.ProjectCache{ + Type: aws.String("NO_CACHE"), + } + } + } + if d.HasChange("description") { params.Description = aws.String(d.Get("description").(string)) } @@ -567,6 +666,19 @@ func flattenAwsCodeBuildProjectArtifacts(artifacts *codebuild.ProjectArtifacts) return &artifactSet } +func flattenAwsCodebuildProjectCache(cache *codebuild.ProjectCache) []interface{} { + if cache == nil { + return []interface{}{} + } + + values := map[string]interface{}{ + "location": aws.StringValue(cache.Location), + "type": aws.StringValue(cache.Type), + } + + return []interface{}{values} +} + func flattenAwsCodeBuildProjectEnvironment(environment *codebuild.ProjectEnvironment) []interface{} { envConfig := map[string]interface{}{} @@ -708,33 +820,6 @@ func sourceAuthToMap(sourceAuth *codebuild.SourceAuth) map[string]interface{} { return auth } -func validateAwsCodeBuildArifactsType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - types := map[string]bool{ - "CODEPIPELINE": true, - "NO_ARTIFACTS": true, - "S3": true, - } - - if !types[value] { - errors = append(errors, fmt.Errorf("CodeBuild: Arifacts Type can only be CODEPIPELINE / NO_ARTIFACTS / S3")) - } - return -} - -func validateAwsCodeBuildArifactsNamespaceType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - types := map[string]bool{ - "NONE": true, - "BUILD_ID": true, - } - - if !types[value] { - errors = append(errors, fmt.Errorf("CodeBuild: Arifacts Namespace Type can only be NONE / BUILD_ID")) - } - return -} - func validateAwsCodeBuildProjectName(v interface{}, k string) (ws []string, errors []error) { value := v.(string) if !regexp.MustCompile(`^[A-Za-z0-9]`).MatchString(value) { @@ -754,80 +839,3 @@ func validateAwsCodeBuildProjectName(v interface{}, k string) (ws []string, erro return } - -func validateAwsCodeBuildProjectDescription(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 255 { - errors = append(errors, fmt.Errorf("%q cannot be greater than 255 characters", value)) - } - return -} - -func validateAwsCodeBuildEnvironmentComputeType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - types := map[string]bool{ - "BUILD_GENERAL1_SMALL": true, - "BUILD_GENERAL1_MEDIUM": true, - "BUILD_GENERAL1_LARGE": true, - } - - if !types[value] { - errors = append(errors, fmt.Errorf("CodeBuild: Environment Compute Type can only be BUILD_GENERAL1_SMALL / BUILD_GENERAL1_MEDIUM / BUILD_GENERAL1_LARGE")) - } - return -} - -func validateAwsCodeBuildEnvironmentType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - types := map[string]bool{ - "LINUX_CONTAINER": true, - } - - if !types[value] { - errors = append(errors, fmt.Errorf("CodeBuild: Environment Type can only be LINUX_CONTAINER")) - } - return -} - -func validateAwsCodeBuildSourceType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - types := map[string]bool{ - codebuild.SourceTypeBitbucket: true, - codebuild.SourceTypeCodecommit: true, - codebuild.SourceTypeCodepipeline: true, - codebuild.SourceTypeGithub: true, - codebuild.SourceTypeS3: true, - } - s := make([]string, 0, len(types)) - - for key, _ := range types { - s = append(s, key) - } - - if !types[value] { - strings.Join(s, ", ") - errors = append(errors, fmt.Errorf("CodeBuild: Source Type can only be one of: %s", strings.Join(s, ", "))) - } - return -} - -func validateAwsCodeBuildSourceAuthType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - types := map[string]bool{ - "OAUTH": true, - } - - if !types[value] { - errors = append(errors, fmt.Errorf("CodeBuild: Source Auth Type can only be OAUTH")) - } - return -} - -func validateAwsCodeBuildTimeout(v interface{}, k string) (ws []string, errors []error) { - value := v.(int) - - if value < 5 || value > 480 { - errors = append(errors, fmt.Errorf("%q must be greater than 5 minutes and less than 480 minutes (8 hours)", value)) - } - return -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codecommit_repository.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codecommit_repository.go index a477c274e5a8..365fb29a86b6 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codecommit_repository.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codecommit_repository.go @@ -21,30 +21,16 @@ func resourceAwsCodeCommitRepository() *schema.Resource { Schema: map[string]*schema.Schema{ "repository_name": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 100 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 100 characters", k)) - } - return - }, + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validateMaxLength(100), }, "description": { - Type: schema.TypeString, - Optional: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 1000 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 1000 characters", k)) - } - return - }, + Type: schema.TypeString, + Optional: true, + ValidateFunc: validateMaxLength(1000), }, "arn": { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codedeploy_deployment_config.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codedeploy_deployment_config.go index 10130dc765ab..886e4f25ad03 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codedeploy_deployment_config.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codedeploy_deployment_config.go @@ -8,6 +8,7 @@ import ( "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/codedeploy" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsCodeDeployDeploymentConfig() *schema.Resource { @@ -31,11 +32,13 @@ func resourceAwsCodeDeployDeploymentConfig() *schema.Resource { Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "type": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateMinimumHealtyHostsType, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + codedeploy.MinimumHealthyHostsTypeHostCount, + codedeploy.MinimumHealthyHostsTypeFleetPercent, + }, false), }, - "value": { Type: schema.TypeInt, Optional: true, @@ -141,12 +144,3 @@ func flattenAwsCodeDeployConfigMinimumHealthHosts(hosts *codedeploy.MinimumHealt return result } - -func validateMinimumHealtyHostsType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != "FLEET_PERCENT" && value != "HOST_COUNT" { - errors = append(errors, fmt.Errorf( - "%q must be one of \"FLEET_PERCENT\" or \"HOST_COUNT\"", k)) - } - return -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codedeploy_deployment_group.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codedeploy_deployment_group.go index 30af3ecc1d3c..956932f0ac95 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codedeploy_deployment_group.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codedeploy_deployment_group.go @@ -11,6 +11,7 @@ import ( "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awserr" @@ -26,30 +27,16 @@ func resourceAwsCodeDeployDeploymentGroup() *schema.Resource { Schema: map[string]*schema.Schema{ "app_name": &schema.Schema{ - Type: schema.TypeString, - Required: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 100 { - errors = append(errors, fmt.Errorf( - "%q cannot exceed 100 characters", k)) - } - return - }, + Type: schema.TypeString, + Required: true, + ValidateFunc: validateMaxLength(100), }, "deployment_group_name": &schema.Schema{ - Type: schema.TypeString, - Required: true, - ForceNew: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 100 { - errors = append(errors, fmt.Errorf( - "%q cannot exceed 100 characters", k)) - } - return - }, + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validateMaxLength(100), }, "deployment_style": &schema.Schema{ @@ -60,15 +47,20 @@ func resourceAwsCodeDeployDeploymentGroup() *schema.Resource { Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "deployment_option": &schema.Schema{ - Type: schema.TypeString, - Optional: true, - ValidateFunc: validateDeploymentOption, + Type: schema.TypeString, + Optional: true, + ValidateFunc: validation.StringInSlice([]string{ + codedeploy.DeploymentOptionWithTrafficControl, + codedeploy.DeploymentOptionWithoutTrafficControl, + }, false), }, - "deployment_type": &schema.Schema{ - Type: schema.TypeString, - Optional: true, - ValidateFunc: validateDeploymentType, + Type: schema.TypeString, + Optional: true, + ValidateFunc: validation.StringInSlice([]string{ + codedeploy.DeploymentTypeInPlace, + codedeploy.DeploymentTypeBlueGreen, + }, false), }, }, }, @@ -88,9 +80,12 @@ func resourceAwsCodeDeployDeploymentGroup() *schema.Resource { Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "action_on_timeout": &schema.Schema{ - Type: schema.TypeString, - Optional: true, - ValidateFunc: validateDeploymentReadyOption, + Type: schema.TypeString, + Optional: true, + ValidateFunc: validation.StringInSlice([]string{ + codedeploy.DeploymentReadyActionContinueDeployment, + codedeploy.DeploymentReadyActionStopDeployment, + }, false), }, "wait_time_in_minutes": &schema.Schema{ Type: schema.TypeInt, @@ -108,9 +103,12 @@ func resourceAwsCodeDeployDeploymentGroup() *schema.Resource { Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "action": &schema.Schema{ - Type: schema.TypeString, - Optional: true, - ValidateFunc: validateGreenFleetProvisioningOption, + Type: schema.TypeString, + Optional: true, + ValidateFunc: validation.StringInSlice([]string{ + codedeploy.GreenFleetProvisioningActionDiscoverExisting, + codedeploy.GreenFleetProvisioningActionCopyAutoScalingGroup, + }, false), }, }, }, @@ -123,9 +121,12 @@ func resourceAwsCodeDeployDeploymentGroup() *schema.Resource { Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "action": &schema.Schema{ - Type: schema.TypeString, - Optional: true, - ValidateFunc: validateBlueInstanceTerminationOption, + Type: schema.TypeString, + Optional: true, + ValidateFunc: validation.StringInSlice([]string{ + codedeploy.InstanceActionTerminate, + codedeploy.InstanceActionKeepAlive, + }, false), }, "termination_wait_time_in_minutes": &schema.Schema{ Type: schema.TypeInt, @@ -238,17 +239,10 @@ func resourceAwsCodeDeployDeploymentGroup() *schema.Resource { }, "deployment_config_name": &schema.Schema{ - Type: schema.TypeString, - Optional: true, - Default: "CodeDeployDefault.OneAtATime", - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 100 { - errors = append(errors, fmt.Errorf( - "%q cannot exceed 100 characters", k)) - } - return - }, + Type: schema.TypeString, + Optional: true, + Default: "CodeDeployDefault.OneAtATime", + ValidateFunc: validateMaxLength(100), }, "ec2_tag_filter": &schema.Schema{ @@ -311,8 +305,19 @@ func resourceAwsCodeDeployDeploymentGroup() *schema.Resource { Required: true, Set: schema.HashString, Elem: &schema.Schema{ - Type: schema.TypeString, - ValidateFunc: validateTriggerEvent, + Type: schema.TypeString, + ValidateFunc: validation.StringInSlice([]string{ + codedeploy.TriggerEventTypeDeploymentStart, + codedeploy.TriggerEventTypeDeploymentSuccess, + codedeploy.TriggerEventTypeDeploymentFailure, + codedeploy.TriggerEventTypeDeploymentStop, + codedeploy.TriggerEventTypeDeploymentRollback, + codedeploy.TriggerEventTypeDeploymentReady, + codedeploy.TriggerEventTypeInstanceStart, + codedeploy.TriggerEventTypeInstanceSuccess, + codedeploy.TriggerEventTypeInstanceFailure, + codedeploy.TriggerEventTypeInstanceReady, + }, false), }, }, @@ -1097,89 +1102,3 @@ func loadBalancerInfoHash(v interface{}) int { return hashcode.String(buf.String()) } - -func validateTriggerEvent(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - triggerEvents := map[string]bool{ - "DeploymentStart": true, - "DeploymentStop": true, - "DeploymentSuccess": true, - "DeploymentFailure": true, - "DeploymentRollback": true, - "DeploymentReady": true, - "InstanceStart": true, - "InstanceSuccess": true, - "InstanceFailure": true, - "InstanceReady": true, - } - - if !triggerEvents[value] { - errors = append(errors, fmt.Errorf("%q must be a valid event type value: %q", k, value)) - } - return -} - -func validateDeploymentOption(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - validOptions := map[string]bool{ - "WITH_TRAFFIC_CONTROL": true, - "WITHOUT_TRAFFIC_CONTROL": true, - } - - if !validOptions[value] { - errors = append(errors, fmt.Errorf("%q must be a valid deployment option: %q", k, value)) - } - return -} - -func validateDeploymentType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - validTypes := map[string]bool{ - "IN_PLACE": true, - "BLUE_GREEN": true, - } - - if !validTypes[value] { - errors = append(errors, fmt.Errorf("%q must be a valid deployment type: %q", k, value)) - } - return -} - -func validateDeploymentReadyOption(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - validOptions := map[string]bool{ - "CONTINUE_DEPLOYMENT": true, - "STOP_DEPLOYMENT": true, - } - - if !validOptions[value] { - errors = append(errors, fmt.Errorf("%q must be a valid deployment_ready_option:action_on_timeout value: %q", k, value)) - } - return -} - -func validateGreenFleetProvisioningOption(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - validOptions := map[string]bool{ - "DISCOVER_EXISTING": true, - "COPY_AUTO_SCALING_GROUP": true, - } - - if !validOptions[value] { - errors = append(errors, fmt.Errorf("%q must be a valid green_fleet_provisioning_option:action value: %q", k, value)) - } - return -} - -func validateBlueInstanceTerminationOption(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - validOptions := map[string]bool{ - "TERMINATE": true, - "KEEP_ALIVE": true, - } - - if !validOptions[value] { - errors = append(errors, fmt.Errorf("%q must be a valid terminate_blue_instances_on_deployment_success:action value: %q", k, value)) - } - return -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codepipeline.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codepipeline.go index a918d84ae52d..ff35e5b8f136 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codepipeline.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_codepipeline.go @@ -11,6 +11,7 @@ import ( "github.com/aws/aws-sdk-go/service/codepipeline" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsCodePipeline() *schema.Resource { @@ -52,9 +53,11 @@ func resourceAwsCodePipeline() *schema.Resource { }, "type": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateAwsCodePipelineArtifactStoreType, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + codepipeline.ArtifactStoreTypeS3, + }, false), }, "encryption_key": { @@ -69,9 +72,11 @@ func resourceAwsCodePipeline() *schema.Resource { }, "type": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateAwsCodePipelineEncryptionKeyType, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + codepipeline.EncryptionKeyTypeKms, + }, false), }, }, }, @@ -99,14 +104,25 @@ func resourceAwsCodePipeline() *schema.Resource { Optional: true, }, "category": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateAwsCodePipelineStageActionCategory, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + codepipeline.ActionCategorySource, + codepipeline.ActionCategoryBuild, + codepipeline.ActionCategoryDeploy, + codepipeline.ActionCategoryTest, + codepipeline.ActionCategoryInvoke, + codepipeline.ActionCategoryApproval, + }, false), }, "owner": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateAwsCodePipelineStageActionOwner, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + codepipeline.ActionOwnerAws, + codepipeline.ActionOwnerThirdParty, + codepipeline.ActionOwnerCustom, + }, false), }, "provider": { Type: schema.TypeString, @@ -148,50 +164,6 @@ func resourceAwsCodePipeline() *schema.Resource { }, } } -func validateAwsCodePipelineEncryptionKeyType(v interface{}, k string) (ws []string, errors []error) { - if v.(string) != "KMS" { - errors = append(errors, fmt.Errorf("CodePipeline: encryption_key type can only be KMS")) - } - return -} - -func validateAwsCodePipelineArtifactStoreType(v interface{}, k string) (ws []string, errors []error) { - if v.(string) != "S3" { - errors = append(errors, fmt.Errorf("CodePipeline: artifact_store type can only be S3")) - } - return -} - -func validateAwsCodePipelineStageActionCategory(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - types := map[string]bool{ - "Source": true, - "Build": true, - "Deploy": true, - "Test": true, - "Invoke": true, - "Approval": true, - } - - if !types[value] { - errors = append(errors, fmt.Errorf("CodePipeline: category can only be one of Source | Build | Deploy | Test | Invoke | Approval")) - } - return -} - -func validateAwsCodePipelineStageActionOwner(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - types := map[string]bool{ - "AWS": true, - "ThirdParty": true, - "Custom": true, - } - - if !types[value] { - errors = append(errors, fmt.Errorf("CodePipeline: owner can only be one of AWS | ThirdParty | Custom")) - } - return -} func validateAwsCodePipelineStageActionConfiguration(v interface{}, k string) (ws []string, errors []error) { for k := range v.(map[string]interface{}) { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cognito_identity_pool_roles_attachment.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cognito_identity_pool_roles_attachment.go index 5030331b9617..5e1f5324d9ca 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cognito_identity_pool_roles_attachment.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cognito_identity_pool_roles_attachment.go @@ -13,6 +13,7 @@ import ( "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsCognitoIdentityPoolRolesAttachment() *schema.Resource { @@ -39,9 +40,12 @@ func resourceAwsCognitoIdentityPoolRolesAttachment() *schema.Resource { Required: true, }, "ambiguous_role_resolution": { - Type: schema.TypeString, - ValidateFunc: validateCognitoRoleMappingsAmbiguousRoleResolution, - Optional: true, // Required if Type equals Token or Rules. + Type: schema.TypeString, + Optional: true, // Required if Type equals Token or Rules. + ValidateFunc: validation.StringInSlice([]string{ + cognitoidentity.AmbiguousRoleResolutionTypeAuthenticatedRole, + cognitoidentity.AmbiguousRoleResolutionTypeDeny, + }, false), }, "mapping_rule": { Type: schema.TypeList, @@ -55,9 +59,14 @@ func resourceAwsCognitoIdentityPoolRolesAttachment() *schema.Resource { ValidateFunc: validateCognitoRoleMappingsRulesClaim, }, "match_type": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateCognitoRoleMappingsRulesMatchType, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + cognitoidentity.MappingRuleMatchTypeEquals, + cognitoidentity.MappingRuleMatchTypeContains, + cognitoidentity.MappingRuleMatchTypeStartsWith, + cognitoidentity.MappingRuleMatchTypeNotEqual, + }, false), }, "role_arn": { Type: schema.TypeString, @@ -67,15 +76,18 @@ func resourceAwsCognitoIdentityPoolRolesAttachment() *schema.Resource { "value": { Type: schema.TypeString, Required: true, - ValidateFunc: validateCognitoRoleMappingsRulesValue, + ValidateFunc: validation.StringLenBetween(1, 128), }, }, }, }, "type": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateCognitoRoleMappingsType, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + cognitoidentity.RoleMappingTypeToken, + cognitoidentity.RoleMappingTypeRules, + }, false), }, }, }, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cognito_user_pool.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cognito_user_pool.go index 5f24243e401d..25ef24a9b974 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cognito_user_pool.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cognito_user_pool.go @@ -68,7 +68,7 @@ func resourceAwsCognitoUserPool() *schema.Resource { Type: schema.TypeInt, Optional: true, Default: 7, - ValidateFunc: validateIntegerInRange(0, 90), + ValidateFunc: validation.IntBetween(0, 90), }, }, }, @@ -79,8 +79,12 @@ func resourceAwsCognitoUserPool() *schema.Resource { Optional: true, ForceNew: true, Elem: &schema.Schema{ - Type: schema.TypeString, - ValidateFunc: validateCognitoUserPoolAliasAttribute, + Type: schema.TypeString, + ValidateFunc: validation.StringInSlice([]string{ + cognitoidentityprovider.AliasAttributeTypeEmail, + cognitoidentityprovider.AliasAttributeTypePhoneNumber, + cognitoidentityprovider.AliasAttributeTypePreferredUsername, + }, false), }, ConflictsWith: []string{"username_attributes"}, }, @@ -94,8 +98,11 @@ func resourceAwsCognitoUserPool() *schema.Resource { Type: schema.TypeSet, Optional: true, Elem: &schema.Schema{ - Type: schema.TypeString, - ValidateFunc: validateCognitoUserPoolAutoVerifiedAttribute, + Type: schema.TypeString, + ValidateFunc: validation.StringInSlice([]string{ + cognitoidentityprovider.VerifiedAttributeTypePhoneNumber, + cognitoidentityprovider.VerifiedAttributeTypeEmail, + }, false), }, }, @@ -218,10 +225,14 @@ func resourceAwsCognitoUserPool() *schema.Resource { }, "mfa_configuration": { - Type: schema.TypeString, - Optional: true, - Default: cognitoidentityprovider.UserPoolMfaTypeOff, - ValidateFunc: validateCognitoUserPoolMfaConfiguration, + Type: schema.TypeString, + Optional: true, + Default: cognitoidentityprovider.UserPoolMfaTypeOff, + ValidateFunc: validation.StringInSlice([]string{ + cognitoidentityprovider.UserPoolMfaTypeOff, + cognitoidentityprovider.UserPoolMfaTypeOn, + cognitoidentityprovider.UserPoolMfaTypeOptional, + }, false), }, "name": { @@ -240,7 +251,7 @@ func resourceAwsCognitoUserPool() *schema.Resource { "minimum_length": { Type: schema.TypeInt, Optional: true, - ValidateFunc: validateIntegerInRange(6, 99), + ValidateFunc: validation.IntBetween(6, 99), }, "require_lowercase": { Type: schema.TypeBool, @@ -273,6 +284,7 @@ func resourceAwsCognitoUserPool() *schema.Resource { "attribute_data_type": { Type: schema.TypeString, Required: true, + ForceNew: true, ValidateFunc: validation.StringInSlice([]string{ cognitoidentityprovider.AttributeDataTypeString, cognitoidentityprovider.AttributeDataTypeNumber, @@ -283,29 +295,35 @@ func resourceAwsCognitoUserPool() *schema.Resource { "developer_only_attribute": { Type: schema.TypeBool, Optional: true, + ForceNew: true, }, "mutable": { Type: schema.TypeBool, Optional: true, + ForceNew: true, }, "name": { Type: schema.TypeString, Required: true, + ForceNew: true, ValidateFunc: validateCognitoUserPoolSchemaName, }, "number_attribute_constraints": { Type: schema.TypeList, Optional: true, + ForceNew: true, MaxItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "min_value": { Type: schema.TypeString, Optional: true, + ForceNew: true, }, "max_value": { Type: schema.TypeString, Optional: true, + ForceNew: true, }, }, }, @@ -313,20 +331,24 @@ func resourceAwsCognitoUserPool() *schema.Resource { "required": { Type: schema.TypeBool, Optional: true, + ForceNew: true, }, "string_attribute_constraints": { Type: schema.TypeList, Optional: true, + ForceNew: true, MaxItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "min_length": { Type: schema.TypeString, Optional: true, + ForceNew: true, }, "max_length": { Type: schema.TypeString, Optional: true, + ForceNew: true, }, }, }, @@ -390,10 +412,13 @@ func resourceAwsCognitoUserPool() *schema.Resource { Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "default_email_option": { - Type: schema.TypeString, - Optional: true, - Default: cognitoidentityprovider.DefaultEmailOptionTypeConfirmWithCode, - ValidateFunc: validateCognitoUserPoolTemplateDefaultEmailOption, + Type: schema.TypeString, + Optional: true, + Default: cognitoidentityprovider.DefaultEmailOptionTypeConfirmWithCode, + ValidateFunc: validation.StringInSlice([]string{ + cognitoidentityprovider.DefaultEmailOptionTypeConfirmWithLink, + cognitoidentityprovider.DefaultEmailOptionTypeConfirmWithCode, + }, false), }, "email_message": { Type: schema.TypeString, @@ -625,9 +650,8 @@ func resourceAwsCognitoUserPoolRead(d *schema.ResourceData, meta interface{}) er Resource: fmt.Sprintf("userpool/%s", d.Id()), } d.Set("arn", arn.String()) - if resp.UserPool.AutoVerifiedAttributes != nil { - d.Set("auto_verified_attributes", flattenStringList(resp.UserPool.AutoVerifiedAttributes)) - } + d.Set("auto_verified_attributes", flattenStringList(resp.UserPool.AutoVerifiedAttributes)) + if resp.UserPool.EmailVerificationSubject != nil { d.Set("email_verification_subject", *resp.UserPool.EmailVerificationSubject) } @@ -661,6 +685,14 @@ func resourceAwsCognitoUserPoolRead(d *schema.ResourceData, meta interface{}) er } } + var configuredSchema []interface{} + if v, ok := d.GetOk("schema"); ok { + configuredSchema = v.(*schema.Set).List() + } + if err := d.Set("schema", flattenCognitoUserPoolSchema(expandCognitoUserPoolSchema(configuredSchema), resp.UserPool.SchemaAttributes)); err != nil { + return fmt.Errorf("Failed setting schema: %s", err) + } + if err := d.Set("sms_configuration", flattenCognitoUserPoolSmsConfiguration(resp.UserPool.SmsConfiguration)); err != nil { return fmt.Errorf("Failed setting sms_configuration: %s", err) } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cognito_user_pool_client.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cognito_user_pool_client.go index e848774c8b2c..692f8bcf9fce 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cognito_user_pool_client.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_cognito_user_pool_client.go @@ -78,7 +78,7 @@ func resourceAwsCognitoUserPoolClient() *schema.Resource { Type: schema.TypeInt, Optional: true, Default: 30, - ValidateFunc: validateIntegerInRange(0, 3650), + ValidateFunc: validation.IntBetween(0, 3650), }, "allowed_oauth_flows": { @@ -103,8 +103,13 @@ func resourceAwsCognitoUserPoolClient() *schema.Resource { "allowed_oauth_scopes": { Type: schema.TypeSet, Optional: true, + MaxItems: 25, Elem: &schema.Schema{ Type: schema.TypeString, + // https://docs.aws.amazon.com/cognito/latest/developerguide/authorization-endpoint.html + // System reserved scopes are openid, email, phone, profile, and aws.cognito.signin.user.admin. + // https://docs.aws.amazon.com/cognito-user-identity-pools/latest/APIReference/API_CreateUserPoolClient.html#CognitoUserPools-CreateUserPoolClient-request-AllowedOAuthScopes + // Constraints seem like to be designed for custom scopes which are not supported yet? }, }, @@ -292,7 +297,7 @@ func resourceAwsCognitoUserPoolClientUpdate(d *schema.ResourceData, meta interfa } if d.HasChange("callback_urls") { - params.ReadAttributes = expandStringList(d.Get("callback_urls").([]interface{})) + params.CallbackURLs = expandStringList(d.Get("callback_urls").([]interface{})) } if d.HasChange("default_redirect_uri") { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_config_config_rule.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_config_config_rule.go index cc18d19956e5..7d10647ddb84 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_config_config_rule.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_config_config_rule.go @@ -9,6 +9,7 @@ import ( "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awserr" @@ -53,7 +54,7 @@ func resourceAwsConfigConfigRule() *schema.Resource { "maximum_execution_frequency": { Type: schema.TypeString, Optional: true, - ValidateFunc: validateConfigExecutionFrequency, + ValidateFunc: validateConfigExecutionFrequency(), }, "scope": { Type: schema.TypeList, @@ -96,9 +97,12 @@ func resourceAwsConfigConfigRule() *schema.Resource { Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "owner": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateConfigRuleSourceOwner, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + configservice.OwnerCustomLambda, + configservice.OwnerAws, + }, false), }, "source_detail": { Type: schema.TypeSet, @@ -115,7 +119,7 @@ func resourceAwsConfigConfigRule() *schema.Resource { "maximum_execution_frequency": { Type: schema.TypeString, Optional: true, - ValidateFunc: validateConfigExecutionFrequency, + ValidateFunc: validateConfigExecutionFrequency(), }, "message_type": { Type: schema.TypeString, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_config_delivery_channel.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_config_delivery_channel.go index 78501fe8c616..bd3b70e170f0 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_config_delivery_channel.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_config_delivery_channel.go @@ -54,7 +54,7 @@ func resourceAwsConfigDeliveryChannel() *schema.Resource { "delivery_frequency": { Type: schema.TypeString, Optional: true, - ValidateFunc: validateConfigExecutionFrequency, + ValidateFunc: validateConfigExecutionFrequency(), }, }, }, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_event_subscription.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_event_subscription.go index 4415bbcc1b21..aca39ccc15be 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_event_subscription.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_event_subscription.go @@ -6,7 +6,6 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/rds" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" @@ -21,7 +20,16 @@ func resourceAwsDbEventSubscription() *schema.Resource { Importer: &schema.ResourceImporter{ State: resourceAwsDbEventSubscriptionImport, }, + Timeouts: &schema.ResourceTimeout{ + Create: schema.DefaultTimeout(40 * time.Minute), + Delete: schema.DefaultTimeout(40 * time.Minute), + Update: schema.DefaultTimeout(40 * time.Minute), + }, Schema: map[string]*schema.Schema{ + "arn": { + Type: schema.TypeString, + Computed: true, + }, "name": { Type: schema.TypeString, Required: true, @@ -65,7 +73,7 @@ func resourceAwsDbEventSubscription() *schema.Resource { } func resourceAwsDbEventSubscriptionCreate(d *schema.ResourceData, meta interface{}) error { - rdsconn := meta.(*AWSClient).rdsconn + conn := meta.(*AWSClient).rdsconn name := d.Get("name").(string) tags := tagsFromMapRDS(d.Get("tags").(map[string]interface{})) @@ -93,19 +101,25 @@ func resourceAwsDbEventSubscriptionCreate(d *schema.ResourceData, meta interface log.Println("[DEBUG] Create RDS Event Subscription:", request) - _, err := rdsconn.CreateEventSubscription(request) - if err != nil { + output, err := conn.CreateEventSubscription(request) + if err != nil || output.EventSubscription == nil { return fmt.Errorf("Error creating RDS Event Subscription %s: %s", name, err) } + d.SetId(aws.StringValue(output.EventSubscription.CustSubscriptionId)) + + if err := setTagsRDS(conn, d, aws.StringValue(output.EventSubscription.EventSubscriptionArn)); err != nil { + return fmt.Errorf("Error creating RDS Event Subscription (%s) tags: %s", d.Id(), err) + } + log.Println( "[INFO] Waiting for RDS Event Subscription to be ready") stateConf := &resource.StateChangeConf{ Pending: []string{"creating"}, Target: []string{"active"}, - Refresh: resourceAwsDbEventSubscriptionRefreshFunc(d, meta.(*AWSClient).rdsconn), - Timeout: 40 * time.Minute, + Refresh: resourceAwsDbEventSubscriptionRefreshFunc(d.Id(), conn), + Timeout: d.Timeout(schema.TimeoutCreate), MinTimeout: 10 * time.Second, Delay: 30 * time.Second, // Wait 30 secs before starting } @@ -120,16 +134,19 @@ func resourceAwsDbEventSubscriptionCreate(d *schema.ResourceData, meta interface } func resourceAwsDbEventSubscriptionRead(d *schema.ResourceData, meta interface{}) error { - sub, err := resourceAwsDbEventSubscriptionRetrieve(d.Get("name").(string), meta.(*AWSClient).rdsconn) + conn := meta.(*AWSClient).rdsconn + + sub, err := resourceAwsDbEventSubscriptionRetrieve(d.Get("name").(string), conn) if err != nil { return fmt.Errorf("Error retrieving RDS Event Subscription %s: %s", d.Id(), err) } if sub == nil { + log.Printf("[WARN] RDS Event Subscription (%s) not found - removing from state", d.Id()) d.SetId("") return nil } - d.SetId(*sub.CustSubscriptionId) + d.Set("arn", sub.EventSubscriptionArn) if err := d.Set("name", sub.CustSubscriptionId); err != nil { return err } @@ -153,39 +170,34 @@ func resourceAwsDbEventSubscriptionRead(d *schema.ResourceData, meta interface{} } // list tags for resource - // set tags - conn := meta.(*AWSClient).rdsconn - if arn, err := buildRDSEventSubscriptionARN(d.Get("customer_aws_id").(string), d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).region); err != nil { - log.Printf("[DEBUG] Error building ARN for RDS Event Subscription, not setting Tags for Event Subscription %s", *sub.CustSubscriptionId) - } else { - resp, err := conn.ListTagsForResource(&rds.ListTagsForResourceInput{ - ResourceName: aws.String(arn), - }) + resp, err := conn.ListTagsForResource(&rds.ListTagsForResourceInput{ + ResourceName: sub.EventSubscriptionArn, + }) - if err != nil { - log.Printf("[DEBUG] Error retrieving tags for ARN: %s", arn) - } + if err != nil { + log.Printf("[DEBUG] Error retrieving tags for ARN: %s", aws.StringValue(sub.EventSubscriptionArn)) + } - var dt []*rds.Tag - if len(resp.TagList) > 0 { - dt = resp.TagList - } - d.Set("tags", tagsToMapRDS(dt)) + var dt []*rds.Tag + if len(resp.TagList) > 0 { + dt = resp.TagList + } + if err := d.Set("tags", tagsToMapRDS(dt)); err != nil { + return fmt.Errorf("error setting tags: %s", err) } return nil } -func resourceAwsDbEventSubscriptionRetrieve( - name string, rdsconn *rds.RDS) (*rds.EventSubscription, error) { +func resourceAwsDbEventSubscriptionRetrieve(name string, conn *rds.RDS) (*rds.EventSubscription, error) { request := &rds.DescribeEventSubscriptionsInput{ SubscriptionName: aws.String(name), } - describeResp, err := rdsconn.DescribeEventSubscriptions(request) + describeResp, err := conn.DescribeEventSubscriptions(request) if err != nil { - if rdserr, ok := err.(awserr.Error); ok && rdserr.Code() == "SubscriptionNotFound" { + if isAWSErr(err, rds.ErrCodeSubscriptionNotFoundFault, "") { log.Printf("[WARN] No RDS Event Subscription by name (%s) found", name) return nil, nil } @@ -200,7 +212,7 @@ func resourceAwsDbEventSubscriptionRetrieve( } func resourceAwsDbEventSubscriptionUpdate(d *schema.ResourceData, meta interface{}) error { - rdsconn := meta.(*AWSClient).rdsconn + conn := meta.(*AWSClient).rdsconn d.Partial(true) requestUpdate := false @@ -237,7 +249,7 @@ func resourceAwsDbEventSubscriptionUpdate(d *schema.ResourceData, meta interface log.Printf("[DEBUG] Send RDS Event Subscription modification request: %#v", requestUpdate) if requestUpdate { log.Printf("[DEBUG] RDS Event Subscription modification request: %#v", req) - _, err := rdsconn.ModifyEventSubscription(req) + _, err := conn.ModifyEventSubscription(req) if err != nil { return fmt.Errorf("Modifying RDS Event Subscription %s failed: %s", d.Id(), err) } @@ -248,8 +260,8 @@ func resourceAwsDbEventSubscriptionUpdate(d *schema.ResourceData, meta interface stateConf := &resource.StateChangeConf{ Pending: []string{"modifying"}, Target: []string{"active"}, - Refresh: resourceAwsDbEventSubscriptionRefreshFunc(d, meta.(*AWSClient).rdsconn), - Timeout: 40 * time.Minute, + Refresh: resourceAwsDbEventSubscriptionRefreshFunc(d.Id(), conn), + Timeout: d.Timeout(schema.TimeoutUpdate), MinTimeout: 10 * time.Second, Delay: 30 * time.Second, // Wait 30 secs before starting } @@ -265,12 +277,10 @@ func resourceAwsDbEventSubscriptionUpdate(d *schema.ResourceData, meta interface d.SetPartial("source_type") } - if arn, err := buildRDSEventSubscriptionARN(d.Get("customer_aws_id").(string), d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).region); err == nil { - if err := setTagsRDS(rdsconn, d, arn); err != nil { - return err - } else { - d.SetPartial("tags") - } + if err := setTagsRDS(conn, d, d.Get("arn").(string)); err != nil { + return err + } else { + d.SetPartial("tags") } if d.HasChange("source_ids") { @@ -290,7 +300,7 @@ func resourceAwsDbEventSubscriptionUpdate(d *schema.ResourceData, meta interface if len(remove) > 0 { for _, removing := range remove { log.Printf("[INFO] Removing %s as a Source Identifier from %q", *removing, d.Id()) - _, err := rdsconn.RemoveSourceIdentifierFromSubscription(&rds.RemoveSourceIdentifierFromSubscriptionInput{ + _, err := conn.RemoveSourceIdentifierFromSubscription(&rds.RemoveSourceIdentifierFromSubscriptionInput{ SourceIdentifier: removing, SubscriptionName: aws.String(d.Id()), }) @@ -303,7 +313,7 @@ func resourceAwsDbEventSubscriptionUpdate(d *schema.ResourceData, meta interface if len(add) > 0 { for _, adding := range add { log.Printf("[INFO] Adding %s as a Source Identifier to %q", *adding, d.Id()) - _, err := rdsconn.AddSourceIdentifierToSubscription(&rds.AddSourceIdentifierToSubscriptionInput{ + _, err := conn.AddSourceIdentifierToSubscription(&rds.AddSourceIdentifierToSubscriptionInput{ SourceIdentifier: adding, SubscriptionName: aws.String(d.Id()), }) @@ -321,28 +331,23 @@ func resourceAwsDbEventSubscriptionUpdate(d *schema.ResourceData, meta interface } func resourceAwsDbEventSubscriptionDelete(d *schema.ResourceData, meta interface{}) error { - rdsconn := meta.(*AWSClient).rdsconn + conn := meta.(*AWSClient).rdsconn deleteOpts := rds.DeleteEventSubscriptionInput{ SubscriptionName: aws.String(d.Id()), } - if _, err := rdsconn.DeleteEventSubscription(&deleteOpts); err != nil { - rdserr, ok := err.(awserr.Error) - if !ok { - return fmt.Errorf("Error deleting RDS Event Subscription %s: %s", d.Id(), err) - } - - if rdserr.Code() != "DBEventSubscriptionNotFoundFault" { - log.Printf("[WARN] RDS Event Subscription %s missing during delete", d.Id()) - return fmt.Errorf("Error deleting RDS Event Subscription %s: %s", d.Id(), err) + if _, err := conn.DeleteEventSubscription(&deleteOpts); err != nil { + if isAWSErr(err, rds.ErrCodeSubscriptionNotFoundFault, "") { + return nil } + return fmt.Errorf("Error deleting RDS Event Subscription %s: %s", d.Id(), err) } stateConf := &resource.StateChangeConf{ Pending: []string{"deleting"}, Target: []string{}, - Refresh: resourceAwsDbEventSubscriptionRefreshFunc(d, meta.(*AWSClient).rdsconn), - Timeout: 40 * time.Minute, + Refresh: resourceAwsDbEventSubscriptionRefreshFunc(d.Id(), conn), + Timeout: d.Timeout(schema.TimeoutDelete), MinTimeout: 10 * time.Second, Delay: 30 * time.Second, // Wait 30 secs before starting } @@ -353,12 +358,10 @@ func resourceAwsDbEventSubscriptionDelete(d *schema.ResourceData, meta interface return err } -func resourceAwsDbEventSubscriptionRefreshFunc( - d *schema.ResourceData, - rdsconn *rds.RDS) resource.StateRefreshFunc { +func resourceAwsDbEventSubscriptionRefreshFunc(name string, conn *rds.RDS) resource.StateRefreshFunc { return func() (interface{}, string, error) { - sub, err := resourceAwsDbEventSubscriptionRetrieve(d.Get("name").(string), rdsconn) + sub, err := resourceAwsDbEventSubscriptionRetrieve(name, conn) if err != nil { log.Printf("Error on retrieving DB Event Subscription when waiting: %s", err) @@ -370,17 +373,9 @@ func resourceAwsDbEventSubscriptionRefreshFunc( } if sub.Status != nil { - log.Printf("[DEBUG] DB Event Subscription status for %s: %s", d.Id(), *sub.Status) + log.Printf("[DEBUG] DB Event Subscription status for %s: %s", name, *sub.Status) } return sub, *sub.Status, nil } } - -func buildRDSEventSubscriptionARN(customerAwsId, subscriptionId, partition, region string) (string, error) { - if partition == "" { - return "", fmt.Errorf("Unable to construct RDS ARN because of missing AWS partition") - } - arn := fmt.Sprintf("arn:%s:rds:%s:%s:es:%s", partition, region, customerAwsId, subscriptionId) - return arn, nil -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_instance.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_instance.go index b52d856a1e28..b24346593734 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_instance.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_instance.go @@ -8,6 +8,7 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/rds" @@ -777,29 +778,28 @@ func resourceAwsDbInstanceRead(d *schema.ResourceData, meta interface{}) error { // list tags for resource // set tags conn := meta.(*AWSClient).rdsconn - arn, err := buildRDSARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region) - if err != nil { - name := "" - if v.DBName != nil && *v.DBName != "" { - name = *v.DBName - } - log.Printf("[DEBUG] Error building ARN for DB Instance, not setting Tags for DB %s", name) - } else { - d.Set("arn", arn) - resp, err := conn.ListTagsForResource(&rds.ListTagsForResourceInput{ - ResourceName: aws.String(arn), - }) - if err != nil { - log.Printf("[DEBUG] Error retrieving tags for ARN: %s", arn) - } + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "rds", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("db:%s", d.Id()), + }.String() + d.Set("arn", arn) + resp, err := conn.ListTagsForResource(&rds.ListTagsForResourceInput{ + ResourceName: aws.String(arn), + }) - var dt []*rds.Tag - if len(resp.TagList) > 0 { - dt = resp.TagList - } - d.Set("tags", tagsToMapRDS(dt)) + if err != nil { + log.Printf("[DEBUG] Error retrieving tags for ARN: %s", arn) + } + + var dt []*rds.Tag + if len(resp.TagList) > 0 { + dt = resp.TagList } + d.Set("tags", tagsToMapRDS(dt)) // Create an empty schema.Set to hold all vpc security group ids ids := &schema.Set{ @@ -1073,13 +1073,19 @@ func resourceAwsDbInstanceUpdate(d *schema.ResourceData, meta interface{}) error } } - if arn, err := buildRDSARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region); err == nil { - if err := setTagsRDS(conn, d, arn); err != nil { - return err - } else { - d.SetPartial("tags") - } + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "rds", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("db:%s", d.Id()), + }.String() + if err := setTagsRDS(conn, d, arn); err != nil { + return err + } else { + d.SetPartial("tags") } + d.Partial(false) return resourceAwsDbInstanceRead(d, meta) @@ -1145,17 +1151,6 @@ func resourceAwsDbInstanceStateRefreshFunc(id string, conn *rds.RDS) resource.St } } -func buildRDSARN(identifier, partition, accountid, region string) (string, error) { - if partition == "" { - return "", fmt.Errorf("Unable to construct RDS ARN because of missing AWS partition") - } - if accountid == "" { - return "", fmt.Errorf("Unable to construct RDS ARN because of missing AWS Account ID") - } - arn := fmt.Sprintf("arn:%s:rds:%s:%s:db:%s", partition, region, accountid, identifier) - return arn, nil -} - // Database instance status: http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Overview.DBInstance.Status.html var resourceAwsDbInstanceCreatePendingStates = []string{ "backing-up", @@ -1177,9 +1172,11 @@ var resourceAwsDbInstanceDeletePendingStates = []string{ "configuring-enhanced-monitoring", "creating", "deleting", + "incompatible-parameters", "modifying", "starting", "stopping", + "storage-full", "storage-optimization", } @@ -1195,5 +1192,6 @@ var resourceAwsDbInstanceUpdatePendingStates = []string{ "resetting-master-credentials", "starting", "stopping", + "storage-full", "upgrading", } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_option_group.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_option_group.go index 258572bb2e78..f84fbd3bd3f7 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_option_group.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_option_group.go @@ -8,8 +8,10 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/rds" + "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" @@ -189,30 +191,27 @@ func resourceAwsDbOptionGroupRead(d *schema.ResourceData, meta interface{}) erro d.Set("option", flattenOptions(option.Options)) } - optionGroup := options.OptionGroupsList[0] - arn, err := buildRDSOptionGroupARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region) - if err != nil { - name := "" - if optionGroup.OptionGroupName != nil && *optionGroup.OptionGroupName != "" { - name = *optionGroup.OptionGroupName - } - log.Printf("[DEBUG] Error building ARN for DB Option Group, not setting Tags for Option Group %s", name) - } else { - d.Set("arn", arn) - resp, err := rdsconn.ListTagsForResource(&rds.ListTagsForResourceInput{ - ResourceName: aws.String(arn), - }) + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "rds", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("og:%s", d.Id()), + }.String() + d.Set("arn", arn) + resp, err := rdsconn.ListTagsForResource(&rds.ListTagsForResourceInput{ + ResourceName: aws.String(arn), + }) - if err != nil { - log.Printf("[DEBUG] Error retrieving tags for ARN: %s", arn) - } + if err != nil { + log.Printf("[DEBUG] Error retrieving tags for ARN: %s", arn) + } - var dt []*rds.Tag - if len(resp.TagList) > 0 { - dt = resp.TagList - } - d.Set("tags", tagsToMapRDS(dt)) + var dt []*rds.Tag + if len(resp.TagList) > 0 { + dt = resp.TagList } + d.Set("tags", tagsToMapRDS(dt)) return nil } @@ -284,12 +283,17 @@ func resourceAwsDbOptionGroupUpdate(d *schema.ResourceData, meta interface{}) er } - if arn, err := buildRDSOptionGroupARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region); err == nil { - if err := setTagsRDS(rdsconn, d, arn); err != nil { - return err - } else { - d.SetPartial("tags") - } + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "rds", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("og:%s", d.Id()), + }.String() + if err := setTagsRDS(rdsconn, d, arn); err != nil { + return err + } else { + d.SetPartial("tags") } return resourceAwsDbOptionGroupRead(d, meta) @@ -355,14 +359,3 @@ func resourceAwsDbOptionHash(v interface{}) int { } return hashcode.String(buf.String()) } - -func buildRDSOptionGroupARN(identifier, partition, accountid, region string) (string, error) { - if partition == "" { - return "", fmt.Errorf("Unable to construct RDS Option Group ARN because of missing AWS partition") - } - if accountid == "" { - return "", fmt.Errorf("Unable to construct RDS Option Group ARN because of missing AWS Account ID") - } - arn := fmt.Sprintf("arn:%s:rds:%s:%s:og:%s", partition, region, accountid, identifier) - return arn, nil -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_parameter_group.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_parameter_group.go index cbc00b4cfcb2..aab4fe97d6a2 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_parameter_group.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_parameter_group.go @@ -12,6 +12,7 @@ import ( "github.com/hashicorp/terraform/helper/schema" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/rds" ) @@ -226,30 +227,27 @@ func resourceAwsDbParameterGroupRead(d *schema.ResourceData, meta interface{}) e return fmt.Errorf("error setting 'parameter' in state: %#v", err) } - paramGroup := describeResp.DBParameterGroups[0] - arn, err := buildRDSPGARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region) - if err != nil { - name := "" - if paramGroup.DBParameterGroupName != nil && *paramGroup.DBParameterGroupName != "" { - name = *paramGroup.DBParameterGroupName - } - log.Printf("[DEBUG] Error building ARN for DB Parameter Group, not setting Tags for Param Group %s", name) - } else { - d.Set("arn", arn) - resp, err := rdsconn.ListTagsForResource(&rds.ListTagsForResourceInput{ - ResourceName: aws.String(arn), - }) + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "rds", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("pg:%s", d.Id()), + }.String() + d.Set("arn", arn) + resp, err := rdsconn.ListTagsForResource(&rds.ListTagsForResourceInput{ + ResourceName: aws.String(arn), + }) - if err != nil { - log.Printf("[DEBUG] Error retrieving tags for ARN: %s", arn) - } + if err != nil { + log.Printf("[DEBUG] Error retrieving tags for ARN: %s", arn) + } - var dt []*rds.Tag - if len(resp.TagList) > 0 { - dt = resp.TagList - } - d.Set("tags", tagsToMapRDS(dt)) + var dt []*rds.Tag + if len(resp.TagList) > 0 { + dt = resp.TagList } + d.Set("tags", tagsToMapRDS(dt)) return nil } @@ -303,12 +301,17 @@ func resourceAwsDbParameterGroupUpdate(d *schema.ResourceData, meta interface{}) } } - if arn, err := buildRDSPGARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region); err == nil { - if err := setTagsRDS(rdsconn, d, arn); err != nil { - return err - } else { - d.SetPartial("tags") - } + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "rds", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("pg:%s", d.Id()), + }.String() + if err := setTagsRDS(rdsconn, d, arn); err != nil { + return err + } else { + d.SetPartial("tags") } d.Partial(false) @@ -346,15 +349,3 @@ func resourceAwsDbParameterHash(v interface{}) int { return hashcode.String(buf.String()) } - -func buildRDSPGARN(identifier, partition, accountid, region string) (string, error) { - if partition == "" { - return "", fmt.Errorf("Unable to construct RDS ARN because of missing AWS partition") - } - if accountid == "" { - return "", fmt.Errorf("Unable to construct RDS ARN because of missing AWS Account ID") - } - arn := fmt.Sprintf("arn:%s:rds:%s:%s:pg:%s", partition, region, accountid, identifier) - return arn, nil - -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_security_group.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_security_group.go index b9e73f2fb407..058a11ff40c3 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_security_group.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_security_group.go @@ -7,8 +7,10 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/rds" + "github.com/hashicorp/go-multierror" "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/resource" @@ -176,29 +178,28 @@ func resourceAwsDbSecurityGroupRead(d *schema.ResourceData, meta interface{}) er d.Set("ingress", rules) conn := meta.(*AWSClient).rdsconn - arn, err := buildRDSSecurityGroupARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region) - if err != nil { - name := "" - if sg.DBSecurityGroupName != nil && *sg.DBSecurityGroupName != "" { - name = *sg.DBSecurityGroupName - } - log.Printf("[DEBUG] Error building ARN for DB Security Group, not setting Tags for DB Security Group %s", name) - } else { - d.Set("arn", arn) - resp, err := conn.ListTagsForResource(&rds.ListTagsForResourceInput{ - ResourceName: aws.String(arn), - }) - if err != nil { - log.Printf("[DEBUG] Error retrieving tags for ARN: %s", arn) - } + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "rds", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("secgrp:%s", d.Id()), + }.String() + d.Set("arn", arn) + resp, err := conn.ListTagsForResource(&rds.ListTagsForResourceInput{ + ResourceName: aws.String(arn), + }) - var dt []*rds.Tag - if len(resp.TagList) > 0 { - dt = resp.TagList - } - d.Set("tags", tagsToMapRDS(dt)) + if err != nil { + log.Printf("[DEBUG] Error retrieving tags for ARN: %s", arn) + } + + var dt []*rds.Tag + if len(resp.TagList) > 0 { + dt = resp.TagList } + d.Set("tags", tagsToMapRDS(dt)) return nil } @@ -207,12 +208,18 @@ func resourceAwsDbSecurityGroupUpdate(d *schema.ResourceData, meta interface{}) conn := meta.(*AWSClient).rdsconn d.Partial(true) - if arn, err := buildRDSSecurityGroupARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region); err == nil { - if err := setTagsRDS(conn, d, arn); err != nil { - return err - } else { - d.SetPartial("tags") - } + + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "rds", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("secgrp:%s", d.Id()), + }.String() + if err := setTagsRDS(conn, d, arn); err != nil { + return err + } else { + d.SetPartial("tags") } if d.HasChange("ingress") { @@ -420,15 +427,3 @@ func resourceAwsDbSecurityGroupStateRefreshFunc( return v, "authorized", nil } } - -func buildRDSSecurityGroupARN(identifier, partition, accountid, region string) (string, error) { - if partition == "" { - return "", fmt.Errorf("Unable to construct RDS ARN because of missing AWS partition") - } - if accountid == "" { - return "", fmt.Errorf("Unable to construct RDS ARN because of missing AWS Account ID") - } - arn := fmt.Sprintf("arn:%s:rds:%s:%s:secgrp:%s", partition, region, accountid, identifier) - return arn, nil - -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_subnet_group.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_subnet_group.go index c4e437beeb02..b46f5066e83a 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_subnet_group.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_db_subnet_group.go @@ -7,8 +7,10 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/rds" + "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" ) @@ -147,25 +149,28 @@ func resourceAwsDbSubnetGroupRead(d *schema.ResourceData, meta interface{}) erro // list tags for resource // set tags conn := meta.(*AWSClient).rdsconn - arn, err := buildRDSsubgrpARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region) - if err != nil { - log.Printf("[DEBUG] Error building ARN for DB Subnet Group, not setting Tags for group %s", *subnetGroup.DBSubnetGroupName) - } else { - d.Set("arn", arn) - resp, err := conn.ListTagsForResource(&rds.ListTagsForResourceInput{ - ResourceName: aws.String(arn), - }) - if err != nil { - log.Printf("[DEBUG] Error retreiving tags for ARN: %s", arn) - } + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "rds", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("subgrp:%s", d.Id()), + }.String() + d.Set("arn", arn) + resp, err := conn.ListTagsForResource(&rds.ListTagsForResourceInput{ + ResourceName: aws.String(arn), + }) - var dt []*rds.Tag - if len(resp.TagList) > 0 { - dt = resp.TagList - } - d.Set("tags", tagsToMapRDS(dt)) + if err != nil { + log.Printf("[DEBUG] Error retreiving tags for ARN: %s", arn) + } + + var dt []*rds.Tag + if len(resp.TagList) > 0 { + dt = resp.TagList } + d.Set("tags", tagsToMapRDS(dt)) return nil } @@ -195,12 +200,17 @@ func resourceAwsDbSubnetGroupUpdate(d *schema.ResourceData, meta interface{}) er } } - if arn, err := buildRDSsubgrpARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region); err == nil { - if err := setTagsRDS(conn, d, arn); err != nil { - return err - } else { - d.SetPartial("tags") - } + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "rds", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("subgrp:%s", d.Id()), + }.String() + if err := setTagsRDS(conn, d, arn); err != nil { + return err + } else { + d.SetPartial("tags") } return resourceAwsDbSubnetGroupRead(d, meta) @@ -243,15 +253,3 @@ func resourceAwsDbSubnetGroupDeleteRefreshFunc( return d, "destroyed", nil } } - -func buildRDSsubgrpARN(identifier, partition, accountid, region string) (string, error) { - if partition == "" { - return "", fmt.Errorf("Unable to construct RDS ARN because of missing AWS partition") - } - if accountid == "" { - return "", fmt.Errorf("Unable to construct RDS ARN because of missing AWS Account ID") - } - arn := fmt.Sprintf("arn:%s:rds:%s:%s:subgrp:%s", partition, region, accountid, identifier) - return arn, nil - -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dms_endpoint.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dms_endpoint.go index 2acaec6257e6..67f746c11aba 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dms_endpoint.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dms_endpoint.go @@ -53,8 +53,8 @@ func resourceAwsDmsEndpoint() *schema.Resource { Type: schema.TypeString, Required: true, ValidateFunc: validation.StringInSlice([]string{ - "source", - "target", + dms.ReplicationEndpointTypeValueSource, + dms.ReplicationEndpointTypeValueTarget, }, false), }, "engine_name": { @@ -67,6 +67,7 @@ func resourceAwsDmsEndpoint() *schema.Resource { "dynamodb", "mariadb", "aurora", + "aurora-postgresql", "redshift", "sybase", "sqlserver", @@ -102,10 +103,10 @@ func resourceAwsDmsEndpoint() *schema.Resource { Computed: true, Optional: true, ValidateFunc: validation.StringInSlice([]string{ - "none", - "require", - "verify-ca", - "verify-full", + dms.DmsSslModeValueNone, + dms.DmsSslModeValueRequire, + dms.DmsSslModeValueVerifyCa, + dms.DmsSslModeValueVerifyFull, }, false), }, "tags": { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dms_replication_instance.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dms_replication_instance.go index 81db6f199d2b..df12efb91d6c 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dms_replication_instance.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dms_replication_instance.go @@ -10,6 +10,7 @@ import ( dms "github.com/aws/aws-sdk-go/service/databasemigrationservice" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsDmsReplicationInstance() *schema.Resource { @@ -34,7 +35,7 @@ func resourceAwsDmsReplicationInstance() *schema.Resource { Type: schema.TypeInt, Computed: true, Optional: true, - ValidateFunc: validateIntegerInRange(5, 6144), + ValidateFunc: validation.IntBetween(5, 6144), }, "apply_immediately": { Type: schema.TypeBool, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dms_replication_subnet_group.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dms_replication_subnet_group.go index b2816530808d..a74ce44748a0 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dms_replication_subnet_group.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dms_replication_subnet_group.go @@ -5,7 +5,9 @@ import ( "log" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" dms "github.com/aws/aws-sdk-go/service/databasemigrationservice" + "github.com/hashicorp/terraform/helper/schema" ) @@ -95,8 +97,14 @@ func resourceAwsDmsReplicationSubnetGroupRead(d *schema.ResourceData, meta inter // The AWS API for DMS subnet groups does not return the ARN which is required to // retrieve tags. This ARN can be built. - d.Set("replication_subnet_group_arn", fmt.Sprintf("arn:aws:dms:%s:%s:subgrp:%s", - meta.(*AWSClient).region, meta.(*AWSClient).accountid, d.Id())) + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "dms", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("subgrp:%s", d.Id()), + }.String() + d.Set("replication_subnet_group_arn", arn) err = resourceAwsDmsReplicationSubnetGroupSetState(d, response.ReplicationSubnetGroups[0]) if err != nil { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dms_replication_task.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dms_replication_task.go index ab10eedbc537..526ce9eae66e 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dms_replication_task.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dms_replication_task.go @@ -35,9 +35,9 @@ func resourceAwsDmsReplicationTask() *schema.Resource { Type: schema.TypeString, Required: true, ValidateFunc: validation.StringInSlice([]string{ - "full-load", - "cdc", - "full-load-and-cdc", + dms.MigrationTypeValueFullLoad, + dms.MigrationTypeValueCdc, + dms.MigrationTypeValueFullLoadAndCdc, }, false), }, "replication_instance_arn": { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dx_connection.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dx_connection.go index 0dc1066256b7..5e91e919ba71 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dx_connection.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dx_connection.go @@ -36,7 +36,7 @@ func resourceAwsDxConnection() *schema.Resource { Type: schema.TypeString, Required: true, ForceNew: true, - ValidateFunc: validateDxConnectionBandWidth, + ValidateFunc: validateDxConnectionBandWidth(), }, "location": { Type: schema.TypeString, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dx_lag.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dx_lag.go index 88fcef06dc21..6c0fbb2524dc 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dx_lag.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dx_lag.go @@ -35,7 +35,7 @@ func resourceAwsDxLag() *schema.Resource { Type: schema.TypeString, Required: true, ForceNew: true, - ValidateFunc: validateDxConnectionBandWidth, + ValidateFunc: validateDxConnectionBandWidth(), }, "location": { Type: schema.TypeString, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dynamodb_table.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dynamodb_table.go index 1aa608abd6a0..25bd461e86d4 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dynamodb_table.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dynamodb_table.go @@ -9,9 +9,11 @@ import ( "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/service/dynamodb" + "github.com/hashicorp/terraform/helper/customdiff" "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsDynamoDbTable() *schema.Resource { @@ -30,9 +32,23 @@ func resourceAwsDynamoDbTable() *schema.Resource { Update: schema.DefaultTimeout(10 * time.Minute), }, - CustomizeDiff: func(diff *schema.ResourceDiff, v interface{}) error { - return validateDynamoDbStreamSpec(diff) - }, + CustomizeDiff: customdiff.Sequence( + func(diff *schema.ResourceDiff, v interface{}) error { + return validateDynamoDbStreamSpec(diff) + }, + func(diff *schema.ResourceDiff, v interface{}) error { + return validateDynamoDbTableAttributes(diff) + }, + func(diff *schema.ResourceDiff, v interface{}) error { + if diff.Id() != "" && diff.HasChange("server_side_encryption") { + o, n := diff.GetChange("server_side_encryption") + if isDynamoDbTableSSEDisabled(o) && isDynamoDbTableSSEDisabled(n) { + return diff.Clear("server_side_encryption") + } + } + return nil + }, + ), SchemaVersion: 1, MigrateState: resourceAwsDynamoDbTableMigrateState, @@ -75,9 +91,13 @@ func resourceAwsDynamoDbTable() *schema.Resource { Required: true, }, "type": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateDynamoAttributeType, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + dynamodb.ScalarAttributeTypeB, + dynamodb.ScalarAttributeTypeN, + dynamodb.ScalarAttributeTypeS, + }, false), }, }, }, @@ -186,7 +206,13 @@ func resourceAwsDynamoDbTable() *schema.Resource { value := v.(string) return strings.ToUpper(value) }, - ValidateFunc: validateStreamViewType, + ValidateFunc: validation.StringInSlice([]string{ + "", + dynamodb.StreamViewTypeNewImage, + dynamodb.StreamViewTypeOldImage, + dynamodb.StreamViewTypeNewAndOldImages, + dynamodb.StreamViewTypeKeysOnly, + }, false), }, "stream_arn": { Type: schema.TypeString, @@ -196,6 +222,21 @@ func resourceAwsDynamoDbTable() *schema.Resource { Type: schema.TypeString, Computed: true, }, + "server_side_encryption": { + Type: schema.TypeList, + Optional: true, + Computed: true, + MaxItems: 1, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "enabled": { + Type: schema.TypeBool, + Required: true, + ForceNew: true, + }, + }, + }, + }, "tags": tagsSchema(), }, } @@ -250,6 +291,16 @@ func resourceAwsDynamoDbTableCreate(d *schema.ResourceData, meta interface{}) er } } + if v, ok := d.GetOk("server_side_encryption"); ok { + options := v.([]interface{}) + if options[0] == nil { + return fmt.Errorf("At least one field is expected inside server_side_encryption") + } + + s := options[0].(map[string]interface{}) + req.SSESpecification = expandDynamoDbEncryptAtRestOptions(s) + } + var output *dynamodb.CreateTableOutput err := resource.Retry(2*time.Minute, func() *resource.RetryError { var err error @@ -326,11 +377,10 @@ func resourceAwsDynamoDbTableUpdate(d *schema.ResourceData, meta interface{}) er } } - if d.HasChange("global_secondary_index") && !d.IsNewResource() { - var attributes []*dynamodb.AttributeDefinition - if v, ok := d.GetOk("attribute"); ok { - attributes = expandDynamoDbAttributes(v.(*schema.Set).List()) - } + // Indexes and attributes are tightly coupled (DynamoDB requires attribute definitions + // for all indexed attributes) so it's necessary to update these together. + if (d.HasChange("global_secondary_index") || d.HasChange("attribute")) && !d.IsNewResource() { + attributes := d.Get("attribute").(*schema.Set).List() o, n := d.GetChange("global_secondary_index") ops, err := diffDynamoDbGSI(o.(*schema.Set).List(), n.(*schema.Set).List()) @@ -341,12 +391,13 @@ func resourceAwsDynamoDbTableUpdate(d *schema.ResourceData, meta interface{}) er input := &dynamodb.UpdateTableInput{ TableName: aws.String(d.Id()), - AttributeDefinitions: attributes, + AttributeDefinitions: expandDynamoDbAttributes(attributes), } // Only 1 online index can be created or deleted simultaneously per table for _, op := range ops { input.GlobalSecondaryIndexUpdates = []*dynamodb.GlobalSecondaryIndexUpdate{op} + log.Printf("[DEBUG] Updating DynamoDB Table: %s", input) _, err := conn.UpdateTable(input) if err != nil { return err @@ -371,6 +422,14 @@ func resourceAwsDynamoDbTableUpdate(d *schema.ResourceData, meta interface{}) er } } + // We may only be changing the attribute type + if len(ops) == 0 { + _, err := conn.UpdateTable(input) + if err != nil { + return err + } + } + if err := waitForDynamoDbTableToBeActive(d.Id(), d.Timeout(schema.TimeoutUpdate), conn); err != nil { return fmt.Errorf("Error waiting for DynamoDB Table op: %s", err) } @@ -697,3 +756,12 @@ func waitForDynamoDbTtlUpdateToBeCompleted(tableName string, toEnable bool, conn _, err := stateConf.WaitForState() return err } + +func isDynamoDbTableSSEDisabled(v interface{}) bool { + options := v.([]interface{}) + if len(options) == 0 { + return true + } + e := options[0].(map[string]interface{})["enabled"] + return !e.(bool) +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dynamodb_table_item.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dynamodb_table_item.go index 764bf8b12d90..8d7588c40141 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dynamodb_table_item.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_dynamodb_table_item.go @@ -105,9 +105,9 @@ func resourceAwsDynamoDbTableItemUpdate(d *schema.ResourceData, meta interface{} updates := map[string]*dynamodb.AttributeValueUpdate{} for key, value := range attributes { - // Hash keys are not updatable, so we'll basically create + // Hash keys and range keys are not updatable, so we'll basically create // a new record and delete the old one below - if key == hashKey { + if key == hashKey || key == rangeKey { continue } updates[key] = &dynamodb.AttributeValueUpdate{ diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ebs_snapshot.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ebs_snapshot.go index 8ca7ef717f88..8e6eaba7fcde 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ebs_snapshot.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ebs_snapshot.go @@ -99,8 +99,16 @@ func resourceAwsEbsSnapshotRead(d *schema.ResourceData, meta interface{}) error SnapshotIds: []*string{aws.String(d.Id())}, } res, err := conn.DescribeSnapshots(req) - if ec2err, ok := err.(awserr.Error); ok && ec2err.Code() == "InvalidSnapshotID.NotFound" { - log.Printf("Snapshot %q Not found - removing from state", d.Id()) + if err != nil { + if isAWSErr(err, "InvalidSnapshot.NotFound", "") { + log.Printf("[WARN] Snapshot %q Not found - removing from state", d.Id()) + d.SetId("") + return nil + } + return err + } + + if len(res.Snapshots) == 0 { d.SetId("") return nil } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ecs_service.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ecs_service.go index fa72419e4a50..dd270ed05f52 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ecs_service.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ecs_service.go @@ -9,6 +9,7 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/service/ecs" "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/resource" @@ -217,13 +218,13 @@ func resourceAwsEcsServiceImport(d *schema.ResourceData, meta interface{}) ([]*s log.Printf("[DEBUG] Importing ECS service %s from cluster %s", name, cluster) d.SetId(name) - clusterArn := arnString( - meta.(*AWSClient).partition, - meta.(*AWSClient).region, - "ecs", - meta.(*AWSClient).accountid, - fmt.Sprintf("cluster/%s", cluster), - ) + clusterArn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Region: meta.(*AWSClient).region, + Service: "ecs", + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("cluster/%s", cluster), + }.String() d.Set("cluster", clusterArn) return []*schema.ResourceData{d}, nil } @@ -357,8 +358,11 @@ func resourceAwsEcsServiceRead(d *schema.ResourceData, meta interface{}) error { return resource.NonRetryableError(err) } - if d.IsNewResource() && len(out.Services) < 1 { - return resource.RetryableError(fmt.Errorf("No ECS service found: %q", d.Id())) + if len(out.Services) < 1 { + if d.IsNewResource() { + return resource.RetryableError(fmt.Errorf("ECS service not created yet: %q", d.Id())) + } + return resource.NonRetryableError(fmt.Errorf("No ECS service found: %q", d.Id())) } service := out.Services[0] diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ecs_task_definition.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ecs_task_definition.go index c03695fa0527..697c623de7b0 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ecs_task_definition.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ecs_task_definition.go @@ -277,7 +277,11 @@ func resourceAwsEcsTaskDefinitionRead(d *schema.ResourceData, meta interface{}) d.Set("cpu", taskDefinition.Cpu) d.Set("memory", taskDefinition.Memory) d.Set("network_mode", taskDefinition.NetworkMode) - d.Set("volumes", flattenEcsVolumes(taskDefinition.Volumes)) + + if err := d.Set("volume", flattenEcsVolumes(taskDefinition.Volumes)); err != nil { + return fmt.Errorf("error setting volume: %s", err) + } + if err := d.Set("placement_constraints", flattenPlacementConstraints(taskDefinition.PlacementConstraints)); err != nil { log.Printf("[ERR] Error setting placement_constraints for (%s): %s", d.Id(), err) } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_efs_file_system.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_efs_file_system.go index 9edb3c1540c5..b842e506c979 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_efs_file_system.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_efs_file_system.go @@ -11,6 +11,7 @@ import ( "github.com/aws/aws-sdk-go/service/efs" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsEfsFileSystem() *schema.Resource { @@ -42,11 +43,14 @@ func resourceAwsEfsFileSystem() *schema.Resource { }, "performance_mode": { - Type: schema.TypeString, - Optional: true, - Computed: true, - ForceNew: true, - ValidateFunc: validatePerformanceModeType, + Type: schema.TypeString, + Optional: true, + Computed: true, + ForceNew: true, + ValidateFunc: validation.StringInSlice([]string{ + efs.PerformanceModeGeneralPurpose, + efs.PerformanceModeMaxIo, + }, false), }, "encrypted": { @@ -300,16 +304,6 @@ func validateReferenceName(v interface{}, k string) (ws []string, errors []error return } -func validatePerformanceModeType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != efs.PerformanceModeGeneralPurpose && value != efs.PerformanceModeMaxIo { - errors = append(errors, fmt.Errorf( - "%q contains an invalid Performance Mode %q. Valid modes are either %q or %q.", - k, value, efs.PerformanceModeGeneralPurpose, efs.PerformanceModeMaxIo)) - } - return -} - func hasEmptyFileSystems(fs *efs.DescribeFileSystemsOutput) bool { if fs != nil && len(fs.FileSystems) > 0 { return false diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_eip.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_eip.go index 9ce357352fed..94a951fb1965 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_eip.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_eip.go @@ -24,6 +24,12 @@ func resourceAwsEip() *schema.Resource { State: schema.ImportStatePassthrough, }, + Timeouts: &schema.ResourceTimeout{ + Read: schema.DefaultTimeout(15 * time.Minute), + Update: schema.DefaultTimeout(5 * time.Minute), + Delete: schema.DefaultTimeout(3 * time.Minute), + }, + Schema: map[string]*schema.Schema{ "vpc": &schema.Schema{ Type: schema.TypeBool, @@ -145,7 +151,7 @@ func resourceAwsEipRead(d *schema.ResourceData, meta interface{}) error { var describeAddresses *ec2.DescribeAddressesOutput if d.IsNewResource() { - err := resource.Retry(15*time.Minute, func() *resource.RetryError { + err := resource.Retry(d.Timeout(schema.TimeoutRead), func() *resource.RetryError { describeAddresses, err = ec2conn.DescribeAddresses(req) if err != nil { awsErr, ok := err.(awserr.Error) @@ -276,7 +282,7 @@ func resourceAwsEipUpdate(d *schema.ResourceData, meta interface{}) error { log.Printf("[DEBUG] EIP associate configuration: %s (domain: %s)", assocOpts, domain) - err := resource.Retry(5*time.Minute, func() *resource.RetryError { + err := resource.Retry(d.Timeout(schema.TimeoutUpdate), func() *resource.RetryError { _, err := ec2conn.AssociateAddress(assocOpts) if err != nil { if isAWSErr(err, "InvalidAllocationID.NotFound", "") { @@ -323,7 +329,7 @@ func resourceAwsEipDelete(d *schema.ResourceData, meta interface{}) error { } domain := resourceAwsEipDomain(d) - return resource.Retry(3*time.Minute, func() *resource.RetryError { + return resource.Retry(d.Timeout(schema.TimeoutDelete), func() *resource.RetryError { var err error switch domain { case "vpc": diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_eip_association.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_eip_association.go index 5d99f5fd016b..e5a051631b09 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_eip_association.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_eip_association.go @@ -172,6 +172,9 @@ func resourceAwsEipAssociationDelete(d *schema.ResourceData, meta interface{}) e _, err := conn.DisassociateAddress(opts) if err != nil { + if isAWSErr(err, "InvalidAssociationID.NotFound", "") { + return nil + } return fmt.Errorf("Error deleting Elastic IP association: %s", err) } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elastic_beanstalk_environment.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elastic_beanstalk_environment.go index 156b1809fa4b..48f20587c786 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elastic_beanstalk_environment.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elastic_beanstalk_environment.go @@ -56,6 +56,10 @@ func resourceAwsElasticBeanstalkEnvironment() *schema.Resource { MigrateState: resourceAwsElasticBeanstalkEnvironmentMigrateState, Schema: map[string]*schema.Schema{ + "arn": { + Type: schema.TypeString, + Computed: true, + }, "name": { Type: schema.TypeString, Required: true, @@ -452,6 +456,63 @@ func resourceAwsElasticBeanstalkEnvironmentUpdate(d *schema.ResourceData, meta i } } + if d.HasChange("tags") { + o, n := d.GetChange("tags") + oldTags := tagsFromMapBeanstalk(o.(map[string]interface{})) + newTags := tagsFromMapBeanstalk(n.(map[string]interface{})) + + tagsToAdd, tagNamesToRemove := diffTagsBeanstalk(oldTags, newTags) + + updateTags := elasticbeanstalk.UpdateTagsForResourceInput{ + ResourceArn: aws.String(d.Get("arn").(string)), + TagsToAdd: tagsToAdd, + TagsToRemove: tagNamesToRemove, + } + + // Get the current time to filter getBeanstalkEnvironmentErrors messages + t := time.Now() + log.Printf("[DEBUG] Elastic Beanstalk Environment update tags: %s", updateTags) + _, err := conn.UpdateTagsForResource(&updateTags) + if err != nil { + return err + } + + waitForReadyTimeOut, err := time.ParseDuration(d.Get("wait_for_ready_timeout").(string)) + if err != nil { + return err + } + pollInterval, err := time.ParseDuration(d.Get("poll_interval").(string)) + if err != nil { + pollInterval = 0 + log.Printf("[WARN] Error parsing poll_interval, using default backoff") + } + + stateConf := &resource.StateChangeConf{ + Pending: []string{"Launching", "Updating"}, + Target: []string{"Ready"}, + Refresh: environmentStateRefreshFunc(conn, d.Id(), t), + Timeout: waitForReadyTimeOut, + Delay: 10 * time.Second, + PollInterval: pollInterval, + MinTimeout: 3 * time.Second, + } + + _, err = stateConf.WaitForState() + if err != nil { + return fmt.Errorf( + "Error waiting for Elastic Beanstalk Environment (%s) to become ready: %s", + d.Id(), err) + } + + envErrors, err := getBeanstalkEnvironmentErrors(conn, d.Id(), t) + if err != nil { + return err + } + if envErrors != nil { + return envErrors + } + } + return resourceAwsElasticBeanstalkEnvironmentRead(d, meta) } @@ -496,6 +557,8 @@ func resourceAwsElasticBeanstalkEnvironmentRead(d *schema.ResourceData, meta int return err } + d.Set("arn", env.EnvironmentArn) + if err := d.Set("name", env.EnvironmentName); err != nil { return err } @@ -564,6 +627,18 @@ func resourceAwsElasticBeanstalkEnvironmentRead(d *schema.ResourceData, meta int return err } + tags, err := conn.ListTagsForResource(&elasticbeanstalk.ListTagsForResourceInput{ + ResourceArn: aws.String(d.Get("arn").(string)), + }) + + if err != nil { + return err + } + + if err := d.Set("tags", tagsToMapBeanstalk(tags.ResourceTags)); err != nil { + return err + } + return resourceAwsElasticBeanstalkEnvironmentSettingsRead(d, meta) } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elasticache_cluster.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elasticache_cluster.go index 049a60f3ddeb..745d9040ba2a 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elasticache_cluster.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elasticache_cluster.go @@ -1,6 +1,7 @@ package aws import ( + "errors" "fmt" "log" "sort" @@ -8,10 +9,13 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/awserr" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/service/elasticache" + gversion "github.com/hashicorp/go-version" + "github.com/hashicorp/terraform/helper/customdiff" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsElastiCacheCommonSchema() map[string]*schema.Schema { @@ -26,11 +30,14 @@ func resourceAwsElastiCacheCommonSchema() map[string]*schema.Schema { }, "node_type": { Type: schema.TypeString, - Required: true, + Optional: true, + Computed: true, }, "engine": { Type: schema.TypeString, - Required: true, + Optional: true, + //Computed: true, Set in resourceAwsElasticacheCluster because this Schema is used in resource_aws_elasticache_replication_group with a default value. + ForceNew: true, }, "engine_version": { Type: schema.TypeString, @@ -101,8 +108,15 @@ func resourceAwsElastiCacheCommonSchema() map[string]*schema.Schema { }, "port": { Type: schema.TypeInt, - Required: true, + Optional: true, ForceNew: true, + DiffSuppressFunc: func(k, old, new string, d *schema.ResourceData) bool { + // Supress default memcached/redis ports when not defined + if !d.IsNewResource() && new == "0" && (old == "6379" || old == "11211") { + return true + } + return false + }, }, "notification_topic_arn": { Type: schema.TypeString, @@ -110,16 +124,9 @@ func resourceAwsElastiCacheCommonSchema() map[string]*schema.Schema { }, "snapshot_retention_limit": { - Type: schema.TypeInt, - Optional: true, - ValidateFunc: func(v interface{}, k string) (ws []string, es []error) { - value := v.(int) - if value > 35 { - es = append(es, fmt.Errorf( - "snapshot retention limit cannot be more than 35 days")) - } - return - }, + Type: schema.TypeInt, + Optional: true, + ValidateFunc: validation.IntAtMost(35), }, "apply_immediately": { @@ -135,6 +142,8 @@ func resourceAwsElastiCacheCommonSchema() map[string]*schema.Schema { func resourceAwsElasticacheCluster() *schema.Resource { resourceSchema := resourceAwsElastiCacheCommonSchema() + resourceSchema["engine"].Computed = true + resourceSchema["cluster_id"] = &schema.Schema{ Type: schema.TypeString, Required: true, @@ -150,13 +159,18 @@ func resourceAwsElasticacheCluster() *schema.Resource { resourceSchema["num_cache_nodes"] = &schema.Schema{ Type: schema.TypeInt, - Required: true, + Optional: true, + Computed: true, } resourceSchema["az_mode"] = &schema.Schema{ Type: schema.TypeString, Optional: true, Computed: true, + ValidateFunc: validation.StringInSlice([]string{ + elasticache.AZModeCrossAz, + elasticache.AZModeSingleAz, + }, false), } resourceSchema["availability_zone"] = &schema.Schema{ @@ -176,11 +190,6 @@ func resourceAwsElasticacheCluster() *schema.Resource { Computed: true, } - resourceSchema["replication_group_id"] = &schema.Schema{ - Type: schema.TypeString, - Computed: true, - } - resourceSchema["cache_nodes"] = &schema.Schema{ Type: schema.TypeList, Computed: true, @@ -206,6 +215,33 @@ func resourceAwsElasticacheCluster() *schema.Resource { }, } + resourceSchema["replication_group_id"] = &schema.Schema{ + Type: schema.TypeString, + Optional: true, + ForceNew: true, + ConflictsWith: []string{ + "availability_zone", + "availability_zones", + "az_mode", + "engine_version", + "engine", + "maintenance_window", + "node_type", + "notification_topic_arn", + "num_cache_nodes", + "parameter_group_name", + "port", + "security_group_ids", + "security_group_names", + "snapshot_arns", + "snapshot_name", + "snapshot_retention_limit", + "snapshot_window", + "subnet_group_name", + }, + Computed: true, + } + return &schema.Resource{ Create: resourceAwsElasticacheClusterCreate, Read: resourceAwsElasticacheClusterRead, @@ -216,37 +252,133 @@ func resourceAwsElasticacheCluster() *schema.Resource { }, Schema: resourceSchema, + + CustomizeDiff: customdiff.Sequence( + func(diff *schema.ResourceDiff, v interface{}) error { + // Plan time validation for az_mode + // InvalidParameterCombination: Must specify at least two cache nodes in order to specify AZ Mode of 'cross-az'. + if v, ok := diff.GetOk("az_mode"); !ok || v.(string) != elasticache.AZModeCrossAz { + return nil + } + if v, ok := diff.GetOk("num_cache_nodes"); !ok || v.(int) != 1 { + return nil + } + return errors.New(`az_mode "cross-az" is not supported with num_cache_nodes = 1`) + }, + func(diff *schema.ResourceDiff, v interface{}) error { + // Plan time validation for engine_version + // InvalidParameterCombination: Cannot modify memcached from 1.4.33 to 1.4.24 + // InvalidParameterCombination: Cannot modify redis from 3.2.6 to 3.2.4 + if diff.Id() == "" || !diff.HasChange("engine_version") { + return nil + } + o, n := diff.GetChange("engine_version") + oVersion, err := gversion.NewVersion(o.(string)) + if err != nil { + return err + } + nVersion, err := gversion.NewVersion(n.(string)) + if err != nil { + return err + } + if nVersion.GreaterThan(oVersion) { + return nil + } + return diff.ForceNew("engine_version") + }, + func(diff *schema.ResourceDiff, v interface{}) error { + // Plan time validation for node_type + // InvalidParameterCombination: Instance type cache.t2.micro can only be created in a VPC. + nodeType, nodeTypeOk := diff.GetOk("node_type") + if !nodeTypeOk { + return nil + } + vpcOnlyNodeTypes := []string{ + "cache.t2.micro", + "cache.t2.small", + "cache.t2.medium", + } + if _, ok := diff.GetOk("subnet_group_name"); !ok { + for _, vpcOnlyNodeType := range vpcOnlyNodeTypes { + if nodeType == vpcOnlyNodeType { + return fmt.Errorf("node_type %q can only be created in a VPC", nodeType) + } + } + } + return nil + }, + func(diff *schema.ResourceDiff, v interface{}) error { + // Plan time validation for num_cache_nodes + // InvalidParameterValue: Cannot create a Redis cluster with a NumCacheNodes parameter greater than 1. + if v, ok := diff.GetOk("engine"); !ok || v.(string) == "memcached" { + return nil + } + if v, ok := diff.GetOk("num_cache_nodes"); !ok || v.(int) == 1 { + return nil + } + return errors.New(`engine "redis" does not support num_cache_nodes > 1`) + }, + func(diff *schema.ResourceDiff, v interface{}) error { + // Engine memcached does not currently support vertical scaling + // InvalidParameterCombination: Scaling is not supported for engine memcached + // https://docs.aws.amazon.com/AmazonElastiCache/latest/UserGuide/Scaling.Memcached.html#Scaling.Memcached.Vertically + if diff.Id() == "" || !diff.HasChange("node_type") { + return nil + } + if v, ok := diff.GetOk("engine"); !ok || v.(string) == "redis" { + return nil + } + return diff.ForceNew("node_type") + }, + ), } } func resourceAwsElasticacheClusterCreate(d *schema.ResourceData, meta interface{}) error { conn := meta.(*AWSClient).elasticacheconn - clusterId := d.Get("cluster_id").(string) - nodeType := d.Get("node_type").(string) // e.g) cache.m1.small - numNodes := int64(d.Get("num_cache_nodes").(int)) // 2 - engine := d.Get("engine").(string) // memcached - engineVersion := d.Get("engine_version").(string) // 1.4.14 - port := int64(d.Get("port").(int)) // e.g) 11211 - subnetGroupName := d.Get("subnet_group_name").(string) - securityNameSet := d.Get("security_group_names").(*schema.Set) - securityIdSet := d.Get("security_group_ids").(*schema.Set) - - securityNames := expandStringList(securityNameSet.List()) - securityIds := expandStringList(securityIdSet.List()) - tags := tagsFromMapEC(d.Get("tags").(map[string]interface{})) - - req := &elasticache.CreateCacheClusterInput{ - CacheClusterId: aws.String(clusterId), - CacheNodeType: aws.String(nodeType), - NumCacheNodes: aws.Int64(numNodes), - Engine: aws.String(engine), - EngineVersion: aws.String(engineVersion), - Port: aws.Int64(port), - CacheSubnetGroupName: aws.String(subnetGroupName), - CacheSecurityGroupNames: securityNames, - SecurityGroupIds: securityIds, - Tags: tags, + req := &elasticache.CreateCacheClusterInput{} + + if v, ok := d.GetOk("replication_group_id"); ok { + req.ReplicationGroupId = aws.String(v.(string)) + } else { + securityNameSet := d.Get("security_group_names").(*schema.Set) + securityIdSet := d.Get("security_group_ids").(*schema.Set) + securityNames := expandStringList(securityNameSet.List()) + securityIds := expandStringList(securityIdSet.List()) + tags := tagsFromMapEC(d.Get("tags").(map[string]interface{})) + + req.CacheSecurityGroupNames = securityNames + req.SecurityGroupIds = securityIds + req.Tags = tags + } + + if v, ok := d.GetOk("cluster_id"); ok { + req.CacheClusterId = aws.String(v.(string)) + } + + if v, ok := d.GetOk("node_type"); ok { + req.CacheNodeType = aws.String(v.(string)) + } + + if v, ok := d.GetOk("num_cache_nodes"); ok { + req.NumCacheNodes = aws.Int64(int64(v.(int))) + } + + if v, ok := d.GetOk("engine"); ok { + req.Engine = aws.String(v.(string)) + } + + if v, ok := d.GetOk("engine_version"); ok { + req.EngineVersion = aws.String(v.(string)) + } + + if v, ok := d.GetOk("port"); ok { + req.Port = aws.Int64(int64(v.(int))) + } + + if v, ok := d.GetOk("subnet_group_name"); ok { + req.CacheSubnetGroupName = aws.String(v.(string)) } // parameter groups are optional and can be defaulted by AWS @@ -295,10 +427,6 @@ func resourceAwsElasticacheClusterCreate(d *schema.ResourceData, meta interface{ req.PreferredAvailabilityZones = azs } - if v, ok := d.GetOk("replication_group_id"); ok { - req.ReplicationGroupId = aws.String(v.(string)) - } - resp, err := conn.CreateCacheCluster(req) if err != nil { return fmt.Errorf("Error creating Elasticache: %s", err) @@ -338,7 +466,7 @@ func resourceAwsElasticacheClusterRead(d *schema.ResourceData, meta interface{}) res, err := conn.DescribeCacheClusters(req) if err != nil { - if eccErr, ok := err.(awserr.Error); ok && eccErr.Code() == "CacheClusterNotFound" { + if isAWSErr(err, elasticache.ErrCodeCacheClusterNotFoundFault, "") { log.Printf("[WARN] ElastiCache Cluster (%s) not found", d.Id()) d.SetId("") return nil @@ -358,6 +486,8 @@ func resourceAwsElasticacheClusterRead(d *schema.ResourceData, meta interface{}) d.Set("port", c.ConfigurationEndpoint.Port) d.Set("configuration_endpoint", aws.String(fmt.Sprintf("%s:%d", *c.ConfigurationEndpoint.Address, *c.ConfigurationEndpoint.Port))) d.Set("cluster_address", aws.String(fmt.Sprintf("%s", *c.ConfigurationEndpoint.Address))) + } else if len(c.CacheNodes) > 0 { + d.Set("port", int(aws.Int64Value(c.CacheNodes[0].Endpoint.Port))) } if c.ReplicationGroupId != nil { @@ -390,24 +520,26 @@ func resourceAwsElasticacheClusterRead(d *schema.ResourceData, meta interface{}) } // list tags for resource // set tags - arn, err := buildECARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region) - if err != nil { - log.Printf("[DEBUG] Error building ARN for ElastiCache Cluster, not setting Tags for cluster %s", *c.CacheClusterId) - } else { - resp, err := conn.ListTagsForResource(&elasticache.ListTagsForResourceInput{ - ResourceName: aws.String(arn), - }) + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "elasticache", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("cluster:%s", d.Id()), + }.String() + resp, err := conn.ListTagsForResource(&elasticache.ListTagsForResourceInput{ + ResourceName: aws.String(arn), + }) - if err != nil { - log.Printf("[DEBUG] Error retrieving tags for ARN: %s", arn) - } + if err != nil { + log.Printf("[DEBUG] Error retrieving tags for ARN: %s", arn) + } - var et []*elasticache.Tag - if len(resp.TagList) > 0 { - et = resp.TagList - } - d.Set("tags", tagsToMapEC(et)) + var et []*elasticache.Tag + if len(resp.TagList) > 0 { + et = resp.TagList } + d.Set("tags", tagsToMapEC(et)) } return nil @@ -415,13 +547,16 @@ func resourceAwsElasticacheClusterRead(d *schema.ResourceData, meta interface{}) func resourceAwsElasticacheClusterUpdate(d *schema.ResourceData, meta interface{}) error { conn := meta.(*AWSClient).elasticacheconn - arn, err := buildECARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region) - if err != nil { - log.Printf("[DEBUG] Error building ARN for ElastiCache Cluster, not updating Tags for cluster %s", d.Id()) - } else { - if err := setTagsEC(conn, d, arn); err != nil { - return err - } + + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "elasticache", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("cluster:%s", d.Id()), + }.String() + if err := setTagsEC(conn, d, arn); err != nil { + return err } req := &elasticache.ModifyCacheClusterInput{ @@ -486,9 +621,6 @@ func resourceAwsElasticacheClusterUpdate(d *schema.ResourceData, meta interface{ oraw, nraw := d.GetChange("num_cache_nodes") o := oraw.(int) n := nraw.(int) - if v, ok := d.GetOk("az_mode"); ok && v.(string) == "cross-az" && n == 1 { - return fmt.Errorf("[WARN] Error updateing Elasticache cluster (%s), error: Cross-AZ mode is not supported in a single cache node.", d.Id()) - } if n < o { log.Printf("[INFO] Cluster %s is marked for Decreasing cache nodes from %d to %d", d.Id(), o, n) nodesToRemove := getCacheNodesToRemove(d, o, o-n) @@ -571,42 +703,11 @@ func (b byCacheNodeId) Less(i, j int) bool { func resourceAwsElasticacheClusterDelete(d *schema.ResourceData, meta interface{}) error { conn := meta.(*AWSClient).elasticacheconn - req := &elasticache.DeleteCacheClusterInput{ - CacheClusterId: aws.String(d.Id()), - } - err := resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err := conn.DeleteCacheCluster(req) - if err != nil { - awsErr, ok := err.(awserr.Error) - // The cluster may be just snapshotting, so we retry until it's ready for deletion - if ok && awsErr.Code() == "InvalidCacheClusterState" { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) + err := deleteElasticacheCluster(d.Id(), 40*time.Minute, conn) if err != nil { - return err + return fmt.Errorf("error deleting Elasticache Cluster (%s): %s", d.Id(), err) } - log.Printf("[DEBUG] Waiting for deletion: %v", d.Id()) - stateConf := &resource.StateChangeConf{ - Pending: []string{"creating", "available", "deleting", "incompatible-parameters", "incompatible-network", "restore-failed", "snapshotting"}, - Target: []string{}, - Refresh: cacheClusterStateRefreshFunc(conn, d.Id(), "", []string{}), - Timeout: 40 * time.Minute, - MinTimeout: 10 * time.Second, - Delay: 30 * time.Second, - } - - _, sterr := stateConf.WaitForState() - if sterr != nil { - return fmt.Errorf("Error waiting for elasticache (%s) to delete: %s", d.Id(), sterr) - } - - d.SetId("") - return nil } @@ -617,9 +718,7 @@ func cacheClusterStateRefreshFunc(conn *elasticache.ElastiCache, clusterID, give ShowCacheNodeInfo: aws.Bool(true), }) if err != nil { - apierr := err.(awserr.Error) - log.Printf("[DEBUG] message: %v, code: %v", apierr.Message(), apierr.Code()) - if apierr.Message() == fmt.Sprintf("CacheCluster not found: %v", clusterID) { + if isAWSErr(err, elasticache.ErrCodeCacheClusterNotFoundFault, "") { log.Printf("[DEBUG] Detect deletion") return nil, "", nil } @@ -683,14 +782,35 @@ func cacheClusterStateRefreshFunc(conn *elasticache.ElastiCache, clusterID, give } } -func buildECARN(identifier, partition, accountid, region string) (string, error) { - if partition == "" { - return "", fmt.Errorf("Unable to construct ElastiCache ARN because of missing AWS partition") +func deleteElasticacheCluster(clusterID string, timeout time.Duration, conn *elasticache.ElastiCache) error { + input := &elasticache.DeleteCacheClusterInput{ + CacheClusterId: aws.String(clusterID), } - if accountid == "" { - return "", fmt.Errorf("Unable to construct ElastiCache ARN because of missing AWS Account ID") + err := resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err := conn.DeleteCacheCluster(input) + if err != nil { + // The cluster may be just snapshotting, so we retry until it's ready for deletion + if isAWSErr(err, elasticache.ErrCodeInvalidCacheClusterStateFault, "") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + if err != nil { + return err + } + + log.Printf("[DEBUG] Waiting for deletion: %v", clusterID) + stateConf := &resource.StateChangeConf{ + Pending: []string{"creating", "available", "deleting", "incompatible-parameters", "incompatible-network", "restore-failed", "snapshotting"}, + Target: []string{}, + Refresh: cacheClusterStateRefreshFunc(conn, clusterID, "", []string{}), + Timeout: timeout, + MinTimeout: 10 * time.Second, + Delay: 30 * time.Second, } - arn := fmt.Sprintf("arn:%s:elasticache:%s:%s:cluster:%s", partition, region, accountid, identifier) - return arn, nil + _, err = stateConf.WaitForState() + return err } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elasticache_replication_group.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elasticache_replication_group.go index 03d387e3c61e..57b8d70801a3 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elasticache_replication_group.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elasticache_replication_group.go @@ -8,7 +8,6 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/elasticache" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" @@ -63,8 +62,13 @@ func resourceAwsElasticacheReplicationGroup() *schema.Resource { } resourceSchema["cluster_mode"] = &schema.Schema{ - Type: schema.TypeSet, + Type: schema.TypeList, Optional: true, + // We allow Computed: true here since using number_cache_clusters + // and a cluster mode enabled parameter_group_name will create + // a single shard replication group with number_cache_clusters - 1 + // read replicas. Otherwise, the resource is marked ForceNew. + Computed: true, MaxItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ @@ -76,7 +80,6 @@ func resourceAwsElasticacheReplicationGroup() *schema.Resource { "num_node_groups": { Type: schema.TypeInt, Required: true, - ForceNew: true, }, }, }, @@ -118,7 +121,14 @@ func resourceAwsElasticacheReplicationGroup() *schema.Resource { State: schema.ImportStatePassthrough, }, - Schema: resourceSchema, + Schema: resourceSchema, + SchemaVersion: 1, + + Timeouts: &schema.ResourceTimeout{ + Create: schema.DefaultTimeout(50 * time.Minute), + Delete: schema.DefaultTimeout(40 * time.Minute), + Update: schema.DefaultTimeout(40 * time.Minute), + }, } } @@ -133,7 +143,6 @@ func resourceAwsElasticacheReplicationGroupCreate(d *schema.ResourceData, meta i AutoMinorVersionUpgrade: aws.Bool(d.Get("auto_minor_version_upgrade").(bool)), CacheNodeType: aws.String(d.Get("node_type").(string)), Engine: aws.String(d.Get("engine").(string)), - Port: aws.Int64(int64(d.Get("port").(int))), Tags: tags, } @@ -151,6 +160,10 @@ func resourceAwsElasticacheReplicationGroupCreate(d *schema.ResourceData, meta i params.CacheParameterGroupName = aws.String(v.(string)) } + if v, ok := d.GetOk("port"); ok { + params.Port = aws.Int64(int64(v.(int))) + } + if v, ok := d.GetOk("subnet_group_name"); ok { params.CacheSubnetGroupName = aws.String(v.(string)) } @@ -210,8 +223,8 @@ func resourceAwsElasticacheReplicationGroupCreate(d *schema.ResourceData, meta i } if clusterModeOk { - clusterModeAttributes := clusterMode.(*schema.Set).List() - attributes := clusterModeAttributes[0].(map[string]interface{}) + clusterModeList := clusterMode.([]interface{}) + attributes := clusterModeList[0].(map[string]interface{}) if v, ok := attributes["num_node_groups"]; ok { params.NumNodeGroups = aws.Int64(int64(v.(int))) @@ -238,7 +251,7 @@ func resourceAwsElasticacheReplicationGroupCreate(d *schema.ResourceData, meta i Pending: pending, Target: []string{"available"}, Refresh: cacheReplicationGroupStateRefreshFunc(conn, d.Id(), "available", pending), - Timeout: 50 * time.Minute, + Timeout: d.Timeout(schema.TimeoutCreate), MinTimeout: 10 * time.Second, Delay: 30 * time.Second, } @@ -260,7 +273,7 @@ func resourceAwsElasticacheReplicationGroupRead(d *schema.ResourceData, meta int res, err := conn.DescribeReplicationGroups(req) if err != nil { - if eccErr, ok := err.(awserr.Error); ok && eccErr.Code() == "ReplicationGroupNotFoundFault" { + if isAWSErr(err, elasticache.ErrCodeReplicationGroupNotFoundFault, "") { log.Printf("[WARN] Elasticache Replication Group (%s) not found", d.Id()) d.SetId("") return nil @@ -301,6 +314,9 @@ func resourceAwsElasticacheReplicationGroupRead(d *schema.ResourceData, meta int d.Set("replication_group_description", rgp.Description) d.Set("number_cache_clusters", len(rgp.MemberClusters)) + if err := d.Set("cluster_mode", flattenElasticacheNodeGroupsToClusterMode(aws.BoolValue(rgp.ClusterEnabled), rgp.NodeGroups)); err != nil { + return fmt.Errorf("error setting cluster_mode attribute: %s", err) + } d.Set("replication_group_id", rgp.ReplicationGroupId) if rgp.NodeGroups != nil { @@ -361,6 +377,51 @@ func resourceAwsElasticacheReplicationGroupRead(d *schema.ResourceData, meta int func resourceAwsElasticacheReplicationGroupUpdate(d *schema.ResourceData, meta interface{}) error { conn := meta.(*AWSClient).elasticacheconn + if d.HasChange("cluster_mode.0.num_node_groups") { + o, n := d.GetChange("cluster_mode.0.num_node_groups") + oldNumNodeGroups := o.(int) + newNumNodeGroups := n.(int) + + input := &elasticache.ModifyReplicationGroupShardConfigurationInput{ + ApplyImmediately: aws.Bool(true), + NodeGroupCount: aws.Int64(int64(newNumNodeGroups)), + ReplicationGroupId: aws.String(d.Id()), + } + + if oldNumNodeGroups > newNumNodeGroups { + // Node Group IDs are 1 indexed: 0001 through 0015 + // Loop from highest old ID until we reach highest new ID + nodeGroupsToRemove := []string{} + for i := oldNumNodeGroups; i > newNumNodeGroups; i-- { + nodeGroupID := fmt.Sprintf("%04d", i) + nodeGroupsToRemove = append(nodeGroupsToRemove, nodeGroupID) + } + input.NodeGroupsToRemove = aws.StringSlice(nodeGroupsToRemove) + } + + log.Printf("[DEBUG] Modifying Elasticache Replication Group (%s) shard configuration: %s", d.Id(), input) + _, err := conn.ModifyReplicationGroupShardConfiguration(input) + if err != nil { + return fmt.Errorf("error modifying Elasticache Replication Group shard configuration: %s", err) + } + + pending := []string{"creating", "modifying", "snapshotting"} + stateConf := &resource.StateChangeConf{ + Pending: pending, + Target: []string{"available"}, + Refresh: cacheReplicationGroupStateRefreshFunc(conn, d.Id(), "available", pending), + Timeout: d.Timeout(schema.TimeoutUpdate), + MinTimeout: 10 * time.Second, + Delay: 30 * time.Second, + } + + log.Printf("[DEBUG] Waiting for Elasticache Replication Group (%s) shard reconfiguration completion", d.Id()) + _, err = stateConf.WaitForState() + if err != nil { + return fmt.Errorf("error waiting for Elasticache Replication Group (%s) shard reconfiguration completion: %s", d.Id(), err) + } + } + requestUpdate := false params := &elasticache.ModifyReplicationGroupInput{ ApplyImmediately: aws.Bool(d.Get("apply_immediately").(bool)), @@ -448,7 +509,7 @@ func resourceAwsElasticacheReplicationGroupUpdate(d *schema.ResourceData, meta i Pending: pending, Target: []string{"available"}, Refresh: cacheReplicationGroupStateRefreshFunc(conn, d.Id(), "available", pending), - Timeout: 40 * time.Minute, + Timeout: d.Timeout(schema.TimeoutUpdate), MinTimeout: 10 * time.Second, Delay: 30 * time.Second, } @@ -465,33 +526,9 @@ func resourceAwsElasticacheReplicationGroupUpdate(d *schema.ResourceData, meta i func resourceAwsElasticacheReplicationGroupDelete(d *schema.ResourceData, meta interface{}) error { conn := meta.(*AWSClient).elasticacheconn - req := &elasticache.DeleteReplicationGroupInput{ - ReplicationGroupId: aws.String(d.Id()), - } - - _, err := conn.DeleteReplicationGroup(req) + err := deleteElasticacheReplicationGroup(d.Id(), 40*time.Minute, conn) if err != nil { - if ec2err, ok := err.(awserr.Error); ok && ec2err.Code() == "ReplicationGroupNotFoundFault" { - d.SetId("") - return nil - } - - return fmt.Errorf("Error deleting Elasticache replication group: %s", err) - } - - log.Printf("[DEBUG] Waiting for deletion: %v", d.Id()) - stateConf := &resource.StateChangeConf{ - Pending: []string{"creating", "available", "deleting"}, - Target: []string{}, - Refresh: cacheReplicationGroupStateRefreshFunc(conn, d.Id(), "", []string{}), - Timeout: 40 * time.Minute, - MinTimeout: 10 * time.Second, - Delay: 30 * time.Second, - } - - _, sterr := stateConf.WaitForState() - if sterr != nil { - return fmt.Errorf("Error waiting for replication group (%s) to delete: %s", d.Id(), sterr) + return fmt.Errorf("error deleting Elasticache Replication Group (%s): %s", d.Id(), err) } return nil @@ -503,7 +540,7 @@ func cacheReplicationGroupStateRefreshFunc(conn *elasticache.ElastiCache, replic ReplicationGroupId: aws.String(replicationGroupId), }) if err != nil { - if eccErr, ok := err.(awserr.Error); ok && eccErr.Code() == "ReplicationGroupNotFoundFault" { + if isAWSErr(err, elasticache.ErrCodeReplicationGroupNotFoundFault, "") { log.Printf("[DEBUG] Replication Group Not Found") return nil, "", nil } @@ -544,6 +581,52 @@ func cacheReplicationGroupStateRefreshFunc(conn *elasticache.ElastiCache, replic } } +func deleteElasticacheReplicationGroup(replicationGroupID string, timeout time.Duration, conn *elasticache.ElastiCache) error { + input := &elasticache.DeleteReplicationGroupInput{ + ReplicationGroupId: aws.String(replicationGroupID), + } + + _, err := conn.DeleteReplicationGroup(input) + if err != nil { + if isAWSErr(err, elasticache.ErrCodeReplicationGroupNotFoundFault, "") { + return nil + } + return err + } + + log.Printf("[DEBUG] Waiting for deletion: %s", replicationGroupID) + stateConf := &resource.StateChangeConf{ + Pending: []string{"creating", "available", "deleting"}, + Target: []string{}, + Refresh: cacheReplicationGroupStateRefreshFunc(conn, replicationGroupID, "", []string{}), + Timeout: timeout, + MinTimeout: 10 * time.Second, + Delay: 30 * time.Second, + } + + _, err = stateConf.WaitForState() + return err +} + +func flattenElasticacheNodeGroupsToClusterMode(clusterEnabled bool, nodeGroups []*elasticache.NodeGroup) []map[string]interface{} { + if !clusterEnabled { + return []map[string]interface{}{} + } + + m := map[string]interface{}{ + "num_node_groups": 0, + "replicas_per_node_group": 0, + } + + if len(nodeGroups) == 0 { + return []map[string]interface{}{m} + } + + m["num_node_groups"] = len(nodeGroups) + m["replicas_per_node_group"] = (len(nodeGroups[0].NodeGroupMembers) - 1) + return []map[string]interface{}{m} +} + func validateAwsElastiCacheReplicationGroupEngine(v interface{}, k string) (ws []string, errors []error) { if strings.ToLower(v.(string)) != "redis" { errors = append(errors, fmt.Errorf("The only acceptable Engine type when using Replication Groups is Redis")) diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elasticache_replication_group_migrate.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elasticache_replication_group_migrate.go new file mode 100644 index 000000000000..0daf561f4137 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elasticache_replication_group_migrate.go @@ -0,0 +1,59 @@ +package aws + +import ( + "fmt" + "log" + "strings" + + "github.com/hashicorp/terraform/terraform" +) + +func resourceAwsElasticacheReplicationGroupMigrateState(v int, is *terraform.InstanceState, meta interface{}) (*terraform.InstanceState, error) { + switch v { + case 0: + log.Println("[INFO] Found AWS Elasticache Replication Group State v0; migrating to v1") + return migrateAwsElasticacheReplicationGroupStateV0toV1(is) + default: + return is, fmt.Errorf("Unexpected schema version: %d", v) + } +} + +func migrateAwsElasticacheReplicationGroupStateV0toV1(is *terraform.InstanceState) (*terraform.InstanceState, error) { + if is.Empty() || is.Attributes == nil { + log.Println("[DEBUG] Empty InstanceState; nothing to migrate.") + return is, nil + } + + numCountStr, ok := is.Attributes["cluster_mode.#"] + if !ok || numCountStr == "0" { + log.Println("[DEBUG] Empty cluster_mode in InstanceState; no need to migrate.") + return is, nil + } + + for k, v := range is.Attributes { + if !strings.HasPrefix(k, "cluster_mode.") || strings.HasPrefix(k, "cluster_mode.#") { + continue + } + + // cluster_mode.HASHCODE.attr + path := strings.Split(k, ".") + if len(path) != 3 { + return is, fmt.Errorf("Found unexpected cluster_mode field: %#v", k) + } + hashcode, attr := path[1], path[2] + if hashcode == "0" { + // Skip already migrated attribute + continue + } + + if attr == "replicas_per_node_group" { + is.Attributes["cluster_mode.0.replicas_per_node_group"] = v + } + if attr == "num_node_groups" { + is.Attributes["cluster_mode.0.num_node_groups"] = v + } + delete(is.Attributes, k) + } + log.Printf("[DEBUG] Attributes after migration: %#v", is.Attributes) + return is, nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elasticsearch_domain.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elasticsearch_domain.go index 7b04cea2c096..53173acb69c3 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elasticsearch_domain.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elasticsearch_domain.go @@ -15,6 +15,7 @@ import ( "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" "github.com/hashicorp/terraform/helper/structure" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsElasticSearchDomain() *schema.Resource { @@ -205,17 +206,10 @@ func resourceAwsElasticSearchDomain() *schema.Resource { "log_type": { Type: schema.TypeString, Required: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - validLogTypes := []string{"INDEX_SLOW_LOGS", "SEARCH_SLOW_LOGS"} - for _, str := range validLogTypes { - if value == str { - return - } - } - errors = append(errors, fmt.Errorf("expected %s to be one of %v, got %s", k, validLogTypes, value)) - return - }, + ValidateFunc: validation.StringInSlice([]string{ + elasticsearch.LogTypeIndexSlowLogs, + elasticsearch.LogTypeSearchSlowLogs, + }, false), }, "cloudwatch_log_group_arn": { Type: schema.TypeString, @@ -683,44 +677,46 @@ func resourceAwsElasticSearchDomainUpdate(d *schema.ResourceData, meta interface func resourceAwsElasticSearchDomainDelete(d *schema.ResourceData, meta interface{}) error { conn := meta.(*AWSClient).esconn + domainName := d.Get("domain_name").(string) - log.Printf("[DEBUG] Deleting ElasticSearch domain: %q", d.Get("domain_name").(string)) + log.Printf("[DEBUG] Deleting ElasticSearch domain: %q", domainName) _, err := conn.DeleteElasticsearchDomain(&elasticsearch.DeleteElasticsearchDomainInput{ - DomainName: aws.String(d.Get("domain_name").(string)), + DomainName: aws.String(domainName), }) if err != nil { + if isAWSErr(err, elasticsearch.ErrCodeResourceNotFoundException, "") { + return nil + } return err } - log.Printf("[DEBUG] Waiting for ElasticSearch domain %q to be deleted", d.Get("domain_name").(string)) - err = resource.Retry(90*time.Minute, func() *resource.RetryError { - out, err := conn.DescribeElasticsearchDomain(&elasticsearch.DescribeElasticsearchDomainInput{ - DomainName: aws.String(d.Get("domain_name").(string)), - }) + log.Printf("[DEBUG] Waiting for ElasticSearch domain %q to be deleted", domainName) + err = resourceAwsElasticSearchDomainDeleteWaiter(domainName, conn) - if err != nil { - awsErr, ok := err.(awserr.Error) - if !ok { - return resource.NonRetryableError(err) - } + return err +} + +func resourceAwsElasticSearchDomainDeleteWaiter(domainName string, conn *elasticsearch.ElasticsearchService) error { + input := &elasticsearch.DescribeElasticsearchDomainInput{ + DomainName: aws.String(domainName), + } + err := resource.Retry(90*time.Minute, func() *resource.RetryError { + out, err := conn.DescribeElasticsearchDomain(input) - if awsErr.Code() == "ResourceNotFoundException" { + if err != nil { + if isAWSErr(err, elasticsearch.ErrCodeResourceNotFoundException, "") { return nil } - return resource.NonRetryableError(err) } - if !*out.DomainStatus.Processing { + if out.DomainStatus != nil && !aws.BoolValue(out.DomainStatus.Processing) { return nil } - return resource.RetryableError( - fmt.Errorf("%q: Timeout while waiting for the domain to be deleted", d.Id())) + return resource.RetryableError(fmt.Errorf("timeout while waiting for the domain %q to be deleted", domainName)) }) - d.SetId("") - return err } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elb.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elb.go index caf28742c20c..eb26f9626339 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elb.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_elb.go @@ -473,7 +473,10 @@ func resourceAwsElbUpdate(d *schema.ResourceData, meta interface{}) error { ns := n.(*schema.Set) remove, _ := expandListeners(os.Difference(ns).List()) - add, _ := expandListeners(ns.Difference(os).List()) + add, err := expandListeners(ns.Difference(os).List()) + if err != nil { + return err + } if len(remove) > 0 { ports := make([]*int64, 0, len(remove)) diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_emr_cluster.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_emr_cluster.go index f5048e71ef70..0be3f0438b24 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_emr_cluster.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_emr_cluster.go @@ -132,6 +132,44 @@ func resourceAwsEMRCluster() *schema.Resource { }, }, }, + "kerberos_attributes": { + Type: schema.TypeList, + MaxItems: 1, + Optional: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "ad_domain_join_password": { + Type: schema.TypeString, + Optional: true, + Sensitive: true, + ForceNew: true, + }, + "ad_domain_join_user": { + Type: schema.TypeString, + Optional: true, + ForceNew: true, + }, + "cross_realm_trust_principal_password": { + Type: schema.TypeString, + Optional: true, + Sensitive: true, + ForceNew: true, + }, + "kdc_admin_password": { + Type: schema.TypeString, + Required: true, + Sensitive: true, + ForceNew: true, + }, + "realm": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + }, + }, + }, "instance_group": { Type: schema.TypeSet, Optional: true, @@ -160,7 +198,7 @@ func resourceAwsEMRCluster() *schema.Resource { "type": { Type: schema.TypeString, Required: true, - ValidateFunc: validateAwsEmrEbsVolumeType, + ValidateFunc: validateAwsEmrEbsVolumeType(), }, "volumes_per_instance": { Type: schema.TypeInt, @@ -186,9 +224,13 @@ func resourceAwsEMRCluster() *schema.Resource { }, }, "instance_role": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateAwsEmrInstanceGroupRole, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + emr.InstanceFleetTypeMaster, + emr.InstanceFleetTypeCore, + emr.InstanceFleetTypeTask, + }, false), }, "instance_type": { Type: schema.TypeString, @@ -226,6 +268,63 @@ func resourceAwsEMRCluster() *schema.Resource { }, }, }, + "step": { + Type: schema.TypeList, + Optional: true, + Computed: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "action_on_failure": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validation.StringInSlice([]string{ + emr.ActionOnFailureCancelAndWait, + emr.ActionOnFailureContinue, + emr.ActionOnFailureTerminateCluster, + emr.ActionOnFailureTerminateJobFlow, + }, false), + }, + "hadoop_jar_step": { + Type: schema.TypeList, + MaxItems: 1, + Required: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "args": { + Type: schema.TypeList, + Optional: true, + ForceNew: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "jar": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "main_class": { + Type: schema.TypeString, + Optional: true, + ForceNew: true, + }, + "properties": { + Type: schema.TypeMap, + Optional: true, + ForceNew: true, + }, + }, + }, + }, + "name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + }, + }, + }, "tags": tagsSchema(), "configurations": { Type: schema.TypeString, @@ -403,6 +502,10 @@ func resourceAwsEMRClusterCreate(d *schema.ResourceData, meta interface{}) error bootstrapActions := v.(*schema.Set).List() params.BootstrapActions = expandBootstrapActions(bootstrapActions) } + if v, ok := d.GetOk("step"); ok { + steps := v.([]interface{}) + params.Steps = expandEmrStepConfigs(steps) + } if v, ok := d.GetOk("tags"); ok { tagsIn := v.(map[string]interface{}) params.Tags = expandTags(tagsIn) @@ -412,6 +515,12 @@ func resourceAwsEMRClusterCreate(d *schema.ResourceData, meta interface{}) error params.Configurations = expandConfigures(confUrl) } + if v, ok := d.GetOk("kerberos_attributes"); ok { + kerberosAttributesList := v.([]interface{}) + kerberosAttributesMap := kerberosAttributesList[0].(map[string]interface{}) + params.KerberosAttributes = expandEmrKerberosAttributes(kerberosAttributesMap) + } + log.Printf("[DEBUG] EMR Cluster create options: %s", params) var resp *emr.RunJobFlowOutput @@ -438,8 +547,14 @@ func resourceAwsEMRClusterCreate(d *schema.ResourceData, meta interface{}) error log.Println("[INFO] Waiting for EMR Cluster to be available") stateConf := &resource.StateChangeConf{ - Pending: []string{"STARTING", "BOOTSTRAPPING"}, - Target: []string{"WAITING", "RUNNING"}, + Pending: []string{ + emr.ClusterStateBootstrapping, + emr.ClusterStateStarting, + }, + Target: []string{ + emr.ClusterStateRunning, + emr.ClusterStateWaiting, + }, Refresh: resourceAwsEMRClusterStateRefreshFunc(d, meta), Timeout: 75 * time.Minute, MinTimeout: 10 * time.Second, @@ -475,19 +590,15 @@ func resourceAwsEMRClusterRead(d *schema.ResourceData, meta interface{}) error { cluster := resp.Cluster if cluster.Status != nil { - if *cluster.Status.State == "TERMINATED" { - log.Printf("[DEBUG] EMR Cluster (%s) was TERMINATED already", d.Id()) - d.SetId("") - return nil - } + state := aws.StringValue(cluster.Status.State) - if *cluster.Status.State == "TERMINATED_WITH_ERRORS" { - log.Printf("[DEBUG] EMR Cluster (%s) was TERMINATED_WITH_ERRORS already", d.Id()) + if state == emr.ClusterStateTerminated || state == emr.ClusterStateTerminatedWithErrors { + log.Printf("[WARN] EMR Cluster (%s) was %s already, removing from state", d.Id(), state) d.SetId("") return nil } - d.Set("cluster_state", cluster.Status.State) + d.Set("cluster_state", state) } instanceGroups, err := fetchAllEMRInstanceGroups(emrconn, d.Id()) @@ -532,6 +643,10 @@ func resourceAwsEMRClusterRead(d *schema.ResourceData, meta interface{}) error { log.Printf("[ERR] Error setting EMR Ec2 Attributes: %s", err) } + if err := d.Set("kerberos_attributes", flattenEmrKerberosAttributes(d, cluster.KerberosAttributes)); err != nil { + return fmt.Errorf("error setting kerberos_attributes: %s", err) + } + respBootstraps, err := emrconn.ListBootstrapActions(&emr.ListBootstrapActionsInput{ ClusterId: cluster.Id, }) @@ -543,6 +658,24 @@ func resourceAwsEMRClusterRead(d *schema.ResourceData, meta interface{}) error { log.Printf("[WARN] Error setting Bootstrap Actions: %s", err) } + var stepSummaries []*emr.StepSummary + listStepsInput := &emr.ListStepsInput{ + ClusterId: aws.String(d.Id()), + } + err = emrconn.ListStepsPages(listStepsInput, func(page *emr.ListStepsOutput, lastPage bool) bool { + // ListSteps returns steps in reverse order (newest first) + for _, step := range page.Steps { + stepSummaries = append([]*emr.StepSummary{step}, stepSummaries...) + } + return !lastPage + }) + if err != nil { + return fmt.Errorf("error listing steps: %s", err) + } + if err := d.Set("step", flattenEmrStepSummaries(stepSummaries)); err != nil { + return fmt.Errorf("error setting step: %s", err) + } + return nil } @@ -585,8 +718,14 @@ func resourceAwsEMRClusterUpdate(d *schema.ResourceData, meta interface{}) error log.Println("[INFO] Waiting for EMR Cluster to be available") stateConf := &resource.StateChangeConf{ - Pending: []string{"STARTING", "BOOTSTRAPPING"}, - Target: []string{"WAITING", "RUNNING"}, + Pending: []string{ + emr.ClusterStateBootstrapping, + emr.ClusterStateStarting, + }, + Target: []string{ + emr.ClusterStateRunning, + emr.ClusterStateWaiting, + }, Refresh: resourceAwsEMRClusterStateRefreshFunc(d, meta), Timeout: 40 * time.Minute, MinTimeout: 10 * time.Second, @@ -670,7 +809,7 @@ func resourceAwsEMRClusterDelete(d *schema.ResourceData, meta interface{}) error var terminated []string for j, i := range resp.Instances { if i.Status != nil { - if *i.Status.State == "TERMINATED" { + if aws.StringValue(i.Status.State) == emr.InstanceStateTerminated { terminated = append(terminated, *i.Ec2InstanceId) } } else { @@ -751,6 +890,83 @@ func flattenEc2Attributes(ia *emr.Ec2InstanceAttributes) []map[string]interface{ return result } +func flattenEmrKerberosAttributes(d *schema.ResourceData, kerberosAttributes *emr.KerberosAttributes) []map[string]interface{} { + l := make([]map[string]interface{}, 0) + + if kerberosAttributes == nil || kerberosAttributes.Realm == nil { + return l + } + + // Do not set from API: + // * ad_domain_join_password + // * cross_realm_trust_principal_password + // * kdc_admin_password + + m := map[string]interface{}{ + "kdc_admin_password": d.Get("kerberos_attributes.0.kdc_admin_password").(string), + "realm": *kerberosAttributes.Realm, + } + + if v, ok := d.GetOk("kerberos_attributes.0.ad_domain_join_password"); ok { + m["ad_domain_join_password"] = v.(string) + } + + if kerberosAttributes.ADDomainJoinUser != nil { + m["ad_domain_join_user"] = *kerberosAttributes.ADDomainJoinUser + } + + if v, ok := d.GetOk("kerberos_attributes.0.cross_realm_trust_principal_password"); ok { + m["cross_realm_trust_principal_password"] = v.(string) + } + + l = append(l, m) + + return l +} + +func flattenEmrHadoopStepConfig(config *emr.HadoopStepConfig) map[string]interface{} { + if config == nil { + return nil + } + + m := map[string]interface{}{ + "args": aws.StringValueSlice(config.Args), + "jar": aws.StringValue(config.Jar), + "main_class": aws.StringValue(config.MainClass), + "properties": aws.StringValueMap(config.Properties), + } + + return m +} + +func flattenEmrStepSummaries(stepSummaries []*emr.StepSummary) []map[string]interface{} { + l := make([]map[string]interface{}, 0) + + if len(stepSummaries) == 0 { + return l + } + + for _, stepSummary := range stepSummaries { + l = append(l, flattenEmrStepSummary(stepSummary)) + } + + return l +} + +func flattenEmrStepSummary(stepSummary *emr.StepSummary) map[string]interface{} { + if stepSummary == nil { + return nil + } + + m := map[string]interface{}{ + "action_on_failure": aws.StringValue(stepSummary.ActionOnFailure), + "hadoop_jar_step": []map[string]interface{}{flattenEmrHadoopStepConfig(stepSummary.Config)}, + "name": aws.StringValue(stepSummary.Name), + } + + return m +} + func flattenInstanceGroups(igs []*emr.InstanceGroup) []map[string]interface{} { result := make([]map[string]interface{}, 0) @@ -932,6 +1148,81 @@ func expandBootstrapActions(bootstrapActions []interface{}) []*emr.BootstrapActi return actionsOut } +func expandEmrHadoopJarStepConfig(m map[string]interface{}) *emr.HadoopJarStepConfig { + hadoopJarStepConfig := &emr.HadoopJarStepConfig{ + Jar: aws.String(m["jar"].(string)), + } + + if v, ok := m["args"]; ok { + hadoopJarStepConfig.Args = expandStringList(v.([]interface{})) + } + + if v, ok := m["main_class"]; ok { + hadoopJarStepConfig.MainClass = aws.String(v.(string)) + } + + if v, ok := m["properties"]; ok { + hadoopJarStepConfig.Properties = expandEmrKeyValues(v.(map[string]interface{})) + } + + return hadoopJarStepConfig +} + +func expandEmrKeyValues(m map[string]interface{}) []*emr.KeyValue { + keyValues := make([]*emr.KeyValue, 0) + + for k, v := range m { + keyValue := &emr.KeyValue{ + Key: aws.String(k), + Value: aws.String(v.(string)), + } + keyValues = append(keyValues, keyValue) + } + + return keyValues +} + +func expandEmrKerberosAttributes(m map[string]interface{}) *emr.KerberosAttributes { + kerberosAttributes := &emr.KerberosAttributes{ + KdcAdminPassword: aws.String(m["kdc_admin_password"].(string)), + Realm: aws.String(m["realm"].(string)), + } + if v, ok := m["ad_domain_join_password"]; ok && v.(string) != "" { + kerberosAttributes.ADDomainJoinPassword = aws.String(v.(string)) + } + if v, ok := m["ad_domain_join_user"]; ok && v.(string) != "" { + kerberosAttributes.ADDomainJoinUser = aws.String(v.(string)) + } + if v, ok := m["cross_realm_trust_principal_password"]; ok && v.(string) != "" { + kerberosAttributes.CrossRealmTrustPrincipalPassword = aws.String(v.(string)) + } + return kerberosAttributes +} + +func expandEmrStepConfig(m map[string]interface{}) *emr.StepConfig { + hadoopJarStepList := m["hadoop_jar_step"].([]interface{}) + hadoopJarStepMap := hadoopJarStepList[0].(map[string]interface{}) + + stepConfig := &emr.StepConfig{ + ActionOnFailure: aws.String(m["action_on_failure"].(string)), + HadoopJarStep: expandEmrHadoopJarStepConfig(hadoopJarStepMap), + Name: aws.String(m["name"].(string)), + } + + return stepConfig +} + +func expandEmrStepConfigs(l []interface{}) []*emr.StepConfig { + stepConfigs := []*emr.StepConfig{} + + for _, raw := range l { + m := raw.(map[string]interface{}) + stepConfigs = append(stepConfigs, expandEmrStepConfig(m)) + } + + return stepConfigs +} + func expandInstanceGroupConfigs(instanceGroupConfigs []interface{}) []*emr.InstanceGroupConfig { instanceGroupConfig := []*emr.InstanceGroupConfig{} @@ -1083,23 +1374,25 @@ func resourceAwsEMRClusterStateRefreshFunc(d *schema.ResourceData, meta interfac return nil, "", err } - emrc := resp.Cluster - - if emrc == nil { + if resp.Cluster == nil { return 42, "destroyed", nil } - if resp.Cluster.Status != nil { - log.Printf("[DEBUG] EMR Cluster status (%s): %s", d.Id(), *resp.Cluster.Status) + if resp.Cluster.Status == nil { + return resp.Cluster, "", fmt.Errorf("cluster status not provided") } - status := emrc.Status - if *status.State == "TERMINATING" || *status.State == "TERMINATED_WITH_ERRORS" { - reason := *status.StateChangeReason - return emrc, *status.State, fmt.Errorf("%s: %s", - *reason.Code, *reason.Message) + state := aws.StringValue(resp.Cluster.Status.State) + log.Printf("[DEBUG] EMR Cluster status (%s): %s", d.Id(), state) + + if state == emr.ClusterStateTerminating || state == emr.ClusterStateTerminatedWithErrors { + reason := resp.Cluster.Status.StateChangeReason + if reason == nil { + return resp.Cluster, state, fmt.Errorf("%s: reason code and message not provided", state) + } + return resp.Cluster, state, fmt.Errorf("%s: %s: %s", state, aws.StringValue(reason.Code), aws.StringValue(reason.Message)) } - return emrc, *status.State, nil + return resp.Cluster, state, nil } } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_emr_instance_group.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_emr_instance_group.go index 343a68b8f3a3..49a70f355fdc 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_emr_instance_group.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_emr_instance_group.go @@ -72,7 +72,7 @@ func resourceAwsEMRInstanceGroup() *schema.Resource { "type": { Type: schema.TypeString, Required: true, - ValidateFunc: validateAwsEmrEbsVolumeType, + ValidateFunc: validateAwsEmrEbsVolumeType(), }, "volumes_per_instance": { Type: schema.TypeInt, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_emr_security_configuration.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_emr_security_configuration.go index 0002d5d29442..50400c407f3b 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_emr_security_configuration.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_emr_security_configuration.go @@ -1,7 +1,6 @@ package aws import ( - "fmt" "log" "github.com/aws/aws-sdk-go/aws" @@ -20,33 +19,19 @@ func resourceAwsEMRSecurityConfiguration() *schema.Resource { }, Schema: map[string]*schema.Schema{ - "name": &schema.Schema{ + "name": { Type: schema.TypeString, Optional: true, Computed: true, ForceNew: true, ConflictsWith: []string{"name_prefix"}, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 10280 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 10280 characters", k)) - } - return - }, + ValidateFunc: validateMaxLength(10280), }, - "name_prefix": &schema.Schema{ - Type: schema.TypeString, - Optional: true, - ForceNew: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 10000 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 10000 characters, name is limited to 10280", k)) - } - return - }, + "name_prefix": { + Type: schema.TypeString, + Optional: true, + ForceNew: true, + ValidateFunc: validateMaxLength(10280 - resource.UniqueIDSuffixLength), }, "configuration": { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_gamelift_build.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_gamelift_build.go index 9a327acccc43..2c13f228ca64 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_gamelift_build.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_gamelift_build.go @@ -25,10 +25,13 @@ func resourceAwsGameliftBuild() *schema.Resource { ValidateFunc: validation.StringLenBetween(1, 1024), }, "operating_system": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - ValidateFunc: validateGameliftOperatingSystem, + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validation.StringInSlice([]string{ + gamelift.OperatingSystemAmazonLinux, + gamelift.OperatingSystemWindows2012, + }, false), }, "storage_location": { Type: schema.TypeList, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_guardduty_ipset.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_guardduty_ipset.go index cb14525f3d87..6627936b6792 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_guardduty_ipset.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_guardduty_ipset.go @@ -10,6 +10,7 @@ import ( "github.com/aws/aws-sdk-go/service/guardduty" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsGuardDutyIpset() *schema.Resource { @@ -34,10 +35,17 @@ func resourceAwsGuardDutyIpset() *schema.Resource { Required: true, }, "format": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - ValidateFunc: validateGuardDutyIpsetFormat, + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validation.StringInSlice([]string{ + guardduty.IpSetFormatTxt, + guardduty.IpSetFormatStix, + guardduty.IpSetFormatOtxCsv, + guardduty.IpSetFormatAlienVault, + guardduty.IpSetFormatProofPoint, + guardduty.IpSetFormatFireEye, + }, false), }, "location": { Type: schema.TypeString, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_guardduty_threatintelset.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_guardduty_threatintelset.go index e559898068c5..16351a51ee19 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_guardduty_threatintelset.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_guardduty_threatintelset.go @@ -10,6 +10,7 @@ import ( "github.com/aws/aws-sdk-go/service/guardduty" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsGuardDutyThreatintelset() *schema.Resource { @@ -34,10 +35,17 @@ func resourceAwsGuardDutyThreatintelset() *schema.Resource { Required: true, }, "format": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - ValidateFunc: validateGuardDutyThreatIntelSetFormat, + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validation.StringInSlice([]string{ + guardduty.ThreatIntelSetFormatTxt, + guardduty.ThreatIntelSetFormatStix, + guardduty.ThreatIntelSetFormatOtxCsv, + guardduty.ThreatIntelSetFormatAlienVault, + guardduty.ThreatIntelSetFormatProofPoint, + guardduty.ThreatIntelSetFormatFireEye, + }, false), }, "location": { Type: schema.TypeString, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_account_alias.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_account_alias.go index 3b1b86f1efb8..3307ae1c29be 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_account_alias.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_account_alias.go @@ -41,7 +41,7 @@ func resourceAwsIamAccountAliasCreate(d *schema.ResourceData, meta interface{}) _, err := conn.CreateAccountAlias(params) if err != nil { - return fmt.Errorf("Error creating account alias with name %s", account_alias) + return fmt.Errorf("Error creating account alias with name '%s': %s", account_alias, err) } d.SetId(account_alias) @@ -57,7 +57,7 @@ func resourceAwsIamAccountAliasRead(d *schema.ResourceData, meta interface{}) er resp, err := conn.ListAccountAliases(params) if err != nil { - return err + return fmt.Errorf("Error listing account aliases: %s", err) } if resp == nil || len(resp.AccountAliases) == 0 { @@ -85,7 +85,7 @@ func resourceAwsIamAccountAliasDelete(d *schema.ResourceData, meta interface{}) _, err := conn.DeleteAccountAlias(params) if err != nil { - return fmt.Errorf("Error deleting account alias with name %s", account_alias) + return fmt.Errorf("Error deleting account alias with name '%s': %s", account_alias, err) } d.SetId("") diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_policy_attachment.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_policy_attachment.go index adbd81b20c6e..a973460286c3 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_policy_attachment.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_policy_attachment.go @@ -11,6 +11,7 @@ import ( "github.com/aws/aws-sdk-go/service/iam" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsIamPolicyAttachment() *schema.Resource { @@ -22,16 +23,10 @@ func resourceAwsIamPolicyAttachment() *schema.Resource { Schema: map[string]*schema.Schema{ "name": &schema.Schema{ - Type: schema.TypeString, - Required: true, - ForceNew: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - if v.(string) == "" { - errors = append(errors, fmt.Errorf( - "%q cannot be an empty string", k)) - } - return - }, + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validation.NoZeroValues, }, "users": &schema.Schema{ Type: schema.TypeSet, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_role.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_role.go index 43526174c0f7..31c0455d1cec 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_role.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_role.go @@ -12,6 +12,7 @@ import ( "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsIamRole() *schema.Resource { @@ -105,6 +106,13 @@ func resourceAwsIamRole() *schema.Resource { Type: schema.TypeString, Computed: true, }, + + "max_session_duration": { + Type: schema.TypeInt, + Optional: true, + Default: 3600, + ValidateFunc: validation.IntBetween(3600, 43200), + }, }, } } @@ -137,6 +145,10 @@ func resourceAwsIamRoleCreate(d *schema.ResourceData, meta interface{}) error { request.Description = aws.String(v.(string)) } + if v, ok := d.GetOk("max_session_duration"); ok { + request.MaxSessionDuration = aws.Int64(int64(v.(int))) + } + var createResp *iam.CreateRoleOutput err := resource.Retry(30*time.Second, func() *resource.RetryError { var err error @@ -176,6 +188,9 @@ func resourceAwsIamRoleRead(d *schema.ResourceData, meta interface{}) error { if err := d.Set("name", role.RoleName); err != nil { return err } + if err := d.Set("max_session_duration", role.MaxSessionDuration); err != nil { + return err + } if err := d.Set("arn", role.Arn); err != nil { return err } @@ -239,6 +254,21 @@ func resourceAwsIamRoleUpdate(d *schema.ResourceData, meta interface{}) error { } } + if d.HasChange("max_session_duration") { + roleMaxDurationInput := &iam.UpdateRoleInput{ + RoleName: aws.String(d.Id()), + MaxSessionDuration: aws.Int64(int64(d.Get("max_session_duration").(int))), + } + _, err := iamconn.UpdateRole(roleMaxDurationInput) + if err != nil { + if isAWSErr(err, iam.ErrCodeNoSuchEntityException, "") { + d.SetId("") + return nil + } + return fmt.Errorf("Error Updating IAM Role (%s) Max Session Duration: %s", d.Id(), err) + } + } + return nil } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_server_certificate.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_server_certificate.go index 11a1a2479167..ab3caf9619a7 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_server_certificate.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_server_certificate.go @@ -62,28 +62,14 @@ func resourceAwsIAMServerCertificate() *schema.Resource { Computed: true, ForceNew: true, ConflictsWith: []string{"name_prefix"}, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 128 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 128 characters", k)) - } - return - }, + ValidateFunc: validateMaxLength(128), }, "name_prefix": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 102 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 102 characters, name is limited to 128", k)) - } - return - }, + Type: schema.TypeString, + Optional: true, + ForceNew: true, + ValidateFunc: validateMaxLength(128 - resource.UniqueIDSuffixLength), }, "arn": { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_user.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_user.go index 082e9d4dd9dc..b7930f1d0e16 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_user.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_user.go @@ -4,11 +4,13 @@ import ( "fmt" "log" "regexp" + "time" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/iam" + "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" ) @@ -218,13 +220,25 @@ func resourceAwsIamUserDelete(d *schema.ResourceData, meta interface{}) error { } } - _, err = iamconn.DeleteLoginProfile(&iam.DeleteLoginProfileInput{ - UserName: aws.String(d.Id()), + err = resource.Retry(1*time.Minute, func() *resource.RetryError { + _, err = iamconn.DeleteLoginProfile(&iam.DeleteLoginProfileInput{ + UserName: aws.String(d.Id()), + }) + if err != nil { + if isAWSErr(err, iam.ErrCodeNoSuchEntityException, "") { + return nil + } + // EntityTemporarilyUnmodifiable: Login Profile for User XXX cannot be modified while login profile is being created. + if isAWSErr(err, iam.ErrCodeEntityTemporarilyUnmodifiableException, "") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil }) + if err != nil { - if iamerr, ok := err.(awserr.Error); !ok || iamerr.Code() != "NoSuchEntity" { - return fmt.Errorf("Error deleting Account Login Profile: %s", err) - } + return fmt.Errorf("Error deleting Account Login Profile: %s", err) } } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_user_login_profile.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_user_login_profile.go index c60b67feebb2..98c0ac4e8f13 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_user_login_profile.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_user_login_profile.go @@ -1,11 +1,11 @@ package aws import ( - "errors" + "bytes" + "crypto/rand" "fmt" "log" - "math/rand" - "time" + "math/big" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awserr" @@ -13,6 +13,7 @@ import ( "github.com/hashicorp/errwrap" "github.com/hashicorp/terraform/helper/encryption" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsIamUserLoginProfile() *schema.Resource { @@ -40,7 +41,7 @@ func resourceAwsIamUserLoginProfile() *schema.Resource { Type: schema.TypeInt, Optional: true, Default: 20, - ValidateFunc: validateAwsIamLoginProfilePasswordLength, + ValidateFunc: validation.IntBetween(5, 128), }, "key_fingerprint": { @@ -55,46 +56,62 @@ func resourceAwsIamUserLoginProfile() *schema.Resource { } } -func validateAwsIamLoginProfilePasswordLength(v interface{}, _ string) (_ []string, es []error) { - length := v.(int) - if length < 4 { - es = append(es, errors.New("minimum password_length is 4 characters")) - } - if length > 128 { - es = append(es, errors.New("maximum password_length is 128 characters")) - } - return -} +const ( + charLower = "abcdefghijklmnopqrstuvwxyz" + charUpper = "ABCDEFGHIJKLMNOPQRSTUVWXYZ" + charNumbers = "0123456789" + charSymbols = "!@#$%^&*()_+-=[]{}|'" +) -// generatePassword generates a random password of a given length using -// characters that are likely to satisfy any possible AWS password policy -// (given sufficient length). -func generatePassword(length int) string { - charsets := []string{ - "abcdefghijklmnopqrstuvwxyz", - "ABCDEFGHIJKLMNOPQRSTUVWXYZ", - "012346789", - "!@#$%^&*()_+-=[]{}|'", - } +// generateIAMPassword generates a random password of a given length, matching the +// most restrictive iam password policy. +func generateIAMPassword(length int) string { + const charset = charLower + charUpper + charNumbers + charSymbols + + result := make([]byte, length) + charsetSize := big.NewInt(int64(len(charset))) + + // rather than trying to artifically add specific characters from each + // class to the password to match the policy, we generate passwords + // randomly and reject those that don't match. + // + // Even in the worst case, this tends to take less than 10 tries to find a + // matching password. Any sufficiently long password is likely to succeed + // on the first try + for n := 0; n < 100000; n++ { + for i := range result { + r, err := rand.Int(rand.Reader, charsetSize) + if err != nil { + panic(err) + } + if !r.IsInt64() { + panic("rand.Int() not representable as an Int64") + } + + result[i] = charset[r.Int64()] + } + + if !checkIAMPwdPolicy(result) { + continue + } - // Use all character sets - random := rand.New(rand.NewSource(time.Now().UTC().UnixNano())) - components := make(map[int]byte, length) - for i := 0; i < length; i++ { - charset := charsets[i%len(charsets)] - components[i] = charset[random.Intn(len(charset))] + return string(result) } - // Randomise the ordering so we don't end up with a predictable - // lower case, upper case, numeric, symbol pattern - result := make([]byte, length) - i := 0 - for _, b := range components { - result[i] = b - i = i + 1 + panic("failed to generate acceptable password") +} + +// Check the generated password contains all character classes listed in the +// IAM password policy. +func checkIAMPwdPolicy(pass []byte) bool { + if !(bytes.ContainsAny(pass, charLower) && + bytes.ContainsAny(pass, charNumbers) && + bytes.ContainsAny(pass, charSymbols) && + bytes.ContainsAny(pass, charUpper)) { + return false } - return string(result) + return true } func resourceAwsIamUserLoginProfileCreate(d *schema.ResourceData, meta interface{}) error { @@ -124,7 +141,8 @@ func resourceAwsIamUserLoginProfileCreate(d *schema.ResourceData, meta interface } } - initialPassword := generatePassword(passwordLength) + initialPassword := generateIAMPassword(passwordLength) + fingerprint, encrypted, err := encryption.EncryptValue(encryptionKey, initialPassword, "Password") if err != nil { return err diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_user_policy.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_user_policy.go index 6495bc679ee6..0c6e0f6ed715 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_user_policy.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_user_policy.go @@ -17,11 +17,14 @@ func resourceAwsIamUserPolicy() *schema.Resource { return &schema.Resource{ // PutUserPolicy API is idempotent, so these can be the same. Create: resourceAwsIamUserPolicyPut, - Update: resourceAwsIamUserPolicyPut, - Read: resourceAwsIamUserPolicyRead, + Update: resourceAwsIamUserPolicyPut, Delete: resourceAwsIamUserPolicyDelete, + Importer: &schema.ResourceImporter{ + State: schema.ImportStatePassthrough, + }, + Schema: map[string]*schema.Schema{ "policy": &schema.Schema{ Type: schema.TypeString, @@ -59,8 +62,12 @@ func resourceAwsIamUserPolicyPut(d *schema.ResourceData, meta interface{}) error } var policyName string + var err error if !d.IsNewResource() { - _, policyName = resourceAwsIamUserPolicyParseId(d.Id()) + _, policyName, err = resourceAwsIamUserPolicyParseId(d.Id()) + if err != nil { + return err + } } else if v, ok := d.GetOk("name"); ok { policyName = v.(string) } else if v, ok := d.GetOk("name_prefix"); ok { @@ -81,14 +88,16 @@ func resourceAwsIamUserPolicyPut(d *schema.ResourceData, meta interface{}) error func resourceAwsIamUserPolicyRead(d *schema.ResourceData, meta interface{}) error { iamconn := meta.(*AWSClient).iamconn - user, name := resourceAwsIamUserPolicyParseId(d.Id()) + user, name, err := resourceAwsIamUserPolicyParseId(d.Id()) + if err != nil { + return err + } request := &iam.GetUserPolicyInput{ PolicyName: aws.String(name), UserName: aws.String(user), } - var err error getResp, err := iamconn.GetUserPolicy(request) if err != nil { if iamerr, ok := err.(awserr.Error); ok && iamerr.Code() == "NoSuchEntity" { // XXX test me @@ -106,13 +115,22 @@ func resourceAwsIamUserPolicyRead(d *schema.ResourceData, meta interface{}) erro if err != nil { return err } - return d.Set("policy", policy) + if err := d.Set("policy", policy); err != nil { + return err + } + if err := d.Set("name", name); err != nil { + return err + } + return d.Set("user", user) } func resourceAwsIamUserPolicyDelete(d *schema.ResourceData, meta interface{}) error { iamconn := meta.(*AWSClient).iamconn - user, name := resourceAwsIamUserPolicyParseId(d.Id()) + user, name, err := resourceAwsIamUserPolicyParseId(d.Id()) + if err != nil { + return err + } request := &iam.DeleteUserPolicyInput{ PolicyName: aws.String(name), @@ -125,8 +143,13 @@ func resourceAwsIamUserPolicyDelete(d *schema.ResourceData, meta interface{}) er return nil } -func resourceAwsIamUserPolicyParseId(id string) (userName, policyName string) { +func resourceAwsIamUserPolicyParseId(id string) (userName, policyName string, err error) { parts := strings.SplitN(id, ":", 2) + if len(parts) != 2 { + err = fmt.Errorf("user_policy id must be of the form :") + return + } + userName = parts[0] policyName = parts[1] return diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_user_ssh_key.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_user_ssh_key.go index abb449986461..3031c0e6ffad 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_user_ssh_key.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iam_user_ssh_key.go @@ -9,6 +9,7 @@ import ( "github.com/aws/aws-sdk-go/service/iam" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsIamUserSshKey() *schema.Resource { @@ -38,9 +39,12 @@ func resourceAwsIamUserSshKey() *schema.Resource { }, "encoding": &schema.Schema{ - Type: schema.TypeString, - Required: true, - ValidateFunc: validateIamUserSSHKeyEncoding, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + iam.EncodingTypeSsh, + iam.EncodingTypePem, + }, false), }, "status": &schema.Schema{ @@ -136,16 +140,3 @@ func resourceAwsIamUserSshKeyDelete(d *schema.ResourceData, meta interface{}) er } return nil } - -func validateIamUserSSHKeyEncoding(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - encodingTypes := map[string]bool{ - "PEM": true, - "SSH": true, - } - - if !encodingTypes[value] { - errors = append(errors, fmt.Errorf("IAM User SSH Key Encoding can only be PEM or SSH")) - } - return -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_instance.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_instance.go index aab29ccc8e2d..bea0347f1ae4 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_instance.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_instance.go @@ -78,6 +78,17 @@ func resourceAwsInstance() *schema.Resource { Computed: true, }, + "get_password_data": { + Type: schema.TypeBool, + Optional: true, + Default: false, + }, + + "password_data": { + Type: schema.TypeString, + Computed: true, + }, + "subnet_id": { Type: schema.TypeString, Optional: true, @@ -116,7 +127,7 @@ func resourceAwsInstance() *schema.Resource { return "" } }, - ValidateFunc: validateInstanceUserDataSize, + ValidateFunc: validateMaxLength(16384), }, "user_data_base64": { @@ -773,6 +784,17 @@ func resourceAwsInstanceRead(d *schema.ResourceData, meta interface{}) error { } } + if d.Get("get_password_data").(bool) { + passwordData, err := getAwsEc2InstancePasswordData(*instance.InstanceId, conn) + if err != nil { + return err + } + d.Set("password_data", passwordData) + } else { + d.Set("get_password_data", false) + d.Set("password_data", nil) + } + return nil } @@ -921,6 +943,10 @@ func resourceAwsInstanceUpdate(d *schema.ResourceData, meta interface{}) error { groups = append(groups, aws.String(v.(string))) } } + + if len(groups) < 1 { + return fmt.Errorf("VPC-based instances require at least one security group to be attached.") + } // If a user has multiple network interface attachments on the target EC2 instance, simply modifying the // instance attributes via a `ModifyInstanceAttributes()` request would fail with the following error message: // "There are multiple interfaces attached to instance 'i-XX'. Please specify an interface ID for the operation instead." @@ -1554,6 +1580,37 @@ func readSecurityGroups(d *schema.ResourceData, instance *ec2.Instance, conn *ec return nil } +func getAwsEc2InstancePasswordData(instanceID string, conn *ec2.EC2) (string, error) { + log.Printf("[INFO] Reading password data for instance %s", instanceID) + + var passwordData string + + err := resource.Retry(15*time.Minute, func() *resource.RetryError { + resp, err := conn.GetPasswordData(&ec2.GetPasswordDataInput{ + InstanceId: aws.String(instanceID), + }) + + if err != nil { + return resource.NonRetryableError(err) + } + + if resp.PasswordData == nil || *resp.PasswordData == "" { + return resource.RetryableError(fmt.Errorf("Password data is blank for instance ID: %s", instanceID)) + } + + passwordData = strings.TrimSpace(*resp.PasswordData) + + log.Printf("[INFO] Password data read for instance %s", instanceID) + return nil + }) + + if err != nil { + return "", err + } + + return passwordData, nil +} + type awsInstanceOpts struct { BlockDeviceMappings []*ec2.BlockDeviceMapping DisableAPITermination *bool diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iot_thing.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iot_thing.go new file mode 100644 index 000000000000..3fef149f88e7 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_iot_thing.go @@ -0,0 +1,162 @@ +package aws + +import ( + "log" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/iot" + "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" +) + +func resourceAwsIotThing() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsIotThingCreate, + Read: resourceAwsIotThingRead, + Update: resourceAwsIotThingUpdate, + Delete: resourceAwsIotThingDelete, + + Importer: &schema.ResourceImporter{ + State: schema.ImportStatePassthrough, + }, + + Schema: map[string]*schema.Schema{ + "name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validation.StringLenBetween(1, 128), + }, + "attributes": { + Type: schema.TypeMap, + Optional: true, + }, + "thing_type_name": { + Type: schema.TypeString, + Optional: true, + ValidateFunc: validation.StringLenBetween(1, 128), + }, + "default_client_id": { + Type: schema.TypeString, + Computed: true, + }, + "version": { + Type: schema.TypeInt, + Computed: true, + }, + "arn": { + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func resourceAwsIotThingCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).iotconn + + params := &iot.CreateThingInput{ + ThingName: aws.String(d.Get("name").(string)), + } + + if v, ok := d.GetOk("thing_type_name"); ok { + params.ThingTypeName = aws.String(v.(string)) + } + if v, ok := d.GetOk("attributes"); ok { + params.AttributePayload = &iot.AttributePayload{ + Attributes: stringMapToPointers(v.(map[string]interface{})), + } + } + + log.Printf("[DEBUG] Creating IoT Thing: %s", params) + out, err := conn.CreateThing(params) + if err != nil { + return err + } + + d.SetId(*out.ThingName) + + return resourceAwsIotThingRead(d, meta) +} + +func resourceAwsIotThingRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).iotconn + + params := &iot.DescribeThingInput{ + ThingName: aws.String(d.Id()), + } + log.Printf("[DEBUG] Reading IoT Thing: %s", params) + out, err := conn.DescribeThing(params) + + if err != nil { + if isAWSErr(err, iot.ErrCodeResourceNotFoundException, "") { + log.Printf("[WARN] IoT Thing %q not found, removing from state", d.Id()) + d.SetId("") + } + return err + } + + log.Printf("[DEBUG] Received IoT Thing: %s", out) + + d.Set("arn", out.ThingArn) + d.Set("name", out.ThingName) + d.Set("attributes", aws.StringValueMap(out.Attributes)) + d.Set("default_client_id", out.DefaultClientId) + d.Set("thing_type_name", out.ThingTypeName) + d.Set("version", out.Version) + + return nil +} + +func resourceAwsIotThingUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).iotconn + + params := &iot.UpdateThingInput{ + ThingName: aws.String(d.Get("name").(string)), + } + if d.HasChange("thing_type_name") { + if v, ok := d.GetOk("thing_type_name"); ok { + params.ThingTypeName = aws.String(v.(string)) + } else { + params.RemoveThingType = aws.Bool(true) + } + } + if d.HasChange("attributes") { + attributes := map[string]*string{} + + if v, ok := d.GetOk("attributes"); ok { + if m, ok := v.(map[string]interface{}); ok { + attributes = stringMapToPointers(m) + } + } + params.AttributePayload = &iot.AttributePayload{ + Attributes: attributes, + } + } + + _, err := conn.UpdateThing(params) + if err != nil { + return err + } + + return resourceAwsIotThingRead(d, meta) +} + +func resourceAwsIotThingDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).iotconn + + params := &iot.DeleteThingInput{ + ThingName: aws.String(d.Id()), + } + log.Printf("[DEBUG] Deleting IoT Thing: %s", params) + + _, err := conn.DeleteThing(params) + if err != nil { + if isAWSErr(err, iot.ErrCodeResourceNotFoundException, "") { + return nil + } + return err + } + + return nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_key_pair.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_key_pair.go index 02050c7af981..a8f30c992698 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_key_pair.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_key_pair.go @@ -26,27 +26,21 @@ func resourceAwsKeyPair() *schema.Resource { MigrateState: resourceAwsKeyPairMigrateState, Schema: map[string]*schema.Schema{ - "key_name": &schema.Schema{ + "key_name": { Type: schema.TypeString, Optional: true, Computed: true, ForceNew: true, ConflictsWith: []string{"key_name_prefix"}, + ValidateFunc: validateMaxLength(255), }, - "key_name_prefix": &schema.Schema{ - Type: schema.TypeString, - Optional: true, - ForceNew: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 100 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 100 characters, name is limited to 255", k)) - } - return - }, + "key_name_prefix": { + Type: schema.TypeString, + Optional: true, + ForceNew: true, + ValidateFunc: validateMaxLength(255 - resource.UniqueIDSuffixLength), }, - "public_key": &schema.Schema{ + "public_key": { Type: schema.TypeString, Required: true, ForceNew: true, @@ -59,7 +53,7 @@ func resourceAwsKeyPair() *schema.Resource { } }, }, - "fingerprint": &schema.Schema{ + "fingerprint": { Type: schema.TypeString, Computed: true, }, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kinesis_firehose_delivery_stream.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kinesis_firehose_delivery_stream.go index 1d4762f5fc05..c32bdba849a7 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kinesis_firehose_delivery_stream.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kinesis_firehose_delivery_stream.go @@ -121,9 +121,9 @@ func processingConfigurationSchema() *schema.Schema { Required: true, ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { value := v.(string) - if value != "LambdaArn" && value != "NumberOfRetries" { + if value != "LambdaArn" && value != "NumberOfRetries" && value != "RoleArn" && value != "BufferSizeInMBs" && value != "BufferIntervalInSeconds" { errors = append(errors, fmt.Errorf( - "%q must be one of 'LambdaArn', 'NumberOfRetries'", k)) + "%q must be one of 'LambdaArn', 'NumberOfRetries', 'RoleArn', 'BufferSizeInMBs', 'BufferIntervalInSeconds'", k)) } return }, @@ -174,41 +174,159 @@ func cloudwatchLoggingOptionsHash(v interface{}) int { return hashcode.String(buf.String()) } -func flattenCloudwatchLoggingOptions(clo firehose.CloudWatchLoggingOptions) *schema.Set { +func flattenCloudwatchLoggingOptions(clo *firehose.CloudWatchLoggingOptions) *schema.Set { + if clo == nil { + return schema.NewSet(cloudwatchLoggingOptionsHash, []interface{}{}) + } + cloudwatchLoggingOptions := map[string]interface{}{ - "enabled": *clo.Enabled, + "enabled": aws.BoolValue(clo.Enabled), } - if *clo.Enabled { - cloudwatchLoggingOptions["log_group_name"] = *clo.LogGroupName - cloudwatchLoggingOptions["log_stream_name"] = *clo.LogStreamName + if aws.BoolValue(clo.Enabled) { + cloudwatchLoggingOptions["log_group_name"] = aws.StringValue(clo.LogGroupName) + cloudwatchLoggingOptions["log_stream_name"] = aws.StringValue(clo.LogStreamName) } return schema.NewSet(cloudwatchLoggingOptionsHash, []interface{}{cloudwatchLoggingOptions}) } -func flattenFirehoseS3Configuration(s3 firehose.S3DestinationDescription) []interface{} { - s3Configuration := map[string]interface{}{ - "role_arn": *s3.RoleARN, - "bucket_arn": *s3.BucketARN, - "buffer_size": *s3.BufferingHints.SizeInMBs, - "buffer_interval": *s3.BufferingHints.IntervalInSeconds, - "compression_format": *s3.CompressionFormat, +func flattenFirehoseElasticsearchConfiguration(description *firehose.ElasticsearchDestinationDescription) []map[string]interface{} { + if description == nil { + return []map[string]interface{}{} + } + + m := map[string]interface{}{ + "cloudwatch_logging_options": flattenCloudwatchLoggingOptions(description.CloudWatchLoggingOptions), + "domain_arn": aws.StringValue(description.DomainARN), + "role_arn": aws.StringValue(description.RoleARN), + "type_name": aws.StringValue(description.TypeName), + "index_name": aws.StringValue(description.IndexName), + "s3_backup_mode": aws.StringValue(description.S3BackupMode), + "index_rotation_period": aws.StringValue(description.IndexRotationPeriod), + "processing_configuration": flattenProcessingConfiguration(description.ProcessingConfiguration, aws.StringValue(description.RoleARN)), + } + + if description.BufferingHints != nil { + m["buffering_interval"] = int(aws.Int64Value(description.BufferingHints.IntervalInSeconds)) + m["buffering_size"] = int(aws.Int64Value(description.BufferingHints.SizeInMBs)) + } + + if description.RetryOptions != nil { + m["retry_duration"] = int(aws.Int64Value(description.RetryOptions.DurationInSeconds)) + } + + return []map[string]interface{}{m} +} + +func flattenFirehoseExtendedS3Configuration(description *firehose.ExtendedS3DestinationDescription) []map[string]interface{} { + if description == nil { + return []map[string]interface{}{} + } + + m := map[string]interface{}{ + "bucket_arn": aws.StringValue(description.BucketARN), + "cloudwatch_logging_options": flattenCloudwatchLoggingOptions(description.CloudWatchLoggingOptions), + "compression_format": aws.StringValue(description.CompressionFormat), + "prefix": aws.StringValue(description.Prefix), + "processing_configuration": flattenProcessingConfiguration(description.ProcessingConfiguration, aws.StringValue(description.RoleARN)), + "role_arn": aws.StringValue(description.RoleARN), + "s3_backup_configuration": flattenFirehoseS3Configuration(description.S3BackupDescription), + "s3_backup_mode": aws.StringValue(description.S3BackupMode), + } + + if description.BufferingHints != nil { + m["buffer_interval"] = int(aws.Int64Value(description.BufferingHints.IntervalInSeconds)) + m["buffer_size"] = int(aws.Int64Value(description.BufferingHints.SizeInMBs)) + } + + if description.EncryptionConfiguration != nil && description.EncryptionConfiguration.KMSEncryptionConfig != nil { + m["kms_key_arn"] = aws.StringValue(description.EncryptionConfiguration.KMSEncryptionConfig.AWSKMSKeyARN) + } + + return []map[string]interface{}{m} +} + +func flattenFirehoseRedshiftConfiguration(description *firehose.RedshiftDestinationDescription, configuredPassword string) []map[string]interface{} { + if description == nil { + return []map[string]interface{}{} + } + + m := map[string]interface{}{ + "cloudwatch_logging_options": flattenCloudwatchLoggingOptions(description.CloudWatchLoggingOptions), + "cluster_jdbcurl": aws.StringValue(description.ClusterJDBCURL), + "password": configuredPassword, + "role_arn": aws.StringValue(description.RoleARN), + "s3_backup_configuration": flattenFirehoseS3Configuration(description.S3BackupDescription), + "s3_backup_mode": aws.StringValue(description.S3BackupMode), + "username": aws.StringValue(description.Username), + } + + if description.CopyCommand != nil { + m["copy_options"] = aws.StringValue(description.CopyCommand.CopyOptions) + m["data_table_columns"] = aws.StringValue(description.CopyCommand.DataTableColumns) + m["data_table_name"] = aws.StringValue(description.CopyCommand.DataTableName) + } + + if description.RetryOptions != nil { + m["retry_duration"] = int(aws.Int64Value(description.RetryOptions.DurationInSeconds)) + } + + return []map[string]interface{}{m} +} + +func flattenFirehoseSplunkConfiguration(description *firehose.SplunkDestinationDescription) []map[string]interface{} { + if description == nil { + return []map[string]interface{}{} } - if s3.CloudWatchLoggingOptions != nil { - s3Configuration["cloudwatch_logging_options"] = flattenCloudwatchLoggingOptions(*s3.CloudWatchLoggingOptions) + m := map[string]interface{}{ + "cloudwatch_logging_options": flattenCloudwatchLoggingOptions(description.CloudWatchLoggingOptions), + "hec_acknowledgment_timeout": int(aws.Int64Value(description.HECAcknowledgmentTimeoutInSeconds)), + "hec_endpoint_type": aws.StringValue(description.HECEndpointType), + "hec_endpoint": aws.StringValue(description.HECEndpoint), + "hec_token": aws.StringValue(description.HECToken), + "processing_configuration": flattenProcessingConfiguration(description.ProcessingConfiguration, ""), + "s3_backup_mode": aws.StringValue(description.S3BackupMode), } - if s3.EncryptionConfiguration.KMSEncryptionConfig != nil { - s3Configuration["kms_key_arn"] = *s3.EncryptionConfiguration.KMSEncryptionConfig.AWSKMSKeyARN + + if description.RetryOptions != nil { + m["retry_duration"] = int(aws.Int64Value(description.RetryOptions.DurationInSeconds)) + } + + return []map[string]interface{}{m} +} + +func flattenFirehoseS3Configuration(description *firehose.S3DestinationDescription) []map[string]interface{} { + if description == nil { + return []map[string]interface{}{} } - if s3.Prefix != nil { - s3Configuration["prefix"] = *s3.Prefix + + m := map[string]interface{}{ + "bucket_arn": aws.StringValue(description.BucketARN), + "cloudwatch_logging_options": flattenCloudwatchLoggingOptions(description.CloudWatchLoggingOptions), + "compression_format": aws.StringValue(description.CompressionFormat), + "prefix": aws.StringValue(description.Prefix), + "role_arn": aws.StringValue(description.RoleARN), } - return []interface{}{s3Configuration} + + if description.BufferingHints != nil { + m["buffer_interval"] = int(aws.Int64Value(description.BufferingHints.IntervalInSeconds)) + m["buffer_size"] = int(aws.Int64Value(description.BufferingHints.SizeInMBs)) + } + + if description.EncryptionConfiguration != nil && description.EncryptionConfiguration.KMSEncryptionConfig != nil { + m["kms_key_arn"] = aws.StringValue(description.EncryptionConfiguration.KMSEncryptionConfig.AWSKMSKeyARN) + } + + return []map[string]interface{}{m} } -func flattenProcessingConfiguration(pc firehose.ProcessingConfiguration, roleArn string) []map[string]interface{} { +func flattenProcessingConfiguration(pc *firehose.ProcessingConfiguration, roleArn string) []map[string]interface{} { + if pc == nil { + return []map[string]interface{}{} + } + processingConfiguration := make([]map[string]interface{}, 1) - // It is necessary to explicitely filter this out + // It is necessary to explicitly filter this out // to prevent diffs during routine use and retain the ability // to show diffs if any field has drifted defaultLambdaParams := map[string]string{ @@ -220,11 +338,12 @@ func flattenProcessingConfiguration(pc firehose.ProcessingConfiguration, roleArn processors := make([]interface{}, len(pc.Processors), len(pc.Processors)) for i, p := range pc.Processors { - t := *p.Type + t := aws.StringValue(p.Type) parameters := make([]interface{}, 0) for _, params := range p.Parameters { - name, value := *params.ParameterName, *params.ParameterValue + name := aws.StringValue(params.ParameterName) + value := aws.StringValue(params.ParameterValue) if t == firehose.ProcessorTypeLambda { // Ignore defaults @@ -245,7 +364,7 @@ func flattenProcessingConfiguration(pc firehose.ProcessingConfiguration, roleArn } } processingConfiguration[0] = map[string]interface{}{ - "enabled": *pc.Enabled, + "enabled": aws.BoolValue(pc.Enabled), "processors": processors, } return processingConfiguration @@ -259,110 +378,41 @@ func flattenKinesisFirehoseDeliveryStream(d *schema.ResourceData, s *firehose.De destination := s.Destinations[0] if destination.RedshiftDestinationDescription != nil { d.Set("destination", "redshift") - password := d.Get("redshift_configuration.0.password").(string) - - redshiftConfiguration := map[string]interface{}{ - "cluster_jdbcurl": *destination.RedshiftDestinationDescription.ClusterJDBCURL, - "role_arn": *destination.RedshiftDestinationDescription.RoleARN, - "username": *destination.RedshiftDestinationDescription.Username, - "password": password, - "data_table_name": *destination.RedshiftDestinationDescription.CopyCommand.DataTableName, - "copy_options": *destination.RedshiftDestinationDescription.CopyCommand.CopyOptions, - "data_table_columns": *destination.RedshiftDestinationDescription.CopyCommand.DataTableColumns, - "s3_backup_mode": *destination.RedshiftDestinationDescription.S3BackupMode, - "retry_duration": *destination.RedshiftDestinationDescription.RetryOptions.DurationInSeconds, - } - - if v := destination.RedshiftDestinationDescription.CloudWatchLoggingOptions; v != nil { - redshiftConfiguration["cloudwatch_logging_options"] = flattenCloudwatchLoggingOptions(*v) + configuredPassword := d.Get("redshift_configuration.0.password").(string) + if err := d.Set("redshift_configuration", flattenFirehoseRedshiftConfiguration(destination.RedshiftDestinationDescription, configuredPassword)); err != nil { + return fmt.Errorf("error setting redshift_configuration: %s", err) } - - if v := destination.RedshiftDestinationDescription.S3BackupDescription; v != nil { - redshiftConfiguration["s3_backup_configuration"] = flattenFirehoseS3Configuration(*v) + if err := d.Set("s3_configuration", flattenFirehoseS3Configuration(destination.RedshiftDestinationDescription.S3DestinationDescription)); err != nil { + return fmt.Errorf("error setting s3_configuration: %s", err) } - - redshiftConfList := make([]map[string]interface{}, 1) - redshiftConfList[0] = redshiftConfiguration - d.Set("redshift_configuration", redshiftConfList) - d.Set("s3_configuration", flattenFirehoseS3Configuration(*destination.RedshiftDestinationDescription.S3DestinationDescription)) - } else if destination.ElasticsearchDestinationDescription != nil { d.Set("destination", "elasticsearch") - - elasticsearchConfiguration := map[string]interface{}{ - "buffering_interval": *destination.ElasticsearchDestinationDescription.BufferingHints.IntervalInSeconds, - "buffering_size": *destination.ElasticsearchDestinationDescription.BufferingHints.SizeInMBs, - "domain_arn": *destination.ElasticsearchDestinationDescription.DomainARN, - "role_arn": *destination.ElasticsearchDestinationDescription.RoleARN, - "type_name": *destination.ElasticsearchDestinationDescription.TypeName, - "index_name": *destination.ElasticsearchDestinationDescription.IndexName, - "s3_backup_mode": *destination.ElasticsearchDestinationDescription.S3BackupMode, - "retry_duration": *destination.ElasticsearchDestinationDescription.RetryOptions.DurationInSeconds, - "index_rotation_period": *destination.ElasticsearchDestinationDescription.IndexRotationPeriod, + if err := d.Set("elasticsearch_configuration", flattenFirehoseElasticsearchConfiguration(destination.ElasticsearchDestinationDescription)); err != nil { + return fmt.Errorf("error setting elasticsearch_configuration: %s", err) } - - if v := destination.ElasticsearchDestinationDescription.CloudWatchLoggingOptions; v != nil { - elasticsearchConfiguration["cloudwatch_logging_options"] = flattenCloudwatchLoggingOptions(*v) + if err := d.Set("s3_configuration", flattenFirehoseS3Configuration(destination.ElasticsearchDestinationDescription.S3DestinationDescription)); err != nil { + return fmt.Errorf("error setting s3_configuration: %s", err) } - - elasticsearchConfList := make([]map[string]interface{}, 1) - elasticsearchConfList[0] = elasticsearchConfiguration - d.Set("elasticsearch_configuration", elasticsearchConfList) - d.Set("s3_configuration", flattenFirehoseS3Configuration(*destination.ElasticsearchDestinationDescription.S3DestinationDescription)) } else if destination.SplunkDestinationDescription != nil { d.Set("destination", "splunk") - - splunkConfiguration := map[string]interface{}{ - "hec_acknowledgment_timeout": *destination.SplunkDestinationDescription.HECAcknowledgmentTimeoutInSeconds, - "hec_endpoint": *destination.SplunkDestinationDescription.HECEndpoint, - "hec_endpoint_type": *destination.SplunkDestinationDescription.HECEndpointType, - "hec_token": *destination.SplunkDestinationDescription.HECToken, - "s3_backup_mode": *destination.SplunkDestinationDescription.S3BackupMode, - "retry_duration": *destination.SplunkDestinationDescription.RetryOptions.DurationInSeconds, + if err := d.Set("splunk_configuration", flattenFirehoseSplunkConfiguration(destination.SplunkDestinationDescription)); err != nil { + return fmt.Errorf("error setting splunk_configuration: %s", err) } - - if v := destination.SplunkDestinationDescription.CloudWatchLoggingOptions; v != nil { - splunkConfiguration["cloudwatch_logging_options"] = flattenCloudwatchLoggingOptions(*v) + if err := d.Set("s3_configuration", flattenFirehoseS3Configuration(destination.SplunkDestinationDescription.S3DestinationDescription)); err != nil { + return fmt.Errorf("error setting s3_configuration: %s", err) } - - splunkConfList := make([]map[string]interface{}, 1) - splunkConfList[0] = splunkConfiguration - d.Set("splunk_configuration", splunkConfList) - d.Set("s3_configuration", flattenFirehoseS3Configuration(*destination.SplunkDestinationDescription.S3DestinationDescription)) } else if d.Get("destination").(string) == "s3" { d.Set("destination", "s3") - d.Set("s3_configuration", flattenFirehoseS3Configuration(*destination.S3DestinationDescription)) + if err := d.Set("s3_configuration", flattenFirehoseS3Configuration(destination.S3DestinationDescription)); err != nil { + return fmt.Errorf("error setting s3_configuration: %s", err) + } } else { d.Set("destination", "extended_s3") - - roleArn := *destination.ExtendedS3DestinationDescription.RoleARN - extendedS3Configuration := map[string]interface{}{ - "buffer_interval": *destination.ExtendedS3DestinationDescription.BufferingHints.IntervalInSeconds, - "buffer_size": *destination.ExtendedS3DestinationDescription.BufferingHints.SizeInMBs, - "bucket_arn": *destination.ExtendedS3DestinationDescription.BucketARN, - "role_arn": roleArn, - "compression_format": *destination.ExtendedS3DestinationDescription.CompressionFormat, - "prefix": *destination.ExtendedS3DestinationDescription.Prefix, - "cloudwatch_logging_options": flattenCloudwatchLoggingOptions(*destination.ExtendedS3DestinationDescription.CloudWatchLoggingOptions), - } - - if v := destination.ExtendedS3DestinationDescription.EncryptionConfiguration.KMSEncryptionConfig; v != nil { - extendedS3Configuration["kms_key_arn"] = *v.AWSKMSKeyARN - } - - if v := destination.ExtendedS3DestinationDescription.ProcessingConfiguration; v != nil { - extendedS3Configuration["processing_configuration"] = flattenProcessingConfiguration(*v, roleArn) - } - - extendedS3ConfList := make([]map[string]interface{}, 1) - extendedS3ConfList[0] = extendedS3Configuration - - err := d.Set("extended_s3_configuration", extendedS3ConfList) - if err != nil { - return err + if err := d.Set("extended_s3_configuration", flattenFirehoseExtendedS3Configuration(destination.ExtendedS3DestinationDescription)); err != nil { + return fmt.Errorf("error setting extended_s3_configuration: %s", err) } } - d.Set("destination_id", *destination.DestinationId) + d.Set("destination_id", destination.DestinationId) } return nil } @@ -376,11 +426,16 @@ func resourceAwsKinesisFirehoseDeliveryStream() *schema.Resource { Importer: &schema.ResourceImporter{ State: func(d *schema.ResourceData, meta interface{}) ([]*schema.ResourceData, error) { + idErr := fmt.Errorf("Expected ID in format of arn:PARTITION:firehose:REGION:ACCOUNTID:deliverystream/NAME and provided: %s", d.Id()) resARN, err := arn.Parse(d.Id()) if err != nil { - return nil, err + return nil, idErr + } + resourceParts := strings.Split(resARN.Resource, "/") + if len(resourceParts) != 2 { + return nil, idErr } - d.Set("name", strings.Split(resARN.Resource, "/")[1]) + d.Set("name", resourceParts[1]) return []*schema.ResourceData{d}, nil }, }, @@ -490,6 +545,22 @@ func resourceAwsKinesisFirehoseDeliveryStream() *schema.Resource { Optional: true, }, + "s3_backup_mode": { + Type: schema.TypeString, + Optional: true, + Default: "Disabled", + ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { + value := v.(string) + if value != "Disabled" && value != "Enabled" { + errors = append(errors, fmt.Errorf( + "%q must be one of 'Disabled', 'Enabled'", k)) + } + return + }, + }, + + "s3_backup_configuration": s3ConfigurationSchema(), + "cloudwatch_logging_options": cloudWatchLoggingOptionsSchema(), "processing_configuration": processingConfigurationSchema(), @@ -679,6 +750,8 @@ func resourceAwsKinesisFirehoseDeliveryStream() *schema.Resource { }, "cloudwatch_logging_options": cloudWatchLoggingOptionsSchema(), + + "processing_configuration": processingConfigurationSchema(), }, }, }, @@ -851,6 +924,11 @@ func createExtendedS3Config(d *schema.ResourceData) *firehose.ExtendedS3Destinat configuration.CloudWatchLoggingOptions = extractCloudWatchLoggingConfiguration(s3) } + if s3BackupMode, ok := s3["s3_backup_mode"]; ok { + configuration.S3BackupMode = aws.String(s3BackupMode.(string)) + configuration.S3BackupConfiguration = expandS3BackupConfig(d.Get("extended_s3_configuration").([]interface{})[0].(map[string]interface{})) + } + return configuration } @@ -926,6 +1004,11 @@ func updateExtendedS3Config(d *schema.ResourceData) *firehose.ExtendedS3Destinat configuration.CloudWatchLoggingOptions = extractCloudWatchLoggingConfiguration(s3) } + if s3BackupMode, ok := s3["s3_backup_mode"]; ok { + configuration.S3BackupMode = aws.String(s3BackupMode.(string)) + configuration.S3BackupUpdate = updateS3BackupConfig(d.Get("extended_s3_configuration").([]interface{})[0].(map[string]interface{})) + } + return configuration } @@ -1107,6 +1190,10 @@ func createElasticsearchConfig(d *schema.ResourceData, s3Config *firehose.S3Dest config.CloudWatchLoggingOptions = extractCloudWatchLoggingConfiguration(es) } + if _, ok := es["processing_configuration"]; ok { + config.ProcessingConfiguration = extractProcessingConfiguration(es) + } + if indexRotationPeriod, ok := es["index_rotation_period"]; ok { config.IndexRotationPeriod = aws.String(indexRotationPeriod.(string)) } @@ -1140,6 +1227,10 @@ func updateElasticsearchConfig(d *schema.ResourceData, s3Update *firehose.S3Dest update.CloudWatchLoggingOptions = extractCloudWatchLoggingConfiguration(es) } + if _, ok := es["processing_configuration"]; ok { + update.ProcessingConfiguration = extractProcessingConfiguration(es) + } + if indexRotationPeriod, ok := es["index_rotation_period"]; ok { update.IndexRotationPeriod = aws.String(indexRotationPeriod.(string)) } @@ -1165,6 +1256,10 @@ func createSplunkConfig(d *schema.ResourceData, s3Config *firehose.S3Destination S3Configuration: s3Config, } + if _, ok := splunk["processing_configuration"]; ok { + configuration.ProcessingConfiguration = extractProcessingConfiguration(splunk) + } + if _, ok := splunk["cloudwatch_logging_options"]; ok { configuration.CloudWatchLoggingOptions = extractCloudWatchLoggingConfiguration(splunk) } @@ -1193,6 +1288,10 @@ func updateSplunkConfig(d *schema.ResourceData, s3Update *firehose.S3Destination S3Update: s3Update, } + if _, ok := splunk["processing_configuration"]; ok { + configuration.ProcessingConfiguration = extractProcessingConfiguration(splunk) + } + if _, ok := splunk["cloudwatch_logging_options"]; ok { configuration.CloudWatchLoggingOptions = extractCloudWatchLoggingConfiguration(splunk) } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kinesis_stream.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kinesis_stream.go index cf4a60430b23..45c7e2ec7cf1 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kinesis_stream.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kinesis_stream.go @@ -44,17 +44,10 @@ func resourceAwsKinesisStream() *schema.Resource { }, "retention_period": { - Type: schema.TypeInt, - Optional: true, - Default: 24, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(int) - if value < 24 || value > 168 { - errors = append(errors, fmt.Errorf( - "%q must be between 24 and 168 hours", k)) - } - return - }, + Type: schema.TypeInt, + Optional: true, + Default: 24, + ValidateFunc: validation.IntBetween(24, 168), }, "shard_level_metrics": { @@ -65,10 +58,13 @@ func resourceAwsKinesisStream() *schema.Resource { }, "encryption_type": { - Type: schema.TypeString, - Optional: true, - Default: "NONE", - ValidateFunc: validation.StringInSlice([]string{"NONE", "KMS"}, true), + Type: schema.TypeString, + Optional: true, + Default: "NONE", + ValidateFunc: validation.StringInSlice([]string{ + kinesis.EncryptionTypeNone, + kinesis.EncryptionTypeKms, + }, true), DiffSuppressFunc: func(k, old, new string, d *schema.ResourceData) bool { if strings.ToLower(old) == strings.ToLower(new) { return true diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kms_alias.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kms_alias.go index d394850a64b7..6f724d7a9920 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kms_alias.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kms_alias.go @@ -3,7 +3,6 @@ package aws import ( "fmt" "log" - "regexp" "time" "github.com/hashicorp/terraform/helper/resource" @@ -38,17 +37,10 @@ func resourceAwsKmsAlias() *schema.Resource { ValidateFunc: validateAwsKmsName, }, "name_prefix": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, - ValidateFunc: func(v interface{}, k string) (ws []string, es []error) { - value := v.(string) - if !regexp.MustCompile(`^(alias\/)[a-zA-Z0-9:/_-]+$`).MatchString(value) { - es = append(es, fmt.Errorf( - "%q must begin with 'alias/' and be comprised of only [a-zA-Z0-9:/_-]", k)) - } - return - }, + Type: schema.TypeString, + Optional: true, + ForceNew: true, + ValidateFunc: validateAwsKmsName, }, "target_key_id": { Type: schema.TypeString, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kms_grant.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kms_grant.go new file mode 100644 index 000000000000..9d171dd5bf3f --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kms_grant.go @@ -0,0 +1,540 @@ +package aws + +import ( + "bytes" + "fmt" + "log" + "sort" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/kms" + "github.com/hashicorp/terraform/helper/hashcode" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" +) + +func resourceAwsKmsGrant() *schema.Resource { + return &schema.Resource{ + // There is no API for updating/modifying grants, hence no Update + // Instead changes to most fields will force a new resource + Create: resourceAwsKmsGrantCreate, + Read: resourceAwsKmsGrantRead, + Delete: resourceAwsKmsGrantDelete, + Exists: resourceAwsKmsGrantExists, + + Schema: map[string]*schema.Schema{ + "name": { + Type: schema.TypeString, + Optional: true, + ForceNew: true, + ValidateFunc: validateAwsKmsGrantName, + }, + "key_id": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "grantee_principal": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validateArn, + }, + "operations": { + Type: schema.TypeSet, + Set: schema.HashString, + Elem: &schema.Schema{ + Type: schema.TypeString, + ValidateFunc: validation.StringInSlice([]string{ + kms.GrantOperationCreateGrant, + kms.GrantOperationDecrypt, + kms.GrantOperationDescribeKey, + kms.GrantOperationEncrypt, + kms.GrantOperationGenerateDataKey, + kms.GrantOperationGenerateDataKeyWithoutPlaintext, + kms.GrantOperationReEncryptFrom, + kms.GrantOperationReEncryptTo, + kms.GrantOperationRetireGrant, + }, false), + }, + Required: true, + ForceNew: true, + }, + "constraints": { + Type: schema.TypeSet, + Set: resourceKmsGrantConstraintsHash, + Optional: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "encryption_context_equals": { + Type: schema.TypeMap, + Optional: true, + ForceNew: true, + Elem: schema.TypeString, + // ConflictsWith encryption_context_subset handled in Create, see kmsGrantConstraintsIsValid + }, + "encryption_context_subset": { + Type: schema.TypeMap, + Optional: true, + ForceNew: true, + Elem: schema.TypeString, + // ConflictsWith encryption_context_equals handled in Create, see kmsGrantConstraintsIsValid + }, + }, + }, + }, + "retiring_principal": { + Type: schema.TypeString, + Optional: true, + ForceNew: true, + ValidateFunc: validateArn, + }, + "grant_creation_tokens": { + Type: schema.TypeSet, + Elem: &schema.Schema{Type: schema.TypeString}, + Optional: true, + ForceNew: true, + }, + "retire_on_delete": { + Type: schema.TypeBool, + Optional: true, + Default: false, + ForceNew: true, + }, + "grant_id": { + Type: schema.TypeString, + Computed: true, + }, + "grant_token": { + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func resourceAwsKmsGrantCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).kmsconn + keyId := d.Get("key_id").(string) + + input := kms.CreateGrantInput{ + GranteePrincipal: aws.String(d.Get("grantee_principal").(string)), + KeyId: aws.String(keyId), + Operations: expandStringSet(d.Get("operations").(*schema.Set)), + } + + if v, ok := d.GetOk("name"); ok { + input.Name = aws.String(v.(string)) + } + if v, ok := d.GetOk("constraints"); ok { + if !kmsGrantConstraintsIsValid(v.(*schema.Set)) { + return fmt.Errorf("[ERROR] A grant constraint can't have both encryption_context_equals and encryption_context_subset set") + } + input.Constraints = expandKmsGrantConstraints(v.(*schema.Set)) + } + if v, ok := d.GetOk("retiring_principal"); ok { + input.RetiringPrincipal = aws.String(v.(string)) + } + if v, ok := d.GetOk("grant_creation_tokens"); ok { + input.GrantTokens = expandStringSet(v.(*schema.Set)) + } + + log.Printf("[DEBUG]: Adding new KMS Grant: %s", input) + + var out *kms.CreateGrantOutput + + err := resource.Retry(3*time.Minute, func() *resource.RetryError { + var err error + + out, err = conn.CreateGrant(&input) + + if err != nil { + // Error Codes: https://docs.aws.amazon.com/sdk-for-go/api/service/kms/#KMS.CreateGrant + // Under some circumstances a newly created IAM Role doesn't show up and causes + // an InvalidArnException to be thrown. + if isAWSErr(err, kms.ErrCodeDependencyTimeoutException, "") || + isAWSErr(err, kms.ErrCodeInternalException, "") || + isAWSErr(err, kms.ErrCodeInvalidArnException, "") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error adding new KMS Grant for key: %s, retrying %s", + *input.KeyId, err)) + } + log.Printf("[ERROR] An error occured creating new AWS KMS Grant: %s", err) + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return err + } + + log.Printf("[DEBUG] Created new KMS Grant: %s", *out.GrantId) + d.SetId(fmt.Sprintf("%s:%s", keyId, *out.GrantId)) + d.Set("grant_id", out.GrantId) + d.Set("grant_token", out.GrantToken) + + return resourceAwsKmsGrantRead(d, meta) +} + +func resourceAwsKmsGrantRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).kmsconn + + keyId, grantId, err := decodeKmsGrantId(d.Id()) + if err != nil { + return err + } + + log.Printf("[DEBUG] Looking for grant id: %s", grantId) + grant, err := findKmsGrantByIdWithRetry(conn, keyId, grantId) + + if err != nil { + return err + } + + if grant == nil { + log.Printf("[WARN] %s KMS grant id not found for key id %s, removing from state file", grantId, keyId) + d.SetId("") + return nil + } + + // The grant sometimes contains principals that identified by their unique id: "AROAJYCVIVUZIMTXXXXX" + // instead of "arn:aws:...", in this case don't update the state file + if strings.HasPrefix(*grant.GranteePrincipal, "arn:aws") { + d.Set("grantee_principal", grant.GranteePrincipal) + } else { + log.Printf( + "[WARN] Unable to update grantee principal state %s for grant id %s for key id %s.", + *grant.GranteePrincipal, grantId, keyId) + } + + if grant.RetiringPrincipal != nil { + if strings.HasPrefix(*grant.RetiringPrincipal, "arn:aws") { + d.Set("retiring_principal", grant.RetiringPrincipal) + } else { + log.Printf( + "[WARN] Unable to update retiring principal state %s for grant id %s for key id %s", + *grant.RetiringPrincipal, grantId, keyId) + } + } + + if err := d.Set("operations", aws.StringValueSlice(grant.Operations)); err != nil { + log.Printf("[DEBUG] Error setting operations for grant %s with error %s", grantId, err) + } + if *grant.Name != "" { + d.Set("name", grant.Name) + } + if grant.Constraints != nil { + if err := d.Set("constraints", flattenKmsGrantConstraints(grant.Constraints)); err != nil { + log.Printf("[DEBUG] Error setting constraints for grant %s with error %s", grantId, err) + } + } + + return nil +} + +func resourceAwsKmsGrantDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).kmsconn + + keyId, grantId, decodeErr := decodeKmsGrantId(d.Id()) + if decodeErr != nil { + return decodeErr + } + doRetire := d.Get("retire_on_delete").(bool) + + var err error + if doRetire { + retireInput := kms.RetireGrantInput{ + GrantId: aws.String(grantId), + KeyId: aws.String(keyId), + } + + log.Printf("[DEBUG] Retiring KMS grant: %s", grantId) + _, err = conn.RetireGrant(&retireInput) + } else { + revokeInput := kms.RevokeGrantInput{ + GrantId: aws.String(grantId), + KeyId: aws.String(keyId), + } + + log.Printf("[DEBUG] Revoking KMS grant: %s", grantId) + _, err = conn.RevokeGrant(&revokeInput) + } + + if err != nil { + if isAWSErr(err, kms.ErrCodeNotFoundException, "") { + return nil + } + return err + } + + log.Printf("[DEBUG] Checking if grant is revoked: %s", grantId) + err = waitForKmsGrantToBeRevoked(conn, keyId, grantId) + + if err != nil { + return err + } + + return nil +} + +func resourceAwsKmsGrantExists(d *schema.ResourceData, meta interface{}) (bool, error) { + conn := meta.(*AWSClient).kmsconn + + keyId, grantId, err := decodeKmsGrantId(d.Id()) + if err != nil { + return false, err + } + + log.Printf("[DEBUG] Looking for Grant: %s", grantId) + grant, err := findKmsGrantByIdWithRetry(conn, keyId, grantId) + + if err != nil { + return true, err + } + if grant != nil { + return true, err + } + + return false, nil +} + +func getKmsGrantById(grants []*kms.GrantListEntry, grantIdentifier string) *kms.GrantListEntry { + for _, grant := range grants { + if *grant.GrantId == grantIdentifier { + return grant + } + } + + return nil +} + +/* +In the functions below it is not possible to use retryOnAwsCodes function, as there +is no describe grants call, so an error has to be created if the grant is or isn't returned +by the list grants call when expected. +*/ + +// NB: This function only retries the grant not being returned and some edge cases, while AWS Errors +// are handled by the findKmsGrantById function +func findKmsGrantByIdWithRetry(conn *kms.KMS, keyId string, grantId string) (*kms.GrantListEntry, error) { + var grant *kms.GrantListEntry + err := resource.Retry(3*time.Minute, func() *resource.RetryError { + var err error + grant, err = findKmsGrantById(conn, keyId, grantId, nil) + + if err != nil { + if serr, ok := err.(KmsGrantMissingError); ok { + // Force a retry if the grant should exist + return resource.RetryableError(serr) + } + + return resource.NonRetryableError(err) + } + + return nil + }) + + return grant, err +} + +// Used by the tests as well +func waitForKmsGrantToBeRevoked(conn *kms.KMS, keyId string, grantId string) error { + err := resource.Retry(3*time.Minute, func() *resource.RetryError { + grant, err := findKmsGrantById(conn, keyId, grantId, nil) + if err != nil { + if _, ok := err.(KmsGrantMissingError); ok { + return nil + } + } + + if grant != nil { + // Force a retry if the grant still exists + return resource.RetryableError( + fmt.Errorf("[DEBUG] Grant still exists while expected to be revoked, retyring revocation check: %s", *grant.GrantId)) + } + + return resource.NonRetryableError(err) + }) + + return err +} + +// The ListGrants API defaults to listing only 50 grants +// Use a marker to iterate over all grants in "pages" +// NB: This function only retries on AWS Errors +func findKmsGrantById(conn *kms.KMS, keyId string, grantId string, marker *string) (*kms.GrantListEntry, error) { + + input := kms.ListGrantsInput{ + KeyId: aws.String(keyId), + Limit: aws.Int64(int64(100)), + Marker: marker, + } + + var out *kms.ListGrantsResponse + var err error + var grant *kms.GrantListEntry + + err = resource.Retry(3*time.Minute, func() *resource.RetryError { + out, err = conn.ListGrants(&input) + + if err != nil { + if isAWSErr(err, kms.ErrCodeDependencyTimeoutException, "") || + isAWSErr(err, kms.ErrCodeInternalException, "") || + isAWSErr(err, kms.ErrCodeInvalidArnException, "") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + + return nil + }) + + grant = getKmsGrantById(out.Grants, grantId) + if grant != nil { + return grant, nil + } + if *out.Truncated { + log.Printf("[DEBUG] KMS Grant list truncated, getting next page via marker: %s", *out.NextMarker) + return findKmsGrantById(conn, keyId, grantId, out.NextMarker) + } + + return nil, NewKmsGrantMissingError(fmt.Sprintf("[DEBUG] Grant %s not found for key id: %s", grantId, keyId)) +} + +// Can't have both constraint options set: +// ValidationException: More than one constraint supplied +// NB: set.List() returns an empty map if the constraint is not set, filter those out +// using len(v) > 0 +func kmsGrantConstraintsIsValid(constraints *schema.Set) bool { + constraintCount := 0 + for _, raw := range constraints.List() { + data := raw.(map[string]interface{}) + if v, ok := data["encryption_context_equals"].(map[string]interface{}); ok { + if len(v) > 0 { + constraintCount += 1 + } + } + if v, ok := data["encryption_context_subset"].(map[string]interface{}); ok { + if len(v) > 0 { + constraintCount += 1 + } + } + } + + if constraintCount > 1 { + return false + } + return true +} + +func expandKmsGrantConstraints(configured *schema.Set) *kms.GrantConstraints { + if len(configured.List()) < 1 { + return nil + } + + var constraint kms.GrantConstraints + + for _, raw := range configured.List() { + data := raw.(map[string]interface{}) + if contextEq, ok := data["encryption_context_equals"]; ok { + constraint.SetEncryptionContextEquals(stringMapToPointers(contextEq.(map[string]interface{}))) + } + if contextSub, ok := data["encryption_context_subset"]; ok { + constraint.SetEncryptionContextSubset(stringMapToPointers(contextSub.(map[string]interface{}))) + } + } + + return &constraint +} + +func sortStringMapKeys(m map[string]*string) []string { + keys := make([]string, 0) + for k := range m { + keys = append(keys, k) + } + sort.Strings(keys) + + return keys +} + +// NB: For the constraint hash to be deterministic the order in which +// print the keys and values of the encryption context maps needs to be +// determistic, so sort them. +func sortedConcatStringMap(m map[string]*string, sep string) string { + var strList []string + mapKeys := sortStringMapKeys(m) + for _, key := range mapKeys { + strList = append(strList, key, *m[key]) + } + return strings.Join(strList, sep) +} + +// The hash needs to encapsulate what type of constraint it is +// as well as the keys and values of the constraint. +func resourceKmsGrantConstraintsHash(v interface{}) int { + var buf bytes.Buffer + m, castOk := v.(map[string]interface{}) + if !castOk { + return 0 + } + + if v, ok := m["encryption_context_equals"]; ok { + if len(v.(map[string]interface{})) > 0 { + buf.WriteString(fmt.Sprintf("encryption_context_equals-%s-", sortedConcatStringMap(stringMapToPointers(v.(map[string]interface{})), "-"))) + } + } + if v, ok := m["encryption_context_subset"]; ok { + if len(v.(map[string]interface{})) > 0 { + buf.WriteString(fmt.Sprintf("encryption_context_subset-%s-", sortedConcatStringMap(stringMapToPointers(v.(map[string]interface{})), "-"))) + } + } + + return hashcode.String(buf.String()) +} + +func flattenKmsGrantConstraints(constraint *kms.GrantConstraints) *schema.Set { + constraints := schema.NewSet(resourceKmsGrantConstraintsHash, []interface{}{}) + if constraint == nil { + return constraints + } + + m := make(map[string]interface{}, 0) + if constraint.EncryptionContextEquals != nil { + if len(constraint.EncryptionContextEquals) > 0 { + m["encryption_context_equals"] = pointersMapToStringList(constraint.EncryptionContextEquals) + } + } + if constraint.EncryptionContextSubset != nil { + if len(constraint.EncryptionContextSubset) > 0 { + m["encryption_context_subset"] = pointersMapToStringList(constraint.EncryptionContextSubset) + } + } + constraints.Add(m) + + return constraints +} + +func decodeKmsGrantId(id string) (string, string, error) { + parts := strings.Split(id, ":") + if len(parts) != 2 { + return "", "", fmt.Errorf("unexpected format of ID (%q), expected KeyID:GrantID", id) + } + return parts[0], parts[1], nil +} + +// Custom error, so we don't have to rely on +// the content of an error message +type KmsGrantMissingError string + +func (e KmsGrantMissingError) Error() string { + return e.Error() +} + +func NewKmsGrantMissingError(msg string) KmsGrantMissingError { + return KmsGrantMissingError(msg) +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kms_key.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kms_key.go index b493de55d04f..d86d1ab676b8 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kms_key.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_kms_key.go @@ -12,6 +12,7 @@ import ( "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" "github.com/hashicorp/terraform/helper/structure" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsKmsKey() *schema.Resource { @@ -45,14 +46,10 @@ func resourceAwsKmsKey() *schema.Resource { Optional: true, Computed: true, ForceNew: true, - ValidateFunc: func(v interface{}, k string) (ws []string, es []error) { - value := v.(string) - if !(value == "ENCRYPT_DECRYPT" || value == "") { - es = append(es, fmt.Errorf( - "%q must be ENCRYPT_DECRYPT or not specified", k)) - } - return - }, + ValidateFunc: validation.StringInSlice([]string{ + "", + kms.KeyUsageTypeEncryptDecrypt, + }, false), }, "policy": { Type: schema.TypeString, @@ -72,16 +69,9 @@ func resourceAwsKmsKey() *schema.Resource { Default: false, }, "deletion_window_in_days": { - Type: schema.TypeInt, - Optional: true, - ValidateFunc: func(v interface{}, k string) (ws []string, es []error) { - value := v.(int) - if value > 30 || value < 7 { - es = append(es, fmt.Errorf( - "%q must be between 7 and 30 days inclusive", k)) - } - return - }, + Type: schema.TypeInt, + Optional: true, + ValidateFunc: validation.IntBetween(7, 30), }, "tags": tagsSchema(), }, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lambda_alias.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lambda_alias.go index 083225f3ad23..eff4d20c8afc 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lambda_alias.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lambda_alias.go @@ -34,6 +34,7 @@ func resourceAwsLambdaAlias() *schema.Resource { "name": &schema.Schema{ Type: schema.TypeString, Required: true, + ForceNew: true, }, "arn": &schema.Schema{ Type: schema.TypeString, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lambda_function.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lambda_function.go index 6050df8d8060..f360dd46c0d0 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lambda_function.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lambda_function.go @@ -7,6 +7,7 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/lambda" "github.com/mitchellh/go-homedir" @@ -97,9 +98,21 @@ func resourceAwsLambdaFunction() *schema.Resource { Required: true, }, "runtime": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateRuntime, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + // lambda.RuntimeNodejs has reached end of life since October 2016 so not included here + lambda.RuntimeDotnetcore10, + lambda.RuntimeDotnetcore20, + lambda.RuntimeGo1X, + lambda.RuntimeJava8, + lambda.RuntimeNodejs43, + lambda.RuntimeNodejs43Edge, + lambda.RuntimeNodejs610, + lambda.RuntimeNodejs810, + lambda.RuntimePython27, + lambda.RuntimePython36, + }, false), }, "timeout": { Type: schema.TypeInt, @@ -349,10 +362,8 @@ func resourceAwsLambdaFunctionCreate(d *schema.ResourceData, meta interface{}) e params.Tags = tagsFromMapGeneric(v.(map[string]interface{})) } - // IAM profiles can take ~10 seconds to propagate in AWS: - // http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/iam-roles-for-amazon-ec2.html#launch-instance-with-role-console - // Error creating Lambda function: InvalidParameterValueException: The role defined for the task cannot be assumed by Lambda. - err := resource.Retry(10*time.Minute, func() *resource.RetryError { + // IAM changes can take 1 minute to propagate in AWS + err := resource.Retry(1*time.Minute, func() *resource.RetryError { _, err := conn.CreateFunction(params) if err != nil { log.Printf("[DEBUG] Error creating Lambda Function: %s", err) @@ -375,9 +386,31 @@ func resourceAwsLambdaFunctionCreate(d *schema.ResourceData, meta interface{}) e return nil }) if err != nil { - return fmt.Errorf("Error creating Lambda function: %s", err) + if !isAWSErr(err, "InvalidParameterValueException", "Your request has been throttled by EC2") { + return fmt.Errorf("Error creating Lambda function: %s", err) + } + // Allow 9 more minutes for EC2 throttling + err := resource.Retry(9*time.Minute, func() *resource.RetryError { + _, err := conn.CreateFunction(params) + if err != nil { + log.Printf("[DEBUG] Error creating Lambda Function: %s", err) + + if isAWSErr(err, "InvalidParameterValueException", "Your request has been throttled by EC2") { + log.Printf("[DEBUG] Received %s, retrying CreateFunction", err) + return resource.RetryableError(err) + } + + return resource.NonRetryableError(err) + } + return nil + }) + if err != nil { + return fmt.Errorf("Error creating Lambda function: %s", err) + } } + d.SetId(d.Get("function_name").(string)) + if reservedConcurrentExecutions > 0 { log.Printf("[DEBUG] Setting Concurrency to %d for the Lambda Function %s", reservedConcurrentExecutions, functionName) @@ -387,14 +420,21 @@ func resourceAwsLambdaFunctionCreate(d *schema.ResourceData, meta interface{}) e ReservedConcurrentExecutions: aws.Int64(int64(reservedConcurrentExecutions)), } - _, err := conn.PutFunctionConcurrency(concurrencyParams) + err := resource.Retry(1*time.Minute, func() *resource.RetryError { + _, err := conn.PutFunctionConcurrency(concurrencyParams) + if err != nil { + if isAWSErr(err, lambda.ErrCodeResourceNotFoundException, "") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) if err != nil { return fmt.Errorf("Error setting concurrency for Lambda %s: %s", functionName, err) } } - d.SetId(d.Get("function_name").(string)) - return resourceAwsLambdaFunctionRead(d, meta) } @@ -489,7 +529,14 @@ func resourceAwsLambdaFunctionRead(d *schema.ResourceData, meta interface{}) err d.Set("version", lastVersion) d.Set("qualified_arn", lastQualifiedArn) - d.Set("invoke_arn", buildLambdaInvokeArn(*function.FunctionArn, meta.(*AWSClient).region)) + invokeArn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "apigateway", + Region: meta.(*AWSClient).region, + AccountID: "lambda", + Resource: fmt.Sprintf("path/2015-03-31/functions/%s/invocations", *function.FunctionArn), + }.String() + d.Set("invoke_arn", invokeArn) if getFunctionOutput.Concurrency != nil { d.Set("reserved_concurrent_executions", getFunctionOutput.Concurrency.ReservedConcurrentExecutions) @@ -591,13 +638,14 @@ func resourceAwsLambdaFunctionUpdate(d *schema.ResourceData, meta interface{}) e } if d.HasChange("dead_letter_config") { dlcMaps := d.Get("dead_letter_config").([]interface{}) + configReq.DeadLetterConfig = &lambda.DeadLetterConfig{ + TargetArn: aws.String(""), + } if len(dlcMaps) == 1 { // Schema guarantees either 0 or 1 dlcMap := dlcMaps[0].(map[string]interface{}) - configReq.DeadLetterConfig = &lambda.DeadLetterConfig{ - TargetArn: aws.String(dlcMap["target_arn"].(string)), - } - configUpdate = true + configReq.DeadLetterConfig.TargetArn = aws.String(dlcMap["target_arn"].(string)) } + configUpdate = true } if d.HasChange("tracing_config") { tracingConfig := d.Get("tracing_config").([]interface{}) @@ -666,11 +714,16 @@ func resourceAwsLambdaFunctionUpdate(d *schema.ResourceData, meta interface{}) e if configUpdate { log.Printf("[DEBUG] Send Update Lambda Function Configuration request: %#v", configReq) - err := resource.Retry(10*time.Minute, func() *resource.RetryError { + // IAM changes can take 1 minute to propagate in AWS + err := resource.Retry(1*time.Minute, func() *resource.RetryError { _, err := conn.UpdateFunctionConfiguration(configReq) if err != nil { log.Printf("[DEBUG] Received error modifying Lambda Function Configuration %s: %s", d.Id(), err) + if isAWSErr(err, "InvalidParameterValueException", "The role defined for the function cannot be assumed by Lambda") { + log.Printf("[DEBUG] Received %s, retrying UpdateFunctionConfiguration", err) + return resource.RetryableError(err) + } if isAWSErr(err, "InvalidParameterValueException", "The provided execution role does not have permissions") { log.Printf("[DEBUG] Received %s, retrying UpdateFunctionConfiguration", err) return resource.RetryableError(err) @@ -684,7 +737,26 @@ func resourceAwsLambdaFunctionUpdate(d *schema.ResourceData, meta interface{}) e return nil }) if err != nil { - return fmt.Errorf("Error modifying Lambda Function Configuration %s: %s", d.Id(), err) + if !isAWSErr(err, "InvalidParameterValueException", "Your request has been throttled by EC2, please make sure you have enough API rate limit.") { + return fmt.Errorf("Error modifying Lambda Function Configuration %s: %s", d.Id(), err) + } + // Allow 9 more minutes for EC2 throttling + err := resource.Retry(9*time.Minute, func() *resource.RetryError { + _, err := conn.UpdateFunctionConfiguration(configReq) + if err != nil { + log.Printf("[DEBUG] Received error modifying Lambda Function Configuration %s: %s", d.Id(), err) + + if isAWSErr(err, "InvalidParameterValueException", "Your request has been throttled by EC2, please make sure you have enough API rate limit.") { + log.Printf("[DEBUG] Received %s, retrying UpdateFunctionConfiguration", err) + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + if err != nil { + return fmt.Errorf("Error modifying Lambda Function Configuration %s: %s", d.Id(), err) + } } d.SetPartial("description") @@ -791,14 +863,3 @@ func readEnvironmentVariables(ev map[string]interface{}) map[string]string { return variables } - -func validateRuntime(v interface{}, k string) (ws []string, errors []error) { - runtime := v.(string) - - if runtime == lambda.RuntimeNodejs { - errors = append(errors, fmt.Errorf( - "%s has reached end of life since October 2016 and has been deprecated in favor of %s.", - runtime, lambda.RuntimeNodejs43)) - } - return -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_launch_configuration.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_launch_configuration.go index a232e6bb3ed5..4ba3436dafbc 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_launch_configuration.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_launch_configuration.go @@ -6,16 +6,15 @@ import ( "encoding/hex" "fmt" "log" - "strings" "time" "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/autoscaling" "github.com/aws/aws-sdk-go/service/ec2" "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsLaunchConfiguration() *schema.Resource { @@ -34,31 +33,14 @@ func resourceAwsLaunchConfiguration() *schema.Resource { Computed: true, ForceNew: true, ConflictsWith: []string{"name_prefix"}, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - // https://github.com/boto/botocore/blob/9f322b1/botocore/data/autoscaling/2011-01-01/service-2.json#L1932-L1939 - value := v.(string) - if len(value) > 255 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 255 characters", k)) - } - return - }, + ValidateFunc: validation.StringLenBetween(1, 255), }, "name_prefix": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - // https://github.com/boto/botocore/blob/9f322b1/botocore/data/autoscaling/2011-01-01/service-2.json#L1932-L1939 - // uuid is 26 characters, limit the prefix to 229. - value := v.(string) - if len(value) > 229 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 229 characters, name is limited to 255", k)) - } - return - }, + Type: schema.TypeString, + Optional: true, + ForceNew: true, + ValidateFunc: validation.StringLenBetween(1, 255-resource.UniqueIDSuffixLength), }, "image_id": { @@ -99,6 +81,7 @@ func resourceAwsLaunchConfiguration() *schema.Resource { return "" } }, + ValidateFunc: validation.StringLenBetween(1, 16384), }, "security_groups": { @@ -175,6 +158,12 @@ func resourceAwsLaunchConfiguration() *schema.Resource { ForceNew: true, }, + "no_device": { + Type: schema.TypeBool, + Optional: true, + ForceNew: true, + }, + "iops": { Type: schema.TypeInt, Optional: true, @@ -355,8 +344,13 @@ func resourceAwsLaunchConfigurationCreate(d *schema.ResourceData, meta interface vL := v.(*schema.Set).List() for _, v := range vL { bd := v.(map[string]interface{}) - ebs := &autoscaling.Ebs{ - DeleteOnTermination: aws.Bool(bd["delete_on_termination"].(bool)), + ebs := &autoscaling.Ebs{} + + var noDevice *bool + if v, ok := bd["no_device"].(bool); ok && v { + noDevice = aws.Bool(v) + } else { + ebs.DeleteOnTermination = aws.Bool(bd["delete_on_termination"].(bool)) } if v, ok := bd["snapshot_id"].(string); ok && v != "" { @@ -386,6 +380,7 @@ func resourceAwsLaunchConfigurationCreate(d *schema.ResourceData, meta interface blockDevices = append(blockDevices, &autoscaling.BlockDeviceMapping{ DeviceName: aws.String(bd["device_name"].(string)), Ebs: ebs, + NoDevice: noDevice, }) } } @@ -451,27 +446,23 @@ func resourceAwsLaunchConfigurationCreate(d *schema.ResourceData, meta interface } createLaunchConfigurationOpts.LaunchConfigurationName = aws.String(lcName) - log.Printf( - "[DEBUG] autoscaling create launch configuration: %s", createLaunchConfigurationOpts) + log.Printf("[DEBUG] autoscaling create launch configuration: %s", createLaunchConfigurationOpts) // IAM profiles can take ~10 seconds to propagate in AWS: // http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/iam-roles-for-amazon-ec2.html#launch-instance-with-role-console err = resource.Retry(90*time.Second, func() *resource.RetryError { _, err := autoscalingconn.CreateLaunchConfiguration(&createLaunchConfigurationOpts) if err != nil { - if awsErr, ok := err.(awserr.Error); ok { - if strings.Contains(awsErr.Message(), "Invalid IamInstanceProfile") { - return resource.RetryableError(err) - } - if strings.Contains(awsErr.Message(), "You are not authorized to perform this operation") { - return resource.RetryableError(err) - } + if isAWSErr(err, "ValidationError", "Invalid IamInstanceProfile") { + return resource.RetryableError(err) + } + if isAWSErr(err, "ValidationError", "You are not authorized to perform this operation") { + return resource.RetryableError(err) } return resource.NonRetryableError(err) } return nil }) - if err != nil { return fmt.Errorf("Error creating launch configuration: %s", err) } @@ -504,6 +495,7 @@ func resourceAwsLaunchConfigurationRead(d *schema.ResourceData, meta interface{} return fmt.Errorf("Error retrieving launch configuration: %s", err) } if len(describConfs.LaunchConfigurations) == 0 { + log.Printf("[WARN] Launch Configuration (%s) not found, removing from state", d.Id()) d.SetId("") return nil } @@ -516,6 +508,7 @@ func resourceAwsLaunchConfigurationRead(d *schema.ResourceData, meta interface{} } lc := describConfs.LaunchConfigurations[0] + log.Printf("[DEBUG] launch configuration output: %s", lc) d.Set("key_name", lc.KeyName) d.Set("image_id", lc.ImageId) @@ -526,11 +519,18 @@ func resourceAwsLaunchConfigurationRead(d *schema.ResourceData, meta interface{} d.Set("ebs_optimized", lc.EbsOptimized) d.Set("spot_price", lc.SpotPrice) d.Set("enable_monitoring", lc.InstanceMonitoring.Enabled) - d.Set("security_groups", lc.SecurityGroups) d.Set("associate_public_ip_address", lc.AssociatePublicIpAddress) + if err := d.Set("security_groups", flattenStringList(lc.SecurityGroups)); err != nil { + return fmt.Errorf("error setting security_groups: %s", err) + } + if aws.StringValue(lc.UserData) != "" { + d.Set("user_data", userDataHashSum(*lc.UserData)) + } d.Set("vpc_classic_link_id", lc.ClassicLinkVPCId) - d.Set("vpc_classic_link_security_groups", lc.ClassicLinkVPCSecurityGroups) + if err := d.Set("vpc_classic_link_security_groups", flattenStringList(lc.ClassicLinkVPCSecurityGroups)); err != nil { + return fmt.Errorf("error setting vpc_classic_link_security_groups: %s", err) + } if err := readLCBlockDevices(d, lc, ec2conn); err != nil { return err @@ -548,8 +548,7 @@ func resourceAwsLaunchConfigurationDelete(d *schema.ResourceData, meta interface LaunchConfigurationName: aws.String(d.Id()), }) if err != nil { - autoscalingerr, ok := err.(awserr.Error) - if ok && (autoscalingerr.Code() == "InvalidConfiguration.NotFound" || autoscalingerr.Code() == "ValidationError") { + if isAWSErr(err, "InvalidConfiguration.NotFound", "") { log.Printf("[DEBUG] Launch configuration (%s) not found", d.Id()) return nil } @@ -601,11 +600,33 @@ func readBlockDevicesFromLaunchConfiguration(d *schema.ResourceData, lc *autosca var blank string rootDeviceName = &blank } + + // Collect existing configured devices, so we can check + // existing value of delete_on_termination below + existingEbsBlockDevices := make(map[string]map[string]interface{}, 0) + if v, ok := d.GetOk("ebs_block_device"); ok { + ebsBlocks := v.(*schema.Set) + for _, ebd := range ebsBlocks.List() { + m := ebd.(map[string]interface{}) + deviceName := m["device_name"].(string) + existingEbsBlockDevices[deviceName] = m + } + } + for _, bdm := range lc.BlockDeviceMappings { bd := make(map[string]interface{}) - if bdm.Ebs != nil && bdm.Ebs.DeleteOnTermination != nil { + + if bdm.NoDevice != nil { + // Keep existing value in place to avoid spurious diff + deleteOnTermination := true + if device, ok := existingEbsBlockDevices[*bdm.DeviceName]; ok { + deleteOnTermination = device["delete_on_termination"].(bool) + } + bd["delete_on_termination"] = deleteOnTermination + } else if bdm.Ebs != nil && bdm.Ebs.DeleteOnTermination != nil { bd["delete_on_termination"] = *bdm.Ebs.DeleteOnTermination } + if bdm.Ebs != nil && bdm.Ebs.VolumeSize != nil { bd["volume_size"] = *bdm.Ebs.VolumeSize } @@ -632,6 +653,9 @@ func readBlockDevicesFromLaunchConfiguration(d *schema.ResourceData, lc *autosca if bdm.Ebs != nil && bdm.Ebs.SnapshotId != nil { bd["snapshot_id"] = *bdm.Ebs.SnapshotId } + if bdm.NoDevice != nil { + bd["no_device"] = *bdm.NoDevice + } blockDevices["ebs"] = append(blockDevices["ebs"].([]map[string]interface{}), bd) } } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb.go index f016ac090013..ea1053d134e4 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb.go @@ -21,7 +21,7 @@ import ( func resourceAwsLb() *schema.Resource { return &schema.Resource{ Create: resourceAwsLbCreate, - Read: resoureAwsLbRead, + Read: resourceAwsLbRead, Update: resourceAwsLbUpdate, Delete: resourceAwsLbDelete, // Subnets are ForceNew for Network Load Balancers @@ -96,6 +96,7 @@ func resourceAwsLb() *schema.Resource { "subnet_mapping": { Type: schema.TypeSet, Optional: true, + Computed: true, ForceNew: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ @@ -121,25 +122,29 @@ func resourceAwsLb() *schema.Resource { }, "access_logs": { - Type: schema.TypeList, - Optional: true, - Computed: true, - MaxItems: 1, + Type: schema.TypeList, + Optional: true, + Computed: true, + MaxItems: 1, + DiffSuppressFunc: suppressIfLBType("network"), Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "bucket": { - Type: schema.TypeString, - Required: true, + Type: schema.TypeString, + Required: true, + DiffSuppressFunc: suppressIfLBType("network"), }, "prefix": { - Type: schema.TypeString, - Optional: true, - Computed: true, + Type: schema.TypeString, + Optional: true, + Computed: true, + DiffSuppressFunc: suppressIfLBType("network"), }, "enabled": { - Type: schema.TypeBool, - Optional: true, - Computed: true, + Type: schema.TypeBool, + Optional: true, + Computed: true, + DiffSuppressFunc: suppressIfLBType("network"), }, }, }, @@ -152,9 +157,24 @@ func resourceAwsLb() *schema.Resource { }, "idle_timeout": { - Type: schema.TypeInt, - Optional: true, - Default: 60, + Type: schema.TypeInt, + Optional: true, + Default: 60, + DiffSuppressFunc: suppressIfLBType("network"), + }, + + "enable_cross_zone_load_balancing": { + Type: schema.TypeBool, + Optional: true, + Default: false, + DiffSuppressFunc: suppressIfLBType("application"), + }, + + "enable_http2": { + Type: schema.TypeBool, + Optional: true, + Default: true, + DiffSuppressFunc: suppressIfLBType("network"), }, "ip_address_type": { @@ -183,6 +203,12 @@ func resourceAwsLb() *schema.Resource { } } +func suppressIfLBType(t string) schema.SchemaDiffSuppressFunc { + return func(k string, old string, new string, d *schema.ResourceData) bool { + return d.Get("load_balancer_type").(string) == t + } +} + func resourceAwsLbCreate(d *schema.ResourceData, meta interface{}) error { elbconn := meta.(*AWSClient).elbv2conn @@ -247,7 +273,7 @@ func resourceAwsLbCreate(d *schema.ResourceData, meta interface{}) error { lb := resp.LoadBalancers[0] d.SetId(*lb.LoadBalancerArn) - log.Printf("[INFO] ALB ID: %s", d.Id()) + log.Printf("[INFO] LB ID: %s", d.Id()) stateConf := &resource.StateChangeConf{ Pending: []string{"provisioning", "failed"}, @@ -265,7 +291,7 @@ func resourceAwsLbCreate(d *schema.ResourceData, meta interface{}) error { } dLb := describeResp.LoadBalancers[0] - log.Printf("[INFO] ALB state: %s", *dLb.State.Code) + log.Printf("[INFO] LB state: %s", *dLb.State.Code) return describeResp, *dLb.State.Code, nil }, @@ -281,7 +307,7 @@ func resourceAwsLbCreate(d *schema.ResourceData, meta interface{}) error { return resourceAwsLbUpdate(d, meta) } -func resoureAwsLbRead(d *schema.ResourceData, meta interface{}) error { +func resourceAwsLbRead(d *schema.ResourceData, meta interface{}) error { elbconn := meta.(*AWSClient).elbv2conn lbArn := d.Id() @@ -318,50 +344,64 @@ func resourceAwsLbUpdate(d *schema.ResourceData, meta interface{}) error { attributes := make([]*elbv2.LoadBalancerAttribute, 0) - if d.HasChange("access_logs") { - logs := d.Get("access_logs").([]interface{}) - if len(logs) == 1 { - log := logs[0].(map[string]interface{}) - - attributes = append(attributes, - &elbv2.LoadBalancerAttribute{ - Key: aws.String("access_logs.s3.enabled"), - Value: aws.String(strconv.FormatBool(log["enabled"].(bool))), - }, - &elbv2.LoadBalancerAttribute{ - Key: aws.String("access_logs.s3.bucket"), - Value: aws.String(log["bucket"].(string)), - }) - - if prefix, ok := log["prefix"]; ok { + switch d.Get("load_balancer_type").(string) { + case "application": + if d.HasChange("access_logs") || d.IsNewResource() { + logs := d.Get("access_logs").([]interface{}) + if len(logs) == 1 { + log := logs[0].(map[string]interface{}) + + attributes = append(attributes, + &elbv2.LoadBalancerAttribute{ + Key: aws.String("access_logs.s3.enabled"), + Value: aws.String(strconv.FormatBool(log["enabled"].(bool))), + }, + &elbv2.LoadBalancerAttribute{ + Key: aws.String("access_logs.s3.bucket"), + Value: aws.String(log["bucket"].(string)), + }) + + if prefix, ok := log["prefix"]; ok { + attributes = append(attributes, &elbv2.LoadBalancerAttribute{ + Key: aws.String("access_logs.s3.prefix"), + Value: aws.String(prefix.(string)), + }) + } + } else if len(logs) == 0 { attributes = append(attributes, &elbv2.LoadBalancerAttribute{ - Key: aws.String("access_logs.s3.prefix"), - Value: aws.String(prefix.(string)), + Key: aws.String("access_logs.s3.enabled"), + Value: aws.String("false"), }) } - } else if len(logs) == 0 { + } + if d.HasChange("idle_timeout") || d.IsNewResource() { + attributes = append(attributes, &elbv2.LoadBalancerAttribute{ + Key: aws.String("idle_timeout.timeout_seconds"), + Value: aws.String(fmt.Sprintf("%d", d.Get("idle_timeout").(int))), + }) + } + if d.HasChange("enable_http2") || d.IsNewResource() { attributes = append(attributes, &elbv2.LoadBalancerAttribute{ - Key: aws.String("access_logs.s3.enabled"), - Value: aws.String("false"), + Key: aws.String("routing.http2.enabled"), + Value: aws.String(strconv.FormatBool(d.Get("enable_http2").(bool))), + }) + } + case "network": + if d.HasChange("enable_cross_zone_load_balancing") || d.IsNewResource() { + attributes = append(attributes, &elbv2.LoadBalancerAttribute{ + Key: aws.String("load_balancing.cross_zone.enabled"), + Value: aws.String(fmt.Sprintf("%t", d.Get("enable_cross_zone_load_balancing").(bool))), }) } } - if d.HasChange("enable_deletion_protection") { + if d.HasChange("enable_deletion_protection") || d.IsNewResource() { attributes = append(attributes, &elbv2.LoadBalancerAttribute{ Key: aws.String("deletion_protection.enabled"), Value: aws.String(fmt.Sprintf("%t", d.Get("enable_deletion_protection").(bool))), }) } - // It's important to know that Idle timeout is not supported for Network Loadbalancers - if d.Get("load_balancer_type").(string) != "network" && d.HasChange("idle_timeout") { - attributes = append(attributes, &elbv2.LoadBalancerAttribute{ - Key: aws.String("idle_timeout.timeout_seconds"), - Value: aws.String(fmt.Sprintf("%d", d.Get("idle_timeout").(int))), - }) - } - if len(attributes) != 0 { input := &elbv2.ModifyLoadBalancerAttributesInput{ LoadBalancerArn: aws.String(d.Id()), @@ -371,7 +411,7 @@ func resourceAwsLbUpdate(d *schema.ResourceData, meta interface{}) error { log.Printf("[DEBUG] ALB Modify Load Balancer Attributes Request: %#v", input) _, err := elbconn.ModifyLoadBalancerAttributes(input) if err != nil { - return fmt.Errorf("Failure configuring ALB attributes: %s", err) + return fmt.Errorf("Failure configuring LB attributes: %s", err) } } @@ -384,7 +424,7 @@ func resourceAwsLbUpdate(d *schema.ResourceData, meta interface{}) error { } _, err := elbconn.SetSecurityGroups(params) if err != nil { - return fmt.Errorf("Failure Setting ALB Security Groups: %s", err) + return fmt.Errorf("Failure Setting LB Security Groups: %s", err) } } @@ -403,7 +443,7 @@ func resourceAwsLbUpdate(d *schema.ResourceData, meta interface{}) error { _, err := elbconn.SetSubnets(params) if err != nil { - return fmt.Errorf("Failure Setting ALB Subnets: %s", err) + return fmt.Errorf("Failure Setting LB Subnets: %s", err) } } @@ -416,7 +456,7 @@ func resourceAwsLbUpdate(d *schema.ResourceData, meta interface{}) error { _, err := elbconn.SetIpAddressType(params) if err != nil { - return fmt.Errorf("Failure Setting ALB IP Address Type: %s", err) + return fmt.Errorf("Failure Setting LB IP Address Type: %s", err) } } @@ -437,7 +477,7 @@ func resourceAwsLbUpdate(d *schema.ResourceData, meta interface{}) error { } dLb := describeResp.LoadBalancers[0] - log.Printf("[INFO] ALB state: %s", *dLb.State.Code) + log.Printf("[INFO] LB state: %s", *dLb.State.Code) return describeResp, *dLb.State.Code, nil }, @@ -450,20 +490,20 @@ func resourceAwsLbUpdate(d *schema.ResourceData, meta interface{}) error { return err } - return resoureAwsLbRead(d, meta) + return resourceAwsLbRead(d, meta) } func resourceAwsLbDelete(d *schema.ResourceData, meta interface{}) error { lbconn := meta.(*AWSClient).elbv2conn - log.Printf("[INFO] Deleting ALB: %s", d.Id()) + log.Printf("[INFO] Deleting LB: %s", d.Id()) // Destroy the load balancer deleteElbOpts := elbv2.DeleteLoadBalancerInput{ LoadBalancerArn: aws.String(d.Id()), } if _, err := lbconn.DeleteLoadBalancer(&deleteElbOpts); err != nil { - return fmt.Errorf("Error deleting ALB: %s", err) + return fmt.Errorf("Error deleting LB: %s", err) } conn := meta.(*AWSClient).ec2conn @@ -538,7 +578,7 @@ func waitForNLBNetworkInterfacesToDetach(conn *ec2.EC2, lbArn string) error { // OperationNotPermitted: You are not allowed to manage 'ela-attach' attachments. // yet presence of these ENIs may prevent us from deleting EIPs associated w/ the NLB - return resource.Retry(1*time.Minute, func() *resource.RetryError { + return resource.Retry(5*time.Minute, func() *resource.RetryError { out, err := conn.DescribeNetworkInterfaces(&ec2.DescribeNetworkInterfacesInput{ Filters: []*ec2.Filter{ { @@ -591,6 +631,23 @@ func flattenSubnetsFromAvailabilityZones(availabilityZones []*elbv2.Availability return result } +func flattenSubnetMappingsFromAvailabilityZones(availabilityZones []*elbv2.AvailabilityZone) []map[string]interface{} { + l := make([]map[string]interface{}, 0) + for _, availabilityZone := range availabilityZones { + for _, loadBalancerAddress := range availabilityZone.LoadBalancerAddresses { + m := make(map[string]interface{}, 0) + m["subnet_id"] = *availabilityZone.SubnetId + + if loadBalancerAddress.AllocationId != nil { + m["allocation_id"] = *loadBalancerAddress.AllocationId + } + + l = append(l, m) + } + } + return l +} + func lbSuffixFromARN(arn *string) string { if arn == nil { return "" @@ -614,35 +671,25 @@ func flattenAwsLbResource(d *schema.ResourceData, meta interface{}, lb *elbv2.Lo d.Set("name", lb.LoadBalancerName) d.Set("internal", (lb.Scheme != nil && *lb.Scheme == "internal")) d.Set("security_groups", flattenStringList(lb.SecurityGroups)) - d.Set("subnets", flattenSubnetsFromAvailabilityZones(lb.AvailabilityZones)) d.Set("vpc_id", lb.VpcId) d.Set("zone_id", lb.CanonicalHostedZoneId) d.Set("dns_name", lb.DNSName) d.Set("ip_address_type", lb.IpAddressType) d.Set("load_balancer_type", lb.Type) - subnetMappings := make([]interface{}, 0) - for _, az := range lb.AvailabilityZones { - subnetMappingRaw := make([]map[string]interface{}, len(az.LoadBalancerAddresses)) - for _, subnet := range az.LoadBalancerAddresses { - subnetMap := make(map[string]interface{}, 0) - subnetMap["subnet_id"] = *az.SubnetId - - if subnet.AllocationId != nil { - subnetMap["allocation_id"] = *subnet.AllocationId - } + if err := d.Set("subnets", flattenSubnetsFromAvailabilityZones(lb.AvailabilityZones)); err != nil { + return fmt.Errorf("error setting subnets: %s", err) + } - subnetMappingRaw = append(subnetMappingRaw, subnetMap) - } - subnetMappings = append(subnetMappings, subnetMappingRaw) + if err := d.Set("subnet_mapping", flattenSubnetMappingsFromAvailabilityZones(lb.AvailabilityZones)); err != nil { + return fmt.Errorf("error setting subnet_mapping: %s", err) } - d.Set("subnet_mapping", subnetMappings) respTags, err := elbconn.DescribeTags(&elbv2.DescribeTagsInput{ ResourceArns: []*string{lb.LoadBalancerArn}, }) if err != nil { - return errwrap.Wrapf("Error retrieving ALB Tags: {{err}}", err) + return errwrap.Wrapf("Error retrieving LB Tags: {{err}}", err) } var et []*elbv2.Tag @@ -658,7 +705,7 @@ func flattenAwsLbResource(d *schema.ResourceData, meta interface{}, lb *elbv2.Lo LoadBalancerArn: aws.String(d.Id()), }) if err != nil { - return errwrap.Wrapf("Error retrieving ALB Attributes: {{err}}", err) + return errwrap.Wrapf("Error retrieving LB Attributes: {{err}}", err) } accessLogMap := map[string]interface{}{} @@ -679,8 +726,16 @@ func flattenAwsLbResource(d *schema.ResourceData, meta interface{}, lb *elbv2.Lo d.Set("idle_timeout", timeout) case "deletion_protection.enabled": protectionEnabled := (*attr.Value) == "true" - log.Printf("[DEBUG] Setting ALB Deletion Protection Enabled: %t", protectionEnabled) + log.Printf("[DEBUG] Setting LB Deletion Protection Enabled: %t", protectionEnabled) d.Set("enable_deletion_protection", protectionEnabled) + case "routing.http2.enabled": + http2Enabled := (*attr.Value) == "true" + log.Printf("[DEBUG] Setting ALB HTTP/2 Enabled: %t", http2Enabled) + d.Set("enable_http2", http2Enabled) + case "load_balancing.cross_zone.enabled": + crossZoneLbEnabled := (*attr.Value) == "true" + log.Printf("[DEBUG] Setting NLB Cross Zone Load Balancing Enabled: %t", crossZoneLbEnabled) + d.Set("enable_cross_zone_load_balancing", crossZoneLbEnabled) } } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb_cookie_stickiness_policy.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb_cookie_stickiness_policy.go index 026f981426fa..1379b175265b 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb_cookie_stickiness_policy.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb_cookie_stickiness_policy.go @@ -9,6 +9,7 @@ import ( "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/elb" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsLBCookieStickinessPolicy() *schema.Resource { @@ -39,17 +40,10 @@ func resourceAwsLBCookieStickinessPolicy() *schema.Resource { }, "cookie_expiration_period": &schema.Schema{ - Type: schema.TypeInt, - Optional: true, - ForceNew: true, - ValidateFunc: func(v interface{}, k string) (ws []string, es []error) { - value := v.(int) - if value <= 0 { - es = append(es, fmt.Errorf( - "LB Cookie Expiration Period must be greater than zero if specified")) - } - return - }, + Type: schema.TypeInt, + Optional: true, + ForceNew: true, + ValidateFunc: validation.IntAtLeast(1), }, }, } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb_listener.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb_listener.go index ec99fa366f44..918d05250b0e 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb_listener.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb_listener.go @@ -8,11 +8,11 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/elbv2" "github.com/hashicorp/errwrap" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsLbListener() *schema.Resource { @@ -40,7 +40,7 @@ func resourceAwsLbListener() *schema.Resource { "port": { Type: schema.TypeInt, Required: true, - ValidateFunc: validateAwsLbListenerPort, + ValidateFunc: validation.IntBetween(1, 65535), }, "protocol": { @@ -50,7 +50,7 @@ func resourceAwsLbListener() *schema.Resource { StateFunc: func(v interface{}) string { return strings.ToUpper(v.(string)) }, - ValidateFunc: validateAwsLbListenerProtocol, + ValidateFunc: validateLbListenerProtocol(), }, "ssl_policy": { @@ -76,7 +76,7 @@ func resourceAwsLbListener() *schema.Resource { "type": { Type: schema.TypeString, Required: true, - ValidateFunc: validateAwsLbListenerActionType, + ValidateFunc: validateLbListenerActionType(), }, }, }, @@ -126,16 +126,12 @@ func resourceAwsLbListenerCreate(d *schema.ResourceData, meta interface{}) error var err error log.Printf("[DEBUG] Creating LB listener for ARN: %s", d.Get("load_balancer_arn").(string)) resp, err = elbconn.CreateListener(params) - if awsErr, ok := err.(awserr.Error); ok { - if awsErr.Code() == "CertificateNotFound" { - log.Printf("[WARN] Got an error while trying to create LB listener for ARN: %s: %s", lbArn, err) + if err != nil { + if isAWSErr(err, elbv2.ErrCodeCertificateNotFoundException, "") { return resource.RetryableError(err) } - } - if err != nil { return resource.NonRetryableError(err) } - return nil }) @@ -159,7 +155,7 @@ func resourceAwsLbListenerRead(d *schema.ResourceData, meta interface{}) error { ListenerArns: []*string{aws.String(d.Id())}, }) if err != nil { - if isListenerNotFound(err) { + if isAWSErr(err, elbv2.ErrCodeListenerNotFoundException, "") { log.Printf("[WARN] DescribeListeners - removing %s from state", d.Id()) d.SetId("") return nil @@ -231,7 +227,16 @@ func resourceAwsLbListenerUpdate(d *schema.ResourceData, meta interface{}) error } } - _, err := elbconn.ModifyListener(params) + err := resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err := elbconn.ModifyListener(params) + if err != nil { + if isAWSErr(err, elbv2.ErrCodeCertificateNotFoundException, "") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) if err != nil { return errwrap.Wrapf("Error modifying LB Listener: {{err}}", err) } @@ -252,33 +257,16 @@ func resourceAwsLbListenerDelete(d *schema.ResourceData, meta interface{}) error return nil } -func validateAwsLbListenerPort(v interface{}, k string) (ws []string, errors []error) { - port := v.(int) - if port < 1 || port > 65536 { - errors = append(errors, fmt.Errorf("%q must be a valid port number (1-65536)", k)) - } - return -} - -func validateAwsLbListenerProtocol(v interface{}, k string) (ws []string, errors []error) { - value := strings.ToLower(v.(string)) - if value == "http" || value == "https" || value == "tcp" { - return - } - - errors = append(errors, fmt.Errorf("%q must be either %q, %q or %q", k, "HTTP", "HTTPS", "TCP")) - return -} - -func validateAwsLbListenerActionType(v interface{}, k string) (ws []string, errors []error) { - value := strings.ToLower(v.(string)) - if value != "forward" { - errors = append(errors, fmt.Errorf("%q must have the value %q", k, "forward")) - } - return +func validateLbListenerActionType() schema.SchemaValidateFunc { + return validation.StringInSlice([]string{ + elbv2.ActionTypeEnumForward, + }, true) } -func isListenerNotFound(err error) bool { - elberr, ok := err.(awserr.Error) - return ok && elberr.Code() == "ListenerNotFound" +func validateLbListenerProtocol() schema.SchemaValidateFunc { + return validation.StringInSlice([]string{ + "http", + "https", + "tcp", + }, true) } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb_listener_rule.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb_listener_rule.go index 578d29e18e76..c32465a64e7d 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb_listener_rule.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb_listener_rule.go @@ -56,7 +56,7 @@ func resourceAwsLbbListenerRule() *schema.Resource { "type": { Type: schema.TypeString, Required: true, - ValidateFunc: validateAwsLbListenerActionType, + ValidateFunc: validateLbListenerActionType(), }, }, }, @@ -69,7 +69,7 @@ func resourceAwsLbbListenerRule() *schema.Resource { "field": { Type: schema.TypeString, Optional: true, - ValidateFunc: validateAwsListenerRuleField, + ValidateFunc: validateMaxLength(64), }, "values": { Type: schema.TypeList, @@ -313,14 +313,6 @@ func validateAwsLbListenerRulePriority(v interface{}, k string) (ws []string, er return } -func validateAwsListenerRuleField(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 64 { - errors = append(errors, fmt.Errorf("%q must be a maximum of 64 characters", k)) - } - return -} - // from arn: // arn:aws:elasticloadbalancing:us-east-1:012345678912:listener-rule/app/name/0123456789abcdef/abcdef0123456789/456789abcedf1234 // select submatches: diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb_target_group.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb_target_group.go index bfda18e3efa1..7222b853300f 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb_target_group.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_lb_target_group.go @@ -14,6 +14,7 @@ import ( "github.com/hashicorp/errwrap" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsLbTargetGroup() *schema.Resource { @@ -46,27 +47,27 @@ func resourceAwsLbTargetGroup() *schema.Resource { Computed: true, ForceNew: true, ConflictsWith: []string{"name_prefix"}, - ValidateFunc: validateAwsLbTargetGroupName, + ValidateFunc: validateMaxLength(32), }, "name_prefix": { Type: schema.TypeString, Optional: true, ForceNew: true, - ValidateFunc: validateAwsLbTargetGroupNamePrefix, + ValidateFunc: validateMaxLength(32 - resource.UniqueIDSuffixLength), }, "port": { Type: schema.TypeInt, Required: true, ForceNew: true, - ValidateFunc: validateAwsLbTargetGroupPort, + ValidateFunc: validation.IntBetween(1, 65535), }, "protocol": { Type: schema.TypeString, Required: true, ForceNew: true, - ValidateFunc: validateAwsLbTargetGroupProtocol, + ValidateFunc: validateLbListenerProtocol(), }, "vpc_id": { @@ -79,7 +80,7 @@ func resourceAwsLbTargetGroup() *schema.Resource { Type: schema.TypeInt, Optional: true, Default: 300, - ValidateFunc: validateAwsLbTargetGroupDeregistrationDelay, + ValidateFunc: validation.IntBetween(0, 3600), }, "target_type": { @@ -102,15 +103,17 @@ func resourceAwsLbTargetGroup() *schema.Resource { Default: true, }, "type": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateAwsLbTargetGroupStickinessType, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + "lb_cookie", + }, false), }, "cookie_duration": { Type: schema.TypeInt, Optional: true, Default: 86400, - ValidateFunc: validateAwsLbTargetGroupStickinessCookieDuration, + ValidateFunc: validation.IntBetween(0, 604800), }, }, }, @@ -150,21 +153,21 @@ func resourceAwsLbTargetGroup() *schema.Resource { StateFunc: func(v interface{}) string { return strings.ToUpper(v.(string)) }, - ValidateFunc: validateAwsLbTargetGroupHealthCheckProtocol, + ValidateFunc: validateLbListenerProtocol(), }, "timeout": { Type: schema.TypeInt, Optional: true, Computed: true, - ValidateFunc: validateAwsLbTargetGroupHealthCheckTimeout, + ValidateFunc: validation.IntBetween(2, 60), }, "healthy_threshold": { Type: schema.TypeInt, Optional: true, Default: 3, - ValidateFunc: validateAwsLbTargetGroupHealthCheckHealthyThreshold, + ValidateFunc: validation.IntBetween(2, 10), }, "matcher": { @@ -177,7 +180,7 @@ func resourceAwsLbTargetGroup() *schema.Resource { Type: schema.TypeInt, Optional: true, Default: 3, - ValidateFunc: validateAwsLbTargetGroupHealthCheckHealthyThreshold, + ValidateFunc: validation.IntBetween(2, 10), }, }, }, @@ -425,74 +428,6 @@ func validateAwsLbTargetGroupHealthCheckPort(v interface{}, k string) (ws []stri return } -func validateAwsLbTargetGroupHealthCheckHealthyThreshold(v interface{}, k string) (ws []string, errors []error) { - value := v.(int) - if value < 2 || value > 10 { - errors = append(errors, fmt.Errorf("%q must be an integer between 2 and 10", k)) - } - return -} - -func validateAwsLbTargetGroupHealthCheckTimeout(v interface{}, k string) (ws []string, errors []error) { - value := v.(int) - if value < 2 || value > 60 { - errors = append(errors, fmt.Errorf("%q must be an integer between 2 and 60", k)) - } - return -} - -func validateAwsLbTargetGroupHealthCheckProtocol(v interface{}, k string) (ws []string, errors []error) { - value := strings.ToLower(v.(string)) - if value == "http" || value == "https" || value == "tcp" { - return - } - - errors = append(errors, fmt.Errorf("%q must be either %q, %q or %q", k, "HTTP", "HTTPS", "TCP")) - return -} - -func validateAwsLbTargetGroupPort(v interface{}, k string) (ws []string, errors []error) { - port := v.(int) - if port < 1 || port > 65536 { - errors = append(errors, fmt.Errorf("%q must be a valid port number (1-65536)", k)) - } - return -} - -func validateAwsLbTargetGroupProtocol(v interface{}, k string) (ws []string, errors []error) { - protocol := strings.ToLower(v.(string)) - if protocol == "http" || protocol == "https" || protocol == "tcp" { - return - } - - errors = append(errors, fmt.Errorf("%q must be either %q, %q or %q", k, "HTTP", "HTTPS", "TCP")) - return -} - -func validateAwsLbTargetGroupDeregistrationDelay(v interface{}, k string) (ws []string, errors []error) { - delay := v.(int) - if delay < 0 || delay > 3600 { - errors = append(errors, fmt.Errorf("%q must be in the range 0-3600 seconds", k)) - } - return -} - -func validateAwsLbTargetGroupStickinessType(v interface{}, k string) (ws []string, errors []error) { - stickinessType := v.(string) - if stickinessType != "lb_cookie" { - errors = append(errors, fmt.Errorf("%q must have the value %q", k, "lb_cookie")) - } - return -} - -func validateAwsLbTargetGroupStickinessCookieDuration(v interface{}, k string) (ws []string, errors []error) { - duration := v.(int) - if duration < 1 || duration > 604800 { - errors = append(errors, fmt.Errorf("%q must be a between 1 second and 1 week (1-604800 seconds))", k)) - } - return -} - func lbTargetGroupSuffixFromARN(arn *string) string { if arn == nil { return "" @@ -530,7 +465,7 @@ func flattenAwsLbTargetGroupResource(d *schema.ResourceData, meta interface{}, t if targetGroup.HealthCheckPath != nil { healthCheck["path"] = *targetGroup.HealthCheckPath } - if targetGroup.Matcher.HttpCode != nil { + if targetGroup.Matcher != nil && targetGroup.Matcher.HttpCode != nil { healthCheck["matcher"] = *targetGroup.Matcher.HttpCode } @@ -651,6 +586,9 @@ func resourceAwsLbTargetGroupCustomizeDiff(diff *schema.ResourceDiff, v interfac // LB and is a first run return fmt.Errorf("%s: custom timeout is not supported for target_groups with TCP protocol", diff.Id()) } + if healthCheck["healthy_threshold"].(int) != healthCheck["unhealthy_threshold"].(int) { + return fmt.Errorf("%s: healthy_threshold %d and unhealthy_threshold %d must be the same for target_groups with TCP protocol", diff.Id(), healthCheck["healthy_threshold"].(int), healthCheck["unhealthy_threshold"].(int)) + } } } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_network_acl.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_network_acl.go index 6080e53c1537..f742841517cc 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_network_acl.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_network_acl.go @@ -308,6 +308,10 @@ func resourceAwsNetworkAclUpdate(d *schema.ResourceData, meta interface{}) error for _, r := range remove { association, err := findNetworkAclAssociation(r.(string), conn) if err != nil { + if isResourceNotFoundError(err) { + // Subnet has been deleted. + continue + } return fmt.Errorf("Failed to find acl association: acl %s with subnet %s: %s", d.Id(), r, err) } log.Printf("DEBUG] Replacing Network Acl Association (%s) with Default Network ACL ID (%s)", *association.NetworkAclAssociationId, *defaultAcl.NetworkAclId) @@ -479,6 +483,9 @@ func resourceAwsNetworkAclDelete(d *schema.ResourceData, meta interface{}) error for _, i := range ids { a, err := findNetworkAclAssociation(i.(string), conn) if err != nil { + if isResourceNotFoundError(err) { + continue + } return resource.NonRetryableError(err) } associations = append(associations, a) @@ -597,26 +604,30 @@ func getDefaultNetworkAcl(vpc_id string, conn *ec2.EC2) (defaultAcl *ec2.Network } func findNetworkAclAssociation(subnetId string, conn *ec2.EC2) (networkAclAssociation *ec2.NetworkAclAssociation, err error) { - resp, err := conn.DescribeNetworkAcls(&ec2.DescribeNetworkAclsInput{ - Filters: []*ec2.Filter{ - { - Name: aws.String("association.subnet-id"), - Values: []*string{aws.String(subnetId)}, - }, + req := &ec2.DescribeNetworkAclsInput{} + req.Filters = buildEC2AttributeFilterList( + map[string]string{ + "association.subnet-id": subnetId, }, - }) - + ) + resp, err := conn.DescribeNetworkAcls(req) if err != nil { return nil, err } - if resp.NetworkAcls != nil && len(resp.NetworkAcls) > 0 { + + if len(resp.NetworkAcls) > 0 { for _, association := range resp.NetworkAcls[0].Associations { - if *association.SubnetId == subnetId { + if aws.StringValue(association.SubnetId) == subnetId { return association, nil } } } - return nil, fmt.Errorf("could not find association for subnet: %s ", subnetId) + + return nil, &resource.NotFoundError{ + LastRequest: req, + LastResponse: resp, + Message: fmt.Sprintf("could not find association for subnet: %s ", subnetId), + } } // networkAclEntriesToMapList turns ingress/egress rules read from AWS into a list diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_network_interface.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_network_interface.go index 5825e0d871b1..ae60963cc58b 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_network_interface.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_network_interface.go @@ -225,7 +225,7 @@ func resourceAwsNetworkInterfaceDetach(oa *schema.Set, meta interface{}, eniId s } } - log.Printf("[DEBUG] Waiting for ENI (%s) to become dettached", eniId) + log.Printf("[DEBUG] Waiting for ENI (%s) to become detached", eniId) stateConf := &resource.StateChangeConf{ Pending: []string{"true"}, Target: []string{"false"}, @@ -234,7 +234,7 @@ func resourceAwsNetworkInterfaceDetach(oa *schema.Set, meta interface{}, eniId s } if _, err := stateConf.WaitForState(); err != nil { return fmt.Errorf( - "Error waiting for ENI (%s) to become dettached: %s", eniId, err) + "Error waiting for ENI (%s) to become detached: %s", eniId, err) } } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_network_interface_attachment.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_network_interface_attachment.go index c37b0d18fedc..684a407f795f 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_network_interface_attachment.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_network_interface_attachment.go @@ -149,7 +149,7 @@ func resourceAwsNetworkInterfaceAttachmentDelete(d *schema.ResourceData, meta in } } - log.Printf("[DEBUG] Waiting for ENI (%s) to become dettached", interfaceId) + log.Printf("[DEBUG] Waiting for ENI (%s) to become detached", interfaceId) stateConf := &resource.StateChangeConf{ Pending: []string{"true"}, Target: []string{"false"}, @@ -159,7 +159,7 @@ func resourceAwsNetworkInterfaceAttachmentDelete(d *schema.ResourceData, meta in if _, err := stateConf.WaitForState(); err != nil { return fmt.Errorf( - "Error waiting for ENI (%s) to become dettached: %s", interfaceId, err) + "Error waiting for ENI (%s) to become detached: %s", interfaceId, err) } return nil diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_opsworks_application.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_opsworks_application.go index 9d3df69cde84..939d2fef4913 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_opsworks_application.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_opsworks_application.go @@ -11,6 +11,7 @@ import ( "github.com/aws/aws-sdk-go/service/opsworks" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsOpsworksApplication() *schema.Resource { @@ -30,27 +31,18 @@ func resourceAwsOpsworksApplication() *schema.Resource { Computed: true, Optional: true, }, - // aws-flow-ruby | java | rails | php | nodejs | static | other "type": { Type: schema.TypeString, Required: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - - expected := [7]string{"aws-flow-ruby", "java", "rails", "php", "nodejs", "static", "other"} - - found := false - for _, b := range expected { - if b == value { - found = true - } - } - if !found { - errors = append(errors, fmt.Errorf( - "%q has to be one of [aws-flow-ruby, java, rails, php, nodejs, static, other]", k)) - } - return - }, + ValidateFunc: validation.StringInSlice([]string{ + opsworks.AppTypeAwsFlowRuby, + opsworks.AppTypeJava, + opsworks.AppTypeRails, + opsworks.AppTypePhp, + opsworks.AppTypeNodejs, + opsworks.AppTypeStatic, + opsworks.AppTypeOther, + }, false), }, "stack_id": { Type: schema.TypeString, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_opsworks_instance.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_opsworks_instance.go index 08770b35985a..e5183e8487e2 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_opsworks_instance.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_opsworks_instance.go @@ -9,6 +9,7 @@ import ( "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awserr" @@ -46,16 +47,22 @@ func resourceAwsOpsworksInstance() *schema.Resource { }, "architecture": { - Type: schema.TypeString, - Optional: true, - Default: "x86_64", - ValidateFunc: validateArchitecture, + Type: schema.TypeString, + Optional: true, + Default: "x86_64", + ValidateFunc: validation.StringInSlice([]string{ + opsworks.ArchitectureX8664, + opsworks.ArchitectureI386, + }, false), }, "auto_scaling_type": { - Type: schema.TypeString, - Optional: true, - ValidateFunc: validateAutoScalingType, + Type: schema.TypeString, + Optional: true, + ValidateFunc: validation.StringInSlice([]string{ + opsworks.AutoScalingTypeLoad, + opsworks.AutoScalingTypeTimer, + }, false), }, "availability_zone": { @@ -92,7 +99,6 @@ func resourceAwsOpsworksInstance() *schema.Resource { "ec2_instance_id": { Type: schema.TypeString, - Optional: true, Computed: true, }, @@ -218,11 +224,14 @@ func resourceAwsOpsworksInstance() *schema.Resource { }, "root_device_type": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, - Computed: true, - ValidateFunc: validateRootDeviceType, + Type: schema.TypeString, + Optional: true, + ForceNew: true, + Computed: true, + ValidateFunc: validation.StringInSlice([]string{ + opsworks.RootDeviceTypeEbs, + opsworks.RootDeviceTypeInstanceStore, + }, false), }, "root_device_volume_id": { @@ -263,9 +272,12 @@ func resourceAwsOpsworksInstance() *schema.Resource { }, "state": { - Type: schema.TypeString, - Optional: true, - ValidateFunc: validateState, + Type: schema.TypeString, + Optional: true, + ValidateFunc: validation.StringInSlice([]string{ + "running", + "stopped", + }, false), }, "status": { @@ -282,19 +294,26 @@ func resourceAwsOpsworksInstance() *schema.Resource { }, "tenancy": { - Type: schema.TypeString, - Optional: true, - Computed: true, - ForceNew: true, - ValidateFunc: validateTenancy, + Type: schema.TypeString, + Optional: true, + Computed: true, + ForceNew: true, + ValidateFunc: validation.StringInSlice([]string{ + "dedicated", + "default", + "host", + }, false), }, "virtualization_type": { - Type: schema.TypeString, - Optional: true, - Computed: true, - ForceNew: true, - ValidateFunc: validateVirtualizationType, + Type: schema.TypeString, + Optional: true, + Computed: true, + ForceNew: true, + ValidateFunc: validation.StringInSlice([]string{ + opsworks.VirtualizationTypeParavirtual, + opsworks.VirtualizationTypeHvm, + }, false), }, "ebs_block_device": { @@ -433,60 +452,6 @@ func resourceAwsOpsworksInstance() *schema.Resource { } } -func validateArchitecture(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != "x86_64" && value != "i386" { - errors = append(errors, fmt.Errorf( - "%q must be one of \"x86_64\" or \"i386\"", k)) - } - return -} - -func validateTenancy(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != "dedicated" && value != "default" && value != "host" { - errors = append(errors, fmt.Errorf( - "%q must be one of \"dedicated\", \"default\" or \"host\"", k)) - } - return -} - -func validateAutoScalingType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != "load" && value != "timer" { - errors = append(errors, fmt.Errorf( - "%q must be one of \"load\" or \"timer\"", k)) - } - return -} - -func validateRootDeviceType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != "ebs" && value != "instance-store" { - errors = append(errors, fmt.Errorf( - "%q must be one of \"ebs\" or \"instance-store\"", k)) - } - return -} - -func validateState(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != "running" && value != "stopped" { - errors = append(errors, fmt.Errorf( - "%q must be one of \"running\" or \"stopped\"", k)) - } - return -} - -func validateVirtualizationType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != "paravirtual" && value != "hvm" { - errors = append(errors, fmt.Errorf( - "%q must be one of \"paravirtual\" or \"hvm\"", k)) - } - return -} - func resourceAwsOpsworksInstanceValidate(d *schema.ResourceData) error { if d.HasChange("ami_id") { if v, ok := d.GetOk("os"); ok { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_opsworks_permission.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_opsworks_permission.go index 13757228d449..99ba4bf542f7 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_opsworks_permission.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_opsworks_permission.go @@ -1,7 +1,6 @@ package aws import ( - "fmt" "log" "time" @@ -10,6 +9,7 @@ import ( "github.com/aws/aws-sdk-go/service/opsworks" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsOpsworksPermission() *schema.Resource { @@ -34,28 +34,17 @@ func resourceAwsOpsworksPermission() *schema.Resource { Type: schema.TypeString, Required: true, }, - // one of deny, show, deploy, manage, iam_only "level": { Type: schema.TypeString, Computed: true, Optional: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - - expected := [5]string{"deny", "show", "deploy", "manage", "iam_only"} - - found := false - for _, b := range expected { - if b == value { - found = true - } - } - if !found { - errors = append(errors, fmt.Errorf( - "%q has to be one of [deny, show, deploy, manage, iam_only]", k)) - } - return - }, + ValidateFunc: validation.StringInSlice([]string{ + "deny", + "show", + "deploy", + "manage", + "iam_only", + }, false), }, "stack_id": { Type: schema.TypeString, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_organizations_account.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_organizations_account.go new file mode 100644 index 000000000000..99bd7dae8fc4 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_organizations_account.go @@ -0,0 +1,243 @@ +package aws + +import ( + "fmt" + "log" + "regexp" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/organizations" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" +) + +func resourceAwsOrganizationsAccount() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsOrganizationsAccountCreate, + Read: resourceAwsOrganizationsAccountRead, + Delete: resourceAwsOrganizationsAccountDelete, + Importer: &schema.ResourceImporter{ + State: schema.ImportStatePassthrough, + }, + + Schema: map[string]*schema.Schema{ + "arn": { + Type: schema.TypeString, + Computed: true, + }, + "joined_method": { + Type: schema.TypeString, + Computed: true, + }, + "joined_timestamp": { + Type: schema.TypeString, + Computed: true, + }, + "status": { + Type: schema.TypeString, + Computed: true, + }, + "name": { + ForceNew: true, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringLenBetween(1, 50), + }, + "email": { + ForceNew: true, + Type: schema.TypeString, + Required: true, + ValidateFunc: validateAwsOrganizationsAccountEmail, + }, + "iam_user_access_to_billing": { + ForceNew: true, + Type: schema.TypeString, + Optional: true, + ValidateFunc: validation.StringInSlice([]string{organizations.IAMUserAccessToBillingAllow, organizations.IAMUserAccessToBillingDeny}, true), + }, + "role_name": { + ForceNew: true, + Type: schema.TypeString, + Optional: true, + ValidateFunc: validateAwsOrganizationsAccountRoleName, + }, + }, + } +} + +func resourceAwsOrganizationsAccountCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).organizationsconn + + // Create the account + createOpts := &organizations.CreateAccountInput{ + AccountName: aws.String(d.Get("name").(string)), + Email: aws.String(d.Get("email").(string)), + } + if role, ok := d.GetOk("role_name"); ok { + createOpts.RoleName = aws.String(role.(string)) + } + + if iam_user, ok := d.GetOk("iam_user_access_to_billing"); ok { + createOpts.IamUserAccessToBilling = aws.String(iam_user.(string)) + } + + log.Printf("[DEBUG] Account create config: %#v", createOpts) + + var err error + var resp *organizations.CreateAccountOutput + err = resource.Retry(4*time.Minute, func() *resource.RetryError { + resp, err = conn.CreateAccount(createOpts) + + if err != nil { + if isAWSErr(err, organizations.ErrCodeFinalizingOrganizationException, "") { + log.Printf("[DEBUG] Trying to create account again: %q", err.Error()) + return resource.RetryableError(err) + } + + return resource.NonRetryableError(err) + } + + return nil + }) + + if err != nil { + return fmt.Errorf("Error creating account: %s", err) + } + log.Printf("[DEBUG] Account create response: %#v", resp) + + requestId := *resp.CreateAccountStatus.Id + + // Wait for the account to become available + log.Printf("[DEBUG] Waiting for account request (%s) to succeed", requestId) + + stateConf := &resource.StateChangeConf{ + Pending: []string{organizations.CreateAccountStateInProgress}, + Target: []string{organizations.CreateAccountStateSucceeded}, + Refresh: resourceAwsOrganizationsAccountStateRefreshFunc(conn, requestId), + PollInterval: 10 * time.Second, + Timeout: 5 * time.Minute, + } + stateResp, stateErr := stateConf.WaitForState() + if stateErr != nil { + return fmt.Errorf( + "Error waiting for account request (%s) to become available: %s", + requestId, stateErr) + } + + // Store the ID + accountId := stateResp.(*organizations.CreateAccountStatus).AccountId + d.SetId(*accountId) + + return resourceAwsOrganizationsAccountRead(d, meta) +} + +func resourceAwsOrganizationsAccountRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).organizationsconn + describeOpts := &organizations.DescribeAccountInput{ + AccountId: aws.String(d.Id()), + } + resp, err := conn.DescribeAccount(describeOpts) + if err != nil { + if isAWSErr(err, organizations.ErrCodeAccountNotFoundException, "") { + log.Printf("[WARN] Account does not exist, removing from state: %s", d.Id()) + d.SetId("") + return nil + } + return err + } + + account := resp.Account + if account == nil { + log.Printf("[WARN] Account does not exist, removing from state: %s", d.Id()) + d.SetId("") + return nil + } + + d.Set("arn", account.Arn) + d.Set("email", account.Email) + d.Set("joined_method", account.JoinedMethod) + d.Set("joined_timestamp", account.JoinedTimestamp) + d.Set("name", account.Name) + d.Set("status", account.Status) + return nil +} + +func resourceAwsOrganizationsAccountDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).organizationsconn + + input := &organizations.RemoveAccountFromOrganizationInput{ + AccountId: aws.String(d.Id()), + } + log.Printf("[DEBUG] Removing AWS account from organization: %s", input) + _, err := conn.RemoveAccountFromOrganization(input) + if err != nil { + if isAWSErr(err, organizations.ErrCodeAccountNotFoundException, "") { + return nil + } + return err + } + return nil +} + +// resourceAwsOrganizationsAccountStateRefreshFunc returns a resource.StateRefreshFunc +// that is used to watch a CreateAccount request +func resourceAwsOrganizationsAccountStateRefreshFunc(conn *organizations.Organizations, id string) resource.StateRefreshFunc { + return func() (interface{}, string, error) { + opts := &organizations.DescribeCreateAccountStatusInput{ + CreateAccountRequestId: aws.String(id), + } + resp, err := conn.DescribeCreateAccountStatus(opts) + if err != nil { + if isAWSErr(err, organizations.ErrCodeCreateAccountStatusNotFoundException, "") { + resp = nil + } else { + log.Printf("Error on OrganizationAccountStateRefresh: %s", err) + return nil, "", err + } + } + + if resp == nil { + // Sometimes AWS just has consistency issues and doesn't see + // our account yet. Return an empty state. + return nil, "", nil + } + + accountStatus := resp.CreateAccountStatus + if *accountStatus.State == organizations.CreateAccountStateFailed { + return nil, *accountStatus.State, fmt.Errorf(*accountStatus.FailureReason) + } + return accountStatus, *accountStatus.State, nil + } +} + +func validateAwsOrganizationsAccountEmail(v interface{}, k string) (ws []string, errors []error) { + value := v.(string) + if !regexp.MustCompile(`^[^\s@]+@[^\s@]+\.[^\s@]+$`).MatchString(value) { + errors = append(errors, fmt.Errorf( + "%q must be a valid email address", value)) + } + + if len(value) < 6 { + errors = append(errors, fmt.Errorf( + "%q cannot be less than 6 characters", value)) + } + + if len(value) > 64 { + errors = append(errors, fmt.Errorf( + "%q cannot be greater than 64 characters", value)) + } + + return +} + +func validateAwsOrganizationsAccountRoleName(v interface{}, k string) (ws []string, errors []error) { + value := v.(string) + if !regexp.MustCompile(`^[\w+=,.@-]{1,64}$`).MatchString(value) { + errors = append(errors, fmt.Errorf( + "%q must consist of uppercase letters, lowercase letters, digits with no spaces, and any of the following characters: =,.@-", value)) + } + + return +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_organizations_organization.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_organizations_organization.go new file mode 100644 index 000000000000..7b4fb8311eec --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_organizations_organization.go @@ -0,0 +1,105 @@ +package aws + +import ( + "fmt" + "log" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/organizations" + "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" +) + +func resourceAwsOrganizationsOrganization() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsOrganizationsOrganizationCreate, + Read: resourceAwsOrganizationsOrganizationRead, + Delete: resourceAwsOrganizationsOrganizationDelete, + Importer: &schema.ResourceImporter{ + State: schema.ImportStatePassthrough, + }, + + Schema: map[string]*schema.Schema{ + "arn": { + Type: schema.TypeString, + Computed: true, + }, + "master_account_arn": { + Type: schema.TypeString, + Computed: true, + }, + "master_account_email": { + Type: schema.TypeString, + Computed: true, + }, + "master_account_id": { + Type: schema.TypeString, + Computed: true, + }, + "feature_set": { + Type: schema.TypeString, + Optional: true, + ForceNew: true, + Default: organizations.OrganizationFeatureSetAll, + ValidateFunc: validation.StringInSlice([]string{ + organizations.OrganizationFeatureSetAll, + organizations.OrganizationFeatureSetConsolidatedBilling, + }, true), + }, + }, + } +} + +func resourceAwsOrganizationsOrganizationCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).organizationsconn + + createOpts := &organizations.CreateOrganizationInput{ + FeatureSet: aws.String(d.Get("feature_set").(string)), + } + log.Printf("[DEBUG] Creating Organization: %#v", createOpts) + + resp, err := conn.CreateOrganization(createOpts) + if err != nil { + return fmt.Errorf("Error creating organization: %s", err) + } + + org := resp.Organization + d.SetId(*org.Id) + + return resourceAwsOrganizationsOrganizationRead(d, meta) +} + +func resourceAwsOrganizationsOrganizationRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).organizationsconn + + log.Printf("[INFO] Reading Organization: %s", d.Id()) + org, err := conn.DescribeOrganization(&organizations.DescribeOrganizationInput{}) + if err != nil { + if isAWSErr(err, organizations.ErrCodeAWSOrganizationsNotInUseException, "") { + log.Printf("[WARN] Organization does not exist, removing from state: %s", d.Id()) + d.SetId("") + return nil + } + return err + } + + d.Set("arn", org.Organization.Arn) + d.Set("feature_set", org.Organization.FeatureSet) + d.Set("master_account_arn", org.Organization.MasterAccountArn) + d.Set("master_account_email", org.Organization.MasterAccountEmail) + d.Set("master_account_id", org.Organization.MasterAccountId) + return nil +} + +func resourceAwsOrganizationsOrganizationDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).organizationsconn + + log.Printf("[INFO] Deleting Organization: %s", d.Id()) + + _, err := conn.DeleteOrganization(&organizations.DeleteOrganizationInput{}) + if err != nil { + return fmt.Errorf("Error deleting Organization: %s", err) + } + + return nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_rds_cluster.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_rds_cluster.go index f76d76452d58..08a9b99ac0b0 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_rds_cluster.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_rds_cluster.go @@ -8,10 +8,12 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/rds" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsRDSCluster() *schema.Resource { @@ -105,7 +107,7 @@ func resourceAwsRDSCluster() *schema.Resource { Optional: true, Default: "aurora", ForceNew: true, - ValidateFunc: validateRdsEngine, + ValidateFunc: validateRdsEngine(), }, "engine_version": { @@ -171,6 +173,7 @@ func resourceAwsRDSCluster() *schema.Resource { Type: schema.TypeInt, Optional: true, Computed: true, + ForceNew: true, }, // apply_immediately is used to determine when the update modifications @@ -211,17 +214,10 @@ func resourceAwsRDSCluster() *schema.Resource { }, "backup_retention_period": { - Type: schema.TypeInt, - Optional: true, - Default: 1, - ValidateFunc: func(v interface{}, k string) (ws []string, es []error) { - value := v.(int) - if value > 35 { - es = append(es, fmt.Errorf( - "backup retention period cannot be more than 35 days")) - } - return - }, + Type: schema.TypeInt, + Optional: true, + Default: 1, + ValidateFunc: validation.IntAtMost(35), }, "kms_key_id": { @@ -466,6 +462,10 @@ func resourceAwsRDSClusterCreate(d *schema.ResourceData, meta interface{}) error createOpts.DBClusterParameterGroupName = aws.String(attr.(string)) } + if attr, ok := d.GetOk("engine_version"); ok { + createOpts.EngineVersion = aws.String(attr.(string)) + } + if attr := d.Get("vpc_security_group_ids").(*schema.Set); attr.Len() > 0 { createOpts.VpcSecurityGroupIds = expandStringList(attr.List()) } @@ -633,13 +633,15 @@ func flattenAwsRdsClusterResource(d *schema.ResourceData, meta interface{}, dbc } // Fetch and save tags - arn, err := buildRDSClusterARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region) - if err != nil { - log.Printf("[DEBUG] Error building ARN for RDS Cluster (%s), not setting Tags", *dbc.DBClusterIdentifier) - } else { - if err := saveTagsRDS(conn, d, arn); err != nil { - log.Printf("[WARN] Failed to save tags for RDS Cluster (%s): %s", *dbc.DBClusterIdentifier, err) - } + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "rds", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("cluster:%s", d.Id()), + }.String() + if err := saveTagsRDS(conn, d, arn); err != nil { + log.Printf("[WARN] Failed to save tags for RDS Cluster (%s): %s", *dbc.DBClusterIdentifier, err) } return nil @@ -740,12 +742,17 @@ func resourceAwsRDSClusterUpdate(d *schema.ResourceData, meta interface{}) error } } - if arn, err := buildRDSClusterARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region); err == nil { - if err := setTagsRDS(conn, d, arn); err != nil { - return err - } else { - d.SetPartial("tags") - } + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "rds", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("cluster:%s", d.Id()), + }.String() + if err := setTagsRDS(conn, d, arn); err != nil { + return err + } else { + d.SetPartial("tags") } return resourceAwsRDSClusterRead(d, meta) @@ -846,19 +853,6 @@ func resourceAwsRDSClusterStateRefreshFunc( } } -func buildRDSClusterARN(identifier, partition, accountid, region string) (string, error) { - if partition == "" { - return "", fmt.Errorf("Unable to construct RDS Cluster ARN because of missing AWS partition") - } - if accountid == "" { - return "", fmt.Errorf("Unable to construct RDS Cluster ARN because of missing AWS Account ID") - } - - arn := fmt.Sprintf("arn:%s:rds:%s:%s:cluster:%s", partition, region, accountid, identifier) - return arn, nil - -} - func setIamRoleToRdsCluster(clusterIdentifier string, roleArn string, conn *rds.RDS) error { params := &rds.AddRoleToDBClusterInput{ DBClusterIdentifier: aws.String(clusterIdentifier), diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_rds_cluster_instance.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_rds_cluster_instance.go index 7c212a7c7eac..b00acf01c5d4 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_rds_cluster_instance.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_rds_cluster_instance.go @@ -7,7 +7,9 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/service/rds" + "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" ) @@ -89,7 +91,7 @@ func resourceAwsRDSClusterInstance() *schema.Resource { Optional: true, ForceNew: true, Default: "aurora", - ValidateFunc: validateRdsEngine, + ValidateFunc: validateRdsEngine(), }, "engine_version": { @@ -307,6 +309,10 @@ func resourceAwsRDSClusterInstanceRead(d *schema.ResourceData, meta interface{}) d.SetId("") return nil } + // Database instance is not in RDS Cluster + if db.DBClusterIdentifier == nil { + return fmt.Errorf("Cluster identifier is missing from instance (%s). The aws_db_instance resource should be used for non-Aurora instances", d.Id()) + } // Retrieve DB Cluster information, to determine if this Instance is a writer conn := meta.(*AWSClient).rdsconn @@ -375,13 +381,15 @@ func resourceAwsRDSClusterInstanceRead(d *schema.ResourceData, meta interface{}) } // Fetch and save tags - arn, err := buildRDSARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region) - if err != nil { - log.Printf("[DEBUG] Error building ARN for RDS Cluster Instance (%s), not setting Tags", *db.DBInstanceIdentifier) - } else { - if err := saveTagsRDS(conn, d, arn); err != nil { - log.Printf("[WARN] Failed to save tags for RDS Cluster Instance (%s): %s", *db.DBClusterIdentifier, err) - } + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "rds", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("db:%s", d.Id()), + }.String() + if err := saveTagsRDS(conn, d, arn); err != nil { + log.Printf("[WARN] Failed to save tags for RDS Cluster Instance (%s): %s", *db.DBClusterIdentifier, err) } return nil @@ -483,10 +491,15 @@ func resourceAwsRDSClusterInstanceUpdate(d *schema.ResourceData, meta interface{ } - if arn, err := buildRDSARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region); err == nil { - if err := setTagsRDS(conn, d, arn); err != nil { - return err - } + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "rds", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("db:%s", d.Id()), + }.String() + if err := setTagsRDS(conn, d, arn); err != nil { + return err } return resourceAwsRDSClusterInstanceRead(d, meta) diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_rds_cluster_parameter_group.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_rds_cluster_parameter_group.go index b81504b06838..e2d7aad801fc 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_rds_cluster_parameter_group.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_rds_cluster_parameter_group.go @@ -6,6 +6,7 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/rds" @@ -165,30 +166,26 @@ func resourceAwsRDSClusterParameterGroupRead(d *schema.ResourceData, meta interf d.Set("parameter", flattenParameters(describeParametersResp.Parameters)) - paramGroup := describeResp.DBClusterParameterGroups[0] - arn, err := buildRDSCPGARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region) + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "rds", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("cluster-pg:%s", d.Id()), + }.String() + d.Set("arn", arn) + resp, err := rdsconn.ListTagsForResource(&rds.ListTagsForResourceInput{ + ResourceName: aws.String(arn), + }) if err != nil { - name := "" - if paramGroup.DBClusterParameterGroupName != nil && *paramGroup.DBClusterParameterGroupName != "" { - name = *paramGroup.DBClusterParameterGroupName - } - log.Printf("[DEBUG] Error building ARN for DB Cluster Parameter Group, not setting Tags for Cluster Param Group %s", name) - } else { - d.Set("arn", arn) - resp, err := rdsconn.ListTagsForResource(&rds.ListTagsForResourceInput{ - ResourceName: aws.String(arn), - }) - - if err != nil { - log.Printf("[DEBUG] Error retrieving tags for ARN: %s", arn) - } + log.Printf("[DEBUG] Error retrieving tags for ARN: %s", arn) + } - var dt []*rds.Tag - if len(resp.TagList) > 0 { - dt = resp.TagList - } - d.Set("tags", tagsToMapRDS(dt)) + var dt []*rds.Tag + if len(resp.TagList) > 0 { + dt = resp.TagList } + d.Set("tags", tagsToMapRDS(dt)) return nil } @@ -242,12 +239,17 @@ func resourceAwsRDSClusterParameterGroupUpdate(d *schema.ResourceData, meta inte } } - if arn, err := buildRDSCPGARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region); err == nil { - if err := setTagsRDS(rdsconn, d, arn); err != nil { - return err - } else { - d.SetPartial("tags") - } + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "rds", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("cluster-pg:%s", d.Id()), + }.String() + if err := setTagsRDS(rdsconn, d, arn); err != nil { + return err + } else { + d.SetPartial("tags") } d.Partial(false) @@ -292,15 +294,3 @@ func resourceAwsRDSClusterParameterGroupDeleteRefreshFunc( return d, "destroyed", nil } } - -func buildRDSCPGARN(identifier, partition, accountid, region string) (string, error) { - if partition == "" { - return "", fmt.Errorf("Unable to construct RDS Cluster ARN because of missing AWS partition") - } - if accountid == "" { - return "", fmt.Errorf("Unable to construct RDS Cluster ARN because of missing AWS Account ID") - } - arn := fmt.Sprintf("arn:%s:rds:%s:%s:cluster-pg:%s", partition, region, accountid, identifier) - return arn, nil - -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_redshift_cluster.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_redshift_cluster.go index b21161ee974a..32a8253ebbc2 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_redshift_cluster.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_redshift_cluster.go @@ -8,9 +8,11 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/service/redshift" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsRedshiftCluster() *schema.Resource { @@ -111,17 +113,10 @@ func resourceAwsRedshiftCluster() *schema.Resource { }, "automated_snapshot_retention_period": { - Type: schema.TypeInt, - Optional: true, - Default: 1, - ValidateFunc: func(v interface{}, k string) (ws []string, es []error) { - value := v.(int) - if value > 35 { - es = append(es, fmt.Errorf( - "backup retention period cannot be more than 35 days")) - } - return - }, + Type: schema.TypeInt, + Optional: true, + Default: 1, + ValidateFunc: validation.IntAtMost(35), }, "port": { @@ -628,15 +623,17 @@ func resourceAwsRedshiftClusterUpdate(d *schema.ResourceData, meta interface{}) conn := meta.(*AWSClient).redshiftconn d.Partial(true) - arn, tagErr := buildRedshiftARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region) - if tagErr != nil { - return fmt.Errorf("Error building ARN for Redshift Cluster, not updating Tags for cluster %s", d.Id()) + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "redshift", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("cluster:%s", d.Id()), + }.String() + if tagErr := setTagsRedshift(conn, d, arn); tagErr != nil { + return tagErr } else { - if tagErr := setTagsRedshift(conn, d, arn); tagErr != nil { - return tagErr - } else { - d.SetPartial("tags") - } + d.SetPartial("tags") } requestUpdate := false @@ -1071,15 +1068,3 @@ func validateRedshiftClusterMasterPassword(v interface{}, k string) (ws []string } return } - -func buildRedshiftARN(identifier, partition, accountid, region string) (string, error) { - if partition == "" { - return "", fmt.Errorf("Unable to construct cluster ARN because of missing AWS partition") - } - if accountid == "" { - return "", fmt.Errorf("Unable to construct cluster ARN because of missing AWS Account ID") - } - arn := fmt.Sprintf("arn:%s:redshift:%s:%s:cluster:%s", partition, region, accountid, identifier) - return arn, nil - -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_redshift_subnet_group.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_redshift_subnet_group.go index 3fe9563940bd..d0c6265e894c 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_redshift_subnet_group.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_redshift_subnet_group.go @@ -6,6 +6,7 @@ import ( "regexp" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/service/redshift" "github.com/hashicorp/terraform/helper/schema" ) @@ -108,13 +109,15 @@ func resourceAwsRedshiftSubnetGroupRead(d *schema.ResourceData, meta interface{} func resourceAwsRedshiftSubnetGroupUpdate(d *schema.ResourceData, meta interface{}) error { conn := meta.(*AWSClient).redshiftconn - arn, tagErr := buildRedshiftSubnetGroupARN(d.Id(), meta.(*AWSClient).partition, meta.(*AWSClient).accountid, meta.(*AWSClient).region) - if tagErr != nil { - return fmt.Errorf("Error building ARN for Redshift Subnet Group, not updating Tags for Subnet Group %s", d.Id()) - } else { - if tagErr := setTagsRedshift(conn, d, arn); tagErr != nil { - return tagErr - } + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "redshift", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("subnetgroup:%s", d.Id()), + }.String() + if tagErr := setTagsRedshift(conn, d, arn); tagErr != nil { + return tagErr } if d.HasChange("subnet_ids") || d.HasChange("description") { @@ -180,15 +183,3 @@ func validateRedshiftSubnetGroupName(v interface{}, k string) (ws []string, erro } return } - -func buildRedshiftSubnetGroupARN(identifier, partition, accountid, region string) (string, error) { - if partition == "" { - return "", fmt.Errorf("Unable to construct Subnet Group ARN because of missing AWS partition") - } - if accountid == "" { - return "", fmt.Errorf("Unable to construct Subnet Group ARN because of missing AWS Account ID") - } - arn := fmt.Sprintf("arn:%s:redshift:%s:%s:subnetgroup:%s", partition, region, accountid, identifier) - return arn, nil - -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_route.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_route.go index 9cabe1f3abc2..dfb126529571 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_route.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_route.go @@ -28,6 +28,11 @@ func resourceAwsRoute() *schema.Resource { Delete: resourceAwsRouteDelete, Exists: resourceAwsRouteExists, + Timeouts: &schema.ResourceTimeout{ + Create: schema.DefaultTimeout(2 * time.Minute), + Delete: schema.DefaultTimeout(5 * time.Minute), + }, + Schema: map[string]*schema.Schema{ "destination_cidr_block": { Type: schema.TypeString, @@ -207,7 +212,7 @@ func resourceAwsRouteCreate(d *schema.ResourceData, meta interface{}) error { // Create the route var err error - err = resource.Retry(2*time.Minute, func() *resource.RetryError { + err = resource.Retry(d.Timeout(schema.TimeoutCreate), func() *resource.RetryError { _, err = conn.CreateRoute(createOpts) if err != nil { @@ -232,7 +237,7 @@ func resourceAwsRouteCreate(d *schema.ResourceData, meta interface{}) error { var route *ec2.Route if v, ok := d.GetOk("destination_cidr_block"); ok { - err = resource.Retry(2*time.Minute, func() *resource.RetryError { + err = resource.Retry(d.Timeout(schema.TimeoutCreate), func() *resource.RetryError { route, err = findResourceRoute(conn, d.Get("route_table_id").(string), v.(string), "") return resource.RetryableError(err) }) @@ -242,7 +247,7 @@ func resourceAwsRouteCreate(d *schema.ResourceData, meta interface{}) error { } if v, ok := d.GetOk("destination_ipv6_cidr_block"); ok { - err = resource.Retry(2*time.Minute, func() *resource.RetryError { + err = resource.Retry(d.Timeout(schema.TimeoutCreate), func() *resource.RetryError { route, err = findResourceRoute(conn, d.Get("route_table_id").(string), "", v.(string)) return resource.RetryableError(err) }) @@ -394,7 +399,7 @@ func resourceAwsRouteDelete(d *schema.ResourceData, meta interface{}) error { log.Printf("[DEBUG] Route delete opts: %s", deleteOpts) var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { + err = resource.Retry(d.Timeout(schema.TimeoutDelete), func() *resource.RetryError { log.Printf("[DEBUG] Trying to delete route with opts %s", deleteOpts) resp, err := conn.DeleteRoute(deleteOpts) log.Printf("[DEBUG] Route delete result: %s", resp) diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_route53_health_check.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_route53_health_check.go index 2850d6392fb0..ce9e8843df7f 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_route53_health_check.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_route53_health_check.go @@ -7,6 +7,7 @@ import ( "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awserr" @@ -84,16 +85,9 @@ func resourceAwsRoute53HealthCheck() *schema.Resource { Set: schema.HashString, }, "child_health_threshold": { - Type: schema.TypeInt, - Optional: true, - ValidateFunc: func(v interface{}, k string) (ws []string, es []error) { - value := v.(int) - if value > 256 { - es = append(es, fmt.Errorf( - "Child HealthThreshold cannot be more than 256")) - } - return - }, + Type: schema.TypeInt, + Optional: true, + ValidateFunc: validation.IntAtMost(256), }, "cloudwatch_alarm_name": { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_route53_record.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_route53_record.go index 322fe3fbe453..b9f507d47a98 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_route53_record.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_route53_record.go @@ -13,6 +13,7 @@ import ( "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awserr" @@ -51,22 +52,29 @@ func resourceAwsRoute53Record() *schema.Resource { }, "type": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateRoute53RecordType, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + route53.RRTypeSoa, + route53.RRTypeA, + route53.RRTypeTxt, + route53.RRTypeNs, + route53.RRTypeCname, + route53.RRTypeMx, + route53.RRTypeNaptr, + route53.RRTypePtr, + route53.RRTypeSrv, + route53.RRTypeSpf, + route53.RRTypeAaaa, + route53.RRTypeCaa, + }, false), }, "zone_id": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - ValidateFunc: func(v interface{}, k string) (ws []string, es []error) { - value := v.(string) - if value == "" { - es = append(es, fmt.Errorf("Cannot have empty zone_id")) - } - return - }, + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validation.NoZeroValues, }, "ttl": { @@ -630,27 +638,35 @@ func findRecord(d *schema.ResourceData, meta interface{}) (*route53.ResourceReco log.Printf("[DEBUG] List resource records sets for zone: %s, opts: %s", zone, lopts) - resp, err := conn.ListResourceRecordSets(lopts) - if err != nil { - return nil, err - } - for _, record := range resp.ResourceRecordSets { - name := cleanRecordName(*record.Name) - if FQDN(strings.ToLower(name)) != FQDN(strings.ToLower(*lopts.StartRecordName)) { - continue - } - if strings.ToUpper(*record.Type) != strings.ToUpper(*lopts.StartRecordType) { - continue - } + var record *route53.ResourceRecordSet + err = conn.ListResourceRecordSetsPages(lopts, func(resp *route53.ListResourceRecordSetsOutput, lastPage bool) bool { + for _, recordSet := range resp.ResourceRecordSets { + name := cleanRecordName(*recordSet.Name) + if FQDN(strings.ToLower(name)) != FQDN(strings.ToLower(*lopts.StartRecordName)) { + continue + } + if strings.ToUpper(*recordSet.Type) != strings.ToUpper(*lopts.StartRecordType) { + continue + } - if record.SetIdentifier != nil && *record.SetIdentifier != d.Get("set_identifier") { - continue + if recordSet.SetIdentifier != nil && *recordSet.SetIdentifier != d.Get("set_identifier") { + continue + } + + record = recordSet + return false } - // The only safe return where a record is found - return record, nil + return !lastPage + }) + + if err != nil { + return nil, err + } + if record == nil { + return nil, r53NoRecordsFound } - return nil, r53NoRecordsFound + return record, nil } func resourceAwsRoute53RecordDelete(d *schema.ResourceData, meta interface{}) error { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_route53_zone.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_route53_zone.go index 0373db6727b6..be92b325ae24 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_route53_zone.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_route53_zone.go @@ -28,9 +28,10 @@ func resourceAwsRoute53Zone() *schema.Resource { Schema: map[string]*schema.Schema{ "name": &schema.Schema{ - Type: schema.TypeString, - Required: true, - ForceNew: true, + Type: schema.TypeString, + Required: true, + ForceNew: true, + DiffSuppressFunc: suppressRoute53ZoneNameWithTrailingDot, }, "comment": &schema.Schema{ diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_s3_bucket.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_s3_bucket.go index a7af215eb467..235c6173fa3b 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_s3_bucket.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_s3_bucket.go @@ -11,6 +11,7 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/s3" "github.com/hashicorp/errwrap" @@ -18,6 +19,7 @@ import ( "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" "github.com/hashicorp/terraform/helper/structure" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsS3Bucket() *schema.Resource { @@ -215,7 +217,7 @@ func resourceAwsS3Bucket() *schema.Resource { Type: schema.TypeString, Optional: true, Computed: true, - ValidateFunc: validateS3BucketLifecycleRuleId, + ValidateFunc: validateMaxLength(255), }, "prefix": { Type: schema.TypeString, @@ -244,7 +246,7 @@ func resourceAwsS3Bucket() *schema.Resource { "days": { Type: schema.TypeInt, Optional: true, - ValidateFunc: validateS3BucketLifecycleExpirationDays, + ValidateFunc: validation.IntAtLeast(1), }, "expired_object_delete_marker": { Type: schema.TypeBool, @@ -262,7 +264,7 @@ func resourceAwsS3Bucket() *schema.Resource { "days": { Type: schema.TypeInt, Optional: true, - ValidateFunc: validateS3BucketLifecycleExpirationDays, + ValidateFunc: validation.IntAtLeast(1), }, }, }, @@ -281,12 +283,12 @@ func resourceAwsS3Bucket() *schema.Resource { "days": { Type: schema.TypeInt, Optional: true, - ValidateFunc: validateS3BucketLifecycleTransitionDays, + ValidateFunc: validation.IntAtLeast(0), }, "storage_class": { Type: schema.TypeString, Required: true, - ValidateFunc: validateS3BucketLifecycleStorageClass, + ValidateFunc: validateS3BucketLifecycleStorageClass(), }, }, }, @@ -300,12 +302,12 @@ func resourceAwsS3Bucket() *schema.Resource { "days": { Type: schema.TypeInt, Optional: true, - ValidateFunc: validateS3BucketLifecycleTransitionDays, + ValidateFunc: validation.IntAtLeast(0), }, "storage_class": { Type: schema.TypeString, Required: true, - ValidateFunc: validateS3BucketLifecycleStorageClass, + ValidateFunc: validateS3BucketLifecycleStorageClass(), }, }, }, @@ -321,17 +323,23 @@ func resourceAwsS3Bucket() *schema.Resource { }, "acceleration_status": { - Type: schema.TypeString, - Optional: true, - Computed: true, - ValidateFunc: validateS3BucketAccelerationStatus, + Type: schema.TypeString, + Optional: true, + Computed: true, + ValidateFunc: validation.StringInSlice([]string{ + s3.BucketAccelerateStatusEnabled, + s3.BucketAccelerateStatusSuspended, + }, false), }, "request_payer": { - Type: schema.TypeString, - Optional: true, - Computed: true, - ValidateFunc: validateS3BucketRequestPayerType, + Type: schema.TypeString, + Optional: true, + Computed: true, + ValidateFunc: validation.StringInSlice([]string{ + s3.PayerRequester, + s3.PayerBucketOwner, + }, false), }, "replication_configuration": { @@ -353,7 +361,7 @@ func resourceAwsS3Bucket() *schema.Resource { "id": { Type: schema.TypeString, Optional: true, - ValidateFunc: validateS3BucketReplicationRuleId, + ValidateFunc: validateMaxLength(255), }, "destination": { Type: schema.TypeSet, @@ -369,9 +377,13 @@ func resourceAwsS3Bucket() *schema.Resource { ValidateFunc: validateArn, }, "storage_class": { - Type: schema.TypeString, - Optional: true, - ValidateFunc: validateS3BucketReplicationDestinationStorageClass, + Type: schema.TypeString, + Optional: true, + ValidateFunc: validation.StringInSlice([]string{ + s3.StorageClassStandard, + s3.StorageClassStandardIa, + s3.StorageClassReducedRedundancy, + }, false), }, "replica_kms_key_id": { Type: schema.TypeString, @@ -409,12 +421,15 @@ func resourceAwsS3Bucket() *schema.Resource { "prefix": { Type: schema.TypeString, Required: true, - ValidateFunc: validateS3BucketReplicationRulePrefix, + ValidateFunc: validateMaxLength(1024), }, "status": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateS3BucketReplicationRuleStatus, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + s3.ReplicationRuleStatusEnabled, + s3.ReplicationRuleStatusDisabled, + }, false), }, }, }, @@ -446,9 +461,12 @@ func resourceAwsS3Bucket() *schema.Resource { Optional: true, }, "sse_algorithm": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateS3BucketServerSideEncryptionAlgorithm, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + s3.ServerSideEncryptionAes256, + s3.ServerSideEncryptionAwsKms, + }, false), }, }, }, @@ -1091,7 +1109,12 @@ func resourceAwsS3BucketRead(d *schema.ResourceData, meta interface{}) error { return err } - d.Set("arn", fmt.Sprintf("arn:%s:s3:::%s", meta.(*AWSClient).partition, d.Id())) + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "s3", + Resource: d.Id(), + }.String() + d.Set("arn", arn) return nil } @@ -2055,28 +2078,6 @@ func normalizeRegion(region string) string { return region } -func validateS3BucketAccelerationStatus(v interface{}, k string) (ws []string, errors []error) { - validTypes := map[string]struct{}{ - "Enabled": struct{}{}, - "Suspended": struct{}{}, - } - - if _, ok := validTypes[v.(string)]; !ok { - errors = append(errors, fmt.Errorf("S3 Bucket Acceleration Status %q is invalid, must be %q or %q", v.(string), "Enabled", "Suspended")) - } - return -} - -func validateS3BucketRequestPayerType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != s3.PayerRequester && value != s3.PayerBucketOwner { - errors = append(errors, fmt.Errorf( - "%q contains an invalid Request Payer type %q. Valid types are either %q or %q", - k, value, s3.PayerRequester, s3.PayerBucketOwner)) - } - return -} - // validateS3BucketName validates any S3 bucket name that is not inside the us-east-1 region. // Buckets outside of this region have to be DNS-compliant. After the same restrictions are // applied to buckets in the us-east-1 region, this function can be refactored as a SchemaValidateFunc diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_s3_bucket_object.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_s3_bucket_object.go index 516fdd37577d..f9165eafde6a 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_s3_bucket_object.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_s3_bucket_object.go @@ -2,15 +2,16 @@ package aws import ( "bytes" + "encoding/base64" "fmt" "io" "log" "net/url" "os" - "sort" "strings" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" "github.com/mitchellh/go-homedir" "github.com/aws/aws-sdk-go/aws" @@ -34,10 +35,18 @@ func resourceAwsS3BucketObject() *schema.Resource { }, "acl": { - Type: schema.TypeString, - Default: "private", - Optional: true, - ValidateFunc: validateS3BucketObjectAclType, + Type: schema.TypeString, + Default: "private", + Optional: true, + ValidateFunc: validation.StringInSlice([]string{ + s3.ObjectCannedACLPrivate, + s3.ObjectCannedACLPublicRead, + s3.ObjectCannedACLPublicReadWrite, + s3.ObjectCannedACLAuthenticatedRead, + s3.ObjectCannedACLAwsExecRead, + s3.ObjectCannedACLBucketOwnerRead, + s3.ObjectCannedACLBucketOwnerFullControl, + }, false), }, "cache_control": { @@ -75,27 +84,40 @@ func resourceAwsS3BucketObject() *schema.Resource { "source": { Type: schema.TypeString, Optional: true, - ConflictsWith: []string{"content"}, + ConflictsWith: []string{"content", "content_base64"}, }, "content": { Type: schema.TypeString, Optional: true, - ConflictsWith: []string{"source"}, + ConflictsWith: []string{"source", "content_base64"}, + }, + + "content_base64": { + Type: schema.TypeString, + Optional: true, + ConflictsWith: []string{"source", "content"}, }, "storage_class": { - Type: schema.TypeString, - Optional: true, - Computed: true, - ValidateFunc: validateS3BucketObjectStorageClassType, + Type: schema.TypeString, + Optional: true, + Computed: true, + ValidateFunc: validation.StringInSlice([]string{ + s3.StorageClassStandard, + s3.StorageClassReducedRedundancy, + s3.StorageClassStandardIa, + }, false), }, "server_side_encryption": { - Type: schema.TypeString, - Optional: true, - ValidateFunc: validateS3BucketObjectServerSideEncryption, - Computed: true, + Type: schema.TypeString, + Optional: true, + ValidateFunc: validation.StringInSlice([]string{ + s3.ServerSideEncryptionAes256, + s3.ServerSideEncryptionAwsKms, + }, false), + Computed: true, }, "kms_key_id": { @@ -151,8 +173,17 @@ func resourceAwsS3BucketObjectPut(d *schema.ResourceData, meta interface{}) erro } else if v, ok := d.GetOk("content"); ok { content := v.(string) body = bytes.NewReader([]byte(content)) + } else if v, ok := d.GetOk("content_base64"); ok { + content := v.(string) + // We can't do streaming decoding here (with base64.NewDecoder) because + // the AWS SDK requires an io.ReadSeeker but a base64 decoder can't seek. + contentRaw, err := base64.StdEncoding.DecodeString(content) + if err != nil { + return fmt.Errorf("error decoding content_base64: %s", err) + } + body = bytes.NewReader(contentRaw) } else { - return fmt.Errorf("Must specify \"source\" or \"content\" field") + return fmt.Errorf("Must specify \"source\", \"content\", or \"content_base64\" field") } bucket := d.Get("bucket").(string) @@ -345,73 +376,3 @@ func resourceAwsS3BucketObjectDelete(d *schema.ResourceData, meta interface{}) e return nil } - -func validateS3BucketObjectAclType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - - cannedAcls := map[string]bool{ - s3.ObjectCannedACLPrivate: true, - s3.ObjectCannedACLPublicRead: true, - s3.ObjectCannedACLPublicReadWrite: true, - s3.ObjectCannedACLAuthenticatedRead: true, - s3.ObjectCannedACLAwsExecRead: true, - s3.ObjectCannedACLBucketOwnerRead: true, - s3.ObjectCannedACLBucketOwnerFullControl: true, - } - - sentenceJoin := func(m map[string]bool) string { - keys := make([]string, 0, len(m)) - for k := range m { - keys = append(keys, fmt.Sprintf("%q", k)) - } - sort.Strings(keys) - - length := len(keys) - words := make([]string, length) - copy(words, keys) - - words[length-1] = fmt.Sprintf("or %s", words[length-1]) - return strings.Join(words, ", ") - } - - if _, ok := cannedAcls[value]; !ok { - errors = append(errors, fmt.Errorf( - "%q contains an invalid canned ACL type %q. Valid types are either %s", - k, value, sentenceJoin(cannedAcls))) - } - return -} - -func validateS3BucketObjectStorageClassType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - - storageClass := map[string]bool{ - s3.StorageClassStandard: true, - s3.StorageClassReducedRedundancy: true, - s3.StorageClassStandardIa: true, - } - - if _, ok := storageClass[value]; !ok { - errors = append(errors, fmt.Errorf( - "%q contains an invalid Storage Class type %q. Valid types are either %q, %q, or %q", - k, value, s3.StorageClassStandard, s3.StorageClassReducedRedundancy, - s3.StorageClassStandardIa)) - } - return -} - -func validateS3BucketObjectServerSideEncryption(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - - serverSideEncryption := map[string]bool{ - s3.ServerSideEncryptionAes256: true, - s3.ServerSideEncryptionAwsKms: true, - } - - if _, ok := serverSideEncryption[value]; !ok { - errors = append(errors, fmt.Errorf( - "%q contains an invalid Server Side Encryption value %q. Valid values are %q and %q", - k, value, s3.ServerSideEncryptionAes256, s3.ServerSideEncryptionAwsKms)) - } - return -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_security_group.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_security_group.go index 9c8426e39ca9..70fe956045de 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_security_group.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_security_group.go @@ -10,6 +10,7 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/ec2" "github.com/hashicorp/terraform/helper/hashcode" @@ -27,6 +28,11 @@ func resourceAwsSecurityGroup() *schema.Resource { State: resourceAwsSecurityGroupImportState, }, + Timeouts: &schema.ResourceTimeout{ + Create: schema.DefaultTimeout(10 * time.Minute), + Delete: schema.DefaultTimeout(10 * time.Minute), + }, + SchemaVersion: 1, MigrateState: resourceAwsSecurityGroupMigrateState, @@ -37,43 +43,22 @@ func resourceAwsSecurityGroup() *schema.Resource { Computed: true, ForceNew: true, ConflictsWith: []string{"name_prefix"}, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 255 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 255 characters", k)) - } - return - }, + ValidateFunc: validateMaxLength(255), }, "name_prefix": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 100 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 100 characters, name is limited to 255", k)) - } - return - }, + Type: schema.TypeString, + Optional: true, + ForceNew: true, + ValidateFunc: validateMaxLength(100), }, "description": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, - Default: "Managed by Terraform", - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 255 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 255 characters", k)) - } - return - }, + Type: schema.TypeString, + Optional: true, + ForceNew: true, + Default: "Managed by Terraform", + ValidateFunc: validateMaxLength(255), }, "vpc_id": { @@ -215,6 +200,11 @@ func resourceAwsSecurityGroup() *schema.Resource { Set: resourceAwsSecurityGroupRuleHash, }, + "arn": { + Type: schema.TypeString, + Computed: true, + }, + "owner_id": { Type: schema.TypeString, Computed: true, @@ -267,17 +257,7 @@ func resourceAwsSecurityGroupCreate(d *schema.ResourceData, meta interface{}) er log.Printf("[INFO] Security Group ID: %s", d.Id()) // Wait for the security group to truly exist - log.Printf( - "[DEBUG] Waiting for Security Group (%s) to exist", - d.Id()) - stateConf := &resource.StateChangeConf{ - Pending: []string{""}, - Target: []string{"exists"}, - Refresh: SGStateRefreshFunc(conn, d.Id()), - Timeout: 10 * time.Minute, - } - - resp, err := stateConf.WaitForState() + resp, err := waitForSgToExist(conn, d.Id(), d.Timeout(schema.TimeoutCreate)) if err != nil { return fmt.Errorf( "Error waiting for Security Group (%s) to become available: %s", @@ -352,11 +332,20 @@ func resourceAwsSecurityGroupCreate(d *schema.ResourceData, meta interface{}) er func resourceAwsSecurityGroupRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*AWSClient).ec2conn - sgRaw, _, err := SGStateRefreshFunc(conn, d.Id())() + var sgRaw interface{} + var err error + if d.IsNewResource() { + sgRaw, err = waitForSgToExist(conn, d.Id(), d.Timeout(schema.TimeoutRead)) + } else { + sgRaw, _, err = SGStateRefreshFunc(conn, d.Id())() + } + if err != nil { return err } + if sgRaw == nil { + log.Printf("[WARN] Security group (%s) not found, removing from state", d.Id()) d.SetId("") return nil } @@ -374,6 +363,15 @@ func resourceAwsSecurityGroupRead(d *schema.ResourceData, meta interface{}) erro ingressRules := matchRules("ingress", localIngressRules, remoteIngressRules) egressRules := matchRules("egress", localEgressRules, remoteEgressRules) + sgArn := arn.ARN{ + AccountID: aws.StringValue(sg.OwnerId), + Partition: meta.(*AWSClient).partition, + Region: meta.(*AWSClient).region, + Resource: fmt.Sprintf("security-group/%s", aws.StringValue(sg.GroupId)), + Service: ec2.ServiceName, + } + + d.Set("arn", sgArn.String()) d.Set("description", sg.Description) d.Set("name", sg.GroupName) d.Set("vpc_id", sg.VpcId) @@ -394,11 +392,19 @@ func resourceAwsSecurityGroupRead(d *schema.ResourceData, meta interface{}) erro func resourceAwsSecurityGroupUpdate(d *schema.ResourceData, meta interface{}) error { conn := meta.(*AWSClient).ec2conn - sgRaw, _, err := SGStateRefreshFunc(conn, d.Id())() + var sgRaw interface{} + var err error + if d.IsNewResource() { + sgRaw, err = waitForSgToExist(conn, d.Id(), d.Timeout(schema.TimeoutRead)) + } else { + sgRaw, _, err = SGStateRefreshFunc(conn, d.Id())() + } + if err != nil { return err } if sgRaw == nil { + log.Printf("[WARN] Security group (%s) not found, removing from state", d.Id()) d.SetId("") return nil } @@ -443,7 +449,7 @@ func resourceAwsSecurityGroupDelete(d *schema.ResourceData, meta interface{}) er } } - return resource.Retry(5*time.Minute, func() *resource.RetryError { + return resource.Retry(d.Timeout(schema.TimeoutDelete), func() *resource.RetryError { _, err := conn.DeleteSecurityGroup(&ec2.DeleteSecurityGroupInput{ GroupId: aws.String(d.Id()), }) @@ -841,6 +847,18 @@ func SGStateRefreshFunc(conn *ec2.EC2, id string) resource.StateRefreshFunc { } } +func waitForSgToExist(conn *ec2.EC2, id string, timeout time.Duration) (interface{}, error) { + log.Printf("[DEBUG] Waiting for Security Group (%s) to exist", id) + stateConf := &resource.StateChangeConf{ + Pending: []string{""}, + Target: []string{"exists"}, + Refresh: SGStateRefreshFunc(conn, id), + Timeout: timeout, + } + + return stateConf.WaitForState() +} + // matchRules receives the group id, type of rules, and the local / remote maps // of rules. We iterate through the local set of rules trying to find a matching // remote rule, which may be structured differently because of how AWS @@ -1281,7 +1299,7 @@ func deleteLingeringLambdaENIs(conn *ec2.EC2, d *schema.ResourceData) error { Pending: []string{"true"}, Target: []string{"false"}, Refresh: networkInterfaceAttachedRefreshFunc(conn, *eni.NetworkInterfaceId), - Timeout: 10 * time.Minute, + Timeout: d.Timeout(schema.TimeoutDelete), } if _, err := stateConf.WaitForState(); err != nil { return fmt.Errorf( diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_security_group_rule.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_security_group_rule.go index 3bc4bd9a78c5..5ab3044c0eb7 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_security_group_rule.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_security_group_rule.go @@ -15,6 +15,7 @@ import ( "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsSecurityGroupRule() *schema.Resource { @@ -29,11 +30,14 @@ func resourceAwsSecurityGroupRule() *schema.Resource { Schema: map[string]*schema.Schema{ "type": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - Description: "Type of rule, ingress (inbound) or egress (outbound).", - ValidateFunc: validateSecurityRuleType, + Type: schema.TypeString, + Required: true, + ForceNew: true, + Description: "Type of rule, ingress (inbound) or egress (outbound).", + ValidateFunc: validation.StringInSlice([]string{ + "ingress", + "egress", + }, false), }, "from_port": { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_servicecatalog_portfolio.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_servicecatalog_portfolio.go index 6d87d4a42ead..161550ccc4a3 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_servicecatalog_portfolio.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_servicecatalog_portfolio.go @@ -9,6 +9,7 @@ import ( "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/servicecatalog" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsServiceCatalogPortfolio() *schema.Resource { @@ -40,18 +41,18 @@ func resourceAwsServiceCatalogPortfolio() *schema.Resource { "name": { Type: schema.TypeString, Required: true, - ValidateFunc: validateServiceCatalogPortfolioName, + ValidateFunc: validation.StringLenBetween(1, 20), }, "description": { Type: schema.TypeString, Optional: true, Computed: true, - ValidateFunc: validateServiceCatalogPortfolioDescription, + ValidateFunc: validateMaxLength(2000), }, "provider_name": { Type: schema.TypeString, Optional: true, - ValidateFunc: validateServiceCatalogPortfolioProviderName, + ValidateFunc: validation.StringLenBetween(1, 20), }, "tags": tagsSchema(), }, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ses_domain_identity.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ses_domain_identity.go index 734030cc71a4..84579dd3adf6 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ses_domain_identity.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ses_domain_identity.go @@ -3,8 +3,10 @@ package aws import ( "fmt" "log" + "strings" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/service/ses" "github.com/hashicorp/terraform/helper/schema" ) @@ -27,6 +29,9 @@ func resourceAwsSesDomainIdentity() *schema.Resource { Type: schema.TypeString, Required: true, ForceNew: true, + StateFunc: func(v interface{}) string { + return strings.TrimSuffix(v.(string), ".") + }, }, "verification_token": { Type: schema.TypeString, @@ -40,6 +45,7 @@ func resourceAwsSesDomainIdentityCreate(d *schema.ResourceData, meta interface{} conn := meta.(*AWSClient).sesConn domainName := d.Get("domain").(string) + domainName = strings.TrimSuffix(domainName, ".") createOpts := &ses.VerifyDomainIdentityInput{ Domain: aws.String(domainName), @@ -80,7 +86,14 @@ func resourceAwsSesDomainIdentityRead(d *schema.ResourceData, meta interface{}) return nil } - d.Set("arn", fmt.Sprintf("arn:%s:ses:%s:%s:identity/%s", meta.(*AWSClient).partition, meta.(*AWSClient).region, meta.(*AWSClient).accountid, d.Id())) + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "ses", + Region: meta.(*AWSClient).region, + AccountID: meta.(*AWSClient).accountid, + Resource: fmt.Sprintf("identity/%s", d.Id()), + }.String() + d.Set("arn", arn) d.Set("verification_token", verificationAttrs.VerificationToken) return nil } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ses_event_destination.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ses_event_destination.go index b8ea3f225157..5317fa2230e4 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ses_event_destination.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ses_event_destination.go @@ -7,6 +7,7 @@ import ( "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/service/ses" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsSesEventDestination() *schema.Resource { @@ -44,8 +45,17 @@ func resourceAwsSesEventDestination() *schema.Resource { ForceNew: true, Set: schema.HashString, Elem: &schema.Schema{ - Type: schema.TypeString, - ValidateFunc: validateMatchingTypes, + Type: schema.TypeString, + ValidateFunc: validation.StringInSlice([]string{ + ses.EventTypeSend, + ses.EventTypeReject, + ses.EventTypeBounce, + ses.EventTypeComplaint, + ses.EventTypeDelivery, + ses.EventTypeOpen, + ses.EventTypeClick, + ses.EventTypeRenderingFailure, + }, false), }, }, @@ -68,9 +78,13 @@ func resourceAwsSesEventDestination() *schema.Resource { }, "value_source": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateDimensionValueSource, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + ses.DimensionValueSourceMessageTag, + ses.DimensionValueSourceEmailHeader, + ses.DimensionValueSourceLinkTag, + }, false), }, }, }, @@ -193,37 +207,6 @@ func resourceAwsSesEventDestinationDelete(d *schema.ResourceData, meta interface return nil } -func validateMatchingTypes(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - matchingTypes := map[string]bool{ - "send": true, - "reject": true, - "bounce": true, - "complaint": true, - "delivery": true, - "open": true, - "click": true, - } - - if !matchingTypes[value] { - errors = append(errors, fmt.Errorf("%q must be a valid matching event type value: %q", k, value)) - } - return -} - -func validateDimensionValueSource(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - matchingSource := map[string]bool{ - "messageTag": true, - "emailHeader": true, - } - - if !matchingSource[value] { - errors = append(errors, fmt.Errorf("%q must be a valid dimension value: %q", k, value)) - } - return -} - func generateCloudWatchDestination(v []interface{}) []*ses.CloudWatchDimensionConfiguration { b := make([]*ses.CloudWatchDimensionConfiguration, len(v)) diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ses_identity_notification_topic.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ses_identity_notification_topic.go new file mode 100644 index 000000000000..ac2f1c53a847 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ses_identity_notification_topic.go @@ -0,0 +1,136 @@ +package aws + +import ( + "fmt" + "log" + "strings" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/ses" + "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" +) + +func resourceAwsSesNotificationTopic() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsSesNotificationTopicSet, + Read: resourceAwsSesNotificationTopicRead, + Update: resourceAwsSesNotificationTopicSet, + Delete: resourceAwsSesNotificationTopicDelete, + + Schema: map[string]*schema.Schema{ + "topic_arn": { + Type: schema.TypeString, + Optional: true, + ValidateFunc: validateArn, + }, + + "notification_type": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validation.StringInSlice([]string{ + ses.NotificationTypeBounce, + ses.NotificationTypeComplaint, + ses.NotificationTypeDelivery, + }, false), + }, + + "identity": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validation.NoZeroValues, + }, + }, + } +} + +func resourceAwsSesNotificationTopicSet(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).sesConn + notification := d.Get("notification_type").(string) + identity := d.Get("identity").(string) + + setOpts := &ses.SetIdentityNotificationTopicInput{ + Identity: aws.String(identity), + NotificationType: aws.String(notification), + } + + if v, ok := d.GetOk("topic_arn"); ok && v.(string) != "" { + setOpts.SnsTopic = aws.String(v.(string)) + } + + d.SetId(fmt.Sprintf("%s|%s", identity, notification)) + + log.Printf("[DEBUG] Setting SES Identity Notification Topic: %#v", setOpts) + + if _, err := conn.SetIdentityNotificationTopic(setOpts); err != nil { + return fmt.Errorf("Error setting SES Identity Notification Topic: %s", err) + } + + return resourceAwsSesNotificationTopicRead(d, meta) +} + +func resourceAwsSesNotificationTopicRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).sesConn + + identity, notificationType, err := decodeSesIdentityNotificationTopicId(d.Id()) + if err != nil { + return err + } + + getOpts := &ses.GetIdentityNotificationAttributesInput{ + Identities: []*string{aws.String(identity)}, + } + + log.Printf("[DEBUG] Reading SES Identity Notification Topic Attributes: %#v", getOpts) + + response, err := conn.GetIdentityNotificationAttributes(getOpts) + + if err != nil { + return fmt.Errorf("Error reading SES Identity Notification Topic: %s", err) + } + + notificationAttributes := response.NotificationAttributes[identity] + switch notificationType { + case ses.NotificationTypeBounce: + d.Set("topic_arn", notificationAttributes.BounceTopic) + case ses.NotificationTypeComplaint: + d.Set("topic_arn", notificationAttributes.ComplaintTopic) + case ses.NotificationTypeDelivery: + d.Set("topic_arn", notificationAttributes.DeliveryTopic) + } + + return nil +} + +func resourceAwsSesNotificationTopicDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).sesConn + + identity, notificationType, err := decodeSesIdentityNotificationTopicId(d.Id()) + if err != nil { + return err + } + + setOpts := &ses.SetIdentityNotificationTopicInput{ + Identity: aws.String(identity), + NotificationType: aws.String(notificationType), + SnsTopic: nil, + } + + log.Printf("[DEBUG] Deleting SES Identity Notification Topic: %#v", setOpts) + + if _, err := conn.SetIdentityNotificationTopic(setOpts); err != nil { + return fmt.Errorf("Error deleting SES Identity Notification Topic: %s", err) + } + + return resourceAwsSesNotificationTopicRead(d, meta) +} + +func decodeSesIdentityNotificationTopicId(id string) (string, string, error) { + parts := strings.Split(id, "|") + if len(parts) != 2 { + return "", "", fmt.Errorf("Unexpected format of ID (%q), expected IDENTITY|TYPE", id) + } + return parts[0], parts[1], nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ses_template.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ses_template.go index 8ff56d22df49..cecf7c28a81f 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ses_template.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ses_template.go @@ -7,6 +7,7 @@ import ( "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/service/ses" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsSesTemplate() *schema.Resource { @@ -25,12 +26,12 @@ func resourceAwsSesTemplate() *schema.Resource { Type: schema.TypeString, Required: true, ForceNew: true, - ValidateFunc: validateSesTemplateName, + ValidateFunc: validation.StringLenBetween(1, 64), }, "html": { Type: schema.TypeString, Optional: true, - ValidateFunc: validateSesTemplateHtml, + ValidateFunc: validateMaxLength(512000), }, "subject": { Type: schema.TypeString, @@ -39,7 +40,7 @@ func resourceAwsSesTemplate() *schema.Resource { "text": { Type: schema.TypeString, Optional: true, - ValidateFunc: validateSesTemplateText, + ValidateFunc: validateMaxLength(512000), }, }, } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sfn_activity.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sfn_activity.go index 7ed65d1f488f..9a5e49d8302f 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sfn_activity.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sfn_activity.go @@ -26,7 +26,7 @@ func resourceAwsSfnActivity() *schema.Resource { Type: schema.TypeString, Required: true, ForceNew: true, - ValidateFunc: validateSfnActivityName, + ValidateFunc: validateMaxLength(80), }, "creation_date": { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sfn_state_machine.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sfn_state_machine.go index e59765e48f71..70d8fd08cc16 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sfn_state_machine.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sfn_state_machine.go @@ -27,7 +27,7 @@ func resourceAwsSfnStateMachine() *schema.Resource { "definition": { Type: schema.TypeString, Required: true, - ValidateFunc: validateSfnStateMachineDefinition, + ValidateFunc: validateMaxLength(1024 * 1024), // 1048576 }, "name": { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sns_topic.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sns_topic.go index 3fba83d9a0d2..7818c94a67ac 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sns_topic.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sns_topic.go @@ -10,6 +10,7 @@ import ( "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" "github.com/hashicorp/terraform/helper/structure" + "github.com/hashicorp/terraform/helper/validation" ) // Mutable attributes @@ -88,7 +89,7 @@ func resourceAwsSnsTopic() *schema.Resource { "application_success_feedback_sample_rate": { Type: schema.TypeInt, Optional: true, - ValidateFunc: validateIntegerInRange(0, 100), + ValidateFunc: validation.IntBetween(0, 100), }, "application_failure_feedback_role_arn": { Type: schema.TypeString, @@ -101,7 +102,7 @@ func resourceAwsSnsTopic() *schema.Resource { "http_success_feedback_sample_rate": { Type: schema.TypeInt, Optional: true, - ValidateFunc: validateIntegerInRange(0, 100), + ValidateFunc: validation.IntBetween(0, 100), }, "http_failure_feedback_role_arn": { Type: schema.TypeString, @@ -114,7 +115,7 @@ func resourceAwsSnsTopic() *schema.Resource { "lambda_success_feedback_sample_rate": { Type: schema.TypeInt, Optional: true, - ValidateFunc: validateIntegerInRange(0, 100), + ValidateFunc: validation.IntBetween(0, 100), }, "lambda_failure_feedback_role_arn": { Type: schema.TypeString, @@ -127,7 +128,7 @@ func resourceAwsSnsTopic() *schema.Resource { "sqs_success_feedback_sample_rate": { Type: schema.TypeInt, Optional: true, - ValidateFunc: validateIntegerInRange(0, 100), + ValidateFunc: validation.IntBetween(0, 100), }, "sqs_failure_feedback_role_arn": { Type: schema.TypeString, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sns_topic_subscription.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sns_topic_subscription.go index a1c499c53d99..377284f4ddf4 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sns_topic_subscription.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sns_topic_subscription.go @@ -10,6 +10,7 @@ import ( "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" "github.com/hashicorp/terraform/helper/structure" + "github.com/hashicorp/terraform/helper/validation" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awserr" @@ -40,10 +41,18 @@ func resourceAwsSnsTopicSubscription() *schema.Resource { Schema: map[string]*schema.Schema{ "protocol": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - ValidateFunc: validateSNSSubscriptionProtocol, + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validation.StringInSlice([]string{ + // email and email-json not supported + "application", + "http", + "https", + "lambda", + "sms", + "sqs", + }, true), }, "endpoint": { Type: schema.TypeString, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_spot_fleet_request.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_spot_fleet_request.go index ec2779c0c348..a9692f9561fe 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_spot_fleet_request.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_spot_fleet_request.go @@ -13,6 +13,7 @@ import ( "github.com/hashicorp/terraform/helper/hashcode" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsSpotFleetRequest() *schema.Resource { @@ -204,7 +205,7 @@ func resourceAwsSpotFleetRequest() *schema.Resource { Optional: true, ForceNew: true, Computed: true, - ValidateFunc: validateSpotFleetRequestKeyName, + ValidateFunc: validation.NoZeroValues, }, "monitoring": { Type: schema.TypeBool, @@ -318,6 +319,22 @@ func resourceAwsSpotFleetRequest() *schema.Resource { Type: schema.TypeString, Computed: true, }, + "load_balancers": { + Type: schema.TypeSet, + Optional: true, + Computed: true, + ForceNew: true, + Elem: &schema.Schema{Type: schema.TypeString}, + Set: schema.HashString, + }, + "target_group_arns": { + Type: schema.TypeSet, + Optional: true, + Computed: true, + ForceNew: true, + Elem: &schema.Schema{Type: schema.TypeString}, + Set: schema.HashString, + }, }, } } @@ -440,16 +457,6 @@ func buildSpotFleetLaunchSpecification(d map[string]interface{}, meta interface{ return opts, nil } -func validateSpotFleetRequestKeyName(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - - if value == "" { - errors = append(errors, fmt.Errorf("Key name cannot be empty.")) - } - - return -} - func readSpotFleetBlockDeviceMappingsFromConfig( d map[string]interface{}, conn *ec2.EC2) ([]*ec2.BlockDeviceMapping, error) { blockDevices := make([]*ec2.BlockDeviceMapping, 0) @@ -611,6 +618,36 @@ func resourceAwsSpotFleetRequestCreate(d *schema.ResourceData, meta interface{}) spotFleetConfig.ValidUntil = &valid_until } + if v, ok := d.GetOk("load_balancers"); ok && v.(*schema.Set).Len() > 0 { + var elbNames []*ec2.ClassicLoadBalancer + for _, v := range v.(*schema.Set).List() { + elbNames = append(elbNames, &ec2.ClassicLoadBalancer{ + Name: aws.String(v.(string)), + }) + } + if spotFleetConfig.LoadBalancersConfig == nil { + spotFleetConfig.LoadBalancersConfig = &ec2.LoadBalancersConfig{} + } + spotFleetConfig.LoadBalancersConfig.ClassicLoadBalancersConfig = &ec2.ClassicLoadBalancersConfig{ + ClassicLoadBalancers: elbNames, + } + } + + if v, ok := d.GetOk("target_group_arns"); ok && v.(*schema.Set).Len() > 0 { + var targetGroups []*ec2.TargetGroup + for _, v := range v.(*schema.Set).List() { + targetGroups = append(targetGroups, &ec2.TargetGroup{ + Arn: aws.String(v.(string)), + }) + } + if spotFleetConfig.LoadBalancersConfig == nil { + spotFleetConfig.LoadBalancersConfig = &ec2.LoadBalancersConfig{} + } + spotFleetConfig.LoadBalancersConfig.TargetGroupsConfig = &ec2.TargetGroupsConfig{ + TargetGroups: targetGroups, + } + } + // http://docs.aws.amazon.com/sdk-for-go/api/service/ec2.html#type-RequestSpotFleetInput spotFleetOpts := &ec2.RequestSpotFleetInput{ SpotFleetRequestConfig: spotFleetConfig, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_spot_instance_request.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_spot_instance_request.go index b5c298a1bc15..1184c53a57ba 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_spot_instance_request.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_spot_instance_request.go @@ -136,7 +136,7 @@ func resourceAwsSpotInstanceRequestCreate(d *schema.ResourceData, meta interface log.Printf("[DEBUG] Requesting spot bid opts: %s", spotOpts) var resp *ec2.RequestSpotInstancesOutput - err = resource.Retry(15*time.Second, func() *resource.RetryError { + err = resource.Retry(1*time.Minute, func() *resource.RetryError { var err error resp, err = conn.RequestSpotInstances(spotOpts) // IAM instance profiles can take ~10 seconds to propagate in AWS: diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sqs_queue.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sqs_queue.go index 164c99d1d9b1..795a0254d611 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sqs_queue.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_sqs_queue.go @@ -313,13 +313,17 @@ func resourceAwsSqsQueueRead(d *schema.ResourceData, meta interface{}) error { d.Set("content_based_deduplication", d.Get("content_based_deduplication").(bool)) tags := make(map[string]string) - if !meta.(*AWSClient).IsGovCloud() { - listTagsOutput, err := sqsconn.ListQueueTags(&sqs.ListQueueTagsInput{ - QueueUrl: aws.String(d.Id()), - }) - if err != nil { + listTagsOutput, err := sqsconn.ListQueueTags(&sqs.ListQueueTagsInput{ + QueueUrl: aws.String(d.Id()), + }) + if err != nil { + // Non-standard partitions (e.g. US Gov) and some local development + // solutions do not yet support this API call. Depending on the + // implementation it may return InvalidAction or AWS.SimpleQueueService.UnsupportedOperation + if !isAWSErr(err, "InvalidAction", "") && !isAWSErr(err, sqs.ErrCodeUnsupportedOperation, "") { return err } + } else { tags = tagsToMapGeneric(listTagsOutput.Tags) } d.Set("tags", tags) diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_activation.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_activation.go index c23ca0eb2086..8fb58671d0bd 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_activation.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_activation.go @@ -34,9 +34,10 @@ func resourceAwsSsmActivation() *schema.Resource { Computed: true, }, "expiration_date": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, + Type: schema.TypeString, + Optional: true, + ForceNew: true, + ValidateFunc: validateRFC3339TimeString, }, "iam_role": { Type: schema.TypeString, @@ -77,8 +78,9 @@ func resourceAwsSsmActivationCreate(d *schema.ResourceData, meta interface{}) er activationInput.Description = aws.String(d.Get("description").(string)) } - if _, ok := d.GetOk("expiration_date"); ok { - activationInput.ExpirationDate = aws.Time(d.Get("expiration_date").(time.Time)) + if v, ok := d.GetOk("expiration_date"); ok { + t, _ := time.Parse(time.RFC3339, v.(string)) + activationInput.ExpirationDate = aws.Time(t) } if _, ok := d.GetOk("iam_role"); ok { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_association.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_association.go index d6d82021f2a1..e459ab878a1e 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_association.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_association.go @@ -6,7 +6,6 @@ import ( "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/service/ssm" - "github.com/hashicorp/errwrap" "github.com/hashicorp/terraform/helper/schema" ) @@ -123,7 +122,7 @@ func resourceAwsSsmAssociationCreate(d *schema.ResourceData, meta interface{}) e } if _, ok := d.GetOk("targets"); ok { - assosciationInput.Targets = expandAwsSsmTargets(d) + assosciationInput.Targets = expandAwsSsmTargets(d.Get("targets").([]interface{})) } if v, ok := d.GetOk("output_location"); ok { @@ -132,7 +131,7 @@ func resourceAwsSsmAssociationCreate(d *schema.ResourceData, meta interface{}) e resp, err := ssmconn.CreateAssociation(assosciationInput) if err != nil { - return errwrap.Wrapf("[ERROR] Error creating SSM association: {{err}}", err) + return fmt.Errorf("[ERROR] Error creating SSM association: %s", err) } if resp.AssociationDescription == nil { @@ -157,7 +156,11 @@ func resourceAwsSsmAssociationRead(d *schema.ResourceData, meta interface{}) err resp, err := ssmconn.DescribeAssociation(params) if err != nil { - return errwrap.Wrapf("[ERROR] Error reading SSM association: {{err}}", err) + if isAWSErr(err, ssm.ErrCodeAssociationDoesNotExist, "") { + d.SetId("") + return nil + } + return fmt.Errorf("[ERROR] Error reading SSM association: %s", err) } if resp.AssociationDescription == nil { return fmt.Errorf("[ERROR] AssociationDescription was nil") @@ -213,12 +216,12 @@ func resourceAwsSsmAssocationUpdate(d *schema.ResourceData, meta interface{}) er } if d.HasChange("targets") { - associationInput.Targets = expandAwsSsmTargets(d) + associationInput.Targets = expandAwsSsmTargets(d.Get("targets").([]interface{})) } _, err := ssmconn.UpdateAssociation(associationInput) if err != nil { - return errwrap.Wrapf("[ERROR] Error updating SSM association: {{err}}", err) + return fmt.Errorf("[ERROR] Error updating SSM association: %s", err) } return resourceAwsSsmAssociationRead(d, meta) @@ -236,7 +239,7 @@ func resourceAwsSsmAssociationDelete(d *schema.ResourceData, meta interface{}) e _, err := ssmconn.DeleteAssociation(params) if err != nil { - return errwrap.Wrapf("[ERROR] Error deleting SSM association: {{err}}", err) + return fmt.Errorf("[ERROR] Error deleting SSM association: %s", err) } return nil diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_document.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_document.go index 7a4c0c3be165..23f7facad9d2 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_document.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_document.go @@ -8,11 +8,13 @@ import ( "time" "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/ssm" "github.com/hashicorp/errwrap" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) const ( @@ -40,10 +42,23 @@ func resourceAwsSsmDocument() *schema.Resource { Type: schema.TypeString, Required: true, }, + "document_format": { + Type: schema.TypeString, + Optional: true, + Default: ssm.DocumentFormatJson, + ValidateFunc: validation.StringInSlice([]string{ + ssm.DocumentFormatJson, + ssm.DocumentFormatYaml, + }, false), + }, "document_type": { - Type: schema.TypeString, - Required: true, - ValidateFunc: validateAwsSSMDocumentType, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + ssm.DocumentTypeCommand, + ssm.DocumentTypePolicy, + ssm.DocumentTypeAutomation, + }, false), }, "schema_version": { Type: schema.TypeString, @@ -136,9 +151,10 @@ func resourceAwsSsmDocumentCreate(d *schema.ResourceData, meta interface{}) erro log.Printf("[INFO] Creating SSM Document: %s", d.Get("name").(string)) docInput := &ssm.CreateDocumentInput{ - Name: aws.String(d.Get("name").(string)), - Content: aws.String(d.Get("content").(string)), - DocumentType: aws.String(d.Get("document_type").(string)), + Name: aws.String(d.Get("name").(string)), + Content: aws.String(d.Get("content").(string)), + DocumentFormat: aws.String(d.Get("document_format").(string)), + DocumentType: aws.String(d.Get("document_type").(string)), } log.Printf("[DEBUG] Waiting for SSM Document %q to be created", d.Get("name").(string)) @@ -197,6 +213,7 @@ func resourceAwsSsmDocumentRead(d *schema.ResourceData, meta interface{}) error d.Set("document_type", doc.DocumentType) } + d.Set("document_format", doc.DocumentFormat) d.Set("document_version", doc.DocumentVersion) d.Set("hash", doc.Hash) d.Set("hash_type", doc.HashType) @@ -204,7 +221,13 @@ func resourceAwsSsmDocumentRead(d *schema.ResourceData, meta interface{}) error d.Set("name", doc.Name) d.Set("owner", doc.Owner) d.Set("platform_types", flattenStringList(doc.PlatformTypes)) - if err := d.Set("arn", flattenAwsSsmDocumentArn(meta, doc.Name)); err != nil { + arn := arn.ARN{ + Partition: meta.(*AWSClient).partition, + Service: "ssm", + Region: meta.(*AWSClient).region, + Resource: fmt.Sprintf("document/%s", *doc.Name), + }.String() + if err := d.Set("arn", arn); err != nil { return fmt.Errorf("[DEBUG] Error setting arn error: %#v", err) } @@ -250,12 +273,6 @@ func resourceAwsSsmDocumentRead(d *schema.ResourceData, meta interface{}) error return nil } -func flattenAwsSsmDocumentArn(meta interface{}, docName *string) string { - region := meta.(*AWSClient).region - - return fmt.Sprintf("arn:aws:ssm:%s::document/%s", region, *docName) -} - func resourceAwsSsmDocumentUpdate(d *schema.ResourceData, meta interface{}) error { if _, ok := d.GetOk("permissions"); ok { @@ -434,6 +451,7 @@ func updateAwsSSMDocument(d *schema.ResourceData, meta interface{}) error { updateDocInput := &ssm.UpdateDocumentInput{ Name: aws.String(name), Content: aws.String(d.Get("content").(string)), + DocumentFormat: aws.String(d.Get("document_format").(string)), DocumentVersion: aws.String(d.Get("default_version").(string)), } @@ -466,17 +484,3 @@ func updateAwsSSMDocument(d *schema.ResourceData, meta interface{}) error { } return nil } - -func validateAwsSSMDocumentType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - types := map[string]bool{ - "Command": true, - "Policy": true, - "Automation": true, - } - - if !types[value] { - errors = append(errors, fmt.Errorf("Document type %s is invalid. Valid types are Command, Policy or Automation", value)) - } - return -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_maintenance_window_target.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_maintenance_window_target.go index 20fbd3bc768b..868323835a02 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_maintenance_window_target.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_maintenance_window_target.go @@ -13,6 +13,7 @@ func resourceAwsSsmMaintenanceWindowTarget() *schema.Resource { return &schema.Resource{ Create: resourceAwsSsmMaintenanceWindowTargetCreate, Read: resourceAwsSsmMaintenanceWindowTargetRead, + Update: resourceAwsSsmMaintenanceWindowTargetUpdate, Delete: resourceAwsSsmMaintenanceWindowTargetDelete, Schema: map[string]*schema.Schema{ @@ -31,7 +32,6 @@ func resourceAwsSsmMaintenanceWindowTarget() *schema.Resource { "targets": { Type: schema.TypeList, Required: true, - ForceNew: true, MaxItems: 5, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ @@ -50,7 +50,6 @@ func resourceAwsSsmMaintenanceWindowTarget() *schema.Resource { "owner_information": { Type: schema.TypeString, - ForceNew: true, Optional: true, }, }, @@ -65,7 +64,7 @@ func resourceAwsSsmMaintenanceWindowTargetCreate(d *schema.ResourceData, meta in params := &ssm.RegisterTargetWithMaintenanceWindowInput{ WindowId: aws.String(d.Get("window_id").(string)), ResourceType: aws.String(d.Get("resource_type").(string)), - Targets: expandAwsSsmTargets(d), + Targets: expandAwsSsmTargets(d.Get("targets").([]interface{})), } if v, ok := d.GetOk("owner_information"); ok { @@ -124,6 +123,29 @@ func resourceAwsSsmMaintenanceWindowTargetRead(d *schema.ResourceData, meta inte return nil } +func resourceAwsSsmMaintenanceWindowTargetUpdate(d *schema.ResourceData, meta interface{}) error { + ssmconn := meta.(*AWSClient).ssmconn + + log.Printf("[INFO] Updating SSM Maintenance Window Target: %s", d.Id()) + + params := &ssm.UpdateMaintenanceWindowTargetInput{ + Targets: expandAwsSsmTargets(d.Get("targets").([]interface{})), + WindowId: aws.String(d.Get("window_id").(string)), + WindowTargetId: aws.String(d.Id()), + } + + if d.HasChange("owner_information") { + params.OwnerInformation = aws.String(d.Get("owner_information").(string)) + } + + _, err := ssmconn.UpdateMaintenanceWindowTarget(params) + if err != nil { + return err + } + + return nil +} + func resourceAwsSsmMaintenanceWindowTargetDelete(d *schema.ResourceData, meta interface{}) error { ssmconn := meta.(*AWSClient).ssmconn diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_maintenance_window_task.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_maintenance_window_task.go index a45aa7db8430..072b5877c801 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_maintenance_window_task.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_maintenance_window_task.go @@ -191,7 +191,7 @@ func resourceAwsSsmMaintenanceWindowTaskCreate(d *schema.ResourceData, meta inte TaskType: aws.String(d.Get("task_type").(string)), ServiceRoleArn: aws.String(d.Get("service_role_arn").(string)), TaskArn: aws.String(d.Get("task_arn").(string)), - Targets: expandAwsSsmTargets(d), + Targets: expandAwsSsmTargets(d.Get("targets").([]interface{})), } if v, ok := d.GetOk("priority"); ok { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_parameter.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_parameter.go index d22668cb4281..8f509be04d56 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_parameter.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ssm_parameter.go @@ -8,8 +8,8 @@ import ( "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/service/ssm" - "github.com/hashicorp/errwrap" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsSsmParameter() *schema.Resource { @@ -18,6 +18,7 @@ func resourceAwsSsmParameter() *schema.Resource { Read: resourceAwsSsmParameterRead, Update: resourceAwsSsmParameterPut, Delete: resourceAwsSsmParameterDelete, + Exists: resourceAwsSmmParameterExists, Importer: &schema.ResourceImporter{ State: schema.ImportStatePassthrough, }, @@ -28,11 +29,18 @@ func resourceAwsSsmParameter() *schema.Resource { Required: true, ForceNew: true, }, + "description": { + Type: schema.TypeString, + Optional: true, + }, "type": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - ValidateFunc: validateSsmParameterType, + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + ssm.ParameterTypeString, + ssm.ParameterTypeStringList, + ssm.ParameterTypeSecureString, + }, false), }, "value": { Type: schema.TypeString, @@ -47,35 +55,47 @@ func resourceAwsSsmParameter() *schema.Resource { "key_id": { Type: schema.TypeString, Optional: true, - ForceNew: true, + Computed: true, }, "overwrite": { Type: schema.TypeBool, Optional: true, - Default: false, }, + "allowed_pattern": { + Type: schema.TypeString, + Optional: true, + }, + "tags": tagsSchema(), }, } } -func resourceAwsSsmParameterRead(d *schema.ResourceData, meta interface{}) error { +func resourceAwsSmmParameterExists(d *schema.ResourceData, meta interface{}) (bool, error) { ssmconn := meta.(*AWSClient).ssmconn - log.Printf("[DEBUG] Reading SSM Parameter: %s", d.Id()) - - paramInput := &ssm.GetParametersInput{ - Names: []*string{ - aws.String(d.Id()), - }, + resp, err := ssmconn.GetParameters(&ssm.GetParametersInput{ + Names: []*string{aws.String(d.Id())}, WithDecryption: aws.Bool(true), + }) + + if err != nil { + return false, err } + return len(resp.InvalidParameters) == 0, nil +} + +func resourceAwsSsmParameterRead(d *schema.ResourceData, meta interface{}) error { + ssmconn := meta.(*AWSClient).ssmconn - resp, err := ssmconn.GetParameters(paramInput) + log.Printf("[DEBUG] Reading SSM Parameter: %s", d.Id()) + resp, err := ssmconn.GetParameters(&ssm.GetParametersInput{ + Names: []*string{aws.String(d.Id())}, + WithDecryption: aws.Bool(true), + }) if err != nil { - return errwrap.Wrapf("[ERROR] Error describing SSM parameter: {{err}}", err) + return fmt.Errorf("error getting SSM parameter: %s", err) } - if len(resp.Parameters) == 0 { log.Printf("[WARN] SSM Param %q not found, removing from state", d.Id()) d.SetId("") @@ -87,6 +107,43 @@ func resourceAwsSsmParameterRead(d *schema.ResourceData, meta interface{}) error d.Set("type", param.Type) d.Set("value", param.Value) + describeParamsInput := &ssm.DescribeParametersInput{ + Filters: []*ssm.ParametersFilter{ + &ssm.ParametersFilter{ + Key: aws.String("Name"), + Values: []*string{aws.String(d.Get("name").(string))}, + }, + }, + } + detailedParameters := []*ssm.ParameterMetadata{} + err = ssmconn.DescribeParametersPages(describeParamsInput, + func(page *ssm.DescribeParametersOutput, lastPage bool) bool { + detailedParameters = append(detailedParameters, page.Parameters...) + return !lastPage + }) + if err != nil { + return fmt.Errorf("error describing SSM parameter: %s", err) + } + if len(detailedParameters) == 0 { + log.Printf("[WARN] SSM Param %q not found, removing from state", d.Id()) + d.SetId("") + return nil + } + + detail := detailedParameters[0] + d.Set("key_id", detail.KeyId) + d.Set("description", detail.Description) + d.Set("allowed_pattern", detail.AllowedPattern) + + if tagList, err := ssmconn.ListTagsForResource(&ssm.ListTagsForResourceInput{ + ResourceId: aws.String(d.Get("name").(string)), + ResourceType: aws.String("Parameter"), + }); err != nil { + return fmt.Errorf("Failed to get SSM parameter tags for %s: %s", d.Get("name"), err) + } else { + d.Set("tags", tagsToMapSSM(tagList.TagList)) + } + arn := arn.ARN{ Partition: meta.(*AWSClient).partition, Region: meta.(*AWSClient).region, @@ -104,15 +161,12 @@ func resourceAwsSsmParameterDelete(d *schema.ResourceData, meta interface{}) err log.Printf("[INFO] Deleting SSM Parameter: %s", d.Id()) - paramInput := &ssm.DeleteParameterInput{ + _, err := ssmconn.DeleteParameter(&ssm.DeleteParameterInput{ Name: aws.String(d.Get("name").(string)), - } - - _, err := ssmconn.DeleteParameter(paramInput) + }) if err != nil { return err } - d.SetId("") return nil @@ -124,24 +178,44 @@ func resourceAwsSsmParameterPut(d *schema.ResourceData, meta interface{}) error log.Printf("[INFO] Creating SSM Parameter: %s", d.Get("name").(string)) paramInput := &ssm.PutParameterInput{ - Name: aws.String(d.Get("name").(string)), - Type: aws.String(d.Get("type").(string)), - Value: aws.String(d.Get("value").(string)), - Overwrite: aws.Bool(d.Get("overwrite").(bool)), + Name: aws.String(d.Get("name").(string)), + Type: aws.String(d.Get("type").(string)), + Value: aws.String(d.Get("value").(string)), + Overwrite: aws.Bool(shouldUpdateSsmParameter(d)), + AllowedPattern: aws.String(d.Get("allowed_pattern").(string)), + } + + if d.HasChange("description") { + _, n := d.GetChange("description") + paramInput.Description = aws.String(n.(string)) } + if keyID, ok := d.GetOk("key_id"); ok { - log.Printf("[DEBUG] Setting key_id for SSM Parameter %s: %s", d.Get("name").(string), keyID.(string)) + log.Printf("[DEBUG] Setting key_id for SSM Parameter %v: %s", d.Get("name"), keyID) paramInput.SetKeyId(keyID.(string)) } - log.Printf("[DEBUG] Waiting for SSM Parameter %q to be updated", d.Get("name").(string)) - _, err := ssmconn.PutParameter(paramInput) + log.Printf("[DEBUG] Waiting for SSM Parameter %v to be updated", d.Get("name")) + if _, err := ssmconn.PutParameter(paramInput); err != nil { + return fmt.Errorf("error creating SSM parameter: %s", err) + } - if err != nil { - return errwrap.Wrapf("[ERROR] Error creating SSM parameter: {{err}}", err) + if err := setTagsSSM(ssmconn, d, d.Get("name").(string), "Parameter"); err != nil { + return fmt.Errorf("error creating SSM parameter tags: %s", err) } d.SetId(d.Get("name").(string)) return resourceAwsSsmParameterRead(d, meta) } + +func shouldUpdateSsmParameter(d *schema.ResourceData) bool { + // If the user has specified a preference, return their preference + if value, ok := d.GetOkExists("overwrite"); ok { + return value.(bool) + } + + // Since the user has not specified a preference, obey lifecycle rules + // if it is not a new resource, otherwise overwrite should be set to false. + return !d.IsNewResource() +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_vpc_endpoint.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_vpc_endpoint.go index e8a895332d71..2826f4904680 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_vpc_endpoint.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_vpc_endpoint.go @@ -32,11 +32,14 @@ func resourceAwsVpcEndpoint() *schema.Resource { ForceNew: true, }, "vpc_endpoint_type": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, - Default: ec2.VpcEndpointTypeGateway, - ValidateFunc: validation.StringInSlice([]string{ec2.VpcEndpointTypeGateway, ec2.VpcEndpointTypeInterface}, false), + Type: schema.TypeString, + Optional: true, + ForceNew: true, + Default: ec2.VpcEndpointTypeGateway, + ValidateFunc: validation.StringInSlice([]string{ + ec2.VpcEndpointTypeGateway, + ec2.VpcEndpointTypeInterface, + }, false), }, "service_name": { Type: schema.TypeString, @@ -347,8 +350,12 @@ func vpcEndpointAttributes(d *schema.ResourceData, vpce *ec2.VpcEndpoint, conn * serviceName := aws.StringValue(vpce.ServiceName) d.Set("service_name", serviceName) - vpceType := aws.StringValue(vpce.VpcEndpointType) - d.Set("vpc_endpoint_type", vpceType) + // VPC endpoints don't have types in GovCloud, so set type to default if empty + if aws.StringValue(vpce.VpcEndpointType) == "" { + d.Set("vpc_endpoint_type", ec2.VpcEndpointTypeGateway) + } else { + d.Set("vpc_endpoint_type", vpce.VpcEndpointType) + } policy, err := structure.NormalizeJsonString(aws.StringValue(vpce.PolicyDocument)) if err != nil { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_vpc_peering_connection.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_vpc_peering_connection.go index 45964e2da5ba..afea54ed4c41 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_vpc_peering_connection.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_vpc_peering_connection.go @@ -282,15 +282,23 @@ func resourceAwsVPCPeeringUpdate(d *schema.ResourceData, meta interface{}) error func resourceAwsVPCPeeringDelete(d *schema.ResourceData, meta interface{}) error { conn := meta.(*AWSClient).ec2conn - _, err := conn.DeleteVpcPeeringConnection( - &ec2.DeleteVpcPeeringConnectionInput{ - VpcPeeringConnectionId: aws.String(d.Id()), - }) + input := &ec2.DeleteVpcPeeringConnectionInput{ + VpcPeeringConnectionId: aws.String(d.Id()), + } + log.Printf("[DEBUG] Deleting VPC Peering Connection: %s", input) + _, err := conn.DeleteVpcPeeringConnection(input) + if err != nil { + if isAWSErr(err, "InvalidVpcPeeringConnectionID.NotFound", "") { + return nil + } + return fmt.Errorf("Error deleting VPC Peering Connection (%s): %s", d.Id(), err) + } - // Wait for the vpc peering connection to become available + // Wait for the vpc peering connection to delete log.Printf("[DEBUG] Waiting for VPC Peering Connection (%s) to delete.", d.Id()) stateConf := &resource.StateChangeConf{ Pending: []string{ + ec2.VpcPeeringConnectionStateReasonCodeActive, ec2.VpcPeeringConnectionStateReasonCodePendingAcceptance, ec2.VpcPeeringConnectionStateReasonCodeDeleting, }, @@ -302,12 +310,10 @@ func resourceAwsVPCPeeringDelete(d *schema.ResourceData, meta interface{}) error Timeout: 1 * time.Minute, } if _, err := stateConf.WaitForState(); err != nil { - return errwrap.Wrapf(fmt.Sprintf( - "Error waiting for VPC Peering Connection (%s) to be deleted: {{err}}", - d.Id()), err) + return fmt.Errorf("Error waiting for VPC Peering Connection (%s) to be deleted: %s", d.Id(), err) } - return err + return nil } // resourceAwsVPCPeeringConnectionStateRefreshFunc returns a resource.StateRefreshFunc that is used to watch diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_geo_match_set.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_geo_match_set.go new file mode 100644 index 000000000000..2bbd8ac7600a --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_geo_match_set.go @@ -0,0 +1,157 @@ +package aws + +import ( + "fmt" + "log" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/waf" + "github.com/hashicorp/errwrap" + "github.com/hashicorp/terraform/helper/schema" +) + +func resourceAwsWafGeoMatchSet() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsWafGeoMatchSetCreate, + Read: resourceAwsWafGeoMatchSetRead, + Update: resourceAwsWafGeoMatchSetUpdate, + Delete: resourceAwsWafGeoMatchSetDelete, + + Schema: map[string]*schema.Schema{ + "name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "geo_match_constraint": &schema.Schema{ + Type: schema.TypeSet, + Optional: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "type": { + Type: schema.TypeString, + Required: true, + }, + "value": { + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + }, + } +} + +func resourceAwsWafGeoMatchSetCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafconn + + log.Printf("[INFO] Creating GeoMatchSet: %s", d.Get("name").(string)) + + wr := newWafRetryer(conn, "global") + out, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + params := &waf.CreateGeoMatchSetInput{ + ChangeToken: token, + Name: aws.String(d.Get("name").(string)), + } + + return conn.CreateGeoMatchSet(params) + }) + if err != nil { + return errwrap.Wrapf("[ERROR] Error creating GeoMatchSet: {{err}}", err) + } + resp := out.(*waf.CreateGeoMatchSetOutput) + + d.SetId(*resp.GeoMatchSet.GeoMatchSetId) + + return resourceAwsWafGeoMatchSetUpdate(d, meta) +} + +func resourceAwsWafGeoMatchSetRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafconn + log.Printf("[INFO] Reading GeoMatchSet: %s", d.Get("name").(string)) + params := &waf.GetGeoMatchSetInput{ + GeoMatchSetId: aws.String(d.Id()), + } + + resp, err := conn.GetGeoMatchSet(params) + if err != nil { + // TODO: Replace with constant once it's available + // See https://github.com/aws/aws-sdk-go/issues/1856 + if isAWSErr(err, "WAFNonexistentItemException", "") { + log.Printf("[WARN] WAF GeoMatchSet (%s) not found, removing from state", d.Id()) + d.SetId("") + return nil + } + + return err + } + + d.Set("name", resp.GeoMatchSet.Name) + d.Set("geo_match_constraint", flattenWafGeoMatchConstraint(resp.GeoMatchSet.GeoMatchConstraints)) + + return nil +} + +func resourceAwsWafGeoMatchSetUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafconn + + if d.HasChange("geo_match_constraint") { + o, n := d.GetChange("geo_match_constraint") + oldT, newT := o.(*schema.Set).List(), n.(*schema.Set).List() + + err := updateGeoMatchSetResource(d.Id(), oldT, newT, conn) + if err != nil { + return errwrap.Wrapf("[ERROR] Error updating GeoMatchSet: {{err}}", err) + } + } + + return resourceAwsWafGeoMatchSetRead(d, meta) +} + +func resourceAwsWafGeoMatchSetDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafconn + + oldConstraints := d.Get("geo_match_constraint").(*schema.Set).List() + if len(oldConstraints) > 0 { + noConstraints := []interface{}{} + err := updateGeoMatchSetResource(d.Id(), oldConstraints, noConstraints, conn) + if err != nil { + return fmt.Errorf("Error updating GeoMatchConstraint: %s", err) + } + } + + wr := newWafRetryer(conn, "global") + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.DeleteGeoMatchSetInput{ + ChangeToken: token, + GeoMatchSetId: aws.String(d.Id()), + } + + return conn.DeleteGeoMatchSet(req) + }) + if err != nil { + return errwrap.Wrapf("[ERROR] Error deleting GeoMatchSet: {{err}}", err) + } + + return nil +} + +func updateGeoMatchSetResource(id string, oldT, newT []interface{}, conn *waf.WAF) error { + wr := newWafRetryer(conn, "global") + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.UpdateGeoMatchSetInput{ + ChangeToken: token, + GeoMatchSetId: aws.String(id), + Updates: diffWafGeoMatchSetConstraints(oldT, newT), + } + + log.Printf("[INFO] Updating GeoMatchSet constraints: %s", req) + return conn.UpdateGeoMatchSet(req) + }) + if err != nil { + return errwrap.Wrapf("[ERROR] Error updating GeoMatchSet: {{err}}", err) + } + + return nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_rate_based_rule.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_rate_based_rule.go index 27d10adec8aa..c30a8178c99a 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_rate_based_rule.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_rate_based_rule.go @@ -8,6 +8,7 @@ import ( "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/waf" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsWafRateBasedRule() *schema.Resource { @@ -39,28 +40,14 @@ func resourceAwsWafRateBasedRule() *schema.Resource { Required: true, }, "data_id": &schema.Schema{ - Type: schema.TypeString, - Required: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 128 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 128 characters", k)) - } - return - }, + Type: schema.TypeString, + Required: true, + ValidateFunc: validateMaxLength(128), }, "type": &schema.Schema{ - Type: schema.TypeString, - Required: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != "IPMatch" && value != "ByteMatch" && value != "SqlInjectionMatch" && value != "SizeConstraint" && value != "XssMatch" { - errors = append(errors, fmt.Errorf( - "%q must be one of IPMatch | ByteMatch | SqlInjectionMatch | SizeConstraint | XssMatch", k)) - } - return - }, + Type: schema.TypeString, + Required: true, + ValidateFunc: validateWafPredicatesType(), }, }, }, @@ -70,15 +57,9 @@ func resourceAwsWafRateBasedRule() *schema.Resource { Required: true, }, "rate_limit": &schema.Schema{ - Type: schema.TypeInt, - Required: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(int) - if value < 2000 { - errors = append(errors, fmt.Errorf("%q cannot be less than 2000", k)) - } - return - }, + Type: schema.TypeInt, + Required: true, + ValidateFunc: validation.IntAtLeast(2000), }, }, } diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_regex_match_set.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_regex_match_set.go new file mode 100644 index 000000000000..ed19133fa8a3 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_regex_match_set.go @@ -0,0 +1,175 @@ +package aws + +import ( + "fmt" + "log" + "strings" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/waf" + "github.com/hashicorp/terraform/helper/schema" +) + +func resourceAwsWafRegexMatchSet() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsWafRegexMatchSetCreate, + Read: resourceAwsWafRegexMatchSetRead, + Update: resourceAwsWafRegexMatchSetUpdate, + Delete: resourceAwsWafRegexMatchSetDelete, + + Schema: map[string]*schema.Schema{ + "name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "regex_match_tuple": { + Type: schema.TypeSet, + Optional: true, + Set: resourceAwsWafRegexMatchSetTupleHash, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "field_to_match": { + Type: schema.TypeList, + Required: true, + MaxItems: 1, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "data": { + Type: schema.TypeString, + Optional: true, + StateFunc: func(v interface{}) string { + return strings.ToLower(v.(string)) + }, + }, + "type": { + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + "regex_pattern_set_id": { + Type: schema.TypeString, + Required: true, + }, + "text_transformation": { + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + }, + } +} + +func resourceAwsWafRegexMatchSetCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafconn + + log.Printf("[INFO] Creating WAF Regex Match Set: %s", d.Get("name").(string)) + + wr := newWafRetryer(conn, "global") + out, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + params := &waf.CreateRegexMatchSetInput{ + ChangeToken: token, + Name: aws.String(d.Get("name").(string)), + } + return conn.CreateRegexMatchSet(params) + }) + if err != nil { + return fmt.Errorf("Failed creating WAF Regex Match Set: %s", err) + } + resp := out.(*waf.CreateRegexMatchSetOutput) + + d.SetId(*resp.RegexMatchSet.RegexMatchSetId) + + return resourceAwsWafRegexMatchSetUpdate(d, meta) +} + +func resourceAwsWafRegexMatchSetRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafconn + log.Printf("[INFO] Reading WAF Regex Match Set: %s", d.Get("name").(string)) + params := &waf.GetRegexMatchSetInput{ + RegexMatchSetId: aws.String(d.Id()), + } + + resp, err := conn.GetRegexMatchSet(params) + if err != nil { + if isAWSErr(err, "WAFNonexistentItemException", "") { + log.Printf("[WARN] WAF Regex Match Set (%s) not found, removing from state", d.Id()) + d.SetId("") + return nil + } + + return err + } + + d.Set("name", resp.RegexMatchSet.Name) + d.Set("regex_match_tuple", flattenWafRegexMatchTuples(resp.RegexMatchSet.RegexMatchTuples)) + + return nil +} + +func resourceAwsWafRegexMatchSetUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafconn + + log.Printf("[INFO] Updating WAF Regex Match Set: %s", d.Get("name").(string)) + + if d.HasChange("regex_match_tuple") { + o, n := d.GetChange("regex_match_tuple") + oldT, newT := o.(*schema.Set).List(), n.(*schema.Set).List() + err := updateRegexMatchSetResource(d.Id(), oldT, newT, conn) + if err != nil { + return fmt.Errorf("Failed updating WAF Regex Match Set: %s", err) + } + } + + return resourceAwsWafRegexMatchSetRead(d, meta) +} + +func resourceAwsWafRegexMatchSetDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafconn + + oldTuples := d.Get("regex_match_tuple").(*schema.Set).List() + if len(oldTuples) > 0 { + noTuples := []interface{}{} + err := updateRegexMatchSetResource(d.Id(), oldTuples, noTuples, conn) + if err != nil { + return fmt.Errorf("Error updating WAF Regex Match Set: %s", err) + } + } + + wr := newWafRetryer(conn, "global") + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.DeleteRegexMatchSetInput{ + ChangeToken: token, + RegexMatchSetId: aws.String(d.Id()), + } + log.Printf("[INFO] Deleting WAF Regex Match Set: %s", req) + return conn.DeleteRegexMatchSet(req) + }) + if err != nil { + return fmt.Errorf("Failed deleting WAF Regex Match Set: %s", err) + } + + return nil +} + +func updateRegexMatchSetResource(id string, oldT, newT []interface{}, conn *waf.WAF) error { + wr := newWafRetryer(conn, "global") + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.UpdateRegexMatchSetInput{ + ChangeToken: token, + RegexMatchSetId: aws.String(id), + Updates: diffWafRegexMatchSetTuples(oldT, newT), + } + + return conn.UpdateRegexMatchSet(req) + }) + if err != nil { + return fmt.Errorf("Failed updating WAF Regex Match Set: %s", err) + } + + return nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_regex_pattern_set.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_regex_pattern_set.go new file mode 100644 index 000000000000..1ebbc58f69a0 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_regex_pattern_set.go @@ -0,0 +1,144 @@ +package aws + +import ( + "fmt" + "log" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/waf" + "github.com/hashicorp/terraform/helper/schema" +) + +func resourceAwsWafRegexPatternSet() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsWafRegexPatternSetCreate, + Read: resourceAwsWafRegexPatternSetRead, + Update: resourceAwsWafRegexPatternSetUpdate, + Delete: resourceAwsWafRegexPatternSetDelete, + + Schema: map[string]*schema.Schema{ + "name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "regex_pattern_strings": { + Type: schema.TypeSet, + Optional: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + }, + } +} + +func resourceAwsWafRegexPatternSetCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafconn + + log.Printf("[INFO] Creating WAF Regex Pattern Set: %s", d.Get("name").(string)) + + wr := newWafRetryer(conn, "global") + out, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + params := &waf.CreateRegexPatternSetInput{ + ChangeToken: token, + Name: aws.String(d.Get("name").(string)), + } + return conn.CreateRegexPatternSet(params) + }) + if err != nil { + return fmt.Errorf("Failed creating WAF Regex Pattern Set: %s", err) + } + resp := out.(*waf.CreateRegexPatternSetOutput) + + d.SetId(*resp.RegexPatternSet.RegexPatternSetId) + + return resourceAwsWafRegexPatternSetUpdate(d, meta) +} + +func resourceAwsWafRegexPatternSetRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafconn + log.Printf("[INFO] Reading WAF Regex Pattern Set: %s", d.Get("name").(string)) + params := &waf.GetRegexPatternSetInput{ + RegexPatternSetId: aws.String(d.Id()), + } + + resp, err := conn.GetRegexPatternSet(params) + if err != nil { + // TODO: Replace with a constant once available + // See https://github.com/aws/aws-sdk-go/issues/1856 + if isAWSErr(err, "WAFNonexistentItemException", "") { + log.Printf("[WARN] WAF Regex Pattern Set (%s) not found, removing from state", d.Id()) + d.SetId("") + return nil + } + + return err + } + + d.Set("name", resp.RegexPatternSet.Name) + d.Set("regex_pattern_strings", aws.StringValueSlice(resp.RegexPatternSet.RegexPatternStrings)) + + return nil +} + +func resourceAwsWafRegexPatternSetUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafconn + + log.Printf("[INFO] Updating WAF Regex Pattern Set: %s", d.Get("name").(string)) + + if d.HasChange("regex_pattern_strings") { + o, n := d.GetChange("regex_pattern_strings") + oldPatterns, newPatterns := o.(*schema.Set).List(), n.(*schema.Set).List() + err := updateWafRegexPatternSetPatternStrings(d.Id(), oldPatterns, newPatterns, conn) + if err != nil { + return fmt.Errorf("Failed updating WAF Regex Pattern Set: %s", err) + } + } + + return resourceAwsWafRegexPatternSetRead(d, meta) +} + +func resourceAwsWafRegexPatternSetDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafconn + + oldPatterns := d.Get("regex_pattern_strings").(*schema.Set).List() + if len(oldPatterns) > 0 { + noPatterns := []interface{}{} + err := updateWafRegexPatternSetPatternStrings(d.Id(), oldPatterns, noPatterns, conn) + if err != nil { + return fmt.Errorf("Error updating WAF Regex Pattern Set: %s", err) + } + } + + wr := newWafRetryer(conn, "global") + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.DeleteRegexPatternSetInput{ + ChangeToken: token, + RegexPatternSetId: aws.String(d.Id()), + } + log.Printf("[INFO] Deleting WAF Regex Pattern Set: %s", req) + return conn.DeleteRegexPatternSet(req) + }) + if err != nil { + return fmt.Errorf("Failed deleting WAF Regex Pattern Set: %s", err) + } + + return nil +} + +func updateWafRegexPatternSetPatternStrings(id string, oldPatterns, newPatterns []interface{}, conn *waf.WAF) error { + wr := newWafRetryer(conn, "global") + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.UpdateRegexPatternSetInput{ + ChangeToken: token, + RegexPatternSetId: aws.String(id), + Updates: diffWafRegexPatternSetPatternStrings(oldPatterns, newPatterns), + } + + return conn.UpdateRegexPatternSet(req) + }) + if err != nil { + return fmt.Errorf("Failed updating WAF Regex Pattern Set: %s", err) + } + + return nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_rule.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_rule.go index 23f5fb594fac..650d2eb9a431 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_rule.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_rule.go @@ -39,28 +39,14 @@ func resourceAwsWafRule() *schema.Resource { Required: true, }, "data_id": &schema.Schema{ - Type: schema.TypeString, - Required: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 128 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 128 characters", k)) - } - return - }, + Type: schema.TypeString, + Required: true, + ValidateFunc: validateMaxLength(128), }, "type": &schema.Schema{ - Type: schema.TypeString, - Required: true, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != "IPMatch" && value != "ByteMatch" && value != "SqlInjectionMatch" && value != "SizeConstraint" && value != "XssMatch" { - errors = append(errors, fmt.Errorf( - "%q must be one of IPMatch | ByteMatch | SqlInjectionMatch | SizeConstraint | XssMatch", k)) - } - return - }, + Type: schema.TypeString, + Required: true, + ValidateFunc: validateWafPredicatesType(), }, }, }, @@ -187,39 +173,3 @@ func updateWafRuleResource(id string, oldP, newP []interface{}, conn *waf.WAF) e return nil } - -func diffWafRulePredicates(oldP, newP []interface{}) []*waf.RuleUpdate { - updates := make([]*waf.RuleUpdate, 0) - - for _, op := range oldP { - predicate := op.(map[string]interface{}) - - if idx, contains := sliceContainsMap(newP, predicate); contains { - newP = append(newP[:idx], newP[idx+1:]...) - continue - } - - updates = append(updates, &waf.RuleUpdate{ - Action: aws.String(waf.ChangeActionDelete), - Predicate: &waf.Predicate{ - Negated: aws.Bool(predicate["negated"].(bool)), - Type: aws.String(predicate["type"].(string)), - DataId: aws.String(predicate["data_id"].(string)), - }, - }) - } - - for _, np := range newP { - predicate := np.(map[string]interface{}) - - updates = append(updates, &waf.RuleUpdate{ - Action: aws.String(waf.ChangeActionInsert), - Predicate: &waf.Predicate{ - Negated: aws.Bool(predicate["negated"].(bool)), - Type: aws.String(predicate["type"].(string)), - DataId: aws.String(predicate["data_id"].(string)), - }, - }) - } - return updates -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_rule_group.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_rule_group.go new file mode 100644 index 000000000000..16c6e74f7099 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_rule_group.go @@ -0,0 +1,187 @@ +package aws + +import ( + "fmt" + "log" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/waf" + "github.com/hashicorp/terraform/helper/schema" +) + +func resourceAwsWafRuleGroup() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsWafRuleGroupCreate, + Read: resourceAwsWafRuleGroupRead, + Update: resourceAwsWafRuleGroupUpdate, + Delete: resourceAwsWafRuleGroupDelete, + + Schema: map[string]*schema.Schema{ + "name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "metric_name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validateWafMetricName, + }, + "activated_rule": { + Type: schema.TypeSet, + Optional: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "action": { + Type: schema.TypeList, + MaxItems: 1, + Required: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "type": { + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + "priority": { + Type: schema.TypeInt, + Required: true, + }, + "rule_id": { + Type: schema.TypeString, + Required: true, + }, + "type": { + Type: schema.TypeString, + Optional: true, + Default: waf.WafRuleTypeRegular, + }, + }, + }, + }, + }, + } +} + +func resourceAwsWafRuleGroupCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafconn + + wr := newWafRetryer(conn, "global") + out, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + params := &waf.CreateRuleGroupInput{ + ChangeToken: token, + MetricName: aws.String(d.Get("metric_name").(string)), + Name: aws.String(d.Get("name").(string)), + } + + return conn.CreateRuleGroup(params) + }) + if err != nil { + return err + } + resp := out.(*waf.CreateRuleGroupOutput) + d.SetId(*resp.RuleGroup.RuleGroupId) + return resourceAwsWafRuleGroupUpdate(d, meta) +} + +func resourceAwsWafRuleGroupRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafconn + + params := &waf.GetRuleGroupInput{ + RuleGroupId: aws.String(d.Id()), + } + + resp, err := conn.GetRuleGroup(params) + if err != nil { + if isAWSErr(err, "WAFNonexistentItemException", "") { + log.Printf("[WARN] WAF Rule Group (%s) not found, removing from state", d.Id()) + d.SetId("") + return nil + } + + return err + } + + rResp, err := conn.ListActivatedRulesInRuleGroup(&waf.ListActivatedRulesInRuleGroupInput{ + RuleGroupId: aws.String(d.Id()), + }) + + d.Set("activated_rule", flattenWafActivatedRules(rResp.ActivatedRules)) + d.Set("name", resp.RuleGroup.Name) + d.Set("metric_name", resp.RuleGroup.MetricName) + + return nil +} + +func resourceAwsWafRuleGroupUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafconn + + if d.HasChange("activated_rule") { + o, n := d.GetChange("activated_rule") + oldRules, newRules := o.(*schema.Set).List(), n.(*schema.Set).List() + + err := updateWafRuleGroupResource(d.Id(), oldRules, newRules, conn) + if err != nil { + return fmt.Errorf("Error Updating WAF Rule Group: %s", err) + } + } + + return resourceAwsWafRuleGroupRead(d, meta) +} + +func resourceAwsWafRuleGroupDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafconn + + oldRules := d.Get("activated_rule").(*schema.Set).List() + err := deleteWafRuleGroup(d.Id(), oldRules, conn) + if err != nil { + return err + } + + return nil +} + +func deleteWafRuleGroup(id string, oldRules []interface{}, conn *waf.WAF) error { + if len(oldRules) > 0 { + noRules := []interface{}{} + err := updateWafRuleGroupResource(id, oldRules, noRules, conn) + if err != nil { + return fmt.Errorf("Error updating WAF Rule Group Predicates: %s", err) + } + } + + wr := newWafRetryer(conn, "global") + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.DeleteRuleGroupInput{ + ChangeToken: token, + RuleGroupId: aws.String(id), + } + log.Printf("[INFO] Deleting WAF Rule Group") + return conn.DeleteRuleGroup(req) + }) + if err != nil { + return fmt.Errorf("Error deleting WAF Rule Group: %s", err) + } + return nil +} + +func updateWafRuleGroupResource(id string, oldRules, newRules []interface{}, conn *waf.WAF) error { + wr := newWafRetryer(conn, "global") + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.UpdateRuleGroupInput{ + ChangeToken: token, + RuleGroupId: aws.String(id), + Updates: diffWafRuleGroupActivatedRules(oldRules, newRules), + } + + return conn.UpdateRuleGroup(req) + }) + if err != nil { + return fmt.Errorf("Error Updating WAF Rule Group: %s", err) + } + + return nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_size_constraint_set.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_size_constraint_set.go index 8df37ab855bb..cc622854938b 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_size_constraint_set.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_size_constraint_set.go @@ -17,50 +17,7 @@ func resourceAwsWafSizeConstraintSet() *schema.Resource { Update: resourceAwsWafSizeConstraintSetUpdate, Delete: resourceAwsWafSizeConstraintSetDelete, - Schema: map[string]*schema.Schema{ - "name": &schema.Schema{ - Type: schema.TypeString, - Required: true, - ForceNew: true, - }, - "size_constraints": &schema.Schema{ - Type: schema.TypeSet, - Optional: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "field_to_match": { - Type: schema.TypeSet, - Required: true, - MaxItems: 1, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "data": { - Type: schema.TypeString, - Optional: true, - }, - "type": { - Type: schema.TypeString, - Required: true, - }, - }, - }, - }, - "comparison_operator": &schema.Schema{ - Type: schema.TypeString, - Required: true, - }, - "size": &schema.Schema{ - Type: schema.TypeInt, - Required: true, - }, - "text_transformation": &schema.Schema{ - Type: schema.TypeString, - Required: true, - }, - }, - }, - }, - }, + Schema: wafSizeConstraintSetSchema(), } } @@ -98,7 +55,7 @@ func resourceAwsWafSizeConstraintSetRead(d *schema.ResourceData, meta interface{ resp, err := conn.GetSizeConstraintSet(params) if err != nil { if awsErr, ok := err.(awserr.Error); ok && awsErr.Code() == "WAFNonexistentItemException" { - log.Printf("[WARN] WAF IPSet (%s) not found, removing from state", d.Id()) + log.Printf("[WARN] WAF SizeConstraintSet (%s) not found, removing from state", d.Id()) d.SetId("") return nil } @@ -117,9 +74,9 @@ func resourceAwsWafSizeConstraintSetUpdate(d *schema.ResourceData, meta interfac if d.HasChange("size_constraints") { o, n := d.GetChange("size_constraints") - oldS, newS := o.(*schema.Set).List(), n.(*schema.Set).List() + oldConstraints, newConstraints := o.(*schema.Set).List(), n.(*schema.Set).List() - err := updateSizeConstraintSetResource(d.Id(), oldS, newS, conn) + err := updateSizeConstraintSetResource(d.Id(), oldConstraints, newConstraints, conn) if err != nil { return errwrap.Wrapf("[ERROR] Error updating SizeConstraintSet: {{err}}", err) } @@ -174,56 +131,3 @@ func updateSizeConstraintSetResource(id string, oldS, newS []interface{}, conn * return nil } - -func flattenWafSizeConstraints(sc []*waf.SizeConstraint) []interface{} { - out := make([]interface{}, len(sc), len(sc)) - for i, c := range sc { - m := make(map[string]interface{}) - m["comparison_operator"] = *c.ComparisonOperator - if c.FieldToMatch != nil { - m["field_to_match"] = flattenFieldToMatch(c.FieldToMatch) - } - m["size"] = *c.Size - m["text_transformation"] = *c.TextTransformation - out[i] = m - } - return out -} - -func diffWafSizeConstraints(oldS, newS []interface{}) []*waf.SizeConstraintSetUpdate { - updates := make([]*waf.SizeConstraintSetUpdate, 0) - - for _, os := range oldS { - constraint := os.(map[string]interface{}) - - if idx, contains := sliceContainsMap(newS, constraint); contains { - newS = append(newS[:idx], newS[idx+1:]...) - continue - } - - updates = append(updates, &waf.SizeConstraintSetUpdate{ - Action: aws.String(waf.ChangeActionDelete), - SizeConstraint: &waf.SizeConstraint{ - FieldToMatch: expandFieldToMatch(constraint["field_to_match"].(*schema.Set).List()[0].(map[string]interface{})), - ComparisonOperator: aws.String(constraint["comparison_operator"].(string)), - Size: aws.Int64(int64(constraint["size"].(int))), - TextTransformation: aws.String(constraint["text_transformation"].(string)), - }, - }) - } - - for _, ns := range newS { - constraint := ns.(map[string]interface{}) - - updates = append(updates, &waf.SizeConstraintSetUpdate{ - Action: aws.String(waf.ChangeActionInsert), - SizeConstraint: &waf.SizeConstraint{ - FieldToMatch: expandFieldToMatch(constraint["field_to_match"].(*schema.Set).List()[0].(map[string]interface{})), - ComparisonOperator: aws.String(constraint["comparison_operator"].(string)), - Size: aws.Int64(int64(constraint["size"].(int))), - TextTransformation: aws.String(constraint["text_transformation"].(string)), - }, - }) - } - return updates -} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_web_acl.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_web_acl.go index 17b603f37bc7..92032a70245c 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_web_acl.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_waf_web_acl.go @@ -8,6 +8,7 @@ import ( "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/waf" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" ) func resourceAwsWafWebAcl() *schema.Resource { @@ -68,14 +69,10 @@ func resourceAwsWafWebAcl() *schema.Resource { Type: schema.TypeString, Optional: true, Default: waf.WafRuleTypeRegular, - ValidateFunc: func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != waf.WafRuleTypeRegular && value != waf.WafRuleTypeRateBased { - errors = append(errors, fmt.Errorf( - "%q must be one of %s | %s", k, waf.WafRuleTypeRegular, waf.WafRuleTypeRateBased)) - } - return - }, + ValidateFunc: validation.StringInSlice([]string{ + waf.WafRuleTypeRegular, + waf.WafRuleTypeRateBased, + }, false), }, "rule_id": &schema.Schema{ Type: schema.TypeString, diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_geo_match_set.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_geo_match_set.go new file mode 100644 index 000000000000..107640171ac9 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_geo_match_set.go @@ -0,0 +1,160 @@ +package aws + +import ( + "fmt" + "log" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/waf" + "github.com/aws/aws-sdk-go/service/wafregional" + "github.com/hashicorp/terraform/helper/schema" +) + +func resourceAwsWafRegionalGeoMatchSet() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsWafRegionalGeoMatchSetCreate, + Read: resourceAwsWafRegionalGeoMatchSetRead, + Update: resourceAwsWafRegionalGeoMatchSetUpdate, + Delete: resourceAwsWafRegionalGeoMatchSetDelete, + + Schema: map[string]*schema.Schema{ + "name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "geo_match_constraint": { + Type: schema.TypeSet, + Optional: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "type": { + Type: schema.TypeString, + Required: true, + }, + "value": { + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + }, + } +} + +func resourceAwsWafRegionalGeoMatchSetCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + log.Printf("[INFO] Creating WAF Regional Geo Match Set: %s", d.Get("name").(string)) + + wr := newWafRegionalRetryer(conn, region) + out, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + params := &waf.CreateGeoMatchSetInput{ + ChangeToken: token, + Name: aws.String(d.Get("name").(string)), + } + + return conn.CreateGeoMatchSet(params) + }) + if err != nil { + return fmt.Errorf("Failed creating WAF Regional Geo Match Set: %s", err) + } + resp := out.(*waf.CreateGeoMatchSetOutput) + + d.SetId(*resp.GeoMatchSet.GeoMatchSetId) + + return resourceAwsWafRegionalGeoMatchSetUpdate(d, meta) +} + +func resourceAwsWafRegionalGeoMatchSetRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + log.Printf("[INFO] Reading WAF Regional Geo Match Set: %s", d.Get("name").(string)) + params := &waf.GetGeoMatchSetInput{ + GeoMatchSetId: aws.String(d.Id()), + } + + resp, err := conn.GetGeoMatchSet(params) + if err != nil { + // TODO: Replace with constant once it's available + // See https://github.com/aws/aws-sdk-go/issues/1856 + if isAWSErr(err, "WAFNonexistentItemException", "") { + log.Printf("[WARN] WAF WAF Regional Geo Match Set (%s) not found, removing from state", d.Id()) + d.SetId("") + return nil + } + + return err + } + + d.Set("name", resp.GeoMatchSet.Name) + d.Set("geo_match_constraint", flattenWafGeoMatchConstraint(resp.GeoMatchSet.GeoMatchConstraints)) + + return nil +} + +func resourceAwsWafRegionalGeoMatchSetUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + if d.HasChange("geo_match_constraint") { + o, n := d.GetChange("geo_match_constraint") + oldConstraints, newConstraints := o.(*schema.Set).List(), n.(*schema.Set).List() + + err := updateGeoMatchSetResourceWR(d.Id(), oldConstraints, newConstraints, conn, region) + if err != nil { + return fmt.Errorf("Failed updating WAF Regional Geo Match Set: %s", err) + } + } + + return resourceAwsWafRegionalGeoMatchSetRead(d, meta) +} + +func resourceAwsWafRegionalGeoMatchSetDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + oldConstraints := d.Get("geo_match_constraint").(*schema.Set).List() + if len(oldConstraints) > 0 { + noConstraints := []interface{}{} + err := updateGeoMatchSetResourceWR(d.Id(), oldConstraints, noConstraints, conn, region) + if err != nil { + return fmt.Errorf("Error updating WAF Regional Geo Match Constraint: %s", err) + } + } + + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.DeleteGeoMatchSetInput{ + ChangeToken: token, + GeoMatchSetId: aws.String(d.Id()), + } + + return conn.DeleteGeoMatchSet(req) + }) + if err != nil { + return fmt.Errorf("Failed deleting WAF Regional Geo Match Set: %s", err) + } + + return nil +} + +func updateGeoMatchSetResourceWR(id string, oldConstraints, newConstraints []interface{}, conn *wafregional.WAFRegional, region string) error { + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.UpdateGeoMatchSetInput{ + ChangeToken: token, + GeoMatchSetId: aws.String(id), + Updates: diffWafGeoMatchSetConstraints(oldConstraints, newConstraints), + } + + log.Printf("[INFO] Updating WAF Regional Geo Match Set constraints: %s", req) + return conn.UpdateGeoMatchSet(req) + }) + if err != nil { + return fmt.Errorf("Failed updating WAF Regional Geo Match Set: %s", err) + } + + return nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_rate_based_rule.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_rate_based_rule.go new file mode 100644 index 000000000000..7e168a50debf --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_rate_based_rule.go @@ -0,0 +1,195 @@ +package aws + +import ( + "fmt" + "log" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/waf" + "github.com/aws/aws-sdk-go/service/wafregional" + "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" +) + +func resourceAwsWafRegionalRateBasedRule() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsWafRegionalRateBasedRuleCreate, + Read: resourceAwsWafRegionalRateBasedRuleRead, + Update: resourceAwsWafRegionalRateBasedRuleUpdate, + Delete: resourceAwsWafRegionalRateBasedRuleDelete, + + Schema: map[string]*schema.Schema{ + "name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "metric_name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validateWafMetricName, + }, + "predicate": { + Type: schema.TypeSet, + Optional: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "negated": { + Type: schema.TypeBool, + Required: true, + }, + "data_id": { + Type: schema.TypeString, + Required: true, + ValidateFunc: validateMaxLength(128), + }, + "type": { + Type: schema.TypeString, + Required: true, + ValidateFunc: validateWafPredicatesType(), + }, + }, + }, + }, + "rate_key": { + Type: schema.TypeString, + Required: true, + }, + "rate_limit": { + Type: schema.TypeInt, + Required: true, + ValidateFunc: validation.IntAtLeast(2000), + }, + }, + } +} + +func resourceAwsWafRegionalRateBasedRuleCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + wr := newWafRegionalRetryer(conn, region) + out, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + params := &waf.CreateRateBasedRuleInput{ + ChangeToken: token, + MetricName: aws.String(d.Get("metric_name").(string)), + Name: aws.String(d.Get("name").(string)), + RateKey: aws.String(d.Get("rate_key").(string)), + RateLimit: aws.Int64(int64(d.Get("rate_limit").(int))), + } + + return conn.CreateRateBasedRule(params) + }) + if err != nil { + return err + } + resp := out.(*waf.CreateRateBasedRuleOutput) + d.SetId(*resp.Rule.RuleId) + return resourceAwsWafRegionalRateBasedRuleUpdate(d, meta) +} + +func resourceAwsWafRegionalRateBasedRuleRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + + params := &waf.GetRateBasedRuleInput{ + RuleId: aws.String(d.Id()), + } + + resp, err := conn.GetRateBasedRule(params) + if err != nil { + if isAWSErr(err, wafregional.ErrCodeWAFNonexistentItemException, "") { + log.Printf("[WARN] WAF Regional Rate Based Rule (%s) not found, removing from state", d.Id()) + d.SetId("") + return nil + } + + return err + } + + var predicates []map[string]interface{} + + for _, predicateSet := range resp.Rule.MatchPredicates { + predicates = append(predicates, map[string]interface{}{ + "negated": *predicateSet.Negated, + "type": *predicateSet.Type, + "data_id": *predicateSet.DataId, + }) + } + + d.Set("predicate", predicates) + d.Set("name", resp.Rule.Name) + d.Set("metric_name", resp.Rule.MetricName) + d.Set("rate_key", resp.Rule.RateKey) + d.Set("rate_limit", resp.Rule.RateLimit) + + return nil +} + +func resourceAwsWafRegionalRateBasedRuleUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + if d.HasChange("predicate") { + o, n := d.GetChange("predicate") + oldP, newP := o.(*schema.Set).List(), n.(*schema.Set).List() + rateLimit := d.Get("rate_limit") + + err := updateWafRateBasedRuleResourceWR(d.Id(), oldP, newP, rateLimit, conn, region) + if err != nil { + return fmt.Errorf("Error Updating WAF Rule: %s", err) + } + } + + return resourceAwsWafRegionalRateBasedRuleRead(d, meta) +} + +func resourceAwsWafRegionalRateBasedRuleDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + oldPredicates := d.Get("predicate").(*schema.Set).List() + if len(oldPredicates) > 0 { + noPredicates := []interface{}{} + rateLimit := d.Get("rate_limit") + + err := updateWafRateBasedRuleResourceWR(d.Id(), oldPredicates, noPredicates, rateLimit, conn, region) + if err != nil { + return fmt.Errorf("Error updating WAF Regional Rate Based Rule Predicates: %s", err) + } + } + + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.DeleteRateBasedRuleInput{ + ChangeToken: token, + RuleId: aws.String(d.Id()), + } + log.Printf("[INFO] Deleting WAF Regional Rate Based Rule") + return conn.DeleteRateBasedRule(req) + }) + if err != nil { + return fmt.Errorf("Error deleting WAF Regional Rate Based Rule: %s", err) + } + + return nil +} + +func updateWafRateBasedRuleResourceWR(id string, oldP, newP []interface{}, rateLimit interface{}, conn *wafregional.WAFRegional, region string) error { + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.UpdateRateBasedRuleInput{ + ChangeToken: token, + RuleId: aws.String(id), + Updates: diffWafRulePredicates(oldP, newP), + RateLimit: aws.Int64(int64(rateLimit.(int))), + } + + return conn.UpdateRateBasedRule(req) + }) + if err != nil { + return fmt.Errorf("Error Updating WAF Regional Rate Based Rule: %s", err) + } + + return nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_regex_match_set.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_regex_match_set.go new file mode 100644 index 000000000000..b1c9d10d08db --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_regex_match_set.go @@ -0,0 +1,179 @@ +package aws + +import ( + "fmt" + "log" + "strings" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/waf" + "github.com/aws/aws-sdk-go/service/wafregional" + "github.com/hashicorp/terraform/helper/schema" +) + +func resourceAwsWafRegionalRegexMatchSet() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsWafRegionalRegexMatchSetCreate, + Read: resourceAwsWafRegionalRegexMatchSetRead, + Update: resourceAwsWafRegionalRegexMatchSetUpdate, + Delete: resourceAwsWafRegionalRegexMatchSetDelete, + + Schema: map[string]*schema.Schema{ + "name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "regex_match_tuple": { + Type: schema.TypeSet, + Optional: true, + Set: resourceAwsWafRegexMatchSetTupleHash, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "field_to_match": { + Type: schema.TypeList, + Required: true, + MaxItems: 1, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "data": { + Type: schema.TypeString, + Optional: true, + StateFunc: func(v interface{}) string { + return strings.ToLower(v.(string)) + }, + }, + "type": { + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + "regex_pattern_set_id": { + Type: schema.TypeString, + Required: true, + }, + "text_transformation": { + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + }, + } +} + +func resourceAwsWafRegionalRegexMatchSetCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + log.Printf("[INFO] Creating WAF Regional Regex Match Set: %s", d.Get("name").(string)) + + wr := newWafRegionalRetryer(conn, region) + out, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + params := &waf.CreateRegexMatchSetInput{ + ChangeToken: token, + Name: aws.String(d.Get("name").(string)), + } + return conn.CreateRegexMatchSet(params) + }) + if err != nil { + return fmt.Errorf("Failed creating WAF Regional Regex Match Set: %s", err) + } + resp := out.(*waf.CreateRegexMatchSetOutput) + + d.SetId(*resp.RegexMatchSet.RegexMatchSetId) + + return resourceAwsWafRegionalRegexMatchSetUpdate(d, meta) +} + +func resourceAwsWafRegionalRegexMatchSetRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + log.Printf("[INFO] Reading WAF Regional Regex Match Set: %s", d.Get("name").(string)) + params := &waf.GetRegexMatchSetInput{ + RegexMatchSetId: aws.String(d.Id()), + } + + resp, err := conn.GetRegexMatchSet(params) + if err != nil { + if isAWSErr(err, wafregional.ErrCodeWAFNonexistentItemException, "") { + log.Printf("[WARN] WAF Regional Regex Match Set (%s) not found, removing from state", d.Id()) + d.SetId("") + return nil + } + + return err + } + + d.Set("name", resp.RegexMatchSet.Name) + d.Set("regex_match_tuple", flattenWafRegexMatchTuples(resp.RegexMatchSet.RegexMatchTuples)) + + return nil +} + +func resourceAwsWafRegionalRegexMatchSetUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + log.Printf("[INFO] Updating WAF Regional Regex Match Set: %s", d.Get("name").(string)) + + if d.HasChange("regex_match_tuple") { + o, n := d.GetChange("regex_match_tuple") + oldT, newT := o.(*schema.Set).List(), n.(*schema.Set).List() + err := updateRegexMatchSetResourceWR(d.Id(), oldT, newT, conn, region) + if err != nil { + return fmt.Errorf("Failed updating WAF Regional Regex Match Set: %s", err) + } + } + + return resourceAwsWafRegionalRegexMatchSetRead(d, meta) +} + +func resourceAwsWafRegionalRegexMatchSetDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + oldTuples := d.Get("regex_match_tuple").(*schema.Set).List() + if len(oldTuples) > 0 { + noTuples := []interface{}{} + err := updateRegexMatchSetResourceWR(d.Id(), oldTuples, noTuples, conn, region) + if err != nil { + return fmt.Errorf("Error updating WAF Regional Regex Match Set: %s", err) + } + } + + wr := newWafRegionalRetryer(conn, "global") + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.DeleteRegexMatchSetInput{ + ChangeToken: token, + RegexMatchSetId: aws.String(d.Id()), + } + log.Printf("[INFO] Deleting WAF Regional Regex Match Set: %s", req) + return conn.DeleteRegexMatchSet(req) + }) + if err != nil { + return fmt.Errorf("Failed deleting WAF Regional Regex Match Set: %s", err) + } + + return nil +} + +func updateRegexMatchSetResourceWR(id string, oldT, newT []interface{}, conn *wafregional.WAFRegional, region string) error { + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.UpdateRegexMatchSetInput{ + ChangeToken: token, + RegexMatchSetId: aws.String(id), + Updates: diffWafRegexMatchSetTuples(oldT, newT), + } + + return conn.UpdateRegexMatchSet(req) + }) + if err != nil { + return fmt.Errorf("Failed updating WAF Regional Regex Match Set: %s", err) + } + + return nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_regex_pattern_set.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_regex_pattern_set.go new file mode 100644 index 000000000000..6f311b325858 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_regex_pattern_set.go @@ -0,0 +1,147 @@ +package aws + +import ( + "fmt" + "log" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/waf" + "github.com/aws/aws-sdk-go/service/wafregional" + "github.com/hashicorp/terraform/helper/schema" +) + +func resourceAwsWafRegionalRegexPatternSet() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsWafRegionalRegexPatternSetCreate, + Read: resourceAwsWafRegionalRegexPatternSetRead, + Update: resourceAwsWafRegionalRegexPatternSetUpdate, + Delete: resourceAwsWafRegionalRegexPatternSetDelete, + + Schema: map[string]*schema.Schema{ + "name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "regex_pattern_strings": { + Type: schema.TypeSet, + Optional: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + }, + } +} + +func resourceAwsWafRegionalRegexPatternSetCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + log.Printf("[INFO] Creating WAF Regional Regex Pattern Set: %s", d.Get("name").(string)) + + wr := newWafRegionalRetryer(conn, region) + out, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + params := &waf.CreateRegexPatternSetInput{ + ChangeToken: token, + Name: aws.String(d.Get("name").(string)), + } + return conn.CreateRegexPatternSet(params) + }) + if err != nil { + return fmt.Errorf("Failed creating WAF Regional Regex Pattern Set: %s", err) + } + resp := out.(*waf.CreateRegexPatternSetOutput) + + d.SetId(*resp.RegexPatternSet.RegexPatternSetId) + + return resourceAwsWafRegionalRegexPatternSetUpdate(d, meta) +} + +func resourceAwsWafRegionalRegexPatternSetRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + + log.Printf("[INFO] Reading WAF Regional Regex Pattern Set: %s", d.Get("name").(string)) + params := &waf.GetRegexPatternSetInput{ + RegexPatternSetId: aws.String(d.Id()), + } + + resp, err := conn.GetRegexPatternSet(params) + if err != nil { + if isAWSErr(err, wafregional.ErrCodeWAFNonexistentItemException, "") { + log.Printf("[WARN] WAF Regional Regex Pattern Set (%s) not found, removing from state", d.Id()) + d.SetId("") + return nil + } + + return err + } + + d.Set("name", resp.RegexPatternSet.Name) + d.Set("regex_pattern_strings", aws.StringValueSlice(resp.RegexPatternSet.RegexPatternStrings)) + + return nil +} + +func resourceAwsWafRegionalRegexPatternSetUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + log.Printf("[INFO] Updating WAF Regional Regex Pattern Set: %s", d.Get("name").(string)) + + if d.HasChange("regex_pattern_strings") { + o, n := d.GetChange("regex_pattern_strings") + oldPatterns, newPatterns := o.(*schema.Set).List(), n.(*schema.Set).List() + err := updateWafRegionalRegexPatternSetPatternStringsWR(d.Id(), oldPatterns, newPatterns, conn, region) + if err != nil { + return fmt.Errorf("Failed updating WAF Regional Regex Pattern Set: %s", err) + } + } + + return resourceAwsWafRegionalRegexPatternSetRead(d, meta) +} + +func resourceAwsWafRegionalRegexPatternSetDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + oldPatterns := d.Get("regex_pattern_strings").(*schema.Set).List() + if len(oldPatterns) > 0 { + noPatterns := []interface{}{} + err := updateWafRegionalRegexPatternSetPatternStringsWR(d.Id(), oldPatterns, noPatterns, conn, region) + if err != nil { + return fmt.Errorf("Error updating WAF Regional Regex Pattern Set: %s", err) + } + } + + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.DeleteRegexPatternSetInput{ + ChangeToken: token, + RegexPatternSetId: aws.String(d.Id()), + } + log.Printf("[INFO] Deleting WAF Regional Regex Pattern Set: %s", req) + return conn.DeleteRegexPatternSet(req) + }) + if err != nil { + return fmt.Errorf("Failed deleting WAF Regional Regex Pattern Set: %s", err) + } + + return nil +} + +func updateWafRegionalRegexPatternSetPatternStringsWR(id string, oldPatterns, newPatterns []interface{}, conn *wafregional.WAFRegional, region string) error { + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.UpdateRegexPatternSetInput{ + ChangeToken: token, + RegexPatternSetId: aws.String(id), + Updates: diffWafRegexPatternSetPatternStrings(oldPatterns, newPatterns), + } + + return conn.UpdateRegexPatternSet(req) + }) + if err != nil { + return fmt.Errorf("Failed updating WAF Regional Regex Pattern Set: %s", err) + } + + return nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_rule.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_rule.go new file mode 100644 index 000000000000..10de0664f972 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_rule.go @@ -0,0 +1,188 @@ +package aws + +import ( + "fmt" + "log" + + "github.com/aws/aws-sdk-go/service/wafregional" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/waf" + "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" +) + +func resourceAwsWafRegionalRule() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsWafRegionalRuleCreate, + Read: resourceAwsWafRegionalRuleRead, + Update: resourceAwsWafRegionalRuleUpdate, + Delete: resourceAwsWafRegionalRuleDelete, + + Schema: map[string]*schema.Schema{ + "name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "metric_name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "predicate": &schema.Schema{ + Type: schema.TypeSet, + Optional: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "negated": &schema.Schema{ + Type: schema.TypeBool, + Required: true, + }, + "data_id": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringLenBetween(1, 128), + }, + "type": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ValidateFunc: validation.StringInSlice([]string{ + wafregional.PredicateTypeByteMatch, + wafregional.PredicateTypeGeoMatch, + wafregional.PredicateTypeIpmatch, + wafregional.PredicateTypeRegexMatch, + wafregional.PredicateTypeSizeConstraint, + wafregional.PredicateTypeSqlInjectionMatch, + wafregional.PredicateTypeXssMatch, + }, false), + }, + }, + }, + }, + }, + } +} + +func resourceAwsWafRegionalRuleCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + wr := newWafRegionalRetryer(conn, region) + out, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + params := &waf.CreateRuleInput{ + ChangeToken: token, + MetricName: aws.String(d.Get("metric_name").(string)), + Name: aws.String(d.Get("name").(string)), + } + + return conn.CreateRule(params) + }) + if err != nil { + return err + } + resp := out.(*waf.CreateRuleOutput) + d.SetId(*resp.Rule.RuleId) + return resourceAwsWafRegionalRuleUpdate(d, meta) +} + +func resourceAwsWafRegionalRuleRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + + params := &waf.GetRuleInput{ + RuleId: aws.String(d.Id()), + } + + resp, err := conn.GetRule(params) + if err != nil { + if isAWSErr(err, wafregional.ErrCodeWAFNonexistentItemException, "") { + log.Printf("[WARN] WAF Rule (%s) not found, error code (404)", d.Id()) + d.SetId("") + return nil + } + + return err + } + + d.Set("predicate", flattenWafPredicates(resp.Rule.Predicates)) + d.Set("name", resp.Rule.Name) + d.Set("metric_name", resp.Rule.MetricName) + + return nil +} + +func resourceAwsWafRegionalRuleUpdate(d *schema.ResourceData, meta interface{}) error { + if d.HasChange("predicate") { + o, n := d.GetChange("predicate") + oldP, newP := o.(*schema.Set).List(), n.(*schema.Set).List() + + err := updateWafRegionalRuleResource(d.Id(), oldP, newP, meta) + if err != nil { + return fmt.Errorf("Error Updating WAF Rule: %s", err) + } + } + return resourceAwsWafRegionalRuleRead(d, meta) +} + +func resourceAwsWafRegionalRuleDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + oldPredicates := d.Get("predicate").(*schema.Set).List() + if len(oldPredicates) > 0 { + noPredicates := []interface{}{} + err := updateWafRegionalRuleResource(d.Id(), oldPredicates, noPredicates, meta) + if err != nil { + return fmt.Errorf("Error Removing WAF Rule Predicates: %s", err) + } + } + + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.DeleteRuleInput{ + ChangeToken: token, + RuleId: aws.String(d.Id()), + } + log.Printf("[INFO] Deleting WAF Rule") + return conn.DeleteRule(req) + }) + if err != nil { + return fmt.Errorf("Error deleting WAF Rule: %s", err) + } + + return nil +} + +func updateWafRegionalRuleResource(id string, oldP, newP []interface{}, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.UpdateRuleInput{ + ChangeToken: token, + RuleId: aws.String(id), + Updates: diffWafRulePredicates(oldP, newP), + } + + return conn.UpdateRule(req) + }) + + if err != nil { + return fmt.Errorf("Error Updating WAF Rule: %s", err) + } + + return nil +} + +func flattenWafPredicates(ts []*waf.Predicate) []interface{} { + out := make([]interface{}, len(ts), len(ts)) + for i, p := range ts { + m := make(map[string]interface{}) + m["negated"] = *p.Negated + m["type"] = *p.Type + m["data_id"] = *p.DataId + out[i] = m + } + return out +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_rule_group.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_rule_group.go new file mode 100644 index 000000000000..c170f3ac9dc2 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_rule_group.go @@ -0,0 +1,191 @@ +package aws + +import ( + "fmt" + "log" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/waf" + "github.com/aws/aws-sdk-go/service/wafregional" + "github.com/hashicorp/terraform/helper/schema" +) + +func resourceAwsWafRegionalRuleGroup() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsWafRegionalRuleGroupCreate, + Read: resourceAwsWafRegionalRuleGroupRead, + Update: resourceAwsWafRegionalRuleGroupUpdate, + Delete: resourceAwsWafRegionalRuleGroupDelete, + + Schema: map[string]*schema.Schema{ + "name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "metric_name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: validateWafMetricName, + }, + "activated_rule": { + Type: schema.TypeSet, + Optional: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "action": { + Type: schema.TypeList, + MaxItems: 1, + Required: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "type": { + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + "priority": { + Type: schema.TypeInt, + Required: true, + }, + "rule_id": { + Type: schema.TypeString, + Required: true, + }, + "type": { + Type: schema.TypeString, + Optional: true, + Default: wafregional.WafRuleTypeRegular, + }, + }, + }, + }, + }, + } +} + +func resourceAwsWafRegionalRuleGroupCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + wr := newWafRegionalRetryer(conn, region) + out, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + params := &waf.CreateRuleGroupInput{ + ChangeToken: token, + MetricName: aws.String(d.Get("metric_name").(string)), + Name: aws.String(d.Get("name").(string)), + } + + return conn.CreateRuleGroup(params) + }) + if err != nil { + return err + } + resp := out.(*waf.CreateRuleGroupOutput) + d.SetId(*resp.RuleGroup.RuleGroupId) + return resourceAwsWafRegionalRuleGroupUpdate(d, meta) +} + +func resourceAwsWafRegionalRuleGroupRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + + params := &waf.GetRuleGroupInput{ + RuleGroupId: aws.String(d.Id()), + } + + resp, err := conn.GetRuleGroup(params) + if err != nil { + if isAWSErr(err, wafregional.ErrCodeWAFNonexistentItemException, "") { + log.Printf("[WARN] WAF Regional Rule Group (%s) not found, removing from state", d.Id()) + d.SetId("") + return nil + } + + return err + } + + rResp, err := conn.ListActivatedRulesInRuleGroup(&waf.ListActivatedRulesInRuleGroupInput{ + RuleGroupId: aws.String(d.Id()), + }) + + d.Set("activated_rule", flattenWafActivatedRules(rResp.ActivatedRules)) + d.Set("name", resp.RuleGroup.Name) + d.Set("metric_name", resp.RuleGroup.MetricName) + + return nil +} + +func resourceAwsWafRegionalRuleGroupUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + if d.HasChange("activated_rule") { + o, n := d.GetChange("activated_rule") + oldRules, newRules := o.(*schema.Set).List(), n.(*schema.Set).List() + + err := updateWafRuleGroupResourceWR(d.Id(), oldRules, newRules, conn, region) + if err != nil { + return fmt.Errorf("Error Updating WAF Regional Rule Group: %s", err) + } + } + + return resourceAwsWafRegionalRuleGroupRead(d, meta) +} + +func resourceAwsWafRegionalRuleGroupDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + oldRules := d.Get("activated_rule").(*schema.Set).List() + err := deleteWafRegionalRuleGroup(d.Id(), oldRules, conn, region) + if err != nil { + return err + } + + return nil +} + +func deleteWafRegionalRuleGroup(id string, oldRules []interface{}, conn *wafregional.WAFRegional, region string) error { + if len(oldRules) > 0 { + noRules := []interface{}{} + err := updateWafRuleGroupResourceWR(id, oldRules, noRules, conn, region) + if err != nil { + return fmt.Errorf("Error updating WAF Regional Rule Group Predicates: %s", err) + } + } + + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.DeleteRuleGroupInput{ + ChangeToken: token, + RuleGroupId: aws.String(id), + } + log.Printf("[INFO] Deleting WAF Regional Rule Group") + return conn.DeleteRuleGroup(req) + }) + if err != nil { + return fmt.Errorf("Error deleting WAF Regional Rule Group: %s", err) + } + return nil +} + +func updateWafRuleGroupResourceWR(id string, oldRules, newRules []interface{}, conn *wafregional.WAFRegional, region string) error { + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.UpdateRuleGroupInput{ + ChangeToken: token, + RuleGroupId: aws.String(id), + Updates: diffWafRuleGroupActivatedRules(oldRules, newRules), + } + + return conn.UpdateRuleGroup(req) + }) + if err != nil { + return fmt.Errorf("Error Updating WAF Regional Rule Group: %s", err) + } + + return nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_size_constraint_set.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_size_constraint_set.go new file mode 100644 index 000000000000..6298666db348 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_size_constraint_set.go @@ -0,0 +1,135 @@ +package aws + +import ( + "fmt" + "log" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/waf" + "github.com/aws/aws-sdk-go/service/wafregional" + "github.com/hashicorp/terraform/helper/schema" +) + +func resourceAwsWafRegionalSizeConstraintSet() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsWafRegionalSizeConstraintSetCreate, + Read: resourceAwsWafRegionalSizeConstraintSetRead, + Update: resourceAwsWafRegionalSizeConstraintSetUpdate, + Delete: resourceAwsWafRegionalSizeConstraintSetDelete, + + Schema: wafSizeConstraintSetSchema(), + } +} + +func resourceAwsWafRegionalSizeConstraintSetCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + name := d.Get("name").(string) + + log.Printf("[INFO] Creating WAF Regional SizeConstraintSet: %s", name) + + wr := newWafRegionalRetryer(conn, region) + out, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + params := &waf.CreateSizeConstraintSetInput{ + ChangeToken: token, + Name: aws.String(name), + } + + return conn.CreateSizeConstraintSet(params) + }) + if err != nil { + return fmt.Errorf("[ERROR] Error creating WAF Regional SizeConstraintSet: %s", err) + } + resp := out.(*waf.CreateSizeConstraintSetOutput) + + d.SetId(*resp.SizeConstraintSet.SizeConstraintSetId) + + return resourceAwsWafRegionalSizeConstraintSetUpdate(d, meta) +} + +func resourceAwsWafRegionalSizeConstraintSetRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + + log.Printf("[INFO] Reading WAF Regional SizeConstraintSet: %s", d.Get("name").(string)) + params := &waf.GetSizeConstraintSetInput{ + SizeConstraintSetId: aws.String(d.Id()), + } + + resp, err := conn.GetSizeConstraintSet(params) + if err != nil { + if isAWSErr(err, wafregional.ErrCodeWAFNonexistentItemException, "") { + log.Printf("[WARN] WAF Regional SizeConstraintSet (%s) not found, removing from state", d.Id()) + d.SetId("") + return nil + } + return err + } + + d.Set("name", resp.SizeConstraintSet.Name) + d.Set("size_constraints", flattenWafSizeConstraints(resp.SizeConstraintSet.SizeConstraints)) + + return nil +} + +func resourceAwsWafRegionalSizeConstraintSetUpdate(d *schema.ResourceData, meta interface{}) error { + client := meta.(*AWSClient) + + if d.HasChange("size_constraints") { + o, n := d.GetChange("size_constraints") + oldConstraints, newConstraints := o.(*schema.Set).List(), n.(*schema.Set).List() + + if err := updateRegionalSizeConstraintSetResource(d.Id(), oldConstraints, newConstraints, client.wafregionalconn, client.region); err != nil { + return fmt.Errorf("[ERROR] Error updating WAF Regional SizeConstraintSet: %s", err) + } + } + + return resourceAwsWafRegionalSizeConstraintSetRead(d, meta) +} + +func resourceAwsWafRegionalSizeConstraintSetDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + oldConstraints := d.Get("size_constraints").(*schema.Set).List() + + if len(oldConstraints) > 0 { + noConstraints := []interface{}{} + if err := updateRegionalSizeConstraintSetResource(d.Id(), oldConstraints, noConstraints, conn, region); err != nil { + return fmt.Errorf("[ERROR] Error deleting WAF Regional SizeConstraintSet: %s", err) + } + } + + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.DeleteSizeConstraintSetInput{ + ChangeToken: token, + SizeConstraintSetId: aws.String(d.Id()), + } + return conn.DeleteSizeConstraintSet(req) + }) + if err != nil { + return fmt.Errorf("[ERROR] Error deleting WAF Regional SizeConstraintSet: %s", err) + } + + return nil +} + +func updateRegionalSizeConstraintSetResource(id string, oldConstraints, newConstraints []interface{}, conn *wafregional.WAFRegional, region string) error { + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.UpdateSizeConstraintSetInput{ + ChangeToken: token, + SizeConstraintSetId: aws.String(id), + Updates: diffWafSizeConstraints(oldConstraints, newConstraints), + } + + log.Printf("[INFO] Updating WAF Regional SizeConstraintSet: %s", req) + return conn.UpdateSizeConstraintSet(req) + }) + if err != nil { + return fmt.Errorf("[ERROR] Error updating WAF Regional SizeConstraintSet: %s", err) + } + + return nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_sql_injection_match_set.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_sql_injection_match_set.go new file mode 100644 index 000000000000..f7d23c9c2a66 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_sql_injection_match_set.go @@ -0,0 +1,233 @@ +package aws + +import ( + "bytes" + "fmt" + "log" + "strings" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/waf" + "github.com/aws/aws-sdk-go/service/wafregional" + "github.com/hashicorp/terraform/helper/hashcode" + "github.com/hashicorp/terraform/helper/schema" +) + +func resourceAwsWafRegionalSqlInjectionMatchSet() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsWafRegionalSqlInjectionMatchSetCreate, + Read: resourceAwsWafRegionalSqlInjectionMatchSetRead, + Update: resourceAwsWafRegionalSqlInjectionMatchSetUpdate, + Delete: resourceAwsWafRegionalSqlInjectionMatchSetDelete, + + Schema: map[string]*schema.Schema{ + "name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "sql_injection_match_tuple": { + Type: schema.TypeSet, + Optional: true, + Set: resourceAwsWafRegionalSqlInjectionMatchSetTupleHash, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "field_to_match": { + Type: schema.TypeList, + Required: true, + MaxItems: 1, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "data": { + Type: schema.TypeString, + Optional: true, + StateFunc: func(v interface{}) string { + value := v.(string) + return strings.ToLower(value) + }, + }, + "type": { + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + "text_transformation": { + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + }, + } +} + +func resourceAwsWafRegionalSqlInjectionMatchSetCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + log.Printf("[INFO] Creating Regional WAF SQL Injection Match Set: %s", d.Get("name").(string)) + + wr := newWafRegionalRetryer(conn, region) + out, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + params := &waf.CreateSqlInjectionMatchSetInput{ + ChangeToken: token, + Name: aws.String(d.Get("name").(string)), + } + + return conn.CreateSqlInjectionMatchSet(params) + }) + if err != nil { + return fmt.Errorf("Failed creating Regional WAF SQL Injection Match Set: %s", err) + } + resp := out.(*waf.CreateSqlInjectionMatchSetOutput) + d.SetId(*resp.SqlInjectionMatchSet.SqlInjectionMatchSetId) + + return resourceAwsWafRegionalSqlInjectionMatchSetUpdate(d, meta) +} + +func resourceAwsWafRegionalSqlInjectionMatchSetRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + log.Printf("[INFO] Reading Regional WAF SQL Injection Match Set: %s", d.Get("name").(string)) + params := &waf.GetSqlInjectionMatchSetInput{ + SqlInjectionMatchSetId: aws.String(d.Id()), + } + + resp, err := conn.GetSqlInjectionMatchSet(params) + if err != nil { + if isAWSErr(err, wafregional.ErrCodeWAFNonexistentItemException, "") { + log.Printf("[WARN] Regional WAF SQL Injection Match Set (%s) not found, error code (404)", d.Id()) + d.SetId("") + return nil + } + + return err + } + + d.Set("name", resp.SqlInjectionMatchSet.Name) + d.Set("sql_injection_match_tuple", flattenWafSqlInjectionMatchTuples(resp.SqlInjectionMatchSet.SqlInjectionMatchTuples)) + + return nil +} + +func resourceAwsWafRegionalSqlInjectionMatchSetUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + if d.HasChange("sql_injection_match_tuple") { + o, n := d.GetChange("sql_injection_match_tuple") + oldT, newT := o.(*schema.Set).List(), n.(*schema.Set).List() + + err := updateSqlInjectionMatchSetResourceWR(d.Id(), oldT, newT, conn, region) + if err != nil { + return fmt.Errorf("[ERROR] Error updating Regional WAF SQL Injection Match Set: %s", err) + } + } + + return resourceAwsWafRegionalSqlInjectionMatchSetRead(d, meta) +} + +func resourceAwsWafRegionalSqlInjectionMatchSetDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + oldTuples := d.Get("sql_injection_match_tuple").(*schema.Set).List() + + if len(oldTuples) > 0 { + noTuples := []interface{}{} + err := updateSqlInjectionMatchSetResourceWR(d.Id(), oldTuples, noTuples, conn, region) + if err != nil { + return fmt.Errorf("[ERROR] Error deleting Regional WAF SQL Injection Match Set: %s", err) + } + } + + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.DeleteSqlInjectionMatchSetInput{ + ChangeToken: token, + SqlInjectionMatchSetId: aws.String(d.Id()), + } + + return conn.DeleteSqlInjectionMatchSet(req) + }) + if err != nil { + return fmt.Errorf("Failed deleting Regional WAF SQL Injection Match Set: %s", err) + } + + return nil +} + +func updateSqlInjectionMatchSetResourceWR(id string, oldT, newT []interface{}, conn *wafregional.WAFRegional, region string) error { + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.UpdateSqlInjectionMatchSetInput{ + ChangeToken: token, + SqlInjectionMatchSetId: aws.String(id), + Updates: diffWafSqlInjectionMatchTuplesWR(oldT, newT), + } + + log.Printf("[INFO] Updating Regional WAF SQL Injection Match Set: %s", req) + return conn.UpdateSqlInjectionMatchSet(req) + }) + if err != nil { + return fmt.Errorf("Failed updating Regional WAF SQL Injection Match Set: %s", err) + } + + return nil +} + +func diffWafSqlInjectionMatchTuplesWR(oldT, newT []interface{}) []*waf.SqlInjectionMatchSetUpdate { + updates := make([]*waf.SqlInjectionMatchSetUpdate, 0) + + for _, od := range oldT { + tuple := od.(map[string]interface{}) + + if idx, contains := sliceContainsMap(newT, tuple); contains { + newT = append(newT[:idx], newT[idx+1:]...) + continue + } + + ftm := tuple["field_to_match"].([]interface{}) + + updates = append(updates, &waf.SqlInjectionMatchSetUpdate{ + Action: aws.String(waf.ChangeActionDelete), + SqlInjectionMatchTuple: &waf.SqlInjectionMatchTuple{ + FieldToMatch: expandFieldToMatch(ftm[0].(map[string]interface{})), + TextTransformation: aws.String(tuple["text_transformation"].(string)), + }, + }) + } + + for _, nd := range newT { + tuple := nd.(map[string]interface{}) + ftm := tuple["field_to_match"].([]interface{}) + + updates = append(updates, &waf.SqlInjectionMatchSetUpdate{ + Action: aws.String(waf.ChangeActionInsert), + SqlInjectionMatchTuple: &waf.SqlInjectionMatchTuple{ + FieldToMatch: expandFieldToMatch(ftm[0].(map[string]interface{})), + TextTransformation: aws.String(tuple["text_transformation"].(string)), + }, + }) + } + return updates +} + +func resourceAwsWafRegionalSqlInjectionMatchSetTupleHash(v interface{}) int { + var buf bytes.Buffer + m := v.(map[string]interface{}) + if v, ok := m["field_to_match"]; ok { + ftms := v.([]interface{}) + ftm := ftms[0].(map[string]interface{}) + + if v, ok := ftm["data"]; ok { + buf.WriteString(fmt.Sprintf("%s-", strings.ToLower(v.(string)))) + } + buf.WriteString(fmt.Sprintf("%s-", ftm["type"].(string))) + } + buf.WriteString(fmt.Sprintf("%s-", m["text_transformation"].(string))) + + return hashcode.String(buf.String()) +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_web_acl.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_web_acl.go new file mode 100644 index 000000000000..d466b14d95d0 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_web_acl.go @@ -0,0 +1,266 @@ +package aws + +import ( + "fmt" + "log" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/waf" + "github.com/aws/aws-sdk-go/service/wafregional" + "github.com/hashicorp/terraform/helper/schema" +) + +func resourceAwsWafRegionalWebAcl() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsWafRegionalWebAclCreate, + Read: resourceAwsWafRegionalWebAclRead, + Update: resourceAwsWafRegionalWebAclUpdate, + Delete: resourceAwsWafRegionalWebAclDelete, + + Schema: map[string]*schema.Schema{ + "name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "default_action": &schema.Schema{ + Type: schema.TypeList, + Required: true, + MaxItems: 1, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "type": &schema.Schema{ + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + "metric_name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "rule": &schema.Schema{ + Type: schema.TypeSet, + Optional: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "action": &schema.Schema{ + Type: schema.TypeList, + Required: true, + MaxItems: 1, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "type": &schema.Schema{ + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + "priority": &schema.Schema{ + Type: schema.TypeInt, + Required: true, + }, + "rule_id": &schema.Schema{ + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + }, + } +} + +func resourceAwsWafRegionalWebAclCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + wr := newWafRegionalRetryer(conn, region) + out, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + params := &waf.CreateWebACLInput{ + ChangeToken: token, + DefaultAction: expandDefaultActionWR(d.Get("default_action").([]interface{})), + MetricName: aws.String(d.Get("metric_name").(string)), + Name: aws.String(d.Get("name").(string)), + } + + return conn.CreateWebACL(params) + }) + if err != nil { + return err + } + resp := out.(*waf.CreateWebACLOutput) + d.SetId(*resp.WebACL.WebACLId) + return resourceAwsWafRegionalWebAclUpdate(d, meta) +} + +func resourceAwsWafRegionalWebAclRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + params := &waf.GetWebACLInput{ + WebACLId: aws.String(d.Id()), + } + + resp, err := conn.GetWebACL(params) + if err != nil { + if isAWSErr(err, wafregional.ErrCodeWAFNonexistentItemException, "") { + log.Printf("[WARN] WAF Regional ACL (%s) not found, error code (404)", d.Id()) + d.SetId("") + return nil + } + + return err + } + + d.Set("default_action", flattenDefaultActionWR(resp.WebACL.DefaultAction)) + d.Set("name", resp.WebACL.Name) + d.Set("metric_name", resp.WebACL.MetricName) + d.Set("rule", flattenWafWebAclRules(resp.WebACL.Rules)) + + return nil +} + +func resourceAwsWafRegionalWebAclUpdate(d *schema.ResourceData, meta interface{}) error { + if d.HasChange("default_action") || d.HasChange("rule") { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + action := expandDefaultActionWR(d.Get("default_action").([]interface{})) + o, n := d.GetChange("rule") + oldR, newR := o.(*schema.Set).List(), n.(*schema.Set).List() + + err := updateWebAclResourceWR(d.Id(), action, oldR, newR, conn, region) + if err != nil { + return fmt.Errorf("Error Updating WAF Regional ACL: %s", err) + } + } + return resourceAwsWafRegionalWebAclRead(d, meta) +} + +func resourceAwsWafRegionalWebAclDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + action := expandDefaultActionWR(d.Get("default_action").([]interface{})) + rules := d.Get("rule").(*schema.Set).List() + if len(rules) > 0 { + noRules := []interface{}{} + err := updateWebAclResourceWR(d.Id(), action, rules, noRules, conn, region) + if err != nil { + return fmt.Errorf("Error Removing WAF Regional ACL Rules: %s", err) + } + } + + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.DeleteWebACLInput{ + ChangeToken: token, + WebACLId: aws.String(d.Id()), + } + + log.Printf("[INFO] Deleting WAF ACL") + return conn.DeleteWebACL(req) + }) + if err != nil { + return fmt.Errorf("Error Deleting WAF Regional ACL: %s", err) + } + return nil +} + +func updateWebAclResourceWR(id string, a *waf.WafAction, oldR, newR []interface{}, conn *wafregional.WAFRegional, region string) error { + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.UpdateWebACLInput{ + DefaultAction: a, + ChangeToken: token, + WebACLId: aws.String(id), + Updates: diffWafWebAclRules(oldR, newR), + } + return conn.UpdateWebACL(req) + }) + if err != nil { + return fmt.Errorf("Error Updating WAF Regional ACL: %s", err) + } + return nil +} + +func expandDefaultActionWR(d []interface{}) *waf.WafAction { + if d == nil || len(d) == 0 { + return nil + } + + if d[0] == nil { + log.Printf("[ERR] First element of Default Action is set to nil") + return nil + } + + dA := d[0].(map[string]interface{}) + + return &waf.WafAction{ + Type: aws.String(dA["type"].(string)), + } +} + +func flattenDefaultActionWR(n *waf.WafAction) []map[string]interface{} { + if n == nil { + return nil + } + + m := setMap(make(map[string]interface{})) + + m.SetString("type", n.Type) + return m.MapList() +} + +func flattenWafWebAclRules(ts []*waf.ActivatedRule) []interface{} { + out := make([]interface{}, len(ts), len(ts)) + for i, r := range ts { + actionMap := map[string]interface{}{ + "type": *r.Action.Type, + } + m := make(map[string]interface{}) + m["action"] = []interface{}{actionMap} + m["priority"] = *r.Priority + m["rule_id"] = *r.RuleId + out[i] = m + } + return out +} + +func expandWafWebAclUpdate(updateAction string, aclRule map[string]interface{}) *waf.WebACLUpdate { + ruleAction := aclRule["action"].([]interface{})[0].(map[string]interface{}) + rule := &waf.ActivatedRule{ + Action: &waf.WafAction{Type: aws.String(ruleAction["type"].(string))}, + Priority: aws.Int64(int64(aclRule["priority"].(int))), + RuleId: aws.String(aclRule["rule_id"].(string)), + } + + update := &waf.WebACLUpdate{ + Action: aws.String(updateAction), + ActivatedRule: rule, + } + + return update +} + +func diffWafWebAclRules(oldR, newR []interface{}) []*waf.WebACLUpdate { + updates := make([]*waf.WebACLUpdate, 0) + + for _, or := range oldR { + aclRule := or.(map[string]interface{}) + + if idx, contains := sliceContainsMap(newR, aclRule); contains { + newR = append(newR[:idx], newR[idx+1:]...) + continue + } + updates = append(updates, expandWafWebAclUpdate(waf.ChangeActionDelete, aclRule)) + } + + for _, nr := range newR { + aclRule := nr.(map[string]interface{}) + updates = append(updates, expandWafWebAclUpdate(waf.ChangeActionInsert, aclRule)) + } + return updates +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_web_acl_association.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_web_acl_association.go new file mode 100644 index 000000000000..559a8d0417c1 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_web_acl_association.go @@ -0,0 +1,128 @@ +package aws + +import ( + "fmt" + "log" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/wafregional" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" +) + +func resourceAwsWafRegionalWebAclAssociation() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsWafRegionalWebAclAssociationCreate, + Read: resourceAwsWafRegionalWebAclAssociationRead, + Delete: resourceAwsWafRegionalWebAclAssociationDelete, + + Schema: map[string]*schema.Schema{ + "web_acl_id": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "resource_arn": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + }, + } +} + +func resourceAwsWafRegionalWebAclAssociationCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + + log.Printf( + "[INFO] Creating WAF Regional Web ACL association: %s => %s", + d.Get("web_acl_id").(string), + d.Get("resource_arn").(string)) + + params := &wafregional.AssociateWebACLInput{ + WebACLId: aws.String(d.Get("web_acl_id").(string)), + ResourceArn: aws.String(d.Get("resource_arn").(string)), + } + + // create association and wait on retryable error + // no response body + var err error + err = resource.Retry(2*time.Minute, func() *resource.RetryError { + _, err = conn.AssociateWebACL(params) + if err != nil { + if isAWSErr(err, wafregional.ErrCodeWAFUnavailableEntityException, "") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + if err != nil { + return err + } + + // Store association id + d.SetId(fmt.Sprintf("%s:%s", *params.WebACLId, *params.ResourceArn)) + + return nil +} + +func resourceAwsWafRegionalWebAclAssociationRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + + webAclId, resourceArn := resourceAwsWafRegionalWebAclAssociationParseId(d.Id()) + + // List all resources for Web ACL and see if we get a match + params := &wafregional.ListResourcesForWebACLInput{ + WebACLId: aws.String(webAclId), + } + + resp, err := conn.ListResourcesForWebACL(params) + if err != nil { + return err + } + + // Find match + found := false + for _, listResourceArn := range resp.ResourceArns { + if resourceArn == *listResourceArn { + found = true + break + } + } + if !found { + log.Printf("[WARN] WAF Regional Web ACL association (%s) not found, removing from state", d.Id()) + d.SetId("") + } + + return nil +} + +func resourceAwsWafRegionalWebAclAssociationDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + + _, resourceArn := resourceAwsWafRegionalWebAclAssociationParseId(d.Id()) + + log.Printf("[INFO] Deleting WAF Regional Web ACL association: %s", resourceArn) + + params := &wafregional.DisassociateWebACLInput{ + ResourceArn: aws.String(resourceArn), + } + + // If action successful HTTP 200 response with an empty body + _, err := conn.DisassociateWebACL(params) + if err != nil { + return err + } + + return nil +} + +func resourceAwsWafRegionalWebAclAssociationParseId(id string) (webAclId, resourceArn string) { + parts := strings.SplitN(id, ":", 2) + webAclId = parts[0] + resourceArn = parts[1] + return +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_xss_match_set.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_xss_match_set.go new file mode 100644 index 000000000000..eed3d928b6c3 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_wafregional_xss_match_set.go @@ -0,0 +1,175 @@ +package aws + +import ( + "fmt" + "log" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/waf" + "github.com/aws/aws-sdk-go/service/wafregional" + "github.com/hashicorp/terraform/helper/schema" +) + +func resourceAwsWafRegionalXssMatchSet() *schema.Resource { + return &schema.Resource{ + Create: resourceAwsWafRegionalXssMatchSetCreate, + Read: resourceAwsWafRegionalXssMatchSetRead, + Update: resourceAwsWafRegionalXssMatchSetUpdate, + Delete: resourceAwsWafRegionalXssMatchSetDelete, + + Schema: map[string]*schema.Schema{ + "name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "xss_match_tuple": &schema.Schema{ + Type: schema.TypeSet, + Optional: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "field_to_match": { + Type: schema.TypeSet, + Required: true, + MaxItems: 1, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "data": { + Type: schema.TypeString, + Optional: true, + }, + "type": { + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + "text_transformation": &schema.Schema{ + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + }, + } +} + +func resourceAwsWafRegionalXssMatchSetCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + log.Printf("[INFO] Creating regional WAF XSS Match Set: %s", d.Get("name").(string)) + + wr := newWafRegionalRetryer(conn, region) + out, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + params := &waf.CreateXssMatchSetInput{ + ChangeToken: token, + Name: aws.String(d.Get("name").(string)), + } + + return conn.CreateXssMatchSet(params) + }) + if err != nil { + return fmt.Errorf("Failed creating regional WAF XSS Match Set: %s", err) + } + resp := out.(*waf.CreateXssMatchSetOutput) + + d.SetId(*resp.XssMatchSet.XssMatchSetId) + + return resourceAwsWafRegionalXssMatchSetUpdate(d, meta) +} + +func resourceAwsWafRegionalXssMatchSetRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + log.Printf("[INFO] Reading regional WAF XSS Match Set: %s", d.Get("name").(string)) + params := &waf.GetXssMatchSetInput{ + XssMatchSetId: aws.String(d.Id()), + } + + resp, err := conn.GetXssMatchSet(params) + if err != nil { + if isAWSErr(err, wafregional.ErrCodeWAFNonexistentItemException, "") { + log.Printf("[WARN] Regional WAF XSS Match Set (%s) not found, error code (404)", d.Id()) + d.SetId("") + return nil + } + + return err + } + + set := resp.XssMatchSet + + d.Set("xss_match_tuple", flattenWafXssMatchTuples(set.XssMatchTuples)) + d.Set("name", set.Name) + + return nil +} + +func resourceAwsWafRegionalXssMatchSetUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + if d.HasChange("xss_match_tuple") { + o, n := d.GetChange("xss_match_tuple") + oldT, newT := o.(*schema.Set).List(), n.(*schema.Set).List() + + err := updateXssMatchSetResourceWR(d.Id(), oldT, newT, conn, region) + if err != nil { + return fmt.Errorf("Failed updating regional WAF XSS Match Set: %s", err) + } + } + + return resourceAwsWafRegionalXssMatchSetRead(d, meta) +} + +func resourceAwsWafRegionalXssMatchSetDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*AWSClient).wafregionalconn + region := meta.(*AWSClient).region + + if v, ok := d.GetOk("xss_match_tuple"); ok { + oldTuples := v.(*schema.Set).List() + if len(oldTuples) > 0 { + noTuples := []interface{}{} + err := updateXssMatchSetResourceWR(d.Id(), oldTuples, noTuples, conn, region) + if err != nil { + return fmt.Errorf("Error updating regional WAF XSS Match Set: %s", err) + } + } + } + + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.DeleteXssMatchSetInput{ + ChangeToken: token, + XssMatchSetId: aws.String(d.Id()), + } + + return conn.DeleteXssMatchSet(req) + }) + if err != nil { + return fmt.Errorf("Failed deleting regional WAF XSS Match Set: %s", err) + } + + return nil +} + +func updateXssMatchSetResourceWR(id string, oldT, newT []interface{}, conn *wafregional.WAFRegional, region string) error { + wr := newWafRegionalRetryer(conn, region) + _, err := wr.RetryWithToken(func(token *string) (interface{}, error) { + req := &waf.UpdateXssMatchSetInput{ + ChangeToken: token, + XssMatchSetId: aws.String(id), + Updates: diffWafXssMatchSetTuples(oldT, newT), + } + + log.Printf("[INFO] Updating XSS Match Set tuples: %s", req) + return conn.UpdateXssMatchSet(req) + }) + if err != nil { + return fmt.Errorf("Failed updating regional WAF XSS Match Set: %s", err) + } + + return nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/structure.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/structure.go index 39a0ad00db58..154971abef6c 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/structure.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/structure.go @@ -2111,15 +2111,6 @@ func buildApiGatewayInvokeURL(restApiId, region, stageName string) string { restApiId, region, stageName) } -func buildApiGatewayExecutionARN(restApiId, region, accountId string) (string, error) { - if accountId == "" { - return "", fmt.Errorf("Unable to build execution ARN for %s as account ID is missing", - restApiId) - } - return fmt.Sprintf("arn:aws:execute-api:%s:%s:%s", - region, accountId, restApiId), nil -} - func expandCognitoSupportedLoginProviders(config map[string]interface{}) map[string]*string { m := map[string]*string{} for k, v := range config { @@ -2767,65 +2758,294 @@ func expandCognitoUserPoolSchema(inputs []interface{}) []*cognitoidentityprovide return configs } -func flattenCognitoUserPoolSchema(inputs []*cognitoidentityprovider.SchemaAttributeType) []map[string]interface{} { - values := make([]map[string]interface{}, len(inputs), len(inputs)) - - for i, input := range inputs { - value := make(map[string]interface{}) +func cognitoUserPoolSchemaAttributeMatchesStandardAttribute(input *cognitoidentityprovider.SchemaAttributeType) bool { + if input == nil { + return false + } + + // All standard attributes always returned by API + // https://docs.aws.amazon.com/cognito/latest/developerguide/user-pool-settings-attributes.html#cognito-user-pools-standard-attributes + var standardAttributes = []cognitoidentityprovider.SchemaAttributeType{ + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("address"), + Required: aws.Bool(false), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("2048"), + MinLength: aws.String("0"), + }, + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("birthdate"), + Required: aws.Bool(false), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("10"), + MinLength: aws.String("10"), + }, + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("email"), + Required: aws.Bool(false), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("2048"), + MinLength: aws.String("0"), + }, + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeBoolean), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("email_verified"), + Required: aws.Bool(false), + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("gender"), + Required: aws.Bool(false), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("2048"), + MinLength: aws.String("0"), + }, + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("given_name"), + Required: aws.Bool(false), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("2048"), + MinLength: aws.String("0"), + }, + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("family_name"), + Required: aws.Bool(false), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("2048"), + MinLength: aws.String("0"), + }, + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("locale"), + Required: aws.Bool(false), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("2048"), + MinLength: aws.String("0"), + }, + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("middle_name"), + Required: aws.Bool(false), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("2048"), + MinLength: aws.String("0"), + }, + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("name"), + Required: aws.Bool(false), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("2048"), + MinLength: aws.String("0"), + }, + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("nickname"), + Required: aws.Bool(false), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("2048"), + MinLength: aws.String("0"), + }, + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("phone_number"), + Required: aws.Bool(false), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("2048"), + MinLength: aws.String("0"), + }, + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeBoolean), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("phone_number_verified"), + Required: aws.Bool(false), + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("picture"), + Required: aws.Bool(false), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("2048"), + MinLength: aws.String("0"), + }, + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("preferred_username"), + Required: aws.Bool(false), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("2048"), + MinLength: aws.String("0"), + }, + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("profile"), + Required: aws.Bool(false), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("2048"), + MinLength: aws.String("0"), + }, + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(false), + Name: aws.String("sub"), + Required: aws.Bool(true), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("2048"), + MinLength: aws.String("1"), + }, + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeNumber), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("updated_at"), + NumberAttributeConstraints: &cognitoidentityprovider.NumberAttributeConstraintsType{ + MinValue: aws.String("0"), + }, + Required: aws.Bool(false), + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("website"), + Required: aws.Bool(false), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("2048"), + MinLength: aws.String("0"), + }, + }, + { + AttributeDataType: aws.String(cognitoidentityprovider.AttributeDataTypeString), + DeveloperOnlyAttribute: aws.Bool(false), + Mutable: aws.Bool(true), + Name: aws.String("zoneinfo"), + Required: aws.Bool(false), + StringAttributeConstraints: &cognitoidentityprovider.StringAttributeConstraintsType{ + MaxLength: aws.String("2048"), + MinLength: aws.String("0"), + }, + }, + } + for _, standardAttribute := range standardAttributes { + if reflect.DeepEqual(*input, standardAttribute) { + return true + } + } + return false +} + +func flattenCognitoUserPoolSchema(configuredAttributes, inputs []*cognitoidentityprovider.SchemaAttributeType) []map[string]interface{} { + values := make([]map[string]interface{}, 0) + for _, input := range inputs { if input == nil { - return nil - } - - if input.AttributeDataType != nil { - value["attribute_data_type"] = *input.AttributeDataType + continue } - if input.DeveloperOnlyAttribute != nil { - value["developer_only_attribute"] = *input.DeveloperOnlyAttribute + // The API returns all standard attributes + // https://docs.aws.amazon.com/cognito/latest/developerguide/user-pool-settings-attributes.html#cognito-user-pools-standard-attributes + // Ignore setting them in state if they are unconfigured to prevent a huge and unexpected diff + configured := false + if configuredAttributes != nil { + for _, configuredAttribute := range configuredAttributes { + if reflect.DeepEqual(input, configuredAttribute) { + configured = true + } + } } - - if input.Mutable != nil { - value["mutable"] = *input.Mutable + if !configured && cognitoUserPoolSchemaAttributeMatchesStandardAttribute(input) { + continue } - if input.Name != nil { - value["name"] = *input.Name + var value = map[string]interface{}{ + "attribute_data_type": aws.StringValue(input.AttributeDataType), + "developer_only_attribute": aws.BoolValue(input.DeveloperOnlyAttribute), + "mutable": aws.BoolValue(input.Mutable), + "name": strings.TrimPrefix(strings.TrimPrefix(aws.StringValue(input.Name), "dev:"), "custom:"), + "required": aws.BoolValue(input.Required), } if input.NumberAttributeConstraints != nil { subvalue := make(map[string]interface{}) if input.NumberAttributeConstraints.MinValue != nil { - subvalue["min_value"] = input.NumberAttributeConstraints.MinValue + subvalue["min_value"] = aws.StringValue(input.NumberAttributeConstraints.MinValue) } if input.NumberAttributeConstraints.MaxValue != nil { - subvalue["max_value"] = input.NumberAttributeConstraints.MaxValue + subvalue["max_value"] = aws.StringValue(input.NumberAttributeConstraints.MaxValue) } - value["number_attribute_constraints"] = subvalue - } - - if input.Required != nil { - value["required"] = *input.Required + value["number_attribute_constraints"] = []map[string]interface{}{subvalue} } if input.StringAttributeConstraints != nil { subvalue := make(map[string]interface{}) if input.StringAttributeConstraints.MinLength != nil { - subvalue["min_length"] = input.StringAttributeConstraints.MinLength + subvalue["min_length"] = aws.StringValue(input.StringAttributeConstraints.MinLength) } if input.StringAttributeConstraints.MaxLength != nil { - subvalue["max_length"] = input.StringAttributeConstraints.MaxLength + subvalue["max_length"] = aws.StringValue(input.StringAttributeConstraints.MaxLength) } - value["string_attribute_constraints"] = subvalue + value["string_attribute_constraints"] = []map[string]interface{}{subvalue} } - values[i] = value + values = append(values, value) } return values @@ -2926,12 +3146,6 @@ func flattenCognitoUserPoolVerificationMessageTemplate(s *cognitoidentityprovide return []map[string]interface{}{} } -func buildLambdaInvokeArn(lambdaArn, region string) string { - apiVersion := "2015-03-31" - return fmt.Sprintf("arn:aws:apigateway:%s:lambda:path/%s/functions/%s/invocations", - region, apiVersion, lambdaArn) -} - func sliceContainsMap(l []interface{}, m map[string]interface{}) (int, bool) { for i, t := range l { if reflect.DeepEqual(m, t.(map[string]interface{})) { @@ -2942,12 +3156,10 @@ func sliceContainsMap(l []interface{}, m map[string]interface{}) (int, bool) { return -1, false } -func expandAwsSsmTargets(d *schema.ResourceData) []*ssm.Target { +func expandAwsSsmTargets(in []interface{}) []*ssm.Target { targets := make([]*ssm.Target, 0) - targetConfig := d.Get("targets").([]interface{}) - - for _, tConfig := range targetConfig { + for _, tConfig := range in { config := tConfig.(map[string]interface{}) target := &ssm.Target{ @@ -3534,6 +3746,17 @@ func flattenAwsDynamoDbTableResource(d *schema.ResourceData, table *dynamodb.Tab return err } + sseOptions := []map[string]interface{}{} + if table.SSEDescription != nil { + m := map[string]interface{}{} + m["enabled"] = aws.StringValue(table.SSEDescription.Status) == dynamodb.SSEStatusEnabled + sseOptions = []map[string]interface{}{m} + } + err = d.Set("server_side_encryption", sseOptions) + if err != nil { + return err + } + d.Set("arn", table.TableArn) return nil @@ -3622,6 +3845,16 @@ func expandDynamoDbKeySchema(data map[string]interface{}) []*dynamodb.KeySchemaE return keySchema } +func expandDynamoDbEncryptAtRestOptions(m map[string]interface{}) *dynamodb.SSESpecification { + options := dynamodb.SSESpecification{} + + if v, ok := m["enabled"]; ok { + options.Enabled = aws.Bool(v.(bool)) + } + + return &options +} + func flattenVpcEndpointServiceAllowedPrincipals(allowedPrincipals []*ec2.AllowedPrincipal) []string { result := make([]string, 0, len(allowedPrincipals)) for _, allowedPrincipal := range allowedPrincipals { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/tagsBeanstalk.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/tagsBeanstalk.go index 7b85d611603d..29158b109156 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/tagsBeanstalk.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/tagsBeanstalk.go @@ -11,7 +11,7 @@ import ( // diffTags takes our tags locally and the ones remotely and returns // the set of tags that must be created, and the set of tags that must // be destroyed. -func diffTagsBeanstalk(oldTags, newTags []*elasticbeanstalk.Tag) ([]*elasticbeanstalk.Tag, []*elasticbeanstalk.Tag) { +func diffTagsBeanstalk(oldTags, newTags []*elasticbeanstalk.Tag) ([]*elasticbeanstalk.Tag, []*string) { // First, we're creating everything we have create := make(map[string]interface{}) for _, t := range newTags { @@ -19,12 +19,11 @@ func diffTagsBeanstalk(oldTags, newTags []*elasticbeanstalk.Tag) ([]*elasticbean } // Build the list of what to remove - var remove []*elasticbeanstalk.Tag + var remove []*string for _, t := range oldTags { - old, ok := create[*t.Key] - if !ok || old != *t.Value { + if _, ok := create[*t.Key]; !ok { // Delete it! - remove = append(remove, t) + remove = append(remove, t.Key) } } @@ -62,7 +61,7 @@ func tagsToMapBeanstalk(ts []*elasticbeanstalk.Tag) map[string]string { // compare a tag against a list of strings and checks if it should // be ignored or not func tagIgnoredBeanstalk(t *elasticbeanstalk.Tag) bool { - filter := []string{"^aws:"} + filter := []string{"^aws:", "^elasticbeanstalk:", "Name"} for _, v := range filter { log.Printf("[DEBUG] Matching %v with %v\n", v, *t.Key) if r, _ := regexp.MatchString(v, *t.Key); r == true { diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/tagsSSM.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/tagsSSM.go new file mode 100644 index 000000000000..c26eafc5308b --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/tagsSSM.go @@ -0,0 +1,117 @@ +package aws + +import ( + "log" + "regexp" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/ssm" + "github.com/hashicorp/terraform/helper/schema" +) + +// setTags is a helper to set the tags for a resource. It expects the +// tags field to be named "tags" +func setTagsSSM(conn *ssm.SSM, d *schema.ResourceData, id, resourceType string) error { + if d.HasChange("tags") { + oraw, nraw := d.GetChange("tags") + o := oraw.(map[string]interface{}) + n := nraw.(map[string]interface{}) + create, remove := diffTagsSSM(tagsFromMapSSM(o), tagsFromMapSSM(n)) + + // Set tags + if len(remove) > 0 { + log.Printf("[DEBUG] Removing tags: %#v", remove) + k := make([]*string, len(remove), len(remove)) + for i, t := range remove { + k[i] = t.Key + } + + _, err := conn.RemoveTagsFromResource(&ssm.RemoveTagsFromResourceInput{ + ResourceId: aws.String(id), + ResourceType: aws.String(resourceType), + TagKeys: k, + }) + if err != nil { + return err + } + } + if len(create) > 0 { + log.Printf("[DEBUG] Creating tags: %#v", create) + _, err := conn.AddTagsToResource(&ssm.AddTagsToResourceInput{ + ResourceId: aws.String(id), + ResourceType: aws.String(resourceType), + Tags: create, + }) + if err != nil { + return err + } + } + } + + return nil +} + +// diffTags takes our tags locally and the ones remotely and returns +// the set of tags that must be created, and the set of tags that must +// be destroyed. +func diffTagsSSM(oldTags, newTags []*ssm.Tag) ([]*ssm.Tag, []*ssm.Tag) { + // First, we're creating everything we have + create := make(map[string]interface{}) + for _, t := range newTags { + create[*t.Key] = *t.Value + } + + // Build the list of what to remove + var remove []*ssm.Tag + for _, t := range oldTags { + old, ok := create[*t.Key] + if !ok || old != *t.Value { + // Delete it! + remove = append(remove, t) + } + } + + return tagsFromMapSSM(create), remove +} + +// tagsFromMap returns the tags for the given map of data. +func tagsFromMapSSM(m map[string]interface{}) []*ssm.Tag { + result := make([]*ssm.Tag, 0, len(m)) + for k, v := range m { + t := &ssm.Tag{ + Key: aws.String(k), + Value: aws.String(v.(string)), + } + if !tagIgnoredSSM(t) { + result = append(result, t) + } + } + + return result +} + +// tagsToMap turns the list of tags into a map. +func tagsToMapSSM(ts []*ssm.Tag) map[string]string { + result := make(map[string]string) + for _, t := range ts { + if !tagIgnoredSSM(t) { + result[*t.Key] = *t.Value + } + } + + return result +} + +// compare a tag against a list of strings and checks if it should +// be ignored or not +func tagIgnoredSSM(t *ssm.Tag) bool { + filter := []string{"^aws:"} + for _, v := range filter { + log.Printf("[DEBUG] Matching %v with %v\n", v, *t.Key) + if r, _ := regexp.MatchString(v, *t.Key); r == true { + log.Printf("[DEBUG] Found AWS specific tag %s (val: %s), ignoring.\n", *t.Key, *t.Value) + return true + } + } + return false +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/utils.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/utils.go index bfca044cfb1a..21c3aab7ef3d 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/utils.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/utils.go @@ -5,6 +5,8 @@ import ( "encoding/json" "reflect" "regexp" + + "github.com/hashicorp/terraform/helper/resource" ) // Base64Encode encodes data if the input isn't already encoded using base64.StdEncoding.EncodeToString. @@ -40,3 +42,8 @@ func jsonBytesEqual(b1, b2 []byte) bool { return reflect.DeepEqual(o1, o2) } + +func isResourceNotFoundError(err error) bool { + _, ok := err.(*resource.NotFoundError) + return ok +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/validators.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/validators.go index 3199e3229e9e..3fcbdb1b444d 100644 --- a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/validators.go +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/validators.go @@ -13,21 +13,20 @@ import ( "github.com/aws/aws-sdk-go/service/apigateway" "github.com/aws/aws-sdk-go/service/cognitoidentity" "github.com/aws/aws-sdk-go/service/cognitoidentityprovider" - "github.com/aws/aws-sdk-go/service/dynamodb" + "github.com/aws/aws-sdk-go/service/configservice" "github.com/aws/aws-sdk-go/service/ec2" - "github.com/aws/aws-sdk-go/service/gamelift" - "github.com/aws/aws-sdk-go/service/guardduty" "github.com/aws/aws-sdk-go/service/s3" + "github.com/aws/aws-sdk-go/service/waf" "github.com/hashicorp/terraform/helper/schema" "github.com/hashicorp/terraform/helper/structure" + "github.com/hashicorp/terraform/helper/validation" ) -func validateInstanceUserDataSize(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - length := len(value) - - if length > 16384 { - errors = append(errors, fmt.Errorf("%q is %d bytes, cannot be longer than 16384 bytes", k, length)) +// When released, replace all usage with upstream validation function: +// https://github.com/hashicorp/terraform/pull/17484 +func validateRFC3339TimeString(v interface{}, k string) (ws []string, errors []error) { + if _, err := time.Parse(time.RFC3339, v.(string)); err != nil { + errors = append(errors, fmt.Errorf("%q: %s", k, err)) } return } @@ -70,21 +69,12 @@ func validateRdsIdentifierPrefix(v interface{}, k string) (ws []string, errors [ return } -func validateRdsEngine(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - - validTypes := map[string]bool{ - "aurora": true, - "aurora-mysql": true, - "aurora-postgresql": true, - } - - if _, ok := validTypes[value]; !ok { - errors = append(errors, fmt.Errorf( - "%q contains an invalid engine type %q. Valid types are either %q, %q or %q.", - k, value, "aurora", "aurora-mysql", "aurora-postgresql")) - } - return +func validateRdsEngine() schema.SchemaValidateFunc { + return validation.StringInSlice([]string{ + "aurora", + "aurora-mysql", + "aurora-postgresql", + }, false) } func validateElastiCacheClusterId(v interface{}, k string) (ws []string, errors []error) { @@ -180,45 +170,6 @@ func validateDbParamGroupNamePrefix(v interface{}, k string) (ws []string, error return } -func validateStreamViewType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - - if value == "" { - return - } - - viewTypes := map[string]bool{ - "KEYS_ONLY": true, - "NEW_IMAGE": true, - "OLD_IMAGE": true, - "NEW_AND_OLD_IMAGES": true, - } - - if !viewTypes[value] { - errors = append(errors, fmt.Errorf("%q must be a valid DynamoDB StreamViewType", k)) - } - return -} - -func validateDynamoAttributeType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - validTypes := []string{ - dynamodb.ScalarAttributeTypeB, - dynamodb.ScalarAttributeTypeN, - dynamodb.ScalarAttributeTypeS, - } - - for _, t := range validTypes { - if t == value { - return - } - } - - errors = append(errors, fmt.Errorf("%q must be a valid DynamoDB attribute type", k)) - - return -} - func validateElbName(v interface{}, k string) (ws []string, errors []error) { value := v.(string) if len(value) == 0 { @@ -333,14 +284,7 @@ func validateCloudWatchLogResourcePolicyDocument(v interface{}, k string) (ws [] } func validateMaxLength(length int) schema.SchemaValidateFunc { - return func(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > length { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than %d characters: %q", k, length, value)) - } - return - } + return validation.StringLenBetween(0, length) } func validateIntegerInRange(min, max int) schema.SchemaValidateFunc { @@ -494,26 +438,17 @@ func validateCIDRNetworkAddress(v interface{}, k string) (ws []string, errors [] return } -func validateHTTPMethod(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - - validMethods := map[string]bool{ - "ANY": true, - "DELETE": true, - "GET": true, - "HEAD": true, - "OPTIONS": true, - "PATCH": true, - "POST": true, - "PUT": true, - } - - if _, ok := validMethods[value]; !ok { - errors = append(errors, fmt.Errorf( - "%q contains an invalid method %q. Valid methods are either %q, %q, %q, %q, %q, %q, %q, or %q.", - k, value, "ANY", "DELETE", "GET", "HEAD", "OPTIONS", "PATCH", "POST", "PUT")) - } - return +func validateHTTPMethod() schema.SchemaValidateFunc { + return validation.StringInSlice([]string{ + "ANY", + "DELETE", + "GET", + "HEAD", + "OPTIONS", + "PATCH", + "POST", + "PUT", + }, false) } func validateLogMetricFilterName(v interface{}, k string) (ws []string, errors []error) { @@ -606,91 +541,11 @@ func validateS3BucketLifecycleTimestamp(v interface{}, k string) (ws []string, e return } -func validateS3BucketLifecycleExpirationDays(v interface{}, k string) (ws []string, errors []error) { - if v.(int) <= 0 { - errors = append(errors, fmt.Errorf( - "%q must be greater than 0", k)) - } - - return -} - -func validateS3BucketLifecycleTransitionDays(v interface{}, k string) (ws []string, errors []error) { - if v.(int) < 0 { - errors = append(errors, fmt.Errorf( - "%q must be greater than 0", k)) - } - - return -} - -func validateS3BucketLifecycleStorageClass(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != s3.TransitionStorageClassStandardIa && value != s3.TransitionStorageClassGlacier { - errors = append(errors, fmt.Errorf( - "%q must be one of '%q', '%q'", k, s3.TransitionStorageClassStandardIa, s3.TransitionStorageClassGlacier)) - } - - return -} - -func validateS3BucketReplicationRuleId(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 255 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 255 characters: %q", k, value)) - } - - return -} - -func validateS3BucketReplicationRulePrefix(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 1024 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 1024 characters: %q", k, value)) - } - - return -} - -func validateS3BucketServerSideEncryptionAlgorithm(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != s3.ServerSideEncryptionAes256 && value != s3.ServerSideEncryptionAwsKms { - errors = append(errors, fmt.Errorf( - "%q must be one of %q or %q", k, s3.ServerSideEncryptionAwsKms, s3.ServerSideEncryptionAes256)) - } - - return -} - -func validateS3BucketReplicationDestinationStorageClass(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != s3.StorageClassStandard && value != s3.StorageClassStandardIa && value != s3.StorageClassReducedRedundancy { - errors = append(errors, fmt.Errorf( - "%q must be one of '%q', '%q' or '%q'", k, s3.StorageClassStandard, s3.StorageClassStandardIa, s3.StorageClassReducedRedundancy)) - } - - return -} - -func validateS3BucketReplicationRuleStatus(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != s3.ReplicationRuleStatusEnabled && value != s3.ReplicationRuleStatusDisabled { - errors = append(errors, fmt.Errorf( - "%q must be one of '%q' or '%q'", k, s3.ReplicationRuleStatusEnabled, s3.ReplicationRuleStatusDisabled)) - } - - return -} - -func validateS3BucketLifecycleRuleId(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 255 { - errors = append(errors, fmt.Errorf( - "%q cannot exceed 255 characters", k)) - } - return +func validateS3BucketLifecycleStorageClass() schema.SchemaValidateFunc { + return validation.StringInSlice([]string{ + s3.TransitionStorageClassStandardIa, + s3.TransitionStorageClassGlacier, + }, false) } func validateDbEventSubscriptionName(v interface{}, k string) (ws []string, errors []error) { @@ -706,15 +561,6 @@ func validateDbEventSubscriptionName(v interface{}, k string) (ws []string, erro return } -func validateApiGatewayIntegrationPassthroughBehavior(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if value != "WHEN_NO_MATCH" && value != "WHEN_NO_TEMPLATES" && value != "NEVER" { - errors = append(errors, fmt.Errorf( - "%q must be one of 'WHEN_NO_MATCH', 'WHEN_NO_TEMPLATES', 'NEVER'", k)) - } - return -} - func validateJsonString(v interface{}, k string) (ws []string, errors []error) { if _, err := structure.NormalizeJsonString(v); err != nil { errors = append(errors, fmt.Errorf("%q contains an invalid JSON: %s", k, err)) @@ -752,39 +598,11 @@ func validateCloudFormationTemplate(v interface{}, k string) (ws []string, error return } -func validateApiGatewayIntegrationType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - - validTypes := map[string]bool{ - "AWS": true, - "AWS_PROXY": true, - "HTTP": true, - "HTTP_PROXY": true, - "MOCK": true, - } - - if _, ok := validTypes[value]; !ok { - errors = append(errors, fmt.Errorf( - "%q contains an invalid integration type %q. Valid types are either %q, %q, %q, %q, or %q.", - k, value, "AWS", "AWS_PROXY", "HTTP", "HTTP_PROXY", "MOCK")) - } - return -} - -func validateApiGatewayIntegrationContentHandling(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - - validTypes := map[string]bool{ - "CONVERT_TO_BINARY": true, - "CONVERT_TO_TEXT": true, - } - - if _, ok := validTypes[value]; !ok { - errors = append(errors, fmt.Errorf( - "%q contains an invalid integration type %q. Valid types are either %q or %q.", - k, value, "CONVERT_TO_BINARY", "CONVERT_TO_TEXT")) - } - return +func validateApiGatewayIntegrationContentHandling() schema.SchemaValidateFunc { + return validation.StringInSlice([]string{ + apigateway.ContentHandlingStrategyConvertToBinary, + apigateway.ContentHandlingStrategyConvertToText, + }, false) } func validateSQSQueueName(v interface{}, k string) (ws []string, errors []error) { @@ -833,36 +651,6 @@ func validateSQSFifoQueueName(v interface{}, k string) (errors []error) { return } -func validateSNSSubscriptionProtocol(v interface{}, k string) (ws []string, errors []error) { - value := strings.ToLower(v.(string)) - forbidden := []string{"email"} - for _, f := range forbidden { - if strings.Contains(value, f) { - errors = append( - errors, - fmt.Errorf("Unsupported protocol (%s) for SNS Topic", value), - ) - } - } - return -} - -func validateSecurityRuleType(v interface{}, k string) (ws []string, errors []error) { - value := strings.ToLower(v.(string)) - - validTypes := map[string]bool{ - "ingress": true, - "egress": true, - } - - if _, ok := validTypes[value]; !ok { - errors = append(errors, fmt.Errorf( - "%q contains an invalid Security Group Rule type %q. Valid types are either %q or %q.", - k, value, "ingress", "egress")) - } - return -} - func validateOnceAWeekWindowFormat(v interface{}, k string) (ws []string, errors []error) { // valid time format is "ddd:hh24:mi" validTimeFormat := "(sun|mon|tue|wed|thu|fri|sat):([0-1][0-9]|2[0-3]):([0-5][0-9])" @@ -889,32 +677,6 @@ func validateOnceADayWindowFormat(v interface{}, k string) (ws []string, errors return } -func validateRoute53RecordType(v interface{}, k string) (ws []string, errors []error) { - // Valid Record types - // SOA, A, TXT, NS, CNAME, MX, NAPTR, PTR, SRV, SPF, AAAA, CAA - validTypes := map[string]struct{}{ - "SOA": {}, - "A": {}, - "TXT": {}, - "NS": {}, - "CNAME": {}, - "MX": {}, - "NAPTR": {}, - "PTR": {}, - "SRV": {}, - "SPF": {}, - "AAAA": {}, - "CAA": {}, - } - - value := v.(string) - if _, ok := validTypes[value]; !ok { - errors = append(errors, fmt.Errorf( - "%q must be one of [SOA, A, TXT, NS, CNAME, MX, NAPTR, PTR, SRV, SPF, AAAA, CAA]", k)) - } - return -} - // Validates that ECS Placement Constraints are set correctly // Takes type, and expression as strings func validateAwsEcsPlacementConstraint(constType, constExpr string) error { @@ -969,36 +731,12 @@ func validateAwsEcsPlacementStrategy(stratType, stratField string) error { return nil } -func validateAwsEmrEbsVolumeType(v interface{}, k string) (ws []string, errors []error) { - validTypes := map[string]struct{}{ - "gp2": {}, - "io1": {}, - "standard": {}, - } - - value := v.(string) - - if _, ok := validTypes[value]; !ok { - errors = append(errors, fmt.Errorf( - "%q must be one of ['gp2', 'io1', 'standard']", k)) - } - return -} - -func validateAwsEmrInstanceGroupRole(v interface{}, k string) (ws []string, errors []error) { - validRoles := map[string]struct{}{ - "MASTER": {}, - "CORE": {}, - "TASK": {}, - } - - value := v.(string) - - if _, ok := validRoles[value]; !ok { - errors = append(errors, fmt.Errorf( - "%q must be one of ['MASTER', 'CORE', 'TASK']", k)) - } - return +func validateAwsEmrEbsVolumeType() schema.SchemaValidateFunc { + return validation.StringInSlice([]string{ + "gp2", + "io1", + "standard", + }, false) } func validateAwsEmrCustomAmiId(v interface{}, k string) (ws []string, errors []error) { @@ -1015,23 +753,6 @@ func validateAwsEmrCustomAmiId(v interface{}, k string) (ws []string, errors []e return } -func validateSfnActivityName(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 80 { - errors = append(errors, fmt.Errorf("%q cannot be longer than 80 characters", k)) - } - - return -} - -func validateSfnStateMachineDefinition(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 1048576 { - errors = append(errors, fmt.Errorf("%q cannot be longer than 1048576 characters", k)) - } - return -} - func validateSfnStateMachineName(v interface{}, k string) (ws []string, errors []error) { value := v.(string) if len(value) > 80 { @@ -1137,70 +858,14 @@ func validateDmsReplicationTaskId(v interface{}, k string) (ws []string, es []er return } -func validateAppautoscalingCustomizedMetricSpecificationStatistic(v interface{}, k string) (ws []string, errors []error) { - validStatistic := []string{ - "Average", - "Minimum", - "Maximum", - "SampleCount", - "Sum", - } - statistic := v.(string) - for _, o := range validStatistic { - if statistic == o { - return - } - } - errors = append(errors, fmt.Errorf( - "%q contains an invalid statistic %q. Valid statistic are %q.", - k, statistic, validStatistic)) - return -} - -func validateAppautoscalingPredefinedResourceLabel(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 1023 { - errors = append(errors, fmt.Errorf( - "%q cannot be greater than 1023 characters", k)) - } - return -} - -func validateConfigRuleSourceOwner(v interface{}, k string) (ws []string, errors []error) { - validOwners := []string{ - "CUSTOM_LAMBDA", - "AWS", - } - owner := v.(string) - for _, o := range validOwners { - if owner == o { - return - } - } - errors = append(errors, fmt.Errorf( - "%q contains an invalid owner %q. Valid owners are %q.", - k, owner, validOwners)) - return -} - -func validateConfigExecutionFrequency(v interface{}, k string) (ws []string, errors []error) { - validFrequencies := []string{ - "One_Hour", - "Three_Hours", - "Six_Hours", - "Twelve_Hours", - "TwentyFour_Hours", - } - frequency := v.(string) - for _, f := range validFrequencies { - if frequency == f { - return - } - } - errors = append(errors, fmt.Errorf( - "%q contains an invalid frequency %q. Valid frequencies are %q.", - k, frequency, validFrequencies)) - return +func validateConfigExecutionFrequency() schema.SchemaValidateFunc { + return validation.StringInSlice([]string{ + configservice.MaximumExecutionFrequencyOneHour, + configservice.MaximumExecutionFrequencyThreeHours, + configservice.MaximumExecutionFrequencySixHours, + configservice.MaximumExecutionFrequencyTwelveHours, + configservice.MaximumExecutionFrequencyTwentyFourHours, + }, false) } func validateAccountAlias(v interface{}, k string) (ws []string, es []error) { @@ -1221,19 +886,6 @@ func validateAccountAlias(v interface{}, k string) (ws []string, es []error) { return } -func validateApiGatewayApiKeyValue(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) < 30 { - errors = append(errors, fmt.Errorf( - "%q must be at least 30 characters long", k)) - } - if len(value) > 128 { - errors = append(errors, fmt.Errorf( - "%q cannot be longer than 128 characters", k)) - } - return -} - func validateIamRolePolicyName(v interface{}, k string) (ws []string, errors []error) { // https://github.com/boto/botocore/blob/2485f5c/botocore/data/iam/2010-05-08/service-2.json#L8291-L8296 value := v.(string) @@ -1259,24 +911,6 @@ func validateIamRolePolicyNamePrefix(v interface{}, k string) (ws []string, erro return } -func validateApiGatewayUsagePlanQuotaSettingsPeriod(v interface{}, k string) (ws []string, errors []error) { - validPeriods := []string{ - apigateway.QuotaPeriodTypeDay, - apigateway.QuotaPeriodTypeWeek, - apigateway.QuotaPeriodTypeMonth, - } - period := v.(string) - for _, f := range validPeriods { - if period == f { - return - } - } - errors = append(errors, fmt.Errorf( - "%q contains an invalid period %q. Valid period are %q.", - k, period, validPeriods)) - return -} - func validateApiGatewayUsagePlanQuotaSettings(v map[string]interface{}) (errors []error) { period := v["period"].(string) offset := v["offset"].(int) @@ -1372,22 +1006,6 @@ func validateDbOptionGroupNamePrefix(v interface{}, k string) (ws []string, erro return } -func validateAwsLbTargetGroupName(v interface{}, k string) (ws []string, errors []error) { - name := v.(string) - if len(name) > 32 { - errors = append(errors, fmt.Errorf("%q (%q) cannot be longer than '32' characters", k, name)) - } - return -} - -func validateAwsLbTargetGroupNamePrefix(v interface{}, k string) (ws []string, errors []error) { - name := v.(string) - if len(name) > 6 { - errors = append(errors, fmt.Errorf("%q (%q) cannot be longer than '6' characters", k, name)) - } - return -} - func validateOpenIdURL(v interface{}, k string) (ws []string, errors []error) { value := v.(string) u, err := url.Parse(value) @@ -1413,6 +1031,20 @@ func validateAwsKmsName(v interface{}, k string) (ws []string, es []error) { return } +func validateAwsKmsGrantName(v interface{}, k string) (ws []string, es []error) { + value := v.(string) + + if len(value) > 256 { + es = append(es, fmt.Errorf("%s can not be greater than 256 characters", k)) + } + + if !regexp.MustCompile(`^[a-zA-Z0-9:/_-]+$`).MatchString(value) { + es = append(es, fmt.Errorf("%s must only contain [a-zA-Z0-9:/_-]", k)) + } + + return +} + func validateCognitoIdentityPoolName(v interface{}, k string) (ws []string, errors []error) { val := v.(string) if !regexp.MustCompile("^[\\w _]+$").MatchString(val) { @@ -1542,21 +1174,6 @@ func validateCognitoUserPoolId(v interface{}, k string) (ws []string, es []error return } -func validateCognitoUserPoolMfaConfiguration(v interface{}, k string) (ws []string, es []error) { - value := v.(string) - - valid := map[string]bool{ - cognitoidentityprovider.UserPoolMfaTypeOff: true, - cognitoidentityprovider.UserPoolMfaTypeOn: true, - cognitoidentityprovider.UserPoolMfaTypeOptional: true, - } - if !valid[value] { - es = append(es, fmt.Errorf( - "%q must be equal to OFF, ON, or OPTIONAL", k)) - } - return -} - func validateCognitoUserPoolSmsAuthenticationMessage(v interface{}, k string) (ws []string, es []error) { value := v.(string) if len(value) < 6 { @@ -1589,41 +1206,6 @@ func validateCognitoUserPoolSmsVerificationMessage(v interface{}, k string) (ws return } -func validateCognitoUserPoolAliasAttribute(v interface{}, k string) (ws []string, es []error) { - validValues := []string{ - cognitoidentityprovider.AliasAttributeTypeEmail, - cognitoidentityprovider.AliasAttributeTypePhoneNumber, - cognitoidentityprovider.AliasAttributeTypePreferredUsername, - } - period := v.(string) - for _, f := range validValues { - if period == f { - return - } - } - es = append(es, fmt.Errorf( - "%q contains an invalid alias attribute %q. Valid alias attributes are %q.", - k, period, validValues)) - return -} - -func validateCognitoUserPoolAutoVerifiedAttribute(v interface{}, k string) (ws []string, es []error) { - validValues := []string{ - cognitoidentityprovider.VerifiedAttributeTypePhoneNumber, - cognitoidentityprovider.VerifiedAttributeTypeEmail, - } - period := v.(string) - for _, f := range validValues { - if period == f { - return - } - } - es = append(es, fmt.Errorf( - "%q contains an invalid verified attribute %q. Valid verified attributes are %q.", - k, period, validValues)) - return -} - func validateCognitoUserPoolClientAuthFlows(v interface{}, k string) (ws []string, es []error) { validValues := []string{ cognitoidentityprovider.AuthFlowTypeAdminNoSrpAuth, @@ -1641,23 +1223,6 @@ func validateCognitoUserPoolClientAuthFlows(v interface{}, k string) (ws []strin return } -func validateCognitoUserPoolTemplateDefaultEmailOption(v interface{}, k string) (ws []string, es []error) { - validValues := []string{ - cognitoidentityprovider.DefaultEmailOptionTypeConfirmWithLink, - cognitoidentityprovider.DefaultEmailOptionTypeConfirmWithCode, - } - period := v.(string) - for _, f := range validValues { - if period == f { - return - } - } - es = append(es, fmt.Errorf( - "%q contains an invalid template default email option %q. Valid template default email options are %q.", - k, period, validValues)) - return -} - func validateCognitoUserPoolTemplateEmailMessage(v interface{}, k string) (ws []string, es []error) { value := v.(string) if len(value) < 6 { @@ -1680,8 +1245,8 @@ func validateCognitoUserPoolTemplateEmailMessageByLink(v interface{}, k string) es = append(es, fmt.Errorf("%q cannot be less than 1 character", k)) } - if len(value) > 140 { - es = append(es, fmt.Errorf("%q cannot be longer than 140 characters", k)) + if len(value) > 20000 { + es = append(es, fmt.Errorf("%q cannot be longer than 20000 characters", k)) } if !regexp.MustCompile(`[\p{L}\p{M}\p{S}\p{N}\p{P}\s*]*\{##[\p{L}\p{M}\p{S}\p{N}\p{P}\s*]*##\}[\p{L}\p{M}\p{S}\p{N}\p{P}\s*]*`).MatchString(value) { @@ -1830,6 +1395,17 @@ func validateWafMetricName(v interface{}, k string) (ws []string, errors []error return } +func validateWafPredicatesType() schema.SchemaValidateFunc { + return validation.StringInSlice([]string{ + waf.PredicateTypeIpmatch, + waf.PredicateTypeByteMatch, + waf.PredicateTypeSqlInjectionMatch, + waf.PredicateTypeSizeConstraint, + waf.PredicateTypeXssMatch, + waf.PredicateTypeGeoMatch, + }, false) +} + func validateIamRoleDescription(v interface{}, k string) (ws []string, errors []error) { value := v.(string) @@ -1858,20 +1434,6 @@ func validateAwsSSMName(v interface{}, k string) (ws []string, errors []error) { return } -func validateSsmParameterType(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - types := map[string]bool{ - "String": true, - "StringList": true, - "SecureString": true, - } - - if !types[value] { - errors = append(errors, fmt.Errorf("Parameter type %s is invalid. Valid types are String, StringList or SecureString", value)) - } - return -} - func validateBatchName(v interface{}, k string) (ws []string, errors []error) { value := v.(string) if !regexp.MustCompile(`^[0-9a-zA-Z]{1}[0-9a-zA-Z_\-]{0,127}$`).MatchString(value) { @@ -1951,55 +1513,6 @@ func validateIoTTopicRuleElasticSearchEndpoint(v interface{}, k string) (ws []st return } -func validateServiceCatalogPortfolioName(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if (len(value) > 20) || (len(value) == 0) { - errors = append(errors, fmt.Errorf("Service catalog name must be between 1 and 20 characters.")) - } - return -} - -func validateServiceCatalogPortfolioDescription(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 2000 { - errors = append(errors, fmt.Errorf("Service catalog description must be less than 2000 characters.")) - } - return -} - -func validateServiceCatalogPortfolioProviderName(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if (len(value) > 20) || (len(value) == 0) { - errors = append(errors, fmt.Errorf("Service catalog provider name must be between 1 and 20 characters.")) - } - return -} - -func validateSesTemplateName(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if (len(value) > 64) || (len(value) == 0) { - errors = append(errors, fmt.Errorf("SES template name must be between 1 and 64 characters.")) - } - return -} - -func validateSesTemplateHtml(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 512000 { - errors = append(errors, fmt.Errorf("SES template must be less than 500KB in size, including both the text and HTML parts.")) - } - return -} - -func validateSesTemplateText(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) > 512000 { - errors = append(errors, fmt.Errorf("SES template must be less than 500KB in size, including both the text and HTML parts.")) - } - - return -} - func validateCognitoRoleMappingsAmbiguousRoleResolutionAgainstType(v map[string]interface{}) (errors []error) { t := v["type"].(string) isRequired := t == cognitoidentity.RoleMappingTypeToken || t == cognitoidentity.RoleMappingTypeRules @@ -2029,23 +1542,6 @@ func validateCognitoRoleMappingsRulesConfiguration(v map[string]interface{}) (er return } -func validateCognitoRoleMappingsAmbiguousRoleResolution(v interface{}, k string) (ws []string, errors []error) { - validValues := []string{ - cognitoidentity.AmbiguousRoleResolutionTypeAuthenticatedRole, - cognitoidentity.AmbiguousRoleResolutionTypeDeny, - } - value := v.(string) - for _, s := range validValues { - if value == s { - return - } - } - errors = append(errors, fmt.Errorf( - "%q contains an invalid value %q. Valid values are %q.", - k, value, validValues)) - return -} - func validateCognitoRoleMappingsRulesClaim(v interface{}, k string) (ws []string, errors []error) { value := v.(string) @@ -2056,55 +1552,6 @@ func validateCognitoRoleMappingsRulesClaim(v interface{}, k string) (ws []string return } -func validateCognitoRoleMappingsRulesMatchType(v interface{}, k string) (ws []string, errors []error) { - validValues := []string{ - cognitoidentity.MappingRuleMatchTypeEquals, - cognitoidentity.MappingRuleMatchTypeContains, - cognitoidentity.MappingRuleMatchTypeStartsWith, - cognitoidentity.MappingRuleMatchTypeNotEqual, - } - value := v.(string) - for _, s := range validValues { - if value == s { - return - } - } - errors = append(errors, fmt.Errorf( - "%q contains an invalid value %q. Valid values are %q.", - k, value, validValues)) - return -} - -func validateCognitoRoleMappingsRulesValue(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - if len(value) < 1 { - errors = append(errors, fmt.Errorf("%q cannot be less than 1 character", k)) - } - - if len(value) > 128 { - errors = append(errors, fmt.Errorf("%q cannot be longer than 1 characters", k)) - } - - return -} - -func validateCognitoRoleMappingsType(v interface{}, k string) (ws []string, errors []error) { - validValues := []string{ - cognitoidentity.RoleMappingTypeToken, - cognitoidentity.RoleMappingTypeRules, - } - value := v.(string) - for _, s := range validValues { - if value == s { - return - } - } - errors = append(errors, fmt.Errorf( - "%q contains an invalid value %q. Valid values are %q.", - k, value, validValues)) - return -} - // Validates that either authenticated or unauthenticated is defined func validateCognitoRoles(v map[string]interface{}, k string) (errors []error) { _, hasAuthenticated := v["authenticated"].(string) @@ -2126,21 +1573,23 @@ func validateCognitoUserPoolDomain(v interface{}, k string) (ws []string, errors return } -func validateDxConnectionBandWidth(v interface{}, k string) (ws []string, errors []error) { - val, ok := v.(string) - if !ok { - errors = append(errors, fmt.Errorf("expected type of %s to be string", k)) - return - } +func validateDxConnectionBandWidth() schema.SchemaValidateFunc { + return validation.StringInSlice([]string{"1Gbps", "10Gbps"}, false) +} - validBandWidth := []string{"1Gbps", "10Gbps"} - for _, str := range validBandWidth { - if val == str { - return - } +func validateKmsKey(v interface{}, k string) (ws []string, errors []error) { + value := v.(string) + arnPrefixPattern := `arn:[^:]+:kms:[^:]+:[^:]+:` + keyIdPattern := "[A-Za-z0-9-]+" + keyArnPattern := arnPrefixPattern + "key/" + keyIdPattern + aliasNamePattern := "alias/[a-zA-Z0-9:/_-]+" + aliasArnPattern := arnPrefixPattern + aliasNamePattern + if !regexp.MustCompile(fmt.Sprintf("^%s$", keyIdPattern)).MatchString(value) && + !regexp.MustCompile(fmt.Sprintf("^%s$", keyArnPattern)).MatchString(value) && + !regexp.MustCompile(fmt.Sprintf("^%s$", aliasNamePattern)).MatchString(value) && + !regexp.MustCompile(fmt.Sprintf("^%s$", aliasArnPattern)).MatchString(value) { + errors = append(errors, fmt.Errorf("%q must be one of the following patterns: %s, %s, %s or %s", k, keyIdPattern, keyArnPattern, aliasNamePattern, aliasArnPattern)) } - - errors = append(errors, fmt.Errorf("expected %s to be one of %v, got %s", k, validBandWidth, val)) return } @@ -2157,57 +1606,6 @@ func validateAwsElastiCacheReplicationGroupAuthToken(v interface{}, k string) (w return } -func validateGameliftOperatingSystem(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - operatingSystems := map[string]bool{ - gamelift.OperatingSystemAmazonLinux: true, - gamelift.OperatingSystemWindows2012: true, - } - - if !operatingSystems[value] { - errors = append(errors, fmt.Errorf("%q must be a valid operating system value: %q", k, value)) - } - return -} - -func validateGuardDutyIpsetFormat(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - validType := []string{ - guardduty.IpSetFormatTxt, - guardduty.IpSetFormatStix, - guardduty.IpSetFormatOtxCsv, - guardduty.IpSetFormatAlienVault, - guardduty.IpSetFormatProofPoint, - guardduty.IpSetFormatFireEye, - } - for _, str := range validType { - if value == str { - return - } - } - errors = append(errors, fmt.Errorf("expected %s to be one of %v, got %s", k, validType, value)) - return -} - -func validateGuardDutyThreatIntelSetFormat(v interface{}, k string) (ws []string, errors []error) { - value := v.(string) - validType := []string{ - guardduty.ThreatIntelSetFormatTxt, - guardduty.ThreatIntelSetFormatStix, - guardduty.ThreatIntelSetFormatOtxCsv, - guardduty.ThreatIntelSetFormatAlienVault, - guardduty.ThreatIntelSetFormatProofPoint, - guardduty.ThreatIntelSetFormatFireEye, - } - for _, str := range validType { - if value == str { - return - } - } - errors = append(errors, fmt.Errorf("expected %s to be one of %v, got %s", k, validType, value)) - return -} - func validateDynamoDbStreamSpec(d *schema.ResourceDiff) error { enabled := d.Get("stream_enabled").(bool) if enabled { @@ -2292,3 +1690,53 @@ func validateIotThingTypeSearchableAttribute(v interface{}, k string) (ws []stri } return } + +func validateDynamoDbTableAttributes(d *schema.ResourceDiff) error { + // Collect all indexed attributes + primaryHashKey := d.Get("hash_key").(string) + indexedAttributes := map[string]bool{ + primaryHashKey: true, + } + if v, ok := d.GetOk("range_key"); ok { + indexedAttributes[v.(string)] = true + } + if v, ok := d.GetOk("local_secondary_index"); ok { + indexes := v.(*schema.Set).List() + for _, idx := range indexes { + index := idx.(map[string]interface{}) + rangeKey := index["range_key"].(string) + indexedAttributes[rangeKey] = true + } + } + if v, ok := d.GetOk("global_secondary_index"); ok { + indexes := v.(*schema.Set).List() + for _, idx := range indexes { + index := idx.(map[string]interface{}) + + hashKey := index["hash_key"].(string) + indexedAttributes[hashKey] = true + + if rk, ok := index["range_key"]; ok { + indexedAttributes[rk.(string)] = true + } + } + } + + // Check if all indexed attributes have an attribute definition + attributes := d.Get("attribute").(*schema.Set).List() + missingAttrDefs := []string{} + for _, attr := range attributes { + attribute := attr.(map[string]interface{}) + attrName := attribute["name"].(string) + + if _, ok := indexedAttributes[attrName]; !ok { + missingAttrDefs = append(missingAttrDefs, attrName) + } + } + + if len(missingAttrDefs) > 0 { + return fmt.Errorf("All attributes must be indexed. Unused attributes: %q", missingAttrDefs) + } + + return nil +} diff --git a/vendor/github.com/terraform-providers/terraform-provider-aws/aws/waf_helpers.go b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/waf_helpers.go new file mode 100644 index 000000000000..a54371af5657 --- /dev/null +++ b/vendor/github.com/terraform-providers/terraform-provider-aws/aws/waf_helpers.go @@ -0,0 +1,364 @@ +package aws + +import ( + "bytes" + "fmt" + "strings" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/service/waf" + "github.com/hashicorp/terraform/helper/hashcode" + "github.com/hashicorp/terraform/helper/schema" +) + +func wafSizeConstraintSetSchema() map[string]*schema.Schema { + return map[string]*schema.Schema{ + "name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + + "size_constraints": &schema.Schema{ + Type: schema.TypeSet, + Optional: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "field_to_match": { + Type: schema.TypeSet, + Required: true, + MaxItems: 1, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "data": { + Type: schema.TypeString, + Optional: true, + }, + "type": { + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + "comparison_operator": &schema.Schema{ + Type: schema.TypeString, + Required: true, + }, + "size": &schema.Schema{ + Type: schema.TypeInt, + Required: true, + }, + "text_transformation": &schema.Schema{ + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + } +} + +func diffWafSizeConstraints(oldS, newS []interface{}) []*waf.SizeConstraintSetUpdate { + updates := make([]*waf.SizeConstraintSetUpdate, 0) + + for _, os := range oldS { + constraint := os.(map[string]interface{}) + + if idx, contains := sliceContainsMap(newS, constraint); contains { + newS = append(newS[:idx], newS[idx+1:]...) + continue + } + + updates = append(updates, &waf.SizeConstraintSetUpdate{ + Action: aws.String(waf.ChangeActionDelete), + SizeConstraint: &waf.SizeConstraint{ + FieldToMatch: expandFieldToMatch(constraint["field_to_match"].(*schema.Set).List()[0].(map[string]interface{})), + ComparisonOperator: aws.String(constraint["comparison_operator"].(string)), + Size: aws.Int64(int64(constraint["size"].(int))), + TextTransformation: aws.String(constraint["text_transformation"].(string)), + }, + }) + } + + for _, ns := range newS { + constraint := ns.(map[string]interface{}) + + updates = append(updates, &waf.SizeConstraintSetUpdate{ + Action: aws.String(waf.ChangeActionInsert), + SizeConstraint: &waf.SizeConstraint{ + FieldToMatch: expandFieldToMatch(constraint["field_to_match"].(*schema.Set).List()[0].(map[string]interface{})), + ComparisonOperator: aws.String(constraint["comparison_operator"].(string)), + Size: aws.Int64(int64(constraint["size"].(int))), + TextTransformation: aws.String(constraint["text_transformation"].(string)), + }, + }) + } + return updates +} + +func flattenWafSizeConstraints(sc []*waf.SizeConstraint) []interface{} { + out := make([]interface{}, len(sc), len(sc)) + for i, c := range sc { + m := make(map[string]interface{}) + m["comparison_operator"] = *c.ComparisonOperator + if c.FieldToMatch != nil { + m["field_to_match"] = flattenFieldToMatch(c.FieldToMatch) + } + m["size"] = *c.Size + m["text_transformation"] = *c.TextTransformation + out[i] = m + } + return out +} + +func flattenWafGeoMatchConstraint(ts []*waf.GeoMatchConstraint) []interface{} { + out := make([]interface{}, len(ts), len(ts)) + for i, t := range ts { + m := make(map[string]interface{}) + m["type"] = *t.Type + m["value"] = *t.Value + out[i] = m + } + return out +} + +func diffWafGeoMatchSetConstraints(oldT, newT []interface{}) []*waf.GeoMatchSetUpdate { + updates := make([]*waf.GeoMatchSetUpdate, 0) + + for _, od := range oldT { + constraint := od.(map[string]interface{}) + + if idx, contains := sliceContainsMap(newT, constraint); contains { + newT = append(newT[:idx], newT[idx+1:]...) + continue + } + + updates = append(updates, &waf.GeoMatchSetUpdate{ + Action: aws.String(waf.ChangeActionDelete), + GeoMatchConstraint: &waf.GeoMatchConstraint{ + Type: aws.String(constraint["type"].(string)), + Value: aws.String(constraint["value"].(string)), + }, + }) + } + + for _, nd := range newT { + constraint := nd.(map[string]interface{}) + + updates = append(updates, &waf.GeoMatchSetUpdate{ + Action: aws.String(waf.ChangeActionInsert), + GeoMatchConstraint: &waf.GeoMatchConstraint{ + Type: aws.String(constraint["type"].(string)), + Value: aws.String(constraint["value"].(string)), + }, + }) + } + return updates +} + +func diffWafRegexPatternSetPatternStrings(oldPatterns, newPatterns []interface{}) []*waf.RegexPatternSetUpdate { + updates := make([]*waf.RegexPatternSetUpdate, 0) + + for _, op := range oldPatterns { + if idx, contains := sliceContainsString(newPatterns, op.(string)); contains { + newPatterns = append(newPatterns[:idx], newPatterns[idx+1:]...) + continue + } + + updates = append(updates, &waf.RegexPatternSetUpdate{ + Action: aws.String(waf.ChangeActionDelete), + RegexPatternString: aws.String(op.(string)), + }) + } + + for _, np := range newPatterns { + updates = append(updates, &waf.RegexPatternSetUpdate{ + Action: aws.String(waf.ChangeActionInsert), + RegexPatternString: aws.String(np.(string)), + }) + } + return updates +} + +func diffWafRulePredicates(oldP, newP []interface{}) []*waf.RuleUpdate { + updates := make([]*waf.RuleUpdate, 0) + + for _, op := range oldP { + predicate := op.(map[string]interface{}) + + if idx, contains := sliceContainsMap(newP, predicate); contains { + newP = append(newP[:idx], newP[idx+1:]...) + continue + } + + updates = append(updates, &waf.RuleUpdate{ + Action: aws.String(waf.ChangeActionDelete), + Predicate: &waf.Predicate{ + Negated: aws.Bool(predicate["negated"].(bool)), + Type: aws.String(predicate["type"].(string)), + DataId: aws.String(predicate["data_id"].(string)), + }, + }) + } + + for _, np := range newP { + predicate := np.(map[string]interface{}) + + updates = append(updates, &waf.RuleUpdate{ + Action: aws.String(waf.ChangeActionInsert), + Predicate: &waf.Predicate{ + Negated: aws.Bool(predicate["negated"].(bool)), + Type: aws.String(predicate["type"].(string)), + DataId: aws.String(predicate["data_id"].(string)), + }, + }) + } + return updates +} + +func sliceContainsString(slice []interface{}, s string) (int, bool) { + for idx, value := range slice { + v := value.(string) + if v == s { + return idx, true + } + } + return -1, false +} + +func diffWafRuleGroupActivatedRules(oldRules, newRules []interface{}) []*waf.RuleGroupUpdate { + updates := make([]*waf.RuleGroupUpdate, 0) + + for _, op := range oldRules { + rule := op.(map[string]interface{}) + + if idx, contains := sliceContainsMap(newRules, rule); contains { + newRules = append(newRules[:idx], newRules[idx+1:]...) + continue + } + + updates = append(updates, &waf.RuleGroupUpdate{ + Action: aws.String(waf.ChangeActionDelete), + ActivatedRule: expandWafActivatedRule(rule), + }) + } + + for _, np := range newRules { + rule := np.(map[string]interface{}) + + updates = append(updates, &waf.RuleGroupUpdate{ + Action: aws.String(waf.ChangeActionInsert), + ActivatedRule: expandWafActivatedRule(rule), + }) + } + return updates +} + +func flattenWafActivatedRules(activatedRules []*waf.ActivatedRule) []interface{} { + out := make([]interface{}, len(activatedRules), len(activatedRules)) + for i, ar := range activatedRules { + rule := map[string]interface{}{ + "priority": int(*ar.Priority), + "rule_id": *ar.RuleId, + "type": *ar.Type, + } + if ar.Action != nil { + rule["action"] = []interface{}{ + map[string]interface{}{ + "type": *ar.Action.Type, + }, + } + } + out[i] = rule + } + return out +} + +func expandWafActivatedRule(rule map[string]interface{}) *waf.ActivatedRule { + r := &waf.ActivatedRule{ + Priority: aws.Int64(int64(rule["priority"].(int))), + RuleId: aws.String(rule["rule_id"].(string)), + Type: aws.String(rule["type"].(string)), + } + + if a, ok := rule["action"].([]interface{}); ok && len(a) > 0 { + m := a[0].(map[string]interface{}) + r.Action = &waf.WafAction{ + Type: aws.String(m["type"].(string)), + } + } + return r +} + +func flattenWafRegexMatchTuples(tuples []*waf.RegexMatchTuple) []interface{} { + out := make([]interface{}, len(tuples), len(tuples)) + for i, t := range tuples { + m := make(map[string]interface{}) + + if t.FieldToMatch != nil { + m["field_to_match"] = flattenFieldToMatch(t.FieldToMatch) + } + m["regex_pattern_set_id"] = *t.RegexPatternSetId + m["text_transformation"] = *t.TextTransformation + + out[i] = m + } + return out +} + +func diffWafRegexMatchSetTuples(oldT, newT []interface{}) []*waf.RegexMatchSetUpdate { + updates := make([]*waf.RegexMatchSetUpdate, 0) + + for _, ot := range oldT { + tuple := ot.(map[string]interface{}) + + if idx, contains := sliceContainsMap(newT, tuple); contains { + newT = append(newT[:idx], newT[idx+1:]...) + continue + } + + ftm := tuple["field_to_match"].([]interface{}) + updates = append(updates, &waf.RegexMatchSetUpdate{ + Action: aws.String(waf.ChangeActionDelete), + RegexMatchTuple: &waf.RegexMatchTuple{ + FieldToMatch: expandFieldToMatch(ftm[0].(map[string]interface{})), + RegexPatternSetId: aws.String(tuple["regex_pattern_set_id"].(string)), + TextTransformation: aws.String(tuple["text_transformation"].(string)), + }, + }) + } + + for _, nt := range newT { + tuple := nt.(map[string]interface{}) + + ftm := tuple["field_to_match"].([]interface{}) + updates = append(updates, &waf.RegexMatchSetUpdate{ + Action: aws.String(waf.ChangeActionInsert), + RegexMatchTuple: &waf.RegexMatchTuple{ + FieldToMatch: expandFieldToMatch(ftm[0].(map[string]interface{})), + RegexPatternSetId: aws.String(tuple["regex_pattern_set_id"].(string)), + TextTransformation: aws.String(tuple["text_transformation"].(string)), + }, + }) + } + return updates +} + +func resourceAwsWafRegexMatchSetTupleHash(v interface{}) int { + var buf bytes.Buffer + m := v.(map[string]interface{}) + if v, ok := m["field_to_match"]; ok { + ftms := v.([]interface{}) + ftm := ftms[0].(map[string]interface{}) + + if v, ok := ftm["data"]; ok { + buf.WriteString(fmt.Sprintf("%s-", strings.ToLower(v.(string)))) + } + buf.WriteString(fmt.Sprintf("%s-", ftm["type"].(string))) + } + buf.WriteString(fmt.Sprintf("%s-", m["regex_pattern_set_id"].(string))) + buf.WriteString(fmt.Sprintf("%s-", m["text_transformation"].(string))) + + return hashcode.String(buf.String()) +} diff --git a/vendor/vendor.json b/vendor/vendor.json index 6dcdd3558e70..f9ca8daffcd5 100644 --- a/vendor/vendor.json +++ b/vendor/vendor.json @@ -261,776 +261,808 @@ "revisionTime": "2016-01-15T23:47:25Z" }, { - "checksumSHA1": "fQFz9TVTFLzLZBBTL/3nXt0PepA=", + "checksumSHA1": "Fs3DE5rdov9GRx+jUJ7VfG/EBvA=", "path": "github.com/aws/aws-sdk-go/aws", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "DtuTqKH29YnLjrIJkRYX0HQtXY0=", "path": "github.com/aws/aws-sdk-go/aws/arn", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "Y9W+4GimK4Fuxq+vyIskVYFRnX4=", "path": "github.com/aws/aws-sdk-go/aws/awserr", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "yyYr41HZ1Aq0hWc3J5ijXwYEcac=", "path": "github.com/aws/aws-sdk-go/aws/awsutil", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "9nE/FjZ4pYrT883KtV2/aI+Gayo=", + "checksumSHA1": "hicPtITUionsA+dgs1SpsZUkQu4=", "path": "github.com/aws/aws-sdk-go/aws/client", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "ieAJ+Cvp/PKv1LpUEnUXpc3OI6E=", "path": "github.com/aws/aws-sdk-go/aws/client/metadata", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "7/8j/q0TWtOgXyvEcv4B2Dhl00o=", + "checksumSHA1": "vVSUnICaD9IaBQisCfw0n8zLwig=", "path": "github.com/aws/aws-sdk-go/aws/corehandlers", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "Y+cPwQL0dZMyqp3wI+KJWmA9KQ8=", "path": "github.com/aws/aws-sdk-go/aws/credentials", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "u3GOAJLmdvbuNUeUEcZSEAOeL/0=", "path": "github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "NUJUTWlc1sV8b7WjfiYc4JZbXl0=", "path": "github.com/aws/aws-sdk-go/aws/credentials/endpointcreds", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "JEYqmF83O5n5bHkupAzA6STm0no=", "path": "github.com/aws/aws-sdk-go/aws/credentials/stscreds", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "OnU/n7R33oYXiB4SAGd5pK7I0Bs=", + "checksumSHA1": "HogDW/Wu6ZKTDrQ2HSzG8/vj9Ag=", "path": "github.com/aws/aws-sdk-go/aws/defaults", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "/EXbk/z2TWjWc1Hvb4QYs3Wmhb8=", + "checksumSHA1": "pDnK93CqjQ4ROSW8Y/RuHXjv52M=", "path": "github.com/aws/aws-sdk-go/aws/ec2metadata", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "LRonWcnvI95HVKs5fLa+wBU9A+E=", + "checksumSHA1": "Sv3a7nAY/z1ZHiQ1eN0SE0rLLtQ=", "path": "github.com/aws/aws-sdk-go/aws/endpoints", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "657ICMok3uC5dm5e9bKcVF2HaxE=", + "checksumSHA1": "CntJM8T3dRgC0e1i66CIbP8uCSY=", "path": "github.com/aws/aws-sdk-go/aws/request", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "DIn7B+oP++/nw603OB95fmupzu8=", + "checksumSHA1": "J66FLqo++F1PXLUU8XQqYaageSc=", "path": "github.com/aws/aws-sdk-go/aws/session", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "iU00ZjhAml/13g+1YXT21IqoXqg=", + "checksumSHA1": "BqDC+Sxo3hrC6WYvwx1U4OObaT4=", "path": "github.com/aws/aws-sdk-go/aws/signer/v4", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" + }, + { + "checksumSHA1": "wjxQlU1PYxrDRFoL1Vek8Wch7jk=", + "path": "github.com/aws/aws-sdk-go/internal/sdkio", + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" + }, + { + "checksumSHA1": "MYLldFRnsZh21TfCkgkXCT3maPU=", + "path": "github.com/aws/aws-sdk-go/internal/sdkrand", + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "04ypv4x12l4q0TksA1zEVsmgpvw=", "path": "github.com/aws/aws-sdk-go/internal/shareddefaults", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "NStHCXEvYqG72GknZyv1jaKaeH0=", "path": "github.com/aws/aws-sdk-go/private/protocol", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "1QmQ3FqV37w0Zi44qv8pA1GeR0A=", + "checksumSHA1": "GQuRJY72iGQrufDqIaB50zG27u0=", "path": "github.com/aws/aws-sdk-go/private/protocol/ec2query", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "yHfT5DTbeCLs4NE2Rgnqrhe15ls=", "path": "github.com/aws/aws-sdk-go/private/protocol/json/jsonutil", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "R00RL5jJXRYq1iiK1+PGvMfvXyM=", "path": "github.com/aws/aws-sdk-go/private/protocol/jsonrpc", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "ZqY5RWavBLWTo6j9xqdyBEaNFRk=", + "checksumSHA1": "SBBVYdLcocjdPzMWgDuR8vcOfDQ=", "path": "github.com/aws/aws-sdk-go/private/protocol/query", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "9V1PvtFQ9MObZTc3sa86WcuOtOU=", "path": "github.com/aws/aws-sdk-go/private/protocol/query/queryutil", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "pkeoOfZpHRvFG/AOZeTf0lwtsFg=", "path": "github.com/aws/aws-sdk-go/private/protocol/rest", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "Rpu8KBtHZgvhkwHxUfaky+qW+G4=", "path": "github.com/aws/aws-sdk-go/private/protocol/restjson", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "ODo+ko8D6unAxZuN1jGzMcN4QCc=", "path": "github.com/aws/aws-sdk-go/private/protocol/restxml", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "0qYPUga28aQVkxZgBR3Z86AbGUQ=", "path": "github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "F6mth+G7dXN1GI+nktaGo8Lx8aE=", "path": "github.com/aws/aws-sdk-go/private/signer/v2", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "Ih4il2OyFyaSuoMv6hhvPUN8Gn4=", + "checksumSHA1": "krjKYP+Z5qrFgZkHccphnuPdYd0=", "path": "github.com/aws/aws-sdk-go/service/acm", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "DPl/OkvEUjrd+XKqX73l6nUNw3U=", + "checksumSHA1": "rQmpNRto8bpB17qNubhGzRh/Aj8=", "path": "github.com/aws/aws-sdk-go/service/apigateway", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "edPLU/Lb9QzcB2tFBgkKvF/WdY8=", + "checksumSHA1": "7o1gMXoE8cemDzkZFUrQknQS4Yo=", "path": "github.com/aws/aws-sdk-go/service/applicationautoscaling", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "eXdYovPaIY64heZE1nczTsNRvtw=", + "checksumSHA1": "s0TQJfF7ZqeS9IH4hdvX5EQk2l8=", "path": "github.com/aws/aws-sdk-go/service/appsync", - "revision": "ebef4262e06a772a06a80aaee8e952c2514e1606", - "revisionTime": "2018-02-23T18:40:12Z" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "wrOVdI/6ZTZ/H0Kxjh3bBEZtVzk=", + "checksumSHA1": "YlKOG1eZClZYmcRwJQO+LfEQrVY=", "path": "github.com/aws/aws-sdk-go/service/athena", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "q4j8cW2zBulU/xx16A8/NxexXKE=", + "checksumSHA1": "58ARAtV4EKAIv5zpieVjvJMFjO0=", "path": "github.com/aws/aws-sdk-go/service/autoscaling", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "P5gDOoqIdVjMU77e5Nhy48QLpS4=", + "checksumSHA1": "leWnf/5HCZ3nD79LpJ0EDNQnNrI=", "path": "github.com/aws/aws-sdk-go/service/batch", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "EoaTzMilW+OIi5eETJUpd+giyTc=", + "checksumSHA1": "AQGPL+fXjjKhBmyb37QAG05R/Qw=", "path": "github.com/aws/aws-sdk-go/service/cloud9", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "yuFNzmUIWppfji/Xx6Aao0EE4cY=", + "checksumSHA1": "NU6AqUCd5TOrxaqFdWmo8l2oeOI=", "path": "github.com/aws/aws-sdk-go/service/cloudformation", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "0nPnGWlegQG7bn/iIIfjJFoljyU=", + "checksumSHA1": "hCz5z7QQz1416cCjbhjGjvbrdpY=", "path": "github.com/aws/aws-sdk-go/service/cloudfront", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "VTc9UOMqIwuhWJ6oGQDsMkTW09I=", + "checksumSHA1": "pKJec2iJiKDSY5UKmLSeYxLxucg=", "path": "github.com/aws/aws-sdk-go/service/cloudtrail", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "ItXljM1vG/0goVleodRgbfYgyxQ=", + "checksumSHA1": "BD7EvXghMHMw52wtxISIhpJ4CTk=", "path": "github.com/aws/aws-sdk-go/service/cloudwatch", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "5lmoDceAWT0vrUTf3wKAaZRXwbg=", + "checksumSHA1": "6Q9ZHEAsu92jsFOCwJAI+SjYYAk=", "path": "github.com/aws/aws-sdk-go/service/cloudwatchevents", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "HHct8eQygkIJ+vrQpKhB0IEDymQ=", + "checksumSHA1": "YNl9xTPOb1SFVmwXDtmwzyGsx8U=", "path": "github.com/aws/aws-sdk-go/service/cloudwatchlogs", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "22txzj8ItH1+lzyyLlFz/vtRV2I=", + "checksumSHA1": "p/I/GLsXOoZ0XdhDuSQ+lP4NlYM=", "path": "github.com/aws/aws-sdk-go/service/codebuild", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "RRQCgy4s3k6CJQae3ueLepkK4PI=", + "checksumSHA1": "4KiQdvEfpTf2g+UF2rWlLg/kgok=", "path": "github.com/aws/aws-sdk-go/service/codecommit", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "wvXGTyWPjtgC4OjXb80IxYdpqmE=", + "checksumSHA1": "mLFFVXyhKLYgoKSJ17URM/GXdNc=", "path": "github.com/aws/aws-sdk-go/service/codedeploy", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "V1Y05qfjN4xOCy+GnPWSCqIeZb4=", + "checksumSHA1": "bh5IjjK9tKextJTq+gLV+6zhmL8=", "path": "github.com/aws/aws-sdk-go/service/codepipeline", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "Ju8efcqcIgggB7N8io/as9ERVdc=", + "checksumSHA1": "cx2wG4c6Q5gSTsAU6D/UZMQN/Kg=", "path": "github.com/aws/aws-sdk-go/service/cognitoidentity", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "jeCyZm4iJmOLbVOe/70QNkII+qU=", + "checksumSHA1": "k4lfEcz91J29Wax6GPBlUUQb5bk=", "path": "github.com/aws/aws-sdk-go/service/cognitoidentityprovider", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "kt8wGmAKAo+iC1dR/g9iJn46nDo=", + "checksumSHA1": "qrxVu09idcoHIT2HqDJIbV3weUE=", "path": "github.com/aws/aws-sdk-go/service/configservice", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "45sgs1urdRiXDb35iuAhQPzl0e4=", + "checksumSHA1": "2CBd4VCNpKFk/fBIsLEJNG2Shps=", "path": "github.com/aws/aws-sdk-go/service/databasemigrationservice", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "bu1R1eKCK2fc5+hMcXmagr3iIik=", + "checksumSHA1": "I5sSvXLvlj9Ppv0HCbFXdN4tqn4=", "path": "github.com/aws/aws-sdk-go/service/dax", - "revision": "ebef4262e06a772a06a80aaee8e952c2514e1606", - "revisionTime": "2018-02-23T18:40:12Z" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "EaEfUc3nt1sS/cdfSYGq+JtSVKs=", + "checksumSHA1": "WMCgYV6S5ZeQo6pjIFTStdmBVcg=", "path": "github.com/aws/aws-sdk-go/service/devicefarm", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "LRdh5oXUe2yURIk5FDH6ceEZGMo=", + "checksumSHA1": "hurqUivjVxLHaXEd2oS8JrwMGQs=", "path": "github.com/aws/aws-sdk-go/service/directconnect", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "a7itHIwtyXtOGQ0KsiefmsHgu4s=", + "checksumSHA1": "zxX7V0AIU1x2yX5Uyd9RMe0C3ok=", "path": "github.com/aws/aws-sdk-go/service/directoryservice", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "8JiVrxMjFSdBOfVWCy1QU+JzB08=", + "checksumSHA1": "Ae8sc+KEu6BMw89WRwaq4Ol/87g=", "path": "github.com/aws/aws-sdk-go/service/dynamodb", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "Wt2FgZmez84iZmcDjR2pof13dTQ=", + "checksumSHA1": "12jA2n3aIJzdwvOxl+dvtx5S4CI=", "path": "github.com/aws/aws-sdk-go/service/ec2", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "kEgV0dSAj3M3M1waEkC27JS7VnU=", + "checksumSHA1": "V3D5pDdtXS0yVShpS/fOqFGxCrA=", "path": "github.com/aws/aws-sdk-go/service/ecr", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "WeevJuELH3BFpUQJC4cqZODz4c0=", + "checksumSHA1": "7igFr0esmtcs9V0F9iMs2k5uNDI=", "path": "github.com/aws/aws-sdk-go/service/ecs", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "4XmkiujbDA68x39KGgURR1+uPiQ=", + "checksumSHA1": "PQnfXJ0ZQIIMiqUUFs4bkUPHqnc=", "path": "github.com/aws/aws-sdk-go/service/efs", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "o73xT1zFo3C+giQwKcRj02OAZhM=", + "checksumSHA1": "pZoO4JKc/TJACuq1n9IHuhovD4k=", "path": "github.com/aws/aws-sdk-go/service/elasticache", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "1U0w3+W7kvH901jSftehitrRHCg=", + "checksumSHA1": "s0INIDkP10AOmJkmTpCHpazIwUw=", "path": "github.com/aws/aws-sdk-go/service/elasticbeanstalk", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "VYGtTaSiajfKOVTbi9/SNmbiIac=", + "checksumSHA1": "BSSURh/ALTj0QW5BWPJkW3i+FN0=", "path": "github.com/aws/aws-sdk-go/service/elasticsearchservice", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "SZ7yLDZ6RvMhpWe0Goyem64kgyA=", + "checksumSHA1": "JpvcQ+tc0yz2WZ0ne6zzxlbfscI=", "path": "github.com/aws/aws-sdk-go/service/elastictranscoder", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "iRI32eUYQfumh0LybzZ+5iWV3jE=", + "checksumSHA1": "MgdGxbP8vjCkzkj1ukmU5Uqh3UA=", "path": "github.com/aws/aws-sdk-go/service/elb", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "SvXeFtI3yR9UmamKEYKY/diBWDY=", + "checksumSHA1": "hgqHUngsP+NPjkZVqevXuioHnkE=", "path": "github.com/aws/aws-sdk-go/service/elbv2", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "5x77vwxya74Qu5YEq75/lhyYkqY=", + "checksumSHA1": "OQuas8ovzB34Yb2bCMBDsu8teu4=", "path": "github.com/aws/aws-sdk-go/service/emr", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "t7BmfpJqmQ7Y0EYcj/CR9Aup9go=", + "checksumSHA1": "hUosfOQhleGpv6UWGnbDf/eB5Ts=", "path": "github.com/aws/aws-sdk-go/service/firehose", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "iHyMxl+rkonWCTlysoO4ISkumCA=", + "checksumSHA1": "UPwhm+XWgDTDZ4wUziP+9RHOozg=", "path": "github.com/aws/aws-sdk-go/service/gamelift", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "oDoGvSfmO2Z099ixV2HXn+SDeHE=", + "checksumSHA1": "N1F3vRsnxAZyfr4v7iK+MagWuGU=", "path": "github.com/aws/aws-sdk-go/service/glacier", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "M01rYrldc6zwbpAeaLX5UJ6b25g=", + "checksumSHA1": "Mc6WHGaAikP+uYx38VtKbl5KEYE=", "path": "github.com/aws/aws-sdk-go/service/glue", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "VRaMYP1928z+aLVk2qX5OPFaobk=", + "checksumSHA1": "YZJXefe33AjqEWaIm8ufdQc0atE=", "path": "github.com/aws/aws-sdk-go/service/guardduty", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "I8CWKTI9BLrIF9ZKf6SpWhG+LXM=", + "checksumSHA1": "DHrIPXQ0QzjE+Hnfwk0INR4rUkU=", "path": "github.com/aws/aws-sdk-go/service/iam", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "45gdBZuM7PWLQzWuBasytvZZpK0=", + "checksumSHA1": "pvrqgHDeZ3gAHIiZyZfwXOi9GD4=", "path": "github.com/aws/aws-sdk-go/service/inspector", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "pZwCI4DpP5hcMa/ItKhiwo/ukd0=", + "checksumSHA1": "TpvdN/5q0qLBHZhQQlB4cyQOxR4=", "path": "github.com/aws/aws-sdk-go/service/iot", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "DfzNze8B3ME2tV3TtXP7eQXUjD0=", + "checksumSHA1": "zdG3e3bdyNaBuApO06pygeSJsJ4=", "path": "github.com/aws/aws-sdk-go/service/kinesis", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "Vqq049R2eveVD15emT9vKTyBsIg=", + "checksumSHA1": "zmOo5EeLSGFEuIBiRQsVd4+SBJ0=", "path": "github.com/aws/aws-sdk-go/service/kms", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "lAgaKbwpyflY7+t4V3EeH18RwgA=", + "checksumSHA1": "nlvFlqVKHyuyYHG88H3Yt/OA1e0=", "path": "github.com/aws/aws-sdk-go/service/lambda", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "4yGrGQatXcr8eGRWUoBg3KqAHK8=", + "checksumSHA1": "AO97b1GChOs2geiFc//6YcpVfX8=", + "path": "github.com/aws/aws-sdk-go/service/lexmodelbuildingservice", + "revision": "f63b41ba024702aca32b063327a0852f9758d914", + "revisionTime": "2018-04-19T23:04:09Z" + }, + { + "checksumSHA1": "jyxQ6TEdSl9/j7qC0LCkVMSXkog=", "path": "github.com/aws/aws-sdk-go/service/lightsail", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "kEZmPI9Y9+05SWuRCdtt+QkqwLI=", + "checksumSHA1": "I1sxeu8aJOiM3a5/tnJya8blE3A=", "path": "github.com/aws/aws-sdk-go/service/mediastore", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "3QV+ZVkQ8g8JkNkftwHaOCevyqM=", + "checksumSHA1": "lAweYYdjcZ6acj6oI3HI9hX3eIQ=", "path": "github.com/aws/aws-sdk-go/service/mq", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "QuOSKqV8nFvvzN4wcsToltMFI1Y=", + "checksumSHA1": "X/WdGuHGMxRCvufmQxstVjdbFT4=", "path": "github.com/aws/aws-sdk-go/service/opsworks", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" + }, + { + "checksumSHA1": "smOJ/rypXb18/Rjryf2a85paSa4=", + "path": "github.com/aws/aws-sdk-go/service/organizations", + "revision": "f63b41ba024702aca32b063327a0852f9758d914", + "revisionTime": "2018-04-19T23:04:09Z" }, { - "checksumSHA1": "LI+fV4xrVf/bHYHt3nCb3rhc7+c=", + "checksumSHA1": "vL235vodhgG61BkUxRD4B7io+zk=", "path": "github.com/aws/aws-sdk-go/service/rds", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "Pj9IgrR635tqA0YamoSC1GaHeao=", + "checksumSHA1": "kapXC7OZ1fnkZ3N6p19+WUafn40=", "path": "github.com/aws/aws-sdk-go/service/redshift", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "EaDeOWEVUQ21y3cFDyDuZPaK470=", + "checksumSHA1": "Hi/sxx81pqe+fI5VrS5+UK2DsDU=", "path": "github.com/aws/aws-sdk-go/service/route53", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "fXQn3V0ZRBZpTXUEHl4/yOjR4mQ=", + "checksumSHA1": "KidzwXO5VKKI9zIuTAUsuF7KxIM=", "path": "github.com/aws/aws-sdk-go/service/s3", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "rtKbVK1uZVIdkTR7yJIhAte97XQ=", + "checksumSHA1": "cyCJGeDReKwRq69kTcd4lozkuIg=", "path": "github.com/aws/aws-sdk-go/service/servicecatalog", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "erg+1BSdtfOk1KFXmnJ2bFHJpBY=", + "checksumSHA1": "NLj37wyUZIo8/Rp3zp+LDfr878M=", "path": "github.com/aws/aws-sdk-go/service/servicediscovery", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "8LeTeLzNs+0vNxTeOjMCtSrSwqo=", + "checksumSHA1": "nXAp7K8BCFvsaSdorGV7swBEQgA=", "path": "github.com/aws/aws-sdk-go/service/ses", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "u3AMeFxtHGtiJCxDeIm4dAwzBIc=", + "checksumSHA1": "q4qCE/5OiBJA1k8P0jQRx9UhKvs=", "path": "github.com/aws/aws-sdk-go/service/sfn", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "B3CgAFSREebpsFoFOo4vrQ6u04w=", + "checksumSHA1": "hAIPfcEcdc8xJ7MseIufmssdE/s=", "path": "github.com/aws/aws-sdk-go/service/simpledb", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "9Qj8yLl67q9uxBUCc0PT20YiP1M=", + "checksumSHA1": "1Fin0tclPDC/+rL7V06GrzXaMXI=", "path": "github.com/aws/aws-sdk-go/service/sns", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "XmEJe50M8MddNEkwbZoC+YvRjgg=", + "checksumSHA1": "T8ABBS2aS6yRTD6w3kjpgFLe/Zw=", "path": "github.com/aws/aws-sdk-go/service/sqs", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "jl3IYnqe0OFL2bemYhF5tLOwvvs=", + "checksumSHA1": "IHVhprySAcelCzbTU/eumCZNu1I=", "path": "github.com/aws/aws-sdk-go/service/ssm", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "x7HCNPJnQi+4P6FKpBTY1hm3m6o=", + "checksumSHA1": "llx3DydC0nTbF0cZoYUjO9P1eZw=", "path": "github.com/aws/aws-sdk-go/service/sts", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "ZKwkpd+UVwEKTOMhsbNpfXGUIvI=", + "checksumSHA1": "Mf9nXjY0+Lq5RxEGEIYCYL8u+Kc=", "path": "github.com/aws/aws-sdk-go/service/waf", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { - "checksumSHA1": "Uk2A+lTH7aAlQlkj7WIm2RFZV8A=", + "checksumSHA1": "iRNs3RoLjrzcBsPrSynhbEqY/4s=", "path": "github.com/aws/aws-sdk-go/service/wafregional", - "revision": "ebc8a649dc2a7c78c9237c2575a63b3efd6d0a2d", - "revisionTime": "2018-02-12T21:53:52Z", - "version": "v1.12.75", - "versionExact": "v1.12.75" + "revision": "7f68df2a5baf19398d17def23a514a6e617e5937", + "revisionTime": "2018-04-04T18:37:54Z", + "version": "v1.13.28", + "versionExact": "v1.13.28" }, { "checksumSHA1": "usT4LCSQItkFvFOQT7cBlkCuGaE=", @@ -2190,20 +2222,20 @@ "revisionTime": "2018-01-15T19:27:20Z" }, { - "checksumSHA1": "TZcEg85gFLvAxihpYP99r6espQE=", + "checksumSHA1": "il+FbGDKwMfS/1uSj+FEliiFAS4=", "path": "github.com/terraform-providers/terraform-provider-aws", - "revision": "684291f45b87da88f39a8b4050ebc1c5e6c2f6e0", - "revisionTime": "2018-02-24T22:47:55Z", - "version": "v1.10.0", - "versionExact": "v1.10.0" + "revision": "6b76cd7527bb204337dc23a3254b345f3cfe4ef8", + "revisionTime": "2018-04-11T17:49:04Z", + "version": "v1.14.1", + "versionExact": "v1.14.1" }, { - "checksumSHA1": "jBr0FKeswC9xVg758hOtM/Mb1fA=", + "checksumSHA1": "lObAHyWim5InTKVxY2MPZiCVvmc=", "path": "github.com/terraform-providers/terraform-provider-aws/aws", - "revision": "684291f45b87da88f39a8b4050ebc1c5e6c2f6e0", - "revisionTime": "2018-02-24T22:47:55Z", - "version": "v1.10.0", - "versionExact": "v1.10.0" + "revision": "6b76cd7527bb204337dc23a3254b345f3cfe4ef8", + "revisionTime": "2018-04-11T17:49:04Z", + "version": "v1.14.1", + "versionExact": "v1.14.1" }, { "checksumSHA1": "7WDq0VsOJmABPUCEvfuerEp7mBg=",