/ Docs / MCP
MCP Reference

MCP Guide

MCP exposes ergonomic tools over Ultra endpoints while preserving protocol safety and one-time grant invariants.

Tool Reference

  • upload_file(file_path, ttl_seconds?)
  • upload_text(content, filename?, ttl_seconds?)
  • download_file(file_id_or_url, save_path?)
  • download_share(share_url, save_path?, agent_key?)

Protected Flow Automation

For policy.mode=agent, MCP can orchestrate resolve → grant → fetch when an agent key is available.

download_share(
  "https://ultra.egomonk.com/s/<shareId>",
  agent_key="agk_<keyId>.<secret>"
)
POST /api/agent/auth
GET  /api/share/{shareId}
POST /api/agent/grants
GET  /api/dl/{targetId} + X-Access-Grant

Cookbook

upload_text("hello", filename="hello.txt")
download_share("https://ultra.egomonk.com/s/shr_...")

Operational Guidance

  • Store root agk_... credentials in secure server env only.
  • Use short TTLs for sensitive transfers.
  • Treat grant errors as one-time semantics and reissue when needed.