Python Playwright Task Automation

Customer: AI | Published: 16.01.2026

I need a clean, well-structured Python script that leans on Playwright to eliminate a trio of repetitive chores: data entry, file handling, and basic system monitoring. Here’s the current pain-point flow I’d like you to replace: • Log in to a couple of web dashboards every morning, grab fresh figures, and punch them into forms or spreadsheets. • Shuffle inbound files into the correct folders and rename them consistently. • Ping two internal services (one REST API, one Postgres database) to confirm they’re alive, then push an “all clear” or “needs attention” status report. What I’m after – A single script (or tidy module set) written in modern Python that: • Uses Playwright for all browser actions—login, scrape, form fill, upload, download. • Talks directly to the database with proper credentials handling, and hits the REST endpoints to send/receive JSON. • Moves/renames files locally in a fault-tolerant way. • Logs meaningful events and surfaces errors immediately (console + optional email or Slack webhook is fine). Acceptance I’ll consider the job done when I can: 1. Drop my credentials and paths into a config file. 2. Run `python main.py` on Windows or Linux and watch every step complete unattended. 3. Read concise inline docs and a short README that show setup, dependency install, and how to extend or schedule the script with cron/Task Scheduler. If you’re comfortable juggling Playwright, databases, and APIs, let’s make this workflow disappear.