NESTAIDOCS
NestAI Docs

API REFERENCE

NestAI exposes an internal API for managing your server and account. All routes require the x-internal-secret header.

The NestAI API is an internal management API, not a public API. It's used by the NestAI dashboard. Direct API access for end users is through the Open WebUI API running on your server.

Open WebUI API (on your server)

Your deployed server runs Open WebUI which exposes an OpenAI-compatible API. You can use this to build integrations directly against your private AI:

Base URL
https://yourname.nestai.chirai.dev/api/v1
Chat completion (OpenAI-compatible)
curl https://yourname.nestai.chirai.dev/api/v1/chat/completions \
  -H "Authorization: Bearer YOUR_WEBUI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "llama3.1",
    "messages": [{"role": "user", "content": "Hello"}]
  }'

Get your API key from Open WebUI → Settings → Account → API Keys.

Ollama API (on your server)

Ollama also has its own API on port 11434 of your server (accessible only from the NestAI backend, not publicly exposed):

EndpointMethodDescription
/api/tagsGETList installed models
/api/pullPOSTPull a model ({"name": "llama3.1"})
/api/deleteDELETEDelete a model ({"name": "llama3.1"})
/api/generatePOSTGenerate text (streaming)
/api/chatPOSTChat completion (streaming)

NestAI Management API

Used internally by the dashboard. All endpoints are at https://api.nestai.chirai.dev and require x-internal-secret header.

EndpointMethodDescription
/api/deploy/provisionPOSTDeploy a new server
/api/deploy/cancelPOSTCancel an in-progress deployment
/api/team/invitePOSTInvite a team member
/api/team/rename-subdomainPOSTRename subdomain
/api/models/:teamIdGETList installed models
/api/models/pullPOSTPull a model onto server
/api/models/:teamId/:nameDELETEDelete a model
/api/analytics/:teamIdGETUsage analytics
/api/audit/:teamIdGETAudit log entries
/api/knowledge/:teamIdGETList knowledge docs
/api/knowledge/uploadPOSTUpload a document
Want API access to build integrations? The Open WebUI API on your server is the right tool — it's fully OpenAI-compatible and your data stays on your server.