{
  "typeName" : "AWS::EC2::VerifiedAccessEndpoint",
  "description" : "The AWS::EC2::VerifiedAccessEndpoint resource creates an AWS EC2 Verified Access Endpoint.",
  "sourceUrl" : "https://github.com/aws-cloudformation/aws-cloudformation-resource-providers-ec2-verified-access.aws-ec2-verifiedaccessendpoint",
  "properties" : {
    "VerifiedAccessEndpointId" : {
      "description" : "The ID of the AWS Verified Access endpoint.",
      "type" : "string"
    },
    "VerifiedAccessGroupId" : {
      "description" : "The ID of the AWS Verified Access group.",
      "type" : "string"
    },
    "VerifiedAccessInstanceId" : {
      "description" : "The ID of the AWS Verified Access instance.",
      "type" : "string"
    },
    "Status" : {
      "description" : "The endpoint status.",
      "type" : "string"
    },
    "SecurityGroupIds" : {
      "description" : "The IDs of the security groups for the endpoint.",
      "type" : "array",
      "uniqueItems" : true,
      "insertionOrder" : false,
      "items" : {
        "$ref" : "#/definitions/SecurityGroupId"
      }
    },
    "NetworkInterfaceOptions" : {
      "description" : "The options for network-interface type endpoint.",
      "$ref" : "#/definitions/NetworkInterfaceOptions"
    },
    "LoadBalancerOptions" : {
      "description" : "The load balancer details if creating the AWS Verified Access endpoint as load-balancer type.",
      "$ref" : "#/definitions/LoadBalancerOptions"
    },
    "RdsOptions" : {
      "description" : "The options for rds type endpoint.",
      "$ref" : "#/definitions/RdsOptions"
    },
    "CidrOptions" : {
      "description" : "The options for cidr type endpoint.",
      "$ref" : "#/definitions/CidrOptions"
    },
    "EndpointType" : {
      "description" : "The type of AWS Verified Access endpoint. Incoming application requests will be sent to an IP address, load balancer or a network interface depending on the endpoint type specified.The type of AWS Verified Access endpoint. Incoming application requests will be sent to an IP address, load balancer or a network interface depending on the endpoint type specified.",
      "type" : "string"
    },
    "EndpointDomain" : {
      "description" : "A DNS name that is generated for the endpoint.",
      "type" : "string"
    },
    "EndpointDomainPrefix" : {
      "description" : "A custom identifier that gets prepended to a DNS name that is generated for the endpoint.",
      "type" : "string"
    },
    "DeviceValidationDomain" : {
      "description" : "Returned if endpoint has a device trust provider attached.",
      "type" : "string"
    },
    "DomainCertificateArn" : {
      "description" : "The ARN of a public TLS/SSL certificate imported into or created with ACM.",
      "type" : "string"
    },
    "AttachmentType" : {
      "description" : "The type of attachment used to provide connectivity between the AWS Verified Access endpoint and the application.",
      "type" : "string"
    },
    "ApplicationDomain" : {
      "description" : "The DNS name for users to reach your application.",
      "type" : "string"
    },
    "CreationTime" : {
      "description" : "The creation time.",
      "type" : "string"
    },
    "LastUpdatedTime" : {
      "description" : "The last updated time.",
      "type" : "string"
    },
    "Description" : {
      "description" : "A description for the AWS Verified Access endpoint.",
      "type" : "string"
    },
    "PolicyDocument" : {
      "description" : "The AWS Verified Access policy document.",
      "type" : "string"
    },
    "PolicyEnabled" : {
      "description" : "The status of the Verified Access policy.",
      "type" : "boolean"
    },
    "Tags" : {
      "description" : "An array of key-value pairs to apply to this resource.",
      "type" : "array",
      "uniqueItems" : true,
      "insertionOrder" : false,
      "items" : {
        "$ref" : "#/definitions/Tag"
      }
    },
    "SseSpecification" : {
      "description" : "The configuration options for customer provided KMS encryption.",
      "$ref" : "#/definitions/SseSpecification"
    }
  },
  "definitions" : {
    "SecurityGroupId" : {
      "description" : "The ID of a security group for the endpoint.",
      "type" : "string"
    },
    "NetworkInterfaceOptions" : {
      "description" : "The options for network-interface type endpoint.",
      "type" : "object",
      "properties" : {
        "NetworkInterfaceId" : {
          "description" : "The ID of the network interface.",
          "type" : "string"
        },
        "Port" : {
          "description" : "The IP port number.",
          "type" : "integer",
          "minimum" : 1,
          "maximum" : 65535
        },
        "PortRanges" : {
          "description" : "The list of port ranges.",
          "type" : "array",
          "uniqueItems" : true,
          "insertionOrder" : false,
          "items" : {
            "$ref" : "#/definitions/PortRange"
          }
        },
        "Protocol" : {
          "description" : "The IP protocol.",
          "type" : "string"
        }
      },
      "additionalProperties" : false
    },
    "LoadBalancerOptions" : {
      "description" : "The load balancer details if creating the AWS Verified Access endpoint as load-balancertype.",
      "type" : "object",
      "properties" : {
        "LoadBalancerArn" : {
          "description" : "The ARN of the load balancer.",
          "type" : "string"
        },
        "Port" : {
          "description" : "The IP port number.",
          "type" : "integer",
          "minimum" : 1,
          "maximum" : 65535
        },
        "PortRanges" : {
          "description" : "The list of port range.",
          "type" : "array",
          "uniqueItems" : true,
          "insertionOrder" : false,
          "items" : {
            "$ref" : "#/definitions/PortRange"
          }
        },
        "Protocol" : {
          "description" : "The IP protocol.",
          "type" : "string"
        },
        "SubnetIds" : {
          "description" : "The IDs of the subnets.",
          "type" : "array",
          "uniqueItems" : true,
          "insertionOrder" : false,
          "items" : {
            "$ref" : "#/definitions/SubnetId"
          }
        }
      },
      "additionalProperties" : false
    },
    "RdsOptions" : {
      "description" : "The options for rds type endpoint.",
      "type" : "object",
      "properties" : {
        "Protocol" : {
          "description" : "The IP protocol.",
          "type" : "string"
        },
        "Port" : {
          "description" : "The IP port number.",
          "type" : "integer",
          "minimum" : 1,
          "maximum" : 65535
        },
        "RdsDbInstanceArn" : {
          "description" : "The ARN of the RDS DB instance.",
          "type" : "string"
        },
        "RdsDbClusterArn" : {
          "description" : "The ARN of the RDS DB cluster.",
          "type" : "string"
        },
        "RdsDbProxyArn" : {
          "description" : "The ARN of the RDS DB proxy.",
          "type" : "string"
        },
        "RdsEndpoint" : {
          "description" : "The RDS endpoint.",
          "type" : "string"
        },
        "SubnetIds" : {
          "description" : "The IDs of the subnets.",
          "type" : "array",
          "uniqueItems" : true,
          "insertionOrder" : false,
          "items" : {
            "$ref" : "#/definitions/SubnetId"
          }
        }
      },
      "additionalProperties" : false
    },
    "CidrOptions" : {
      "description" : "The options for cidr type endpoint.",
      "type" : "object",
      "properties" : {
        "Cidr" : {
          "description" : "The IP address range, in CIDR notation.",
          "type" : "string"
        },
        "PortRanges" : {
          "description" : "The list of port range.",
          "type" : "array",
          "uniqueItems" : true,
          "insertionOrder" : false,
          "items" : {
            "$ref" : "#/definitions/PortRange"
          }
        },
        "Protocol" : {
          "description" : "The IP protocol.",
          "type" : "string"
        },
        "SubnetIds" : {
          "description" : "The IDs of the subnets.",
          "type" : "array",
          "uniqueItems" : true,
          "insertionOrder" : false,
          "items" : {
            "$ref" : "#/definitions/SubnetId"
          }
        }
      },
      "additionalProperties" : false
    },
    "PortRange" : {
      "description" : "The IP port range.",
      "type" : "object",
      "properties" : {
        "FromPort" : {
          "description" : "The first port in the range.",
          "type" : "integer",
          "minimum" : 1,
          "maximum" : 65535
        },
        "ToPort" : {
          "description" : "The last port in the range.",
          "type" : "integer",
          "minimum" : 1,
          "maximum" : 65535
        }
      },
      "additionalProperties" : false
    },
    "SubnetId" : {
      "description" : "The IDs of the subnet.",
      "type" : "string"
    },
    "Tag" : {
      "description" : "A key-value pair to associate with a resource.",
      "type" : "object",
      "properties" : {
        "Key" : {
          "type" : "string",
          "description" : "The key name of the tag. You can specify a value that is 1 to 128 Unicode characters in length and cannot be prefixed with aws:. You can use any of the following characters: the set of Unicode letters, digits, whitespace, _, ., /, =, +, and -.",
          "minLength" : 1,
          "maxLength" : 128
        },
        "Value" : {
          "type" : "string",
          "description" : "The value for the tag. You can specify a value that is 0 to 256 Unicode characters in length and cannot be prefixed with aws:. You can use any of the following characters: the set of Unicode letters, digits, whitespace, _, ., /, =, +, and -.",
          "minLength" : 0,
          "maxLength" : 256
        }
      },
      "required" : [ "Key", "Value" ],
      "additionalProperties" : false
    },
    "SseSpecification" : {
      "description" : "The configuration options for customer provided KMS encryption.",
      "type" : "object",
      "properties" : {
        "KmsKeyArn" : {
          "description" : "KMS Key Arn used to encrypt the group policy",
          "type" : "string"
        },
        "CustomerManagedKeyEnabled" : {
          "description" : "Whether to encrypt the policy with the provided key or disable encryption",
          "type" : "boolean"
        }
      },
      "additionalProperties" : false
    }
  },
  "additionalProperties" : false,
  "required" : [ "AttachmentType", "EndpointType", "VerifiedAccessGroupId" ],
  "readOnlyProperties" : [ "/properties/VerifiedAccessEndpointId", "/properties/EndpointDomain", "/properties/CreationTime", "/properties/LastUpdatedTime", "/properties/Status", "/properties/DeviceValidationDomain", "/properties/VerifiedAccessInstanceId" ],
  "createOnlyProperties" : [ "/properties/ApplicationDomain", "/properties/AttachmentType", "/properties/DomainCertificateArn", "/properties/EndpointDomainPrefix", "/properties/EndpointType", "/properties/SecurityGroupIds", "/properties/NetworkInterfaceOptions/NetworkInterfaceId", "/properties/LoadBalancerOptions/LoadBalancerArn", "/properties/RdsOptions/Protocol", "/properties/RdsOptions/RdsDbInstanceArn", "/properties/RdsOptions/RdsDbClusterArn", "/properties/RdsOptions/RdsDbProxyArn", "/properties/CidrOptions/Cidr", "/properties/CidrOptions/Protocol", "/properties/CidrOptions/SubnetIds" ],
  "primaryIdentifier" : [ "/properties/VerifiedAccessEndpointId" ],
  "tagging" : {
    "taggable" : true,
    "tagOnCreate" : true,
    "tagUpdatable" : true,
    "cloudFormationSystemTags" : false,
    "tagProperty" : "/properties/Tags",
    "permissions" : [ "ec2:CreateTags", "ec2:DescribeTags", "ec2:DeleteTags" ]
  },
  "handlers" : {
    "create" : {
      "permissions" : [ "ec2:CreateVerifiedAccessEndpoint", "ec2:DescribeVerifiedAccessEndpoints", "ec2:DescribeSubnets", "ec2:DescribeSecurityGroups", "ec2:DescribeNetworkInterfaces", "ec2:DescribeAccountAttributes", "ec2:CreateTags", "ec2:DescribeTags", "ec2:DescribeVpcs", "ec2:GetVerifiedAccessEndpointPolicy", "elasticloadbalancing:DescribeLoadBalancers", "elasticloadbalancing:DescribeListeners", "elasticloadbalancing:DescribeListenerCertificates", "iam:CreateServiceLinkedRole", "acm:DescribeCertificate", "sso:PutApplicationAccessScope", "sso:GetSharedSsoConfiguration", "sso:CreateManagedApplicationInstance", "sso:DeleteManagedApplicationInstance", "kms:DescribeKey", "kms:GenerateDataKey", "kms:RetireGrant", "kms:CreateGrant", "kms:Decrypt", "rds:DescribeDbInstances", "rds:DescribeDbProxies", "rds:DescribeDbClusters", "ec2:DescribeAvailabilityZones", "ec2:DescribeVpcEndpointServiceConfigurations" ],
      "timeoutInMinutes" : 600
    },
    "read" : {
      "permissions" : [ "ec2:DescribeVerifiedAccessEndpoints", "ec2:GetVerifiedAccessEndpointPolicy", "ec2:DescribeTags", "kms:DescribeKey", "kms:Decrypt", "kms:GenerateDataKey" ]
    },
    "update" : {
      "permissions" : [ "ec2:ModifyVerifiedAccessEndpoint", "ec2:ModifyVerifiedAccessEndpointPolicy", "ec2:DescribeVerifiedAccessEndpoints", "ec2:GetVerifiedAccessEndpointPolicy", "ec2:DescribeSubnets", "ec2:DescribeSecurityGroups", "ec2:DescribeNetworkInterfaces", "ec2:DescribeVpcs", "ec2:DescribeTags", "ec2:DeleteTags", "ec2:CreateTags", "elasticloadbalancing:DescribeLoadBalancers", "elasticloadbalancing:DescribeListeners", "elasticloadbalancing:DescribeListenerCertificates", "kms:DescribeKey", "kms:GenerateDataKey", "kms:RetireGrant", "kms:CreateGrant", "kms:Decrypt", "rds:DescribeDbInstances", "rds:DescribeDbProxies", "rds:DescribeDbClusters" ],
      "timeoutInMinutes" : 60
    },
    "delete" : {
      "permissions" : [ "ec2:DescribeVerifiedAccessEndpoints", "ec2:DeleteVerifiedAccessEndpoint", "ec2:GetVerifiedAccessEndpointPolicy", "ec2:DescribeTags", "ec2:DeleteTags", "sso:DeleteManagedApplicationInstance", "kms:DescribeKey", "kms:RetireGrant", "kms:Decrypt", "kms:GenerateDataKey" ],
      "timeoutInMinutes" : 60
    },
    "list" : {
      "permissions" : [ "ec2:DescribeVerifiedAccessEndpoints", "ec2:GetVerifiedAccessEndpointPolicy", "ec2:DescribeTags", "kms:DescribeKey", "kms:Decrypt", "kms:GenerateDataKey" ]
    }
  }
}