Yes, you can usually link an AI agent to an older ERP, an on-premise SQL database, desktop accounting software, or a core spreadsheet without replacing it. Start with the most stable path the system already supports, keep the agent read-only at first, and log every action.
This guide shows you how to choose a connection today, protect live records as you add write access, and catch quiet failures before they spread.
Answer four questions before picking a path
Before anyone builds a connector, work through four checks. They show which path fits and where the risk sits.
- Read versus write. Separate what the agent must look up from what it must change. Reading stock levels leaves live records intact. Check that the data is fresh enough for the decision. Creating orders carries real risk.
- Data freshness. Decide whether the job needs numbers from the last few minutes, the last hour, or yesterday.
- Vendor support. Check what the vendor allows and what would void your support agreement.
- Cost of a bad write. Decide what a wrong entry costs and how your team would find and undo it.
Talk to whoever administers the system before choosing. They usually know which reports already exist, which tables can be trusted, and which overnight jobs lock records.
Picture an illustration from a distributor running an on-premise ERP with no API. The order desk wants an agent to draft replies to customer order-status emails. The agent only needs to read, and data current within the hour works fine. A read-only database view of orders and shipments fits, and nothing writes back. If the business later wants to enter orders, a supported import file with human approval for each batch might fit.
Mixing methods is normal. A database read for lookups, a file import for writes, and email reading for one supplier that only sends attachments is a standard setup. Choose based on what the job needs and what the vendor allows. When fixed rules can move the data reliably, ordinary software often fits better. See agent or automation.
Start with the doors your old system already has
There are five standard ways into an older system, ranked from most reliable to least reliable. Prefer the most reliable supported path that meets the job’s needs. Does the supported API provide the access and freshness you need?
| Path | How it works | Main catch |
|---|---|---|
| Supported API | Vendor's built-in interface. | May need a module or upgrade. |
| Read-only database | Queries a reporting copy or views. | Undocumented fields; read-only. |
| Scheduled files | Exports reports; imports fixed files. | Delay means older data. |
| System email | Reads emails the system sends. | Breaks on template edits. |
| Screen automation | Clicks screens and types into fields. | Slowest and most fragile. |
Five ways into an older system
Check for an API first, even on an ERP installed twenty years ago. Many older systems have one that nobody on the current team has used. Sometimes it is a separate module or only on a newer release. A supported API is the strongest choice. It applies the system's own rules, respects permissions, and holds up best when the vendor ships updates.
With no usable API, a direct database read is usually next. Most on-premise systems store their data in a standard database. The agent connects through a read-only account, ideally to a reporting copy or views rather than live tables.
Direct reads are fast and complete, with three catches. The schema is often undocumented. Field meanings drift over the years. Many vendors do not support direct database writes. Writing around the application can skip its checks. Keep database access read-only unless the vendor documents a safe write path.
Use files, email, or screen clicks when there is no API
Almost every business system can export a report. A scheduled export to a secure shared folder gives an agent a regular snapshot to read. Many systems can also import a fixed-format file for controlled writes. The trade-off is delay. A nightly export leaves the agent working from yesterday's data. That fits a weekly reorder review and fails for checking stock on a live call.
Email is another way in. Older systems often email confirmations, alerts, and reports. An agent can read those messages while the system keeps working untouched. Because layout edits break parsing, the agent must flag any message it cannot read cleanly instead of guessing.
Screen-level automation is the last resort. Software drives the application like a clerk, clicking screens and typing into fields. It works on old desktop software with no export at all, though it is the slowest and most fragile option. A moved button, a new pop-up, or a slow screen can break it. Keep it to narrow steps, watch it closely, and look for a better path.
Treat a critical spreadsheet like a real database
In many businesses, daily work depends on a spreadsheet. The production schedule, pricing exceptions, and key accounts with their terms often live there.
Connecting an agent to a spreadsheet is easy. Keeping it reliable is harder, because adding one column changes the shape.
Put four rules around any spreadsheet an agent reads:
- One owner. Assign one person to approve layout changes.
- Fixed structure. Lock the column names, header row, and tabs the agent uses.
- Version history on. Keep a trail of every edit.
- Staging tab for writes. Spreadsheet permissions are coarse. Have the agent write to a staging tab that a person reviews and copies across, at least at first.
Doing this work often shows which spreadsheet data deserves a proper system later.
Start read-only, then earn write access
The safest first release reads from the old system and prepares work for a person. The agent checks a customer's order history, drafts an order entry, or builds a reorder list. Someone checks the draft and enters it. You see real accuracy without risking live records. For help choosing a first workflow, see where to start.
When drafts are consistently right, add one write action, usually with approval at first. Then add the next. Every write step should be reversible and tested against messy cases: duplicates, locked records, and half-finished entries. See how to test an AI agent.
From read-only to live writes
Permissions follow the same discipline. Give the agent its own service account, never a shared admin login or a staff member's credentials. Limit it to the exact tables, screens, or folders it needs. Store credentials in a secrets manager, never in a script, and name who rotates them.
Log every read and write in an audit trail: what the agent did, which record it touched, when, from which input, and who approved it. Old systems often have weak audit trails, and your setup should improve that record. When someone asks why an order changed, one lookup should answer.
Catch the quiet failures in a legacy system integration
Most failures in older connections happen quietly while work keeps moving.
An export job stops, and the agent works from stale data. A vendor update renames a column. Someone adds a status code the agent has never seen. A retry after a timeout creates a duplicate record. A screen tool types into the wrong field after an update, and nobody notices for a week.
Build five checks in from the start:
- Freshness alerts. Flag whenever incoming data is older than expected.
- Count and total checks. Compare row counts and totals between the source and what the agent read.
- Unique write keys. Tag every write with a unique key so retries cannot create duplicates.
- Stop and flag rules. Pause and alert a person on any unrecognized field, code, or layout.
- Daily reconciliation. Compare what the agent says it did with what the old system shows.
Quiet failures and checks that catch them
Plan for the old system's habits too. Overnight batch windows, maintenance outages, and records locked while someone has them open will break a fragile link. A setup that runs cleanly on a quiet Tuesday morning can still fail at month end.