API reference
Catalogue
Plans, domain availability and prices. Callable with a public key from browsers.
Try these requests in Postman: Download Postman collection (how to use it).
- List plans
GET /v1/plans - Check domain availability
GET /v1/domains/check - Domain prices
GET /v1/domains/pricing
List plans
GET/v1/plans
Hosting plans currently on sale, priced in rand. Global Software Services (Pty) Ltd, the company behind NewHost, is not registered for VAT, so no VAT is added: the price shown is the full amount you pay. Plans are ordered in the dashboard, not through the API: a new web hosting or app plan names its domain there (one you own, one to transfer to NewHost or a new one to register).
Works with a public key (browser-safe) or a secret key.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
category | query | string | WEB, EMAIL, APP or WINDOWS (Windows hosting). |
Request
curl "https://api.newhost.co.za/v1/plans" \
-H "X-Public-Key: pk_live_..."Response
{
"data": [
{
"slug": "starter",
"name": "Starter",
"category": "APP",
"priceMonthly": "99.00",
"priceYearly": "990.00",
"storageGb": 10,
"featured": false
}
]
}Check domain availability
GET/v1/domains/check
Checks the name and suggests it in other popular extensions. Prices are in rand per year. No VAT is added: the price shown is the full amount you pay. With a secret key the prices are your account's (a domain reseller's reseller prices); a public key always gets the standard prices.
Works with a public key (browser-safe) or a secret key.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
qrequired | query | string | A name or domain, e.g. acme or acme.co.za. |
Request
curl "https://api.newhost.co.za/v1/domains/check?q=acme.co.za" \
-H "X-Public-Key: pk_live_..."Response
{
"data": [
{
"domain": "acme.co.za",
"available": false,
"premium": false,
"price": 107
},
{
"domain": "acme.africa",
"available": true,
"premium": false,
"price": 227
}
]
}Domain prices
GET/v1/domains/pricing
Registration, renewal and transfer prices for the featured extensions (rand per year). No VAT is added: the price shown is the full amount you pay. Called with a secret key, the prices are your account's: an active domain reseller gets its reseller prices (reseller: true). A public key always gets the standard prices, so they are safe to show on your own site.
Works with a public key (browser-safe) or a secret key.
Request
curl "https://api.newhost.co.za/v1/domains/pricing" \
-H "X-Public-Key: pk_live_..."Response
{
"data": [
{
"tld": "co.za",
"registration": 107,
"renewal": 107,
"transfer": 99,
"reseller": false
}
]
}