Upload
Upload audio or video files for transcription and processing.
Upload a meeting recording via a two-step flow: get a presigned URL, then confirm when done.
Step 1: Request Upload URL
POST /v1/upload/request-urlRequest Body
| Field | Type | Required | Description |
|---|---|---|---|
fileName | string | Yes | File name with extension |
Supported formats: mp4, webm, mov, mp3, m4a, wav
Maximum file size: 5 GB
Response
{
"success": true,
"data": {
"uploadUrl": "https://storage.../presigned-put-url",
"uploadId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"requiredHeaders": {}
}
}Step 2: Upload the File
PUT your file directly to the uploadUrl from step 1. Include any requiredHeaders if present.
curl -X PUT "UPLOAD_URL_FROM_STEP_1" --data-binary @./my-meeting.mp3Step 3: Trigger Processing
POST /v1/upload/completeRequest Body
| Field | Type | Required | Description |
|---|---|---|---|
uploadId | UUID | Yes | The upload ID from step 1 |
title | string | No | Meeting title (defaults to "Untitled Upload") |
protocolId | UUID | No | Protocol for summarization (defaults to your default protocol) |
Response
{
"success": true,
"message": "Processing started"
}Full Example
# Step 1: Get upload URL
curl -X POST "https://api.optiverse.ai/external-api/v1/upload/request-url" \
-H "Authorization: Bearer optiuser_v1_your_key_here" \
-H "Content-Type: application/json" \
-d '{"fileName": "weekly-sync.mp3"}'
# Step 2: Upload the file (use uploadUrl from step 1)
curl -X PUT "UPLOAD_URL" --data-binary @./weekly-sync.mp3
# Step 3: Trigger processing (use uploadId from step 1)
curl -X POST "https://api.optiverse.ai/external-api/v1/upload/complete" \
-H "Authorization: Bearer optiuser_v1_your_key_here" \
-H "Content-Type: application/json" \
-d '{"uploadId": "UPLOAD_ID", "title": "Weekly Sync"}'const axios = require('axios');
const fs = require('fs');
const API_KEY = 'optiuser_v1_your_key_here';
const BASE_URL = 'https://api.optiverse.ai/external-api';
const headers = { 'Authorization': `Bearer ${API_KEY}` };
// Step 1: Get upload URL
const { data } = await axios.post(`${BASE_URL}/v1/upload/request-url`,
{ fileName: 'weekly-sync.mp3' },
{ headers }
);
const { uploadUrl, uploadId, requiredHeaders } = data.data;
// Step 2: Upload the file
const file = fs.readFileSync('./weekly-sync.mp3');
await axios.put(uploadUrl, file, {
headers: { ...requiredHeaders },
maxBodyLength: Infinity
});
// Step 3: Trigger processing
await axios.post(`${BASE_URL}/v1/upload/complete`,
{ uploadId, title: 'Weekly Sync', protocolId: null },
{ headers }
);Errors
| Status | Code | Description |
|---|---|---|
| 400 | VAL001 | Invalid file name or unsupported format |
| 400 | VAL001 | Missing or invalid uploadId |
| 401 | AUTH001 | Missing authorization header |
| 401 | AUTH002 | Invalid API key |
| 500 | SRV500 | Internal server error |