Every endpoint on the model hosting service, with fields and
error codes. Base URL: https://api.gpus4all.dev/v1.
Send the key as a Bearer token. Keys start with g4a_live_.
Authorization: Bearer g4a_live_<key>
| Method | Path | Purpose |
|---|---|---|
| GET | /health | liveness check, no auth |
| GET | /v1/models | list deployable models |
| POST | /v1/chat/completions | chat completions |
| POST | /v1/completions | raw completions |
| POST | /v1/embeddings | embedding vectors |
| POST | /generate | native generate with metadata |
Request fields, most of which match the OpenAI reference:
| Field | Type | Notes |
|---|---|---|
model | string | required, a model id from /v1/models |
messages | array | required, role + content pairs |
max_tokens | int | cap on output tokens |
temperature | float | 0 to 2, default 0.7 |
top_p | float | nucleus sampling, default 1.0 |
stream | bool | server-sent events |
stop | string|array | stop sequences |
user | string | optional id for your own bookkeeping |
Response is the OpenAI shape: id, object,
created, model, choices[],
usage.
Input can be a string or an array of strings. Response is the OpenAI
embedding shape with a 1536-dimension vector on
gpus4all/bge-m3.
Native endpoint. Accepts text, sampling_params,
and return_logprob. Response carries text[] and a
meta_info block with token counts and cached tokens.
| Code | Meaning |
|---|---|
| 400 | malformed request, missing model |
| 401 | bad or missing API key |
| 404 | model not found |
| 429 | rate limited or spending cap reached |
| 500 | we broke something, check status.gpus4all.dev |
| 503 | model is starting or being redeployed, retry shortly |
60 requests per minute per key by default. Raise it per deployment on request. Streaming chunks do not count separately; a stream is one request.