The Spaces API provides users a method to explore the server groups and geographic regions available to their account, where clusters may be provisioned.
The Spaces API provides users a method to explore the server groups and geographic regions available to their account, where clusters may be provisioned. This API supports the following actions:
- View all available spaces for your account
- View a single space for your account
All calls to the Spaces API must be authenticated with an active API token that has the account:read scope.
The Bonsai Space Object
The Bonsai API provides a standard format for Space objects. A Space object includes:
| Attribute | Description |
|---|---|
| path | A String representing a machine-readable name for the server group. |
| private_network | A Boolean indicating whether the space is isolated and inaccessible from the public Internet. A VPC connection will be needed to communicate with a private cluster. |
| cloud | An Object containing details about the cloud provider and region attributes:
|
View all available spaces
The Bonsai API provides a method to get a list of all available spaces on your account. An HTTP GET call is made to the /spaces endpoint, and Bonsai will return a JSON list of Space objects.
Supported Parameters
No parameters are supported for this action.
HTTP Request
An HTTP GET call is made to /spaces.
HTTP Response
Upon success, Bonsai responds with an HTTP 200: OK code, along with a JSON list representing the spaces available to your account:
View a single space
The Bonsai API provides a method to get information about a single space available to your account.
Supported Parameters
No parameters are supported for this action.
HTTP Request
An HTTP GET call is made to /spaces/[:path].
HTTP Response
Upon success, Bonsai responds with an HTTP 200: OK code, along with a JSON body representing the Space object:
A path that does not name a space available to your account gets an HTTP 404: Not Found error:
A path that is not shaped like a space path at all, such as omc/bonsai/us-east-1, gets the message Invalid space path. instead.
Ready to power your search with AI?
Launch a fully managed Elasticsearch or OpenSearch cluster, with built-in vector search and AI capabilities.