Logo

Command Palette

Search for a command to run...

GET/accounts/:account_id/gateways

Required Parameters

account_idstring
The account id

Get a list of all the gateways of the account.

Related Models:GatewayPagination

Request

GET
/accounts/:account_id/gateways
curl -X GET \
  "https://app.cloud66.com/api/3/accounts/:account_id/gateways" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json"

Response

{
  "response": [
    {
      "id": 1,
      "name": "aws_bastion",
      "username": "ec2-usr",
      "address": "1.1.1.1",
      "private_ip": "2.2.2.2",
      "ttl": "2016-02-01T14:46:38Z",
      "content": "N/A",
      "created_at_iso": "2016-02-01T14:37:05Z",
      "updated_at_iso": "2016-02-01T14:47:01Z",
      "created_by": "user1@cloud66.com",
      "updated_by": "user1@cloud66.com"
    }
  ],
  "count": 1,
  "pagination": {
    "previous": null,
    "next": null,
    "current": 1,
    "per_page": 30,
    "count": 1,
    "pages": 1
  }
}
POST/accounts/:account_id/gateways

Required Parameters

account_idstring
The account id
namestring
New gateway name

Optional Parameters

usernamestring
Username of bastion server
addressstring
Public IP or DNS address of bastion server
ttlinteger
The number of seconds you want the gateway available
private_ipstring
Private IP or DNS address of bastion server
contentstring
The content of private key of bastion server

Create a new gateway under the account. name must be passed as params. You can also specify username, address, ttl, private_ip and content as params.

Related Models:Gateway

Request

POST
/accounts/:account_id/gateways
curl -X POST \
  "https://app.cloud66.com/api/3/accounts/:account_id/gateways?username=ec2-usr&address=1.1.1.1&ttl=3600&private_ip=2.2.2.2&content=xxxxxxxx" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "account_id": "12345",
  "name": "new_gateway_name"
}'

Response

{
  "response": {
    "ok": true
  }
}
PUT/accounts/:account_id/gateways/:id

Required Parameters

idinteger
The gateway id
account_idstring
The account id

Optional Parameters

namestring
Gateway name
usernamestring
Username of bastion server
addressstring
Public IP or DNS address of bastion server
ttlinteger
The number of seconds you want the gateway available
private_ipstring
Private IP or DNS address of bastion server
contentstring
The content of private key of bastion server

Update gateway information.

Related Models:Gateway

Request

PUT
/accounts/:account_id/gateways/:id
curl -X PUT \
  "https://app.cloud66.com/api/3/accounts/:account_id/gateways/:id?name=new_gateway_name&username=ec2-usr&address=1.1.1.1&ttl=3600&private_ip=2.2.2.2&content=xxxxxxxx" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "id": "1",
  "account_id": "12345"
}'

Response

{
  "response": {
    "ok": true
  }
}
DELETE/accounts/:account_id/gateways/:id

Required Parameters

idinteger
The gateway id
account_idstring
The account id

Delete a gateway.

Related Models:Gateway

Request

DELETE
/accounts/:account_id/gateways/:id
curl -X DELETE \
  "https://app.cloud66.com/api/3/accounts/:account_id/gateways/:id" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json"
Gatewaypublic

Gateway endpoints provide access to Cloud 66 gateway functionality.

This section contains endpoints for managing gateway configurations and settings.

Related Models:Gateway