Skip to content

Builtin tools

Builtin tools are the actions a profile is allowed to take.

The mental model is simple:

  • A profile can only use the tools assigned to it
  • Different profiles can have different permissions
  • Tool access is one of the main ways you control risk

Platform admins assign tools to profiles from the dashboard.

Why tools matter

The same model behaves very differently depending on its tools.

For example:

  • A writing bot may need no tools at all
  • A research bot may need web search and knowledge base search
  • An ops bot may need file access and email
  • A power-user bot may need skills and MCP servers

Give each profile the minimum tool set it needs.

Default assignments

TinyClaw includes these builtins:

Tooldefault / super_botAll profilesNotes
write_fileYesNo
delete_fileYesNo
read_fileYesNo
search_filesYesNo
knowledge_base_searchYesNo
web_searchYesNo
update_profile_memoryYesNo
emailYesNoOmitted at runtime when mailbox is unconfigured
create_skillYesYesOnly builtin assigned to new custom profiles by default

New custom profiles receive only create_skill until a platform admin assigns additional tools. System profiles (default, super_bot) get the full seeded set.

Choosing tools for a profile

Good starting patterns:

  • Simple chat bot: no extra tools
  • Research bot: web_search, knowledge_base_search
  • Knowledge bot: knowledge_base_search, update_profile_memory
  • Ops bot: file tools, email

Tool reference

write_file

Write text to a file in the profile workspace.

ParameterTypeRequiredNotes
pathstringYesRelative to profile workspace unless absolute
contentstringYesText to write
cwdstringNoBase directory within workspace; defaults to workspace root

Returns: { path, bytesWritten }

Scope: ~/.tinyclaw/profiles/{profileId}/ and ~/.tinyclaw/tools/ (custom JS modules)

Availability: When assigned to the profile.

delete_file

Delete a file from the profile workspace or custom tools directory.

ParameterTypeRequiredNotes
pathstringYesMust be within allowed directories
cwdstringNoBase directory within workspace

Returns: { path, deleted: true }

Scope: Profile workspace and custom tools directory only.

Availability: When assigned to the profile.

read_file

Read text from a file in the profile workspace.

ParameterTypeRequiredNotes
pathstringYesRelative to profile workspace unless absolute
cwdstringNoBase directory within workspace
offsetnumberNo1-based start line; default 1
limitnumberNoMaximum lines to return

Returns: { path, content, bytesRead, startLine, endLine, totalLines, truncated }

Scope: Profile workspace and custom tools directory. Reading config.ini by basename is blocked.

Availability: When assigned to the profile.

create_skill

Save a repeatable procedure as a skill for the active profile and assign it immediately.

ParameterTypeRequiredNotes
namestringYesUnique skill name for the profile
descriptionstringYesWhen the skill should be used
bodystringNoStep-by-step instructions
disableModelInvocationbooleanNoWhen true, skill only activates on explicit invocation

Availability: When assigned to the profile.

search_files

Search text in files under the profile workspace.

ParameterTypeRequiredNotes
querystringYesKeyword or regex pattern
pathstringNoSubdirectory or file within workspace
globstringNoRipgrep glob filter (e.g. *.md)
regexbooleanNoTreat query as regex; default true
maxResultsnumberNoDefault 50, max 200

Returns: { query, root, matches, matchCount, truncated }

Scope: ~/.tinyclaw/profiles/{profileId}/ only. Requires rg (ripgrep) on PATH.

Availability: When assigned to the profile.

Search uploaded knowledge base documents for relevant facts.

ParameterTypeRequiredNotes
querystringYesKeyword or regex pattern
filenamestringNoFilter to one source document (e.g. report.pdf)
regexbooleanNoDefault true
maxResultsnumberNoDefault 50, max 200

Returns: { query, root, matches, matchCount, truncated } — empty matches when no ready document matches the filter.

Scope: Extracted text under ~/.tinyclaw/profiles/{profileId}/data/knowledge-base/extracted/.

Availability: When assigned and at least one uploaded document has status: "ready".

Search the web for current information.

ParameterTypeRequiredNotes
querystringYesSearch query

Availability: When assigned and the configured provider is OpenAI or Anthropic with a valid API key. Not available on OpenRouter. On Gemini, web search is disabled when other local tools are present on the same turn.

update_profile_memory

Record a fact, preference, or decision in the profile's MEMORY.md.

ParameterTypeRequiredNotes
contentstringYesFact or observation to remember

Returns: { path, bytesTotal }

Behavior: Appends under a dated ## YYYY-MM-DD section in ~/.tinyclaw/profiles/{profileId}/MEMORY.md.

Limits: 4096 bytes total file size.

Availability: When assigned to the profile.

email

List, read, search, and send email through the deployment mailbox configured in Settings.

ParameterTypeRequiredNotes
actionstringYeslist, read, search, or send
folderstringNoMailbox folder; default INBOX
limitnumberNoFor list/search; default 20, max 100
uidnumberYes for readIMAP UID
querystringYes for searchSubject/from/body search
tostringYes for sendSingle recipient
subjectstringFor sendEmail subject
textstringFor sendPlain text body
htmlstringNoOptional HTML body for send

Returns: Structured JSON with messages, message, or sent — or { error: "..." } on failure. Send body max 256 KB.

Availability: When assigned and the [email] section in ~/.tinyclaw/config.ini is complete. Omitted at runtime when incomplete (omitUnavailableBuiltinTools).

Configuration prerequisites

Email

The email tool uses a deployment-global mailbox. Required keys in ~/.tinyclaw/config.ini under [email]:

  • imap_host, smtp_host
  • username, password
  • Resolvable from address
  • TLS flags as needed

Org admins configure these from the web System → Tools page.

Web search

Requires an OpenAI or Anthropic provider with a configured API key.

Knowledge base

Upload documents via the profile dashboard or API. Search only indexes extracted text from documents with status: "ready". Upload path: ~/.tinyclaw/profiles/{profileId}/data/knowledge-base/.

Safety boundaries

File tools (read_file, write_file, delete_file) are scoped to:

  • Profile workspace: ~/.tinyclaw/profiles/{profileId}/ (soul files, knowledge base, etc.)
  • Custom tools directory: ~/.tinyclaw/tools/ (or TINYCLAW_TOOLS_DIR if set)

Path guards enforce:

  • 10 MB maximum file size for reads and writes
  • No path traversal outside allowed directories
  • No reads of config.ini by basename
  • Blocked special paths (/dev/, /proc/, /sys/)

All nine builtin tool IDs are protected and cannot be deleted from the dashboard.

Next steps

  • MCP servers — extend a profile with external tools via the Model Context Protocol
  • Profiles — how to design each bot
  • Multi-tenancy — who can assign tools and manage access

Released under the MIT License.