Skip to main content

AI Marketplace Monitor

PyPI - Version PyPI - Python Version Tests Codecov Read the Docs PyPI - License

Black pre-commit Contributor Covenant

An intelligent tool that monitors Facebook Marketplace listings using AI to help you find the best deals. Get instant notifications when items matching your criteria are posted, with AI-powered analysis of each listing.

📚 Read the Full Documentation

Search In Action

Example notification from PushBullet:

Found 1 new gopro from facebook
[Great deal (5)] Go Pro hero 12
$180, Houston, TX
https://facebook.com/marketplace/item/1234567890
AI: Great deal; A well-priced, well-maintained camera meets all search criteria, with extra battery and charger.

What's New

  • Guided Facebook login: aimm types your Facebook username and password, then waits for you to complete any CAPTCHA or security code before it searches. In Docker, the web UI shows a banner with an Open browser button. See Run the Monitor.
  • AI-assisted configuration: aimm configure guides users through AI services, marketplace searches, items, notifications, regions, translations, and monitor settings without hand-writing TOML.
  • UnitySVC for AI and notifications: Use one UnitySVC key for almost arbitrary AI models and 100+ notification channels. See AI Services and UnitySVC notification.
  • Built-in Web UI: Edit config, add AI backends, and monitor live logs from your browser — starts automatically with the monitor. See Web UI documentation.
  • Anthropic/Claude AI Backend: Use Claude models (e.g. claude-sonnet-5-5) to evaluate listings alongside OpenAI, DeepSeek, Gemini, and Ollama. See AI Services for configuration.
  • Configurable Rate Limiting: Rate limiting framework for all notification types with per-instance and global limits. Telegram notifications use optimized defaults automatically.

Table of Contents:

✨ Key Features

🔍 Smart Search

  • Search multiple products using keywords
  • Filter by price and location
  • Exclude irrelevant results and spammers
  • Support for different Facebook Marketplace layouts

🤖 AI-Powered

  • Intelligent listing evaluation
  • Smart recommendations
  • AI-assisted configuration editing with aimm configure and the Web UI Configure chat
  • Almost arbitrary AI models through UnitySVC, plus OpenAI, Anthropic, DeepSeek, Gemini, and Ollama
  • Self-hosted model option through Ollama

📱 Notifications

  • 100+ notification channels through UnitySVC
  • PushBullet, PushOver, Telegram, and Ntfy notifications
  • HTML email notifications with images
  • Customizable notification levels
  • Repeated notification options
  • Optional daily digest (digest_at) of searches, matches and rejected listings: the full digest by email, a short summary on push channels

🖥️ Web UI

  • Built-in config editor with TOML syntax highlighting
  • Live log streaming and filtering
  • A Listings table of every listing aimm evaluated, with its AI rating and why it was notified, rejected, or excluded
  • Add, edit, and delete config sections from your browser
  • No password required on localhost

Web UI

🌎 Location Support

  • Multi-city search
  • Pre-defined regions (USA, Canada, etc.)
  • Customizable search radius
  • Flexible seller location filtering

🚀 Quick Start

⚠️ Legal Notice: Facebook's EULA prohibits automated data collection without authorization. This tool was developed for personal, hobbyist use only. You are solely responsible for ensuring compliance with platform terms and applicable laws.

Installation

Requires Python 3.10 or higher. Check your version with python --version. If your system default is older, use pip3.10 (or pip3.11, pip3.12, etc.) instead of pip, or create a virtual environment with the correct version.

pip install ai-marketplace-monitor
playwright install

Configure with AI

Most users do not need to write a configuration file by hand. Set one AI provider key, then let aimm configure create or update ~/.ai-marketplace-monitor/config.toml through a guided conversation:

export OPENAI_API_KEY='your_openai_key'
# or: export ANTHROPIC_API_KEY='your_anthropic_key'
# or: export UNITYSVC_API_KEY='your_unitysvc_key'

# aimm searches only while logged in to Facebook
export FACEBOOK_USERNAME='you@example.com'
export FACEBOOK_PASSWORD='your_facebook_password'

aimm configure

