Quickstart
Get a key, make a call, read the receipt. GPULab follows the OpenAI API, so the SDKs and tools you already use work by changing the base URL and the key.
1Get a key
Request access. A person reviews each request. When it is approved you receive a key; GPULab keeps only its name, so store it somewhere safe. The examples here read it from GPULAB_KEY and send it as a bearer token.
2Make a call
Chat and embeddings answer in the request. Every request must finish within 60 seconds, and your tier caps how many tokens a chat answer may use.
curl https://api.gpulab.io/v1/chat/completions \ -H "Authorization: Bearer $GPULAB_KEY" \ -H "Content-Type: application/json" \ -d '{"model": "qwen3:8b", "messages": [{"role": "user", "content": "Summarize this paragraph: ..."}], "max_tokens": 400}'
import os from openai import OpenAI client = OpenAI( base_url="https://api.gpulab.io/v1", api_key=os.environ["GPULAB_KEY"], ) reply = client.chat.completions.create( model="qwen3:8b", messages=[{"role": "user", "content": "Summarize this paragraph: ..."}], max_tokens=400, ) print(reply.choices[0].message.content) print(reply.model_extra["receipt"])
3Run longer work as a job
Documents, images, speech, transcription and music are jobs. The request waits up to 45 seconds for the job. If it finishes, the answer is 200 with the result; if not, it is 202 with the job, which you poll. Results are kept for 24 hours.
curl https://api.gpulab.io/v1/images/generations \ -H "Authorization: Bearer $GPULAB_KEY" \ -H "Content-Type: application/json" \ -d '{"prompt": "Wireframe planes in deep navy space", "size": "1024x1024"}' HTTP 202 {"id": "job_7cdc73377ae5454d8bb72d99fbf9243a", "object": "job", "type": "image", "model": "z-image-turbo", "status": "queued", "position": 1, "poll": "/v1/jobs/job_7cdc73377ae5454d8bb72d99fbf9243a"} curl "https://api.gpulab.io/v1/jobs/job_7cdc73377ae5454d8bb72d99fbf9243a/result?wait=50" \ -H "Authorization: Bearer $GPULAB_KEY" HTTP 200 {"created": 1795669310, "model": "z-image-turbo", "data": [{"b64_json": "iVBORw0KGgo...", "seed": 11, "width": 1024, "height": 1024, "format": "png"}], "receipt": {"pool": "media", "gpu_seconds": 64.7, "watt_hours": 0.9197, "images": 1, "megapixels": 1.05}}
The receipt above is from the first image after the image model loaded, so its GPU time includes the load.
Receipts
Every answer that used a GPU carries a receipt in its body, and its GPU time and energy in the X-GPULab-GPU-Seconds and X-GPULab-Watt-Hours headers. The same figures add up in your usage.
| Field | What it is |
|---|---|
| pool | language or media: the pool your work ran in |
| gpu_seconds | Time your work held a GPU |
| watt_hours | Energy from GPU power readings. In the media pool it is added up from readings taken through the job; in the language pool it is GPU time multiplied by the power reading at the time. |
| input_tokens, output_tokens | Chat and documents |
| inputs | Embeddings: how many texts |
| pages | Documents: pages read |
| images, megapixels | Images |
| audio_seconds, characters | Speech; transcription reports audio_seconds read; music reports audio_seconds and cpu_seconds |
Limits
| One request | 60 seconds; longer work is a job |
|---|---|
| Request body | 10,485,760 bytes |
| Requests per minute | 60 per key |
| Free tier, each day | 500 requests and 1,800 GPU seconds; chat answers up to 2,048 tokens; jobs admitted while their queue is short |
| Customer tier, each day | 20,000 requests and 36,000 GPU seconds; chat answers up to 4,096 tokens |
| Job results | Kept for 24 hours |
From your Plexara
On Plexara, an administrator adds GPULab as an API connection: base URL https://api.gpulab.io/v1, your key as the bearer token, and the OpenAPI spec at https://gpulab.io/openapi.json. Your agents and automations then call GPULab through that connection under your own personas, and each call is in your audit log as well as ours. The spec names every operation, such as createChatCompletion and createTranscription; the API reference reads from the same document.
Base URL and keys
https://api.gpulab.io/v1
Send your key in every request as Authorization: Bearer <key>. Bodies are JSON. Errors use the OpenAI shape, {"error": {"message", "type", "code"}}. Streaming responses are not available: a request with stream: true is refused with 400.
Models
GET/v1/models
Lists the models your key can call, each with a gpulab object naming its kinds, pool and route.
| Model | Kinds | Pool | Route |
|---|---|---|---|
| qwen3:8b | chat; 8,192-token context | Language | /v1/chat/completions |
| qwen3-vl:8b | chat, vision, documents; 8,192-token context | Language | /v1/chat/completions, /v1/documents |
| qwen3-embedding:0.6b | embeddings; 1,024 dimensions | Language | /v1/embeddings |
| z-image-turbo | images | Media | /v1/images/generations |
| chatterbox | speech | Media | /v1/audio/speech, /v1/audio/text2speech |
| whisper-large-v3-turbo | transcription | Media | /v1/audio/transcriptions, /v1/audio/speech2text |
| plexara-score | music | CPU | /v1/music |
Chat completions
POST/v1/chat/completions
The OpenAI chat completion request and answer, plus a receipt.
| Field | Notes |
|---|---|
| model | qwen3:8b or qwen3-vl:8b |
| messages | System, user, assistant and tool messages. Content is a string, or a list of text and image_url parts. Images go to qwen3-vl:8b as data: URLs with base64 content; web addresses are refused. |
| max_tokens, max_completion_tokens | Capped at your tier's limit |
| temperature, top_p, seed, stop | Passed to the model |
| response_format | {"type": "json_object"}, or json_schema with a schema the answer must follow |
| tools | Function tools; calls come back in message.tool_calls with finish_reason: "tool_calls" |
| reasoning_effort | low, medium or high turns on the model's thinking, returned in message.reasoning_content. Left out, the model answers directly. |
| n, stream | n must be 1; stream must be false |
{"id": "chatcmpl-6b28173e673e3813f6c984a8", "object": "chat.completion",
"created": 1795673373, "model": "qwen3:8b",
"choices": [{"index": 0, "finish_reason": "stop",
"message": {"role": "assistant",
"content": "An embedding is a numerical representation of data, such as words or images, in a continuous vector space that captures semantic or structural relationships."}}],
"usage": {"prompt_tokens": 25, "completion_tokens": 28, "total_tokens": 53},
"receipt": {"pool": "language", "gpu_seconds": 0.87, "watt_hours": 0.0067,
"input_tokens": 25, "output_tokens": 28}}
The prompt was "In one sentence, what is an embedding?" with max_tokens 80.
import base64 image = base64.b64encode(open("receipt.png", "rb").read()).decode() reply = client.chat.completions.create( model="qwen3-vl:8b", messages=[{"role": "user", "content": [ {"type": "text", "text": "What is the total on this receipt?"}, {"type": "image_url", "image_url": {"url": "data:image/png;base64," + image}}, ]}], )
Embeddings
POST/v1/embeddings
model is qwen3-embedding:0.6b. input is a string or a list of 1 to 256 strings. dimensions is optional; vectors have 1,024 by default. encoding_format must be float.
vectors = client.embeddings.create(
model="qwen3-embedding:0.6b",
input=["invoice total due", "weather forecast for Glendale"],
)
print(len(vectors.data), len(vectors.data[0].embedding)) # 2 1024
Documents
POST/v1/documents
Reads a PDF or a scan with qwen3-vl:8b, page by page, as a job.
| Field | Notes |
|---|---|
| document | Base64 PDF, PNG, JPEG, WebP or TIFF; up to 40 pages a request |
| prompt | What to read out. Left out, each page is transcribed as Markdown, tables included. |
| format | markdown (default) or json |
| schema | With json: a JSON schema each page's answer follows |
| first_page, last_page | Pages of a PDF to read |
| dpi | Rendering resolution for PDF pages; 150 by default |
| max_tokens | Output per page; 4,096 by default |
import base64, os, requests BASE = "https://api.gpulab.io/v1" HEAD = {"Authorization": "Bearer " + os.environ["GPULAB_KEY"]} doc = base64.b64encode(open("invoice.pdf", "rb").read()).decode() r = requests.post(BASE + "/documents", headers=HEAD, timeout=70, json={ "document": doc, "format": "json", "prompt": "Extract vendor, invoice_number, date, terms, line_items and total as JSON.", }) while r.status_code == 202: r = requests.get(BASE + "/jobs/" + r.json()["id"] + "/result?wait=50", headers=HEAD, timeout=70) print(r.json()["pages"])
{"model": "qwen3-vl:8b", "page_count": 1,
"pages": [{"page": 1, "content": {"vendor": "ACME SUPPLY CO.", "invoice_number": "#10442",
"date": "2026-11-20", "terms": "Net 30",
"line_items": [{"description": "Widget, 12 x $4.50", "amount": "$54.00"},
{"description": "Freight", "amount": "$12.00"}],
"total": "$66.00"}}],
"receipt": {"pool": "language", "gpu_seconds": 33.92, "watt_hours": 0.2649,
"pages": 1, "input_tokens": 1112, "output_tokens": 246}}
Images
POST/v1/images/generations
Generates images with z-image-turbo as a job. The answer has the OpenAI images shape, data with b64_json, plus the receipt.
| Field | Notes |
|---|---|
| prompt | Required |
| size | WIDTHxHEIGHT, each side 512 to 1536 in steps of 64, at most 1536 × 1024 pixels; 1024x1024 by default |
| n | 1 to 4 |
| steps | 4 to 16; 9 by default |
| seed | Repeat a seed and prompt to get the same image |
| output_format | png (default), jpeg or webp |
| response_format | b64_json only |
Speech
POST/v1/audio/speech
Reads text aloud with chatterbox as a job. /v1/audio/text2speech is the same route under a second name. The answer is JSON with the audio in base64, not raw audio bytes, so read it as shown below rather than with an SDK's speech helper.
| Field | Notes |
|---|---|
| input | Text, up to 5,000 characters |
| voice | A base64 WAV or MP3 of about 10 seconds of clean speech, to speak in that voice. Left out, or a short name, uses the built-in voice. Use your own voice, or a voice whose speaker agreed; see Acceptable use. |
| response_format | mp3 (default) or wav |
| exaggeration, cfg_weight, temperature | Delivery: 0.5, 0.5 and 0.8 by default |
| seed | Repeat a seed to repeat a reading |
r = requests.post(BASE + "/audio/speech", headers=HEAD, timeout=70, json={"input": "Your order has shipped.", "seed": 3}) while r.status_code == 202: r = requests.get(BASE + "/jobs/" + r.json()["id"] + "/result?wait=50", headers=HEAD, timeout=70) audio = r.json()["audio"] # b64, format, sample_rate, seconds open("speech." + audio["format"], "wb").write(base64.b64decode(audio["b64"]))
Transcription
POST/v1/audio/transcriptions
Turns speech into text with whisper-large-v3-turbo as a job: the text and the detected language, and on request timed segments, word timings, or SRT or WebVTT subtitles. /v1/audio/speech2text is the same route under a second name. The request is JSON with the audio in base64, not a multipart upload, so send it as shown below rather than with an SDK's transcription helper.
| Field | Notes |
|---|---|
| file | Base64 WAV, MP3, M4A, OGG, FLAC, WebM or MP4; up to 60 minutes, within the 10,485,760-byte request body (about 7.5 MB of audio) |
| language | An ISO 639-1 code such as en. Left out, the language is detected and returned. |
| prompt | Names and spellings to expect. Naming the people, products and companies in the audio gets them spelled right. |
| response_format | json (default) and text answer the text; verbose_json adds timed segments; srt and vtt add subtitles in that format |
| timestamp_granularities, words | ["word"], or words: true, adds word timings to each segment |
| model | whisper-large-v3-turbo; whisper-1 is accepted as the same model |
audio = base64.b64encode(open("call.mp3", "rb").read()).decode() r = requests.post(BASE + "/audio/transcriptions", headers=HEAD, timeout=70, json={ "file": audio, "response_format": "srt", "prompt": "GPULab, Plexara, Deasil", }) while r.status_code == 202: r = requests.get(BASE + "/jobs/" + r.json()["id"] + "/result?wait=50", headers=HEAD, timeout=70) print(r.json()["text"]) open("call.srt", "w").write(r.json()["subtitles"])
{"model": "whisper-large-v3-turbo", "language": "en", "duration": 56.47,
"text": "Chat, vision, document, embedding, image, speech, and music models run on dedicated GPUs in Deasil's cluster. ...",
"subtitles_format": "srt",
"subtitles": "1\n00:00:00,080 --> 00:00:05,660\nChat, vision, document, embedding, image, speech, and music models run on dedicated\n\n2\n...",
"receipt": {"pool": "media", "gpu_seconds": 1.89, "watt_hours": 0.0274, "audio_seconds": 56.47}}
The audio was this site's narration. With the prompt naming GPU Lab, Deasil, Plexara and Claude, the text matched the script word for word; without it, Deasil came back as Diesel.
Music
POST/v1/music
Renders a JSON score to audio with plexara-score, on the CPU. A score sets its length in seconds and lists parts, each played on a Surge XT synth patch, a VSCO2 Community Edition sampler or one-shot hits, with notes as [time, note, velocity, duration]. Parts play into buses that share a reverb and pass through a master compressor and limiter, with faders and fades in and out. Each part is lowered by octaves until the middle of what it plays sits a fifth under its ceiling (E6, or C7 for bells and mallets), and the answer lists what was lowered.
| Field | Notes |
|---|---|
| score.seconds | Length, up to 600 |
| score.loop | True renders a seamless loop: the tail wraps onto the start, with no fades |
| score.buses | [{"name", "gain", "pan", "reverb"}] |
| score.parts | Each part has a bus and an instrument: {"synth": "Keys/EP 1"} (a Surge XT factory patch), {"sampler": "Strings/Solo Contrabass/Pizz/*.wav", "tune"} (a VSCO2 sample folder) or {"hits": "<sample pattern>"} for one-shot hits. Notes are [time, note, velocity, duration] in seconds with the note as a MIDI number or a name such as C4; hits are [seconds, velocity, pitch]. Optional gain, pan, ceiling, and bends for synths. |
| score.faders, score.ducks | Ride a bus's level over time, or keep one bus under others |
| score.seed, fade_in, fade_out | Sample choice and fades |
| format | mp3 (default) or wav |
A score holds at most 20,000 notes and hits.
{"format": "mp3",
"score": {"seconds": 8, "fade_out": 1.5,
"buses": [{"name": "music", "reverb": 0.2}],
"parts": [
{"bus": "music", "instrument": {"sampler": "Percussion/Xylo/*.wav", "tune": -12},
"notes": [[0, "C5", 90, 0.4], [0.5, "E5", 90, 0.4], [1.0, "G5", 90, 0.8]]},
{"bus": "music", "instrument": {"synth": "Keys/EP 1"},
"notes": [[0, "C4", 70, 4], [0, "E4", 70, 4], [4, "B3", 70, 4], [4, "D4", 70, 4]]},
{"bus": "music", "instrument": {"sampler": "Strings/Solo Contrabass/Pizz/*.wav"},
"notes": [[0, "C2", 100, 1], [2, "G2", 100, 1], [4, "G1", 100, 1], [6, "D2", 100, 1]]}
]}}
Jobs
Documents, images, speech, transcription and music answer 202 with a job when the work outlasts the wait. Add wait (0 to 50 seconds; 45 by default) as a query parameter or a body field to change how long a request holds.
| Route | What it does |
|---|---|
| GET /v1/jobs | Your 50 newest jobs |
| GET /v1/jobs/{id} | A job's status, position in the queue and, once it ends, its receipt |
| GET /v1/jobs/{id}/result | The finished result, shaped as its route answers; 202 while it runs, 422 if it failed |
| DELETE /v1/jobs/{id} | Cancel a job that is still queued |
A job's status is queued, running, succeeded, failed or canceled. Jobs in a pool run in turn, by tier and then by age.
Usage
GET/v1/usage
Today's requests, GPU seconds and watt-hours for your account, against your tier's daily quota.
{"customer": "acme", "key": "gpulab-acme-1", "tier": "customer",
"today": {"requests": 12, "gpu_seconds": 41.6, "watt_hours": 0.39},
"quota": {"requests": 20000, "gpu_seconds": 36000, "max_output_tokens": 4096}}
Errors
| 400 | The request is not valid; the message says why |
|---|---|
| 401 | No key, or a key the platform does not recognize |
| 403 | The key is not a GPULab key, or its account is not approved |
| 404 | No such route or job, or a result past its 24 hours |
| 413 | Body over 10,485,760 bytes |
| 422 | The job failed; the message says why |
| 429 | Over a limit, or the queue is busy and your key is free tier. Retry after the seconds in Retry-After. |
| 502 | A model server did not answer |
| 504 | The request ran past 60 seconds |
Status
GEThttps://plexara.deasil.works/endpoints/gpulab-status
Public, no key. Each pool's workloads and utilization, and the model loaded in the media pool; the queue for media, music and documents and what is running; and today's requests, jobs, GPU seconds and watt-hours across every customer. It names no customer. The live board reads it.