Create instances

How to create an instance with the FluidStack API

Steps

1

Decide which configuration and operating system to use

Determine the currently available options:

Retrieve the gpu_type of the desired configuration, and the label of the desired OS template. This label value maps to the operating_system_label value when you create the instance.

2

Create the instance

Call the Create a new instance endpoint to deploy an instance.

Example:

POST
1curl -X POST https://platform.fluidstack.io/instances \
2 -H "api-key: <api-key>" \
3 -H "Content-Type: application/json" \
4 -d '{
5 "gpu_type": "RTX_A5000_24GB",
6 "ssh_key": "my_ssh_key",
7 "name": "my_instance_name",
8 "operating_system_label": "ubuntu_20_04_lts_nvidia"
9}'

You must provide your own API key in the header of the request.

The following values are required in the JSON body of your request:

  • thegpu_type (Select an option from the gpu_model field of your desired Configuration.)
  • the ssh_key_name from an SSH key added to your FluidStack account

These values are optional:

  • a custom name for the instance (Default: a randomized string)
  • gpu_count (Default: 1)
  • operating_system_label (Select an option from the label field of your desired Operating Systems. Default: ubuntu_20_04_lts_nvidia)
3

Confirm instance creation

If the instance is successfully created, the endpoint will respond with a status code of 201. The response body should contain a JSON object similar to this:

Response
1{
2 "id": "i-1234567890",
3 "name": "my_instance_name",
4 "gpu_type": "RTX_A5000_24GB",
5 "operating_system_label": "ubuntu_20_04_lts_nvidia"
6}

For further details, see the API Reference.