API Reference
Complete API documentation available on GitHub
Two API Surfaces
Management API: Full CRUD for all resources at /api/v1/
Runtime API: Execute webhooks and interact with agents (dynamically generated OpenAPI docs)
# Management API
curl http://localhost:51245/api/v1/agents \
-H "Authorization: Bearer YOUR_JWT_TOKEN"
# Runtime API
curl http://localhost:51245/webhooks/my-webhook \
-H "Authorization: Bearer YOUR_JWT_TOKEN"
Authentication & Authorization
POST
/api/v1/auth/login
Request OTP code for passwordless login
POST
/api/v1/auth/verify-otp
Verify OTP and receive JWT token
POST
/api/v1/auth/api-keys
Create API key for programmatic access
GET
/api/v1/auth/api-keys
List all API keys
GET
/api/v1/auth/me
Get current user information
Agents & Chat
POST
/api/v1/agents
Create AI agent with system prompt, tools, and LLM config
GET
/api/v1/agents
List all agents
POST
/agents/{namespace}/{name}/chats
Create chat with agent (Runtime API)
POST
/chats/{id}/messages/stream
Send message and stream response (SSE)
Skills
POST
/api/v1/skills
Create skill (reusable instruction module)
GET
/api/v1/skills
List all skills
GET
/api/v1/skills/{namespace}/{name}
Get skill by namespace and name
Functions
POST
/api/v1/functions
Create Python function with JSON schema validation
GET
/api/v1/functions
List all functions with filtering
GET
/api/v1/functions/:id/versions
View function version history
GET
/api/v1/executions
List function executions
GET
/api/v1/executions/:id/steps
View execution tree with nested calls
Webhooks
POST
/api/v1/webhooks
Create webhook endpoint
GET
/api/v1/webhooks
List all webhooks
POST
/webhooks/:path
Invoke webhook (triggers function execution)
Schedules
POST
/api/v1/schedules
Create cron-based scheduled job
GET
/api/v1/schedules
List all scheduled jobs
PATCH
/api/v1/schedules/:id
Update schedule configuration
States
POST
/states
Create state (key-value storage)
GET
/states/{namespace}/{key}
Get state by namespace and key
PUT
/states/{namespace}/{key}
Update state value
DELETE
/states/{namespace}/{key}
Delete state
MCP Servers
POST
/api/v1/mcp-servers
Register MCP server
GET
/api/v1/mcp-servers
List all MCP servers
GET
/api/v1/mcp-servers/{id}/tools
List tools provided by MCP server
Packages
POST
/api/v1/packages
Add Python package dependency
GET
/api/v1/packages
List all packages
DELETE
/api/v1/packages/{id}
Remove package
Users & Groups
GET
/api/v1/users
List all users (admin only)
POST
/api/v1/groups
Create group
POST
/api/v1/groups/:id/members
Add member to group
POST
/api/v1/groups/:id/permissions
Set group permission
Request Logs
GET
/api/v1/request-logs
Query request logs from ClickHouse
Official SDKs
JavaScript / TypeScript
npm install @sinas/client
Python
pip install sinas-client
Go
go get github.com/sinas/sinas-go
Rust
cargo add sinas