ReboFilesDocs
Start3
What is ReboFiles
Getting started
Demos to run
Put it in your app6
React component
Headless: your own UI
Without a framework
Styling and themes
Keyboard and accessibility
Languages
Files9
Uploads
Previews and the viewer
Search
Live changes and large folders
Comments
Starred and fields
Versions, trash and space
Download as .zip
Word documents
The server14
The route
Frameworks and sign-in
Who may do what
Storage: S3, GCS, Azure and disk
Checking uploads
Metadata: SQLite and Postgres
Database schema
Sharing and links
Activity and notifications
Hooks, logs and limits
Retention, holds and export
Desktop and other origins
Sync a folder
Going to production
Together1
AI assistants (MCP)
Reference5
Packages
Components and hooks
Client API
HTTP routes
Status and roadmap
↑↓ to move↵ to openEsc to close38 pages

Together AI assistants (MCP)

AI assistants (MCP)

@rebofiles/mcp gives an assistant the drive as tools: list, search, read, write text, rename, move, colour and put in the trash. Each is asked of the drive’s routes with the person’s own rights, so authorize is asked for the assistant too.
HTTP

In your application, over HTTP

Beside the drive’s route: it forwards the authorization and cookie of each request to the drive, so a token of the person’s is enough.

// app/api/mcp/route.ts, in Next.js
import { createMcpHandler } from '@rebofiles/mcp';

export const POST = createMcpHandler({ base: 'https://acme.com/api/files' });
claude mcp add --transport http rebofiles https://acme.com/api/mcp --header "Authorization: Bearer …"

headers says otherwise what the drive is asked with; fetch gives the drive’s handler itself, to ask it in the same process; origins the origins a browser may call it from besides its own.

stdio

On your computer, over stdio

For Claude Desktop and other clients that start a command.

{
  "mcpServers": {
    "rebofiles": {
      "command": "npx",
      "args": ["rebofiles-mcp"],
      "env": { "REBOFILES_URL": "https://acme.com/api/files", "REBOFILES_TOKEN": "…" }
    }
  }
}
Safety

What an assistant may touch

  • Only what its person may: every tool goes through the drive’s routes, identify and authorize.
  • Nothing for good: it may put in the trash, not delete; it may not share. What it does can be undone from the trash or the versions.
  • What the server refuses comes back to the model in words, for it to do something else.
Tools

Every tool

As the server tells them to the assistant.

ToolTypeWhat it does
list_folderreadsWhat is in a folder of the drive, folders first, or at the top of My files. Gives the id of each, for the other tools.
search_textreadsFiles whose text has every word of the query, in any case and with or without accents, with a piece of the text around what was found: text files and Word documents, as they were read when uploaded.
get_inforeadsOne file or folder: its type, size, owner, when it changed and by whom, where it is, who it is shared with, and its versions.
read_filereadsThe text of a file: plain text, Markdown, CSV, JSON and the like, and Word documents (.docx) when the server has Rebodocs. Of a version, when given. Not pictures or PDFs. Up to a megabyte.
list_recentreadsThe files changed last, that the one the assistant works for may read, the latest first.
list_sharedreadsWhat others shared with the one the assistant works for.
get_activityreadsWho did what to a file or a folder, and, of a folder, to what is right inside it: made, uploaded, renamed, moved, put in the trash, shared. The newest first.
list_commentsreadsWhat people said of a file or a folder, each thread with its replies under it, and whether it was resolved.
add_commentwritesA comment on a file or a folder, in the name of the one the assistant works for, seen by everyone who may read it; or a reply under another, with its id. Names with @ are told.
create_folderwritesA new folder; with "(2)" after its name when the name is taken there.
create_text_filewritesA new file with the text given, its type from its name (.md, .csv, .json, .txt…); with "(2)" after its name when the name is taken there.
update_text_filewritesThe text given becomes the file as it is now; what it was stays as its previous version, to restore.
restore_versionwritesAn earlier version of a file becomes the file as it is now, as a new version: the one it was stays, so this too can be undone.
renamewritesA file or folder given another name; refused when another in the same folder has it.
set_folder_colorwritesA folder given a colour, to tell it apart at a glance: red, orange, yellow, green, teal, blue, purple, pink, gray; or "none" for the drive's own.
movewritesA file or folder put into another folder, or at the top of My files; refused when the name is taken there.
move_to_trashwritesInto the trash, with what is inside it; restore takes it out. Nothing is deleted for good here.
restorewritesBack to the folder it was in, or to the top when that folder is gone; with "(2)" when its name was taken meanwhile.
Rebodocs

Word documents, with Rebodocs

With @rebodocs/mcp installed, the drive’s .docx are read and edited with Rebodocs’ own tools, each change saved as a version.

