Skip to content

Get a quote for a server order

POST/servers/quote

Overview

Calculates a server price and returns a signed quote_token. Send plan_key from the catalogue. Optionally send billing_cycle to use a cycle other than the default.

The response includes the plan, product group, location, price, currency, billing cycle, cycle length in months and payment window. Use the token to place the order at the quoted price.

postpaid is true when the servers would go into a postpaid team. amount is then the monthly price, billed by the hour, the billing cycle is always monthly, and the order is checked against the postpaid spending limit instead of account credit.

Requesting a quote does not charge the account or reserve capacity.

Permissions

Requires the server.read (View servers) permission for the selected team. Resources outside that team return 404.

curl --request POST \
  --url 'https://console.advinservers.com/api/v1/client/servers/quote' \
  --header 'Authorization: Bearer <token>' \
  --header 'Accept: application/json' \
  --header 'Content-Type: application/json' \
  --data '{
  "plan_key": "032f97c3b0f718ae9a2edfba83d5adf321025b5d9af1e90d397e79b8667bb3a4",
  "billing_cycle": "monthly"
}'
{
  "plan": {
    "key": "032f97c3b0f718ae9a2edfba83d5adf321025b5d9af1e90d397e79b8667bb3a4",
    "id": "standard-4gb",
    "name": "Standard 4 GB",
    "vcpu_cores": 4,
    "memory": 4000,
    "disk": 80,
    "bandwidth": 5000,
    "hdd": false,
    "primary_disk": 80,
    "hdd_disk": 0,
    "price": "12.00",
    "deployment_time": "Instant",
    "whmcs_id": "48"
  },
  "plan_key": "032f97c3b0f718ae9a2edfba83d5adf321025b5d9af1e90d397e79b8667bb3a4",
  "group": {
    "id": "2",
    "name": "Standard VPS"
  },
  "location": {
    "id": "2-3",
    "display_name": "Kansas City, MO",
    "name": "Kansas City, MO",
    "flag_url": null,
    "cid": 3,
    "group_name": "Standard VPS"
  },
  "location_id": 3,
  "product_group_id": 2,
  "amount": "12.00",
  "currency": "USD",
  "billing_cycle": "monthly",
  "billing_cycle_months": 1,
  "payment_window_minutes": 30,
  "postpaid": false,
  "quote_token": "eyJ2ZXJzaW9uIjoxLCJub25jZSI6IjNmYWRiNjgyM2ZmZTkyY2Q0ZDkwYzRkNjg4YTdjZWY5ZjBiYjBjZDE1YjVhM2VlMGE2MzMyZmU1YmQ4Njg1YWYiLCJvd25lcl9pZCI6MTg3Mywib3duZXJfZW1haWwiOiJnb3Jkb24uZnJlZW1hbkBibGFja21lc2EuZXhhbXBsZS5jb20iLCJleHBpcmVzX2F0IjoxNzg5NDA0NzI5LCJ3aG1jc19jb25maWd1cmF0aW9uX2ZpbmdlcnByaW50IjoiZTY3ZDIzZTc4MjBjNDlhOCJ9.f84ed5bfb2e3e24710926d5ccf5902fc93d0c9a0a45365dd784e1aa72d4083f0"
}

Authorization

Authorizationstringheaderrequired

Your API key, sent as a bearer token. Create one in the control panel under API Keys, give it only the permissions the integration needs, and copy it when it is created. It cannot be shown again. Each key is restricted to one owned team. The key determines the team for every request.

Send it as Bearer <token>.

Body

application/json
plan_keystringrequired

The value of plan_key.

Exactly 64 characters

billing_cyclestring

How often the service renews and is billed.

One of: monthly, quarterly, semiannually, annually, biennially, triennially

Response 200

application/json

The record, as a JSON object. There is no envelope.

planobjectrequired

The value of plan.

Show child attributes
keystringrequired

The value of key.

idstringrequired

The id ID.

namestringrequired

The name shown to customers.

vcpu_coresintegerrequired

The value of vcpu_cores.

memoryintegerrequired

Memory in advertised units; 1000 represents 1 GiB.

diskintegerrequired

Advertised disk capacity in GiB.

bandwidthintegerrequired

Transfer allowance in advertised units; 1000 represents 1 TiB and zero means unlimited.

hddbooleanrequired

The value of hdd.

primary_diskintegerrequired

Primary disk capacity in GiB.

hdd_diskintegerrequired

Secondary hard disk capacity in GiB.

pricestringrequired

The value of price.

deployment_timestring | nullrequired

The value of deployment_time.

whmcs_idstringrequired

The billing product identifier.

plan_keystringrequired

The value of plan_key.

groupobjectrequired

The value of group.

Show child attributes
idstringrequired

The id ID.

namestringrequired

The name shown to customers.

locationobjectrequired

The value of location.

Show child attributes
idstringrequired

The id ID.

display_namestringrequired

The value of display_name.

namestringrequired

The name shown to customers.

flag_urlstring | nullrequired

The value of flag_url.

cidintegerrequired

The value of cid.

group_namestringrequired

The value of group_name.

location_idinteger | nullrequired

The location id ID.

product_group_idinteger | nullrequired

The product group id ID.

amountstringrequired

The amount in the currency shown by currency.

currencystringrequired

The three-letter currency code used for monetary amounts.

billing_cyclestringrequired

How often the service renews and is billed.

billing_cycle_monthsintegerrequired

The value of billing_cycle_months.

payment_window_minutesintegerrequired

How many minutes the original payment window allowed.

postpaidbooleanrequired

The value of postpaid.

quote_tokenstringrequired

The value of quote_token.

Errors

401
The key was missing, malformed, revoked, or belongs to an account that no longer exists.
403
Access denied. Check the key's team, permissions and allowed IP addresses. Some actions, such as managing API keys, require a browser session. The response message explains the reason.
422
A field is missing or invalid, or the resource cannot accept this change in its current state. Check message for details. Field validation also includes an errors object keyed by field name.
429
Too many requests. The Retry-After header says how many seconds to wait. Limits are per account, so several keys on one account share them.