Weekly digestSubscribeSerpApi Track 1 on GitHub
Run the digest
Python 3.10 or newer. The tool plans a date window, searches, compares the hits, and prints a digest. Teams and Slack post only when their keys are set.


Install
From the repo root, create a virtual environment and install the requirements.
python -m venv .venvWindows PowerShell, after the environment exists:
.\.venv\Scripts\Activate.ps1
python -m pip install -r requirements.txt
Copy-Item .env.example .envIf script activation is blocked, open cmd and run .venv\Scripts\activate.bat instead.
Unix:
source .venv/bin/activate
python -m pip install -r requirements.txt
cp .env.example .envKeys
Copy .env.example to .env and fill in the names below. Do not commit .env. This page does not contain key values.
Required:
SERPAPI_API_KEYAZURE_OPENAI_ENDPOINTAZURE_OPENAI_KEY
AZURE_OPENAI_DEPLOYMENT selects the deployment. When it is empty, extraction uses gpt-5.3-chat.
Optional:
TEAMS_WEBHOOK_URL. Leave it empty to print the console summary and skip Teams.SLACK_BOT_TOKENandSLACK_CHANNEL_ID. Leave either empty to skip Slack. Posting needs both.SUPABASE_URL,SUPABASE_SECRET_KEY, andNEXT_PUBLIC_SUPABASE_PUBLISHABLE_KEY. Configures PostgreSQL subscriber delivery with Row-Level Security.
--dry-run needs SERPAPI_API_KEY. It does not need the Azure names, and it does not call Azure.
Health Check & Diagnostics
The production site exposes live service diagnostics for Supabase, SerpApi, Azure OpenAI, and the hosted execution model. Open Diagnostics & APIs from the homepage to inspect the current status.
Judge preview
The hosted page is the product preview. Start with Preview a digest to inspect the readable Teams and Slack outputs, then open Diagnostics & APIs to verify the live SerpApi, Azure OpenAI, and Supabase connections.
The Run Discovery Pipeline panel reports UNAVAILABLE on Vercel by design. Vercel serves the Next.js interface, but it does not package or keep a Python worker alive for a long scrape and extraction run. To execute a fresh digest during judging, open the Weekly digest GitHub Actionand choose Run workflow. The repository CLI is the local alternative.
Run
From the repo root, with the virtual environment active:
python main.pyFlags
--days- Date window in days. Default 7, or SEARCH_DAYS when the flag is omitted. Must be a positive integer.
--dry-run- Print the comparison table. Do not fetch pages, call Azure, or post to Teams or Slack.
--skip-teams- Skip the Teams webhook. Still print the console summary.
--skip-slack- Skip Slack even when the bot token and channel ID are set. Still print the console summary.
--skip-subscribers- Do not deliver the digest to signed-in Supabase subscribers.
--max-urls- Cap how many compared candidates are fetched and extracted. Must be a positive integer.
python main.py --days 7
python main.py --dry-run
python main.py --skip-teams
python main.py --skip-slack
python main.py --skip-subscribers
python main.py --days 7 --max-urls 3
python main.py --days 7 --max-urls 3 --skip-teams --skip-slack --skip-subscribersEdge cases
--days 0and a negative--daysexit with code 2. The message is--days must be a positive integer. There is no traceback and no search.--max-urls 0and a negative--max-urlsexit with code 2. The message is--max-urls must be a positive integer. The run does not print an empty table.- If one search engine fails, the run continues with the other. If both fail, the process exits non-zero.
--dry-runprints the comparison table and stops before fetch.- A missing Teams webhook, or
--skip-teams, skips Teams. A missing Slack token or channel, or--skip-slack, skips Slack. - Supabase subscriber webhooks must be valid HTTPS. Insecure endpoints are discarded.
Tests
From the repo root, with the virtual environment active:
python -m pytest tests -v