Implementation
gradeNot graded
gradeNot graded
view_productsAction
Fetches the product catalog from the backend API. Requires an active user session.
View tool JSON
{
"name": "view_products",
"kind": "act",
"impl": "imperative",
"description": "Fetches the product catalog from the backend API. Requires an active user session.",
"inputSchema": {},
"page": "/WebMCP-Demo-Retail/"
}add_to_cartAction
Adds a product to the shopping cart by product ID and quantity.
View tool JSON
{
"name": "add_to_cart",
"kind": "act",
"impl": "imperative",
"description": "Adds a product to the shopping cart by product ID and quantity.",
"inputSchema": {
"type": "object",
"properties": {
"product_id": {
"type": "string",
"description": "Product ID from the catalog"
},
"quantity": {
"type": "integer",
"description": "Number of units to add",
"minimum": 1
}
},
"required": [
"product_id",
"quantity"
]
},
"page": "/WebMCP-Demo-Retail/"
}view_cartAnswer
Returns the current cart contents and total as JSON. Requires an active user session.
View tool JSON
{
"name": "view_cart",
"kind": "answer",
"impl": "imperative",
"description": "Returns the current cart contents and total as JSON. Requires an active user session.",
"inputSchema": {},
"page": "/WebMCP-Demo-Retail/"
}