aimm reads your Facebook username and password from FACEBOOK_USERNAME and FACEBOOK_PASSWORD (or from username and password in [marketplace.facebook]). They are required: aimm does not search without logging in.

aimm configure checks or creates the AI setup first, then asks what you want to configure: marketplace searches, items to watch, notifications, regions, translations, or monitor settings. It explains proposed changes and asks before writing them.

You can also jump directly to one section:

aimm configure ai
aimm configure marketplace
aimm configure item.gopro

Here is a real session that adds an item. aimm configure starts with a summary of what is already configured and what is still missing, drafts the item from one plain-language request, and shows the change before writing it:

$ aimm configure
Using [ai.anthropic].
Thinking...
AIMM: Hi! You have two AI services (Anthropic, and UnitySVC with qwen3.7-flash), a Facebook
Marketplace search around Houston, and notifications to you (user "me") via UnitySVC. The one thing
still missing is an item to search for, so aimm can't monitor anything yet. Want to start by adding
one?

You can say things like "I want to add an item" (e.g. "watch for a GoPro under $200"), "update my
marketplace settings", or "what can I configure?".
You: I want to watch for an action camera: a GoPro Hero 9 or newer, a DJI Osmo Action 3 or newer,
or an Insta360 X3, X4 or Ace Pro. Used is fine if it works, with no water damage and no scratched
lens. Preferably under $250. Same Houston area, check every 30 minutes.
Thinking...
Thinking...
Thinking...
Thinking...
New item "action_camera": GoPro Hero 9+, DJI Osmo Action 3+, Insta360 X3/X4/Ace Pro; used OK if
working, no water damage or scratched lens; max $250; checked every 30 minutes; Houston area (20
miles) from your existing marketplace.

 [item.action_camera]
 request = "Watch for an action camera (GoPro Hero 9+, DJI Osmo Action 3+, Insta360 X3/X4/Ace Pro),
 used OK if working, no water damage or scratched lens, preferably under $250, in the Houston area,
 checked every 30 minutes."
 search_phrases = ["gopro hero", "dji osmo action", "insta360 x3", "insta360 x4", "insta360 ace pro",
 "action camera"]
 description = "Action camera: GoPro Hero 9 or newer, DJI Osmo Action 3 or newer, or Insta360 X3,
 X4 or Ace Pro. Used is fine if it works. No water damage and no scratched lens."
 keywords = ["gopro", "go pro", "dji", "osmo", "insta360"]
 max_price = "250"
 search_interval = "30m"

 (a diff of ~/.ai-marketplace-monitor/config.toml follows)

Write these changes? [Y/n] y
Saved ~/.ai-marketplace-monitor/config.toml.
Thinking...
AIMM: I've saved the action camera item. It covers GoPro Hero 9+, DJI Osmo Action 3+ and Insta360
X3/X4/Ace Pro. It accepts used cameras that work, with no water damage or scratched lens. The price
limit is $250, and it's checked every 30 minutes in your Houston area (20 miles). I set the price as
a hard limit. I can't make it a soft preference.

Is there anything else you'd like to change?
You: No, that's all. Thanks.
Thinking...
AIMM: All done. Enjoy the hunt!
Your configuration is saved, but nothing is searching yet: run `aimm run` to start monitoring (a
monitor that is already running picks up the change on its own).

Run the Monitor

aimm

What happens next:

  1. aimm opens a browser window, goes to Facebook, and types your username and password.
  2. If Facebook asks for a CAPTCHA or a security code, complete it in that window. aimm waits as long as it takes (the web UI shows a "waiting for Facebook login" banner) and reminds you in the log every few minutes.
  3. Once you are logged in, aimm searches Facebook Marketplace and notifies you of matching items. If Facebook logs it out later, it waits for you the same way.

A web UI also starts automatically at http://127.0.0.1:8467 for editing config and monitoring logs — see Web UI Guide. Its ⏸ button pauses searches and ▶ resumes them. aimm is the same as aimm run; ai-marketplace-monitor provides the same interface.

