Skip to content
Fermium

Publish your first document

What to ask your agent, what comes back, and how to update the same link.

You do not call tools yourself. You describe what you want, and the agent chooses publish_html, publish_markdown, publish_snippet, publish_file or create_upload based on what it has in hand.

Say it plainly

> Turn this analysis into a page and publish it. Keep it forever, tag it "q3-review".

A typical reply:

Published: https://fermiumusercontent.app/d/xBVNwKdi7ukQhXrWhQuz4g/
Visibility: restricted (only you, until you share it)
Expires: never
Tags: q3-review

Behind that reply is one call to publish_html with retention_days: 0 and tags: ["q3-review"]. The response the agent got back contains doc_id, slug, url, visibility, listing, retention_days, expires_at, version, total_bytes, kind and tags.

> Replace the second chart with a table and update the same link.

The agent calls update_html with the doc_id it remembers. Everyone holding the link sees the new version; the URL does not change. If the content is byte-for-byte identical, nothing happens and no new version is written. During a working session, publish once and keep updating.

Pick the right kind

You have The agent uses The reader gets
A self-contained HTML page publish_html the page as written, rendered in a sandbox
Prose, notes, a runbook publish_markdown a readable page with tables, highlighted code, task lists and mermaid diagrams, plus a raw source.md link
Code publish_snippet a dark page with line numbers, syntax highlighting and a raw link; the language is detected if not given
A screenshot, image or PDF up to 20 MiB publish_file an image viewer, or the PDF opened directly in the browser
An HTML file on disk, up to 20 MiB create_upload and one curl -T your page, rendered as-is
A video, audio file or large download, up to 2 GiB create_upload and one curl -T a player or download page
Assets for an existing HTML page put_file files reachable by relative path inside that document

Details of each kind are in Kinds and formats.

Decide who can open it

Every document starts Restricted: readers must sign in, and only you can open it until you share it. Ask for what you need:

> Share it with ada@acme.com so she can comment.
> Share it with the whole workspace.
> Make it readable by anyone with the link.
> Make it password protected. The password is "harbor-42".

The first two add grants for workspace members with share_doc and keep the document Restricted. The third becomes set_visibility(visibility="unlisted"): anyone holding the 128-bit random URL can open it. The fourth becomes set_visibility(visibility="password", password="harbor-42"); readers see an HTTP Basic prompt. In the app, the same choices are on the inspector's Access tab. See Access.

Keep it or let it go

The default is 30 days after the last update, and the expiry moves every time the document changes. Say "keep this forever" or "expire this in a week" and the agent calls set_retention. The expiry is in every response, so the agent can remind you when it hands over a link. See Expiry and retention.

Find it later

Open fermium.app/app. The new document is at the top of Recent work on Home and in Library; the q3-review tag in the Library sidebar lists it too. Select it to see its link, access, expiry, tags, files and version in the inspector. Your agent can also run list_docs (optionally with a tag) to find an existing document instead of publishing a near-duplicate.