Skip to main content
Glama
opensearch-project

opensearch-mcp-server-py

Official

GenericOpenSearchApiTool

Call any OpenSearch API endpoint via custom path, HTTP method, query parameters, body, and headers. Use for APIs without dedicated tools or when precise request control is required.

Instructions

A flexible tool for calling any OpenSearch API endpoint. Supports all HTTP methods with custom paths, query parameters, request bodies, and headers. Use this when you need to access OpenSearch APIs that don't have dedicated tools, or when you need more control over the request. Leverages your knowledge of OpenSearch API documentation to construct appropriate requests.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bodyNoRequest body for GET/POST/PUT requests. Can be a JSON object, string, or None
pathYesThe API endpoint path (e.g., "/_search", "/_cat/indices", "/my_index/_doc/1"). Should start with "/".
methodNoHTTP method to use (GET, POST, PUT, DELETE, HEAD, PATCH)GET
headersNoAdditional HTTP headers to include in the request
aws_regionNoAWS region for IAM/Serverless authentication.
aws_iam_arnNoIAM role ARN for role-based authentication.
aws_profileNoAWS profile name for authentication.
query_paramsNoQuery parameters to include in the request URL as key-value pairs
opensearch_urlYesOpenSearch endpoint URL.
opensearch_no_authNoIf true, connect without authentication.
opensearch_timeoutNoConnection timeout in seconds.
opensearch_passwordNoPassword for basic authentication.
opensearch_usernameNoUsername for basic authentication.
opensearch_ssl_verifyNoSet true to require SSL certificate verification. A false value is ignored, since only the operator may disable verification.
aws_opensearch_serverlessNoIf true, use OpenSearch Serverless service.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.12.0
    • changedInput schema / properties / opensearch_ssl_verify / description
      Previous value: -"If false, disable SSL certificate verification."New value: +"Set true to require SSL certificate verification. A false value is ignored, since only the operator may disable verification."
  2. First observedv0.9.0

TDQS

A3.9/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description must carry the full burden of behavioral disclosure. It does not mention potential side effects (e.g., destructive operations), error handling, return format, or any special behaviors. The phrase 'any OpenSearch API endpoint' implies it could perform mutations, but this is not surfaced explicitly. The description adds little beyond the basic capability.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two sentences, front-loads the core purpose, and provides usage guidance without any fluff. Every sentence earns its place, and the structure is clear and efficient.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The tool is complex with 15 parameters and no output schema. The description does not state what the tool returns (e.g., raw API response), nor does it explain error behavior or how to interpret results. It relies on the agent's knowledge of OpenSearch API documentation, which is stated, but for a generic tool that can perform any operation, more clarity on expected output would be helpful. The description is adequate but leaves gaps.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so each parameter already has a clear description. The tool description mentions 'custom paths, query parameters, request bodies, and headers', which maps to a few parameters but adds no new meaning. It does not explain relationships between parameters (e.g., authentication options) or provide usage context beyond what the schema offers. Baseline 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states a specific action: 'calling any OpenSearch API endpoint', and distinguishes itself from siblings by specifying it is for endpoints that 'don't have dedicated tools'. The verb and resource are explicit, and it tells the agent when to choose this tool over dedicated ones.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explicitly states when to use this tool: 'when you need to access OpenSearch APIs that don't have dedicated tools, or when you need more control over the request.' It implies that dedicated tools should be used for their specific endpoints, giving clear guidance on selection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.