def _load_pages(self) -> Response: resp = self.session.get( self._api_url, params={ "chapter_id": self.chapter_id, "split": "yes", "img_quality": "high", }, ) response_proto = Response() return response_proto.FromString(resp.content)
def _load_pages(self, chapter_id: Union[str, int], quality: str, split: bool) -> Response: resp = self.session.get( self._api_url, params={ "chapter_id": chapter_id, "split": "yes" if split else "no", "img_quality": quality, }, ) response_proto = Response() return response_proto.FromString(resp.content)
def _load_pages(self) -> Response: url = "https://jumpg-webapi.tokyo-cdn.com/api/manga_viewer" resp = self.session.get( url, params={ "chapter_id": self.chapter_id, "split": "yes", "img_quality": "high", }, ) response_proto = Response() return response_proto.FromString(resp.content)
def _load_pages(self, chapter_id: Union[str, int]) -> MangaViewer: resp = self.session.get( f"{self._api_url}/api/manga_viewer", params={ "chapter_id": chapter_id, "split": "yes" if self.split else "no", "img_quality": self.quality, }, ) return Response.FromString(resp.content).success.manga_viewer
def _get_title_details(self, title_id: Union[str, int]) -> TitleDetailView: resp = self.session.get( f"{self._api_url}/api/title_detail", params={"title_id": title_id}, ) return Response.FromString(resp.content).success.title_detail_view