Documarium
v1.0.3Your docs site. No editor to open.
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
list_pages List pages
Lists every page of a kept site, or of a preview given its draft_id, in one answer with no paging. Each line is a page's address and title, indented by depth, and on a kept site the date it last changed. A kept site lists the top-level pages first, then each deeper level, in alphabetical order of address within a level; a preview lists all its pages in alphabetical order of address. It is how page addresses are found: read_page reads one page in full, find_references finds the pages that state a given fact, and site_status says whether the site is published.
| Parameter | Type | Description |
|---|---|---|
draft_id | string | Which preview: the draft_id create_preview returned, a 43-character key of letters, digits, - and _ (stray quotes or punctuation around it are ignored). It is not the code in the preview's link. Leave… |
site | string | Which site: its name (like Acme Docs), its Documarium address (like acme.documarium.com) or the short name in that address (like acme); a custom domain is not accepted. Leave it out when this connecti… |
read_page Read a page
Reads one page of a kept site, or of a preview given its draft_id. It returns the page's address, its title and its full markdown; on a kept site also the date it last changed and the settings at the top of the page, as key: value lines. When no page has that address, it returns the five closest addresses instead (on a preview, every address the preview has). The markdown it returns is what a propose_edit update replaces. list_pages lists the addresses, and find_references finds which pages mention something without reading each one.
| Parameter | Type | Description |
|---|---|---|
path * | string | The page's address within the site, as list_pages shows it, like /pricing or /guides/setup. The front page's address is /, and /index means the same page. Capitals, a missing first slash and a trailin… |
draft_id | string | Which preview: the draft_id create_preview returned, a 43-character key of letters, digits, - and _ (stray quotes or punctuation around it are ignored). It is not the code in the preview's link. Leave… |
site | string | Which site: its name (like Acme Docs), its Documarium address (like acme.documarium.com) or the short name in that address (like acme); a custom domain is not accepted. Leave it out when this connecti… |
find_references Find every mention
Finds the passages in a site that state a fact, and returns each with its page address, its line numbers and its text, best match first. On a kept site it matches meaning, so passages that say the fact in other words are found too, each with a confidence from 0 to 1; if that search cannot answer in time or fails, a plain word match comes back instead and the answer says so. On a preview, given its draft_id, it matches words only. Before a fact such as a refund window, a limit or a product name changes, it shows every page that states it, so one propose_edit can change them all. read_page reads…
| Parameter | Type | Description |
|---|---|---|
query * | string | The fact to look for, in plain words, 3 to 500 characters, like how long the refund window is. On a kept site, passages that say it differently are found too. |
draft_id | string | Which preview: the draft_id create_preview returned, a 43-character key of letters, digits, - and _ (stray quotes or punctuation around it are ignored). It is not the code in the preview's link. Leave… |
site | string | Which site: its name (like Acme Docs), its Documarium address (like acme.documarium.com) or the short name in that address (like acme); a custom domain is not accepted. Leave it out when this connecti… |
history See what changed
Lists a kept site's numbered versions, newest first, a page of them at a time: each line is the version number, what changed, who changed it and the date. When older visible versions remain, the answer gives the starting_before value that lists the next page. Given compare_from and compare_to, it instead lists each page that differs between those two versions, as added, removed or the number of lines added and removed. How far back versions can be seen depends on the site's plan; older ones are still kept, and the answer says where the visible ones start. It answers what changed and when: site…
| Parameter | Type | Description |
|---|---|---|
compare_from | integer | The earlier of two version numbers to compare, as this list shows them, like 3. Give compare_to with it; one without the other is refused. A version older than the site's plan lets it see is refused. |
compare_to | integer | The later of two version numbers to compare, like 5. Give compare_from with it. |
site | string | Which site: its name (like Acme Docs), its Documarium address (like acme.documarium.com) or the short name in that address (like acme); a custom domain is not accepted. Leave it out when this connecti… |
starting_before | string | To see older versions: the version number the previous answer gave after starting_before, like 41; the list then starts at that version and goes back. Leave it out to start from the newest. |
site_status Check a site
Reports the state of one site, or of a preview given its draft_id, at the moment of the call. For a kept site: its name and address; whether readers can see it, and at which version; whether a publish is under way; when it was last published; whether the last publish failed, and at which file and line; and, when the site has published as often as its plan allows for the day or month, when waiting changes go out. Someone whose role lets them keep changes also gets the changes waiting to be kept, each with a link to read it and the reference apply_edit takes. For a preview: its link, its number…
| Parameter | Type | Description |
|---|---|---|
draft_id | string | Which preview: the draft_id create_preview returned, a 43-character key of letters, digits, - and _ (stray quotes or punctuation around it are ignored). It is not the code in the preview's link. Leave… |
site | string | Which site: its name (like Acme Docs), its Documarium address (like acme.documarium.com) or the short name in that address (like acme); a custom domain is not accepted. Leave it out when this connecti… |
propose_edit Propose a change
Stages a set of page changes (create, update, delete or move) for review, without keeping any of them. On a kept site it returns a link that shows the site with the changes for 24 hours and can be shared, the reference apply_edit takes to keep them, and any links the changes would break; readers see nothing until the set is kept and published. On a preview, given its draft_id, it only reports what the changes would do, and apply_edit with the same operations saves them. The operations are checked together: if one is refused, none is staged. A change that would take the site past its plan's roo…
| Parameter | Type | Description |
|---|---|---|
operations * | array | The changes to stage, one operation per page, 1 to 500 of them. They are staged together, all of them or none. |
draft_id | string | Which preview: the draft_id create_preview returned, a 43-character key of letters, digits, - and _ (stray quotes or punctuation around it are ignored). It is not the code in the preview's link. Leave… |
site | string | Which site: its name (like Acme Docs), its Documarium address (like acme.documarium.com) or the short name in that address (like acme); a custom domain is not accepted. Leave it out when this connecti… |
apply_edit Keep a change
Keeps changes. On a kept site it takes the proposal_id that propose_edit returned, or that site_status lists, and saves that staged set as the site's next numbered version, all at once or not at all. It does not publish: readers see the change after publish. A staged set is not kept if someone else changed the same pages in the meantime or if it is more than a day old, and the answer says which. A member whose role does not allow keeping leaves the change waiting for an editor. On a preview, given its draft_id, there is no staged set: it takes the operations themselves and saves them into the…
| Parameter | Type | Description |
|---|---|---|
draft_id | string | Which preview: the draft_id create_preview returned, a 43-character key of letters, digits, - and _ (stray quotes or punctuation around it are ignored). It is not the code in the preview's link. Leave… |
operations | array | On a preview only: the changes to save, 1 to 500, in the same form propose_edit takes, saved all at once or not at all. Not used on a kept site, where proposal_id names the staged set. |
proposal_id | string | On a kept site: the reference propose_edit returned, also listed by site_status. A reference can be kept once, within 24 hours of being proposed. Not used on a preview. |
site | string | Which site: its name (like Acme Docs), its Documarium address (like acme.documarium.com) or the short name in that address (like acme); a custom domain is not accepted. Leave it out when this connecti… |
publish Publish
Publishes a kept site: its latest kept version goes out to readers at the site's address and replaces what they saw. It answers at once, the publish starts in about a minute and readers see it shortly after, and site_status shows the progress. Only kept versions go out, so changes from propose_edit need apply_edit first, and the site needs a front page at /. Publishing needs a paid plan with room for the site; without one nothing goes out and the answer says so. When the site has already published as often as its plan allows that day or month, the version waits and goes out on its own later. A…
| Parameter | Type | Description |
|---|---|---|
draft_id | string | Which preview: the draft_id create_preview returned, a 43-character key of letters, digits, - and _ (stray quotes or punctuation around it are ignored). It is not the code in the preview's link. Leave… |
rights_confirmed | boolean | Say true only after the person has confirmed, in this conversation, that the content is theirs or they have permission to publish it. Needed once, for a site whose content was brought from somewhere e… |
site | string | Which site: its name (like Acme Docs), its Documarium address (like acme.documarium.com) or the short name in that address (like acme); a custom domain is not accepted. Leave it out when this connecti… |
subdomain | string | Only with the draft_id of a preview nobody has kept yet: the name for its web address, like acme for acme.documarium.com. 3 to 63 lower-case letters, digits and hyphens, not starting or ending with a… |
rollback Go back
Puts a kept site, or chosen pages of it, back to how they were at an earlier version. The result is saved as a new version, so no version is lost and a rollback can be undone by going back again; when nothing would change, no version is saved. If the site is published, it republishes by itself and readers see the restored pages, unless the site has already published as often as its plan allows that day or month, when it goes out on its own later. Only versions the site's plan lets it see can be chosen, by the numbers history lists. A writer on the site cannot roll back, and someone who looks a…
| Parameter | Type | Description |
|---|---|---|
to_version * | integer | The version number to go back to, as history lists it, like 4. A number that does not exist, or that is older than the site's plan lets it see, is refused, and the answer names the newest version, or… |
pages | array | The addresses of the pages to put back, like ["/pricing", "/guides/setup"], up to 500. A named page that did not exist at that version is removed; one that exists in neither version is refused. Leave… |
site | string | Which site: its name (like Acme Docs), its Documarium address (like acme.documarium.com) or the short name in that address (like acme); a custom domain is not accepted. Leave it out when this connecti… |
create_preview Create a preview site
Creates a temporary preview site from pages already converted to markdown, and returns its link and its draft_id. The preview belongs to no one until somebody keeps it, and expires if nobody does. The result says what to check, page by page, before the link is shared. It is the tool for content that has no site yet. A preview's pages are then changed with apply_edit and its draft_id; claim_draft keeps it, and publish keeps and publishes it in one call. A kept site is changed with propose_edit and apply_edit. It takes one entry per page; a record of where the content came from, exactly as it ha…
| Parameter | Type | Description |
|---|---|---|
source * | object | Where this content came from, exactly as it happened. |
attribution | string | The code a starter prompt gives to pass here, when the conversation began from one. Leave it out otherwise. |
languages | array | The site's language as a code, like en, ru or pt-BR — the language every page, title and heading is written in. |
logo_shows_name | boolean | true when the logo image itself spells the name, so the name is not printed again beside it. Leave it out otherwise. |
logo_url | string | A direct https address of the product's logo as the source shows it in its header — the mark, not a banner or a picture made for social media. Leave it out if the source has none. |
pages | array | The pages, already converted to markdown. One entry per page. |
site_name | string | The name of the product or company the site is about, as the source writes it. It is shown at the top of every page. |
claim_draft Keep this site
Keeps a preview nobody has kept yet as a site in the signed-in person's own account, at the web address named by subdomain. Its pages come over as they are and nothing is published: the site gets a private link, and readers see it only after publish. Keeping needs no paid plan. Without a subdomain, or with one that is taken, the answer offers names that are free and nothing is kept. It is the tool for keeping a preview without publishing it; publish with the same draft_id and subdomain keeps and publishes in one call, which needs a paid plan. The subdomain is the web address, not the name show…
| Parameter | Type | Description |
|---|---|---|
draft_id | string | The preview to keep: the draft_id create_preview returned, a 43-character key, not the code in the preview's link. |
subdomain | string | The name for the site's web address, like acme for acme.documarium.com: 3 to 63 lower-case letters, digits and hyphens, not starting or ending with a hyphen; some names are reserved. Left out, or take… |
set_branding Change how a site looks
Change how a site looks: its theme, main colour, typeface, header links, logo and icon, and whether it has an Articles section. Only the site's owner can do this. Give only the things to change; the rest stay as they are. The changes show from the site's next publish. Every look change (theme, Articles, colour, typeface, header links, logo and icon) waits for the owner to publish; until then it shows in the site's preview. Before turning Articles on, tell the owner that readers won't see anything yet: they can look at it in the site's Preview, change anything, then publish, or ask to turn it o…
| Parameter | Type | Description |
|---|---|---|
articles | boolean | true turns on the Articles section: pages under /articles become dated posts, listed newest first at /articles and left out of the docs sidebar. false turns it off, and those pages go back into the si… |
draft_id | string | Which preview: the draft_id create_preview returned, a 43-character key of letters, digits, - and _ (stray quotes or punctuation around it are ignored). It is not the code in the preview's link. Leave… |
font | string | The typeface: system, serif, mono, humanist, grotesque. |
header_links | array | Up to 4 links for the header, each a label and an address starting with https://. They replace the current set. |
icon_url | string | A direct https address of the small icon for the browser tab: PNG, JPEG, WebP or SVG, up to 1 MB. It is fetched once from that address; an address that redirects, is private or is not https is refused… |
images_are_ours | boolean | Say true only when the owner has told you the pictures are theirs to use. Otherwise they are kept but not shown until the owner confirms them. |
languages | array | The site's language as a code, like en, ru or pt-BR — the language every page, title and heading is written in. |
logo_shows_name | boolean | true when the logo image itself spells the name, so the name is not printed again beside it. Leave it out otherwise. |
logo_url | string | A direct https address of the logo — PNG, JPEG, WebP or SVG, up to 1 MB. An empty value removes the logo. |
primary_color | string | The main colour as a hex code of six or three digits, with or without #, like #2e5fa3 or #25a. A colour that would not stay readable on light and dark screens is refused. |
site | string | Which site: its name (like Acme Docs), its Documarium address (like acme.documarium.com) or the short name in that address (like acme); a custom domain is not accepted. Leave it out when this connecti… |
site_name | string | The name shown at the top of every page. |
theme | string | The theme preset: base, slab, space or paper. |