Skip to main content
POST
/
virtual_machines
Python (SDK)
import latitudesh_python_sdk
from latitudesh_python_sdk import Latitudesh
import os


with Latitudesh(
    bearer=os.getenv("LATITUDESH_BEARER", ""),
) as latitudesh:

    res = latitudesh.virtual_machines.create(data={
        "type": latitudesh_python_sdk.VirtualMachinePayloadType.VIRTUAL_MACHINES,
        "attributes": {
            "name": "my-new-vm",
            "project": "lightweight-leather-lamp",
        },
    })

    # Handle response
    print(res)
{
  "data": {
    "id": "vm_mw49QDB5qagKb",
    "type": "virtual_machines",
    "attributes": {
      "name": "my-new-vm",
      "status": "Starting",
      "created_at": "2026-01-14T15:57:13+00:00",
      "primary_ipv4": "192.168.1.50",
      "operating_system": "ubuntu_24_04_x64_lts",
      "site": "FRA181",
      "billing": "monthly",
      "plan": {
        "id": "plan_VE1Wd3VXOXnZJ",
        "name": "g3.h100.large-131"
      },
      "specs": {
        "vcpu": 16,
        "ram": "128 GB",
        "storage": "100 GB",
        "nic": "1 x 1 Gbps",
        "gpu": "1 x NVIDIA H100 Tensor Core GPU"
      },
      "team": {
        "id": "team_zAbb72Zm3VS3N0o89Y48sGXv3mZ",
        "name": "690 Team",
        "slug": "690-team",
        "description": "690 Team",
        "address": "Apt. 922 405 Ondricka Lights, Lake Jennineview, SC 58925-4625",
        "status": "verified",
        "currency": {
          "id": "cur_AW6Q2D9lqKLpr",
          "code": "BRL",
          "name": "Brazilian Real",
          "currency_id": null
        }
      },
      "project": {
        "id": "proj_GMy1Dbk1ON50m",
        "name": "Lightweight Leather Lamp",
        "slug": "lightweight-leather-lamp",
        "description": "Sleek Wool Plate",
        "billing_type": "Normal",
        "billing_method": "Normal",
        "bandwidth_alert": false,
        "environment": null,
        "billing": {
          "subscription_id": null,
          "type": "Normal",
          "method": "Normal"
        },
        "stats": {
          "databases": 0,
          "ip_addresses": 0,
          "prefixes": 0,
          "servers": 0,
          "storages": 0,
          "virtual_machines": 1,
          "vlans": 0
        }
      }
    }
  }
}

Authorizations

Authorization
string
header
required

Body

data
object

Response

201 - application/vnd.api+json

Created

data
object
meta
object