functions

functions is a skill for Claude Code, Codex from zavudev/zavu-skills. It costs 69 tokens per session (9,851 once invoked), scanned A, original, Apache-2.0.

A toolkit for writing and deploying serverless TypeScript code on Zavu Cloud, including AI agents and custom tools. Serverless code runs in the cloud without managing a server.

In plain words
What is it for?
Use it to define agents, create tool handlers, add event-driven business logic, deploy projects, and inspect agent runs.
Why use it?
It removes much of the setup needed to connect an AI agent to custom code and deploy it. It also provides commands for checking agent executions when debugging.

Skill for Claude CodeCodex

Written for Claude Code: shipped in a Claude Code plugin. Also seen: positional $N argument.

Part of the zavu-skills plugin — 14 skills shipped together

Good fit Use it to define agents, create tool handlers, add event-driven business logic, deploy projects, and inspect agent runs.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/zavudev/zavu-skills/functions
Install

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.

Any agent
npx skills add zavudev/zavu-skills --skill functions
Clone the repo
git clone --depth 1 https://github.com/zavudev/zavu-skills

Made for: Claude Code, Codex.

Or install zavu-skills, the plugin that ships this one along with the rest of its 14 skills.

Wrote 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.

agentmods badge for functions

README.md
[![agentmods](https://agentmods.dev/badge/skills/zavudev/zavu-skills/functions/github.svg)](https://agentmods.dev/skills/zavudev/zavu-skills/functions)
Your own site
<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.

agentmods 80×15 button for functions

Your own site · 80×15
<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>
Per session 69 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 9,851 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce 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

Measured 9d ago against content hash 06d084791c0e, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

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.

skills/functions/SKILL.md · 997 lines

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. deploy starts at index.ts and 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 dependencies in package.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 __zavu are 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

Read the full file on GitHub · 997 lines

Changes

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.

  1. 9d ago First seen · 997 lines · 69 tokens per session scan A 06d084791c0e

Subscribe to this mod's changes

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.

Related

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/trpc · 67 tokens

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.

trpc/trpc · 59 tokens

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.

e2b-dev/E2B · 51 tokens

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…

vercel-labs/open-agents · 191 tokens

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…

Jeffallan/claude-skills · 107 tokens

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…

mcollina/skills · 137 tokens