OpenSearch MCP Server
@rithin-pullela-aws
关于 OpenSearch MCP Server
暂无概览
基本信息
配置
使用下面的配置,将此服务器添加到你的 MCP 客户端。
{
"mcpServers": {
"opensearch-mcp-server": {
"command": "uvx",
"args": [
"test-opensearch-mcp"
],
"env": {
"OPENSEARCH_URL": "<your_opensearch_domain_url>",
"OPENSEARCH_USERNAME": "<your_opensearch_domain_username>",
"OPENSEARCH_PASSWORD": "<your_opensearch_domain_password>",
"AWS_REGION": "<your_aws_region>",
"AWS_ACCESS_KEY": "<your_aws_access_key>",
"AWS_SECRET_ACCESS_KEY": "<your_aws_secret_access_key>",
"AWS_SESSION_TOKEN": "<your_aws_session_token>"
}
}
}
}工具
4Lists all indices in OpenSearch.
Retrieves index mapping and setting information for an index in OpenSearch.
Searches an index using a query written in query domain-specific language (DSL) in OpenSearch.
Gets information about shards in OpenSearch.
概览
What is OpenSearch MCP Server?
A minimal Model Context Protocol (MCP) server for OpenSearch that exposes four tools over stdio and SSE transports. It is aimed at developers who want to interact with an OpenSearch cluster through LLM agents or assistants.
How to use OpenSearch MCP Server?
Install the package from PyPI with pip install test-opensearch-mcp. Set the required environment variables (OPENSEARCH_URL and either OPENSEARCH_USERNAME/OPENSEARCH_PASSWORD for basic auth or AWS_REGION/AWS_ACCESS_KEY/AWS_SECRET_ACCESS_KEY/AWS_SESSION_TOKEN for IAM role auth). Run the server in stdio mode with python -m mcp_server_opensearch or in SSE mode with python -m mcp_server_opensearch --transport sse. Integration examples for Claude Desktop and LangChain are provided.
Key features of OpenSearch MCP Server
- List all indices in the OpenSearch cluster
- Retrieve index mapping and settings
- Search an index using query DSL
- Get shard information for indices
- Supports both basic and IAM role authentication
- Runs over stdio or SSE transport
Use cases of OpenSearch MCP Server
- Allow an LLM agent to list and explore OpenSearch indices
- Let an assistant fetch index mapping before constructing queries
- Enable natural language search against OpenSearch via a LangChain agent
- Monitor shard health and distribution using an AI-driven workflow
FAQ from OpenSearch MCP Server
How do I authenticate with the server?
The server supports two authentication methods: basic authentication (using OPENSEARCH_USERNAME and OPENSEARCH_PASSWORD) and IAM role authentication (using AWS_REGION, AWS_ACCESS_KEY, AWS_SECRET_ACCESS_KEY, and optionally AWS_SESSION_TOKEN). Set the corresponding environment variables before starting the server.
What transports are available?
The server can run in two modes: stdio (default) and SSE (use --transport sse flag). The SSE mode is used for integrating with frameworks like LangChain.
Can I integrate this server with LangChain?
Yes. The README includes a LangChain integration example using langchain-mcp-adapters. You run the server in SSE mode, then connect via MultiServerMCPClient and use the LLM to call the tools.
What data does the server access?
The server only connects to the OpenSearch cluster specified by the OPENSEARCH_URL environment variable. It does not store or cache any data; all operations are live queries against that cluster.
Are there any known limitations?
The server currently provides four tools. The README notes that more tools are coming soon, but no specific limitations are documented beyond the tool set.
数据库 分类下的更多 MCP 服务器
Postgres Mcp
crystaldbaPostgres MCP Pro provides configurable read/write access and performance analysis for you and your AI agents.
MongoDB Lens
furey🍃🔎 MongoDB Lens: Full Featured MCP Server for MongoDB Databases
MySQL MCP Server
designcomputerA Model Context Protocol (MCP) server that enables secure interaction with MySQL databases
ClickHouse MCP Server
ClickHouseConnect ClickHouse to your AI assistants.
mcp_mysql_server
xwb602625136Model Context Protocol (MCP) server that supports secure interaction with MySQL databases and has anomaly analysis capabilities.更加牛逼!更加好用!不仅止于mysql的增删改查功能; 还包含了数据库异常分析能力;且便于开发者们进行个性化的工具扩展
评论