Extension development¶
Katari extensions connect the app to external catalogues. They provide metadata and tell Katari how to resolve something a person can read or watch. Extensions do not bundle or host the content itself.
Katari uses entry-source-api for new extensions. Although Katari can still load compatible Mihon extensions, new extensions should not depend on the legacy source-api module or use its SManga, SChapter, MangasPage, Page, or RxJava contracts.
The model¶
An extension starts with an EntrySourceFactory, which creates one or more UnifiedSource instances:
EntrySourceFactory
└── UnifiedSource
├── SEntry a title in a catalogue
├── SEntryChapter something the user can open
└── EntryMedia representation of the content
The source is not permanently classified as a manga or anime source. Each SEntry declares its EntryType, and getMedia() returns the payload Katari should open. One factory can expose several sources, and a source may return different entry types in the same catalogue.
Choose a starting point¶
- Extend
EntryImageHttpSourcefor an HTTP source that resolves image pages. - Extend
EntryHttpSourcefor an HTTP source that resolves video or other non-image media. - Implement
UnifiedSourcedirectly when the provided HTTP behavior is not appropriate.
Guides¶
- Create your first extension
- Understand the Entry API
- Make HTTP requests and parse responses
- Choose the image or playback media cookbook.
- Publish and maintain the extension
If you already maintain a Mihon source, follow the migration guide. Before selecting an SDK release, read API compatibility and versioning.
The Kotlin sources under entry-source-api are the final reference for the currently checked-out API.