Skip to main content
Find nodes matching multiple criteria simultaneously. Combines text search, node type filtering, page filtering, tag matching, and spatial region queries with AND logic.

Usage

kdx document find <file.kddb> [flags]
At least one filter flag is required.

Flags

FlagDescriptionDefault
--containsText/regex search pattern
--typeFilter by node type (e.g., line, paragraph)
--page NFilter by page number (1-based)
--tagFilter by tag name
--region x1,y1,x2,y2Spatial bounding box filter
--max NMaximum number of results0 (unlimited)
--prettyPretty-print JSON outputfalse

Examples

Combined Filters

kdx document find doc.kddb --contains "total" --type line --page 3
{"nodeId":142,"type":"line","content":"Total Revenue: $1,234,567","page":3,"matchStart":0,"matchEnd":5}
kdx document find doc.kddb --region 0,0,300,100 --page 1

Find by Tag

kdx document find doc.kddb --tag kodexa/amount --max 10 --pretty
Combine --contains with --region to search for text within a specific area of a page, useful for form field extraction.