SpeedInfer Developer API Reference
SpeedInfer provides an OpenAI-compatible developer platform and control plane for high-throughput LLM inference,
fine-tuning orchestration (LoRA / QLoRA), object storage, dataset management, and scoped key governance. Open-source models are served via connected GPU workers, while proprietary closed-source models route through external providers.
Authentication: All API requests require a Bearer token in the Authorization header.
Authorization: Bearer sk-speedinfer-xxxxxxxxxxxxxxxxxxxx
Public API Base URL
Use the public HTTPS endpoint for SDK and API requests.
| Environment | Base URL | Description |
| Public API | https://speedinfer.com/v1 | SpeedInfer API gateway |
Granular Permission Scopes
When creating API keys via POST /v1/keys or Console, you can restrict permissions to minimal privileges:
| Scope | Grants Access To |
inference (or chat:completions) | Chat completions and legacy text completions |
models:read | Model discovery, architectures, pricing, and weights manifest |
files:write / files:read | Upload, read, and delete dataset files for fine-tuning |
storage:write / storage:read | Create storage buckets and upload object artifacts |
fine_tuning:write / fine_tuning:read | Launch, monitor, and cancel model fine-tuning jobs |
keys:write / keys:read | Issue, list, and revoke sub-API keys |
usage:read | Query consumption metrics and credit balance |
admin | Universal administrative superuser bypass |
Retrieve Current User & Balance
GET
/v1/auth/me
Returns the authenticated user's profile, organization role, verified email status, and current USD credit balance.
Model Pricing & Context Limits
GET
/v1/workspace/pricing
Returns current token pricing per 1M input/output tokens, context windows, and storage rates across all supported architectures.
Usage & Rate Limits
GET
/v1/usage
Retrieves aggregated token metrics, hourly request counts, and remaining rate limit quotas.
List Available Models
GET
/v1/models
Lists currently active and warm models available for instant inference, complete with context windows and token pricing.
Retrieve Model Details
GET
/v1/models/{model_id}
Retrieves detailed metadata for a specific base model or fine-tuned checkpoint.
Download & Export Model Weights
GET
/v1/models/{model_id}/weights
Export model weights manifest with SHA-256 checksums or stream direct safetensors weights artifacts.
| Query Param | Type | Description |
| download | boolean | Set true to initiate binary file download stream. |
| format | string | Target format (e.g. safetensors, gguf). Default: safetensors. |
Create Chat Completion
POST
/v1/chat/completions
Creates a model response for the given chat conversation. Fully OpenAI SDK drop-in compatible.
| Field | Type | Description |
| modelrequired | string | Model ID to query (e.g. Qwen/Qwen2.5-7B-Instruct). |
| messagesrequired | array | List of conversation turns (role and content). |
| temperature | float | Sampling temperature between 0.0 and 2.0. Default 0.7. |
| max_tokens | integer | Max tokens to generate. Max: 32,768. |
| stream | boolean | Stream partial tokens via Server-Sent Events (SSE). |
Chat Completion Streaming (SSE)
POST
/v1/chat/completions (stream=true)
Streams chunked token deltas via standard Server-Sent Events (SSE) protocol (text/event-stream).
Legacy Text Completions
POST
/v1/completions
OpenAI-compatible raw prompt text generation endpoint.
Upload a File
POST
/v1/files
Upload a training dataset or object. Automatically validates JSONL schema when purpose is fine-tune.
| Form Field | Type | Description |
| filerequired | file (binary) | The multipart file to upload. |
| purpose | string | Target purpose: fine-tune, storage. Default: fine-tune. |
List Files
GET
/v1/files
Returns a list of all files uploaded by the caller's organization.
Retrieve File Metadata
GET
/v1/files/{file_id}
Returns metadata about a specific file, including size, status, and creation date.
Download File Content
GET
/v1/files/{file_id}/content
Streams the raw binary or text contents of an uploaded file.
Delete a File
DEL
/v1/files/{file_id}
Permanently deletes a file and frees allocated storage space.
Create Storage Bucket
POST
/v1/buckets
Creates an isolated storage bucket for holding model weights, datasets, RAG vector indexes, and checkpoint blobs.
List Storage Buckets
GET
/v1/buckets
Returns a list of all object storage buckets owned by the account.
Retrieve Bucket Details
GET
/v1/buckets/{bucket_id}
Retrieves metadata for a specific storage bucket, including total object count and cumulative byte size.
Delete Storage Bucket
DEL
/v1/buckets/{bucket_id}
Deletes a bucket along with all objects stored within it.
Upload Object to Bucket
POST
/v1/buckets/{bucket_id}/objects
Uploads an arbitrary binary blob or dataset file into the specified bucket.
List Objects in Bucket
GET
/v1/buckets/{bucket_id}/objects
Lists all objects stored inside the designated bucket.
Create Fine-Tuning Job
POST
/v1/fine_tuning/jobs
Launch a parameter-efficient fine-tuning (LoRA / QLoRA) run on a specified base model using an uploaded dataset.
| Field | Type | Description |
| modelrequired | string | Base model name (e.g. Qwen/Qwen2.5-7B-Instruct). |
| training_filerequired | string | ID of the uploaded JSONL dataset file (file-...). |
| method | string | Training strategy: lora, qlora, or full. Default: lora. |
| hyperparameters | object | Config for n_epochs, batch_size, lora_rank, lora_alpha. |
List Fine-Tuning Jobs
GET
/v1/fine_tuning/jobs
Lists all training and fine-tuning runs created under the caller's account.
Retrieve Fine-Tuning Job
GET
/v1/fine_tuning/jobs/{job_id}
Get current execution status, trained token counts, and resulting model identifier.
Cancel Fine-Tuning Job
POST
/v1/fine_tuning/jobs/{job_id}/cancel
Gracefully halts execution of a running fine-tuning job.
List Job Checkpoints
GET
/v1/fine_tuning/jobs/{job_id}/checkpoints
Retrieves checkpoint checkpoints saved during training steps with loss metrics.
List Job Events & Logs
GET
/v1/fine_tuning/jobs/{job_id}/events
Real-time log stream and milestones emitted during model optimization.
Create Scoped API Key
POST
/v1/keys
Programmatically issue API keys with custom permission scopes and rate limits for different microservices or applications.
List API Keys
GET
/v1/keys
Lists all API keys associated with the account along with their scopes and usage status.
Retrieve API Key Details
GET
/v1/keys/{key_id}
Returns configuration and granted scopes for a designated API key ID.
Revoke API Key
DEL
/v1/keys/{key_id}
Immediately invalidates and deactivates an API key.