Logo

Command Palette

Search for a command to run...

GET/accounts/:id

Required Parameters

idinteger
The account ID

Optional Parameters

include_serversboolean
Include unmanaged servers in the response (only available for your primary account)

Retrieves detailed information for a specific account.

This endpoint returns comprehensive details about a single account, including optional unmanaged server information when explicitly requested.

Related Models:Account
Response Status Codes
Status CodeDescription
200Success - Returns account details
400Bad Request - Invalid request parameters or account is restricted
401Unauthorized - Authentication failed or missing OAuth token
403Forbidden - OAuth token lacks required `users` scope or user lacks account access
404Not Found - Account doesn't exist or user lacks access

Request

GET
/accounts/:id
curl -X GET \
  "https://app.cloud66.com/api/3/accounts/:id?include_servers=true" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json"

Response

{
  "response": {
    "id": 139,
    "owner": "test@cloud66.com",
    "created_at_iso": "2013-06-19T11:08:03Z",
    "updated_at_iso": "2014-02-20T12:55:58Z",
    "stack_count": 2,
    "used_clouds": [
      "digitalocean",
      "rackspace"
    ],
    "current_account": true,
    "friendly_name": "My Company Account",
    "unmanaged_servers": [
      {
        "id": "i-0123456789abcdef0",
        "name": "unmanaged-server-1",
        "vendor": "aws"
      }
    ],
    "server_registration_script": "curl -sSL https://get.cloud66.com | bash",
    "configstore_namespace": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
  }
}
GET/accounts

Lists all accounts that the current authenticated user has access to.

This endpoint returns a paginated list of accounts with their associated metadata, including stack counts, cloud providers used, and account status information.

Related Models:AccountPagination
Response Status Codes
Status CodeDescription
200Success - Returns paginated list of accounts
400Bad Request - Invalid request parameters
401Unauthorized - Authentication failed or missing OAuth token
403Forbidden - OAuth token lacks required `users` scope

Request

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

Response

{
  "response": [
    {
      "id": 139,
      "owner": "test@cloud66.com",
      "created_at_iso": "2013-06-19T11:08:03Z",
      "updated_at_iso": "2014-02-20T12:55:58Z",
      "stack_count": 2,
      "used_clouds": [
        "digitalocean",
        "rackspace"
      ],
      "current_account": true,
      "friendly_name": "My Company Account",
      "unmanaged_servers": null,
      "server_registration_script": "curl -sSL https://get.cloud66.com | bash",
      "configstore_namespace": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
    }
  ],
  "count": 1,
  "pagination": {
    "previous": null,
    "next": null,
    "current": 1,
    "per_page": 30,
    "count": 1,
    "pages": 1
  }
}
POST/accounts/otp

Generates a one-time password (OTP) for client authentication.

This endpoint creates a temporary authentication token that can be used by Cloud 66 clients for secure web access, exclusively for the calling user. The OTP has a limited lifespan and is intended for single-use authentication scenarios.

Related Models:Account

The generated OTP can be used by Cloud 66 command-line tools and other clients to authenticate with the web dashboard.

Response Status Codes
Status CodeDescription
200Success - Returns generated OTP
400Bad Request - Invalid request parameters
401Unauthorized - Authentication failed or missing OAuth token
403Forbidden - OAuth token lacks required `users` scope

Request

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

Response

{
  "response": {
    "ok": true,
    "otp": "abc123def456ghi789jkl012mno345pqr678stu901vwx234"
  }
}