All Documents
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Overview
The Craft Space API provides programmatic access to your entire Craft space - the top-level container for all your documents and organizational structure.
Space Structure
A Craft space organizes content through:
- Folders: Hierarchical folders to organize documents
- Documents: Individual documents within locations
- Blocks: The content within documents (text, pages, collections, media)
- Tasks: Task management across inbox, daily notes, and documents
Key Concepts
Locations: Documents exist in locations. A location is either a folder or one of the built-in locations: 'unsorted' (default for new documents), 'templates', or 'trash' (recently deleted).
Document IDs: A document ID is the same as its root block ID. Use a document ID with GET /blocks to fetch the document's content.
Space Discovery: Use GET /folders to see all locations, then GET /documents to list documents within a specific location.
Document Organization: Documents can be created in, moved between, and deleted from locations. Use folder and document management endpoints to organize your space.
Tasks: Tasks can be managed across the space. Use GET /tasks with scope filters (inbox, active, upcoming, logbook) to retrieve tasks, and other task endpoints to create, update, or delete them.
Development Tips
- Start with
GET /foldersto discover all locations in the space - Use
GET /documentswith a location filter to list documents in a specific location - Create new locations with
POST /folders - Use
POST /documentsto create new documents in a specific location - Access document content with
GET /blocks?id={documentId} - Search across the entire space with
GET /documents/search - Use
PUT /documents/moveto move documents between locations - Manage tasks with
GET /tasks?scope=activeto retrieve due tasks, or use other scopes (inbox, upcoming, logbook)
Note for AI
When implementing functionality using this API, always make actual calls to these endpoints and verify the responses. Do not simulate or mock the API interactions or use hard-coded values on the client-side - use the real endpoints to ensure proper functionality and data handling.
IMPORTANT: This is a production server connected to real user data. Only perform testing operations that can be safely rolled back:
- Safe: Reading data (
GETrequests), creating test content that you delete immediately after - Safe: Modifying content if you can restore it to its original state
- Safe: Moving blocks if you can move them back to their original position
- Unsafe: Permanent deletions, modifications without backup, or any changes you cannot reverse
Always verify rollback operations work before considering a test complete.
Fetch Blocks
Summary
Fetches content from any document in the space. Use 'id' query parameter to specify which block to fetch.
Use Accept header application/json for structured data, text/markdown for rendered content.
Content Rendering: Text blocks contain markdown formatting and markdown formatted output may include structural tags like <page></page>, etc. When displaying content, consider rendering markdown as formatted text or cleaning up the syntax for plain text display.
Full Space Access: This connection has access to all documents across all locations in the space. Block links and relations within the space are preserved.
Tip: Start with GET /folders to see all locations, then GET /documents to list documents by location. Use document IDs as the 'id' parameter to fetch content.
Query Parameters
Fetches the root page of a Daily Note for the specified date. Accepts ISO format YYYY-MM-DD or relative dates: 'today', 'tomorrow', 'yesterday'. Mutually exclusive with 'id' - use this to fetch a Daily Note's root page, or use 'id' to fetch a specific block.
Fetches a specific page block by its ID. Use this when you want to retrieve a particular block directly. Mutually exclusive with 'date' - omit 'date' entirely when using this parameter.
The maximum depth of blocks to fetch. Default is -1 (all descendants). With a depth of 0, only the specified block is fetched. With a depth of 1, only direct children are returned.
-1Whether to fetch metadata (comments, createdBy, lastModifiedBy, lastModifiedAt, createdAt) for the blocks. Default is false.
Response Body
Successfully retrieved data
"text"h1-h4, body, caption for text blocks. card/page for page blocks with visual styling.
"card" | "page" | "h1" | "h2" | "h3" | "h4" | "caption" | "body"default is left
"left" | "center" | "right" | "justify""system" | "serif" | "rounded" | "mono"Applies for 'card' textStyle. Small and square are for laying out in multi-column (2 or 3 depending on screen size, multi-column is only supported for certain block types, not for text). Regular and large are full width cards.
"small" | "square" | "regular" | "large"The markdown content of the block.
The indentation level of the block.
0 <= value <= 5"none" | "bullet" | "numbered" | "toggle" | "task"7-character hex code (e.g., #RRGGBB). Case-insensitive. Auto-adjusted for readability, with dark variant auto-generated.
^#[0-9a-fA-F]{6}$only interpreted, if listStyle is 'task'
"page"The title of the page block.
The indentation level of the block.
0 <= value <= 5"none" | "bullet" | "numbered" | "toggle" | "task"7-character hex code (e.g., #RRGGBB). Case-insensitive. Auto-adjusted for readability, with dark variant auto-generated.
^#[0-9a-fA-F]{6}$only interpreted, if listStyle is 'task'
h1-h4, body, caption for text blocks. card/page for page blocks with visual styling.
"card" | "page" | "h1" | "h2" | "h3" | "h4" | "caption" | "body"default is left
"left" | "center" | "right" | "justify""system" | "serif" | "rounded" | "mono"Applies for 'card' textStyle. Small and square are for laying out in multi-column (2 or 3 depending on screen size, multi-column is only supported for certain block types, not for text). Regular and large are full width cards.
"small" | "square" | "regular" | "large"Content of the page block. Array of blocks. Follows the same block schema.
"collectionItem"The title of the block.
The properties of the block.
Empty Object
The title of the collection item
Content of the collection item block's page. Array of blocks. Follows the same block schema.
"image""fit" | "fill""auto" | "fullWidth"The markdown content of the block.
The indentation level of the block.
0 <= value <= 5"none" | "bullet" | "numbered" | "toggle" | "task"7-character hex code (e.g., #RRGGBB). Case-insensitive. Auto-adjusted for readability, with dark variant auto-generated.
^#[0-9a-fA-F]{6}$only interpreted, if listStyle is 'task'
"video""fit" | "fill""auto" | "fullWidth"The markdown content of the block.
The indentation level of the block.
0 <= value <= 5"none" | "bullet" | "numbered" | "toggle" | "task"7-character hex code (e.g., #RRGGBB). Case-insensitive. Auto-adjusted for readability, with dark variant auto-generated.
^#[0-9a-fA-F]{6}$only interpreted, if listStyle is 'task'
"file"The name of the file.
"small" | "regular" | "card"The markdown content of the block.
The indentation level of the block.
0 <= value <= 5"none" | "bullet" | "numbered" | "toggle" | "task"7-character hex code (e.g., #RRGGBB). Case-insensitive. Auto-adjusted for readability, with dark variant auto-generated.
^#[0-9a-fA-F]{6}$only interpreted, if listStyle is 'task'
"drawing"The markdown content of the block.
The indentation level of the block.
0 <= value <= 5"none" | "bullet" | "numbered" | "toggle" | "task"7-character hex code (e.g., #RRGGBB). Case-insensitive. Auto-adjusted for readability, with dark variant auto-generated.
^#[0-9a-fA-F]{6}$only interpreted, if listStyle is 'task'
"whiteboard"The markdown content of the block.
The indentation level of the block.
0 <= value <= 5"none" | "bullet" | "numbered" | "toggle" | "task"7-character hex code (e.g., #RRGGBB). Case-insensitive. Auto-adjusted for readability, with dark variant auto-generated.
^#[0-9a-fA-F]{6}$only interpreted, if listStyle is 'task'
"table"The markdown content of the block.
The indentation level of the block.
0 <= value <= 5"none" | "bullet" | "numbered" | "toggle" | "task"7-character hex code (e.g., #RRGGBB). Case-insensitive. Auto-adjusted for readability, with dark variant auto-generated.
^#[0-9a-fA-F]{6}$only interpreted, if listStyle is 'task'
"collection"The markdown content of the block.
The indentation level of the block.
0 <= value <= 5"none" | "bullet" | "numbered" | "toggle" | "task"7-character hex code (e.g., #RRGGBB). Case-insensitive. Auto-adjusted for readability, with dark variant auto-generated.
^#[0-9a-fA-F]{6}$only interpreted, if listStyle is 'task'
"code"The raw code of the block.
"ada" | "bash" | "cpp" | "cs" | "css" | "dart" | "dockerfile" | "matlab" | "go" | "groovy" | "haskell" | "html" | "java" | "javascript" | "json" | "julia" | "kotlin" | "lua" | "markdown" | "objectivec" | "perl" | "php" | "prolog" | "plaintext" | "python" | "r" | "ruby" | "rust" | "scala" | "shell" | "sql" | "swift" | "typescript" | "vbnet" | "xml" | "yaml" | "math_formula" | "other"The markdown content of the block.
The indentation level of the block.
0 <= value <= 5"none" | "bullet" | "numbered" | "toggle" | "task"7-character hex code (e.g., #RRGGBB). Case-insensitive. Auto-adjusted for readability, with dark variant auto-generated.
^#[0-9a-fA-F]{6}$only interpreted, if listStyle is 'task'
"richUrl""small" | "regular" | "card"The markdown content of the block.
The indentation level of the block.
0 <= value <= 5"none" | "bullet" | "numbered" | "toggle" | "task"7-character hex code (e.g., #RRGGBB). Case-insensitive. Auto-adjusted for readability, with dark variant auto-generated.
^#[0-9a-fA-F]{6}$only interpreted, if listStyle is 'task'
"line"pageBreak lineStyle is just a strong visual separator within a page (chunks to page-looking groups visually). It does not affect the page block hierarchy.
"regular""strong" | "regular" | "light" | "extraLight" | "pageBreak"The markdown content of the block.
The indentation level of the block.
0 <= value <= 5"none" | "bullet" | "numbered" | "toggle" | "task"7-character hex code (e.g., #RRGGBB). Case-insensitive. Auto-adjusted for readability, with dark variant auto-generated.
^#[0-9a-fA-F]{6}$only interpreted, if listStyle is 'task'
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Insert Blocks
Summary
Insert content into any document in the space. Content can be provided as structured JSON blocks. Use position parameter to specify where to insert (via parent blockId or sibling blockId). Returns the inserted blocks with their assigned block IDs for later reference.
Request Body
The blocks to insert, as JSON array
JSON object to insert the content at. Use 'date' to target a Daily Note, 'pageId' to target a specific block, or 'siblingId' for relative positioning.
"start" | "end"Only page/text/card blocks can be parents. Text blocks auto-convert to page when receiving children.
ISO YYYY-MM-DD or 'today'/'tomorrow'/'yesterday'. Defaults to 'today'.
"today""start" | "end""before" | "after"The markdown content to insert, which will be converted to a flat list of blocks at insert position. Separate each paragraph and heading with two newlines. Separate each list item with one newline. The first item in any list cannot be empty. Craft-specific tokens are HTML tags.:
<callout></callout>for callouts. Can be used to wrap multiple paragraphs/images/etc.<caption></caption>for caption text style. Can be used to wrap a paragraph.<highlight color=''></highlight>for highlights - color is optional. Can only be used inline.<page><pageTitle>Title</pageTitle><content>Content</content></page>for nested page/card structures - where title supports inline formatting, pages can be nested, and content accepts same markdown as top level markdown. Supports<page textStyle='card' cardLayout='small|square|...'>for card styled page blocks.
Special link formats:
[text](block://blockId)for block links - links to specific blocks by their ID[text](date://YYYY-MM-DD)for date links - links to daily notes by date
JSON object to insert the content at. Use 'date' to target a Daily Note, 'pageId' to target a specific block, or 'siblingId' for relative positioning.
"start" | "end"Only page/text/card blocks can be parents. Text blocks auto-convert to page when receiving children.
ISO YYYY-MM-DD or 'today'/'tomorrow'/'yesterday'. Defaults to 'today'.
"today""start" | "end""before" | "after"Response Body
Successfully created resource
Array of blocks
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Delete Blocks
Summary
Delete content from any document in the space. Removes specified blocks by their IDs.
Request Body
The IDs of the blocks to delete
Response Body
Successfully deleted resource
Array of deleted block IDs
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Update Blocks
Summary
Update content in any document in the space. For text blocks, provide updated markdown content. Only the fields that are provided will be updated.
Request Body
The blocks to update, as JSON array. Only the fields that are provided will be updated.
Response Body
Successfully updated resource
Array of blocks
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Move Blocks
Summary
Move blocks to reorder them or move them between any documents across all locations in the space. Returns the moved block IDs.
Request Body
The IDs of the blocks to move
JSON object to move the content to. Use 'date' to target a Daily Note, 'pageId' to target a specific block, or 'siblingId' for relative positioning.
"start" | "end"Only page/text/card blocks can be parents. Text blocks auto-convert to page when receiving children.
ISO YYYY-MM-DD or 'today'/'tomorrow'/'yesterday'. Defaults to 'today'.
"today""start" | "end""before" | "after"Response Body
Successfully moved resource
Array of moved block IDs
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Search in Document
Summary
Search within a single document. Use documents_search first to find documents, then this tool for more context with before/after blocks.
Query Parameters
The block ID (document or page) to search within.
The search patterns to look for. Patterns must follow RE2-compatible syntax, which supports most common regular-expression features (literal text, character classes, grouping alternation, quantifiers, lookaheads, and fixed-width lookbehinds.
Whether the search should be case sensitive. Default is false.
The number of blocks to include before the matched block.
5The number of blocks to include after the matched block.
5Response Body
Successfully retrieved data
Array of search matches with structured context
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Search across Documents
Summary
Search content across all documents in the space using relevance-based ranking. Supports flat date filter fields (createdDateGte, createdDateLte, lastModifiedDateGte, lastModifiedDateLte, dailyNoteDateGte, dailyNoteDateLte) for time-based queries and location object for filtering by folder.
- Searches the entire space (all locations)
- Relevance-based ranking (top 20 results)
- Content snippets with match highlighting
- Filter by date ranges or location
Example Use Cases:
- Find all mentions of a topic anywhere in the space
- Search for specific content across all documents
- Search documents within a specific location or folder
Query Parameters
Search terms to include in the search. Can be a single string or array of strings.
Search terms to include in the search. Patterns must follow RE2-compatible syntax, which supports most common regular-expression features (literal text, character classes, grouping alternation, quantifiers, lookaheads, and fixed-width lookbehinds.
The document IDs to filter. Cannot be used together with 'location' or 'folderIds'. If not provided, all documents will be searched. Can be a single string or array of strings.
Whether to include document metadata (lastModifiedAt, createdAt) in each search result. Default is false.
Filter by virtual location: 'unsorted', 'trash', 'templates', or 'daily_notes'. Cannot be used together with 'folderId' or 'documentIds'. If neither 'location' nor 'folderId' is specified, searches/lists all documents.
"unsorted" | "trash" | "templates" | "daily_notes"Filter by specific folders (includes subfolders recursively). Cannot be used together with 'location' or 'documentIds'. If neither 'location' nor 'folderIds' is specified, searches all documents. Can be a single string or array of strings.
Only include documents created on or after this date. Accepts ISO format YYYY-MM-DD or relative dates: 'today', 'tomorrow', 'yesterday'.
Only include documents created on or before this date. Accepts ISO format YYYY-MM-DD or relative dates: 'today', 'tomorrow', 'yesterday'.
Only include documents modified on or after this date. Accepts ISO format YYYY-MM-DD or relative dates: 'today', 'tomorrow', 'yesterday'.
Only include documents modified on or before this date. Accepts ISO format YYYY-MM-DD or relative dates: 'today', 'tomorrow', 'yesterday'.
Only include daily notes on or after this date. Accepts ISO format YYYY-MM-DD or relative dates: 'today', 'tomorrow', 'yesterday'.
Only include daily notes on or before this date. Accepts ISO format YYYY-MM-DD or relative dates: 'today', 'tomorrow', 'yesterday'.
Response Body
Successfully retrieved data
Array of individual search matches across documents, ordered by document relevance
Create an API connection in the Imagine tab in Craft, and paste your API URL here
List Collections
Summary
List all collections across the entire space. Returns collections from all documents regardless of their location.
Query Parameters
The document IDs to filter. If not provided, collections in all documents will be listed. Can be a single string or array of strings.
Response Body
Success
Array of collections in the specified documents
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Get Collection Schema
Summary
Get collection schema in JSON Schema format
Path Parameters
Query Parameters
The format to return the schema in. Default: json-schema-items. - 'schema': Returns the collection schema structure that can be edited - 'json-schema-items': Returns JSON Schema for addCollectionItems/updateCollectionItems validation
"json-schema-items""schema" | "json-schema-items"Response Body
Successfully retrieved data
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Get Collection Items
Summary
Get all items from a collection
Path Parameters
Query Parameters
The maximum depth of nested content to fetch for each collection item. Default is -1 (all descendants). With a depth of 0, only the item properties are fetched without nested content.
-1Response Body
Successfully retrieved data
Array of items in the collection.
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Add Collection Items
Summary
Add new items to a collection. Two-way relations are synced automatically in the background - only set one side for consistency.
Path Parameters
Request Body
Items to add to the collection. Each item should match the collection's schema (properties will be validated at runtime).
Allow adding new options to select properties. When true, new values will be automatically added to the collection schema. Never add new option values without explicit user intent.
Response Body
Successfully created resource
Array of successfully added items
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Delete Collection Items
Summary
Delete collection items (also deletes content inside items)
Path Parameters
Request Body
IDs of the items to delete from the collection.
Response Body
Successfully deleted resource
Array of successfully deleted item IDs
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Update Collection Items
Summary
Update collection items. Two-way relations are synced automatically in the background - only set one side for consistency.
Path Parameters
Request Body
Items to update in the collection. Each item should have an id and optionally properties matching the collection's schema (properties will be validated at runtime).
Allow adding new options to select properties. When true, new values will be automatically added to the collection schema. Never add new option values without explicit user intent.
Response Body
Successfully updated resource
Array of successfully updated items
Create an API connection in the Imagine tab in Craft, and paste your API URL here
List Documents
Summary
List documents in the space. Without location or folderIds filters, returns ALL documents (may be large). Recommended: use GET /folders first to see available locations and document counts.
Query Parameters
Filter by virtual location: 'unsorted', 'trash', 'templates', or 'daily_notes'. Cannot be used together with 'folderId' or 'documentIds'. If neither 'location' nor 'folderId' is specified, searches/lists all documents.
"unsorted" | "trash" | "templates" | "daily_notes"Filter by specific folder (includes subfolders recursively). Cannot be used together with 'location' or 'documentIds'. If neither 'location' nor 'folderId' is specified, lists all documents.
Whether to include metadata (lastModifiedAt, createdAt) in the response. Default is false.
Only include documents created on or after this date. Accepts ISO format YYYY-MM-DD or relative dates: 'today', 'tomorrow', 'yesterday'.
Only include documents created on or before this date. Accepts ISO format YYYY-MM-DD or relative dates: 'today', 'tomorrow', 'yesterday'.
Only include documents modified on or after this date. Accepts ISO format YYYY-MM-DD or relative dates: 'today', 'tomorrow', 'yesterday'.
Only include documents modified on or before this date. Accepts ISO format YYYY-MM-DD or relative dates: 'today', 'tomorrow', 'yesterday'.
Only include daily notes on or after this date. Accepts ISO format YYYY-MM-DD or relative dates: 'today', 'tomorrow', 'yesterday'.
Only include daily notes on or before this date. Accepts ISO format YYYY-MM-DD or relative dates: 'today', 'tomorrow', 'yesterday'.
Response Body
Success
Array of documents in the specified location
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Create Documents
Summary
Create one or more documents in the space. Specify location as 'unsorted' (default), 'templates', or provide a folderId. Cannot create in 'trash'.
Request Body
Array of documents to create
Where to create the documents. Cannot be trash. Default is unsorted. Use { destination: "unsorted" | "templates" } or { folderId: "..." }.
Move to unsorted or templates
Move to a specific folder
The ID of the destination folder
Response Body
Successfully created resource
Array of created documents with their IDs, titles, and clickable links
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Delete Documents
Summary
Soft-delete documents by moving them to trash. Use documents_move to restore.
Request Body
The IDs of the documents to delete (soft-delete to trash)
Response Body
Successfully deleted resource
Array of IDs of the deleted documents
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Move Documents
Summary
Move documents between locations in the space. Destination cannot be 'trash' - use documents_delete instead. Use this to restore documents from trash. Note: Daily notes cannot be moved.
Request Body
The IDs of the documents to move
Where to move the documents. Use { destination: "unsorted" | "templates" } or { folderId: "..." }. To delete, use DELETE /documents.
Move to unsorted or templates
Move to a specific folder
The ID of the destination folder
Response Body
Successfully moved resource
Array of moved documents with their new destinations
Create an API connection in the Imagine tab in Craft, and paste your API URL here
List Folders
Summary
Get all locations in the space with document counts. Returns built-in locations (Unsorted, Trash, Templates) and user-created folders with their hierarchical structure.
Response Body
Success
Hierarchical folder tree including virtual folders (unsorted, trash, templates)
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Create Folders
Summary
Create one or more folders. Supports creating at root level or nested inside existing folders. Cannot create inside built-in locations.
Request Body
Array of folders to create
Response Body
Successfully created resource
Array of created folders with their IDs
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Delete Folders
Summary
Delete folders. Documents and subfolders are moved to the parent folder, or Unsorted if deleting a top-level folder. Cannot delete built-in locations.
Request Body
The IDs of the folders to delete. Folders must be empty.
Response Body
Successfully deleted resource
Array of IDs of the deleted folders
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Move Folders
Summary
Move folders within the hierarchy. Supports moving to root or inside another folder. Cannot move built-in locations.
Request Body
The IDs of the folders to move
Where to move the folders. Use { destination: "root" } for top-level, or { parentFolderId: "..." } for nested.
Move folder to root level
Move folder inside another folder
The ID of the parent folder
Response Body
Successfully moved resource
Array of moved folders with their new destinations
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Get Tasks
Summary
Retrieve tasks from across the space. Tasks are organized into inbox, active, upcoming, logbook, and document categories. Use scope='document' with documentId to get tasks from a specific document.
Query Parameters
Filter tasks by scope: - 'active': Active tasks (due before now, not completed/cancelled) - 'upcoming': Upcoming tasks (scheduled after now) - 'inbox': Tasks in the task inbox - 'logbook': Tasks in the task logbook (completed/cancelled) - 'document': Tasks in a specific document (requires documentId)
"active" | "upcoming" | "inbox" | "logbook" | "document"Required when scope is 'document'. The ID of the document to list tasks from.
Response Body
Successfully retrieved data
Array of tasks matching the query scope
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Add Tasks
Summary
Create new tasks in inbox, daily notes, or specific documents. Location types: 'inbox', 'dailyNote' (with date), or 'document' (with documentId). Tasks can include schedule dates and deadlines.
Request Body
Tasks to create. Each task will be added to the top of the target location.
Response Body
Successfully created resource
Tasks that were successfully added
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Delete Tasks
Summary
Delete tasks by their IDs from any location in the space.
Request Body
IDs of the tasks to delete. Tasks can be deleted from any location in the space (inbox, logbook, daily notes, or regular documents).
Response Body
Successfully deleted resource
IDs of tasks that were successfully deleted
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Update Tasks
Summary
Update existing tasks across the space. Can modify task content, state, schedule dates, deadlines, and location (to move tasks). Location types: 'inbox', 'dailyNote' (with date), or 'document' (with documentId). Marking inbox tasks as done/canceled moves them to logbook.
Request Body
Tasks to update. Each task must have an id and optionally fields to update.
Response Body
Successfully updated resource
Tasks that were successfully updated
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Upload File
Summary
Upload a file (image, video, or document) and insert it at the specified position. Requires explicit target (pageId, siblingId, or date). Send raw binary data in request body with Content-Type header. This is an experimental API, expect breaking changes.
Query Parameters
Where to insert: 'start' or 'end' for page/date positions, 'before' or 'after' for sibling positions.
"start" | "end" | "before" | "after"Page block ID to insert into. Required when position is 'start' or 'end' (unless date is specified).
Daily note date. Accepts 'today', 'yesterday', 'tomorrow', or ISO date (YYYY-MM-DD). Use with position 'start' or 'end'.
Block ID to insert relative to. Required when position is 'before' or 'after'.
Request Body
binaryResponse Body
Success
The ID of the created block
The URL to access the uploaded asset
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Add comments
Summary
Add comments to blocks. This is an experimental endpoint, expect breaking changes.
Request Body
List of comments to add.
Response Body
Successfully created resource
The ID of the created comment
Create an API connection in the Imagine tab in Craft, and paste your API URL here
Get Connection Info
Summary
Returns connection metadata including space ID, timezone, current time, and URL templates for constructing deep links to blocks. This is an experimental API, expect breaking changes.
Response Body
Successfully retrieved data
Create an API connection in the Imagine tab in Craft, and paste your API URL here