Suggest similar products
suggest_similar_productsAfter optimize_delivery priced the wrong product, use this to show other things the shopper might have meant. Send their words in HEBREW (original line or the correction) and the rejected product_id so that SKU is dropped. Example: priced נקניקיות פרגיות, shopper said thigh cuts → query='פרגיות' or 'שוקיים', product_id=. Then call optimize_delivery again with the same list, that line pinned to the chosen product_id. Also answers 'is there a cheaper one?': every suggestion carries fromPrice, the lowest it goes for at any storefront delivering to this address, and normalizedUnitPrice, the same money per 100g/100ml/piece. Compare on normalizedUnitPrice, NOT on fromPrice: a smaller pack is cheaper to buy and usually dearer per gram, so a saving claimed on fromPrice alone is wrong whenever the pack sizes differ. Results come back cheapest per unit first, and rejected carries the same fields so the swap is directly comparable. fromPrice is a floor across storefronts, so quote it as 'from ₪X'; pricedAtStorefronts=1 means it is one shop's price rather than a market rate. Send city or address, or no price can be reported at all. Do not use this for a first-pass shopping list — call optimize_delivery once with every line.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| city | No | City name in Hebrew or English (also accepts CBS locality codes). Aliases resolve to one place — e.g. 'הרצליה', 'Herzliya', and '6400' are the same filter. May be combined with location as a disambiguation hint. | |
| near | No | 'lat,lng' string, e.g. '32.078,34.774', to find stores near a point. | |
| limit | No | Max neighbours to return. Default 8. | |
| query | No | What they meant, in Hebrew. Prefer the correction ('שוקיים') or the original line ('פרגיות'). A Latin brand name matches nothing. Required unless product_id is set. | |
| location | No | Free-text neighborhood or address in Israel, e.g. 'נווה עמל, הרצליה'. Resolved to coordinates via cached Nominatim. Do not combine with near. | |
| radius_km | No | Search radius in km around the resolved point. Defaults to 10km when near or location is set. Ignored without a point. | |
| product_id | No | The product_id optimize_delivery priced that the shopper rejected. Excluded from results. |