Skip to main content
Glama
Cyreslab-AI

Crunchbase MCP Server

search_companies

Find companies using filters like category, location, founding date, and status. Retrieve detailed results from Crunchbase data for efficient research and analysis.

Instructions

Search for companies based on various criteria

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
categoryNoFilter by category (e.g., "Artificial Intelligence", "Fintech")
founded_afterNoFilter by founding date (YYYY-MM-DD)
founded_beforeNoFilter by founding date (YYYY-MM-DD)
limitNoMaximum number of results to return (default: 10)
locationNoFilter by location (e.g., "San Francisco", "New York")
queryNoSearch query (e.g., company name, description)
statusNoFilter by company status (e.g., "active", "closed")

Implementation Reference

  • The MCP tool handler for 'search_companies' that processes input parameters into SearchCompaniesInput, calls the Crunchbase API wrapper, and returns the results as JSON text.
    case 'search_companies': { if (!args || typeof args !== 'object') { throw new McpError(ErrorCode.InvalidParams, 'Invalid parameters'); } const params: SearchCompaniesInput = { query: typeof args.query === 'string' ? args.query : undefined, location: typeof args.location === 'string' ? args.location : undefined, category: typeof args.category === 'string' ? args.category : undefined, founded_after: typeof args.founded_after === 'string' ? args.founded_after : undefined, founded_before: typeof args.founded_before === 'string' ? args.founded_before : undefined, status: typeof args.status === 'string' ? args.status : undefined, limit: typeof args.limit === 'number' ? args.limit : undefined }; const companies = await this.crunchbaseApi.searchCompanies(params); return { content: [ { type: 'text', text: JSON.stringify(companies, null, 2), }, ], }; }
  • src/index.ts:192-228 (registration)
    Registration of the 'search_companies' tool in the listTools response, defining its name, description, and input schema matching SearchCompaniesInput.
    { name: 'search_companies', description: 'Search for companies based on various criteria', inputSchema: { type: 'object', properties: { query: { type: 'string', description: 'Search query (e.g., company name, description)', }, location: { type: 'string', description: 'Filter by location (e.g., "San Francisco", "New York")', }, category: { type: 'string', description: 'Filter by category (e.g., "Artificial Intelligence", "Fintech")', }, founded_after: { type: 'string', description: 'Filter by founding date (YYYY-MM-DD)', }, founded_before: { type: 'string', description: 'Filter by founding date (YYYY-MM-DD)', }, status: { type: 'string', description: 'Filter by company status (e.g., "active", "closed")', }, limit: { type: 'number', description: 'Maximum number of results to return (default: 10)', }, }, }, },
  • TypeScript interface SearchCompaniesInput defining the input parameters for the search_companies tool and API method.
    export interface SearchCompaniesInput { query?: string; location?: string; category?: string; founded_after?: string; founded_before?: string; status?: string; limit?: number; }
  • Helper method in CrunchbaseAPI class that builds the search query from parameters and performs the HTTP request to Crunchbase API's /searches/organizations endpoint.
    async searchCompanies(params: SearchCompaniesInput): Promise<Company[]> { try { // Build the query string based on the provided parameters let query = params.query || ''; if (params.location) { query += ` AND location:${params.location}`; } if (params.category) { query += ` AND category:${params.category}`; } if (params.founded_after) { query += ` AND founded_on:>=${params.founded_after}`; } if (params.founded_before) { query += ` AND founded_on:<=${params.founded_before}`; } if (params.status) { query += ` AND status:${params.status}`; } const response = await this.client.get<CrunchbaseApiResponse<Company[]>>('/searches/organizations', { params: { query, limit: params.limit || 10, order: 'rank DESC' } }); return response.data.data; } catch (error) { console.error('Error searching companies:', error); throw this.handleError(error); } }

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/Cyreslab-AI/crunchbase-mcp-server'

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