API Overview
Authentication, base URL, rate limits, error handling, and pagination for the Outpost REST API
The Outpost REST API provides programmatic access to repositories, machines, services, jobs, namespaces, SSH keys, secrets, and more. All requests and responses use JSON.
Base URL
All API requests are made relative to the /auth/v1/ base path:
All endpoint paths in this documentation are relative to the base URL. For example, GET /auth/v1/users means:
Authentication
The Outpost API supports two authentication methods: Bearer tokens and API keys. Both are passed via the Authorization header.
Bearer token
Obtain a Bearer token by authenticating through the OAuth/OIDC flow or by creating a Personal Access Token (PAT). Include it in the Authorization header:
API key
Generate an API key from the Outpost dashboard under Settings > API Keys. API keys use the format key_name$key_secret and are passed with the API-Key scheme:
Personal Access Tokens
You can also create and manage Personal Access Tokens (PATs) programmatically:
Content type
All requests with a body must include the Content-Type: application/json header. All responses return JSON.
Rate limits
API requests are rate-limited per authentication credential:
| Plan | Rate limit | Burst limit |
|---|---|---|
| Free | 60 requests/min | 10 req/s |
| Team | 300 requests/min | 30 req/s |
| Enterprise | 1,000 requests/min | 100 req/s |
Rate limit headers are included in every response:
When you exceed the rate limit, the API returns 429:
Error format
All errors follow a consistent JSON structure:
HTTP status codes
| Status | Badge | Description |
|---|---|---|
| 200 | 200 | Request succeeded |
| 201 | 201 | Resource created |
| 204 | 204 | Resource deleted (no content) |
| 400 | 400 | Bad request -- invalid parameters |
| 401 | 401 | Unauthorized -- missing or invalid credentials |
| 403 | 403 | Forbidden -- insufficient permissions |
| 404 | 404 | Not found -- resource does not exist |
| 409 | 409 | Conflict -- resource already exists |
| 422 | 422 | Unprocessable entity -- validation error |
| 429 | 429 | Rate limit exceeded |
| 500 | 500 | Internal server error |
Common error codes
| Error code | Description |
|---|---|
invalid_request | The request body is malformed or missing required fields |
authentication_failed | The provided credentials are invalid or expired |
permission_denied | The authenticated user lacks permission for this action |
not_found | The requested resource does not exist |
already_exists | A resource with the same identifier already exists |
rate_limit_exceeded | Too many requests in the current window |
quota_exceeded | Account quota for this resource type has been reached |
Pagination
List endpoints return paginated results. Use the page and per_page query parameters to control pagination.
Paginated responses include metadata in the response body:
| Parameter | Type | Default | Description |
|---|---|---|---|
page | integer | 1 | Page number (1-indexed) |
per_page | integer | 20 | Items per page (max 100) |
Versioning
The API is versioned via the URL path. The current version is v1. All endpoints are prefixed with /auth/v1/.
Health and diagnostics
You can check the API health status and version without authentication:
GET `/auth/v1/health` -- Health checkAPI reference
- Repositories -- Create, list, and manage Git repositories
- Machines -- Provision and control development machines
- Services -- Deploy and scale production services
- Jobs -- Submit and monitor batch jobs
Next Repositories →