Command reference: knowledge bases
Create knowledge bases, control who can use them, add documents and files, and check retrieval and citations.
Overview
Knowledge commands manage the knowledge bases your agents draw on. They need a browser sign-in and a server that supports knowledge; with only an Agent Key they stop with “Knowledge commands require a signed-in user session”. Commands that work across a workspace take --org <workspace-id> or use the profile’s orgId.
Knowledge bases
figena knowledge list
Lists the knowledge bases in a workspace. Option: --org <workspace-id>.
figena knowledge create
Creates a knowledge base. Options: --name <name> (required), --description <text>, and --org.
figena knowledge get <knowledgeBaseId>
Shows one knowledge base.
Access
figena knowledge access get <knowledgeBaseId>
Shows the visibility and grants of a knowledge base.
figena knowledge access set <knowledgeBaseId>
Updates who can use a knowledge base.
--visibility <value>: change the visibility.--user-id <id>or--org-role <role>: grant access to one person or to a workspace role. A grant always includes read access.--can-write: also allow the person or role to change the knowledge base.--grants-json '[...]': replace the single grant with a JSON array of grants.--metadata-json '<json>'or--metadata-file <file>: attach access metadata.
figena knowledge access set <knowledgeBaseId> --org-role <role> --can-writeDocuments and files
figena knowledge document add <knowledgeBaseId>
Adds a text document. --title <title> and --content <value> are required. If the value of --content is a path to an existing file, the CLI reads that file as UTF-8 text; otherwise it uses the value itself as the content. Content can be up to 30,000 characters. Optional: --source-name <name> and --mime-type <type>.
figena knowledge file import <knowledgeBaseId>
Uploads a local file with --file <path> and imports it as a document, or imports a file that is already uploaded with --file-id <id>. Add --title <title> to name the document. The CLI sets the file type from the extension for JSON, Markdown, plain text and logs, CSV, HTML, PDF, PNG, JPEG, and WebP; other files are sent as generic binary data.
figena knowledge document add <knowledgeBaseId> --title "Refund policy" --content ./refund-policy.mdfigena knowledge file import <knowledgeBaseId> --file ./price-list.pdf --title "2026 price list"Search and verification
figena knowledge search <knowledgeBaseId>
Searches a knowledge base. --query "<text>" is required; --limit <n> caps the number of results.
figena knowledge verify
Checks retrieval for a knowledge base so you can confirm that answers cite the right documents. Name the knowledge base with --knowledge-base <id> or as the first argument; narrow it with --document <id> and --limit <n>.
figena knowledge citation-audits
Lists citation audits in a workspace. Options: --org, --knowledge-base <id>, --document <id>, and --limit <n>.