aimm always shows its browser, because Facebook may ask you to complete a CAPTCHA or a security code. To run aimm on a server, a NAS or another machine without a screen, use the Docker image: it has a virtual display, and the web UI shows you its browser when you need it.

Run with Docker

A prebuilt Linux image is published to GitHub Container Registry. It bundles Python, Playwright Chromium, a virtual display (Xvfb), and an embedded noVNC client so you can solve Facebook CAPTCHAs / interactive logins from the web UI — useful on macOS, headless servers, or NAS boxes.

docker run -d --name aimm \
  -p 8467:8467 \
  -v "$HOME/.ai-marketplace-monitor:/root/.ai-marketplace-monitor" \
  -e FACEBOOK_USERNAME -e FACEBOOK_PASSWORD \
  -e UNITYSVC_API_KEY \
  --restart unless-stopped \
  ghcr.io/bopeng/ai-marketplace-monitor:latest

FACEBOOK_USERNAME, FACEBOOK_PASSWORD, and UNITYSVC_API_KEY (if applicable) are environment variables defined locally, referenced from $HOME/.ai-marketplace-monitor/config.toml, and passed to the container by the -e flags above.

After the container starts:

  1. Open http://localhost:8467 and sign in to the aimm web UI with your Facebook username and password, the same values you passed as FACEBOOK_USERNAME and FACEBOOK_PASSWORD. When Docker exposes the web UI, they also protect the in-container browser from outside access.
  2. Meanwhile, aimm logs in to Facebook in its own browser inside the container and types your username and password. If Facebook asks for a CAPTCHA or a security code, a yellow banner appears at the top of the web UI: click Open browser to see that browser in a new tab, and complete the check there. (The Browser button in the header opens the same view at any time.)
  3. aimm waits as long as it takes and starts searching once you are logged in. You can then close the browser tab; the monitor keeps running in Docker. The ⏸ button in the header pauses searches whenever you need the browser to yourself; ▶ resumes them.

If the page does not load, check docker logs aimm. The web UI requires credentials when it is exposed from Docker; make sure FACEBOOK_USERNAME and FACEBOOK_PASSWORD contain only the intended login values before starting the container.

Mounting ~/.ai-marketplace-monitor shares your existing config, cache, and logs between the host install and the container — so you can switch between them (one at a time; see below).

When a new release is out, the web UI header shows ⬆ aimm X available, which opens Settings with an Update button. It installs the release inside the container and restarts aimm, and the page reloads when it is back. The update lives in the container: it survives docker restart, but recreating the container from an older image brings back the old version (the button then offers the update again).

To update the image itself, pull it and recreate the container — docker restart keeps running the old image:

docker pull ghcr.io/bopeng/ai-marketplace-monitor:latest
docker rm -f aimm

then run the docker run command above again. Your config, cache, and logs live in the mounted directory, so nothing is lost. The web UI header shows the running version, as does docker exec aimm ai-marketplace-monitor --version.

While the container is running, run other aimm commands inside it, e.g. docker exec -it aimm aimm check <listing>, not on the host: aimm's cache is an SQLite database, and an aimm on the host and one in the container writing it through the shared folder at the same time can damage it. If that happens, aimm stops with "cannot be read"; clear the cache with docker exec aimm aimm admin --clear-cache all and restart the container. To check your notifications, use Send test in Settings or docker exec aimm aimm admin --test-notification.

To build the image yourself instead of pulling: docker build -t aimm . from a checkout of this repo.

💡 Example Usage

These are examples of configuration sections that aimm configure can create or update for you. Advanced users can still edit the TOML file directly.

Find GoPro cameras under $300:

[item.gopro]
search_phrases = 'Go Pro Hero'
keywords = "('Go Pro' OR gopro) AND (11 OR 12 OR 13)"
min_price = 100
max_price = 300

Search nationwide with shipping:

[item.rare_item]
search_phrases = 'vintage collectible'
search_region = 'usa'
delivery_method = 'shipping'
seller_locations = []

AI-powered filtering:

[ai.openai]
api_key = 'your_openai_key'

[item.camera]
description = '''High-quality DSLR camera in good condition.
Exclude listings with water damage or missing parts.'''
rating = 5  # Only notify for great deals (default: 4+)

