search_products
Search Elixir's marketplace when the user wants a product and names no merchant, or asks for Elixir or Envoy.
MCP tool search_products, called with tools/call on https://api.envoy.money/mcp (Streamable HTTP).
Search Elixir's marketplace when the user wants a product and names no merchant, or asks for Elixir or Envoy. Show each with its price. To buy one or several, call start_purchase once with items [{name, quantity, product_id}], total = the sum of their total.display (e.g. "₹998.00") and their merchant_url. 1mg products may add a handling fee; if Envoy answers with a different total, ask the user and resend with it. Moves no money.
| Title | Service | Read only | Destructive | Idempotent | External sites |
|---|---|---|---|---|---|
| Search Elixir marketplace | purchase | true | false | true | false |
The text content is a plain-English briefing, then one line of JSON with the slim agent data. structuredContent holds that same slim data. isError is true when the call failed and changed nothing. Diagnostics for support are in _meta["money.envoy/support"]; they are not for the model. Tool annotations describe effects; they do not grant permission. The HTTP API returns the full envelope: see the API reference page.
Input
Prop
Type
Unknown fields are rejected. The exact input schema is on the schemas page.
Synthetic request
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "search_products",
"arguments": {
"query": "whey protein 1kg",
"quantity": 2
}
}
}Success data
The text content opens with a briefing: one to three sentences for the user, then What to do: for the agent. Tell the user the first part in your own words and do what What to do says. One JSON line follows with these fields. Pass next.args unchanged to next.tool. Never show the JSON line, ids or codes to the user. Outputs may gain fields, so ignore ones you do not recognize.
| Field | Required | Type | Description and rules |
|---|---|---|---|
situation | No | "needs_details" | "needs_answer" | "waiting_for_user" | "working" | "ready" | "confirming" | "done" | "stopped" | "needs_support" | Where the purchase stands. The English briefing above says what it means. |
next | No | object | The call to make next: tool, args (pass verbatim) and wait_seconds before calling. |
retry | No | "same_call" | "after_fix" | "check_status_first" | "new_purchase" | "no" | Whether and how to retry. |
fix | No | array | Input fields to fix before retrying. |
support_ref | No | string | Give this to the user only if they ask for help. |
products | No | array | Elixir marketplace products: product_id, name, brand, price, quantity, total and merchant_url. |
Synthetic result
Example synthetic-products (synthetic data, the MCP text content; JSON is formatted here for reading but arrives on one line):
1 product on Elixir's marketplace:
1. "Whey Protein Isolate 1kg" (brand "Synthetic Nutrition"): ₹499.00 each, ₹998.00 for 2.
What to do: Show the user each product with its price. To buy what the user picks, one or several, call start_purchase once with items [{name, quantity, product_id}], total = the sum of their total.display (e.g. "₹998.00"), their merchant_url and the same address_id you searched with. 1mg products may add a handling fee; if Envoy answers with a different total, ask the user and resend with it. A typed address must match a saved address's PIN. Never buy one the user did not pick.
{
"products": [
{
"product_id": "ofr_0123456789abcdef0123456789abcdef",
"name": "Whey Protein Isolate 1kg",
"brand": "Synthetic Nutrition",
"image": "https://cdn.example.test/whey.jpg",
"price": {
"minor": 49900,
"currency": "INR",
"display": "₹499.00"
},
"quantity": 2,
"total": {
"minor": 99800,
"currency": "INR",
"display": "₹998.00"
},
"valid_until": "2026-09-29T12:30:00Z",
"merchant_url": "https://elixir.cards"
}
]
}Errors
A failure sets isError to true and changes nothing. The briefing says what happened and what to do; retry and fix in the JSON line say whether and how to retry. Branch on those, not on a code: these common codes appear only in _meta["money.envoy/support"], for support. See all error codes for the complete contract list.
| Code | HTTP status | Meaning | What the agent does |
|---|---|---|---|
INVALID_INPUT | 400 | Fix the supplied input. | Fix the fields listed in the data below and make the same call again. |
UNAUTHENTICATED | 401 | Reconnect through Central Auth. | Ask the user to reconnect Envoy, then try again. |
UNAVAILABLE | 503 | The service is unavailable; follow retryable and next. | Wait, then make the same call again. Don't pay any other way meanwhile. |