# PeerTube API
> Read PeerTube — the federated, open-source video network — in real time, with no key. Federated search (powered by SepiaSearch) finds videos, channels and playlists across thousands of PeerTube instances at once. Per instance you can list and sort videos, fetch any video's detail, its comment threads and subtitle/caption tracks, look up any channel or account and their videos, and read the instance config, server statistics and the video-category list. Federated handles (name@instance) resolve transparently, and you can point any per-instance call at a specific server with ?instance=<host> (default framatube.org). Every call is live (no cache) and returns the upstream PeerTube REST shape, paginated with limit + start. 14 endpoints. Built for federated video discovery, creator and channel analytics, and content aggregation. A PeerTube (federated video) data API — distinct from single-platform video APIs like YouTube or Dailymotion. No upstream key, no cache.

## Authentication
All requests require your oanor API key in the `x-oanor-key` header. Get one at https://www.oanor.com/developer/keys.

```bash
curl -H "x-oanor-key: oanor_live_…" "https://api.oanor.com/peertube-api/..."
```

## Pricing
- **Free** (Free) — 2,900 calls/Mo, 2 req/s
- **Starter** ($8/Mo) — 60,000 calls/Mo, 8 req/s
- **Pro** ($24/Mo) — 300,000 calls/Mo, 20 req/s
- **Mega** ($53/Mo) — 1,500,000 calls/Mo, 50 req/s

## Endpoints

### Search

#### `GET /v1/search/channels` — Federated channel search

