← Back to list

I Made $4,200 Last Month Automating Boring Tasks With Python + Claude

3 Python automations. Full production code. Real client numbers. No agency, no investors just a laptop and a free API key.

inprogrammer in Stackademic · 2026-05-20 14:31 · 263 claps · 9.3 min read paywalled
#python #agentic-ai #software-development #web-development #programming
Open on Medium ↗
Wiki topics: LLM · Large Language Models AGT · AI Agents 💻 · Programming 🌐 · Web Development

I Made $4,200 Last Month Automating Boring Tasks With Python + Claude

3 Python automations. Full production code. Real client numbers. No agency, no investors just a laptop and a free API key.

I’m not a startup founder. I don’t have a team or VC money. I’m a mid-level developer who found something most people are ignoring: the gap between what AI can do today and what most businesses are still doing manually.

That gap is enormous and right now, it’s paying well for anyone who knows a little Python.

Here’s exactly what I built, what I charged, and how you can replicate it this weekend.

Friend link for non members- https://medium.com/@inprogrammer/fed9f4dc76b4?source=friends_link&sk=05402d78121506ccbb0b7ff847f4a527

Where the $4,200 Actually Came From

Before we get into code, here’s the honest breakdown so you know this isn’t vague hype:

| Service                               | Clients / Projects  | Revenue      |
| ------------------------------------- | ------------------- | ------------ |
| Automation Clients                    | 4 recurring clients | $1,800/mo    |
| Document Intelligence                 | 3 recurring clients | $720/mo      |
| Local Review Responder                | 1 recurring client  | $280/mo      |
| Content Repurposing (one-time setups) | 2 projects          | $1,400 total |
| **Total Revenue**                     | —                   | **$4,200**   |

Three of those four are recurring. I do maybe 2 hours of maintenance a month total.

The Brutal Truth Nobody Tells You

Most “make money with AI” content is vague garbage. “Build a chatbot!” “Sell prompts!” “Start an agency!”

None of that tells you what code to write, who pays for it, or how much.

Here’s what actually works:

Businesses don’t need fancy AI. They need their existing workflows to stop wasting time and money.

That’s your opportunity. Find the boring, repetitive task. Automate it with Python + an LLM. Charge $200–$2,000 to set it up. Charge $50–$300/month to maintain it.

This is a service business, not a product. Products take years. Services pay next week.

Results I Got for Real Clients

Before you see the code, here’s the before/after on my first three clients:

| Client                              | Before                                                           | After                                                                   |
| ----------------------------------- | ---------------------------------------------------------------- | ----------------------------------------------------------------------- |
| 8-person accounting firm            | 40 hrs/month processing invoices manually                        | 45 minutes with script — 98% faster                                     |
| Dental clinic (22 locations)        | Owner reviewing ~60 Google reviews/week, responding to maybe 20% | 100% responded within 24 hours with automated drafts                    |
| E-commerce brand (Shopify, $2M ARR) | No structured data review, gut-feel decisions                    | Weekly plain-English reports; caught a $14K inventory anomaly in week 2 |

These numbers are what close clients. Not promises demos.

The 3 Automations That Actually Pay

I’m keeping this to three. I dropped Email Triage (serious security/privacy risks with business inboxes) and trimmed Content Repurposing (too saturated). These three have the best combination of ticket size, ease of sale, and technical defensibility.

1. Document Intelligence — The $800 Weekend Project

What it does: Reads PDFs (contracts, invoices, reports) and extracts structured data into a spreadsheet automatically.

Who pays: Law firms, accounting firms, real estate agencies, insurance companies.

Why they pay: One paralegal reading contracts = $35/hr × 200 hrs/month = $7,000/month in labor. Your script does it in seconds.

What to charge: $500–$1,500 setup + $100–$200/month maintenance.

# requirements: anthropic pdfplumber pandas pydantic python-dotenv loguru
import json
from pathlib import Path
import anthropic
import pdfplumber
import pandas as pd
from pydantic import BaseModel, Field
from loguru import logger
from dotenv import load_dotenv
load_dotenv()
client = anthropic.Anthropic()
class LineItem(BaseModel):
    description: str
    amount: float
class InvoiceData(BaseModel):
    vendor_name: str
    invoice_number: str
    invoice_date: str
    total_amount: float
    line_items: list[LineItem] = Field(default_factory=list)
def extract_text_from_pdf(pdf_path: str) -> str:
    with pdfplumber.open(pdf_path) as pdf:
        pages = [page.extract_text() or "" for page in pdf.pages]
    return "\n".join(pages)
