Skip to main content
Glama

getAllCompanies

Retrieve all companies from the Mews MCP server, with optional filters for company IDs, names, creation or update date range, and pagination settings.

Instructions

Returns all companies, optionally filtered by criteria

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
CompanyIdsNoFilter by specific company IDs
CreatedUtcNoDate range filter for company creation
LimitationNoPagination settings
NamesNoFilter by company names
UpdatedUtcNoDate range filter for company updates

Implementation Reference

  • The execute function that handles the tool logic: parses args, calls mewsRequest to '/api/connector/v1/companies/getAll', and returns JSON result.
    async execute(config: MewsAuthConfig, args: unknown): Promise<ToolResult> { const inputArgs = args as Record<string, unknown>; const requestData = { Limitation: { Count: 100 }, ...inputArgs }; const result = await mewsRequest(config, '/api/connector/v1/companies/getAll', requestData); return { content: [{ type: 'text', text: JSON.stringify(result, null, 2) }] }; }
  • Input schema defining optional filters (CompanyIds, Names, date ranges) and pagination (Limitation).
    inputSchema: { type: 'object', properties: { CompanyIds: { type: 'array', items: { type: 'string' }, description: 'Filter by specific company IDs', maxItems: 1000 }, Names: { type: 'array', items: { type: 'string' }, description: 'Filter by company names', maxItems: 1000 }, CreatedUtc: { type: 'object', properties: { StartUtc: { type: 'string', description: 'Start of creation date range (ISO 8601)' }, EndUtc: { type: 'string', description: 'End of creation date range (ISO 8601)' } }, description: 'Date range filter for company creation' }, UpdatedUtc: { type: 'object', properties: { StartUtc: { type: 'string', description: 'Start of update date range (ISO 8601)' }, EndUtc: { type: 'string', description: 'End of update date range (ISO 8601)' } }, description: 'Date range filter for company updates' }, Limitation: { type: 'object', properties: { Count: { type: 'number', description: 'Maximum number of companies to return' }, Cursor: { type: 'string', description: 'Pagination cursor for next page' } }, description: 'Pagination settings' } }, additionalProperties: false },
  • The tool is registered by inclusion in the exported allTools array.
    getAllCompaniesTool,
  • Import of the getAllCompaniesTool for registration in index.ts.
    import { getAllCompaniesTool } from './companies/getAllCompanies.js';

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/code-rabi/mews-mcp'

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