Technical

How to automate API-less LatAm ERPs visually with Python and GPT-4o

Stop writing fragile HTML scrapers for DIAN and SAT. Learn how to build a Python agent that uses GPT-4o to visually navigate legacy desktop ERPs like a human.

KytoAI & Automation Firm
·
April 17, 2026
0

Key Takeaways

  • 1LatAm government portals actively break traditional DOM-based web scrapers.
  • 2Visual navigation bypasses fragile HTML entirely by calculating exact screen pixel coordinates.
  • 3You can automate legacy desktop ERPs like Siigo and TOTVS using Python for pennies per run.

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

DOM Timeouts

Portals like AFIP in Argentina use dynamic session tokens embedded deep in the HTML. Standard bots that attempt to parse the page structure fail instantly when the session drops unannounced.

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "mermaidDiagram", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

[@portabletext/react] Unknown block type "span", specify a component for it in the `components.types` prop

This week

1. Sign up for the OpenAI API (the pay-as-you-go tier requires less than $5 to start). 2. Install Python, `pyautogui`, and `mss` on your local Windows machine. 3. Run a 10-line script that takes a screenshot of your DIAN portal and asks GPT-4o to return the XY coordinates of the login button.

Frequently Asked Questions

Why do traditional bots fail on LatAm government portals?

Portals like SAT in Mexico or DIAN in Colombia use aggressive DOM timeouts, hidden session tokens, and CAPTCHAs that instantly break traditional HTML-parsing bots.

How does a visual agent work differently?

Instead of reading page code, a visual agent takes a screenshot of your desktop. It uses AI to find the exact pixel coordinates of a button and clicks it like a human user.

AutomationPythonGPT-4oRPALatAm
Share this article

Kyto

AI & Automation Firm

We design and build AI automations and business operating systems. Agency results + Academy sovereignty.

Ready to automate?

Let's Build Your Operating System.

Book a free discovery call to see how AI automation can transform your operations.

Book Discovery Call