Run agents on-demand via HTTP webhooks usingDocumentation Index
Fetch the complete documentation index at: https://docs.agentuse.io/llms.txt
Use this file to discover all available pages before exploring further.
agentuse serve. Integrate with external services, CI/CD pipelines, or any system that can make HTTP requests.
Quick Start
- Start the daemon:
- Trigger an agent via HTTP:
Serving Multiple Projects
AgentUse runs one serve daemon at a time. Repeat-C on that daemon to serve multiple project roots:
project, multi-project requests return 400 PROJECT_REQUIRED unless a default is set:
project fields override the default.
Global config
You can put serve defaults in~/.agentuse/config.json. See Configuration Files for the schema and CLI override behavior.
Environment isolation
Each project loads its own.env / .env.local in its worker process; env vars never mix across projects.
API Reference
GET /
Returns version, default project, and served projects.POST /run
Execute an agent and receive the result. Request:| Field | Type | Required | Description |
|---|---|---|---|
agent | string | Yes | Path to agent file (relative to that project’s root) |
project | string | Conditional | Required in multi-project mode unless --default is set |
prompt | string | No | Additional prompt appended to agent instructions |
model | string | No | Override model in agent file |
timeout | number | No | Max execution time in seconds (default: 300) |
maxSteps | number | No | Max tool call steps |
| Error Code | HTTP Status | Description |
|---|---|---|
AGENT_NOT_FOUND | 404 | Agent file doesn’t exist |
PROJECT_NOT_FOUND | 404 | Unknown project id in multi-project mode |
PROJECT_REQUIRED | 400 | Multi-project request without project or --default |
INVALID_PATH | 400 | Path outside project root |
INVALID_REQUEST | 400 | Invalid JSON body |
MISSING_FIELD | 400 | Required field missing |
TIMEOUT | 504 | Execution timed out |
EXECUTION_ERROR | 500 | Runtime error |
Streaming Response
For real-time output, request NDJSON streaming:Authentication
When exposing the server externally, authentication is required:Exposing Your Local Server
- Tailscale (Private)
- Cloudflare Tunnel (Public)
Access from your devices or team only:Connect via
http://<machine-name>:12233 from any device on your tailnet.Integration Examples
GitHub Webhook
Create an agent to handle GitHub events:Slack Integration
Slack slash commands require a response within 3 seconds and signature verification. Use a workflow tool as middleware: With n8n or Make:- Add Slack trigger node (receives slash commands)
- Add HTTP Request node → POST to
http://server:12233/run - Return agent response to Slack
- Trigger: Slack → New Slash Command
- Action: Webhooks → POST to AgentUse
/run - Action: Slack → Send Channel Message with result
Direct Slack integration requires handling the 3-second timeout, form-urlencoded parsing, and request signature verification. Workflow tools handle this automatically.
n8n / Make / Zapier
Use HTTP request nodes to trigger agents:- Set URL to
http://your-server:12233/run - Method: POST
- Headers:
Content-Type: application/json - Body:
Cron Job (External)
Trigger from system cron instead of built-in scheduler:Server Configuration
See CLI Commands - agentuse serve for all server options including port, host, debug mode, and authentication configuration.Production Deployment
For deployingagentuse serve in production with reverse proxies (nginx), process management (PM2), and Docker, see Self-Hosting.
Next Steps
Scheduled Agents
Run agents on a cron schedule
Self-Hosting
Deploy in production
