Tool tree
Deterministic local cart for testing WebMCP agents
Implementation
gradeNot graded
gradeNot graded
get_cartAnswer
Return the current cart items, quantities, discount state, and total.
View tool JSON
{
"name": "get_cart",
"kind": "answer",
"impl": "imperative",
"description": "Return the current cart items, quantities, discount state, and total.",
"inputSchema": {
"type": "object",
"properties": {},
"additionalProperties": false
},
"page": "/pagescout/"
}add_itemAction
Add a deterministic catalog item to the visible cart.
View tool JSON
{
"name": "add_item",
"kind": "act",
"impl": "imperative",
"description": "Add a deterministic catalog item to the visible cart.",
"inputSchema": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"Notebook",
"Headphones",
"Coffee"
]
},
"quantity": {
"type": "integer",
"minimum": 1,
"maximum": 10
}
},
"required": [
"name",
"quantity"
],
"additionalProperties": false
},
"page": "/pagescout/"
}clear_cartAction
Remove every item and any applied discount from the visible cart.
View tool JSON
{
"name": "clear_cart",
"kind": "act",
"impl": "imperative",
"description": "Remove every item and any applied discount from the visible cart.",
"inputSchema": {
"type": "object",
"properties": {},
"additionalProperties": false
},
"page": "/pagescout/"
}