def extract_invoice_data(pdf_path: str) -> InvoiceData | None:
    logger.info(f"Processing: {pdf_path}")
    try:
        text = extract_text_from_pdf(pdf_path)
    except Exception as e:
        logger.error(f"Failed to read PDF {pdf_path}: {e}")
        return None
    if not text.strip():
        logger.warning(f"No extractable text in {pdf_path}")
        return None
    try:
        response = client.messages.create(
            model="claude-sonnet-4-5",
            max_tokens=1024,
            messages=[{
                "role": "user",
                "content": f"""Extract invoice fields and return ONLY valid JSON matching this schema:
{{
  "vendor_name": "string",
  "invoice_number": "string",
  "invoice_date": "YYYY-MM-DD",
  "total_amount": 0.00,
  "line_items": [{{"description": "string", "amount": 0.00}}]
}}
Invoice text:
{text[:4000]}
Return ONLY the JSON object. No markdown, no explanation."""
            }]
        )
        raw = response.content[0].text.strip()
        data = json.loads(raw)
        return InvoiceData(**data)
    except json.JSONDecodeError as e:
        logger.error(f"Failed to parse JSON from Claude response: {e}")
        return None
    except Exception as e:
        logger.error(f"Unexpected error processing {pdf_path}: {e}")
        return None
def process_invoice_folder(folder_path: str, output_csv: str = "invoices.csv") -> pd.DataFrame:
    folder = Path(folder_path)
    pdfs = list(folder.glob("*.pdf"))
    logger.info(f"Found {len(pdfs)} PDFs to process")
    records = []
    for pdf in pdfs:
        result = extract_invoice_data(str(pdf))
        if result:
            record = result.model_dump()
            record["source_file"] = pdf.name
            records.append(record)
        else:
            logger.warning(f"Skipped: {pdf.name}")
    df = pd.DataFrame(records)
    df.to_csv(output_csv, index=False)
    logger.success(f"Exported {len(df)} invoices to {output_csv}")
    return df
if __name__ == "__main__":
    df = process_invoice_folder("./invoices")
    print(df.head())

Deploy it: Drop this on Railway with a simple cron schedule. Use GitHub Actions to trigger a run whenever new files land in a watched S3 bucket or Google Drive folder. Total infrastructure cost: ~$5/month.

2. Local Business Review Responder — Easiest Sale You’ll Ever Make

What it does: Monitors Google Reviews and Yelp. When a new review appears, it drafts a personalized, professional response and emails it to the owner for one-click approval.

Who pays: Restaurants, salons, dentists, chiropractors, hotels — any local business with online reviews.

Why it’s an easy sell: Show them one example of a poorly handled negative review. Ask: “How much did that cost you in lost customers?” The answer is always “more than $100/month.”

What to charge: $150–$300/month per business. No setup fee makes it easier to close.

Math: 20 local businesses × $200/month = $4,000/month recurring. Fully automatable.

# requirements: anthropic pydantic python-dotenv loguru
import anthropic
from pydantic import BaseModel
from loguru import logger
from dotenv import load_dotenv
load_dotenv()
client = anthropic.Anthropic()
class ReviewResponse(BaseModel):
    draft_response: str
    tone_used: str  # "warm_apology" | "enthusiastic_thanks" | "professional_neutral"
    suggested_action: str | None  # e.g. "Offer 10% discount on next visit"
def generate_review_response(
    business_name: str,
    business_type: str,
    review_text: str,
    star_rating: int,
    reviewer_name: str,
) -> ReviewResponse | None:
    if star_rating >= 4:
        sentiment = "positive"
    elif star_rating <= 2:
        sentiment = "negative"
    else:
        sentiment = "mixed"
    try:
        response = client.messages.create(
            model="claude-sonnet-4-5",
            max_tokens=600,
            system=f"""You write professional, warm responses to customer reviews for {business_name}, 
a {business_type}. Sound human, not corporate. Never be defensive.
For negative reviews: acknowledge, apologize sincerely, offer a resolution path.
For positive reviews: thank specifically, reinforce what they loved.
Keep responses under 150 words.
Return ONLY valid JSON matching this schema:
{{
  "draft_response": "string",
  "tone_used": "warm_apology | enthusiastic_thanks | professional_neutral",
  "suggested_action": "string or null"
}}""",
            messages=[{
                "role": "user",
                "content": f"""Write a response to this {star_rating}-star {sentiment} review from {reviewer_name}:
"{review_text}"
Return only the JSON object."""
            }]
        )
        raw = response.content[0].text.strip()
        import json
        data = json.loads(raw)
        return ReviewResponse(**data)
    except Exception as e:
        logger.error(f"Failed to generate response: {e}")
        return None