ToolWhat it does
create_documentA new, empty Word document (.docx) in the drive, to write in with insert_paragraphs (after_paragraph 0); with "(2)" after its name when the name is taken there.
get_overviewA summary of the document: how long it is, its headings with the paragraph each is at, its template variables, its notes and its paragraph styles. Start here.
read_documentThe text of the document, one paragraph a line, each with its number in brackets and, in parentheses, its style and its table cell when it has them. A long document comes in parts: ask for the next with "from".
read_formattingHow paragraphs look: for each, its style, alignment, indents, the room before and after it and its line spacing; then each stretch of its text that looks different, with its font, its size and whether it is bold, italic, underlined or coloured. Read it before rewriting or adding text that has to look like what is there.
compare_documentsWhat changed between this document and another version of it: an earlier version of the same file (the one before the current, unless "version" says), or another document ("other"). The paragraphs put in, taken out and changed, of the text and of its headers, footers, notes and text boxes, and the notes on the text, with what was taken out as [-…-] and what was put in as {+…+}. Tracked changes are compared as if accepted, as Word does. By default the other is the earlier one; with "file_is" "later", it is the later one.
find_textEvery place a text is found, with the paragraph it is in and the words around it.
replace_textPuts a text in place of another, in the formatting of what was there: its font, its size and its marks. The text to find has to be inside one paragraph. An empty "replace" deletes it. To write a whole paragraph anew, as in a translation, rewrite_paragraph keeps more of its look.
rewrite_paragraphWrites the whole text of a paragraph anew, as to translate it or say it otherwise, and keeps how it looks: its style, alignment, indents and spacing, and the font, size and colour most of its text has. Words that were set apart (bold, italic…) are kept so by giving the text in "segments". A paragraph with a picture is changed with replace_text instead.
insert_paragraphsWrites new paragraphs after a paragraph. Each has its text and, when wanted, a style (a heading, for one) or a list. With "like_paragraph" a new one looks like a paragraph that is there: its alignment, indents, spacing, list, and the font, size and colour of most of its text. Text between double braces, like {{cliente}}, is a template variable.
delete_paragraphsDeletes whole paragraphs, from one to another. Not for the paragraphs of a table.
edit_documentMakes several changes in one go, each as the tool it names would make it, and all of them or none. Every paragraph number in them is the one read_document showed before the first edit: the numbers do not move as the edits before insert or delete paragraphs, so there is no need to read again between them. A text to find is looked for as the document is when its edit comes. Each edit is an object with "tool" (replace_text, rewrite_paragraph, insert_paragraphs, delete_paragraphs, set_style, set_list, format_text, format_paragraphs, set_link, add_note, insert_page_break, move_section, set_cell_text, renumber_clauses) and the arguments of that tool beside it. The text of the document only: for a header or a footer, use each tool alone with "area".
move_sectionMoves a heading and everything under it, down to the next heading of its level or above (a clause with its text, a chapter with its clauses), to another place, as dragging it in the outline of the editor does. The paragraphs keep their look, their notes and their pictures. After it, renumber_clauses puts the numbers of the headings in order.
renumber_clausesPuts in order the numbers written at the start of the headings of clauses, after one was put in, taken out or moved: "Primera.", "Segunda."… in words, "CLÁUSULA 3.", or "IV.", each kept as it is written (its capitals, "Primera" or "Primero", "Décima Primera" or "Undécima"). The headings of one series are those that begin the same way and have the same style; the longest is renumbered, or the one of "paragraph". It says the places of the text that name a clause by its number ("según la cláusula Tercera"), for you to check: it does not change them.
set_cell_textWrites the text of a cell of a table, by its table, row and cell, as read_document shows them ("table 1, row 2, cell 3"): what the cell had goes, empty or not, and the text takes the look most of it had. A new line in "text" starts another paragraph in the cell. The way to fill the cells of a row just put in.
set_styleGives paragraphs a paragraph style: a heading, a title, the normal text. get_overview lists the styles of the document.
set_listMakes paragraphs the items of a list with bullets or with numbers, or takes them out of the list they are in.
format_textChanges how a text looks: its font, its size, bold, italic, underlined, struck through, its colour or the highlight behind it. The text is one found by "find", or whole paragraphs, from "from" to "to". Give only what is to change.
format_paragraphsChanges how paragraphs sit on the page: their alignment, indents, the room before and after them, their line spacing, their tab stops, and whether they keep with the next one. Give only what is to change.
add_notePuts a note on a text: a comment in the margin, as in Word, that does not change the document. The way to review a document, or to ask about something in it.
list_notesThe notes of the document: the id of each, who wrote it, the text it is about and what it says.
remove_noteTakes a note away; the text it was about stays.
track_changesSwitches tracked changes on or off, as Word's "Track changes". While on, every change made to the text, by any tool, stays marked for a person to accept or reject: what was put in as {+…+} and what was taken out as [-…-] in read_document.
list_changesThe tracked changes of the document, numbered: who made each, whether it put text in, took it out, moved it or changed its formatting, the text, and the paragraph it is in. Text one person put in and another took out is two changes. accept_changes and reject_changes take these numbers.
accept_changesAccepts tracked changes: what was put in stays, unmarked, and what was taken out goes. With "changes", the ones of those numbers in list_changes; with "author", all of that person's; without either, all of them. A move is accepted whole.
reject_changesRejects tracked changes: what was put in goes, and what was taken out comes back. With "changes", the ones of those numbers in list_changes; with "author", all of that person's; without either, all of them. A move is rejected whole.
list_variablesThe template variables of the document, written between double braces: the name of each, how many times it is used and the formats it is given (capitals, a date, money…).
fill_variablesPuts a value in place of each template variable that is given one, everywhere in the document (its headers, footers, notes and text boxes too), in the format the variable asks for, and writes out each block given one: {{#name}} … {{/name}} is repeated for each item of a list (a row of a table, paragraphs, or text), kept for true and taken out for false; {{^name}} … {{/name}} the other way round. Dates go as YYYY-MM-DD and numbers plain (1234.5): the format writes them out. Variables and blocks with no value stay as they are.
insert_tablePuts in a table after a paragraph, with the text of each cell. Every row must have the same number of cells.
insert_signaturesPuts in a block of signatures after a paragraph: side by side, each with its title (such as ASESOR and CLIENTE), a line to sign on and the name under it.
edit_tableChanges the shape or the look of a table that is there. "paragraph" is any paragraph of the cell to act on (read_document says which cell each is in). Actions: insert_row_above, insert_row_below, insert_column_left, insert_column_right, delete_row, delete_column, merge_cells (from "paragraph" to "to_paragraph"), split_cell (undoes a merge), set_column_widths (with "widths_cm", one for each column), set_row_height (with "height_cm", 0 for as tall as it holds, and "exact"), header_row_on and header_row_off (the rows down to this one repeat at the top of each page), align_cells_top, align_cells_center, align_cells_bottom, text_level, text_up and text_down (the text of the cells set level, or vertically to read from the bottom up or from the top down; its lines are as long as the row is tall), shade_cells (with "shade"), cell_lines (with "line_style", "line_width_pt" and "line_color"; "line_style" none takes them away), show_borders, hide_borders (the whole table), keep_together (the whole table on one page, as a block of signatures should be: no row is cut, and each row stays with the next), allow_split (undoes it) and delete_table. The actions on cells take "to_paragraph" for several. The text of a cell is changed with replace_text and insert_paragraphs.
insert_imagePuts a picture from a file (PNG, JPEG or GIF) in a paragraph of its own after a paragraph. It goes at its own size, or as wide as the text when it is wider, unless "width_cm" says otherwise.
edit_imageChanges a picture that is in the document: "resize" it (with "width_cm"; its height follows), "move" it to a paragraph of its own after another (with "after_paragraph"), "align" the paragraph it is in (with "align"), "describe" it for whoever cannot see it (with "description", what a screen reader says; empty takes it away), or "delete" it. read_document shows a picture as [image], or [image: its description].
set_columnsSets text in columns, as a newsletter: one column, two, three, with a line between them or not. With "from" and "to" only those paragraphs go in columns, in a section of their own on the same page; with "paragraph" alone, the whole section that paragraph is in.
insert_column_breakMakes the text from a place start at the top of the next column, in a section set in columns: before a text found with "find", or at the start of a paragraph.
insert_footnotePuts a note at the foot of the page: its number goes in the text right after a text found with "find" (or at the end of paragraph "at_paragraph"), and the note says "text". Notes are numbered by where they are in the text.
insert_endnotePuts a note at the end of the document, after its text (or at the end of its section, when the document puts them there): its number (i, ii, iii) goes in the text right after a text found with "find" (or at the end of paragraph "at_paragraph"), and the note says "text". Notes at the end are numbered by where they are in the text, apart from those at the foot of the page.
insert_text_boxPuts a text box in: a box with a thin black line, anchored to a paragraph (at the end of "after_paragraph"; 1 when left out), at the left of the column, with the text of that paragraph going round it. It is as tall as its text. Its text is "text"; each line of it a paragraph. Change it later with area "textbox".
set_letterheadGives the document a letterhead: a picture from a file (PNG, JPEG or GIF), stretched over the whole page behind the text of every page, in place of the one it had. For a PNG, the top and bottom margins grow to clear what it prints there. With "remove", takes it away; the rest of the header stays. get_overview says whether the document has one.
set_page_setupChanges the size of the paper, its orientation, or its margins; and, for one section of a document of several, whether it has a header and footer of its own and whether its first page has its own. Give only what is to change. Without "section", the page of every section changes.
set_page_numberPuts the number of the page in the header or the footer of every page, moves it, changes how it reads, or takes it away.
insert_page_breakMakes the text after a paragraph start on a new page.

A save made meanwhile by someone else is found by asking the drive just before writing, and not written over.