Compeller Media API
Upload and retrieve account-owned media (audio, image, video, text).
Operations 5
POST
/api/v1/media/upload-url
Get an upload contract describing how and where to POST a media file
#
Upload and retrieve account-owned media (audio, image, video, text).
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/compeller-ai:compeller-ai-media-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Compeller Ai Media API
version: 1.0.0
description: 'Operations tagged Media across 2 of this provider''s published API definitions: compeller-ai-openapi.yaml, compeller-ai-openapi.yml. Each path carries the servers of the definition it was published in.'
servers:
- url: https://compeller.ai
description: Production
- url: https://dev.compeller.ai
description: Development
security:
- bearerToken: []
- apiTokenHeader: []
tags:
- name: Media
description: Upload and retrieve account-owned media (audio, image, video, text).
paths:
/api/v1/media/upload-url:
post:
tags:
- Media
operationId: requestMediaUploadUrl
summary: Get an upload contract describing how and where to POST a media file
description: 'Returns a descriptor pointing at `POST /api/v1/media`. There is no pre-signed
object-store URL today - the actual upload target is this same server, and the
descriptor''s `upload_url` field is the literal string `/api/v1/media`. The
descriptor exists so clients can be coded against a contract that can later move
to a signed S3/GCS URL without code changes.'
requestBody:
required: false
content:
application/json:
schema:
$ref: '#/components/schemas/MediaUploadUrlRequest'
responses:
'200':
description: Upload contract.
content:
application/json:
schema:
$ref: '#/components/schemas/MediaUploadUrlResponse'
'401':
$ref: '#/components/responses/UnauthorizedMediaStyle'
servers:
- url: https://compeller.ai
description: Production
- url: https://dev.compeller.ai
description: Development
/api/v1/media:
post:
tags:
- Media
operationId: uploadMedia
summary: Upload a media file (audio, image, video, or text)
description: 'Submit as `multipart/form-data`. The `file` part is required. Other fields are
optional query-string or form parameters. Audio should be submitted as `audio`.'
requestBody:
required: true
content:
multipart/form-data:
schema:
$ref: '#/components/schemas/MediaUploadForm'
encoding:
file:
contentType: application/octet-stream
parameters:
- name: type
in: query
description: Media type override. Values `audio`, `image`, `video`, `text`.
required: false
schema:
type: string
- name: media_type
in: query
description: Alias for `type`.
required: false
schema:
type: string
- name: workspace_id
in: query
description: Compel id to attach the media to (alias `compel_id`).
required: false
schema:
type: integer
format: int64
- name: compel_id
in: query
description: Alias for `workspace_id`.
required: false
schema:
type: integer
format: int64
responses:
'201':
description: Media record created.
content:
application/json:
schema:
$ref: '#/components/schemas/MediaEnvelope'
'400':
$ref: '#/components/responses/BadRequestMediaStyle'
'401':
$ref: '#/components/responses/UnauthorizedMediaStyle'
'422':
$ref: '#/components/responses/UnprocessableMediaStyle'
get:
tags:
- Media
operationId: listMedia
summary: List media records owned by the authenticated account
parameters:
- name: max
in: query
schema:
type: integer
default: 20
maximum: 100
- name: offset
in: query
schema:
type: integer
default: 0
minimum: 0
- name: type
in: query
schema:
type: string
- name: media_type
in: query
schema:
type: string
- name: workspace_id
in: query
schema:
type: integer
format: int64
- name: compel_id
in: query
schema:
type: integer
format: int64
responses:
'200':
description: Paged media list.
content:
application/json:
schema:
$ref: '#/components/schemas/MediaListResponse'
'401':
$ref: '#/components/responses/UnauthorizedMediaStyle'
servers:
- url: https://compeller.ai
description: Production
- url: https://dev.compeller.ai
description: Development
/api/v1/media/{id}:
get:
tags:
- Media
operationId: getMedia
summary: Fetch a single media record by id
parameters:
- $ref: '#/components/parameters/PathId'
responses:
'200':
description: Media envelope.
content:
application/json:
schema:
$ref: '#/components/schemas/MediaEnvelope'
'401':
$ref: '#/components/responses/UnauthorizedMediaStyle'
'404':
description: Not found or not owned by the authenticated account. Empty body.
servers:
- url: https://compeller.ai
description: Production
- url: https://dev.compeller.ai
description: Development
/api/v1/media/{id}/download:
get:
tags:
- Media
operationId: downloadMedia
summary: Stream a media file
parameters:
- $ref: '#/components/parameters/PathId'
responses:
'200':
description: Media file bytes. `Content-Type` reflects the stored mime type.
content:
application/octet-stream:
schema:
type: string
format: binary
'401':
$ref: '#/components/responses/UnauthorizedMediaStyle'
'404':
description: Not found or not owned by the authenticated account. Empty body.
servers:
- url: https://compeller.ai
description: Production
- url: https://dev.compeller.ai
description: Development
components:
responses:
UnauthorizedMediaStyle:
description: Missing or invalid API token (legacy media-controller error shape).
content:
application/json:
schema:
$ref: '#/components/schemas/MessageError'
UnprocessableMediaStyle:
description: Request understood but media service could not persist it.
content:
application/json:
schema:
$ref: '#/components/schemas/MessageError'
BadRequestMediaStyle:
description: Malformed request (legacy media-controller error shape).
content:
application/json:
schema:
$ref: '#/components/schemas/MessageError'
schemas:
MediaUploadUrlResponse:
type: object
required:
- upload_url
- method
- expires_at
- headers
- fields
- media
properties:
upload_url:
type: string
description: The literal string `/api/v1/media` - not a signed external URL.
example: /api/v1/media
method:
type: string
enum:
- POST
expires_at:
type: string
format: date-time
headers:
type: object
additionalProperties:
type: string
fields:
type: object
additionalProperties: true
media:
$ref: '#/components/schemas/MediaDescriptorPlaceholder'
MediaUploadUrlRequest:
type: object
properties:
name:
type: string
example: track.mp3
file_name:
type: string
description: Alias for `name`.
mime_type:
type: string
example: audio/mpeg
mimeType:
type: string
description: Alias for `mime_type`.
type:
type: string
enum:
- audio
- image
- video
- text
media_type:
type: string
description: Alias for `type`.
role:
type: string
enum:
- primary
- reference
tags:
oneOf:
- type: array
items:
type: string
- type: string
description: Comma-separated tags.
workspace_id:
type: integer
format: int64
compel_id:
type: integer
format: int64
description: Alias for `workspace_id`.
duration_ms:
type: integer
format: int64
MessageError:
type: object
required:
- message
properties:
message:
type: string
Paging:
type: object
properties:
total:
type: integer
format: int64
limit:
type: integer
max:
type: integer
description: Present on legacy listings (media). Equivalent to `limit`.
offset:
type: integer
MediaUploadForm:
type: object
required:
- file
properties:
file:
type: string
format: binary
description: The media file bytes.
type:
type: string
description: Optional override, mirrors the `type` query parameter.
media_type:
type: string
description: Alias for `type`.
workspace_id:
type: integer
format: int64
compel_id:
type: integer
format: int64
Media:
type: object
required:
- id
- type
- status
- download_url
properties:
id:
type: integer
format: int64
workspace_id:
type:
- integer
- 'null'
format: int64
type:
type: string
enum:
- audio
- image
- video
- text
role:
type: string
example: primary
mime_type:
type: string
name:
type: string
status:
type: string
enum:
- UPLOADING
- PROCESSING
- READY
- FAILED
duration_ms:
type:
- integer
- 'null'
format: int64
tags:
type: array
items:
type: string
download_url:
type: string
description: Relative URL, prefix with the server base to fetch.
example: /api/v1/media/55/download
MediaEnvelope:
type: object
required:
- media
properties:
media:
$ref: '#/components/schemas/Media'
MediaListResponse:
type: object
required:
- media
- paging
properties:
media:
type: array
items:
$ref: '#/components/schemas/Media'
paging:
$ref: '#/components/schemas/Paging'
MediaDescriptorPlaceholder:
type: object
description: 'Placeholder media descriptor with `id: null` and `status: UPLOADING`.'
properties:
id:
type:
- integer
- 'null'
format: int64
workspace_id:
type:
- integer
- 'null'
format: int64
type:
type: string
role:
type: string
mime_type:
type: string
name:
type: string
status:
type: string
example: UPLOADING
duration_ms:
type:
- integer
- 'null'
format: int64
tags:
type: array
items:
type: string
download_url:
type:
- string
- 'null'
parameters:
PathId:
name: id
in: path
required: true
schema:
type: integer
format: int64
securitySchemes:
bearerToken:
type: http
scheme: bearer
bearerFormat: opaque
description: 'Compeller API token sent as `Authorization: Bearer <token>`.'
apiTokenHeader:
type: apiKey
in: header
name: X-API-Token
description: 'Compeller API token sent as `X-API-Token: <token>` (equivalent to bearer).'
x-refined-from:
- compeller-ai-openapi.yaml
- compeller-ai-openapi.yml