Docs
Quick setup.
Remote MCP works without an account at https://buyapi.ai/api/mcp. Use the CLI when you want guided setup, local fallback, or private stack sync.
§ Setup
{
"mcpServers": {
"buyapi": {
"url": "https://buyapi.ai/api/mcp"
}
}
}Once connected, ask your agent recommend an email api for a side project. The tool call happens automatically — no wrapper library, no CLI.
Local fallback for clients without remote MCP
{
"mcpServers": {
"buyapi": {
"command": "npx",
"args": ["-y", "buyapi", "mcp"]
}
}
}§ Stack sync
The scanner inspects project files on your machine. Plain scan stays local; sync requires an API key and saves detected tools to your private dashboard.
npx buyapi setup cursor# or codex / claude-codenpx buyapi login# browser authnpx buyapi scan --sync --yes# in project dirToday the scanner uses rules bundled in the open-source package: package names, framework config files, common service directories, and safe `.env.example` key names. Source files and environment values are not uploaded; only tool IDs, categories, confidence, and detection notes are saved.
§ Tools
Seven MCP tools. Agents can discover vendors, fetch sourced detail, inspect evidence, find similar stacks, compare head-to-head options, run deterministic cost math, or jump straight to a complete stack recommendation.
vendors.resolveTake a user question and optional category; return a ranked list of vendor IDs, or an explicit not-in-corpus result.Parameters
- query
- The user's question or task
- required
- category
- database · auth · hosting · payments · email
- optional
Returns
A short list of vendor IDs (format /category/slug) with pricing model, best-fit summary, freshness, and confidence.
vendors.detailsFetch the full product record for a single vendor — pricing tiers, limits, feature grid, gotchas, comparisons, and source provenance.Parameters
- vendorId
- BuyAPI vendor ID (e.g., /database/neon)
- required
- query
- The specific question to tune the response
- optional
Returns
A structured vendor profile with pricing, limits, features, known issues, comparisons, company facts, claims, freshness, and confidence.
vendors.evidenceFetch recent evidence rows for a vendor, category, stack, or comparison.Parameters
- subjectType
- vendor · category · stack · comparison
- required
- subjectId
- e.g. /database/supabase or database
- required
- limit
- Maximum evidence rows
- optional
Returns
Reviewed evidence rows with source type, summary, stance, confidence, source URL, author, and observed date.
stacks.findSimilarFind public stack profiles related to a vendor, or recent curated stack examples.Parameters
- vendorId
- Optional BuyAPI vendor ID
- optional
- limit
- Maximum stack profiles
- optional
Returns
Public stack profiles with project summary, audience, stage, tools, roles, and confidence.
vendors.compareCompare two or more specific vendors for a stated workload or decision.Parameters
- vendorIds
- BuyAPI vendor IDs, e.g. /database/convex
- required
- query
- The user's decision context
- required
- workload
- Explicit workload assumptions
- optional
Returns
A decision matrix with fit, tradeoffs, estimated monthly cost, confidence, freshness, and sources.
vendors.estimateCostRun deterministic monthly cost estimates from explicit workload inputs.Parameters
- workload
- users, MAU, storage GB, email sends, auth MAU, regions, seats, payments volume, notes
- required
- vendorIds
- Specific BuyAPI vendor IDs
- optional
- category
- Estimate across a category in the current corpus
- optional
Returns
Cost estimates with basis, assumptions, unknowns, confidence, and source provenance. Missing workload fields become assumptions, not fabricated precision.
stacks.recommendOne call, full stack. Give BuyAPI a project description, constraints, and optional workload; get one pick per layer plus structured reasoning.Parameters
- projectDescription
- What you're building (a sentence or two)
- required
- constraints
- Budget, scale, compliance, existing tools
- optional
- workload
- Explicit workload assumptions
- optional
Returns
The same core recommendation shape as /api/recommend: stack, decisionMatrix, costEstimate, assumptions, unknowns, alternatives, sources, and generatedAt.
§ Vendor IDs and workload hints
BuyAPI vendor IDs use /category/slug. Use exact IDs when you already know the tools you want compared.
/database/convex /database/supabase /database/neon /auth/clerk /hosting/vercel /payments/stripe /email/resend
The strongest prompts include real workload numbers: monthly active users, team seats, storage GB, email sends, auth MAU, regions, transaction volume, and budget ceiling. Use BuyAPI for the vendor decision, then pair it with Context7 or first-party docs for exact implementation APIs and version-specific code examples.
§ REST API
For non-MCP clients (scripts, web apps, your own agent frame). The same data; plain HTTPS.
/api/vendors/search?query=...&category=...
→ Array of { id, name, description, pricingModel, bestFor, lastUpdated }
/api/vendors/[...slug]e.g., /api/vendors/database/neon
→ Full VendorProfile object (see Tools → vendors.details for shape)
/api/recommendbody: { projectDescription, constraints?, workload? }
→ { stack, decisionMatrix, costEstimate, assumptions, unknowns, alternatives, sources, generatedAt }
All endpoints return JSON. No auth required at default rate limits — see below.
§ Rate limits
Anonymous
10 / min
Default. No setup, no account.
With key
60 / min
Sign in, create a dashboard API key, or run npx buyapi login for CLI-managed key storage.
10/min is plenty for a single developer — an agent makes 1–3 calls per real question. If you're rate-limited, use a keyed MCP or CLI setup and retry after the response hint.