VidGenie-API · v0.0.2

Programmatic video generation API.

Submit render jobs, manage templates, and retrieve generated video outputs through a straightforward JSON API.

Ship your first render in two calls.

Submit a job, get back an ID. Poll render.get or wait for the webhook.

POST /api/v1/render.create
curl -X POST __API_BASE_URL__/api/v1/render.create \
  -H 'Content-Type: application/json' \
  -H 'x-api-key: $VIDGENIE_KEY' \
  -d '{
    "timeline": { "tracks": [] },
    "output":   { "format": "mp4", "resolution": "1080p", "fps": 30 }
  }'

Built for production rendering.

Tools you'd reach for in production, with the operational simplicity of a single Postgres database.

RPC-style endpoints

Predictable URLs like /api/v1/render.create. No nouns-vs-verbs ambiguity, no clever HTTP semantics.

Templates with merge fields

Define a timeline once with {{name}} placeholders. Render N variants by POSTing values; no client-side templating needed.

Webhooks on completion

Subscribe to render.done and render.failed. Workers push results — no polling required.

Per-user keys + audit log

Login returns a short-lived bearer token for account and key management. Minted API keys power render traffic and every authed call is audited.

Worker-backed rendering

The API queues render jobs while workers process videos asynchronously and persist the result for download.

Postgres job queue

Workers claim jobs with FOR UPDATE SKIP LOCKED. Scale horizontally — no Redis, no SQS.

Four steps to your first API key.

Create an account, verify it, then use the login access token to mint machine keys.

  1. 1

    Register

    Create a pending account with a username, email, and password.

    curl -X POST __API_BASE_URL__/api/v1/account.register \
      -H 'Content-Type: application/json' \
      -d '{
        "username": "you",
        "email": "you@example.com",
        "password": "correct horse battery staple"
      }'
  2. 2

    Verify your email

    Tokens expire in 24 hours by default. Configurable via --email-verification-ttl.

    curl -X POST __API_BASE_URL__/api/v1/account.verify_email \
      -H 'Content-Type: application/json' \
      -d '{ "token": "<from-the-email-we-sent>" }'
  3. 3

    Login

    Use the returned bearer token on account.* and apikey.* calls.

    curl -X POST __API_BASE_URL__/api/v1/account.login \
      -H 'Content-Type: application/json' \
      -d '{
        "username": "you",
        "password": "correct horse battery staple"
      }'
    # response.data.access_token starts with vg_at_
  4. 4

    Mint an API key

    Use Authorization: Bearer here. Render and template endpoints use the minted x-api-key.

    curl -X POST __API_BASE_URL__/api/v1/apikey.create \
      -H 'Content-Type: application/json' \
      -H 'Authorization: Bearer <access-token>' \
      -d '{ "name": "laptop" }'
    # response.data.api_key.plaintext starts with vg_live_ and is shown once.

Build with the API.

Create an account, mint a key, and submit your first render job.