Every template is a complete React app built with Vite, with a manifest, the tables it needs, and a README that says what to change. Create one with:
agentserve app init my-app --template <name>agentserve app init --list prints the templates. Each one installs the tables it uses if they are missing, and always acts as the person using it.
blank
For: any app that none of the others fits.
A minimal starting point. It shows who is signed in and their role, which tables the app can read, and the rows of a small example table called items.
| Permission | Why |
|---|---|
tables: [items] | Reads the example table. |
agentserve app init my-app --template blanksales-cockpit
For: account managers preparing for a customer meeting.
Pick an account and see its key figures from the semantic model, its last few visits, and a button that opens Chat with a request for talking points. After the meeting, log the outcome; the person reviews it before it is saved.
| Permission | Why |
|---|---|
tables: [accounts, visits] | Lists accounts, reads recent visits, and adds logged visits. |
model: read | Reads account figures from the semantic model. |
chat: ask | Opens Chat with a talking-points question. The person decides whether to send it. |
Change the measure and entity names in src/lib/model.ts to the ones in your model.
agentserve app init my-app --template sales-cockpitfield-visit-logger
For: field teams who visit customers.
Log each visit with the customer, date, outcome and notes, and attach a photo. The notes are saved as a Markdown file and the photo as an image in the workspace's files, and the visit row keeps both file ids. From the visits list, hand any visit to a Relay for follow-up.
| Permission | Why |
|---|---|
tables: [visits] | Lists visits and adds new ones. |
files: write | Saves notes and photos, up to 5 MB each, as workspace files. |
relays: [Field follow-up] | Gives the follow-up Relay a task for a visit. |
It declares the Field follow-up Relay and a monthly budget of $25 for its Relay tasks.
agentserve app init my-app --template field-visit-loggerdeal-desk
For: sales teams that check offers against pricing policy.
Enter an offer and see its score from 0 to 100 as you type, with the reasons: discount against the limit for the customer's tier, margin, contract term and deal size. Then request approval: the offer is saved as pending approval, and a Relay gets a task with the score and reasons. The score comes from score_offer, a code tool the app ships: a plain TypeScript function that runs on Agent Serve, so the same offer always gets the same score, and Chat, Relays and workflows can ask it too.
| Permission | Why |
|---|---|
tables: [offers] | Lists offers and saves new ones. |
relays: [Deal desk approvals] | Sends each offer to the approvals Relay. |
It declares the Deal desk approvals Relay, the score_offer tool, and a monthly budget of $25. Code tools run from an installed version, so in agentserve app dev the score appears once you have deployed, published and installed the app.
agentserve app init my-app --template deal-desksupport-triage
For: support leads working through a queue.
Open tickets are listed most urgent and oldest first. Select one to read it, ask Chat to summarise it, and route it to a team by running your Route ticket workflow. The app shows whether the run completed or why it failed.
| Permission | Why |
|---|---|
tables: [tickets] | Reads the open tickets. |
workflows: [Route ticket] | Runs the routing workflow for a ticket. |
chat: ask | Opens Chat with a summary request. The person decides whether to send it. |
You build and deploy the Route ticket workflow yourself; it takes ticketId, team and priority. The template sets a monthly budget of $25 for workflow runs.
agentserve app init my-app --template support-triageops-exceptions
For: operations managers watching for problems.
The board shows late shipments by region and site from the semantic model and flags every site above a threshold as an exception. Click a row to see that site split by carrier, then create a follow-up task in the ops_tasks table.
| Permission | Why |
|---|---|
model: read | Reads late shipments by region, site and carrier from the semantic model. |
tables: [ops_tasks] | Adds follow-up tasks. |
Change the measure, entity and attribute names in src/lib/model.ts to the ones in your model.
agentserve app init my-app --template ops-exceptionsknowledge-assistant
For: anyone who wants quick, cited answers from the team's documents.
Ask a question. The app searches a knowledge base for matching passages, then streams a short answer from a chat model that cites them, with the sources listed underneath. It shows the platform AI an app can call directly, without wrapping each step in a workflow.
| Permission | Why |
|---|---|
knowledge: [Product docs] | Searches the knowledge base for passages that match the question. |
ai.models: [gpt-5.5] | Writes the answer from those passages, streamed as it is written. |
Set KNOWLEDGE_BASE and ANSWER_MODEL in src/lib/answer.ts, and the same names in the manifest. Searches and answers count against the app's budget, which the template sets to $20 a month.
agentserve app init my-app --template knowledge-assistantsales-cockpit and ops-exceptions query the semantic model, and field-visit-logger and deal-desk assign Relay tasks. Neither call works in agentserve app dev yet, so try those parts in a deployed draft. See agentserve app dev.
The templates that declare a Relay create it as a draft on install, and only when installed from the Apps page in the workspace. Someone finishes the Relay's setup and publishes it before it can take tasks. See Requires.
Example apps
Two complete apps in the repository show what a finished app looks like: several pages,
tables the workspace already has, a table and Relays created on install, Chat, a code tool,
approvals, and loading, empty and error states throughout. They live in examples/apps/
and are checked like the templates: type-checked, built, manifest-validated and packed on
every change.
They read tables that are already in the workspace, and column names differ between workspaces. So each one reads the tables' columns when it starts, maps the fields it needs by name, and asks the person to map your columns when a required one is missing, instead of failing.
pipeline-cockpit
For: sales managers and reps working at-risk deals.
Deals ranks at-risk deals by the money at stake, how serious the risk is and how soon the deal is due, with filters by rep, stage and value. Deal brief shows one deal with its history and the account's other deals, opens Chat for talking points, logs the next step to a deal_notes table after a review screen, and assigns a follow-up to a Relay. Team shows each rep against quota with the at-risk value on their desk.
| Permission | Why |
|---|---|
tables: [deals_at_risk, pipeline_opportunities, rep_summary, deal_notes] | Reads deals, history and the team; adds next steps. |
relays: [Pipeline follow-up] | Assigns follow-ups. |
chat: ask | Opens Chat with a talking-points question. The person decides whether to send it. |
credit-desk
For: credit analysts and underwriters, and the teams that watch fraud and complaints.
Applications lists loans waiting for a credit review, largest exposure first. Review scores one loan with score_credit_risk, a code tool the app ships, and lists every factor with the points it added; the reviewer then approves, refers or declines. A decline is saved as pending approval and sent to a Relay to approve. Exceptions lists fraud alerts under review and open complaints, each a click from a Relay task.
| Permission | Why |
|---|---|
tables: [loans, fraud_alerts, complaints, credit_decisions] | Reads the queue and exceptions; saves decisions. |
relays: [Credit approvals, Credit exceptions] | Sends declines for approval and exceptions for follow-up. |
It declares the score_credit_risk tool and a monthly budget of $50.
Deploy an example
Example apps are not offered by app init. From a checkout of the repository, copy one out
with the SDK vendored the same way app init does it, then deploy as usual:
bun run scaffold:example-app credit-desk ../credit-desk
cd ../credit-desk
bun install
agentserve app deploy
agentserve app publish 0.1.0
agentserve app installEach example's README lists the tables it expects, the columns it looks for, and what to change.