Install
Sign in
mcp:use and search:query, with the collection restrictions you approved.
status checks server access and refreshes expired tokens when needed. logout revokes this CLI connection and removes local tokens; other devices and your browser login remain separate.
Login options
Use the same base URL for login, status, and logout, or set
BULKGRID_URL. The default is https://bulkgrid.com.
Configure AI clients
init configures the MCP server for Cursor, VS Code, Claude Code, and Codex using API keys:
--cursor, --vscode, --claude, or --codex to configure one client. Keys need mcp:use and search:query for MCP search.
CLI login and AI-client login are separate connections. init does not copy your CLI OAuth tokens into client configuration. For browser OAuth in an AI app, follow MCP setup.
Local credentials and recovery
Tokens are stored per deployment in~/.config/bulkgrid with owner-only file permissions. The CLI refreshes tokens automatically and keeps them out of project configuration.
If remote logout fails, credentials remain available for retry. If access was already revoked, or after revoking it in Connected Apps, clear the local credentials with:
Source management with an API key
The repository build includessources commands. Check bulkgrid sources --help for availability in your installed release. These commands require BULKGRID_API_KEY; they do not use the saved OAuth login. Set BULKGRID_URL or pass --url to select another deployment. Remote deployments require HTTPS.
find requires sources:read; collections requires collections:read. For source-size inspection, explicitly start asynchronous analysis using sources analyze <url>, then check it with sources analysis-status <analysisId>. Analysis may consume resources; its URL counts and warnings are not a storage or credit quote.
After choosing and authorizing the ingestion configuration:
add requires sources:write and may initiate ongoing ingestion. Visibility and refresh policy matter; the example requests a private source with weekly refresh. Plan limits still apply.
Commands output JSON and do not poll automatically. Save source, analysis, and run IDs. Do not blindly retry a timed-out mutation: it may already have succeeded. Source creation and collection inclusion are separate operations, and source creation alone does not mean content is searchable.