Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add zavudev/zavu-skills --skill functionsgit clone --depth 1 https://github.com/zavudev/zavu-skillsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/zavudev/zavu-skills/functions)<a href="https://agentmods.dev/skills/zavudev/zavu-skills/functions"><img src="https://agentmods.dev/badge/skills/zavudev/zavu-skills/functions/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/zavudev/zavu-skills/functions"><img src="https://agentmods.dev/badge/skills/zavudev/zavu-skills/functions.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00069 | $0.09851 |
| Opus 5 | $0.00034 | $0.04926 |
| Sonnet 5 | $0.00014 | $0.01970 |
| Haiku 4.5 | $0.00007 | $0.00985 |
Grade A, and why
functions scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 997 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Zavu Functions
Zavu Functions = serverless TypeScript on Zavu Cloud + a declarative framework for AI agents.
import { defineAgent, defineTool } from "@zavudev/functions"
defineAgent({
senderId: process.env.SENDER_ID!,
name: "Bella",
provider: "zavu",
model: "openai/gpt-4o-mini",
prompt: "You are Bella, host at the restaurant. Be brief.",
})
defineTool({
name: "check_availability",
description: "Get free reservation slots for a date.",
parameters: {
type: "object",
properties: { date: { type: "string" }, partySize: { type: "number" } },
required: ["date", "partySize"],
},
handler: async ({ date, partySize }) => {
return { available: true, slots: ["19:00", "21:00"] }
},
})
That's a full agent + tool. npx zavudev deploy reconciles the live state.
Project shape
Decide this before you write anything, because restructuring later is the expensive kind of rework.
my-agent/
├── index.ts entrypoint: defineAgent + defineTool live here
├── lib/orders.ts imported by index.ts, deployed with it
├── package.json npm dependencies, installed at build time
└── .zavu/ created by the CLI; do not edit
- Several files are fine.
deploystarts atindex.tsand uploads every file it reaches through relative imports. Split the prompt, the tools and the business logic however you like. - Only what is imported ships. A file nothing imports stays on your machine, so tests and scratch work are not deployed.
- npm packages are not files. Declare them under
dependenciesinpackage.json; they are installed and bundled for you. - Limits: 200 files, 900,000 bytes total. Paths above the project root
(
../shared/x.ts),node_modules/, and names starting with__zavuare refused. To share code across projects, publish it as an npm package. --source <file>names a different entrypoint.
When to use Functions vs the imperative AI Agent API
| Use case | Use |
|---|---|
| Customer wants a code-first agent with custom tool handlers in their own language | Functions |
| Tools need to query the user's database, call internal APIs, or transform data before returning | Functions |
| User wants reproducible config from a git repo (one source of truth) | Functions |
| User wants no-code config via the dashboard | imperative senders.agent.create API (see ai-agent skill) |
User needs event-driven handlers (message.inbound, broadcast.status_changed) without dashboard wiring |
Functions |
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 9d ago First seen · 997 lines · 69 tokens per session scan A 06d084791c0e
functions is a skill published in the GitHub repository zavudev/zavu-skills (1 stars, last pushed today), licensed Apache-2.0. It adds 69 tokens to every session and 9,851 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
adapter-express
Mount tRPC as Express middleware with createExpressMiddleware() from @trpc/server/adapters/express. Access Express req/res in createContext via CreateExpressContextOptions. Mount at a path prefix like app.use('/trpc', ...). Avoid global express.json() conflicting with tRPC body parsing for FormData.
trpc-router
Entry point for all tRPC skills. Decision tree routing by task: initTRPC.create(), t.router(), t.procedure, createTRPCClient, adapters, subscriptions, React Query, Next.js, links, middleware, validators, error handling, caching, FormData.
stripe-projects
Use after E2B sandbox/API access has been provisioned through Stripe Projects and the user needs to use the resulting E2B API key with the E2B CLI, JavaScript SDK, Python SDK, or Code Interpreter SDK.
chat-sdk
Build multi-platform chat bots with Chat SDK (chat npm package). Use when developers want to (1) Build a Slack, Teams, Google Chat, Discord, Telegram, GitHub, Linear, or WhatsApp bot, (2) Use Chat SDK to handle mentions, direct messages, subscribed threads, reactions, slash commands, cards, modals, files, or AI…
nestjs-expert
Creates and configures NestJS modules, controllers, services, DTOs, guards, and interceptors for enterprise-grade TypeScript backend applications. Use when building NestJS REST APIs or GraphQL services, implementing dependency injection, scaffolding modular architecture, adding JWT/Passport authentication, integrating…
fastify-best-practices
Guides development of Fastify Node.js backend servers and REST APIs using TypeScript or JavaScript. Use when building, configuring, or debugging a Fastify application — including defining routes, implementing plugins, setting up JSON Schema validation, handling errors, optimising performance, managing authentication…