Skip to main content
Glama
vdmeu

RegistrumMCP

Get company profile

get_company

Retrieve an enriched UK company profile using its Companies House number, providing detailed business information beyond basic API data.

Instructions

Get an enriched profile for a UK company by its Companies House number. Returns name, status, type, incorporation date, registered address, SIC codes with descriptions, accounts status, confirmation statement status, and derived fields like company_age_years and accounts.overdue that are not available from the raw Companies House API.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
company_numberYesCompanies House company number, e.g. '00445790' for Tesco PLC. Numeric-only numbers should be zero-padded to 8 digits.

Implementation Reference

  • Handler function for get_company tool that takes a company_number parameter, calls the API endpoint /company/{company_number}, and returns the company profile data or error
    async ({ company_number }) => {
      try {
        const data = await api(`/company/${company_number}`);
        return text(data);
      } catch (e) {
        return err(String(e));
      }
    }
  • Input schema for get_company tool defining company_number parameter with Zod validation (must be 1-8 alphanumeric characters, regex pattern /^[A-Z0-9]{1,8}$/)
    inputSchema: {
      company_number: z
        .string()
        .regex(/^[A-Z0-9]{1,8}$/, "Must be 1–8 alphanumeric characters")
        .describe(
          "Companies House company number, e.g. '00445790' for Tesco PLC. " +
          "Numeric-only numbers should be zero-padded to 8 digits."
        ),
    },
  • src/server.ts:89-117 (registration)
    Registration of get_company tool with McpServer, including title, description, inputSchema, and handler function
    server.registerTool(
      "get_company",
      {
        title: "Get company profile",
        description:
          "Get an enriched profile for a UK company by its Companies House number. " +
          "Returns name, status, type, incorporation date, registered address, SIC codes " +
          "with descriptions, accounts status, confirmation statement status, and derived " +
          "fields like company_age_years and accounts.overdue that are not available from " +
          "the raw Companies House API.",
        inputSchema: {
          company_number: z
            .string()
            .regex(/^[A-Z0-9]{1,8}$/, "Must be 1–8 alphanumeric characters")
            .describe(
              "Companies House company number, e.g. '00445790' for Tesco PLC. " +
              "Numeric-only numbers should be zero-padded to 8 digits."
            ),
        },
      },
      async ({ company_number }) => {
        try {
          const data = await api(`/company/${company_number}`);
          return text(data);
        } catch (e) {
          return err(String(e));
        }
      }
    );
  • callApi helper function that makes authenticated API requests to the registrum API with API key header and error handling
    export async function callApi(
      path: string,
      apiKey: string,
      baseUrl: string = API_BASE
    ): Promise<unknown> {
      if (!apiKey) {
        throw new Error(
          "REGISTRUM_API_KEY is not set. Get a free key at https://registrum.co.uk and set it in your MCP client config."
        );
      }
      const res = await fetch(`${baseUrl}${path}`, {
        headers: { "X-API-Key": apiKey },
      });
      if (!res.ok) {
        const body = await res.text();
        throw new Error(`API error ${res.status}: ${body}`);
      }
      return res.json();
    }
  • Helper functions text() and err() for formatting successful and error responses in MCP tool format
    function text(content: unknown) {
      return {
        content: [{ type: "text" as const, text: JSON.stringify(content, null, 2) }],
      };
    }
    
    function err(message: string) {
      return {
        isError: true as const,
        content: [{ type: "text" as const, text: message }],
      };
    }
Behavior4/5

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

With no annotations provided, the description carries full burden and does well by disclosing key behavioral traits: it returns enriched data with derived fields not available from the raw API, specifies the data source (Companies House), and indicates the geographic scope (UK companies). It doesn't mention rate limits, authentication needs, or error behavior.

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 efficiently structured in two sentences: the first states the core purpose and scope, the second details the returned data and key differentiators. Every element serves a clear purpose with no wasted words.

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

Completeness4/5

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

For a single-parameter read operation with no output schema, the description provides good completeness by detailing what data is returned and the enrichment aspect. It could be more complete by specifying the exact format of returned data or any limitations, but covers the essential context well.

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% with the parameter well-documented in the schema. The description adds minimal value beyond the schema by mentioning 'UK company' context and the example of Tesco PLC, but doesn't provide additional semantic context about the parameter.

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 the specific action ('Get an enriched profile'), target resource ('UK company'), and key differentiators from raw API data. It distinguishes from siblings by focusing on comprehensive company profile data rather than directors, financials, or network relationships.

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

Usage Guidelines4/5

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

The description provides clear context for when to use this tool (to get enriched company profile data) and implies alternatives by mentioning 'raw Companies House API.' However, it doesn't explicitly state when to choose this over sibling tools like get_financials or search_company.

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

Install Server

Other 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/vdmeu/registrum-mcp'

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