Skip to main content

🛒 allegro-cli

CI License: MIT Python 3.10+

The power-user's gateway to Allegro.

allegro-cli is a high-performance command-line interface for browsing offers, managing carts, and tracking packages on Allegro.pl. It is designed for two types of users: power-users who want to automate their shopping and AI Agents who need structured, token-efficient access to marketplace data.


✨ Key Features

  • 🚀 Agent-First Design: Optimized JSON outputs (--compact) to minimize LLM token usage while maximizing data density.
  • 🎨 Rich UX: Beautifully formatted, color-coded tables for humans.
  • 🔍 Advanced Filtering: Precision search with filters for condition, free shipping, Allegro Smart, and delivery speed.
  • 📦 Full Tracking: Detailed package tracking beyond simple summaries.
  • 🛡️ Bot Bypass: CloakBrowser (source-patched Chromium) defeats DataDome/Cloudflare with 58+ C++ fingerprint patches — no external solver needed.
  • 🛠️ Extensible: Pure Python implementation, easy to integrate into larger automation pipelines.

🚀 Quick Start

Installation

From GitHub Releases (recommended):

pip install https://github.com/pkonowrocki/allegro-cli/releases/latest/download/allegro_cli-0.6.0-py3-none-any.whl

From source (latest):

pip install git+https://github.com/pkonowrocki/allegro-cli.git

Setup

To access personalized data (cart, packages), you need to provide your session cookies:

allegro login

Follow the prompt to paste your cookies from Chrome DevTools (Application $\rightarrow$ Cookies $\rightarrow$ allegro.pl).


📖 Usage

🔍 Search for Products

Find exactly what you need with advanced filters:

# Basic search
allegro search "kawa ziarnista"

# Power-user search: New, with Allegro Smart, delivered in 1 day, sorted by price ascending
allegro search "kawa ziarnista" --condition new --smart --delivery-time one_day --sort p

# Filter by custom criteria (e.g., specific brand or parameter)
allegro search "laptop" --filter "marka=Apple"

# Search on a specific seller's page
allegro search "kawa" --seller Muvepl

# Price range
allegro search "laptop" --price-min 1000 --price-max 3000

# Allegro Pay offers only
allegro search "iphone" --pay

Search Flags:

Flag Description Examples
--category Category ID or slug 491, laptopy-491
--sort p (price ↑), pd (price ↓), m (relevance), n (newest) --sort pd
--condition Product condition (can specify multiple) --condition new, --condition new used
--smart Filter for Allegro Smart --smart
--free-shipping Alias for --smart (Allegro Smart) --free-shipping
--delivery-time Delivery speed one_day, two_day, three_day
--price-min Minimum price in PLN --price-min 100
--price-max Maximum price in PLN --price-max 500
--seller Search on seller's page --seller Muvepl
--pay Filter for Allegro Pay --pay
--location Shipping location --location polska
--filter Key=Value custom filter (repeatable) --filter "color=black"
--columns Custom output columns --columns id,name,seller.name

📦 Manage Your Shopping

Offers:

# Get full details and extracted product specifications
allegro offer 12345678

Cart:

allegro cart list                      # View current items
allegro cart add OFFER_ID              # Add item to cart (seller auto-detected)
allegro cart add OFFER_ID SELLER_ID    # Add item with explicit seller
allegro cart add OFFER_ID --quantity 3 # Add multiple units
allegro cart remove OFFER_ID           # Remove item from cart

Tracking:

allegro packages            # List all active shipments with detailed status

Claude Code Skill:

allegro skill               # Install as a Claude Code skill (auto-discovered by agents)

🤖 For AI Agents (LLM Optimization)

If you are building an AI agent, use the --format json and --compact flags. The compact mode strips unnecessary metadata to save tokens while keeping all critical data points — including the smart field that indicates Allegro Smart eligibility (free delivery).

allegro search "mechanical keyboard" --format json --compact

Compact search output includes: id, name, price, seller, url, smart Compact offer output includes: id, name, price, seller, url, smart, parameters

Allegro Smart

Allegro Smart! is a subscription (59.90 PLN/yr) giving unlimited free delivery on eligible offers above 49.90 PLN. The smart field in compact output shows whether an offer qualifies. Use --smart or --free-shipping to filter for Smart-eligible offers.

Install as a Claude Code Skill

To auto-register the CLI as a Claude Code skill (so AI agents discover it automatically):

allegro skill

🛠️ Development

# Install dev dependencies
pip install -e ".[dev]"

# Run the test suite (including Mock Client tests)
pytest

📜 License

Distributed under the MIT License. See LICENSE for more information.

Release files for allegro-cli 0.8.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for allegro-cli 0.8.0
File Size Uploaded
allegro_cli-0.8.0.tar.gz 36.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for allegro-cli 0.8.0
File Interpreter ABI Platform
allegro_cli-0.8.0-py3-none-any.whl Python 3 none any Details

Total release size: 65.9 kB

Release files / allegro_cli-0.8.0.tar.gz

Download URL allegro_cli-0.8.0.tar.gz
Size 36.1 kB
Tags Source
SHA-256 checksum
How to use checksums
488210b5a92a605a51738b1c8a4b70b1e9b5abf7c81889485fc8252b00362e30
BLAKE2b-256 checksum
How to use checksums
a0ddcb33ba9000bef55324ec387ea5cc49a4589346e6c8ad4a42c253d2e39678
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 14, 2026.

Transparency log

Release files / allegro_cli-0.8.0-py3-none-any.whl

Download URL allegro_cli-0.8.0-py3-none-any.whl
Size 29.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c753df90e997c2a12870b23a986dbca69a2f0b1c8b585fd1578bc37dbe9d9fe3
BLAKE2b-256 checksum
How to use checksums
e1fb2cafa2302ce7cf37857634558db36d14ce9a5fc5c0697e25f3a1bf1608d1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 14, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.8.0 This release

2 release files

0.7.1

2 release files

0.2.0

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page