mercadona-cli-shopping

Automate product search, cart management, and checkout on Mercadona via CLI.

4|Updated May 16, 2026
One-click install
npx skills add https://github.com/reason-machines/devtools-skills --skill mercadona-cli-shopping-reason-machines
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: mercadona-cli-shopping
Source: https://github.com/reason-machines/devtools-skills/tree/main/skills/mercadona-cli-shopping
Command: npx skills add https://github.com/reason-machines/devtools-skills --skill mercadona-cli-shopping-reason-machines

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Manually browsing the Mercadona supermarket website to search products, compare prices, and place grocery orders is slow and cannot be automated. This Skill exposes the Mercadona catalog, cart, and checkout flow as a scriptable command-line interface with structured JSON output. ## Core Features & Use Cases - Product Search & Pricing: Search products by name, get real-time warehouse-specific prices, browse categories, and batch-price entire shopping baskets from text files. - Cart & Checkout Automation: Add or set cart quantities in bulk, create checkouts, select delivery addresses and slots, and submit orders with budget guards that refuse overspending. - Use Case: Convert a plain-text recipe ingredient list into product IDs with mercadona batch, price the basket with mercadona total, load it into the cart with cart set-many, and place a recurring weekly order capped by a maximum euro budget. ## Quick Start Ask the agent to search Mercadona for a product like "queso" and return the top results with prices in JSON format.

Frequently Asked Questions about mercadona-cli-shopping

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I search Mercadona products from the command line?▼

Run `mercadona search <term>` to search the catalog, adding `--json` for structured output and `--limit` to cap results. Use `mercadona batch -f file.txt` to resolve many search terms in a single request.

How do I authenticate the Mercadona CLI for cart and checkout?▼

Log in to tienda.mercadona.es in your browser, export a HAR file from DevTools, and run `mercadona import-har --file export.har`. This extracts a refresh token that auto-renews, and `mercadona whoami` verifies the session.

Can I place a real Mercadona order automatically with a spending limit?▼

Yes, the checkout flow supports budget guards via the `--max` flag or MERCADONA_MAX_EUR environment variable. Any cart or submit operation exceeding the limit fails with exit code 1, and submit requires an explicit `--yes` flag.

Why do Mercadona CLI prices not match the website?▼

Product IDs and prices are warehouse-specific, so a mismatched warehouse causes wrong prices. Run `mercadona set-postal YOUR_POSTAL_CODE` to resolve and save the correct warehouse for your delivery area.

What should I do when the Mercadona CLI returns a 401 token_not_valid error?▼

A 401 error means the access token expired. Re-import authentication with a fresh HAR export using `mercadona import-har`, or use `import-curl` with a newly copied authenticated request from browser DevTools.