Skip to main content

CLI for browsing Allegro offers, managing cart, and tracking packages — human-readable and LLM-agent friendly

Project description

allegro-cli

CI

CLI for browsing Allegro offers, managing your cart, and tracking packages. Designed to be both human-readable and LLM-agent friendly.

All output is available as aligned text tables, JSON, or TSV — pick what suits your workflow or pipe it into other tools.

Install

From GitHub Releases (recommended):

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

From source (latest):

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

For development:

git clone https://github.com/pkonowrocki/allegro-cli.git
cd allegro-cli
pip install -e ".[dev]"

Setup

Import cookies from your browser:

allegro login

Paste cookies from Chrome DevTools (Application > Cookies > allegro.pl). Both the DevTools table format and raw cookie header strings are accepted.

Alternatively, set cookies directly:

allegro config set --cookies 'cookie1=value1; cookie2=value2'

Usage

Search

allegro search "laptop"
allegro search "laptop" --category 491
allegro search "laptop" --category laptopy-491 --sort pd --price-min 2000 --price-max 5000
allegro search "laptop" --columns "id,name,sellingMode.price.amount,parameters"
Flag Description
--category Category ID or slug (e.g. 491, laptopy-491)
--sort Sort order: p (price asc), pd (price desc), m (relevance), n (newest)
--price-min Minimum price in PLN
--price-max Maximum price in PLN
--page Page number (default: 1)
--columns Comma-separated columns to display

Offer details

allegro offer 12345678
allegro offer 12345678 --columns "name,sellingMode.price.amount,parameters"

Offer pages include a parameters field with product specifications (e.g. processor, RAM, screen size) extracted automatically from the listing.

Cart

allegro cart list
allegro cart add OFFER_ID SELLER_ID --quantity 2
allegro cart remove OFFER_ID SELLER_ID

Packages

allegro packages

Configuration

allegro config show
allegro config set --output-format json
allegro config set --flaresolverr-url http://localhost:8191/v1

Output formats

All commands support --format text (default), --format json, and --format tsv.

allegro search "laptop" --format json     # full JSON array
allegro search "laptop" --format tsv      # tab-separated, pipe-friendly
allegro search "laptop"                   # aligned text table (default)
allegro offer 12345678 --format json      # full offer with parameters

Use --columns to select specific fields (dot-notation supported):

allegro search "laptop" --columns "id,name,sellingMode.price.amount"
allegro offer 12345678 --columns "name,parameters"

Set a persistent default:

allegro config set --output-format json

Anti-bot handling

Allegro uses anti-bot protection (DataDome). The CLI first tries a direct request with your cookies via curl_cffi (Chrome TLS fingerprint). If that gets a 403, it falls back to FlareSolverr:

docker run -d --name flaresolverr -p 8191:8191 ghcr.io/flaresolverr/flaresolverr:latest

Development

pip install -e ".[dev]"
pytest

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

allegro_cli-0.2.0.tar.gz (25.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

allegro_cli-0.2.0-py3-none-any.whl (20.9 kB view details)

Uploaded Python 3

File details

Details for the file allegro_cli-0.2.0.tar.gz.

File metadata

  • Download URL: allegro_cli-0.2.0.tar.gz
  • Upload date:
  • Size: 25.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for allegro_cli-0.2.0.tar.gz
Algorithm Hash digest
SHA256 021e77782fedcabba76cb57e2688b04b2046fd15ddb2ef9206a4779cfe0935be
MD5 6d1605141a6bc1116f5e42d3b1fc7d5b
BLAKE2b-256 650931e3cade246d27098853e1cdab968f3b8566aaa9994f712be76f027c128f

See more details on using hashes here.

Provenance

The following attestation bundles were made for allegro_cli-0.2.0.tar.gz:

Publisher: release.yml on pkonowrocki/allegro-cli

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file allegro_cli-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: allegro_cli-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 20.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for allegro_cli-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 36cebb817a6c3d13bdc4a1fb56b747e463236ed17bdb1df649b5f7460cc20d3a
MD5 c337b8862f8fe59c0a3c12f848cfcfdb
BLAKE2b-256 c4292e923b5c32682e25d1a4b9fcfb35b5a08916087b9e562cbe20987d736a9a

See more details on using hashes here.

Provenance

The following attestation bundles were made for allegro_cli-0.2.0-py3-none-any.whl:

Publisher: release.yml on pkonowrocki/allegro-cli

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page