# WarpSearch MCP server

WarpSearch is a serverless hybrid search service: full-text (BM25), vector
and faceted search over JSON documents, plus analytics (facets, metrics,
date histograms), graph neighborhood retrieval and shortest paths. It understands SQL (MySQL and PostgreSQL dialects, with
tsquery full text and pgvector distances), Elasticsearch/OpenSearch Query
DSL, Apache Solr, Lucene, Grafana, LogQL and its native WarpSearch language, so query
it in the language you know best. Data lives in collections: index JSON
documents into one, then search it. Use it as a search backend for an app,
for log and event analytics, or as memory you can search.

This URL is a Model Context Protocol server (streamable HTTP). Add it to your MCP client:

```json
{
  "mcpServers": {
    "warpsearch": {
      "type": "http",
      "url": "https://api.warpsearch.io/mcp",
      "headers": { "Authorization": "Bearer <api key>" }
    }
  }
}
```

Claude Code: `claude mcp add --transport http warpsearch https://api.warpsearch.io/mcp --header "Authorization: Bearer <api key>"`

## Getting an API key

If your user has a WarpSearch API key (ws_live_...), use it. Otherwise connect without the Authorization header: the server then offers only two tools, which sign your user up.

1. `register` with the email address your user gave you for this (never guess one). It must be a work address at their organization's own domain: free and personal mailbox providers (gmail.com, outlook.com, ...) are refused. It returns a `user_code` and a `claim_token`.
2. Tell your user to open the email from WarpSearch, follow its link (it creates their account if they have none), check that the page shows your `user_code`, choose the organization and role, and approve.
3. When they are done, call `claim_registration` with the `claim_token`. It returns the API key once; store it securely.
4. Reconnect with the header `Authorization: Bearer <api key>` to get the search and indexing tools.

The request expires after an hour. Ask for the editor role or higher (admin is the default) if you will create collections.

## Once connected

list_collections, then describe_collection, then search in the query language you know best. To load data: create_collection, then index_documents. The server's instructions and tool descriptions have the details.

More: https://warpsearch.io/docs/agents.md (this guide, with the REST API) and https://warpsearch.io/llms.txt.
