Appearance
Concepts
Hevkar lets you configure AI agents in a web console and run them from your own backend. This page explains the building blocks and how they relate.
Organization
└── Project (e.g. "production", "staging")
├── Agents ──► Versions (immutable, one is current)
├── API keys (scoped, optionally limited to some agents)
├── Data sources (knowledge: indexed or live)
├── Tools (HTTP tools) and Secrets
├── Files (run inputs, data source documents)
├── Webhooks
└── Runs, Conversations, Realtime sessions, UsageOrganizations
An organization is your company's account. Members have one of four roles:
| Role | Can |
|---|---|
owner | everything, including deleting projects |
admin | manage members, projects, API keys, secrets and webhooks |
member | build and test agents, data sources and tools; no keys or member admin |
viewer | read-only, usage dashboard |
Limits such as requests per minute and the monthly spend cap apply to the whole organization (see Usage and limits).
Projects
A project is an isolated workspace inside an organization. Everything you build (agents, data sources, tools, files, keys, webhooks) and everything that happens (runs, usage) belongs to one project. Use projects to separate environments (production, staging) or products.
Each project has a retention period for run inputs and outputs (default 30 days). Usage numbers are kept after the retention period.
Agents and versions
An agent has a name, a slug (lowercase letters, digits and dashes, unique in the project) and a type. You call it from the API by its slug: POST /v1/agents/{slug}/runs.
Its configuration (model, instructions, schemas, knowledge, tools, ...) is edited as a draft in the console. Publishing freezes the draft as an immutable version (1, 2, 3, ...) and makes it the current version. API calls always use a published version: the current one, or the one you pin with version. Rolling back means making an older version current again. An agent that was never published cannot be called (AGENT_NOT_PUBLISHED).
The full list of settings is in Agent configuration.
Agent types
| Type | In → out | Called with |
|---|---|---|
extraction | files or text → JSON matching an output schema | POST /v1/agents/{slug}/runs |
transform | text or JSON → text or JSON (translate, rewrite, ...) | POST /v1/agents/{slug}/runs |
conversational | messages → answer, with history, knowledge and tools | conversations or runs with input.message |
realtime | live audio ⇄ live audio over a WebSocket | realtime sessions |
workflow | input → graph of agents and logic steps → output | POST /v1/agents/{slug}/runs |
Guides: extraction, transform, conversational, realtime, workflows.
Runs
Every invocation of an agent creates a run. A run records the agent version, the source (api, playground, agent for agent-as-tool calls, workflow for workflow steps), the API key, your externalUserId, the input, the output, tool calls, retrieved knowledge, token usage, price and latency.
Run statuses: queued, running, waiting (workflows paused for an approval, event or timer), succeeded, failed, cancelled.
A run can be executed in three modes:
- sync: the HTTP response is the result (
RunResult). - stream:
stream: truereturns Server-Sent Events while the run executes. - async:
async: truereturns202 {runId, status: 'queued'}at once; you get the result by pollingGET /v1/runs/{id}or through a webhook.
Workflow runs are always durable; a sync call waits a limited time and may answer 202 (see Workflows).
API keys and scopes
API keys authenticate the public API (/v1). Org admins create them per project in the console (Project → API keys). A key looks like hk_live_…, is shown once, and is bound to its project: it can only reach that project's agents and data.
http
Authorization: Bearer hk_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx| Scope | Allows |
|---|---|
agents:run | run agents, cancel and retry runs, conversations (write) |
runs:read | read runs, run steps, conversations and usage |
files:write | upload, read and delete files |
datasources:read | list data sources |
datasources:write | push documents into data sources and trigger syncs |
realtime:session | create realtime session tokens |
workflows:approve | decide workflow approvals and deliver events to waiting workflow runs |
workflows:approve is separate from agents:run on purpose: give it only to the backend that reviews or confirms, not to a key used by the app that starts runs for end users, so an end user cannot approve their own human step.
A key can also be restricted to some agents (other agents answer 403 AGENT_NOT_ALLOWED), have its own requests-per-minute limit, and an expiry date. Revoked or expired keys answer 401 INVALID_API_KEY.
Keep keys on your server
API keys are secrets. Never ship them to browsers or mobile apps. For voice apps, your backend mints a short-lived realtime session token and hands only that to the app.
Data sources
Data sources give agents knowledge. Types: files, website, http_api and text. A source is either indexed (content is fetched, parsed, chunked, embedded and searched with hybrid vector and full-text retrieval) or live (http_api only: the API is called at run time as a tool). Attach sources to any number of agents. See Knowledge.
Tools
Agents can call tools during a run:
- HTTP tools: requests you define once per project (URL template, method, headers, parameter schema). Credentials come from project secrets. See HTTP tools and secrets.
- Live data sources: an
http_apisource in live mode. - Agents: other agents of the project. See Agents as tools.
- Built-ins:
current_time,detect_languageandweb_fetch(readable text of a public web page). search_knowledge: added automatically when indexed sources are attached in tool mode.
Workflows
A workflow agent holds a graph of nodes (agents, conditions, parallel branches, map and loop, transforms, HTTP requests, searches, human approvals, waits, output and fail) connected by edges. Runs are durable: they survive restarts and can pause for days. See Workflows.
Realtime
Realtime agents hold live voice conversations. Your backend creates a session (POST /v1/realtime/sessions) and gets a single-use token; the end user's app connects to a WebSocket with it and streams audio. The protocol is the same whether the agent runs on OpenAI Realtime or Gemini Live. See Realtime voice.
End users
Your own users never talk to Hevkar directly and need no account. Pass your identifier for them as externalUserId on runs, conversations and realtime sessions. It is stored on runs and usage, so you can see and limit per-user consumption from the usage dashboard or GET /v1/usage.
Usage and limits
Every billable action (input, cached input and output tokens, audio seconds, embedding tokens, OCR pages) is metered with a price in USD micros (1 USD = 1 000 000 micros). Each RunResult reports usage.priceMicros; GET /v1/usage reports a project's totals.
Organization limits (defaults; your operator may set others):
| Limit | Default | Exceeded |
|---|---|---|
Requests per minute (/v1) | 600 | 429 RATE_LIMITED with retry-after |
| Monthly spend cap | 50 USD | 402 QUOTA_EXCEEDED for new billable work |
| Concurrent realtime sessions | 5 | 429 REALTIME_SESSION_LIMIT |
| Storage | 1024 MB | 402 STORAGE_LIMIT_REACHED |
| Data sources | 20 | 402 DATA_SOURCE_LIMIT_REACHED |