Skip to main content

Overview

The boilerplate agent is the simplest starting point for building an aixyz agent. It demonstrates a multi-skill agent with three unit conversion tools — length, weight, and temperature — using the auto-generated server pattern.

Project Structure

boilerplate/
├── aixyz.config.ts         # Agent metadata and skills
├── app/
│   ├── agent.ts            # Agent definition with tools
│   ├── tools/
│   │   ├── length.ts       # Length conversion tool
│   │   ├── weight.ts       # Weight conversion tool
│   │   └── temperature.ts  # Temperature conversion tool
│   └── icon.png            # Agent icon
├── package.json
└── vercel.json

Skills

SkillDescription
Convert LengthConvert length and distance values between metric and imperial
Convert WeightConvert weight and mass values between metric and imperial
Convert TemperatureConvert temperature values between Celsius, Fahrenheit, and Kelvin

Configuration

aixyz.config.ts
const config: AixyzConfig = {
  name: "Unit Conversion Agent",
  description: "AI agent that converts values between metric, imperial, and other measurement systems.",
  version: "0.1.0",
  x402: {
    payTo: "0x0799872E07EA7a63c79357694504FE66EDfE4a0A",
    network: process.env.NODE_ENV === "production" ? "eip155:8453" : "eip155:84532",
  },
  skills: [
    { id: "convert-length", name: "Convert Length", ... },
    { id: "convert-weight", name: "Convert Weight", ... },
    { id: "convert-temperature", name: "Convert Temperature", ... },
  ],
};

Payment

The agent charges $0.001 per request via x402 on Base (mainnet in production, Base Sepolia in development).

Running

cd examples/boilerplate
bun install
bun run dev
Endpoints available at http://localhost:3000:
EndpointProtocolDescription
/.well-known/agent-card.jsonA2AAgent discovery card
/agentA2AJSON-RPC task handler
/mcpMCPTool endpoint