Hydrilla AI Logo
5-Minute Guide

Quickstart Guide

Get up and running with the Hydrilla AI API in 3 simple steps: authenticate, submit a 3D reconstruction task, and poll for the downloadable GLB mesh.

1

Create your API Key

API requests require a secret key starting with hyd_live_....

  1. Log in to the Hydrilla Studio.
  2. Navigate to API Keys in your dashboard sidebar.
  3. Click Create Secret Key, give it a name (e.g., Production-Backend), and copy the revealed token.
2

Trigger 3D Reconstruction

Submit a prompt to the POST /v1/3d/text-to-3d endpoint. Hydrilla will compile the prompt, render reference views, and dispatch the job to our BlueFox GPU cluster.

cURL Request
curl -X POST https://api.hydrilla.co/v1/3d/text-to-3d \
  -H "Authorization: Bearer hyd_live_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "Futuristic cyberpunk vehicle, high details, game ready prop",
    "image_model": {
      "provider": "openai",
      "quality": "high"
    },
    "resolution": 1536
  }'

The endpoint returns an asynchronous task ID:

Response 200 OK
{
  "id": "job_c18ab44d03e192a40",
  "status": "queued",
  "resolution": 1536,
  "links": {
    "poll": "https://api.hydrilla.co/v1/3d/tasks/job_c18ab44d03e192a40"
  }
}
3

Poll for Completion & Download Mesh

Poll GET /v1/3d/tasks/:taskId every 2–3 seconds until the status reaches completed.

Poll Task
curl -X GET https://api.hydrilla.co/v1/3d/tasks/job_c18ab44d03e192a40 \
  -H "Authorization: Bearer hyd_live_your_api_key_here"
Completed Response
{
  "id": "job_c18ab44d03e192a40",
  "status": "completed",
  "progress": 100,
  "result": {
    "mesh_url": "https://storage.googleapis.com/hydrilla-meshes/job_c18ab.glb",
    "preview_image_url": "https://storage.googleapis.com/hydrilla-meshes/job_c18ab_thumb.png",
    "format": "glb",
    "triangles": 128450
  }
}

Complete Python Example

Copy and run this self-contained script to test end-to-end 3D generation:

quickstart.py
import requests
import time

API_KEY = "hyd_live_your_api_key_here"
HEADERS = {
    "Authorization": f"Bearer {API_KEY}",
    "Content-Type": "application/json"
}

# 1. Trigger Text-to-3D
res = requests.post("https://api.hydrilla.co/v1/3d/text-to-3d", headers=HEADERS, json={
    "prompt": "Futuristic cyberpunk vehicle, high details, game ready prop",
    "resolution": 1536
})
task_id = res.json()["id"]
print(f"Task submitted: {task_id}")

# 2. Poll until complete
while True:
    task = requests.get(f"https://api.hydrilla.co/v1/3d/tasks/{task_id}", headers=HEADERS).json()
    status = task.get("status")
    print(f"Status: {status} ({task.get('progress', 0)}%)")
    
    if status == "completed":
        glb_url = task["result"]["mesh_url"]
        print(f"3D Model Ready! Download at: {glb_url}")
        break
    elif status == "failed":
        print("Failed:", task.get("error"))
        break
        
    time.sleep(3)

Next: Explore Authentication

Learn about API key lifecycle, headers, rate limits, and error handling.

Authentication Guide