# Community Vision AI — API & MCP

> Community Vision AI (CVAI) is an AI literacy platform and analysis suite. It pairs educational content (mental models, AI concept articles) with structured analysis tools (Epistemic Quality Audit, Spec Review, Mental Model analyses, Competitive Research, Conversational Analyst) that score business documents and decisions claim-by-claim.

Root index: https://communityvision.ai/llms.txt
Full export: https://communityvision.ai/llms-full.txt

## Quick Answers

### Q: Does CVAI have a public API?

A: Yes. CVAI exposes a versioned REST API under /api/v1/ for analysis tools (EQA, Spec Review, Mental Models), billing, reports, and agent access. Authentication is via session cookie or a Bearer cvai_ak_ API key.

### Q: Does CVAI support MCP for AI agents?

A: Yes. CVAI ships an MCP server (Spec Review and core analysis tools) reachable over HTTP at /api/mcp and over stdio, callable from Claude Code, Cursor, and any MCP-compatible client.

### Q: How is API usage billed?

A: API and MCP calls are billed against the same USD balance as web UI runs: you pay the final metered cost of each run, with per-user spend caps, immutable ledger entries in cents, and the Pro 20% discount applied automatically.

### Q: Where can I use CVAI as a developer?

A: CVAI plugs into eight developer surfaces with one API key: the command line (CLI), autonomous agents via the REST API and MCP server, the VS Code extension, a GitHub Action for pull requests, a Slack app, the browser (extension and WebMCP), mobile handoff, and automation/embeds via signed webhooks and iframes.

### Q: Do I need a different API key for each CVAI integration?

A: No. A single cvai_ak_ key works across every surface, and the same spend caps, rate limits, and audit logging apply everywhere — whether you call from the CLI, an agent, CI, Slack, or the browser.

### Q: What can I analyze with CVAI as a developer?

A: Every surface reaches the same tools: Spec Review (a 10-dimension product-spec gate), Epistemic Quality Audit (claim-by-claim scoring with a Circle of Knowledge map), and the Conversational Analyst (multi-turn chat grounded in completed reports).

### Q: How do I audit a spec from the command line with CVAI?

A: Install the CVAI CLI, authenticate with a cvai_ak_ API key (run cvai login or set the CVAI_API_KEY environment variable), then run cvai review-spec ./my-spec.md. One command turns a markdown spec into a scored report, and JSON output plugs straight into scripts and CI gates.

### Q: Can CVAI CLI runs work in CI without blocking my shell?

A: Yes. The CLI async mode (cvai review-spec ./spec.md --async) returns immediately so long jobs never block your shell; you then poll cvai status with the run id and pull the full report with cvai result.

### Q: How do I call CVAI tools from my own agent or app?

A: Create an agent app in the developer dashboard, generate a per-app cvai_ak_ key, and POST to the REST API v1 (for example /api/v1/tools/spec_review/runs) with the key as a Bearer header. The same key also works with the native MCP server at /api/mcp from Claude Desktop, Cursor, or any MCP client.

### Q: Do CVAI agent API keys have spend and rate limits?

A: Yes. Each agent app gets its own cvai_ak_ key with isolated daily and monthly spend caps, a rate limit, and an optional webhook URL — all managed from the signed-in developer dashboard, with the same spend caps and audit logging applied across REST and MCP.

### Q: Can CVAI audit a spec directly inside VS Code?

A: Yes. The CVAI Spec Audit extension submits your active markdown file and renders each flagged claim as an inline editor diagnostic anchored to the exact line, with the developer gate (strong, usable, or weak) in the status bar. Run "CVAI: Set API key" once, then "CVAI: Audit this spec".

### Q: Can I point the VS Code extension at a self-hosted CVAI instance?

A: Yes. Set the cvaiAudit.apiBaseUrl setting to your staging or self-hosted instance; it defaults to https://communityvision.ai.

### Q: How do I gate pull requests on a CVAI spec audit?

A: Store your agent key as the encrypted repo secret CVAI_API_KEY, then add the EQA gate workflow under .github/workflows/. It audits only the spec and plan markdown a PR changes, posts a check run with inline annotations, and fails the check when the gate is blocking.

### Q: Does the CVAI GitHub Action audit every file on every PR?

A: No. It runs only on the spec and plan files a PR changes, using path filters and file globs you tune to match where your specs and plans live — preserving spend caps, rate limits, and audit logging.

### Q: How do I run a CVAI audit from Slack?

A: Install the CVAI Slack app to your workspace (a workspace admin approves it), invite the bot to a channel with /invite @CVAI, then mention @CVAI review this with a link or attached file. Results post back in the thread for the whole team.

### Q: Is there a slash command for CVAI in Slack?

A: Yes. Use /cvai from any channel to open quick actions without mentioning the bot.

### Q: Can I audit any web page with the CVAI browser extension?

A: Yes. The Chrome and Firefox extension reads the page you are on and launches an audit with one click — no copy-paste. It works in signed-in (cookie) mode, or you can paste a cvai_ak_ key under Advanced for power use.

### Q: What is WebMCP and how does CVAI use it?

A: Every CVAI page registers eight built-in WebMCP tools via navigator.modelContext, so AI-enabled browsers can call them on your behalf with zero install. The tools are searchContent, listMentalModels, listAIConcepts, listChallenges, listConsultants, getConsultantAvailability, listBusinesses, and navigateTo.

### Q: How do I keep a mobile app on-brand with the CVAI design?

A: Use the mobile handoff bundle: a versioned package of design tokens (colors, typography, spacing), logos and icons, and an app spec generated straight from the website code. Import cvaiTheme.ts or cvaiTheme.json (or the @cvai/design-tokens package) and follow UPDATE_GUIDE.md to stay in sync.

### Q: How do I know when the CVAI design tokens have changed?

A: The handoff manifest reports the version, a SHA-256 hash per file, and a changes field describing what changed since the last build — fetch /api/mobile-handoff/manifest.json to check.

### Q: How do I get CVAI results delivered automatically?

A: Set a webhook URL on your agent app in the developer dashboard. CVAI then POSTs signed (HMAC-SHA256) deliveries for events like tool_run.completed, tool_run.failed, and tool_run.progress; verify the X-CVAI-Signature header against your webhookSecret before trusting the payload.

### Q: Can I embed a CVAI report on my own site?

A: Yes. Publish the report as public or unlisted with embedding enabled, list the allowed domains, then paste the iframe pointing at /reports/your-slug/embed. Unlisted reports require a token in the URL.

## Pages

- https://communityvision.ai/docs/api
- https://communityvision.ai/mental-models/circle-of-knowledge/roles/developer
- https://communityvision.ai/mental-models/circle-of-knowledge/roles/developer/cli
- https://communityvision.ai/mental-models/circle-of-knowledge/roles/developer/agents-api-mcp
- https://communityvision.ai/mental-models/circle-of-knowledge/roles/developer/vscode
- https://communityvision.ai/mental-models/circle-of-knowledge/roles/developer/github
- https://communityvision.ai/mental-models/circle-of-knowledge/roles/developer/slack
- https://communityvision.ai/mental-models/circle-of-knowledge/roles/developer/browser
- https://communityvision.ai/mental-models/circle-of-knowledge/roles/developer/mobile-handoff
- https://communityvision.ai/mental-models/circle-of-knowledge/roles/developer/automation-embeds

## Related segments

- https://communityvision.ai/llms-mental-models.txt
- https://communityvision.ai/llms-ai-concepts.txt
- https://communityvision.ai/llms-tools.txt
- https://communityvision.ai/llms-pricing.txt
- https://communityvision.ai/llms-business.txt
