Einführung Die LoadSh.it API gibt programmatischen Zugriff auf Datei-Verarbeitung, Sicherheits-Scans, Transkription und alle KI-Boost-Tools (Bg-Remove, Upscale, Untertitel, Whiteboard→Diagramm, Chat-mit-PDF, Folien-Generator und mehr).
80+ Formate Video, Audio, Bilder, Dokumente
ClamAV Scan Enterprise Virenschutz
Whisper AI Transkription in 99 Sprachen
Boost AI-Tools 30+ GPU-/LLM-Tools, einheitliche Dispatch-API
Endpoints Presigned Upload-URL anfordern Erster Schritt für jede Verarbeitung: holt eine signierte Upload-URL plus den `file_key`, den die anderen Endpoints später referenzieren.
Parameter Name Typ Beschreibung filename required string Original-Dateiname inkl. Endung. size required number Dateigrösse in Bytes. content_type string MIME-Typ (z.B. video/mp4).
Beispiele
cURL
curl -X DELETE "https://loadsh.it/api/user/api-keys/key_123" \
-H "Authorization: Bearer lsh_live_xxxx"
JavaScript
const response = await fetch(
'https://loadsh.it/api/user/api-keys/key_123',
{
method: 'DELETE',
headers: { 'Authorization': 'Bearer lsh_live_xxxx' }
}
);
const data = await response.json(); Response {
"success": true,
"upload_url": "https://...",
"file_key": "inputs/1/abc.mp4"
} Datei konvertieren Konvertiert eine Datei in ein anderes Format. Zwei Wege: ENTWEDER `jobId` aus dem /api/upload-Multipart-Flow (Frontend), ODER `file_key` aus /api/nodrift/upload/presign (programmatische API-Nutzung — empfohlen). Antwort enthält `job_id` zum Pollen via /api/nodrift/jobs/<id>. Container-Erstellung nicht nötig — nodrift.ch verwaltet GPU-Pool serverless.
Parameter Name Typ Beschreibung jobId required string Job-ID aus /api/upload (Frontend) ODER file_key aus /api/nodrift/upload/presign (API). targetFormat required string Zielformat (z.B. "mp4", "pdf", "png"). processing_mode string "auto" | "force_cpu" | "force_gpu" — bei file_key-Pfad wird routing automatisch.
Beispiele
cURL
curl -X POST "https://loadsh.it/api/convert" \
-H "Authorization: Bearer lsh_live_xxxx" \
-F "file=@video.mov" \
-F "target_format=mp4"
JavaScript
const formData = new FormData();
formData.append('file', fileInput.files[0]);
formData.append('target_format', 'mp4');
const response = await fetch(
'https://loadsh.it/api/convert',
{
method: 'POST',
headers: { 'Authorization': 'Bearer lsh_live_xxxx' },
body: formData
}
);
const data = await response.json(); Response {
"success": true,
"job_id": "job_abc123",
"status": "processing"
} Sicherheits-Scan Scannt eine Datei auf Viren, Malware und andere Bedrohungen mit ClamAV & YARA Rules.
Parameter Name Typ Beschreibung file_key required string Die zu scannende Datei (multipart/form-data) original_filename string Original-Dateiname für Logs/Verlauf.
Beispiele
cURL
curl -X POST "https://loadsh.it/api/scan" \
-H "Authorization: Bearer lsh_live_xxxx" \
-F "file=@download.exe"
JavaScript
const formData = new FormData();
formData.append('file', fileInput.files[0]);
const response = await fetch(
'https://loadsh.it/api/scan',
{
method: 'POST',
headers: { 'Authorization': 'Bearer lsh_live_xxxx' },
body: formData
}
);
const data = await response.json(); Response {
"success": true,
"job_id": "job_xyz789",
"status": "queued"
} Audio/Video Transkription Transkribiert Audio/Video via Whisper über den nodrift /jobs/dispatch-Flow (Spec 2026-05). Erwartet file_key aus dem Presign-Upload. Antwortet mit job_id; Client pollt /api/nodrift/jobs/<id> bis status=completed — dort liegen transcript, language, srt_url und vtt_url. Container-Erstellung nicht mehr nötig.
Parameter Name Typ Beschreibung file_key required string R2 file_key aus /api/nodrift/upload/presign. language required string ISO-639-1-Code (de, en, fr, …). Leer lassen für Auto-Detect. output_format string "text" (Default), "timestamps", "srt", "vtt".
Beispiele
cURL
curl -X POST "https://loadsh.it/api/transcript" \
-H "Authorization: Bearer lsh_live_xxxx" \
-F "file=@interview.mp4" \
-F "language=de"
JavaScript
const formData = new FormData();
formData.append('file', fileInput.files[0]);
formData.append('language', 'de');
const response = await fetch(
'https://loadsh.it/api/transcript',
{
method: 'POST',
headers: { 'Authorization': 'Bearer lsh_live_xxxx' },
body: formData
}
);
const data = await response.json(); Response {
"success": true,
"job_id": "job_def456",
"status": "processing"
} Job Status abrufen Prüft den aktuellen Status eines laufenden oder abgeschlossenen Jobs.
Parameter Name Typ Beschreibung jobId required string Die Job-ID aus der ursprünglichen Anfrage
Beispiele
cURL
curl -X GET "https://loadsh.it/api/status/conv_abc123" \
-H "Authorization: Bearer lsh_live_xxxx"
JavaScript
const response = await fetch(
'https://loadsh.it/api/status/conv_abc123',
{
headers: { 'Authorization': 'Bearer lsh_live_xxxx' }
}
);
const data = await response.json(); Response {
"success": true,
"status": "completed",
"progress": 100,
"download_url": "https://loadsh.it/api/nodrift/download/..."
} AI-/Boost-Tools dispatchen Universeller Dispatch für alle 30+ KI-Boost-Tools (bg-remove, upscale, voice-isolate, document-scan, chat-pdf, slides-generate, video-dub, …). task_type wählt das Tool, ai_options sind tool-spezifisch (siehe nodrift-Capabilities-Endpoint für die Liste).
Parameter Name Typ Beschreibung service required string Immer "ai" für Boost-Tools. task_type required string Tool-Slug, z.B. "bg-remove", "subtitle-generate", "chat-pdf". Liste via /api/nodrift/capabilities. file_key string R2-File-Key aus dem Presign-Schritt. Bei slides-generate optional (Topic-only). ai_options object Tool-spezifisches Object. Siehe nodrift-Spec — z.B. { output_bg, edge_feather } für bg-remove, { question, file_key, prior_messages } für chat-pdf. target_lang string Optional — Übersetzungs-Ziel-Sprache für subtitle-generate (top-level, NICHT in ai_options).
Beispiele
cURL
curl -X DELETE "https://loadsh.it/api/user/api-keys/key_123" \
-H "Authorization: Bearer lsh_live_xxxx"
JavaScript
const response = await fetch(
'https://loadsh.it/api/user/api-keys/key_123',
{
method: 'DELETE',
headers: { 'Authorization': 'Bearer lsh_live_xxxx' }
}
);
const data = await response.json(); Response {
"success": true,
"job_id": "job_xxxxx",
"status": "processing",
"credits_cost": 4,
"routing": {
"use_gpu": true,
"worker": "gpu"
},
"gpu_starting": false
} Health-Check Status-Endpoint für Smoke-Tests. Antwortet mit { status: "ok", timestamp }. Kein Auth nötig — auch für externes Uptime-Monitoring brauchbar.
Beispiele
cURL
curl -X DELETE "https://loadsh.it/api/user/api-keys/key_123" \
-H "Authorization: Bearer lsh_live_xxxx"
JavaScript
const response = await fetch(
'https://loadsh.it/api/user/api-keys/key_123',
{
method: 'DELETE',
headers: { 'Authorization': 'Bearer lsh_live_xxxx' }
}
);
const data = await response.json(); Response {
"status": "ok",
"timestamp": 1735689600000
} Credit-Saldo Liefert das aktuelle nodrift-Credit-Saldo des authentifizierten Accounts. Nützlich um vor einem Dispatch zu prüfen ob genug Credits vorhanden sind.
Beispiele
cURL
curl -X DELETE "https://loadsh.it/api/user/api-keys/key_123" \
-H "Authorization: Bearer lsh_live_xxxx"
JavaScript
const response = await fetch(
'https://loadsh.it/api/user/api-keys/key_123',
{
method: 'DELETE',
headers: { 'Authorization': 'Bearer lsh_live_xxxx' }
}
);
const data = await response.json(); Response {
"credits": 142,
"currency": "CHF"
} Jobs-Liste Listet eigene nodrift-Jobs (paginiert via ?limit & ?cursor). Filter: ?status=queued|processing|completed|failed.
Parameter Name Typ Beschreibung limit number Page size (default 20, max 100). cursor string Cursor from previous response. status string queued | processing | completed | failed
Beispiele
cURL
curl -X DELETE "https://loadsh.it/api/user/api-keys/key_123" \
-H "Authorization: Bearer lsh_live_xxxx"
JavaScript
const response = await fetch(
'https://loadsh.it/api/user/api-keys/key_123',
{
method: 'DELETE',
headers: { 'Authorization': 'Bearer lsh_live_xxxx' }
}
);
const data = await response.json(); Response {
"jobs": [
{
"job_id": "job_abc",
"status": "completed",
"task_type": "bg-remove"
}
],
"next_cursor": null
} Job abbrechen Bricht einen laufenden Job ab. DELETE /api/nodrift/jobs/<job_id>. Falls der Job schon abgeschlossen ist: 409.
Parameter Name Typ Beschreibung jobId required string Job-ID aus Dispatch-Antwort.
Beispiele
cURL
curl -X DELETE "https://loadsh.it/api/user/api-keys/key_123" \
-H "Authorization: Bearer lsh_live_xxxx"
JavaScript
const response = await fetch(
'https://loadsh.it/api/user/api-keys/key_123',
{
method: 'DELETE',
headers: { 'Authorization': 'Bearer lsh_live_xxxx' }
}
);
const data = await response.json(); Response {
"success": true,
"status": "cancelled"
} URL-Import Lädt eine Datei von einer öffentlichen URL (YouTube, Direct-Download) statt eines Multipart-Uploads. Body: { url, target_format? }. Antwort enthält den jobId für /api/status.
Parameter Name Typ Beschreibung url required string Quelle (https-URL, YouTube/Vimeo/etc.). target_format string Optional Zielformat — wenn gesetzt, läuft direkt nach Import die Konvertierung.
Beispiele
cURL
curl -X DELETE "https://loadsh.it/api/user/api-keys/key_123" \
-H "Authorization: Bearer lsh_live_xxxx"
JavaScript
const response = await fetch(
'https://loadsh.it/api/user/api-keys/key_123',
{
method: 'DELETE',
headers: { 'Authorization': 'Bearer lsh_live_xxxx' }
}
);
const data = await response.json(); Response {
"success": true,
"jobId": "job_imp_xyz",
"status": "queued"
} Universal AI-Tools Einheitlicher Endpoint POST /api/ai/<task_type> für alle ~50 Boost-Tools (bg-remove, upscale, ocr-pro, headshot-generate, slides-generate, chat-pdf, math-solve, voice-clone, video-summarize, …). Body: { file_key, ai_options? } — bei slides-generate stattdessen { topic }, bei chat-pdf { pdf_file_key, question | prior_messages }. Antwort: { job_id, poll_url, gpu_starting, credits_cost }. Liste verfügbarer Tasks via GET /api/ai.
Parameter Name Typ Beschreibung :taskType required string Pfad-Parameter — z.B. bg-remove, upscale, ocr-pro, headshot-generate. file_key string R2-Key aus /api/nodrift/upload/presign. Nicht nötig für slides-generate (nutze topic) oder chat-pdf (nutze pdf_file_key). ai_options object Task-spezifische Parameter (z.B. scale=2 für upscale, tone=professional für cover-letter).
Beispiele
cURL
curl -X DELETE "https://loadsh.it/api/user/api-keys/key_123" \
-H "Authorization: Bearer lsh_live_xxxx"
JavaScript
const response = await fetch(
'https://loadsh.it/api/user/api-keys/key_123',
{
method: 'DELETE',
headers: { 'Authorization': 'Bearer lsh_live_xxxx' }
}
);
const data = await response.json(); Response {
"success": true,
"job_id": "job_abc123",
"status": "queued",
"gpu_starting": false,
"credits_cost": 2,
"poll_url": "https://loadsh.it/api/nodrift/jobs/job_abc123"
} Tool-Discovery Listet alle verfügbaren Task-Types mit Endpoint-Pfad und Pflicht-Inputs. Nutze /api/nodrift/capabilities für Limits + Credit-Kosten je Task.
Beispiele
cURL
curl -X DELETE "https://loadsh.it/api/user/api-keys/key_123" \
-H "Authorization: Bearer lsh_live_xxxx"
JavaScript
const response = await fetch(
'https://loadsh.it/api/user/api-keys/key_123',
{
method: 'DELETE',
headers: { 'Authorization': 'Bearer lsh_live_xxxx' }
}
);
const data = await response.json(); Response {
"tasks": [
{
"task_type": "bg-remove",
"service": "image-gen",
"endpoint": "/api/ai/bg-remove",
"required_input": "file_key"
},
{
"task_type": "slides-generate",
"service": "llm",
"endpoint": "/api/ai/slides-generate",
"required_input": "topic"
},
{
"task_type": "chat-pdf",
"service": "llm",
"endpoint": "/api/ai/chat-pdf",
"required_input": "pdf_file_key+question"
}
]
} Tool-Capabilities abfragen Listet alle verfügbaren Tools mit Pricing, Engine, Burst-Tier, max_input_mb und supported_languages. Cached 5 min Edge-seitig. Auth nicht erforderlich.
Beispiele
cURL
curl -X DELETE "https://loadsh.it/api/user/api-keys/key_123" \
-H "Authorization: Bearer lsh_live_xxxx"
JavaScript
const response = await fetch(
'https://loadsh.it/api/user/api-keys/key_123',
{
method: 'DELETE',
headers: { 'Authorization': 'Bearer lsh_live_xxxx' }
}
);
const data = await response.json(); Response {
"tools": {
"bg-remove": {
"available": true,
"credit_cost": 2,
"category": "gpu",
"max_input_mb": 25
},
"subtitle-generate": {
"available": true,
"credit_cost": 3,
"category": "gpu",
"burst_tier": "whisper"
},
"chat-pdf": {
"available": true,
"credit_cost": 1,
"category": "workers-ai"
}
}
} GPU-Pre-Warm triggern Optional — kickt den GPU-Burst-Container für eine Service-Kategorie an, BEVOR der eigentliche Job dispatched wird. Spart 30-60s Cold-Start. Body: { service, task_type? }. Service ist einer von "vision" | "ocr" | "llm" | "image-gen" | "audio-gen" | "video" | "transcribe".
Parameter Name Typ Beschreibung service required string GPU-Pool-Name (siehe Spec). task_type string Optional — präzisiert den Pool falls service mehrere abdeckt.
Beispiele
cURL
curl -X DELETE "https://loadsh.it/api/user/api-keys/key_123" \
-H "Authorization: Bearer lsh_live_xxxx"
JavaScript
const response = await fetch(
'https://loadsh.it/api/user/api-keys/key_123',
{
method: 'DELETE',
headers: { 'Authorization': 'Bearer lsh_live_xxxx' }
}
);
const data = await response.json(); Response {
"triggered": true,
"status": 202
} API Keys auflisten Listet alle API Keys des authentifizierten Benutzers auf.
Beispiele
cURL
curl -X GET "https://loadsh.it/api/user/api-keys" \
-H "Authorization: Bearer lsh_live_xxxx"
JavaScript
const response = await fetch(
'https://loadsh.it/api/user/api-keys',
{
headers: { 'Authorization': 'Bearer lsh_live_xxxx' }
}
);
const data = await response.json(); Response {
"success": true,
"keys": [
{
"id": "key_123",
"name": "Production",
"created_at": "2025-01-01",
"last_used": "2025-01-03"
}
]
} API Key erstellen Erstellt einen neuen API Key. Der vollständige Key wird nur einmal angezeigt!
Parameter Name Typ Beschreibung name required string Name/Beschreibung des Keys
Beispiele
cURL
curl -X POST "https://loadsh.it/api/user/api-keys" \
-H "Authorization: Bearer lsh_live_xxxx" \
-H "Content-Type: application/json" \
-d '{"name": "My App"}'
JavaScript
const response = await fetch(
'https://loadsh.it/api/user/api-keys',
{
method: 'POST',
headers: {
'Authorization': 'Bearer lsh_live_xxxx',
'Content-Type': 'application/json'
},
body: JSON.stringify({ name: 'My App' })
}
);
const data = await response.json(); Response {
"success": true,
"key": {
"id": "key_456",
"name": "My App",
"token": "lsh_live_xxxxxxxxxxxxxxxxxxxxxxxx"
}
} API Key löschen Löscht einen API Key unwiderruflich.
Parameter Name Typ Beschreibung id required string ID des zu löschenden Keys
Beispiele
cURL
curl -X DELETE "https://loadsh.it/api/user/api-keys/key_123" \
-H "Authorization: Bearer lsh_live_xxxx"
JavaScript
const response = await fetch(
'https://loadsh.it/api/user/api-keys/key_123',
{
method: 'DELETE',
headers: { 'Authorization': 'Bearer lsh_live_xxxx' }
}
);
const data = await response.json(); Response {
"success": true,
"message": "Key deleted"
}