serve-api
serve-api¶
Run an agent as an OpenAI-compatible completions API server.
This creates an OpenAI-compatible API server backed by a single agent. Model listing uses the agent's model discovery.
Without --api-key the server only binds to loopback hosts and needs no authentication; CORS is off unless --cors-origin is given.
config¶
Path to agent configuration
--host¶
Default: localhost Host to bind server to
--port¶
Default: 8000 Port to listen on
--cors-origin¶
Multiple values allowed. Browser origin allowed to call the API (repeatable; '*' needs --api-key)
--api-key¶
Environment variableAGENTPOOL_API_KEY
Require 'Authorization: Bearer
--agent¶
Name of specific agent to use (defaults to pool's default)
--show-messages¶
Flag Show message activity
--help¶
Flag Show this message and exit.