# --- FastAPI webhook version (advanced) ---
# Pair this with a Google My Business API webhook:
# When a new review event fires → POST to your /webhook endpoint →
# generate response → email draft to owner via SendGrid.
# from fastapi import FastAPI, Request
# app = FastAPI()
#
# @app.post("/webhook/new-review")
# async def handle_new_review(request: Request):
#     payload = await request.json()
#     result = generate_review_response(
#         business_name=payload["business_name"],
#         business_type=payload["business_type"],
#         review_text=payload["review_text"],
#         star_rating=payload["star_rating"],
#         reviewer_name=payload["reviewer_name"],
#     )
#     if result:
#         # send_draft_email(owner_email, result)
#         return {"status": "draft_sent", "tone": result.tone_used}
#     return {"status": "error"}
if __name__ == "__main__":
    result = generate_review_response(
        business_name="Sunrise Dental",
        business_type="dental clinic",
        review_text="Waited 45 minutes past my appointment. The cleaning was fine but the front desk was rude.",
        star_rating=2,
        reviewer_name="Marcus T.",
    )
    if result:
        print(f"\nDraft:\n{result.draft_response}")
        print(f"\nTone: {result.tone_used}")
        print(f"Suggested action: {result.suggested_action}")

3. Data-to-Insight Report Generator — Your Highest-Ticket Offer

What it does: Takes raw business data (CSV exports from Shopify, QuickBooks, HubSpot) and generates a plain-English weekly or monthly report with key insights, anomalies spotted, and recommended actions.

Who pays: Small business owners with data but no analyst. E-commerce brands. Marketing teams.

What to charge: $300–$800/month. Position it as “your part-time data analyst.”

# requirements: anthropic polars python-dotenv loguru pydantic
import json
from pathlib import Path
import anthropic
import polars as pl  # faster than pandas for this use case
from loguru import logger
from dotenv import load_dotenv
load_dotenv()
client = anthropic.Anthropic()
def compute_statistics(df: pl.DataFrame) -> dict:
    """Extract key stats without sending raw data to the API."""
    stats = {
        "row_count": len(df),
        "columns": df.columns,
        "null_counts": {col: df[col].null_count() for col in df.columns},
        "numeric_summary": {},
        "sample_rows": df.head(5).to_dicts(),
    }
    for col in df.columns:
        if df[col].dtype in (pl.Float64, pl.Int64, pl.Float32, pl.Int32):
            stats["numeric_summary"][col] = {
                "mean": round(df[col].mean() or 0, 2),
                "median": round(df[col].median() or 0, 2),
                "std": round(df[col].std() or 0, 2),
                "min": df[col].min(),
                "max": df[col].max(),
            }
    return stats
def generate_business_report(
    csv_path: str,
    business_context: str,
    report_period: str = "last 30 days",
) -> str | None:
    logger.info(f"Loading data from {csv_path}")
    try:
        df = pl.read_csv(csv_path, infer_schema_length=500)
    except Exception as e:
        logger.error(f"Failed to read CSV: {e}")
        return None
    stats = compute_statistics(df)
    logger.info(f"Computed stats for {stats['row_count']} rows")
    try:
        response = client.messages.create(
            model="claude-sonnet-4-5",
            max_tokens=2000,
            system="""You are a senior business analyst writing clear, actionable reports 
for non-technical business owners. Use plain English. No jargon.
Lead with the single most important insight. 
Format with these sections: Executive Summary, Key Metrics, Anomalies & Risks, 3 Recommended Actions.
Recommended actions must be specific, ranked by expected impact, and immediately actionable.""",
            messages=[{
                "role": "user",
                "content": f"""Analyze this business data and write a concise executive report.
Business context: {business_context}
Report period: {report_period}
Data statistics:
{json.dumps(stats, indent=2, default=str)}
Write the full report."""
            }]
        )
        return response.content[0].text
    except Exception as e:
        logger.error(f"Claude API error: {e}")
        return None
def save_report(report: str, output_path: str = "business_report.md") -> None:
    Path(output_path).write_text(report, encoding="utf-8")
    logger.success(f"Report saved to {output_path}")
if __name__ == "__main__":
    report = generate_business_report(
        csv_path="./shopify_orders.csv",
        business_context="DTC skincare brand, ~$2M ARR, sells primarily via Shopify",
        report_period="April 2025",
    )
    if report:
        save_report(report)
        print(report[:500])  # preview

