Skip to main content
Glama

get_entity_export

Export the merged canonical view of all source records linked to an AnchorID as a single JSON object.

Instructions

Export the golden record for an AnchorID. Returns the merged/canonical view of all linked source records as a single JSON object.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
entity_idYesUUID of the AnchorID to export

Implementation Reference

  • src/tools.ts:380-396 (registration)
    Registration of the 'get_entity_export' MCP tool. Defines tool name, description, input schema (entity_id: UUID string), and delegates execution to the handler (callback).
    // ─── 11. get_entity_export ──────────────────────────────────────
    server.tool(
      "get_entity_export",
      "Export the golden record for an AnchorID. Returns the merged/canonical " +
        "view of all linked source records as a single JSON object.",
      {
        entity_id: z.string().describe("UUID of the AnchorID to export"),
      },
      async ({ entity_id }) => {
        try {
          const data = await api.get(`/entities/${entity_id}/export`);
          return jsonContent(data);
        } catch (e) {
          return errorContent(e);
        }
      },
    );
  • Handler for 'get_entity_export'. Calls api.get('/entities/${entity_id}/export') to fetch the golden record for an AnchorID, returning the merged/canonical view of all linked source records as JSON.
      async ({ entity_id }) => {
        try {
          const data = await api.get(`/entities/${entity_id}/export`);
          return jsonContent(data);
        } catch (e) {
          return errorContent(e);
        }
      },
    );
  • Input schema for 'get_entity_export' — requires a single parameter 'entity_id' (UUID string describing the AnchorID to export).
    {
      entity_id: z.string().describe("UUID of the AnchorID to export"),
    },
  • Helper function jsonContent() — formats API response data as MCP tool content (text type with pretty-printed JSON).
    function jsonContent(data: unknown) {
      return {
        content: [{ type: "text" as const, text: JSON.stringify(data, null, 2) }],
      };
    }
  • Helper function errorContent() — formats errors as MCP tool content with isError flag, supporting ApiError with structured metadata (status_code, request_id, details).
    function errorContent(err: unknown) {
      if (err instanceof ApiError) {
        const payload = {
          error: err.message,
          status_code: err.status_code,
          request_id: err.request_id,
          details: err.details,
        };
        return {
          content: [{ type: "text" as const, text: JSON.stringify(payload, null, 2) }],
          isError: true,
        };
      }
      return {
        content: [{ type: "text" as const, text: (err as Error).message ?? String(err) }],
        isError: true,
      };
    }
Behavior3/5

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

With no annotations, the description carries the full burden of disclosure. It correctly implies a read-only operation ('Export'), but does not explicitly state safety or permissions. It describes the output format, but lacks details on side effects, performance, or error conditions.

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 concise with two sentences that cover the action and the output. No unnecessary words or redundancy.

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?

For a simple tool with one parameter and no output schema, the description is adequate but lacks completeness regarding error handling, input validation, or relationship to sibling tools. It does not mention what happens if the AnchorID does not exist.

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 entity_id described as 'UUID of the AnchorID to export'. The description adds that the export is for the golden record, but does not provide additional constraints or format details beyond the schema.

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

Purpose4/5

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

The description clearly states the tool exports the golden record for an AnchorID and returns a merged view. It specifies the verb 'Export' and the resource 'golden record for an AnchorID'. However, it does not explicitly distinguish it from the sibling 'get_entity' tool, which may perform a similar function.

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

Usage Guidelines2/5

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

No guidance is provided on when to use this tool versus alternatives (e.g., 'get_entity'). There is no mention of prerequisites, limitations, or scenarios where this tool should be avoided.

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/nolenation04/anchord-mcp'

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