FAQ

Frequently asked questions.

Answers to common questions about anime-sdk. Missing something? Open an issue.

What is the fastest way to get started?

Clone github.com/hexxt-git/anime-sdk/tree/master/examples. Build the SDK: npm run build. Start the server: node examples/server.mjs. Run the website: cd examples/website && npm install && npm run dev.

Can I use anime-sdk in a browser app?

No. anime-sdk runs in Node or Bun only. For a browser frontend, run the built-in HTTP server on your backend and call it over HTTP from the client. Set proxy: true when starting the server — it rewrites stream URLs so your frontend never has to deal with CDN headers or CORS.

I got a sourceUrl back from resolveStream. How do I play it?

Check isHLS. If true, the URL is an HLS stream — use hls.js on Chrome or Firefox, or a native <video> on Safari. If false, it's a plain MP4 you can set directly as the video source. If you're running the HTTP server with proxy: true, all of this is handled for you and the URL just works.

Which provider should I use?

For general anime, start with AllManga — widest catalogue, sub and dub, stable API. AnimeParadise is the best pick when you need external subtitle tracks. Gogoanime is a solid fallback for titles AllManga is missing. Goyabu is the only option for Brazilian Portuguese. For manga, MangaDex first, then WeebCentral or Mangapill.

Which providers have dubbed anime?

AllManga, Anikoto, and MegaPlay support sub and dub. Goyabu is Brazilian Portuguese dub only. Gogoanime and AnimeParadise are sub-only. Pass the language when calling resolveStream — if a provider doesn't support what you asked for, it falls back to sub.

Do stream URLs expire?

Yes, usually within minutes. Resolve streams on demand when the user wants to play something — do not cache them. Search results and episode lists are safe to cache; stream URLs are not.

Can I use anime-sdk without TypeScript?

Yes. The package ships as compiled JavaScript with type declarations alongside. Use ESM (import) or CommonJS (require) — TypeScript is not required either way.

Is anime-sdk legal to use?

anime-sdk resolves stream URLs from sites that host content publicly. It does not bypass DRM or crack paywalls. Whether your specific use is legal depends on your jurisdiction and what you are building — a personal tool is a different situation from a public redistribution service.

What happens when a provider goes down?

Swap it out. All providers share the same three-method interface, so switching is a one-line import change. The live E2E tests hit real endpoints and fail the moment an upstream site breaks, which is how we catch when a provider needs updating.

Can I download episodes and chapters to disk?

Yes. downloadVideo saves an episode as an MP4, downloadMangaChapter saves a chapter as a ZIP. Both are exported from anime-sdk. The HTTP server also has /download endpoints that stream progress back via SSE so you can show a progress bar.

What does the proxy do?

The /proxy endpoint in the HTTP server fetches any URL on the server's behalf, attaching whatever headers the CDN requires. When you start the server with proxy: true, stream and subtitle URLs are automatically rewritten to go through it. Browser clients just use the URL directly — no extra headers needed, no CORS issues.

Does anime-sdk cache anything?

Not on its own. The HTTP server accepts a cache object with get and set methods — a plain Map, Redis, SQLite, anything works. Search results and episode lists are safe to cache for a long time. Do not cache stream URLs.