Concepts / Tutorial

Tutorial: your first crew

Build a two-agent crew that monitors a system and reaches you on Telegram when something needs a decision — the canonical "agents that parley" setup.

This assumes you've finished Getting started and have the host running with one model configured.

1 · Create two agents

A Navigator that owns decisions, and a Scout it can delegate investigation to.

bash
dotnet run --project src/AgentParley.Cli -- agent create navigator --model claude-opus --desc "Owns decisions and rollbacks"
dotnet run --project src/AgentParley.Cli -- agent create scout --model claude-sonnet --desc "Investigates and reports"

2 · Let the Navigator delegate to the Scout

Open navigator in the console and allow it to spawn the scout as a subagent. In agents/navigator/agent.yml this is:

agents/navigator/agent.ymlyaml
name: navigator
model: claude-opus
soul: "Calm under fire. You own rollbacks and you keep the human informed."

subagents:
  allowed: [scout]
  default: claude-sonnet

Now the Navigator can hand the Scout a task and get findings back — that's the inter-agent communication layer doing the work.

3 · Connect Telegram

Install the Telegram channel plugin (see Installing plugins), store the bot token, and add a channel instance:

bash
# after dropping the plugin DLL into ~/parley/plugins/ and restarting:
dotnet run --project src/AgentParley.Cli -- secret set telegram-token   # paste from @BotFather
~/parley/parley.yamlyaml
channels:
  - instanceId: tg
    providerId: telegram
    secretRefs: { token: telegram-token }

On the Navigator, list tg under its available channels and add your numeric Telegram user id to the authorized senders (channel auth is default-deny).

4 · Give the crew a standing mission

Add a cron entry so the Navigator checks in on a schedule and pulls in the Scout when needed:

agents/navigator/cron.ymlyaml
- schedule: "*/15 * * * *"
  prompt: |
    Check the health of the payments service. If anything looks wrong,
    send the scout to investigate, then message me on Telegram with a
    recommendation before taking any action.

5 · Watch them parley

Open the Observer in the console. Every 15 minutes the Navigator wakes, delegates to the Scout, reads the findings, and — if it needs your call — messages you on Telegram and parks AwaitingHuman until you reply. Your reply resumes the exact same session with full context.

That's the whole pattern: specialized agents, a real communication layer between them, a standing mission, and a human kept in the loop on anything that matters. Grow the crew by adding more experts and widening subagents.allowed.