Craft Daily Notes icon

Craft Daily Notes

Interact with Craft Daily Notes API - manage blocks, tasks, collections, and search

Block → Search in Document

AI-generated

Summary

Search for blocks matching a regex pattern within a specific daily note identified by date, optionally customizing case sensitivity and context blocks returned before and after matches.

Inputs

  • Date (required) — The daily note date to search within, supporting relative terms like 'today', 'tomorrow', 'yesterday', or an exact 'YYYY-MM-DD' date.
  • Search Pattern (required) — The regex search pattern using RE2-compatible syntax to find matching blocks within the daily note.
  • Options — Optional parameters including case sensitivity, and how many blocks before and after each match to include for context.

Output shape

a list of block search results

Each result includes matched blocks and specified surrounding context blocks. The API endpoint returns JSON data representing matching blocks with specified context. No pagination is indicated in the properties or source.

Examples

Example 1: Search for blocks containing 'meeting' or 'agenda' (case-insensitive) in today's daily note, including 3 blocks before and after each match for context.

Date set to 'today'; Search Pattern set to 'meeting|agenda'; Case Sensitive set to false; Blocks Before set to 3; Blocks After set to 3.

Links

Discussion