roam_create_table
Create structured tables in Roam by providing headers and rows. Automates the complex nested block structure, ensuring valid formatting and reducing manual errors.
Instructions
Create a table in Roam with specified headers and rows. This tool abstracts the complex nested structure that Roam tables require, making it much easier to create properly formatted tables.
Why use this tool:
Roam tables require precise nested block structures that are error-prone to create manually
Automatically handles the {{[[table]]}} container and nested column structure
Validates row/column consistency before execution
Converts empty cells to spaces (required by Roam)
Example: A table with headers ["", "Column A", "Column B"] and rows [{label: "Row 1", cells: ["A1", "B1"]}] creates a 2x3 table.
IMPORTANT: call roam_get_guidelines for this graph once per session, and load the Roam Markdown Cheatsheet, before using this tool.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| rows | Yes | Data rows for the table. Each row has a label (first column) and cells (remaining columns). | |
| graph | No | Target graph key from ROAM_GRAPHS config. Defaults to ROAM_DEFAULT_GRAPH. Only needed in multi-graph mode. | |
| order | No | Optional: Position under the parent. Can be a number (0-based) or "first"/"last". Defaults to "last". | last |
| headers | Yes | Column headers for the table. The first header is typically empty (for the row label column). Example: ["", "Option A", "Option B"] | |
| write_key | No | Write confirmation key. Required for write operations on non-default graphs when write_key is configured. | |
| parent_uid | Yes | The UID of the parent block or page where the table should be created. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| error | No | Present only when success is false. | |
| success | Yes | ||
| uid_map | No | Placeholder name → generated UID. Present only on success. | |
| table_uid | No | ||
| actions_attempted | No | ||
| validation_passed | No |