Skip to main content
Glama
blake365

Macrostrat MCP Server

by blake365

find-columns

Retrieve geological stratigraphic columns and rock layer data for specific coordinates to analyze bedrock formations and geological history.

Instructions

Find geological stratigraphic columns, rock layers, and geological history for any location worldwide. Use for geology, bedrock, formations, age dating, and stratigraphic analysis.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
latYesA valid latitude in decimal degrees
lngYesA valid longitude in decimal degrees
adjacentsNoInclude adjacent columns
responseTypeNoThe length of response long or shortlong

Implementation Reference

  • The handler function that executes the tool logic: destructures input parameters, builds query params, fetches data from Macrostrat columns API endpoint, and returns the JSON response as text content.
    async (request) => { const { lat, lng, adjacents, responseType } = request; const params = new URLSearchParams({ lat: lat.toString(), lng: lng.toString(), adjacents: adjacents?.toString() ?? "false", response: responseType, }); const response = await fetch(`${getApiEndpoint("columns")}?${params}`); const data = await response.json(); return { content: [{ type: "text" as const, text: JSON.stringify(data, null, 2) }] }; }
  • The tool metadata including title, description, and inputSchema with Zod validators for the parameters.
    { title: "Find Columns", description: "Find geological stratigraphic columns, rock layers, and geological history for any location worldwide. Use for geology, bedrock, formations, age dating, and stratigraphic analysis.", inputSchema: { lat: z.number().describe("A valid latitude in decimal degrees"), lng: z.number().describe("A valid longitude in decimal degrees"), adjacents: z.boolean().optional().describe("Include adjacent columns"), responseType: z.enum(["long", "short"]).default("long").describe("The length of response long or short"), } },
  • src/index.ts:914-944 (registration)
    The complete server.registerTool call that registers the 'find-columns' tool, including name, schema/metadata, and inline handler function.
    server.registerTool( "find-columns", { title: "Find Columns", description: "Find geological stratigraphic columns, rock layers, and geological history for any location worldwide. Use for geology, bedrock, formations, age dating, and stratigraphic analysis.", inputSchema: { lat: z.number().describe("A valid latitude in decimal degrees"), lng: z.number().describe("A valid longitude in decimal degrees"), adjacents: z.boolean().optional().describe("Include adjacent columns"), responseType: z.enum(["long", "short"]).default("long").describe("The length of response long or short"), } }, async (request) => { const { lat, lng, adjacents, responseType } = request; const params = new URLSearchParams({ lat: lat.toString(), lng: lng.toString(), adjacents: adjacents?.toString() ?? "false", response: responseType, }); const response = await fetch(`${getApiEndpoint("columns")}?${params}`); const data = await response.json(); return { content: [{ type: "text" as const, text: JSON.stringify(data, null, 2) }] }; } );

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/blake365/macrostrat-mcp'

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