/api/v1/books/bestsellers

GET /api/v1/books/bestsellers

Description

This endpoint allows developers to retrieve a list of the 5 best-selling books ordered by ascending price.

Parameters

No parameters required (and/or available).


Request

Response

The response will show all 5 books with the best score ordered by ascending price. This response will give you 5 books max (can give you less if the database has less than 5 books).

[
        {
            "_id": "6651c712fe5f5504f6bb05d1",
            "amount_sold": 3,
            "title": "Flexible Rails",
            "score": 5,
            "price": 16.41,
            // More book information
        },
        {
            "_id": "6651c712fe5f5504f6bb05c8",
            "amount_sold": 1,
            "title": "Unlocking Android",
            "score": 5,
            "price": 26,
            // More book information
        }
        // 3 more books
]