Linkly AI CLI is a command-line tool that connects to Linkly AI Desktop’s MCP service, allowing you to search, browse, and read local documents from the terminal. It also serves as a bridge between AI Agents (such as Claude Desktop, Cursor) and Linkly AI.
Terminal Search
Search your documents directly from the command line — ideal for developers
and power users
MCP Bridge
Run in stdio MCP mode, enabling Claude Desktop, Cursor, and other AI tools
to call Linkly AI
By default, the CLI discovers and connects to the local Linkly AI Desktop app
via ~/.linkly/port. You can also connect to a remote device via LAN or the
cloud tunnel — see Connection Modes below.
The CLI follows a search → grep or outline → read progressive workflow: first search to find target documents, then use grep to find patterns or view the outline to understand the structure, and finally read the specific content.
Searches your local documents and returns the most relevant results, including title, path, relevance score, and content snippet.Common parameters:
# Limit the number of results (default 20, max 50)linkly search "API design" --limit 5# Filter by document typelinkly search "meeting minutes" --type pdf,docx# Output in JSON format (suitable for scripting)linkly search "budget report" --json
Retrieves the structured outline and metadata of a document. DOC_ID is obtained from search results. You can view multiple documents at once:
linkly outline id1 id2 id3
The outline feature works best with Markdown and DOCX documents, as their
heading structures can be parsed. For plain text or PDFs without bookmarks,
it’s recommended to use the read command directly.
Runs as a stdio MCP server, exposing Linkly AI’s tools to MCP-compatible AI clients.Configure Claude Desktop and other local AI apps:Add the following to the configuration file of Claude Desktop or similar apps:
Automatically checks for and updates to the latest version. The CLI also checks for updates in the background on each launch and will prompt you to run this command if a new version is available.
linkly search "machine learning" --remotelinkly status --remote
--endpoint and --token are required together for LAN access. They cannot
be combined with --remote. For remote access, use linkly auth set-key to
save your API key.
Connect to a specific MCP endpoint (e.g. http://192.168.1.100:60606/mcp), requires --token
--token <token>
LAN
Bearer token for LAN authentication (required with --endpoint, conflicts with --remote)
--remote
Remote
Connect via cloud tunnel at https://mcp.linkly.ai (conflicts with --endpoint)
--json
All commands
Output in JSON format (suitable for scripting and automation)
-V, --version
—
Display CLI version number
-h, --help
—
Display help information
--endpoint, --token, and --remote are available on search, grep,
outline, read, and status commands. --endpoint alone (without
--token) is also available on the mcp command. --json is available on
all commands.