
2. Stateless API design for self-correcting workflows
Most enterprise APIs are built on a “Request-Response” loop. The client asks, the server answers and the connection closes. This is a linear way of thinking. Agentic workflows, however, are non-linear. An agent might start a task, encounter a permission hurdle, pivot to a different data source and then circle back to the original task.
In this environment, “state” is everything. If your APIs are too rigid, the agent loses the thread of the conversation the moment a timeout occurs. We need to move toward asynchronous, event-driven architectures (EDA).
- The change: Agents should interact with a “message bus” (like Apache Kafka or Amazon EventBridge) rather than making direct, blocking calls to a legacy database.
- The benefit: This allows for “Long-Running Tasks.” An agent can trigger an action, go “sleep” while waiting for a third-party verification and resume exactly where it left off when the event is published back to the bus.
IT playbook tip: Stop “bolting on” agents to legacy REST APIs. Instead, build an abstraction layer — an “agent gateway” — that converts synchronous legacy responses into asynchronous events that your agents can subscribe to.

