# Astra DB

MCP server for Astra DB operations: vector search, collections, tables, and keyspace management through the agent.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI
- Author: datastax
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/datastax/astra-db-mcp
- Updated: 2026-10-29
- Security check: automated, 2026-11-16 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/mcp/astra-db

## What it does

The server exposes over forty tools for document collections, vector search, structured tables, and keyspace administration. The agent can create collections with vector indexes and distance metrics, run natural language queries via serverless Vectorize embeddings, execute hybrid search with reranking, insert and update documents in batches, work with typed tables through Data API v2, manage keyspaces, and switch between them.

You need an Astra DB application token (`ASTRA_DB_APPLICATION_TOKEN`) and API endpoint (`ASTRA_DB_API_ENDPOINT`) from the database console after registration. Set `ASTRA_DB_KEYSPACE` to target a specific keyspace; if omitted, the server uses `default_keyspace` from library settings. Windows PowerShell requires wrapping the `npx` command with `cmd /k`.

The server handles MongoDB-style filter operators (`$and`, `$or`, `$gt`, `$in`, `$exists`), vector similarity metrics `cosine`, `euclidean`, and `dot_product`, field projection, sorting, and pagination.

## Requirements
- Needs: Docker

## Install

### Claude Code (native platform)

**Install**
- The MCP registry has no launch command for it: see the repository README

## When to use it
- run vector similarity search on a collection with metadata filters
- create a table with a vector index and primary key
- query documents using natural language via Vectorize
- batch insert multiple records in one operation
- switch to another keyspace and list its tables

## Example prompts
- Find five nearest vectors to `[0.1, 0.5, 0.3]` in `products` collection using `cosine` metric
- Create collection `articles` with 1536-dimensional vector field and `euclidean` metric
- Run hybrid search on `docs` collection: text 'database setup' plus query vector, rerank results

## Similar
- [qdrant-skills](https://affpapa.org/en/nevibecode/plugins/qdrant-skills.md) — plugin · ★ 271 repo stars
- [Vector Search — In-Memory TF-IDF Semantic Store](https://affpapa.org/en/nevibecode/mcp/vector-search-in-memory-tf-idf-semantic-store.md) — MCP server · 3562 installs
- [mongodb-search-and-ai](https://affpapa.org/en/nevibecode/skills/mongodb-search-and-ai.md) — skill · 6300 installs
- [vector-search](https://affpapa.org/en/nevibecode/skills/vector-search.md) — skill · 752 installs
- [vector-embed](https://affpapa.org/en/nevibecode/skills/vector-embed.md) — skill · 732 installs

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