**Parameters:**
- `q` (query, required, string) — Query Example: `news`
- `limit` (query, optional, string) — Page size

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/peertube-api/v1/search/channels?q=news"
```

**Response:**
```json
{
    "data": {
        "data": [
            {
                "id": 5,
                "url": "https://video.fedihost.co/video-channels/news",
                "host": "video.fedihost.co",
                "name": "news",
                "score": 1,
                "avatars": [
                    {
                        "url": "https://video.fedihost.co/lazy-static/avatars/ae0f608f-9f77-449a-820c-7aeea9d83f4d.png",
                        "path": "/lazy-static/avatars/ae0f608f-9f77-449a-820c-7aeea9d83f4d.png",
                        "width": 48,
                        "height": 48,
                        "fileUrl": "https://video.fedihost.co/lazy-static/avatars/ae0f608f-9f77-449a-820c-7aeea9d83f4d.png",
                        "createdAt": "2024-11-14T20:23:41.942Z",
                        "updatedAt": "2024-11-14T20:23:41.942Z"
                    },
                    {
                        "url": "https://video.fedihost.co/lazy-static/avatars/1bc78deb-b5ee-4a49-84f4-39d54f509540.png",
                        "path": "/lazy-static/avatars/1bc78deb-b5ee-4a49-84f4-39d54f509540.png",
                        "width": 120,
                        "height": 120,
                        "fileUrl": "https://video.fedihost.co/lazy-static/avatars/1bc78deb-b5ee-4a49-84f4-39d54f509540.png",
                        "createdAt": "2024-11-14T20:23:41.940Z",
                        "updatedAt": "2024-11-14T20:23:41.940Z"
                    },
                    {
             
…(truncated, see openapi.json for full schema)
```

#### `GET /v1/search/playlists` — Federated playlist search

**Parameters:**
- `q` (query, required, string) — Query Example: `music`
- `limit` (query, optional, string) — Page size

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/peertube-api/v1/search/playlists?q=music"
```

**Response:**
```json
{
    "data": {
        "data": [
            {
                "id": 8,
                "url": "https://libretube.ru/videos/watch/playlist/ac1a3d12-1ea4-4356-8c1e-a344109ccf8e",
                "type": {
                    "id": 1,
                    "label": "Regular"
                },
                "uuid": "ac1a3d12-1ea4-4356-8c1e-a344109ccf8e",
                "score": 1,
                "isLocal": false,
                "privacy": {
                    "id": 1,
                    "label": "Public"
                },
                "embedUrl": "https://libretube.ru/video-playlists/embed/nfBypXHH3Hb4YAtkNVu1Uo",
                "createdAt": "2026-03-02T18:25:51.016Z",
                "embedPath": "/video-playlists/embed/nfBypXHH3Hb4YAtkNVu1Uo",
                "shortUUID": "nfBypXHH3Hb4YAtkNVu1Uo",
                "updatedAt": "2026-03-03T15:55:35.501Z",
                "description": null,
                "displayName": "Music",
                "ownerAccount": {
                    "id": 3,
                    "url": "https://libretube.ru/accounts/v.reznik",
                    "host": "libretube.ru",
                    "name": "v.reznik",
                    "avatars": [
                        {
                            "url": "https://libretube.ru/lazy-static/avatars/29f104ff-bfaf-4403-8870-9a40c77a1f4c.jpg",
                            "path": "/lazy-static/avatars/29f104ff-bfaf-4403-8870-9a40c77a1f4c.jpg",
                            "width": 48,
         
…(truncated, see openapi.json for full schema)
```

#### `GET /v1/search/videos` — Federated video search

**Parameters:**
- `q` (query, required, string) — Query Example: `linux`
- `limit` (query, optional, string) — Page size

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/peertube-api/v1/search/videos?q=linux"
```

**Response:**
```json
{
    "data": {
        "data": [
            {
                "id": 167978,
                "url": "https://spectra.video/videos/watch/da5463ca-fbc7-4311-948a-356594d5c70a",
                "name": "Installing Linux Doesn't Need to Change. The Experience Does.",
                "nsfw": false,
                "tags": [
                    "linux"
                ],
                "uuid": "da5463ca-fbc7-4311-948a-356594d5c70a",
                "likes": 4,
                "score": 1,
                "views": 935,
                "isLive": false,
                "account": {
                    "id": 276396,
                    "url": "https://spectra.video/accounts/trafotin.com",
                    "host": "spectra.video",
                    "name": "trafotin.com",
                    "avatars": [
                        {
                            "url": "https://spectra.video/lazy-static/avatars/e664482e-4d2a-415d-b9bd-e8539d10037e.png",
                            "path": "/lazy-static/avatars/e664482e-4d2a-415d-b9bd-e8539d10037e.png",
                            "width": 48,
                            "fileUrl": "https://spectra.video/lazy-static/avatars/e664482e-4d2a-415d-b9bd-e8539d10037e.png",
                            "createdAt": "2024-12-05T21:22:15.958Z",
                            "updatedAt": "2024-12-05T21:22:15.958Z"
                        },
                        {
                            "url": "https://spectra.video/lazy-static/avatars/fdb8db5
…(truncated, see openapi.json for full schema)
```

### Videos

#### `GET /v1/video` — Video detail

**Parameters:**
- `video` (query, required, string) — Video id or uuid
- `instance` (query, optional, string) — PeerTube host (default framatube.org)

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/peertube-api/v1/video"
```

#### `GET /v1/video/captions` — Video captions

**Parameters:**
- `video` (query, required, string) — Video id or uuid
- `instance` (query, optional, string) — PeerTube host (default framatube.org)

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/peertube-api/v1/video/captions"
```

#### `GET /v1/video/comments` — Video comments

**Parameters:**
- `video` (query, required, string) — Video id or uuid
- `instance` (query, optional, string) — PeerTube host (default framatube.org)
- `limit` (query, optional, string) — Page size

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/peertube-api/v1/video/comments"
```

#### `GET /v1/videos` — Instance videos

**Parameters:**
- `instance` (query, optional, string) — PeerTube host (default framatube.org)
- `sort` (query, optional, string) — -trending|-publishedAt|-views
- `limit` (query, optional, string) — Page size

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/peertube-api/v1/videos"
```

**Response:**
```json
{
    "data": {
        "data": [
            {
                "id": 23435,
                "url": "https://tube.tchncs.de/videos/watch/3f6a4d43-4f6d-4f98-becd-b5aa629a0fe0",
                "name": "Learn JavaScript - Full Course for Beginners",
                "nsfw": false,
                "uuid": "3f6a4d43-4f6d-4f98-becd-b5aa629a0fe0",
                "likes": 1,
                "views": 559,
                "isLive": false,
                "account": {
                    "id": 20054,
                    "url": "https://tube.tchncs.de/accounts/designwithshoeb",
                    "host": "tube.tchncs.de",
                    "name": "designwithshoeb",
                    "avatars": [],
                    "displayName": "designwithshoeb"
                },
                "channel": {
                    "id": 1813,
                    "url": "https://tube.tchncs.de/video-channels/cybereak",
                    "host": "tube.tchncs.de",
                    "name": "cybereak",
                    "avatars": [],
                    "displayName": "Cybereak"
                },
                "isLocal": false,
                "licence": {
                    "id": null,
                    "label": "Unknown"
                },
                "privacy": {
                    "id": 1,
                    "label": "Public"
                },
                "viewers": 1,
                "category": {
                    "id": 13,
                    "label": "Education"
   
…(truncated, see openapi.json for full schema)
```

### Channels

#### `GET /v1/account` — Account detail

**Parameters:**
- `handle` (query, required, string) — Channel/account handle (name or name@instance)
- `instance` (query, optional, string) — PeerTube host (default framatube.org)

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/peertube-api/v1/account"
```

#### `GET /v1/account/videos` — Account videos

**Parameters:**
- `handle` (query, required, string) — Channel/account handle (name or name@instance)
- `instance` (query, optional, string) — PeerTube host (default framatube.org)
- `limit` (query, optional, string) — Page size

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/peertube-api/v1/account/videos"
```

#### `GET /v1/channel` — Channel detail

**Parameters:**
- `handle` (query, required, string) — Channel/account handle (name or name@instance)
- `instance` (query, optional, string) — PeerTube host (default framatube.org)

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/peertube-api/v1/channel"
```

#### `GET /v1/channel/videos` — Channel videos

**Parameters:**
- `handle` (query, required, string) — Channel/account handle (name or name@instance)
- `instance` (query, optional, string) — PeerTube host (default framatube.org)
- `limit` (query, optional, string) — Page size

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/peertube-api/v1/channel/videos"
```

### Instance

#### `GET /v1/categories` — Video categories

**Parameters:**
- `instance` (query, optional, string) — PeerTube host (default framatube.org)

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/peertube-api/v1/categories"
```

**Response:**
```json
{
    "data": {
        "1": "Music",
        "2": "Films",
        "3": "Vehicles",
        "4": "Art",
        "5": "Sports",
        "6": "Travels",
        "7": "Gaming",
        "8": "People",
        "9": "Comedy",
        "10": "Entertainment",
        "11": "News & Politics",
        "12": "How To",
        "13": "Education",
        "14": "Activism",
        "15": "Science & Technology",
        "16": "Animals",
        "17": "Kids",
        "18": "Food"
    },
    "meta": {
        "timestamp": "2026-06-02T08:32:51.495Z",
        "request_id": "c3e04b92-6323-4624-afa1-61e10991bd2e"
    },
    "status": "ok",
    "message": "Video categories",
    "success": true
}
```

#### `GET /v1/config` — Instance config

**Parameters:**
- `instance` (query, optional, string) — PeerTube host (default framatube.org)

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/peertube-api/v1/config"
```

**Response:**
```json
{
    "data": {
        "live": {
            "dvr": {
                "maxWindow": 3600
            },
            "rtmp": {
                "port": 1935
            },
            "enabled": true,
            "allowReplay": false,
            "maxDuration": -1,
            "transcoding": {
                "enabled": true,
                "profile": "default",
                "remoteRunners": {
                    "enabled": true
                },
                "availableProfiles": [
                    "default"
                ],
                "enabledResolutions": [
                    720
                ]
            },
            "maxUserLives": -1,
            "latencySetting": {
                "enabled": true
            },
            "maxInstanceLives": -1
        },
        "logo": {
            "file": {
                "size": {
                    "max": 8388608
                },
                "extensions": [
                    ".svg",
                    ".png",
                    ".jpeg",
                    ".jpg",
                    ".gif",
                    ".webp"
                ]
            }
        },
        "user": {
            "videoQuota": -1,
            "videoQuotaDaily": -1
        },
        "email": {
            "enabled": true
        },
        "theme": {
            "builtIn": [
                {
                    "name": "peertube-core-dark-brown"
                },
                {
                    "name": "peertu
…(truncated, see openapi.json for full schema)
```

#### `GET /v1/stats` — Server statistics

**Parameters:**
- `instance` (query, optional, string) — PeerTube host (default framatube.org)

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/peertube-api/v1/stats"
```

**Response:**
```json
{
    "data": {
        "totalUsers": 9,
        "totalAbuses": 7,
        "totalAdmins": 3,
        "totalVideos": 22831,
        "totalModerators": 1,
        "totalLocalVideos": 925,
        "videosRedundancy": [
            {
                "strategy": "manual",
                "totalSize": null,
                "totalUsed": 0,
                "totalVideos": 0,
                "totalVideoFiles": 0
            }
        ],
        "totalVideoComments": 6600,
        "totalLocalPlaylists": 13,
        "totalAbusesProcessed": 2,
        "totalLocalVideoViews": 988515,
        "totalDailyActiveUsers": 0,
        "totalInstanceFollowers": 101,
        "totalInstanceFollowing": 30,
        "totalWeeklyActiveUsers": 2,
        "totalLocalVideoChannels": 28,
        "totalLocalVideoComments": 2,
        "totalMonthlyActiveUsers": 2,
        "totalLocalVideoDownloads": 1641,
        "totalLocalVideoFilesSize": 467454694678,
        "totalRegistrationRequests": 0,
        "averageAbuseResponseTimeMs": null,
        "totalActivityPubMessagesErrors": 38,
        "totalActivityPubMessagesWaiting": 0,
        "totalActivityPubMessagesProcessed": 93926,
        "totalActivityPubMessagesSuccesses": 93888,
        "totalActivityPubFlagMessagesErrors": 0,
        "totalActivityPubLikeMessagesErrors": 0,
        "totalActivityPubUndoMessagesErrors": 0,
        "totalActivityPubViewMessagesErrors": 37,
        "totalLocalDailyActiveVideoChannels": 0,
        "totalRegistrationRequestsProces
…(truncated, see openapi.json for full schema)
```

### Meta

#### `GET /v1/meta` — Spec

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/peertube-api/v1/meta"
```

**Response:**
```json
{
    "data": {
        "auth": "none upstream; gateway requires x-api-key",
        "name": "PeerTube API",
        "note": "Search is federated across all PeerTube instances (SepiaSearch). Per-instance reads default to framatube.org; pass ?instance=<host>. Live, no cache; pagination via limit + start.",
        "source": "PeerTube REST API + SepiaSearch federated search",
        "endpoints": 15,
        "default_instance": "framatube.org",
        "federated_search": "https://sepiasearch.org"
    },
    "meta": {
        "timestamp": "2026-06-02T08:32:51.792Z",
        "request_id": "560828bc-04f8-4d79-929c-f73e39310e4a"
    },
    "status": "ok",
    "message": "Meta",
    "success": true
}
```


---
Marketplace page: https://www.oanor.com/api/peertube-api
OpenAPI spec: https://www.oanor.com/api/peertube-api/openapi.json
