DEV Community

Cover image for Manga Hook, your own manga API.
kiraaziz
kiraaziz

Posted on

Manga Hook, your own manga API.


Welcome to Manga Hook, your go-to API for accessing a vast repository of manga data freely. Manga Hook is designed to streamline the process of retrieving manga information, offering features such as search, fetching all manga, fetching a single manga, retrieving manga chapters, and obtaining images from a specific chapter.



Demo | Documentation



Manga Hook

Features

-πŸ“š get all manga

-ℹ️ get single manga detail

-πŸ“– get chapter list including images

-πŸ” search support

-πŸ”₯ Nextjs exemple with ready to use hooks

Quick start

Follow these simple steps to get Manga Hook up and running on your local machine:

1. Clone the Repository:

Open your terminal and run the following command to clone the Manga Hook repository:

Terminal window

git  clone  https://github.com/kiraaziz/mangahook-api
Enter fullscreen mode Exit fullscreen mode

2. Navigate to the Server Directory:

Change your working directory to the server folder:

Terminal window

cd  server
Enter fullscreen mode Exit fullscreen mode

3. Install Dependencies:

Install the required dependencies using npm:

Terminal window

npm  install
Enter fullscreen mode Exit fullscreen mode

4. Start the Express Server:

Launch the Manga Hook server by running the following command:

Terminal window

npm  run  start
Enter fullscreen mode Exit fullscreen mode

This will start the server on port 3000.

Now that Manga Hook is running, let’s explore how to retrieve manga data.

List Manga

To list available manga, make a GET request to the following endpoint using a tool like Postman or Insomnia:

  • Endpoint:

    GET http://localhost:3000/api/mangaList
    
  • Example Response:

    {
        "mangaList": [
            {
                "id": "1manga-oa952283",
                "image": "https://ww6.mangakakalot.tv//mangaimage/manga-oa952283.jpg",
                "title": "Attack On Titan",
                "chapter": "chapter-139",
                "view": "105.8M",
                "description": "..."
    
            }
            // ... other manga entries
        ],
        "metaData": {
            "totalStories": 10,
            "totalPages": 100,
            "type": [
                {
                    "id": "newest",
                    "type": "Newest"
                }
                // ... other types
            ],
            "state": [
                {
                    "id": "Completed",
                    "type": "Completed"
                }
                // ... other states
            ],
            "category": [
                {
                    "id": "all",
                    "type": "ALL"
                }
                // ... 40 other categories
            ]
        }
    }
    

Now you're ready to explore and integrate Manga Hook into your projects. Feel free to use the provided API endpoints to access manga data and enhance your manga-related applications!

  • Response Format:
    The API will respond with data structured as follows:

    interface MangaList {
        mangaList: [
            {
                id: String,
                image: String,
                title: String,
                chapter: String,
                view: String,
                description: String
            }
        ],
        metaData: {
            totalStories: Number,
            totalPages: Number,
            type: [
                {
                    id: String,
                    type: String
                }
            ],
            state: [
                {
                    id: String,
                    type: String
                }
            ],
            category: [
                {
                    id: String,
                    type: String
                }
            ],
        }
    }
    

Top comments (0)