The Yoink API is a JSON-over-HTTP interface served by a self-hosted Go server. All endpoints are accessible over plain HTTP on the configured port (defaultDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/coah80/yoink/llms.txt
Use this file to discover all available pages before exploring further.
3001). Every response body is a JSON object, download streams are delivered as binary responses, and real-time progress is pushed over Server-Sent Events. This page covers the baseline facts you need before calling any endpoint.
Base URL
PORT environment variable. If PORT is not set, the server defaults to 3001. Replace your-server with the hostname or IP address of the machine running Yoink.
Authentication
Yoink uses a two-tier authentication model depending on which route group you are targeting.Web Endpoints
Routes under
/api/* (download, convert, compress, progress, etc.) require no authentication by default. They are rate-limited per IP instead.Bot Endpoints
Routes under
/api/bot/* require an Authorization: Bearer {BOT_SECRET} header. Set the BOT_SECRET environment variable on the server to enable this.Bot Authorization Header
Bearer token required for all
/api/bot/* endpoints. Format: Bearer {BOT_SECRET}.Rate Limiting
All requests are subject to a sliding-window rate limit enforced per client IP address. The rate limiter runs before any route handler, so even unauthenticated requests count against the limit.| Parameter | Value |
|---|---|
| Window | 60 seconds (RateLimitWindow) |
| Max requests | 60 per window (RateLimitMax) |
| Scope | Per IP address |
| Header: limit | X-RateLimit-Limit |
| Header: remaining | X-RateLimit-Remaining |
| Header: reset | X-RateLimit-Reset (seconds, only on 429) |
429 and a JSON body:
resetIn is the number of seconds until the oldest request in the current window expires and a new request will be permitted.
CORS
CORS is enabled via the go-chi/cors middleware. Behaviour depends on whether acors-origins.txt file is present on the server:
- With
cors-origins.txt: Only the origins listed in the file are allowed, andcredentials: trueis set. This is the recommended configuration for production. - Without
cors-origins.txt: All origins (*) are allowed, but credentials are disabled. A warning is printed to the server log at startup.
GET, POST, PUT, DELETE, OPTIONS. The MaxAge for preflight caches is set to 86400 seconds (24 hours).
Response Format
All API responses returnContent-Type: application/json. Success and error bodies follow the same envelope pattern:
Success
success boolean alongside a message string for operations that may partially succeed (e.g. cancel and finish-early).
Security Headers
Every response includes the following security headers regardless of route:| Header | Value |
|---|---|
X-Content-Type-Options | nosniff |
X-Frame-Options | DENY |
Referrer-Policy | strict-origin-when-cross-origin |
Route Groups
| Group | Path Prefix | Auth Required |
|---|---|---|
| Core | /health, /api/connect, /api/heartbeat, /api/queue-status, /api/limits, /api/progress, /api/cancel, /api/finish-early | No |
| Download | /api/download | No |
| Playlist | /api/playlist | No |
| Convert | /api/convert | No |
| Gallery | /api/gallery | No |
| Transcribe | /api/transcribe | No |
| Bot | /api/bot/* | Yes — Bearer token |
Global Job Limits
Yoink enforces concurrency limits on background job types to prevent resource exhaustion. These limits are fixed at compile time and can be inspected at runtime viaGET /api/limits.
| Job Type | Concurrent Slots |
|---|---|
playlist | 2 |
convert | 2 |
compress | 1 |
transcribe | 1 |
fetchUrl | 2 |
| Constraint | Value |
|---|---|
| Max jobs per client | 3 |
| Queue size limit | 50 |
| Max file size | 15 GB |
| Max playlist videos | 1,000 |
| Max video duration | 14,400 seconds (4 hours) |
When the queue is full (50 pending jobs) the server will reject new job requests with an error response. Poll
GET /api/queue-status to check current queue depth before submitting long-running jobs.Health Check
UseGET /health to verify the server is running and inspect the current queue state. This endpoint is not rate-limited and does not require a session.
Always
"ok" when the server is healthy.Server version string.
Current queue state object returned by the internal queue service. Shape may include active job counts and per-type breakdowns.
Limits Endpoint
GET /api/limits returns the server’s current concurrency limits and content constraints in a single call — useful for client-side validation before submitting jobs.
Map of job type to the maximum number of concurrent workers for that type.
Maximum output file size in bytes (15 GB = 16,106,127,360).
Maximum number of videos that can be included in a single playlist download.
Maximum video duration in seconds (14,400 = 4 hours).