Alerts on your phone and by email, plus a daily digest:

[user.me]
email = 'me@gmail.com'
notify_with = ['unitysvc', 'gmail']
# every morning at 8: a summary of everything aimm did in the last 24 hours,
# in full by email and as a short message on your phone
digest_at = '08:00'

[notification.unitysvc]
unitysvc_api_key = '${UNITYSVC_API_KEY}'

[notification.gmail]
smtp_password = '${GMAIL_APP_PASSWORD}'

📚 Documentation

For detailed information on setup and advanced features, see the comprehensive documentation:

Key Topics Covered in Documentation

Notification Setup:

  • UnitySVC notification catalog with 100+ channels, plus Email (SMTP), PushBullet, PushOver, Telegram, and Ntfy
  • Multi-user configurations
  • HTML email templates

AI Integration:

  • AI-assisted configuration editing with aimm configure
  • UnitySVC access to almost arbitrary AI models, plus OpenAI, DeepSeek, Gemini, Anthropic, and Ollama setup
  • Custom prompt configuration
  • Rating thresholds and filtering

Advanced Search:

  • Multi-city and region search
  • Currency conversion
  • Keyword filtering with Boolean logic
  • Searching through a proxy

Configuration:

  • TOML file structure
  • Environment variables
  • Multiple marketplace support
  • Language/translation support

🤝 Contributing

Contributions are welcome! Here are some ways you can contribute:

  • 🐛 Report bugs and issues
  • 💡 Suggest new features
  • 🔧 Submit pull requests
  • 📚 Improve documentation
  • 🏪 Add support for new marketplaces
  • 🌍 Add support for new regions and languages
  • 🤖 Add support for new AI providers
  • 📱 Add new notification methods

Please read our Contributing Guidelines before submitting a Pull Request.

📜 License

This project is licensed under the Affero General Public License (AGPL). For the full terms and conditions, please refer to the official GNU AGPL v3.

💬 Support

We provide multiple ways to access support and contribute to AI Marketplace Monitor:

  • 💬 Discord - Ask questions, share your searches, and hear about new releases (no GitHub account needed)
  • 📖 Documentation - Comprehensive guides and instructions
  • 🤝 Discussions - Community support and ideas
  • 🐛 Issues - Bug reports and feature requests
  • 💖 Become a sponsor - Support development
  • 💰 Donate via PayPal - Alternative donation method

Important Note: Due to time constraints, priority support is provided to sponsors and donors. For general questions, please join us on Discord or use GitHub Discussions; report bugs as GitHub Issues.

🙏 Credits

Metadata

Release files for ai-marketplace-monitor 0.10.9

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

Source distribution (sdist)

Source distribution for ai-marketplace-monitor 0.10.9
File Size Uploaded
ai_marketplace_monitor-0.10.9.tar.gz 8.1 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for ai-marketplace-monitor 0.10.9
File Interpreter ABI Platform
ai_marketplace_monitor-0.10.9-py3-none-any.whl Python 3 none any Details

Total release size: 8.6 MB

Release files / ai_marketplace_monitor-0.10.9.tar.gz

Download URL ai_marketplace_monitor-0.10.9.tar.gz
Size 8.1 MB
Tags Source
SHA-256 checksum
How to use checksums
8a7b4597b4c4c5cd5bea0d26044f58279bdf307a6c366900c58553f095b098cb
BLAKE2b-256 checksum
How to use checksums
2e47432b08f2528043aa39ad1127590a40df3904e51c9084d975cdcf76fc83fe
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 Oct 8, 2026.

Transparency log

Release files / ai_marketplace_monitor-0.10.9-py3-none-any.whl

Download URL ai_marketplace_monitor-0.10.9-py3-none-any.whl
Size 487.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
2f3024b4ec90211590aaa2bb9f17b4cd6c9abff5cded4ad1eb0f4b06d6c1608d
BLAKE2b-256 checksum
How to use checksums
63ecb971cdb0a557c69bdc1e67cb00d6f85b9e1ee4969d65340f7461e3267961
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 Oct 8, 2026.

Transparency log
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