Amazon Elastic Container Service for Kubernetes
API Reference (API Version 2017-11-01)


Creates an Amazon EKS control plane.

The Amazon EKS control plane consists of control plane instances that run the Kubernetes software, like etcd and the API server. The control plane runs in an account managed by AWS, and the Kubernetes API is exposed via the Amazon EKS API server endpoint.

Amazon EKS worker nodes run in your AWS account and connect to your cluster's control plane via the Kubernetes API server endpoint and a certificate file that is created for your cluster.

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

After you create an Amazon EKS cluster, you must configure your Kubernetes tooling to communicate with the API server and launch worker nodes into your cluster. For more information, see Managing Cluster Authentication and Launching Amazon EKS Worker Nodesin the Amazon EKS User Guide.

Request Syntax

POST /clusters HTTP/1.1 Content-type: application/json { "clientRequestToken": "string", "name": "string", "resourcesVpcConfig": { "securityGroupIds": [ "string" ], "subnetIds": [ "string" ] }, "roleArn": "string", "version": "string" }

URI Request Parameters

The request does not use any URI parameters.

Request Body

The request accepts the following data in JSON format.


Unique, case-sensitive identifier that you provide to ensure the idempotency of the request.

Type: String

Required: No


The unique name to give to your cluster.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 100.

Pattern: ^[0-9A-Za-z][A-Za-z0-9\-_]*

Required: Yes


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

Type: VpcConfigRequest object

Required: Yes


The Amazon Resource Name (ARN) of the IAM role that provides permissions for Amazon EKS to make calls to other AWS API operations on your behalf. For more information, see Amazon EKS Service IAM Role in the Amazon EKS User Guide .

Type: String

Required: Yes


The desired Kubernetes version for your cluster. If you do not specify a value here, the latest version available in Amazon EKS is used.

Type: String

Required: No

Response Syntax

HTTP/1.1 200 Content-type: application/json { "cluster": { "arn": "string", "certificateAuthority": { "data": "string" }, "clientRequestToken": "string", "createdAt": number, "endpoint": "string", "name": "string", "platformVersion": "string", "resourcesVpcConfig": { "securityGroupIds": [ "string" ], "subnetIds": [ "string" ], "vpcId": "string" }, "roleArn": "string", "status": "string", "version": "string" } }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.


The full description of your new cluster.

Type: Cluster object


For information about the errors that are common to all actions, see Common Errors.


These errors are usually caused by a client action. Actions can include using an action or resource on behalf of a user that doesn't have permissions to use the action or resource or specifying an identifier that is not valid.

HTTP Status Code: 400


The specified parameter is invalid. Review the available parameters for the API request.

HTTP Status Code: 400


The specified resource is in use.

HTTP Status Code: 409


You have encountered a service limit on the specified resource.

HTTP Status Code: 400


These errors are usually caused by a server-side issue.

HTTP Status Code: 500


The service is unavailable. Back off and retry the operation.

HTTP Status Code: 503


At least one of your specified cluster subnets is in an Availability Zone that does not support Amazon EKS. The exception output specifies the supported Availability Zones for your account, from which you can choose subnets for your cluster.

HTTP Status Code: 400


In the following example or examples, the Authorization header contents (AUTHPARAMS) must be replaced with an AWS Signature Version 4 signature. For more information about creating these signatures, see Signature Version 4 Signing Process in the AWS General Reference.

You only need to learn how to sign HTTP requests if you intend to manually create them. 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. When you use these tools, you don't need to learn how to sign requests yourself.


The following example creates an Amazon EKS cluster called prod.

Sample Request

POST /clusters HTTP/1.1 Host: Accept-Encoding: identity User-Agent: aws-cli/1.15.0 Python/3.6.5 Darwin/16.7.0 botocore/1.10.0 X-Amz-Date: 20180531T230747Z Authorization: AUTHPARAMS Content-Length: 294 { "name": "prod", "roleArn": "arn:aws:iam::012345678910:role/eks-service-role-AWSServiceRoleForAmazonEKS-J7ONKE3BQ4PI", "resourcesVpcConfig": { "subnetIds": [ "subnet-6782e71e", "subnet-e7e761ac" ], "securityGroupIds": [ "sg-6979fe18" ] }, "clientRequestToken": "1d2129a1-3d38-460a-9756-e5b91fddb951" }

Sample Response

HTTP/1.1 200 OK Date: Thu, 31 May 2018 23:07:49 GMT Content-Type: application/json Content-Length: 457 x-amzn-RequestId: 6f0db7db-6527-11e8-8a37-a327fbeb897a x-amz-apigw-id: Hxj6kGtiPHcFe_Q= X-Amzn-Trace-Id: Root=1-5b108043-c26a2b984678c4b0ac9dcec8 Connection: keep-alive { "cluster": { "endpoint": null, "status": "CREATING", "createdAt": 1527808069.147, "certificateAuthority": { "data": null }, "arn": "arn:aws:eks:us-west-2:012345678910:cluster/prod", "roleArn": "arn:aws:iam::012345678910:role/eks-service-role-AWSServiceRoleForAmazonEKS-J7ONKE3BQ4PI", "clientRequestToken": null, "version": "1.10", "name": "prod", "resourcesVpcConfig": { "securityGroupIds": [ "sg-6979fe18" ], "vpcId": "vpc-950809ec", "subnetIds": [ "subnet-6782e71e", "subnet-e7e761ac" ] } } }

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: