Skip to content

Conversation

@Katsshura
Copy link
Owner

Highlight feature - Enabled API

Open API docs:

http://localhost:8080/swagger-ui.html
http://localhost:8080/v3/api-docs

HighlightDTO Schema:

Fields marked with * are required and cannot be null.
Field Constraints
id integer($int64)
enabled boolean
product ProductDTO
title* string
subtitle* string

Request JSON Example - POST - {{url}}/product/highlight/<product_id>

{
    "title": "Testing Title One",
    "subtitle": "Testing Description One"
}

Response JSON Example - GET - {{url}}/product/highlight

{
    "id": 2,
    "enabled": true,
    "product": {
        "id": 1,
        "name": "Test Product One",
        "description": "Product Test Via Postman One",
        "price": 0.99,
        "image_url": "https://images.unsplash.com/photo-1551404973-7dec6ee9bba7?ixlib=rb-1.2.1&ixid=MnwxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8&auto=format&fit=crop&w=1287&q=80",
        "available_stock": 5,
        "popularity": 0.0
    },
    "title": "Testing Title One",
    "subtitle": "Testing Description One"
}

PUT Endpoint - {{url}}/product/highlight/<highlight_id>

@Katsshura Katsshura merged commit f5ffc75 into master Oct 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants