Working with documents using the Kodexa CLI
query
command allows you to search for and manipulate documents in a document store:
<document-path>.kddb
<document-path>.native
<document-path>-extracted_data.json
Specify a project ID for extracted data:
upload
command allows you to upload files to a document store:
document.json
for document.pdf
) and attaches its content as external data to the uploaded document.
Option | Description | Example |
---|---|---|
--filter | Use filter syntax instead of query syntax | --filter |
--page | Page number for pagination | --page 2 |
--pageSize | Number of items per page | --pageSize 20 |
--sort | Sort results by field | --sort "name:asc" |
--stream | Stream results instead of paginating | --stream |
--limit | Limit number of results in streaming | --limit 100 |
--threads | Number of threads for operations | --threads 10 |
--download | Download documents in KDDB format | --download |
--download-native | Download original files | --download-native |
--download-extracted-data | Download extracted data as JSON | --download-extracted-data |
--project-id | Project ID for extracted data | --project-id proj123 |
--reprocess | Reprocess with assistant ID | --reprocess asst123 |
--add-label | Add label to documents | --add-label invoice |
--remove-label | Remove label from documents | --remove-label draft |
--delete | Delete matching documents | --delete |
--watch | Refresh results every n seconds | --watch 30 |
Option | Description | Example |
---|---|---|
--threads | Number of threads for parallel uploads | --threads 10 |
--external-data | Attach JSON metadata from matching files | --external-data |