Sizes and regions ›
List regions
GET
/v1/regionsThe regions sandboxes can be made in, and the sizes each has room for now.
RequestTypeScript
- import { Agental } from "agental-sdk";
- const agental = new Agental();
- const regions = await agental.regions();
Answer200 OK · RegionList
- {
- "regions": [{
- "name": string,
- "label": string,
- "about": string,
- "default": boolean,
- "sizesWithRoom": string[],
- }],
- }
The regions sandboxes can be made in now: those with servers, the default first, each with the sizes it has room for now.
Headers
AuthorizationrequiredBearer key | An API key that may make this call. |
Returns
200 The regions sandboxes can be made in now: those with servers, the default first, each with the sizes it has room for now. A region with no servers is not listed.
RegionList1 field
regionsRegion[]5 fields
namestring
labelstring
What it is called in words.
aboutstring
Where its servers are.
defaultboolean
True for the region a create that names none is made in.
sizesWithRoomstring[]
The sizes a new sandbox could be made at in it now.
More
It can change by the second: a create is still refused with 409 capacity_exceeded when it fills meanwhile.Errors and other answers
| 404 | Not found. |
Every error answers { "error": { "code", "message" } }; a key without the action a call needs answers 403 key_action_forbidden, naming it.