added manga integration

This commit is contained in:
2026-10-14 21:55:45 -07:00
parent 401a16d07d
commit b42f21f48a
6 changed files with 320 additions and 5 deletions

View File

@@ -56,6 +56,21 @@ console.log(candidates.map(({ url, type, quality }) => ({ url, type, quality }))
const result = await vyla.getStream(provider.key, 1396, 1, 1);
```
## Read manga
Search manga titles, retrieve chapter listings, and resolve reader-ready page images directly:
```javascript
const search = await vyla.searchManga("Steel Ball Run", 1, 5);
const firstResult = search.results[0];
const manga = await vyla.getManga(firstResult.id);
const firstChapter = manga.chapters[manga.chapters.length - 1];
const chapterData = await vyla.getMangaChapter(manga.id, firstChapter.id);
console.log(chapterData.pages.map(p => p.url));
```
## Make it resilient
Provider results are inherently variable: a source can fail, time out, return more than one candidate, or be temporarily disabled. In production: