| name | coop-cli |
| description | Use the coop-cli tool to search for grocery products, manage shopping carts, and find stores on Coop.se (Swedish grocery chain). Activate when the user wants to shop for groceries, search for food products, manage a Coop shopping cart, or find Coop stores. |
coop-cli — Coop.se Grocery Shopping CLI
You have access to coop-cli, a command-line tool for interacting with Coop.se online grocery shopping.
Setup
Authentication
All commands except stores require Coop.se credentials. Set them as environment variables:
export COOP_EMAIL="user@example.com"
export COOP_PASSWORD="password"
Or pass them as flags: --email / --password.
Store ID
Most commands require a store ID. Set it as an environment variable:
export COOP_STORE="012345"
Or pass it as a flag: --store. Find store IDs with the stores command.
If credentials or store ID are missing, prompt the user to set them up before proceeding.
Commands
Find stores (no auth required)
coop-cli stores <query>
Search by city, name, or address. The STORE ID column is the value to use with --store or COOP_STORE.
Search for products
coop-cli search <query> [--limit N]
Returns: ID, name, manufacturer, size, price, comparative price, and category. Default limit is 10 results.
Cart management
coop-cli cart list
coop-cli cart add <product-id> [qty]
coop-cli cart remove <product-id>
coop-cli cart clear
Product IDs come from search results.
Self-update
coop-cli update
Workflow
When the user asks to shop for groceries or manage their cart, follow this pattern:
- If no store is configured, help them find one with
coop-cli stores <city or name>
- Search for products with
coop-cli search <query>
- Present results and let the user pick which products to add
- Add selected products with
coop-cli cart add <product-id> [qty]
- Show the cart with
coop-cli cart list to confirm
Tips
- Product names and search queries are in Swedish (e.g., "mjolk" for milk, "brod" for bread)
- The comparative price (e.g., "kr/kg" or "kr/l") helps compare value across package sizes
- Cart operations return the full updated cart, so there's no need to call
cart list after cart add