synthetic-search
v1.0.4
Published
Command-line client for Synthetic web search and quotas.
Maintainers
Readme
synthetic-search
A user-facing CLI for Synthetic web search, quotas, and local credential management.
Features
- Search the public web with Synthetic (
/v2/search) - View account usage and limits (
/v2/quotas) - Interactive local auth setup (
auth login/auth logout/auth status) - Readable terminal output by default
--jsonoutput mode for scripts and automation- Tolerant JSON parsing for malformed control characters in API responses
Requirements
- Node.js 18+
- Synthetic API key
Installation
npm install -g synthetic-searchOr run directly with npx:
npx -y synthetic-search --helpAuthentication
SYNTHETIC_API_KEY always takes priority over saved config.
Environment variable (recommended for CI)
export SYNTHETIC_API_KEY=your_api_key_hereSaved local config
synthetic-search auth loginThis validates the key via GET /v2/quotas before saving.
Skip validation:
synthetic-search auth login --no-validateCheck status:
synthetic-search auth statusRemove saved key:
synthetic-search auth logout
synthetic-search auth logout --forceUsage
Search
Root command and subcommand are equivalent:
synthetic-search latest model context protocol news
synthetic-search search latest model context protocol newsRead query from piped stdin:
echo "latest ai safety research" | synthetic-search searchJSON output:
synthetic-search search "latest mcp updates" --jsonClient-side result limit:
synthetic-search search "latest mcp updates" --limit 2Quotas
synthetic-search quotas
synthetic-search quotas --jsonAPI Endpoints
POST https://api.synthetic.new/v2/searchGET https://api.synthetic.new/v2/quotas
Development
npm install
npm run test
npm run buildRun in dev mode:
npm run dev -- search "latest llm tooling"License
MIT
