Organization API: Customer Portal: Vps
The 17 Organization API operations for vps.
Part of Customer Portal.
Operations
Section titled OperationsOne of the customer's instances
Section titled One of the customer's instancesGET /api/v1/orgs/{org_slug}/portal/vps/{uuid}
One of the customer's instances.
ipv6_address is the address the guest holds in its IPv6 /64 and
ipv6_prefix the /64 itself; both are null until the instance has IPv6.
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
uuid |
path | string | yes |
org_slug |
path | string | yes |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
What was done to the instance, newest first
Section titled What was done to the instance, newest firstGET /api/v1/orgs/{org_slug}/portal/vps/{uuid}/activity
What was done to the instance, newest first.
{items: [{id, description, by, at}]}. by is you for the
customer's own actions, staff for the brand's or the platform's staff,
and system for the rest. The event's metadata and the actor's id stay
in the API: they name hosts and staff accounts.
Parameters
Section titled Parameters| Name | In | Type | Required | Description |
|---|---|---|---|---|
uuid |
path | string | yes | |
org_slug |
path | string | yes | |
limit |
query | integer | no | How many rows, newest first. Default: 20. |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
Get bandwidth
Section titled Get bandwidthGET /api/v1/orgs/{org_slug}/portal/vps/{uuid}/bandwidth
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
uuid |
path | string | yes |
org_slug |
path | string | yes |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
Write the instance's account and network settings to it again
Section titled Write the instance's account and network settings to it againPOST /api/v1/orgs/{org_slug}/portal/vps/{uuid}/cloud-init/regenerate
Write the instance's account and network settings to it again.
For an instance that did not pick up a change, such as a primary address
attached after it was built. It writes the user account, the password we
hold, the hostname, the DNS resolvers, the primary address and the IPv6
address, and leaves the SSH keys as they were last saved. The operating
system applies them at its next restart, which this route does not do.
Limited to 10 in 10 minutes per customer and instance, and recorded on
the instance's activity. A suspended or migrating instance answers with
the reason, and one that is not the customer's 404.
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
uuid |
path | string | yes |
org_slug |
path | string | yes |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
A display console session on one of the customer's instances
Section titled A display console session on one of the customer's instancesGET /api/v1/orgs/{org_slug}/portal/vps/{uuid}/console
A display console session on one of the customer's instances.
Answers the fields of GET /api/v1/client/vps/{uuid}/console and
token, the customer token the websocket takes. display reads
serial or pending until the instance is restarted once from the
portal, and vga once the console shows its screen. An instance that is
not the customer's answers 404.
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
uuid |
path | string | yes |
org_slug |
path | string | yes |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
Credentials
Section titled CredentialsGET /api/v1/orgs/{org_slug}/portal/vps/{uuid}/credentials
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
uuid |
path | string | yes |
org_slug |
path | string | yes |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
Get graphs
Section titled Get graphsGET /api/v1/orgs/{org_slug}/portal/vps/{uuid}/graphs
Parameters
Section titled Parameters| Name | In | Type | Required | Description |
|---|---|---|---|---|
uuid |
path | string | yes | |
org_slug |
path | string | yes | |
timeframe |
query | string | no | Default: hour. |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
What the guest reports about itself, as GET /api/v1/client/vps/{uuid}/guest answers it
Section titled What the guest reports about itself, as GET /api/v1/client/vps/{uuid}/guest answers itGET /api/v1/orgs/{org_slug}/portal/vps/{uuid}/guest
What the guest reports about itself, as GET /api/v1/client/vps/{uuid}/guest answers it.
agent_online is false, with no os_info and no interfaces, while the
instance is off or its guest agent has not started. An instance that is
not the customer's answers 404.
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
uuid |
path | string | yes |
org_slug |
path | string | yes |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
Patch hostname
Section titled Patch hostnamePATCH /api/v1/orgs/{org_slug}/portal/vps/{uuid}/hostname
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
uuid |
path | string | yes |
org_slug |
path | string | yes |
Request body
Section titled Request bodyapplication/json (required)
| Field | Type | Required |
|---|---|---|
hostname |
string | yes |
reboot |
boolean | no |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
List IPs
Section titled List IPsGET /api/v1/orgs/{org_slug}/portal/vps/{uuid}/ips
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
uuid |
path | string | yes |
org_slug |
path | string | yes |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
Give one of the customer's instances its IPv6: a /64 routed to it, at no charge
Section titled Give one of the customer's instances its IPv6: a /64 routed to it, at no chargePOST /api/v1/orgs/{org_slug}/portal/vps/{uuid}/ipv6
Give one of the customer's instances its IPv6: a /64 routed to it, at no charge.
Answers {prefix, address, reboot_required}: the /64, the address the
guest takes in it (the network's ::1, with fe80::1 as its
gateway), and whether the instance needs a restart for the guest to take
it. Asking again answers the /64 the instance already has, with
reboot_required false. Answers 409 when the location has no IPv6 yet
or none left, or while the instance is migrating; 404 when the instance
is not the customer's; 429 when asked too often.
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
uuid |
path | string | yes |
org_slug |
path | string | yes |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
Power
Section titled PowerPOST /api/v1/orgs/{org_slug}/portal/vps/{uuid}/power
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
uuid |
path | string | yes |
org_slug |
path | string | yes |
Request body
Section titled Request bodyapplication/json (required)
| Field | Type | Required |
|---|---|---|
action |
string | yes |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
Erase the instance's disk and install an operating system on it from scratch
Section titled Erase the instance's disk and install an operating system on it from scratchPOST /api/v1/orgs/{org_slug}/portal/vps/{uuid}/rebuild
Erase the instance's disk and install an operating system on it from scratch.
The instance keeps its plan, hostname, addresses, SSH keys and backups. It loses every file and its snapshots, and gets a new random password.
template_id is a template of storefront/vps-templates.
confirm_hostname must be the instance's hostname (letter case and
outer spaces aside); without it the request answers 400 and nothing
is queued. A template that is retired, not ready on the instance's host
or too large for its plan answers 409 with the reason. An instance
that is migrating answers 409, a suspended one 403, and one that
is not the customer's 404. Answers {status: "rebuild_queued"};
the work is a job, at most one per instance at a time.
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
uuid |
path | string | yes |
org_slug |
path | string | yes |
Request body
Section titled Request bodyapplication/json (required)
| Field | Type | Required |
|---|---|---|
template_id |
integer | yes |
confirm_hostname |
string | no |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
Reset password
Section titled Reset passwordPOST /api/v1/orgs/{org_slug}/portal/vps/{uuid}/reset-password
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
uuid |
path | string | yes |
org_slug |
path | string | yes |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
The public keys on the instance: {sshkeys, count}
Section titled The public keys on the instance: {sshkeys, count}GET /api/v1/orgs/{org_slug}/portal/vps/{uuid}/ssh-keys
The public keys on the instance: {ssh_keys, count}. A PUT replaces them all, so it starts from these.
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
uuid |
path | string | yes |
org_slug |
path | string | yes |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
Replace the instance's public keys with sshkeys (one per line; empty removes them all)
Section titled Replace the instance's public keys with sshkeys (one per line; empty removes them all)PUT /api/v1/orgs/{org_slug}/portal/vps/{uuid}/ssh-keys
Replace the instance's public keys with ssh_keys (one per line; empty removes them all).
The operating system applies them as it starts, so they reach it at the
next restart. Answers {status, keys_set} and records the change on the
instance's activity.
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
uuid |
path | string | yes |
org_slug |
path | string | yes |
Request body
Section titled Request bodyapplication/json (required)
| Field | Type | Required |
|---|---|---|
ssh_keys |
string | no |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
Get status
Section titled Get statusGET /api/v1/orgs/{org_slug}/portal/vps/{uuid}/status
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
uuid |
path | string | yes |
org_slug |
path | string | yes |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |