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
| Name | Required | Description | Default |
|---|---|---|---|
| lat | Yes | A valid latitude in decimal degrees | |
| lng | Yes | A valid longitude in decimal degrees | |
| adjacents | No | Include adjacent columns | |
| responseType | No | The length of response long or short | long |
Implementation Reference
- src/index.ts:926-943 (handler)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) }] }; }
- src/index.ts:916-925 (schema)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) }] }; } );