docs.manob.ai
Toggle Sidebar

Get Related Products by ID

Retrieve a list of products that are related to a specified product using its unique identifier. This endpoint helps users discover items that are similar or commonly grouped with the selected product.

Requirements

  • id (product ID) is required.

Usage

Request

  • Method: GET
  • Path: /products/{id}/related

Path Parameters

| Name | Type | Required | Example | Description | |------|--------|----------|---------|-------------| | id | string | Yes | 3fa85f64-5717-4562-b3fc-2c963f66afa6 | Unique product ID (UUID). |

Example

curl -X GET "https://api.example.com/products/3fa85f64-5717-4562-b3fc-2c963f66afa6/related"

Response

200 OK

Returns a standard API envelope where the related products list is returned directly in data (array).

Example:

{
  "status": true,
  "path": "string",
  "statusCode": 0,
  "message": "string",
  "data": [
    {
      "is_onsale": true,
      "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
      "title": "string",
      "slug": "string",
      "thumbnail_image": "string",
      "price": 0,
      "avg_rating": "string",
      "total_reviews": 0,
      "total_sales": 0,
      "global_ranking": 0,
      "genre_ranking": 0,
      "is_wishlist": true,
      "is_featured": true,
      "mrp": 0,
      "creator": {
        "full_name": "string",
        "user_name": "string",
        "email": "string",
        "profile_image": "string",
        "is_online": true,
        "level": "string"
      }
    }
  ]
}

Notes

  • The related products list is returned directly as an array in data (not data.data).
  • avg_rating is returned as a string in this response.
  • The creator object contains basic information about the product creator.