Skip to main content
Glama
pinecone-io

Pinecone Developer MCP

Official
by pinecone-io

search-docs

Search Pinecone documentation to find relevant information quickly by entering a query, simplifying access to specific technical details.

Instructions

Search Pinecone documentation for relevant information

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesThe text to search for.

Implementation Reference

  • Handler function for the 'search-docs' tool. Connects to the Pinecone docs MCP server and calls its 'get_context' tool.
    server.tool('search-docs', INSTRUCTIONS, SCHEMA, async ({query}) => {
      const httpTransport = new StreamableHTTPClientTransport(new URL(DOCS_MCP_URL));
    
      const client = new Client({
        name: 'pinecone-docs',
        version: PINECONE_MCP_VERSION,
      });
    
      await client.connect(httpTransport);
    
      return (await client.callTool({
        name: 'get_context',
        arguments: {query},
      })) as SearchDocsResult;
    });
  • Instructions and Zod input schema for the 'search-docs' tool.
    const INSTRUCTIONS = 'Search Pinecone documentation for relevant information';
    
    const SCHEMA = {
      query: z.string().describe('The text to search for.'),
    };
  • Registration of the 'search-docs' tool via the addSearchDocsTool helper function called from docs/index.ts and ultimately from src/server.ts.
    export function addSearchDocsTool(server: McpServer) {
      server.tool('search-docs', INSTRUCTIONS, SCHEMA, async ({query}) => {
        const httpTransport = new StreamableHTTPClientTransport(new URL(DOCS_MCP_URL));
    
        const client = new Client({
          name: 'pinecone-docs',
          version: PINECONE_MCP_VERSION,
        });
    
        await client.connect(httpTransport);
    
        return (await client.callTool({
          name: 'get_context',
          arguments: {query},
        })) as SearchDocsResult;
      });
    }
  • Helper function addDocsTools that calls addSearchDocsTool to register the tool.
    export default async function addDocsTools(server: McpServer) {
      addSearchDocsTool(server);
    }
  • src/server.ts:45-46 (registration)
    Top-level call to addDocsTools during server setup, which triggers the tool registration.
    await addDocsTools(server);
    addDatabaseTools(server);
Install Server

Other Tools

Related Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/pinecone-io/pinecone-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server