NAME
picnic - Command-line interface for Picnic Supermarket API
VERSION
version 0.100
SYNOPSIS
picnic [options] <command> [arguments]
# Using environment variables (recommended)
export PICNIC_USER='your@email.com'
export PICNIC_PASS='yourpassword'
export PICNIC_COUNTRY='de' # optional, defaults to 'de'
export PICNIC_LANG='en' # optional, defaults to 'en'
picnic user # Show user info
picnic cart # Show shopping cart
picnic search haribo # Search for products
picnic add s1234567 2 # Add 2 of product to cart
picnic add "Haribo Cola" # Add by product name
picnic slots # Show delivery slots
# Or with command-line options
picnic --user your@email.com --pass secret user
DESCRIPTION
picnic is a command-line interface for the Picnic supermarket delivery service API. It allows you to search for products, manage your shopping cart, view delivery slots, and more.
Picnic operates in Germany (de) and the Netherlands (nl). Use the PICNIC_COUNTRY environment variable or --country option to select your region.
For convenience, language-specific wrappers are available:
picnic-de- German defaults (PICNIC_LANG=de, PICNIC_COUNTRY=de)picnic-nl- Dutch defaults (PICNIC_LANG=nl, PICNIC_COUNTRY=nl)
OPTIONS
- -u, --user email
-
Picnic account email address. Can also be set via
PICNIC_USERenvironment variable. - -p, --pass password
-
Picnic account password. Can also be set via
PICNIC_PASSenvironment variable. - -c, --country code
-
Two-letter country code:
de(Germany) ornl(Netherlands). Defaults tode. Can also be set viaPICNIC_COUNTRYenvironment variable. - -r, --raw
-
Output raw JSON response instead of formatted text. Useful for scripting or debugging.
- -h, --help
-
Show help message and exit.
COMMANDS
login
picnic login
Test authentication with the Picnic API. If two-factor authentication is required, you will be prompted to enter the SMS code sent to your phone.
user
picnic user
Display your Picnic account information including name, email, phone number, and delivery address.
cart
picnic cart
Display the contents of your shopping cart, including items, quantities, and total price.
clear-cart
picnic clear-cart
Remove all items from your shopping cart.
slots
picnic slots
Display available delivery time slots. The output shows each day with available time windows. Multiple end times for the same start time indicate different slot durations (e.g., 1-hour vs 2-hour delivery windows).
Example output:
Available delivery slots: 12
Mon 13.01. 12:00 15:40 21:10
-13:00 -16:40 -22:10
-13:50 -17:30 -23:00
search term
picnic search haribo
picnic search "organic milk"
Search for products by name or keyword. Results show product ID, name, price, and quantity.
article product_id
picnic article s1234567
Display detailed information about a specific product including description, price, unit quantity, and maximum order quantity.
add product_id_or_name [count]
picnic add s1234567
picnic add s1234567 3
picnic add "Haribo Tropifrutti"
picnic add "Haribo Tropifrutti" 2
Add a product to your shopping cart. You can specify either:
A product ID (e.g.,
s1234567)A product name (will search and add if exactly one match is found)
If the product name matches multiple products, a list of matches will be shown and you'll need to be more specific or use the product ID.
The optional count parameter specifies the quantity (default: 1).
remove product_id [count]
picnic remove s1234567
picnic remove s1234567 2
Remove a product from your shopping cart. The optional count parameter specifies how many to remove (default: 1).
categories [depth]
picnic categories
picnic categories 2
List product categories. The optional depth parameter controls how many levels of subcategories to include (default: 0). Output is raw JSON.
suggest term
picnic suggest har
Get search suggestions for a partial search term. Useful for autocomplete functionality. Output is raw JSON.
ENVIRONMENT VARIABLES
- PICNIC_USER
-
Your Picnic account email address. Required.
- PICNIC_PASS
-
Your Picnic account password. Required.
- PICNIC_COUNTRY
-
Country code:
de(Germany) ornl(Netherlands). Default:de. - PICNIC_LANG
-
Output language:
en(English),de(German), ornl(Dutch). Default:en.
LOCALIZATION
The CLI supports three languages:
English (en) - Default
German (de) - Set
PICNIC_LANG=deDutch (nl) - Set
PICNIC_LANG=nl
For convenience, use picnic-de or picnic-nl which set both the language and country automatically.
TWO-FACTOR AUTHENTICATION
If your Picnic account requires two-factor authentication, the CLI will automatically:
- 1. Detect that 2FA is required
- 2. Request an SMS code to be sent to your phone
- 3. Prompt you to enter the code
- 4. Complete authentication
This happens automatically when you run any command that requires authentication.
EXAMPLES
# Set up credentials
export PICNIC_USER='max@example.com'
export PICNIC_PASS='secret123'
# Search for products
picnic search "Bio Milch"
# Add product to cart by ID
picnic add s1021517
# Add product to cart by name
picnic add "Haribo Goldbären" 2
# View cart
picnic cart
# Check delivery slots
picnic slots
# Use German interface
PICNIC_LANG=de picnic slots
# Or use the German wrapper
picnic-de slots
SEE ALSO
picnic-de, picnic-nl, WWW::Picnic
SUPPORT
Issues
Please report bugs and feature requests on GitHub at https://github.com/Getty/p5-www-picnic/issues.
IRC
You can reach Getty on irc.perl.org for questions and support.
CONTRIBUTING
Contributions are welcome! Please fork the repository and submit a pull request.
AUTHOR
Torsten Raudssus <torsten@raudssus.de>
COPYRIGHT AND LICENSE
This software is copyright (c) 2025 by Torsten Raudssus.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.