Skip to content

Snozxyx/TatakaiAPI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

31 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Tatakai API 🎌

Unified Anime API combining HiAnime, regional scrapers, and utility APIs with modern caching, CORS, rate limiting, and logging.

Social

Discord : https://dsc.gg/tatakai

Disclaimer

  • No other Social Media Handle is availaible right now, If you see then please report us as we only have discord server .

Features

  • πŸš€ Modern Stack: Built with Hono - ultra-fast, lightweight web framework
  • πŸ’Ύ Hybrid Caching: Redis with LRU in-memory fallback
  • πŸ”’ Rate Limiting: Configurable per-IP rate limiting
  • πŸ“ Structured Logging: Pino logger with pretty dev output
  • 🌐 CORS Ready: Configurable origin whitelisting
  • 🐳 Docker Ready: Multi-stage Dockerfile included
  • πŸ“¦ TypeScript: Full type safety
  • πŸ§ͺ Comprehensive Testing: Built-in endpoint validation scripts

API Endpoints

Route Description
/api/v1/hianime/* HiAnime scraper - search, info, episodes, sources
/api/v1/anime/* External anime search providers (GogoAnime, Chia-Anime, etc.)
/api/v1/anime-api/* Anime utility APIs (quotes, images, facts, waifu)
/api/v1/animehindidubbed/* Hindi dubbed anime scraper
/api/v1/animelok/* AnimeLok multi-language streaming
/api/v1/animeya/* Animeya streaming platform
/api/v1/watchaw/* WatchAnimeWorld multi-language streaming
/api/v1/desidubanime/* DesiDubAnime - Hindi/regional dubbed anime
/api/v1/aniworld/* AniWorld - German anime streaming (aniworld.to)
/health Health check
/version API version info
/api/v1/docs/llm Full LLM-friendly documentation

Route Details

HiAnime (/api/v1/hianime)

  • GET /home - Home page with featured anime
  • GET /search?q={query} - Search anime
  • GET /info/{id} - Anime details
  • GET /episodes/{id} - Episode list
  • GET /sources/{episodeId} - Video sources

AnimeLok (/api/v1/animelok)

  • GET /search?q={query} - Search anime
  • GET /anime/{id}/seasons - Get seasons/episodes
  • GET /watch/{episodeId}?ep={num} - Get video sources

Animeya (/api/v1/animeya)

  • GET /home - Home page
  • GET /search?q={query} - Search anime
  • GET /info/{id} - Anime info with episodes
  • GET /watch/{episodeId} - Video sources

WatchAnimeWorld (/api/v1/watchaw)

  • GET /episode?id={id} - Get episode sources by ID

DesiDubAnime (/api/v1/desidubanime)

  • GET /search?q={query} - Search Hindi dubbed anime
  • GET /info/{slug} - Anime details
  • GET /watch/{episodeSlug} - Get video sources

AniWorld (/api/v1/aniworld)

  • GET /info/{slug} - Anime info (German)
  • GET /watch/{slug}/episode/{num} - Get video sources
  • GET /search?q={query} - Search anime

Hindi Dubbed (/api/v1/animehindidubbed)

  • GET /search?title={query} - Search Hindi dubbed anime
  • GET /info/{id} - Anime details
  • GET /watch/{episodeId} - Video sources

Anime API Utilities (/api/v1/anime-api)

  • GET /quotes/random - Random anime quote
  • GET /images/{category} - Anime images (waifu, neko, etc.)
  • GET /facts - Random anime facts

Quick Start

Prerequisites

  • Node.js >= 18
  • npm or yarn
  • Redis (optional, for distributed caching)

Installation

# Clone and install
cd TatakaiAPI
npm install

# Create .env file
cp .env.example .env

# Start development server
npm run dev

Docker

# Build and run with Docker Compose
docker-compose up -d

# Or build image only
docker build -t tatakai-api .
docker run -p 4000:4000 tatakai-api

Configuration

Variable Description Default
PORT Server port 4000
NODE_ENV Environment development
REDIS_URL Redis connection URL (empty = in-memory)
CORS_ALLOWED_ORIGINS Allowed origins (comma-separated) *
RATE_LIMIT_WINDOW_MS Rate limit window 60000
RATE_LIMIT_MAX_REQUESTS Max requests per window 100
CACHE_TTL_SECONDS Default cache TTL 300

Testing

Run the comprehensive test suite to validate all API endpoints:

# Run basic validation
npm run test

# Run comprehensive endpoint tests
npm run test:comprehensive

The comprehensive test script checks all routes with sample parameters and reports success/failure status for each endpoint.

Example Requests

# HiAnime home page
curl http://localhost:4000/api/v1/hianime/home

# Search anime on HiAnime
curl "http://localhost:4000/api/v1/hianime/search?q=naruto"

# External anime search (GogoAnime)
curl "http://localhost:4000/api/v1/anime/gogoanime/naruto"

# Anime quotes
curl "http://localhost:4000/api/v1/anime-api/quotes/random"

# Anime images
curl "http://localhost:4000/api/v1/anime-api/images/waifu"

# Hindi dubbed search
curl "http://localhost:4000/api/v1/hindidubbed/search?title=naruto"

# Animeya home
curl "http://localhost:4000/api/v1/animeya/home"

Project Structure

TatakaiAPI/
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ config/       # Configuration (env, cache, cors, logger, etc.)
β”‚   β”œβ”€β”€ docs/         # API documentation markdown files
β”‚   β”œβ”€β”€ middleware/   # Hono middleware (logging, cache control)
β”‚   β”œβ”€β”€ routes/       # API routes by provider
β”‚   β”‚   β”œβ”€β”€ hianime/          # HiAnime scraper
β”‚   β”‚   β”œβ”€β”€ anime/            # External search providers
β”‚   β”‚   β”œβ”€β”€ anime-api/        # Utility APIs
β”‚   β”‚   β”œβ”€β”€ animehindidubbed/ # Hindi dubbed scraper
β”‚   β”‚   β”œβ”€β”€ animelok/         # AnimeLok multi-language
β”‚   β”‚   β”œβ”€β”€ animeya/          # Animeya platform
β”‚   β”‚   β”œβ”€β”€ watchanimeworld/  # WatchAnimeWorld
β”‚   β”‚   β”œβ”€β”€ desidubanime/     # DesiDubAnime Hindi
β”‚   β”‚   └── aniworld/         # AniWorld German
β”‚   β”œβ”€β”€ server.ts     # Main entry point
β”‚   └── utils.ts      # Utility functions
β”œβ”€β”€ scripts/          # Utility scripts
β”‚   β”œβ”€β”€ comprehensive_test.ts  # Full API endpoint testing
β”‚   └── validate_api.ts        # API validation script
β”œβ”€β”€ public/           # Static files & docs UI
β”œβ”€β”€ Dockerfile
└── docker-compose.yml

License

MIT

About

Unified API for the Anime that includes the multiple website scrapping , streaming link and hindi dubbed and other indian dubbed

Topics

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors