Skip to main content

Overview

The Video resource represents video files for anime themes. Each video contains metadata about resolution, source, encoding properties, and is linked to theme entries.

List Videos

GET
endpoint
/api/video
Retrieve a paginated list of videos.

Query Parameters

page[size]
integer
Number of results per page (default: 15, max: 100)
page[number]
integer
Page number to retrieve
include
string
Comma-separated list of relationships to include. Available includes:
  • animethemeentries - Theme entries this video belongs to
  • animethemeentries.animetheme - Anime themes
  • animethemeentries.animetheme.anime - Parent anime
  • animethemeentries.animetheme.song - Associated songs
  • audio - Audio track for this video
  • videoscript - Subtitle/script file
  • tracks - Playlist tracks using this video
filter[basename]
string
Filter by video basename
filter[resolution]
integer
Filter by resolution (e.g., 720, 1080)
filter[source]
string
Filter by source. Values: WEB, RAW, BD, DVD, VHS, LD, AT
filter[nc]
boolean
Filter by creditless (NC) status. Values: true, false
filter[subbed]
boolean
Filter by subbed status. Values: true, false
filter[lyrics]
boolean
Filter by lyrics status. Values: true, false
filter[uncen]
boolean
Filter by uncensored status. Values: true, false
filter[overlap]
string
Filter by overlap type. Values: None, Transition, Over
fields[video]
string
Comma-separated list of fields to return. Available fields:
  • video_id
  • basename
  • filename
  • path
  • size
  • mimetype
  • resolution
  • source
  • nc
  • subbed
  • lyrics
  • uncen
  • overlap
  • audio_id
  • link
  • tags
  • priority
sort
string
Sort by field. Prefix with - for descending order. Available: basename, resolution, source, created_at, updated_at
q
string
Full-text search query across video basenames and anime

Response

videos
array
Array of video objects
video_id
integer
Unique identifier
basename
string
Video filename without extension
filename
string
Full filename with extension
path
string
Full storage path
size
integer
File size in bytes
mimetype
string
MIME type (e.g., “video/webm”)
resolution
integer
Video resolution (e.g., 720, 1080)
source
string
Video source (WEB, RAW, BD, DVD, etc.)
nc
boolean
Creditless flag
subbed
boolean
Hardsubbed flag
lyrics
boolean
On-screen lyrics flag
uncen
boolean
Uncensored flag
overlap
string
Overlap type (None, Transition, Over)
audio_id
integer
Associated audio track ID
Direct streaming URL
tags
string
Concatenated tags (e.g., “NCBD1080”)
priority
integer
Quality priority score
created_at
string
ISO 8601 timestamp
updated_at
string
ISO 8601 timestamp

Example Request

curl "https://api.animethemes.moe/api/video?include=animethemeentries.animetheme.anime,audio&filter[resolution]=1080&page[size]=10"

Example Response

{
  "videos": [
    {
      "video_id": 1,
      "basename": "CowboyBebop-OP1",
      "filename": "CowboyBebop-OP1.webm",
      "path": "/videos/CowboyBebop-OP1.webm",
      "size": 15728640,
      "mimetype": "video/webm",
      "resolution": 1080,
      "source": "BD",
      "nc": true,
      "subbed": false,
      "lyrics": false,
      "uncen": false,
      "overlap": "None",
      "audio_id": 1,
      "link": "https://v.animethemes.moe/CowboyBebop-OP1.webm",
      "tags": "NCBD1080",
      "priority": 10,
      "created_at": "2024-01-15T12:00:00.000000Z",
      "updated_at": "2024-01-15T12:00:00.000000Z",
      "animethemeentries": [
        {
          "entry_id": 1,
          "version": 1,
          "animetheme": {
            "theme_id": 1,
            "type": "OP",
            "sequence": 1,
            "anime": {
              "anime_id": 1,
              "name": "Cowboy Bebop"
            }
          }
        }
      ],
      "audio": {
        "audio_id": 1,
        "basename": "CowboyBebop-OP1",
        "filename": "CowboyBebop-OP1.ogg"
      }
    }
  ],
  "links": {
    "first": "https://api.animethemes.moe/api/video?page[number]=1",
    "next": "https://api.animethemes.moe/api/video?page[number]=2"
  },
  "meta": {
    "current_page": 1,
    "per_page": 10
  }
}

Show Video

GET
endpoint
/api/video/:basename
Retrieve a single video by its basename.

Path Parameters

basename
string
required
The video basename (filename without extension)

Query Parameters

include
string
Same includes as list endpoint

Example Request

curl "https://api.animethemes.moe/api/video/CowboyBebop-OP1?include=animethemeentries.animetheme.anime,audio,videoscript"

Example Response

{
  "video": {
    "video_id": 1,
    "basename": "CowboyBebop-OP1",
    "filename": "CowboyBebop-OP1.webm",
    "path": "/videos/CowboyBebop-OP1.webm",
    "size": 15728640,
    "mimetype": "video/webm",
    "resolution": 1080,
    "source": "BD",
    "nc": true,
    "subbed": false,
    "lyrics": false,
    "uncen": false,
    "overlap": "None",
    "link": "https://v.animethemes.moe/CowboyBebop-OP1.webm",
    "tags": "NCBD1080",
    "priority": 10,
    "audio": {
      "audio_id": 1,
      "basename": "CowboyBebop-OP1",
      "link": "https://a.animethemes.moe/CowboyBebop-OP1.ogg"
    },
    "videoscript": {
      "script_id": 1,
      "path": "/scripts/CowboyBebop-OP1.ass"
    }
  }
}

Create Video

POST
endpoint
/api/video
Create a new video. Requires authentication.

Request Body

basename
string
required
Video basename (unique)
filename
string
required
Full filename with extension
path
string
required
Storage path
size
integer
required
File size in bytes
mimetype
string
required
MIME type
resolution
integer
Video resolution
source
string
Video source (WEB, RAW, BD, DVD, etc.)
nc
boolean
Creditless flag (default: false)
subbed
boolean
Hardsubbed flag (default: false)
lyrics
boolean
On-screen lyrics flag (default: false)
uncen
boolean
Uncensored flag (default: false)
overlap
string
Overlap type (None, Transition, Over)
audio_id
integer
Associated audio track ID

Update Video

PUT
endpoint
/api/video/:basename
Update an existing video. Requires authentication.

Request Body

Same fields as create endpoint (all optional).

Delete Video

DELETE
endpoint
/api/video/:basename
Soft delete a video. Requires authentication.

Restore Video

PATCH
endpoint
/restore/video/:basename
Restore a soft-deleted video. Requires authentication.

Force Delete Video

DELETE
endpoint
/forceDelete/video/:basename
Permanently delete a video. Requires authentication.

Build docs developers (and LLMs) love