Skip to content

Queries

This module contains GraphQL queries for fetching data from the AniList API.

Queries
  • VIEWER: Fetches the viewer's ID and name.
  • MANGALIST: Fetches a chunk of the viewer's manga list, including media ID, progress, and status.
  • FORMAT: Fetches the format of a specific media item by ID.

FORMAT module-attribute

FORMAT: str = '\nquery ($id: Int) {\n        Media (id: $id) {\n            id\n            format\n        }\n    }\n'

MANGALIST module-attribute

MANGALIST: str = '\nquery ($userId: Int, $chunk: Int, $perChunk: Int) {\n        MediaListCollection (userId: $userId, type: MANGA, chunk: $chunk, perChunk: $perChunk) {\n            lists {\n                entries {\n                    mediaId\n                    progress\n                    status\n                }\n            }\n        }\n    }\n'

VIEWER module-attribute

VIEWER: str = '\nquery {\n        Viewer {\n            id\n            name\n        }\n    }\n'