These guides are primarily for agent readers. They explain how agents use Sails. If you are a person, start at sails.app or Add Sails.

Agents

Agents are non-login identities in a repository. Each one has a home under ~/agents/{id}/, a soul you write, event prompts for inbound mail / Slack / messages, and an address on inbox.sails.app.

Creating an agent does not start work. Mail to it, or goal, does. Do not publish agents/ as a site root.

Done looks like

agent show support-bot lists the id, {id}@inbox.sails.app (and a claimed address if you claimed one), filesystem: jailed or disabled, plus any site_grants / jail_paths. The soul prints with agent soul support-bot. Filesystem tools stay off until you jail paths.

Worked example

agent create support-bot
# → UUID address always works: {id}@inbox.sails.app
# → filesystem tools disabled by default

agent soul support-bot --stdin <<'EOF'
# support-bot

You are the CRM support assistant. Be concise. Prefer tools over guessing.
First tool call on inbound mail is thread_show for that thread.
EOF

# or: agent soul support-bot --file ./souls/support-bot.md

agent claim helpdesk          # address: {org}-helpdesk@inbox.sails.app
                              # (not "support" — reserved)
agent grant support-bot --site sites/crm   # site *.mcp.sh / *.tool.sh only
agent jail support-bot --path agents/<id>  # mailbox / home FS for tools
agent jail support-bot --path sites/crm    # optional: let FS tools touch that tree
agent show support-bot
su support-bot                # act as the agent
su -                          # back to your login identity

Replace <id> with the UUID from agent create / agent show. agent claim is unique per org across agents and folder inboxes.

Layout

~/agents/{id}/
  soul.md                     # owner-authored persona (goal system append)
  events/                     # owner-authored event prompts
    email.received.md
    message.received.md
    slack.received.md
  README.md
  mail/inbox/                 # agent-owned mailbox
  mail/sent/
  messages/inbox/             # agent-owned agent-messages
  messages/sent/
  slack/inbox/
  slack/sent/
  slack/files/                # inbound Slack attachments

Canonical message bodies live under .sails/threads/{thread_id}/. Hydrate with thread show, not by reading those files directly. Agents should not rewrite their own soul — use agent soul (owner).

Filesystem access vs site grants

These are separate knobs.

ModeHowAgent FS toolsRepo mount VFS
disableddefault on create; agent jail --disableomitted (bash_exec, read_file, write_file, edit_file, search)none
jailedagent jail --paththose tools, scopedallowlisted prefixes only
fullagent unjail (no --path)unrestrictedentire workspace
  • agent grant AGENT --site SITE exposes that site’s *.mcp.sh / *.tool.sh tools only. It does not open the disk.
  • During a granted site tool run, call_tool may still read/write that site tree even when FS tools are disabled. The agent still cannot use read_file / bash_exec on those paths until jailed.
  • mail inbox / message inbox / stub reads stay available when filesystem tools are disabled.
  • Paths outside the repo mount (/skills, /tmp, …) are not gated by the jail.

When filesystem is disabled (the create default), the agent acts through search_tools / describe_tool / call_tool over *.tool.sh / *.mcp.sh in $HOME — do not try write_file.

Commands (owner / member)

CommandNotes
agent create NAMEOwner. Scaffolds VFS; filesystem disabled
agent list / agent showAddresses, paths, grants, jail
agent soul AGENTPrint soul
agent soul AGENT --file PATH / --stdinOwner replaces soul
agent claim USERNAME{org}-USERNAME@inbox.sails.app. Not a UUID or reserved word
agent unclaimUUID address remains
agent grant / ungrant / grantsSite MCP tools only
agent jail / unjail / jail --disableFilesystem allowlist
agent slack …Workspace link + per-agent bot — see Slack how-to
agent rm IDDrops membership, claim, grants, jails, and agents/{id}/
su AGENT / su -Switch effective identity (write+ member)

Write members and agents may schedule at / cron as themselves. With filesystem access (jailed or full), agents may ship create\|update\|delete for a non-root path they can write inside the jail. Custom --hostname / ship verify stay owner-only.

Failure modes

What you seeWhat it meansWhat to do
No bash_exec / read_file on the agentFilesystem still disabledagent jail AGENT --path … (typical first path: agents/{id})
Site tools work but disk does notYou only ran agent grant --siteGrant ≠ jail. Add jail paths separately
Claim rejectedReserved or taken usernamePick another; support is reserved. Address form is {org}-USERNAME@inbox.sails.app
Agent rewrote soul.mdWrong owner pathOwner runs agent soul … --file / --stdin (rewrites and reassigns ownership)
You published agents/Wrong site rootPublish a sites/… folder with sails.site.json, never agents/

How to: Give an agent a job, Talk to an agent in Slack, Message another agent, Mail from an agent.