Stars Forks Issues Pull Requests Last Commit License

Node.js Express Cheerio Vercel License Version Endpoints Anime Database

A complete RESTful API scraping real-time anime data from anikototv.to
Search, browse, filter, watch โ€” every endpoint returns live data with 5-minute smart caching.
Built for building anime websites, apps, and bots.

Table of Contents • Features • API Docs • Quick Start • Deployment • Contributing

--- > ## โš ๏ธ Disclaimer > > 1. This `API` does not store any files โ€” it only links to media hosted on 3rd party services. > 2. This `API` is explicitly made for **educational purposes only** and not for commercial usage. This repo will not be responsible for any misuse of it. > 3. All anime data, images, and content belong to their respective owners. This project is not affiliated with anikototv.to. --- ## ๐Ÿ“– Table of Contents - [Overview](#-overview) - [Features](#-features) - [Anime Data Source](#-anime-data-source) - [Tech Stack](#-tech-stack) - [Architecture](#-architecture) - [Project Structure](#-project-structure) - [Quick Start](#-quick-start) - [Configuration](#-configuration) - [API Endpoints](#-api-endpoints) - [API Response Schema](#-api-response-schema) - [Deployment](#-deployment) - [Available Scripts](#-available-scripts) - [Performance](#-performance) - [Changelog Highlights](#-changelog-highlights) - [Troubleshooting](#-troubleshooting) - [FAQ](#-faq) - [Roadmap](#-roadmap) - [Contributing](#-contributing) - [Acknowledgements](#-acknowledgements) - [License](#-license) - [Author](#-author) - [Star History](#-star-history) --- ## ๐ŸŒธ Overview **AniKatoAPI** is a serverless anime data API that scrapes and serves real-time information from **anikototv.to** โ€” including anime details, episode lists, streaming servers, search, filtering, rankings, and more โ€” all through a clean REST API with zero database setup. > ๐Ÿ’ก No database, no auth, no complex setup. Just deploy to Vercel and you have a production API. ### Why AniKatoAPI? - ๐ŸŽฌ **24 Endpoints** โ€” Complete coverage of anikototv.to data - ๐Ÿ” **Full-Text Search** โ€” Search anime by keyword with suggestions - ๐Ÿ“บ **Episode Lists** โ€” AJAX-loaded episode data with server info - ๐ŸŽฏ **Smart Filtering** โ€” Genre, type, status, rating, sort, season, year - ๐Ÿ† **Rankings** โ€” Top 10 (day/week/month), trending, most popular - ๐ŸŽฒ **Random Anime** โ€” Random anime discovery endpoint - โšก **Smart Caching** โ€” 5-minute TTL reduces source site load - ๐Ÿ”’ **CORS Enabled** โ€” Works from any frontend, no proxy needed - ๐Ÿš€ **Zero-Config Deploy** โ€” One click to Vercel, or run standalone with Express - ๐Ÿ“Š **Live Data** โ€” Every response is fresh from the actual website ### How It Works ```mermaid flowchart TD A["๐ŸŒ Client Request
(Browser / App / curl)"] --> B["๐Ÿ›ก๏ธ Vercel Edge / Express Server
CORS ยท Security Headers"] B --> C{"๐Ÿ’พ Cache Check
(In-Memory Map)"} C -- HIT --> D["โšก Return Cached Response
~200ms"] C -- MISS --> E["๐Ÿ” Cheerio Scraper"] E --> E1["Home Page"] E --> E2["Search Results"] E --> E3["Watch Pages"] E --> E4["AJAX Endpoints"] E --> E5["Filter Pages"] E1 & E2 & E3 & E4 & E5 --> F["Axios HTTP Fetch
Custom Headers ยท 15s Timeout"] F --> G["Parse HTML
Cheerio Selectors"] G --> H["Cache + Respond
JSON"] style A fill:#1e1e2e,stroke:#a78bfa,color:#f1f5f9 style B fill:#1e1e2e,stroke:#6366f1,color:#f1f5f9 style C fill:#1e1e2e,stroke:#f43f8e,color:#f1f5f9 style D fill:#1e1e2e,stroke:#22c55e,color:#f1f5f9 style E fill:#1e1e2e,stroke:#a855f7,color:#f1f5f9 style F fill:#1e1e2e,stroke:#eab308,color:#f1f5f9 style G fill:#1e1e2e,stroke:#06b6d4,color:#f1f5f9 style H fill:#1e1e2e,stroke:#22c55e,color:#f1f5f9 ``` --- ## โœจ Features
### โšก Core - **Real-time scraping** from anikototv.to - **Smart caching** with 5-minute TTL - **24 RESTful endpoints** covering all data - **AJAX episode loading** for accurate data - **Mapper API integration** for extra servers - **Graceful error handling** per endpoint ### ๐Ÿ” Data - **Keyword search** with pagination (`/api/search`) - **Search suggestions** for autocomplete (`/api/search/suggest`) - **Advanced filtering** โ€” genre, type, status, rating, sort, season, year - **AZ List** alphabetical browsing (`/api/az-list/:letter`) - **Random anime** discovery (`/api/random`) - **Top 10 rankings** day/week/month (`/api/top-ten`)
### ๐Ÿ“บ Streaming - **Watch page** โ€” full episode data with servers - **Stream info** โ€” video embed URLs via AJAX - **Server list** โ€” all available streaming servers - **Mapper API** โ€” gogoanime/anivibe server sources - **Episode navigation** โ€” prev/next episode data - **Next episode schedule** โ€” countdown timer data ### ๐Ÿ›ก๏ธ Reliability - **CORS enabled** โ€” works from any frontend - **Error responses** with descriptive messages - **Input validation** โ€” required params checked - **Timeout protection** โ€” 15s per request - **Multiple domains** โ€” fallback mirror support - **Zero dependencies on databases** โ€” pure scraping
### ๐ŸŒŸ Feature Highlights | Feature | Description | Status | |:---|:---|:---:| | ๐ŸŽฌ 24 API Endpoints | Complete coverage of anime data | โœ… | | ๐Ÿ” Full-Text Search | Keyword search with pagination | โœ… | | ๐Ÿ“บ Episode Lists | AJAX-loaded episode data | โœ… | | ๐ŸŽฏ Advanced Filtering | Genre, type, status, rating, sort | โœ… | | ๐Ÿ† Top 10 Rankings | Day/week/month leaderboards | โœ… | | ๐ŸŽฒ Random Anime | Random anime discovery | โœ… | | ๐Ÿ“ก Streaming Servers | Video embed URLs + mapper API | โœ… | | ๐Ÿ“‹ AZ List | A-Z alphabetical browsing | โœ… | | ๐Ÿ”„ Smart Caching | 5-min TTL, in-memory Map | โœ… | | ๐Ÿš€ One-Click Deploy | Vercel button deployment | โœ… | | ๐Ÿ—๏ธ Express Mode | Standalone server with `npm start` | โœ… | | ๐Ÿ“– AlisaReactionBot Style | Full JSDoc documentation | โœ… | --- ## ๐Ÿ—ž๏ธ Anime Data Source | Source | Domain | Status | Data | |:---|:---|:---|:---| | **AniKato** | `anikototv.to` | โœ… Active | Primary source | | **AniKato** | `anikoto.cz` | โœ… Active | Mirror domain | | **AniKato** | `anikoto.me` | โœ… Active | Mirror domain | | **AniKato** | `anikoto.net` | โœ… Active | Mirror domain | | **AniKato** | `anikoto.se` | โœ… Active | Mirror domain | ### Data Available | Category | Count | Source | |:---|:---|:---| | ๐ŸŽฌ Total Anime | 10,000+ | anikototv.to | | ๐Ÿ“บ Total Episodes | 100,000+ | AJAX endpoints | | ๐Ÿท๏ธ Genres | 43 | Genre pages | | ๐ŸŽญ Types | 6 | TV, Movie, OVA, ONA, Special, Music | | ๐Ÿ“Š Statuses | 3 | Airing, Finished, Not Yet Aired | --- ## ๐Ÿ› ๏ธ Tech Stack | Technology | Purpose | Version | Documentation | |:---|:---|:---|:---| | ๐ŸŸข [Node.js](https://nodejs.org/) | JavaScript runtime | >= 20 | [Docs](https://nodejs.org/docs/) | | โšก [Express](https://expressjs.com/) | HTTP server framework | 5.2 | [Docs](https://expressjs.com/en/5x/api.html) | | โ–ฒ [Vercel Functions](https://vercel.com/docs/functions) | Serverless deployment | โ€” | [Docs](https://vercel.com/docs/functions) | | ๐Ÿ” [Cheerio](https://cheerio.js.org/) | HTML parsing & scraping | 1.0 | [Docs](https://cheerio.js.org/docs/) | | ๐ŸŒ [Axios](https://axios-http.com/) | HTTP client | 1.11 | [Docs](https://axios-http.com/docs/intro) | | ๐Ÿ”ง [dotenv](https://github.com/motdotla/dotenv) | Environment variables | 17.2 | [Docs](https://github.com/motdotla/dotenv) | | ๐Ÿ”’ [cors](https://github.com/expressjs/cors) | CORS middleware | 2.8 | [Docs](https://github.com/expressjs/cors) | | ๐Ÿช [cookie-parser](https://github.com/expressjs/cookie-parser) | Cookie parsing | 1.4 | [Docs](https://github.com/expressjs/cookie-parser) | ### ๐Ÿ“ฆ Key Dependencies ```json { "express": "^5.2.0", // HTTP server "axios": "^1.11.0", // HTTP client for scraping "cheerio": "^1.0.0-rc.12", // HTML parsing "cors": "^2.8.5", // CORS middleware "dotenv": "^17.2.0", // Environment variables "cookie-parser": "^1.4.7" // Cookie parsing } ``` --- ## ๐Ÿ—๏ธ Architecture ### Request Flow | Stage | Component | Description | |:-----:|-----------|-------------| | 1 | **Client** | Browser, app, or `curl` sends request | | 2 | **Vercel Edge / Express** | Routes request, applies CORS + security headers | | 3 | **Cache Check** | In-memory Map with 5-min TTL โ€” hit = instant response | | 4 | **Scrape Source** | Axios fetches HTML from anikototv.to with custom headers | | 5 | **Parse HTML** | Cheerio extracts data using CSS selectors | | 6 | **Cache + Respond** | Store in cache, return JSON response | ### Caching Architecture ```mermaid flowchart TD A["๐Ÿ“ฅ Request"] --> B{"๐Ÿง  Memory Cache
(Map + TTL)"} B -- HIT --> C["โšก Return Cached
~200ms"] B -- MISS --> D["๐ŸŒ Fetch from
anikototv.to"] D --> E["๐Ÿ” Parse with
Cheerio"] E --> F["๐Ÿ’พ Cache Result
(5-min TTL)"] F --> G["๐Ÿ“ค Return Fresh"] style A fill:#1e1e2e,stroke:#a78bfa,color:#f1f5f9 style B fill:#1e1e2e,stroke:#f43f8e,color:#f1f5f9 style C fill:#1e1e2e,stroke:#22c55e,color:#f1f5f9 style D fill:#1e1e2e,stroke:#6366f1,color:#f1f5f9 style E fill:#1e1e2e,stroke:#06b6d4,color:#f1f5f9 style F fill:#1e1e2e,stroke:#a855f7,color:#f1f5f9 style G fill:#1e1e2e,stroke:#22c55e,color:#f1f5f9 ``` > ๐Ÿ’ก Serverless functions have read-only filesystems except `/tmp`. The cache uses in-memory `Map` which survives across warm invocations. --- ## ๐Ÿ“ Project Structure ``` AniKatoAPI/ โ”œโ”€โ”€ ๐Ÿ“‚ public/ # ๐ŸŒ Static files โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ index.html # ๐Ÿ“– API documentation page โ”‚ โ””โ”€โ”€ ๐Ÿ“„ 404.html # โŒ Custom 404 error page โ”‚ โ”œโ”€โ”€ ๐Ÿ“‚ src/ # โš™๏ธ Core logic โ”‚ โ”œโ”€โ”€ ๐Ÿ“‚ configs/ # ๐Ÿ”ง Configuration files โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ dataUrl.js # ๐ŸŒ URL patterns for anikototv.to โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ header.config.js # ๐Ÿ“‹ Request headers โ”‚ โ”‚ โ””โ”€โ”€ ๐Ÿ“„ ids.config.js # ๐Ÿท๏ธ Genre/Type/Status/Rating ID mappings โ”‚ โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“‚ controllers/ # ๐ŸŽฎ Route handlers (22 files) โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ homeInfo.controller.js โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ animeInfo.controller.js โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ search.controller.js โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ episodeList.controller.js โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ episodeListAjax.controller.js โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ streamInfo.controller.js โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ filter.controller.js โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ watchPage.controller.js โ”‚ โ”‚ โ””โ”€โ”€ ๐Ÿ“„ ... (14 more) โ”‚ โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“‚ extractors/ # ๐Ÿ” HTML scrapers (22 files) โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ homeInfo.extractor.js # ๐Ÿ  Home page data โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ search.extractor.js # ๐Ÿ” Search results โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ animeInfo.extractor.js # ๐Ÿ“บ Anime details โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ streamInfo.extractor.js # ๐Ÿ“ก Streaming servers โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ filter.extractor.js # ๐ŸŽฏ Filtered results โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ watchPage.extractor.js # โ–ถ๏ธ Watch page data โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ episodeList.extractor.js # ๐Ÿ“‹ Episode lists โ”‚ โ”‚ โ””โ”€โ”€ ๐Ÿ“„ ... (15 more) โ”‚ โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“‚ helper/ # ๐Ÿ› ๏ธ Utility functions โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ cache.helper.js # ๐Ÿ’พ In-memory caching โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ countPages.helper.js # ๐Ÿ“„ Pagination counter โ”‚ โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ extractPages.helper.js # ๐Ÿ“ƒ Page fetcher โ”‚ โ”‚ โ””โ”€โ”€ ๐Ÿ“„ formatTitle.helper.js # ๐Ÿ”ค Title formatter โ”‚ โ”‚ โ”‚ โ””โ”€โ”€ ๐Ÿ“‚ routes/ # ๐Ÿ›ค๏ธ Express routes โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ apiRoutes.js # ๐ŸŒ Main API routes (24 endpoints) โ”‚ โ””โ”€โ”€ ๐Ÿ“„ category.route.js # ๐Ÿท๏ธ Category routes โ”‚ โ”œโ”€โ”€ ๐Ÿ“„ server.js # ๐Ÿš€ Express server entry point โ”œโ”€โ”€ ๐Ÿ“„ package.json # ๐Ÿ“ฆ Dependencies & scripts โ”œโ”€โ”€ ๐Ÿ“„ vercel.json # โ–ฒ Vercel routing & headers config โ”œโ”€โ”€ ๐Ÿ“„ CHANGELOG.md # ๐Ÿ“ Version history โ”œโ”€โ”€ ๐Ÿ“„ LICENSE # ๐Ÿ“œ MIT License โ””โ”€โ”€ ๐Ÿ“„ README.md # ๐Ÿ“– This file ``` --- ## ๐Ÿš€ Quick Start ### Prerequisites | Requirement | Minimum | Recommended | |:---|:---|:---| | ๐Ÿ“ฆ Node.js | 20.x | 20.x LTS | | ๐Ÿ“ฆ npm | 9.0+ | 10.x | | ๐Ÿ’ป OS | Windows, macOS, Linux | Any | ### ๐Ÿ”ง Installation ```bash # 1๏ธโƒฃ Clone the repository git clone https://github.com/Shineii86/AniKatoAPI.git cd AniKatoAPI # 2๏ธโƒฃ Install dependencies npm install # 3๏ธโƒฃ Start development server npm run dev ``` > ๐ŸŒ Open [http://localhost:4444](http://localhost:4444) in your browser. ### ๐Ÿ—๏ธ Build for Production ```bash # Start production server npm start ``` ### ๐Ÿณ Alternative Package Managers ```bash # Using yarn yarn install yarn dev # Using pnpm pnpm install pnpm dev # Using bun bun install bun dev ``` --- ## โš™๏ธ Configuration ### Environment Variables | Variable | Default | Description | |:---|:---|:---| | `PORT` | `4444` | Server port (Express mode only) | | `ALLOWED_ORIGINS` | `*` | Comma-separated allowed origins | ### Vercel Configuration The `vercel.json` file handles: - **Builds** โ€” Maps `server.js` to `@vercel/node` - **Routes** โ€” All requests forwarded to Express - **Headers** โ€” CORS `Access-Control-Allow-Origin: *` --- ## ๐Ÿ“ก API Endpoints ### Base URL ``` https://anikato.vercel.app/api ``` --- ### `GET /api/` Home page data โ€” spotlight carousel, trending anime, top airing, and genre list. ```bash curl "https://anikato.vercel.app/api/" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/"); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "spotlights": [ { "slug": "one-piece-odmau", "poster": "https://image.tmdb.org/t/p/original/a6ptrTUH1c5OdWanjyYtAkOuYD0.jpg", "title": "One Piece", "japaneseTitle": "One Piece", "description": "", "rating": "PG-13", "quality": "HD", "sub": 0, "dub": 0, "date": "Oct 20, 1999 to ?" } ], "trending": [ { "slug": "one-piece-odmau/ep-1165", "poster": "https://cdn.anipixcdn.co/thumbnail/f899139df5e1059396431415e770c6dd.jpg", "title": "One Piece", "japaneseTitle": "One Piece", "sub": 1165, "dub": 1133, "total": 0, "type": "TV" } ], "topAiring": [ { "slug": "one-piece-odmau", "poster": "https://cdn.anipixcdn.co/thumbnail/f899139df5e1059396431415e770c6dd.jpg", "title": "One Piece", "sub": 1165, "dub": 1133, "type": "" } ], "genres": [ "Action", "Adventure", "Comedy", "Drama", "Fantasy", "Horror", "Isekai", "Mecha", "Mystery", "Romance", "Sci-Fi", "Slice of Life", "Sports", "Supernatural", "Thriller" ] } } ```
--- ### `GET /api/search` Search anime by keyword with pagination. | Param | Type | Default | Description | |:---|:---|:---|:---| | `keyword` | `string` | **required** | Search query | | `page` | `number` | `1` | Page number | ```bash curl "https://anikato.vercel.app/api/search?keyword=one+piece" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/search", { params: { keyword: "one piece", page: 1 } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "totalPages": 11, "data": [ { "slug": "one-piece-episode-of-luffy-hand-island-adventure-br7lf/ep-1", "animeId": "769", "poster": "https://cdn.anipixcdn.co/thumbnail/4f16c818875d9fcb6867c7bdc89be7eb.jpg", "title": "One Piece: Episode of Luffy - Hand Island Adventure", "japaneseTitle": "One Piece: Episode of Luffy - Hand Island no Bouken", "sub": 1, "dub": 0, "total": 0, "type": "Special", "rating": "7.68", "genres": ["Action", "Adventure", "Fantasy", "Comedy", "Shounen", "Super Power"] }, { "slug": "one-piece-odmau/ep-1", "animeId": "1642", "poster": "https://cdn.anipixcdn.co/thumbnail/f899139df5e1059396431415e770c6dd.jpg", "title": "One Piece", "japaneseTitle": "One Piece", "sub": 1165, "dub": 1133, "total": 0, "type": "TV", "rating": "8.73", "genres": ["Action", "Adventure", "Fantasy", "Comedy", "Shounen", "Super Power", "Drama"] } ] } } ```
--- ### `GET /api/search/suggest` Search suggestions for autocomplete (returns max 10 results). | Param | Type | Default | Description | |:---|:---|:---|:---| | `keyword` | `string` | **required** | Search query | ```bash curl "https://anikato.vercel.app/api/search/suggest?keyword=one+piece" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/search/suggest", { params: { keyword: "one piece" } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": [ { "slug": "one-piece-odmau/ep-1", "poster": "https://cdn.anipixcdn.co/thumbnail/f899139df5e1059396431415e770c6dd.jpg", "title": "One Piece", "japaneseTitle": "One Piece", "type": "TV" } ] } ```
--- ### `GET /api/info` Detailed anime information including synopsis, genres, studios, and more. | Param | Type | Default | Description | |:---|:---|:---|:---| | `id` | `string` | **required** | Anime slug | ```bash curl "https://anikato.vercel.app/api/info?id=one-piece-odmau" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/info", { params: { id: "one-piece-odmau" } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "slug": "one-piece-odmau", "animeId": 1642, "title": "One Piece", "japaneseTitle": "One Piece", "altNames": "", "poster": "https://cdn.anipixcdn.co/thumbnail/f899139df5e1059396431415e770c6dd.jpg", "backgroundImage": "...", "synopsis": "Gol D. Roger was known as the Pirate King...", "type": "TV", "premiered": "Fall 1999", "aired": "Oct 20, 1999", "status": "Currently Airing", "malScore": "8.73", "duration": "24 min", "episodes": "Unknown", "studios": ["Toei Animation"], "producers": [], "genres": ["Action", "Adventure", "Fantasy", "Comedy", "Shounen", "Super Power", "Drama"], "rating": "8.73", "reviewCount": "0" } } ```
--- ### `GET /api/watch` Complete watch page data โ€” anime info, episode list, servers, trending, and recommended. | Param | Type | Default | Description | |:---|:---|:---|:---| | `slug` | `string` | **required** | Anime slug | | `ep` | `number` | **required** | Episode number | ```bash curl "https://anikato.vercel.app/api/watch?slug=one-piece-odmau&ep=1165" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/watch", { params: { slug: "one-piece-odmau", ep: 1165 } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "slug": "one-piece-odmau", "animeId": 1642, "animeUrl": "/watch/one-piece-odmau", "title": "One Piece", "japaneseTitle": "One Piece", "episodeNumber": 1165, "synopsis": "Gol D. Roger was known as the Pirate King...", "type": "TV", "status": "Currently Airing", "malScore": "8.73", "duration": "24 min", "episodes": "Unknown", "studios": ["Toei Animation"], "genres": ["Action", "Adventure", "Fantasy"], "rating": "8.73", "poster": "https://cdn.anipixcdn.co/thumbnail/f899139df5e1059396431415e770c6dd.jpg", "backgroundImage": "...", "nextEpisodeDate": "", "nextEpisodeTimestamp": 0, "servers": [ { "linkId": "...", "epId": "...", "cmId": "...", "svId": "...", "name": "Vidstreaming", "type": "sub" } ], "trending": [...], "recommended": [...] } } ```
--- ### `GET /api/episodes/:id` Episode list for an anime (loaded via AJAX for accuracy). | Param | Type | Default | Description | |:---|:---|:---|:---| | `id` | `string` | **required** | Anime slug | ```bash curl "https://anikato.vercel.app/api/episodes/one-piece-odmau" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/episodes/one-piece-odmau"); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "animeId": 1642, "slug": "one-piece-odmau", "totalEpisodes": 0, "episodes": [] } } ```
--- ### `GET /api/episodes-ajax/:id` Raw AJAX episode list response from the source site. Returns HTML that contains episode buttons with `data-ep-id`, `data-num`, and `data-slug` attributes. | Param | Type | Default | Description | |:---|:---|:---|:---| | `id` | `number` | **required** | Anime ID | ```bash curl "https://anikato.vercel.app/api/episodes-ajax/1642" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/episodes-ajax/1642"); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": "......" } ``` > ๐Ÿ’ก This endpoint returns raw HTML from the AJAX call. Use `/api/episodes/:slug` for parsed episode data instead.
--- ### `GET /api/stream` Streaming server info โ€” extracts video embed URL and skip data via AJAX. Requires a `linkId` from the server buttons on the watch page. | Param | Type | Default | Description | |:---|:---|:---|:---| | `id` | `string` | **required** | Link ID from server buttons (`data-link-id`) | ```bash curl "https://anikato.vercel.app/api/stream?id={linkId}" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/stream", { params: { id: "yourLinkId" } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "linkId": "abc123", "url": "https://embed.s3t.stream/embed/xyz", "skipData": { "intro": { "start": 0, "end": 90 }, "outro": { "start": 1320, "end": 1410 } } } } ``` > ๐Ÿ’ก The `skipData` object contains intro/outro timestamps for the video player to auto-skip.
--- ### `GET /api/servers` Server list for an episode โ€” returns available streaming servers with their names and types. | Param | Type | Default | Description | |:---|:---|:---|:---| | `ids` | `string` | **required** | Episode IDs | ```bash curl "https://anikato.vercel.app/api/servers?ids={episodeIds}" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/servers", { params: { ids: "yourEpisodeIds" } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "sub": [ { "server_id": 1, "server_name": "Vidstreaming", "type": "sub" }, { "server_id": 2, "server_name": "Gogocdn", "type": "sub" } ], "dub": [ { "server_id": 3, "server_name": "Vidstreaming", "type": "dub" } ] } } ```
--- ### `GET /api/mapper-servers` Mapper API โ€” fetches additional streaming servers from gogoanime/anivibe via the nekostream mapper service. Returns sub/dub server URLs for each provider. | Param | Type | Default | Description | |:---|:---|:---|:---| | `malId` | `number` | **required** | MyAnimeList ID | | `slug` | `string` | **required** | Anime slug | | `timestamp` | `number` | **required** | Current timestamp | ```bash curl "https://anikato.vercel.app/api/mapper-servers?malId=21&slug=one-piece×tamp=1717900000" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/mapper-servers", { params: { malId: 21, slug: "one-piece", timestamp: 1717900000 } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": [ { "provider": "gogoanime", "type": "sub", "url": "https://embtaku.pro/embed?id=...", "download": "https://gogodl.net/download?id=..." }, { "provider": "gogoanime", "type": "dub", "url": "https://embtaku.pro/embed?id=...", "download": "https://gogodl.net/download?id=..." } ] } ```
--- ### `GET /api/top-ten` Top 10 anime rankings for day, week, and month. ```bash curl "https://anikato.vercel.app/api/top-ten" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/top-ten"); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "today": [ { "slug": "one-piece-odmau", "rank": 1, "name": "One Piece", "poster": "...", "sub": 1165, "dub": 1133, "type": "" }, { "slug": "that-time-i-got-reincarnated-as-a-slime-season-4-0u851", "rank": 2, "name": "That Time I Got Reincarnated as a Slime Season 4", "sub": 9, "dub": 7 }, { "slug": "wistoria-wand-and-sword-season-2-dua04", "rank": 3, "name": "Wistoria: Wand and Sword Season 2", "sub": 9, "dub": 7 } ], "week": [ { "slug": "one-piece-odmau", "rank": 1, "name": "One Piece", "sub": 1165, "dub": 1133 }, { "slug": "re-zero-starting-life-in-another-world-season-4-4hk9h", "rank": 2, "name": "Re:ZERO Season 4", "sub": 9, "dub": 9 }, { "slug": "that-time-i-got-reincarnated-as-a-slime-season-4-0u851", "rank": 3, "name": "Tensei Slime Season 4", "sub": 9, "dub": 7 } ], "month": [ { "slug": "one-piece-odmau", "rank": 1, "name": "One Piece", "sub": 1165, "dub": 1133 }, { "slug": "that-time-i-got-reincarnated-as-a-slime-season-4-0u851", "rank": 2, "name": "Tensei Slime Season 4", "sub": 9, "dub": 7 }, { "slug": "wistoria-wand-and-sword-season-2-dua04", "rank": 3, "name": "Wistoria Season 2", "sub": 9, "dub": 7 } ] } } ```
--- ### `GET /api/spotlight` Spotlight carousel data โ€” featured anime with posters, descriptions, and ratings. ```bash curl "https://anikato.vercel.app/api/spotlight" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/spotlight"); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": [ { "slug": "one-piece-odmau", "poster": "https://image.tmdb.org/t/p/original/a6ptrTUH1c5OdWanjyYtAkOuYD0.jpg", "title": "One Piece", "japaneseTitle": "One Piece", "description": "", "rating": "PG-13", "quality": "HD", "sub": 0, "dub": 0, "date": "Oct 20, 1999 to ?" }, { "slug": "that-time-i-got-reincarnated-as-a-slime-season-4-0u851", "poster": "https://cdn.anipixcdn.co/background/14c2f4ab3ad95f50_1778862809.jpg", "title": "That Time I Got Reincarnated as a Slime Season 4", "japaneseTitle": "Tensei shitara Slime Datta Ken 4th Season", "rating": "PG-13", "quality": "HD" } ] } ```
--- ### `GET /api/trending` Trending anime โ€” recently updated episodes with sub/dub counts. ```bash curl "https://anikato.vercel.app/api/trending" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/trending"); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": [ { "slug": "one-piece-odmau/ep-1165", "poster": "https://cdn.anipixcdn.co/thumbnail/f899139df5e1059396431415e770c6dd.jpg", "title": "One Piece", "japaneseTitle": "One Piece", "sub": 1165, "dub": 1133, "total": 0, "type": "TV" }, { "slug": "wistoria-wand-and-sword-season-2-dua04/ep-9", "poster": "https://cdn.anipixcdn.co/thumbnail/4739d8dbd05dddb73604f6240b83ea68.jpg", "title": "Wistoria: Wand and Sword Season 2", "sub": 9, "dub": 7, "total": 12, "type": "TV" } ] } ```
--- ### `GET /api/random` Random anime โ€” follows redirect to a random anime page and returns full info. ```bash curl "https://anikato.vercel.app/api/random" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/random"); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "slug": "https://anikototv.to/random", "animeId": 998, "title": "Saint Young Men (Movie)", "japaneseTitle": "Saint Oniisan (Movie)", "poster": "https://cdn.anipixcdn.co/thumbnail/6081594975a764c8e3a691fa2b3a321d.jpg", "type": "Movie", "synopsis": "What if Jesus and Buddha were living on Earth in modern times?", "rating": "7.86 7.86 /10", "genres": ["Comedy", "Slice of Life", "Seinen"], "url": "https://anikototv.to/random" } } ```
--- ### `GET /api/most-popular` Most popular anime with pagination โ€” sorted by view count. | Param | Type | Default | Description | |:---|:---|:---|:---| | `page` | `number` | `1` | Page number | ```bash curl "https://anikato.vercel.app/api/most-popular?page=1" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/most-popular", { params: { page: 1 } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "totalPages": 293, "data": [ { "slug": "solo-leveling-season-2-arise-from-the-shadow-3eukp/ep-1", "animeId": "7457", "poster": "https://cdn.anipixcdn.co/thumbnail/4b5ed938de41e4ff532c02c27dfd143a.jpg", "title": "Solo Leveling Season 2: Arise from the Shadow", "sub": 13, "dub": 13, "total": 13, "type": "TV", "rating": "8.87" }, { "slug": "one-piece-odmau/ep-1", "animeId": "1642", "title": "One Piece", "sub": 1165, "dub": 1133, "type": "TV", "rating": "8.73" }, { "slug": "dandadan-lzcmw/ep-1", "animeId": "4", "title": "Dandadan", "sub": 12, "dub": 12, "type": "TV", "rating": "8.75" } ] } } ```
--- ### `GET /api/new-release` Newly released anime with pagination. | Param | Type | Default | Description | |:---|:---|:---|:---| | `page` | `number` | `1` | Page number | ```bash curl "https://anikato.vercel.app/api/new-release?page=1" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/new-release", { params: { page: 1 } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "totalPages": 50, "data": [ { "slug": "given-movie-2024-xt2kv/ep-1", "animeId": "7386", "poster": "https://cdn.anipixcdn.co/thumbnail/b4067f8aa165e643477e6c2eaf8e978c.jpg", "title": "Given Movie (2024)", "japaneseTitle": "Given Movie (2024)", "sub": 1, "dub": 1, "total": 1, "type": "Movie", "rating": "8" }, { "slug": "jujutsu-kaisen-hidden-inventory-premature-death-wjoxj/ep-1", "animeId": "8584", "title": "Jujutsu Kaisen: Hidden Inventory/Premature Death", "sub": 1, "dub": 1, "total": 1, "type": "Movie", "rating": "8.1" } ] } } ```
--- ### `GET /api/trending-sidebar` Sidebar data โ€” trending (day/week/month) + latest episodes for widget display. ```bash curl "https://anikato.vercel.app/api/trending-sidebar" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/trending-sidebar"); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "day": [ { "slug": "one-piece-odmau", "rank": 1, "name": "One Piece", "sub": 1165, "dub": 1133 }, { "slug": "that-time-i-got-reincarnated-as-a-slime-season-4-0u851", "rank": 2, "name": "Tensei Slime S4", "sub": 9, "dub": 7 } ], "week": [...], "month": [...], "latestEpisodes": [ { "slug": "one-piece-odmau/ep-1165", "title": "One Piece", "sub": 1165, "dub": 1133, "type": "TV" } ] } } ```
--- ### `GET /api/newly-added` Recently added anime with pagination. | Param | Type | Default | Description | |:---|:---|:---|:---| | `page` | `number` | `1` | Page number | ```bash curl "https://anikato.vercel.app/api/newly-added?page=1" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/newly-added", { params: { page: 1 } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "totalPages": 150, "data": [ { "slug": "one-piece-odmau/ep-1", "animeId": "1642", "poster": "https://cdn.anipixcdn.co/thumbnail/f899139df5e1059396431415e770c6dd.jpg", "title": "One Piece", "sub": 1165, "dub": 1133, "total": 0, "type": "TV", "rating": "8.73" }, { "slug": "wistoria-wand-and-sword-season-2-dua04/ep-1", "animeId": "8737", "title": "Wistoria: Wand and Sword Season 2", "sub": 9, "dub": 7, "total": 12, "type": "TV", "rating": "8.12" } ] } } ```
--- ### `GET /api/schedule` Anime schedule for a specific date. Returns an array of anime airing on that date with episode info, or an empty array if no schedule data is available. | Param | Type | Default | Description | |:---|:---|:---|:---| | `date` | `string` | **required** | Date in `YYYY-MM-DD` format | ```bash curl "https://anikato.vercel.app/api/schedule?date=2026-06-08" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/schedule", { params: { date: "2026-06-08" } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": [ { "slug": "anime-slug-xyz/ep-1", "title": "Anime Title", "episode": "Ep 1", "japaneseTitle": "Japanese Title", "type": "TV", "subs": 1, "dubs": 0 } ] } ``` > ๐Ÿ’ก If no anime are scheduled for the given date, the response will be `{"success": true, "results": []}`.
--- ### `GET /api/filter` Advanced filtering with multiple criteria. Requires `keyword` parameter (use empty string for unfiltered). | Param | Type | Default | Description | |:---|:---|:---|:---| | `keyword` | `string` | `""` | Search keyword (required by site) | | `genre` | `string` | โ€” | Comma-separated genre slugs | | `type` | `string` | โ€” | Comma-separated types | | `status` | `string` | โ€” | Comma-separated statuses | | `language` | `string` | โ€” | `sub`, `dub` | | `rating` | `string` | โ€” | `g`, `pg`, `pg-13`, `r`, `r+`, `rx` | | `sort` | `string` | โ€” | `latest-updated`, `score`, `name-az`, etc. | | `season` | `string` | โ€” | `spring`, `summer`, `fall`, `winter` | | `year` | `number` | โ€” | e.g. `2026` | | `page` | `number` | `1` | Page number | **Available Genres:** `action`, `adventure`, `cars`, `comedy`, `dementia`, `demons`, `drama`, `ecchi`, `fantasy`, `game`, `harem`, `historical`, `horror`, `isekai`, `josei`, `kids`, `magic`, `mahou-shoujo`, `martial-arts`, `mecha`, `military`, `music`, `mystery`, `parody`, `police`, `psychological`, `romance`, `samurai`, `school`, `sci-fi`, `seinen`, `shoujo`, `shoujo-ai`, `shounen`, `shounen-ai`, `slice-of-life`, `space`, `sports`, `super-power`, `supernatural`, `thriller`, `unknown`, `vampire` **Available Types:** `movie`, `music`, `ona`, `ova`, `special`, `tv` **Available Statuses:** `currently-airing`, `finished-airing`, `not-yet-aired` **Available Sorts:** `default`, `latest-updated`, `latest-added`, `score`, `name-az`, `release-date`, `most-viewed`, `number_of_episodes` ```bash curl "https://anikato.vercel.app/api/filter?genre=action&type=tv&page=1" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/filter", { params: { genre: "action", type: "tv", page: 1 } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "totalPages": 89, "data": [ { "slug": "one-piece-odmau/ep-1", "animeId": "1642", "poster": "https://cdn.anipixcdn.co/thumbnail/f899139df5e1059396431415e770c6dd.jpg", "title": "One Piece", "sub": 1165, "dub": 1133, "total": 0, "type": "TV", "rating": "8.73" } ] } } ```
--- ### `GET /api/genre/:name` Browse anime by genre. | Param | Type | Default | Description | |:---|:---|:---|:---| | `name` | `string` | **required** | Genre slug (e.g. `action`, `comedy`) | | `page` | `number` | `1` | Page number | ```bash curl "https://anikato.vercel.app/api/genre/action?page=1" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/genre/action", { params: { page: 1 } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "totalPages": 89, "data": [ { "slug": "one-piece-odmau/ep-1", "animeId": "1642", "poster": "https://cdn.anipixcdn.co/thumbnail/f899139df5e1059396431415e770c6dd.jpg", "title": "One Piece", "sub": 1165, "dub": 1133, "total": 0, "type": "TV", "rating": "8.73" }, { "slug": "solo-leveling-season-2-arise-from-the-shadow-3eukp/ep-1", "animeId": "7457", "title": "Solo Leveling Season 2: Arise from the Shadow", "sub": 13, "dub": 13, "total": 13, "type": "TV", "rating": "8.87" } ] } } ```
--- ### `GET /api/type/:name` Browse anime by type. | Param | Type | Default | Description | |:---|:---|:---|:---| | `name` | `string` | **required** | Type slug (`tv`, `movie`, `ova`, `ona`, `special`) | | `page` | `number` | `1` | Page number | ```bash curl "https://anikato.vercel.app/api/type/movie?page=1" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/type/movie", { params: { page: 1 } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "totalPages": 44, "data": [ { "slug": "given-movie-2024-xt2kv/ep-1", "animeId": "7386", "poster": "https://cdn.anipixcdn.co/thumbnail/b4067f8aa165e643477e6c2eaf8e978c.jpg", "title": "Given Movie (2024)", "japaneseTitle": "Given Movie (2024)", "sub": 1, "dub": 1, "total": 1, "type": "Movie", "rating": "8" }, { "slug": "jujutsu-kaisen-hidden-inventory-premature-death-wjoxj/ep-1", "animeId": "8584", "title": "Jujutsu Kaisen: Hidden Inventory/Premature Death", "sub": 1, "dub": 1, "total": 1, "type": "Movie", "rating": "8.1" } ] } } ```
--- ### `GET /api/status/:name` Browse anime by airing status. | Param | Type | Default | Description | |:---|:---|:---|:---| | `name` | `string` | **required** | Status slug | | `page` | `number` | `1` | Page number | ```bash curl "https://anikato.vercel.app/api/status/currently-airing?page=1" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/status/currently-airing", { params: { page: 1 } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "totalPages": 15, "data": [ { "slug": "one-piece-odmau/ep-1", "animeId": "1642", "poster": "https://cdn.anipixcdn.co/thumbnail/f899139df5e1059396431415e770c6dd.jpg", "title": "One Piece", "sub": 1165, "dub": 1133, "total": 0, "type": "TV", "rating": "8.73" }, { "slug": "daemons-of-the-shadow-realm-hxj32/ep-1", "animeId": "8712", "title": "Daemons of the Shadow Realm", "sub": 10, "dub": 8, "total": 24, "type": "TV", "rating": "9.58" } ] } } ```
--- ### `GET /api/az-list/:letter` Browse anime alphabetically. | Param | Type | Default | Description | |:---|:---|:---|:---| | `letter` | `string` | **required** | Letter (`a`-`z`, `0-9`, `other`, `all`) | | `page` | `number` | `1` | Page number | ```bash curl "https://anikato.vercel.app/api/az-list/a?page=1" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/az-list/a", { params: { page: 1 } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": { "totalPages": 19, "letter": "a", "data": [ { "slug": "a-silent-voice-fghla/ep-1", "poster": "https://cdn.anipixcdn.co/thumbnail/6512bd43d9caa6e02c990b0a82652dca.jpg", "title": "A Silent Voice", "japaneseTitle": "Koe no Katachi", "sub": 1, "dub": 1, "total": 0, "type": "Movie", "rating": "" }, { "slug": "attack-on-titan-bgaoa/ep-1", "title": "Attack on Titan", "japaneseTitle": "Shingeki no Kyojin", "sub": 25, "dub": 25, "total": 25, "type": "TV", "rating": "8.52" } ] } } ```
--- ### `GET /api/suggestions` Search suggestions for autocomplete (returns max 10 results). | Param | Type | Default | Description | |:---|:---|:---|:---| | `keyword` | `string` | **required** | Search query | ```bash curl "https://anikato.vercel.app/api/suggestions?keyword=naruto" ``` ```javascript import axios from "axios"; const resp = await axios.get("https://anikato.vercel.app/api/suggestions", { params: { keyword: "naruto" } }); console.log(resp.data); ```
๐Ÿ“„ Example Response ```json { "success": true, "results": [ { "slug": "naruto-shippuden-c8gov/ep-1", "poster": "https://cdn.anipixcdn.co/thumbnail/82cec96096d4281b7c95cd7e74623496.jpg", "title": "Naruto: Shippuden", "japaneseTitle": "Naruto: Shippuuden", "type": "TV", "sub": 500, "dub": 500 }, { "slug": "the-last-naruto-the-movie-whib1/ep-1", "title": "The Last: Naruto the Movie", "type": "Movie", "sub": 1, "dub": 1 } ] } ```
--- ## ๐Ÿ“‹ API Response Schema ### Success Response ```json { "success": true, "results": { ... } } ``` ### Error Response ```json { "success": false, "message": "Error description" } ``` ### Anime Item Object | Field | Type | Description | Example | |:---|:---|:---|:---| | `slug` | `string` | URL-safe identifier | `"one-piece-odmau"` | | `animeId` | `number/string` | Internal ID | `1642` | | `poster` | `string` | Thumbnail URL | `"https://cdn.anipixcdn.co/..."` | | `title` | `string` | English title | `"One Piece"` | | `japaneseTitle` | `string` | Japanese title | `"One Piece"` | | `sub` | `number` | Subbed episodes count | `1165` | | `dub` | `number` | Dubbed episodes count | `1133` | | `total` | `number` | Total episodes | `0` | | `type` | `string` | Anime type | `"TV"` | | `rating` | `string` | MAL rating | `"8.73"` | ### Spotlight Object | Field | Type | Description | Example | |:---|:---|:---|:---| | `slug` | `string` | URL-safe identifier | `"one-piece-odmau"` | | `poster` | `string` | Background image URL | `"https://..."` | | `title` | `string` | English title | `"One Piece"` | | `japaneseTitle` | `string` | Japanese title | `"One Piece"` | | `description` | `string` | Synopsis | `"Gol D. Roger..."` | | `rating` | `string` | Content rating | `"PG-13"` | | `quality` | `string` | Video quality | `"HD"` | | `sub` | `number` | Sub count | `0` | | `dub` | `number` | Dub count | `0` | | `date` | `string` | Air date range | `"Oct 20, 1999 to ?"` | ### Ranking Object | Field | Type | Description | Example | |:---|:---|:---|:---| | `slug` | `string` | URL-safe identifier | `"one-piece-odmau"` | | `rank` | `number` | Position (1-10) | `1` | | `name` | `string` | Anime title | `"One Piece"` | | `poster` | `string` | Thumbnail URL | `"https://..."` | | `sub` | `number` | Sub count | `1165` | | `dub` | `number` | Dub count | `1133` | | `type` | `string` | Anime type | `"TV"` | --- ## ๐ŸŒ Deployment ### โ–ฒ Vercel (Recommended) [![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https://github.com/Shineii86/AniKatoAPI) 1. Click the button above (or import manually on vercel.com) 2. Vercel auto-detects the project โ€” **no config needed** 3. Your API is live! ๐ŸŽ‰ ```bash # Or use Vercel CLI npx vercel --prod ``` ### ๐Ÿ–ฅ๏ธ Render Host your own instance of AniKatoAPI on Render. [![Deploy to Render](https://render.com/images/deploy-to-render-button.svg)](https://render.com/deploy?repo=https://github.com/Shineii86/AniKatoAPI) ### ๐Ÿ–ฅ๏ธ Standalone Server ```bash # Clone and install git clone https://github.com/Shineii86/AniKatoAPI.git cd AniKatoAPI && npm install # Start production server npm start # โ†’ http://localhost:4444 ``` ### ๐Ÿณ Docker ```dockerfile FROM node:20-alpine WORKDIR /app COPY package*.json ./ RUN npm ci --production COPY . . EXPOSE 4444 CMD ["node", "server.js"] ``` --- ## ๐Ÿ“œ Available Scripts | Command | Description | Details | |:---|:---|:---| | `npm run dev` | ๐Ÿ”ฅ Start development server | Runs on `localhost:4444` | | `npm start` | ๐Ÿš€ Start production server | `node server.js` | | `npm test` | ๐Ÿงช Run tests | Placeholder | --- ## โšก Performance | Metric | Value | |:---|:---| | โšก Cached response | ~200ms | | ๐Ÿ”„ Fresh fetch | ~1-3s | | ๐Ÿ’พ Cache TTL | 5 minutes | | โฑ๏ธ Timeout per request | 15 seconds | | ๐ŸŽฌ Total anime indexed | 10,000+ | | ๐Ÿ“ฆ Total codebase | ~80KB | ### Optimization Features - ๐Ÿ’พ **In-memory cache** โ€” Map-based with TTL expiration - โšก **Cheerio parsing** โ€” Fast HTML DOM traversal - ๐Ÿ”ง **Custom headers** โ€” Mimics browser requests - ๐ŸŽฏ **Selective scraping** โ€” Only extracts needed data - ๐Ÿ“ **Minimal deps** โ€” Only 6 production dependencies - ๐Ÿ”„ **Graceful fallback** โ€” Empty arrays on error, never crashes --- ## ๐Ÿ“ Changelog Highlights | Version | Date | Key Changes | |:---|:---|:---| | **1.5.0** | 2026-06-08 | Complete documentation rewrite โ€” 50+ files with AlisaReactionBot style | | **1.4.0** | 2026-06-08 | Fixed ALL CSS selectors to match actual anikototv.to HTML structure | | **1.3.0** | 2026-06-08 | Added streaming, mapper API, seasons, watch order, episode AJAX | | **1.2.0** | 2026-06-08 | Added watch page, AZ list, new release, newly added, trending sidebar | | **1.1.0** | 2026-06-08 | Corrected HTML selectors based on actual website analysis | | **1.0.0** | 2026-06-08 | Initial release โ€” 20+ endpoints, Vercel deployment | > ๐Ÿ“ See [CHANGELOG.md](./CHANGELOG.md) for the full version history. --- ## ๐Ÿ”ง Troubleshooting | Problem | Cause | Solution | |:---|:---|:---| | โŒ `npm install` fails | Node.js version too old | Upgrade to Node.js 20+ (`node -v`) | | โŒ 500 error on filter | Missing `keyword` param | Add `?keyword=` (even empty) to filter requests | | โŒ Empty episodes array | AJAX not loaded | Use `/api/episodes/:slug` which fetches via AJAX | | โŒ CORS errors | Frontend domain blocked | CORS is `*` โ€” check browser extension | | โŒ 404 on API routes | Wrong URL format | Use `/api/` prefix, not just `/` | | โŒ Deploy fails on Vercel | Build error | Check `node server.js` locally first | | โŒ Slow first request | Serverless cold start | Normal โ€” first request after idle takes ~3s | | โŒ Rate limited | Too many requests | Cache reduces this โ€” wait 5 min for TTL expiry | ### ๐Ÿ› Debug Mode ```bash # Run with verbose logging NODE_ENV=development npm run dev # Test specific endpoint curl http://localhost:4444/api/ curl http://localhost:4444/api/search?keyword=naruto curl http://localhost:4444/api/top-ten ``` --- ## โ“ FAQ
๐Ÿ“ฐ How do I search for anime?
Use /api/search?keyword=your+search. Results include title, poster, episodes, rating, and genres. For autocomplete suggestions, use /api/search/suggest?keyword=your+search which returns max 10 results.
๐Ÿ“บ How do I get episode lists?
Use /api/episodes/:slug where :slug is the anime URL slug (e.g., one-piece-odmau). This fetches episode data via AJAX for accuracy. The response includes animeId, totalEpisodes, and episodes array.
๐ŸŽฏ How does filtering work?
Use /api/filter with query params. The keyword param is required by the source site (use empty string if not searching). Combine genre, type, status, sort, season, and year for advanced filtering.
๐Ÿ“ก Can I use this in my frontend app?
Yes! CORS is enabled for all origins (*). Just make fetch requests to the API endpoints. No API key needed. Example: fetch('https://anikato.vercel.app/api/search?keyword=naruto')
๐Ÿ”„ How often does the data refresh?
The cache TTL is 5 minutes. After that, the next request triggers a fresh scrape from anikototv.to. This keeps data relatively fresh while reducing load on the source site.
๐ŸŽฒ What does the random endpoint do?
/api/random follows a redirect on the source site to a random anime page, then returns the full anime info including title, synopsis, rating, genres, and poster.
๐ŸŒ Can I self-host this?
Yes! Use npm start to run the Express server on any VPS, Docker container, or PaaS. The Vercel serverless functions are optional โ€” server.js handles everything.
๐Ÿ“Š How many anime are indexed?
The API can access 10,000+ anime titles from anikototv.to. The most-popular endpoint alone has 293 pages of results with 30 items per page.
--- ## ๐Ÿ—บ๏ธ Roadmap ### ๐ŸŽฏ Planned Features - [ ] ๐Ÿ” **API key authentication** โ€” Per-user rate limits - [ ] ๐Ÿ“Š **Analytics endpoint** โ€” Usage statistics - [ ] ๐ŸŒ™ **Dark/light mode** โ€” Theme toggle for landing page - [ ] ๐Ÿ“ฑ **PWA support** โ€” Install as app on mobile - [ ] ๐Ÿ”” **Webhook notifications** โ€” Push new episodes to Discord - [ ] ๐Ÿ“ˆ **Rate limiting** โ€” Per-IP request throttling - [ ] ๐Ÿ—„๏ธ **Redis cache** โ€” Persistent caching for serverless - [ ] ๐ŸŒ **Multi-language** โ€” Sub/dub language metadata - [ ] ๐Ÿค– **AI summaries** โ€” Auto-generated anime descriptions - [ ] ๐Ÿ“ฆ **NPM package** โ€” Client SDK for easy integration ### โœ… Completed - [x] ๐ŸŽฌ 24 API endpoints covering all data - [x] ๐Ÿ” Full-text search with pagination - [x] ๐Ÿ“บ Episode lists via AJAX loading - [x] ๐ŸŽฏ Advanced filtering (genre, type, status, rating, sort) - [x] ๐Ÿ† Top 10 rankings (day/week/month) - [x] ๐ŸŽฒ Random anime discovery - [x] ๐Ÿ“ก Streaming server info + mapper API - [x] ๐Ÿ“‹ AZ List alphabetical browsing - [x] ๐Ÿ”„ Smart caching with 5-min TTL - [x] ๐Ÿš€ One-click Vercel deployment - [x] ๐Ÿ“– Comprehensive documentation - [x] ๐Ÿ—๏ธ AlisaReactionBot-style code comments --- ## ๐Ÿค Contributing *Contributions are welcome and appreciated! Here's how you can help:*
### ๐Ÿ› Report Bugs Found something broken? [Open an Issue](https://github.com/Shineii86/AniKatoAPI/issues) ### ๐Ÿ’ก Suggest Features Have an idea? [Start a Discussion](https://github.com/Shineii86/AniKatoAPI/issues) ### ๐Ÿ”€ Submit PRs Ready to contribute code? [Fork & Submit](https://github.com/Shineii86/AniKatoAPI/fork)
### ๐Ÿ”„ How to Contribute ```bash # 1๏ธโƒฃ Fork the repository # Click the "Fork" button on GitHub # 2๏ธโƒฃ Clone your fork git clone https://github.com/YOUR_USERNAME/AniKatoAPI.git cd AniKatoAPI # 3๏ธโƒฃ Create a feature branch git checkout -b feature/amazing-feature # 4๏ธโƒฃ Make your changes # Edit files, add features, fix bugs... # 5๏ธโƒฃ Commit your changes git commit -m 'feat: add amazing feature' # 6๏ธโƒฃ Push to your fork git push origin feature/amazing-feature # 7๏ธโƒฃ Open a Pull Request # Go to GitHub and create a PR ``` ### ๐Ÿ“‹ Guidelines - โœ… Follow the existing code style and documentation conventions - โœ… Write meaningful commit messages (use [conventional commits](https://www.conventionalcommits.org/)) - โœ… Update CHANGELOG.md with your changes - โœ… Keep PRs focused โ€” one feature or fix per PR - โœ… Add JSDoc comments for new functions - โŒ Don't commit `node_modules` or cache files - โŒ Don't add unrelated changes to a single PR --- ## ๐Ÿ™ Acknowledgements ### ๐ŸŽฌ Data Source | Source | About | |:---|:---| | [AniKato](https://anikototv.to) | Anime streaming site โ€” primary data source | | [AniKato CZ](https://anikoto.cz) | Mirror domain | | [AniKato ME](https://anikoto.me) | Mirror domain | | [AniKato NET](https://anikoto.net) | Mirror domain | | [AniKato SE](https://anikoto.se) | Mirror domain | ### ๐Ÿ› ๏ธ Technologies - **[Express](https://expressjs.com/)** โ€” Fast, unopinionated web framework - **[Cheerio](https://cheerio.js.org/)** โ€” Fast, flexible HTML parsing - **[Axios](https://axios-http.com/)** โ€” Promise-based HTTP client - **[Vercel](https://vercel.com/)** โ€” Serverless deployment platform ### ๐Ÿ“ Resources - [Shields.io](https://shields.io/) โ€” Badges for README - [Star History](https://star-history.com/) โ€” GitHub star history charts - [Capsule Render](https://github.com/kyechan99/capsule-render) โ€” Header banner generator --- ## ๐Ÿ“„ License
[![License: MIT](https://img.shields.io/badge/License-MIT-22c55e?style=for-the-badge&logo=mit&logoColor=white)](./LICENSE) This project is licensed under the **MIT License**. Free to use, modify, and distribute โ€” see the [LICENSE](LICENSE) file for details.
--- ## ๐Ÿ‘ค Author
Banner

Shinei Nouzen
Full-Stack Developer & Anime Enthusiast

GitHub Telegram Instagram Email

--- ## โญ Star History

Star History Chart

> โญ If you found this project useful, please consider giving it a star! ---

Made With โค๏ธ For The Anime Community

ยฉ 2026 Shineii86. All Rights Reserved.