Partner API v1

    DiLa TV Network — Distribution API

    Distribute the DiLa TV Network catalog on your platform: REST endpoints plus a Media RSS (MRSS) feed for smart-TV, Roku, and CMS ingestion. Metadata-only — playback URLs are not exposed.

    API Key Auth
    Per-partner bearer tokens, revocable.
    REST + MRSS
    JSON endpoints and a Media RSS feed.
    Catalog metadata
    Hidden titles excluded; premium flagged.

    Base URL

    https://c--bf581b83-a43c-41fe-9623-d2bd657e9fb4-prod.lovable.cloud/functions/v1/partner-api

    Authentication

    Every request (except /v1/health) requires a bearer token issued by DiLa TV admins. Contact your account manager to obtain a key. Keep keys server-side — never embed in client apps.

    Authorization: Bearer dilatv_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

    Endpoints

    GET /v1/content

    Paginated catalog listing.

    Query params: limit (max 200), offset, genre, channel_id, publisher_id, type, search, updated_since (ISO timestamp).

    curl -H "Authorization: Bearer $KEY" \
      "https://c--bf581b83-a43c-41fe-9623-d2bd657e9fb4-prod.lovable.cloud/functions/v1/partner-api/v1/content?limit=20&genre=Drama"

    GET /v1/content/:id

    Single title metadata.

    curl -H "Authorization: Bearer $KEY" "https://c--bf581b83-a43c-41fe-9623-d2bd657e9fb4-prod.lovable.cloud/functions/v1/partner-api/v1/content/<uuid>"

    GET /v1/channels

    Active channel directory.

    GET /v1/publishers

    Publisher directory.

    GET /v1/feed.rss

    Media RSS 2.0 (MRSS) feed of the 100 latest non-hidden titles. Suitable for Roku Direct Publisher, podcast-style ingestion, and smart-TV apps that consume RSS catalogs.

    https://c--bf581b83-a43c-41fe-9623-d2bd657e9fb4-prod.lovable.cloud/functions/v1/partner-api/v1/feed.rss

    GET /v1/health

    Public uptime check (no auth).

    Content schema

    {
      "id": "uuid",
      "title": "string",
      "description": "string",
      "type": "movie | series | ...",
      "year": 2025,
      "rating": "PG-13",
      "duration": "1h 42m",
      "genres": ["Drama"],
      "cast": ["..."],
      "poster_url": "https://...",
      "banner_url": "https://...",
      "release_date": "2025-01-01",
      "channel_id": "uuid|null",
      "publisher_id": "uuid|null",
      "is_free": false,
      "is_premium": true,
      "requires_purchase": true,
      "ppv_price_cents": 499,
      "rental_price_cents": 299,
      "rental_duration_hours": 48,
      "updated_at": "2025-...",
      "canonical_url": "https://dilatvnetwork.lovable.app/title/<id>"
    }

    Visibility & monetization rules

    • Hidden titles are never returned.
    • Premium titles are returned with requires_purchase: true; playback URLs are not exposed.
    • Direct viewers to canonical_url to complete purchase or rental on DiLa TV.

    Errors & limits

    • 401 — missing or invalid bearer token.
    • 404 — resource not found.
    • 500 — upstream error; safe to retry with backoff.
    • Responses cached max-age=60 (JSON) / max-age=300 (RSS).
    • Per-key rate limits apply; contact admin to raise.