kind: agent is one of two things:
- A connected agent (
providerset to another platform, such asvapi, set tocustomfor your own stack, or omitted). The agent runs on that platform or your own stack. Roark observes its calls, runs simulations against it, and grades it, but does not run it.provideris optional, and every existing config without it stays valid. - An agent built on Roark (
provider: roark). Roark runs the agent. Apply creates or updates it and publishes a version, and agent-scoped tools with ahandlerbecome the tools it calls. See Agents built on Roark below.
nameis the local key (^[a-z0-9][a-z0-9-_.]*$) and, with the kind, forms the config identity.displayName(optional) is the agent’s name as it appears in Roark, where spaces and capitals are allowed; it defaults toname. Set it to an agent’s exact existing name to bring an agent you created in the app under config (apply takes it over in place instead of creating a duplicate) when that name isn’t slug-shaped, for exampledisplayName: "Dental Clinic"withname: dental-clinic.- Other resources reference an agent by its
name(the slug), not itsdisplayName(e.g. a flow’sagents:list, a collector’sAGENTfilter, or a simulation plan’sagentEndpoints).
Endpoints
An endpoint is identified by itsvalue: the E.164 number for a phone line, the URL otherwise. That is the only field you always have to give.
An endpoint is identified by its value and its direction together, so one number can carry an inbound endpoint and an outbound one:
INCOMING or OUTGOING, never both.
Endpoints reconcile with the agent on that pair: one you add is created, one you change is updated, and one you remove is detached. Changing a direction is therefore a new endpoint and the retirement of the old one rather than an edit, which matches what it does to your call routing.
Prompt
prompt is the agent’s system prompt, kept in your repo and versioned in Roark. In TypeScript it’s a plain string, so read it from a file (or write it inline); in YAML it takes an inline string or a file:// reference resolved from your config root:
prompt leaves any existing prompt alone: config sets a prompt, it never clears one you did not declare.
For a connected agent, the prompt is kept for your reference and versioning only. Roark does not run your agent, and no metric evaluates against this prompt, so setting it does not change how your agent behaves or how it is scored. For an agent built on Roark (
provider: roark), prompt is the system prompt Roark runs.Other endpoint types (LiveKit, SmallWebRTC, ElevenLabs, Kore, Google CES, Daily) are not configurable here. They are bidirectional, so they carry no direction, and each needs provider configuration the config format has no place for. Their endpoints are created by the integration that owns them.
Outbound dialling
By default anOUTGOING endpoint is dialled by Roark. To hand dialling off to your own system, set outboundDialType: HTTP_REQUEST and point outboundDialHttpRequestDefinition at an HTTP request definition by name. Roark fires that request (with the number to dial substituted in) when the call should be placed:
dialer definition in the same bundle (or a previous apply); it reconciles before agents, so the reference resolves in one apply. See HTTP request definitions.
Provider
Top-levelprovider says who runs the agent:
provider is optional. Omitting it means the agent runs somewhere other than Roark, without saying where, so it is not read as custom (the agent could be on Vapi, for example). Existing configs without provider keep working exactly as before.
Only provider: roark makes Roark run the agent. With provider: custom, apply does not create or import an integration, does not create a runtime, and does not need Build on Roark.
provider: api is a deprecated alias for custom. It maps to the same Custom/API provider and keeps working, but use custom in new configs.Top-level
provider is who runs the agent. The provider inside tts, stt, and llm is the speech or LLM vendor, an uppercase catalog value such as ELEVENLABS, DEEPGRAM, or OPENAI.Agents built on Roark
Withprovider: roark, Roark runs the agent. roark config apply (or POST /v1/config/apply) creates or updates the agent and publishes a version of it, and its prompt becomes the system prompt it runs. The agent’s tools are kind: tool resources that name it in agent: and declare a handler (see Tools for an agent built on Roark).
Agents built on Roark need Build on Roark enabled on your account. Without it, apply fails the agent with
Build on Roark is not enabled for this account, and nothing is written for it.Fields
These fields sit directly on the agent and are used whenprovider is roark. Each is optional, but the agent needs either a prompt or a jobDescription.
An unknown
tts, stt, or llm provider fails schema validation, so diff and apply reject the bundle. A model the vendor does not offer fails the agent at apply.
Let Roark write the first prompt
Leave outprompt and give a jobDescription, and on the first apply Roark writes the prompt and greeting from it:
jobDescription is used once. Later applies do not rewrite the prompt from it. To change the prompt after the first apply, declare prompt.
What apply changes
- Every field sets only what it names. A model you leave out keeps what the live version runs (Roark’s default on the first apply). Settings tuned in Roark, such as fallbacks, end-call reasons, or keyterms, stay unless you declare them.
- A version is published only on a difference. On each apply Roark compares what you declare with the live version and publishes a new version only when they differ. Re-applying unchanged config is a no-op.
- A tool edit is an agent change. Editing one of the agent’s tools shows up in
roark config diffas an update to the agent, and apply publishes a version that runs the edited tool. If a tool fails to apply, the agent fails withtool "lookup-patient" did not apply, so the agent was left on the version it runs. - Tools added in Roark stay. Config removes a tool from the agent only when the bundle scopes that tool to another agent, or when a pruning bundle drops it.
Not configurable yet
These are not part of an agent’s config today, and config does not change them:- Sub-agents and handoffs
- Speech-to-speech configs
- Fallback configs
- Call and idle settings
- The chat modality
- Attaching project-wide tools to the agent
- Assigning a Roark phone number to the agent
Build an agent on Roark
A step-by-step guide: write the YAML, diff, apply, and handle the first apply, later applies, and draft conflicts.
For the full field reference of every kind, see the Config DSL reference schema.