Katexs
How Katexs works

Concepts

How Katexs works

The architecture behind Katexs, what happens on every call and message, and the guarantees the platform makes.

The layers

Katexs platform architecture Channels connect through the Katexs edge to the voice and chat runtimes, which call tools in your systems. All runtimes share one tenant-isolated data layer. Channels Katexs edge Runtimes Your systems PhoneInbound and outbound Web callBrowser, short-lived token Website widgetwidget.js, streaming chat Your backendHTTPS API (preview) Edge & governance Auth & tenant check Origin allow-list Credit guard Rate limits Webhook verification Idempotency & dedupe Voice runtimeRealtime speech pipeline STT LLM TTS Carrier-grade telephony layer Chat runtimeServer-sent events, token by token Direct LLM Flow engine Knowledge retrieval per message Custom functionsYour HTTPS endpoints CalendarGoogle Calendar booking Human transferForward to your staff CRM & automationsIntegrations, webhooks Shared platform, isolated per workspace DatabaseRow-level security Credit ledgerAtomic, idempotent Shared memoryContacts, timeline Traces & logsEvery call and tool
How a request moves through Katexs: channels, the edge, the runtimes, your systems, and the shared tenant-isolated platform.

Katexs sits between your customers and the AI. Requests enter through a channel (a phone number, a browser session, the website widget, or in future your own backend). Every request passes the edge, where Katexs authenticates it, finds the workspace it belongs to, checks credits and rate limits, and verifies signatures. It is then served by a runtime: the voice runtime for realtime speech, or the chat runtime for streamed text. Runtimes call your systems through tools, and read and write the shared platform: the database, the credit ledger, shared memory and traces.

Workspaces

A workspace is the unit of isolation. Agents, phone numbers, calls, chats, contacts, knowledge, tools and credits all belong to exactly one workspace. Team members are invited into a workspace with a role (owner, admin or member). Nothing is ever shared between workspaces. See Tenant isolation.

What happens on a phone call

Voice call lifecycle Sequence of events between the caller, the voice runtime, the Katexs platform and your endpoint during one phone call, from dial to end-of-call report. CallerPhone or browser Voice runtimeSTT, LLM, TTS Katexs platformevents, billing, tools Your endpointCustom function Dials your number assistant-request { assistantId } within 7.5 s status-update · in-progress Speaks first message tool-calls POST tool-calls envelope result in < 800 ms { results: [ … ] } Hangs up status-update · ended end-of-call-report only when the number has no agent creates the call log After the callCharge credits · save transcript · update contact
Events during one inbound phone call. Custom functions with their own server URL receive the tool-calls request directly from the voice engine.
  1. 1

    The call connects

    If the number has an agent assigned, the voice engine starts it. If not, Katexs is asked which agent should answer and must reply within 7.5 seconds. Katexs aims for under 800 ms.

  2. 2

    The call is logged

    On the first status update Katexs creates the call log under the right workspace.

  3. 3

    The conversation runs

    The agent listens, thinks and speaks in realtime. When it needs a tool, the tool request is executed and the result is spoken back.

  4. 4

    The call ends

    The end-of-call report arrives with the duration, transcript, recording link, summary and analysis.

  5. 5

    Katexs settles it

    The call is charged once on the ledger, the transcript is stored, the caller's contact and timeline are updated, notifications fire and a trace is written.

What happens on a chat message

Chat streaming request The widget loads its configuration, posts a message, the runtime checks origin, visitor token, rate limits and credits, then streams the model reply back as server-sent events. Visitor browserwidget.js Katexs chat runtime/api/public/chat/{publicId} ModelDirect LLM or flow engine 1 Origin on allow-list 2 Signed visitor token 3 Rate limits 4 Reserve credits GET load widget config { widget, connected } POST { message, sessionId } prompt + memory + knowledge streamed tokens data: {"type":"session", …} data: {"type":"delta","text":"…"} data: {"type":"done"} On completionCommit usage and transcript, or refund
One chat message from the website widget, from checks to the streamed reply.

The widget loads its configuration, then posts each message. Katexs checks the origin, the signed visitor token, rate limits and credits, reserves the cost, and streams the model's reply back as server-sent events. If the reply completes, the usage is committed and the transcript saved; if it fails or the visitor disconnects, the reservation is refunded.

Guarantees

GuaranteeHow it's enforced
No cross-tenant accessRow-level security on every table; workspace tags on every voice resource, checked on every event
No double chargesOne ledger entry per call id or message id; duplicate events are detected and dropped
No silent failuresEvery failed tool returns a calm, speakable message and is logged with its reason
Secrets stay on the serverThe browser only receives short-lived, single-purpose tokens
Every action is traceableCalls, messages and tool runs write traces with timing and credit cost

Last updated November 2026 · Found a problem? Email support@katexs.com