REST API
An architectural style for web APIs that models functionality as resources accessed via HTTP methods.
REST API
A REST API, short for Representational State Transfer API, is an architectural style for designing web services in which functionality is modeled as a set of resources, each identified by a URL, and manipulated through a small set of standard HTTP methods such as GET, POST, PUT, PATCH, and DELETE. It has become the default convention for exposing a system's capabilities over HTTP in a way that is predictable and usable from virtually any programming language or tool.
Core principles
- Resources, not actions: a REST API exposes nouns, such as an agent or a task, addressed by URLs, rather than remote procedure calls named after verbs.
- Standard HTTP methods: the meaning of an operation, whether it reads, creates, updates, or deletes a resource, comes from the HTTP method used, not from the URL alone.
- Statelessness: each request contains everything the server needs to process it, so the server does not need to remember prior requests from the same client.
- Standard status codes and representations: responses use HTTP status codes to indicate success or failure, and typically return resources as JSON.
Why it matters for AI agent systems
An AI agent platform needs to expose operations such as creating an agent, submitting a task, checking status, and managing its lifecycle, to a wide range of clients: a web console, command-line tools, CI pipelines, and other backend services. A REST API gives all of those clients a single, consistent interface, built on tooling and conventions that already exist in every mainstream language, rather than requiring a bespoke protocol or client library. It also makes agent operations scriptable and automatable: any action available through a graphical interface can, in principle, be triggered the same way by a script or another system, which matters for operators who want to integrate agent management into existing infrastructure and deployment pipelines.
REST API in Agenhood
Everything the Agenhood web console can do, creating agents, submitting tasks, and moving agents through their lifecycle with actions like pause, resume, archive, and restore, is also available as a REST API. The console is effectively one client of that API among many, and operators can build their own tooling or automation on top of the same interface without being limited to the console itself.