Api
Val Town is a collaborative website to build and scale JavaScript apps.
Deploy APIs, crons, & store data – all from the browser, and deployed in milliseconds.
REST API wrapping the AllAnime GraphQL API — search anime, get info, episode lists, and streaming/m3u8 source links. All JSON output.
| Method | Path | Description |
|---|---|---|
GET | / | API docs (JSON) |
GET | /api/search?q=naruto | Search anime |
GET | /api/search?q=naruto&type=sub&page=1&limit=20 | Search with filters |
GET | /api/info/:id | Anime details by AllAnime ID |
GET | /api/episodes/:id | Sorted episode list (sub/dub/raw) |
GET | /api/sources/:id/:episode | Streaming sources (m3u8, mp4, embed) |
GET | /api/sources/:id/:episode?type=dub | Dubbed sources |
GET | /source | View source code |
1. Search → GET /api/search?q=boruto
2. Info → GET /api/info/vkD8H5e7HsG2jctw9
3. Episodes → GET /api/episodes/vkD8H5e7HsG2jctw9
4. Sources → GET /api/sources/vkD8H5e7HsG2jctw9/1
Rendering mermaid diagram...
{ "success": true, "data": { "id": "vkD8H5e7HsG2jctw9", "episode": "1", "translationType": "sub", "sources": [ { "name": "Default", "url": "https://...master.m3u8", "type": "hls" }, { "name": "S-mp4", "url": "https://...", "type": "embed" } ] } }
| Key | Description |
|---|---|
ALLANIME_IFRAME_HEAD | Override the episodeIframeHead URL for internal clock.json sources |