A fast, free, and open-source REST API for manga data
Live Demo Β· API Explorer Β· Report Bug
- π Blazing Fast β Responses are aggressively cached on Vercel's Edge Network (5 min to 7 days)
- π API Key Support β Your own apps get unlimited access with a secret bypass key
- π‘οΈ Rate Limited β Built-in per-IP rate limiting (60 req/min) to prevent abuse
- πΌοΈ Image Proxy β Built-in proxy to bypass hotlinking and CORS restrictions
- π Interactive Docs β API Explorer dashboard at
/api - π Cloudflare Bypass β CF Worker proxy to avoid 403 blocks on serverless platforms
- π¦ Self-Hostable β Clone it, set your env vars, and deploy your own instance
Base URL: https://your-deployment.vercel.app
| Method | Endpoint | Description | Cache |
|---|---|---|---|
GET |
/api/home |
Home data β banner, popular, latest, newest manga | 5 min |
GET |
/api/komik/:slug |
Manga detail β synopsis, genres, chapter list | 30 min |
GET |
/api/komik/:slug/:chapterId |
Chapter images & prev/next navigation | 7 days |
GET |
/api/proxy?url=... |
Image proxy β bypasses hotlinking restrictions | 1 year |
| Check more in API Docs |
All endpoints return structured JSON:
{
"status": 200,
"message": "Success",
"data": { ... }
}| Header | Description |
|---|---|
X-RateLimit-Limit |
Maximum requests per window (60) |
X-RateLimit-Remaining |
Remaining requests in current window |
Retry-After |
Seconds until rate limit resets (on 429) |
Bypass rate limit by sending your secret API key:
X-API-Key: your-secret-key
| Component | Technology |
|---|---|
| Framework | Next.js 16 (App Router) |
| Language | TypeScript |
| Scraping | Cheerio + native fetch() |
| Proxy | Cloudflare Workers (free tier) |
| Styling | Tailwind CSS |
| Analytics | Vercel Analytics + Speed Insights |
- Node.js 20+
- pnpm or npm
- A Vercel account (free)
- A Cloudflare account (free)
git clone https://github.com/Wakype/komikcast-api.git
cd komikcast-api
pnpm install # or npm installcp .env.example .env.localEdit .env.local:
# Required: Target manga site URL
MANGA_BASE_URL=https://be.komikcast.cc/
# Required for Vercel deploy: Your CF Worker proxy URL
SCRAPER_PROXY_URL=https://your-worker.your-subdomain.workers.dev
# Optional: Secret key for rate limit bypass
BYPASS_SECRET=your-super-secret-keyThe Vercel deployment needs a Cloudflare Worker to bypass Cloudflare's IP blocking. The worker code is at cloudflare-worker/worker.js.
- Go to Cloudflare Dashboard β Workers & Pages β Create Worker
- Name it (e.g.,
komikcast-proxy) β click Deploy - Click Edit Code β paste the contents of
cloudflare-worker/worker.js - In Worker Settings β Variables, add:
BYPASS_SECRET= same value as your.env.local - Click Deploy
- Copy the Worker URL and set it as
SCRAPER_PROXY_URLin your Vercel environment
pnpm devOpen http://localhost:3000 to see the landing page, or http://localhost:3000/api for the API Explorer.
# Push to GitHub, then import in Vercel
# Or use Vercel CLI:
npx vercelSet environment variables in Vercel β Project β Settings β Environment Variables.
ββββββββββββββββββββ ββββββββββββββββββββ ββββββββββββββββββ
β Your Frontend βββββββ Vercel API βββββββ CF Worker ββββββ Target Site
β + X-API-Key β β (Next.js) β β (Proxy) β (komikcast)
β β β Rate Limiter β β Trusted IPs β
ββββββββββββββββββββ ββββββββββββββββββββ ββββββββββββββββββ
β
Random Users
(rate limited)
Why Cloudflare Worker? Vercel's serverless functions run on datacenter IPs that Cloudflare actively blocks. By routing requests through a CF Worker (which runs inside Cloudflare's own network), the requests are treated as trusted.
komikcast-api/
βββ app/
β βββ api/ # API endpoints + Explorer UI
β βββ legal/ # Legal pages (Terms, Privacy, DMCA)
β βββ page.tsx # Landing page
βββ cloudflare-worker/ # CF Worker proxy (deploy separately)
βββ libs/ # Scraper core (fetchAPI, fetchPage)
βββ types/ # TypeScript interfaces
βββ utils/ # Response helpers, cache utilities
βββ proxy.ts # Rate limiting (Next.js proxy convention)
βββ .env.example # Environment variable template
βββ AGENTS.md # AI coding assistant guide
This API is provided for educational purposes and personal projects only. The creator is not responsible for how you use the data. We do not host any manga, images, or copyrighted content. All content belongs to their respective copyright holders.
MIT License
Made with β€οΈ by waky.dev