Create a New Container

Base URL:


POST /api/atlas/v1.0/groups/{GROUP-ID}/containers

Request Path Parameters

Parameter Required/Optional Description
GROUP-ID Required. The unique identifier for the group.

Request Query Parameters

Field Required/Optional Description
envelope Optional. A boolean that specifies whether or not to wrap the response in an envelope.

Request Body Parameters

Parameter Required/Optional Description
atlasCidrBlock Required.

Atlas CIDR block.

Atlas uses the specified CIDR block for all other VPC peering connections created in the group.

The Atlas CIDR block must be at least a /24 and at most a /21 in one of the following private networks.


Atlas locks this value if an M10+ cluster or a VPC peering connection already exists. To modify the CIDR block, ensure there are no M10+ clusters in the group and no other VPC peering connections in the group. Alternatively, create a new group and create a VPC Peering Connection to set the desired Atlas VPC CIDR block for that group.


Atlas limits the number of MongoDB nodes per VPC based on the CIDR block and the region selected for the group. For example, a group in an AWS region supporting 3 availability zones and a Atlas CIDR VPC block of /24 is limited to the equivalent of 27 3-node replica sets.

Contact MongoDB Support for any questions on Atlas limits of MongoDB nodes per VPC.

providerName Required. The provider name. Specify AWS.
regionName Required. AWS region name.

HTTP Response Elements

Field Description
id The container ID.
providerName Provider name; e.g. AWS.
atlasCidrBlock The Atlas CIDR block.
regionName AWS region.
vpcId The ID of the peer VPC.
isProvisioned Flag that indicates if the group has clusters deployed in the VPC.

Example Request

curl -X POST -u 'username:apiKey' --digest "" \
   -H "Content-Type: application/json" --data '
       "atlasCidrBlock" : "",
       "providerName" : "AWS",
       "regionName" : "US_EAST_1"

Example Response

  "atlasCidrBlock" : "",
  "id" : "1112269b3bf99403840e8934",
  "providerName" : "AWS",
  "provisioned" : true,
  "regionName" : "US_EAST_1",
  "vpcId" : "vpc-zz0zzzzz"