Tech upgrade note: I switched from pandas to polars on all data projects 3–10× faster on large CSVs, and clients notice when demo speed matters. Use uv to manage your project dependencies instead of pip for a far cleaner dev experience.

How to Get Your First Client in 7 Days

Most people build something, then wonder why nobody’s buying. Here’s the sequence that actually works:

Day 1–2: Pick ONE automation. Get it working locally with a real demo output.

Day 3: Record a 90-second Loom video showing it working on realistic fake data.

Day 4–5: Find 30 potential clients. For local businesses: Google Maps. For agencies: LinkedIn. For small businesses: local Facebook business groups.

Day 6: Send 20 outreach messages. Use this template:

“Hi [Name], I noticed [specific thing about their business]. I built a tool that [what it does] automatically took me a weekend. Made a 90-second demo showing it on sample data mind if I send it over? No pitch, just want to show you what’s possible.”

Day 7: Follow up with the demo link. Ask one question: “Is this a problem you’re currently solving manually?” Then close.

The Tech Stack That Keeps Costs Low

| Tool                   | Cost          | Purpose                               |
| ---------------------- | ------------- | ------------------------------------- |
| Anthropic API (Claude) | ~$10–50/month | The AI brain                          |
| Python 3.12 + uv       | Free          | Fast, clean dependency management     |
| Railway or Render      | $5–20/month   | Deploy scripts + cron jobs            |
| Polars                 | Free          | Faster data processing than pandas    |
| Pydantic v2            | Free          | Structured outputs + validation       |
| loguru                 | Free          | Proper logging (not print statements) |
| python-dotenv          | Free          | Secrets management                    |
| GitHub Actions         | Free tier     | Automation triggers                   |

Total infrastructure cost per client: ~$5–15/month. Charge $100–500/month. That’s your margin.

Legal & Ethical Considerations

This section isn’t optional reading. If you’re handling business data, you need to understand these risks before you take on a client:

Data Privacy

  • Invoices and contracts contain PII (names, addresses, financial info). Before sending client data to any third-party API, ensure your client agreement covers this and check whether the business is subject to GDPR, CCPA, or HIPAA.
  • Anthropic’s API has a data privacy policy — review it. For healthcare clients (dentists, clinics), you may need a Business Associate Agreement (BAA).

Email & Communications Access

  • I dropped the Email Triage bot from this guide for good reason: accessing a business’s inbox has significant legal exposure. If you do build email automation, use OAuth (not raw passwords), get explicit written permission, and store credentials securely — never in plain text.

Review Platforms

  • Google’s Terms of Service prohibit automated posting of reviews or responses using bots. The review responder in this guide generates drafts for human approval that’s the right approach. Don’t automate posting directly.

Contracts

  • Use a simple service agreement for every client. Specify what the tool does, what data you access, how it’s stored, and what happens when you offboard. Rocket Lawyer has templates for under $30.

If you’re unsure about any of this for a specific client, consult a lawyer. A $200 legal consultation is cheap compared to losing a client or getting sued.

What Separates People Who Make Money From People Who Don’t

It’s not coding skill. It’s not the AI model.

It’s this: people who make money ship ugly v1 solutions to real clients instead of building perfect v2 solutions for nobody.

Your first automation will be messy. It’ll break sometimes. Clients won’t care because it saves them time and money, which is the only thing they’re actually buying.

Start this weekend. Pick one automation. Find one client. Charge something.

The gap between what AI can do and what most businesses know is massive right now and it won’t stay that way forever.

If this gave you a concrete starting point, follow me for more Python + AI builds that actually make money. Real projects, real code, real numbers, no fluff.

A message from our Founder

Hey, Sunil here. I wanted to take a moment to thank you for reading until the end and for being a part of this community. Did you know that our team run these publications as a volunteer effort to over 3.5m monthly readers? We don’t receive any funding, we do this to support the community.

If you want to show some love, please take a moment to follow me on LinkedIn, TikTok, Instagram. You can also subscribe to our weekly newsletter. And before you go, don’t forget to clap and follow the writer️!


메타데이터
post_id
fed9f4dc76b4
slug
i-made-4-200-last-month-automating-boring-tasks-with-python-claude-fed9f4dc76b4
url
https://blog.stackademic.com/i-made-4-200-last-month-automating-boring-tasks-with-python-claude-fed9f4dc76b4
canonical_url
https://blog.stackademic.com/i-made-4-200-last-month-automating-boring-tasks-with-python-claude-fed9f4dc76b4
author_url
https://medium.com/@inprogrammer
status
ok
fetched_at
2026-06-09 15:37:30