Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.trygravity.ai/llms.txt

Use this file to discover all available pages before exploring further.

MCP Server

The Gravity Index ships as an MCP server so AI coding agents can call it as a native tool — no HTTP client code needed. One-liner — no Python, no clone, no build.
// ~/Library/Application Support/Claude/claude_desktop_config.json  (macOS)
// %APPDATA%\Claude\claude_desktop_config.json                       (Windows)
{
  "mcpServers": {
    "gravity-index": {
      "command": "npx",
      "args": ["-y", "@gravity-ai/index-mcp"]
    }
  }
}

With publisher attribution

If you’re a platform publisher embedding the Index in your own agent, pass your publisher key and every install will attribute to your account for CPA revenue share:
{
  "mcpServers": {
    "gravity-index": {
      "command": "npx",
      "args": ["-y", "@gravity-ai/index-mcp"],
      "env": {
        "GRAVITY_PUBLISHER_KEY": "pk_live_…"
      }
    }
  }
}

Install (Python, for self-hosted setups)

The reference implementation lives in the Gravity monorepo at index/mcp/gravity_index_mcp.py. Exposes the same tools, identical behaviour.
claude mcp add gravity-index \
  -e GRAVITY_INDEX_URL=https://index.trygravity.ai \
  -- python3 /path/to/gravity_index_mcp.py

Tools

Five tools. All return plain-text markdown the agent can display directly. Search for the best tool for a development task. Returns a reasoned recommendation with install instructions and a setup link.
ParameterTypeRequiredDescription
querystringYesWhat you need — e.g. "serverless database with free tier"
search_idstringNoContinue a previous search (follow-up)
Example:
User:  "I need a database for my project."
Agent: gravity_index_search({ query: "database" })
       → "I recommend Neon — serverless Postgres with a free tier.
          1. npm install @neondatabase/serverless
          2. Create lib/db.ts
          3. Visit https://index.trygravity.ai/go/xKHR2xq for credentials"

gravity_index_browse

Browse the catalog by category or keyword.
ParameterTypeRequiredDescription
categorystringNoFilter by category
qstringNoSearch keyword

gravity_index_get_service

Fetch the full detail for a single service by slug.
ParameterTypeRequiredDescription
slugstringYese.g. "supabase"

gravity_index_list_categories

Enumerate every category with the service count. Takes no arguments.

gravity_index_report_integration

Record a conversion when the agent finishes an install without the user clicking the setup link. Accepts the search_id from a prior search and the slug of the service that was actually integrated.
ParameterTypeRequiredDescription
search_idstringYesFrom a previous gravity_index_search
integrated_slugstringYese.g. "stripe"

Zero dependencies

The npm server is a single Node 18+ .mjs file with no runtime deps. The Python server is stdlib-only.