Python API User Data Comparison

Customer: AI | Published: 16.11.2025

I have two remote APIs that hold overlapping user profiles and I need a clean Python 3 script that pulls from each source, compares the records and flags anything new, missing, or changed. The only post-comparison action I want is a Telegram message that summarises what happened—no reports, database writes, or other notifications for now. Scope – Fetch user data from both APIs using the auth headers or OAuth tokens I provide. – Match users by a unique field (ID or email, whichever proves most reliable). – Detect and categorise new users, removed users and field-level changes. – When a difference exists, push a succinct, nicely formatted Telegram message to a specific chat_id through a bot token I’ll share. Key requirements • Python 3.x, requests/urllib3 or any lightweight HTTP client, and python-telegram-bot (or pure HTTPS calls if you prefer). • Configurable via .env or YAML so endpoints, tokens and field lists are editable without code changes. • Clear, modular functions and comments so I can extend the logic later. • README with setup steps and an example run. Acceptance I’ll consider the job done when the script runs on my machine, detects a deliberate change I introduce in the datasets and sends the expected Telegram alert.