Skip to main content
Glama
receptopalak

PostGIS MCP Server

by receptopalak

create-point

Generate point geometries from coordinates using PostGIS MCP Server. Input longitude and latitude to create spatial data with an optional SRID for custom projection.

Instructions

Koordinatlardan nokta geometrisi oluştur

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
latitudeYesEnlem koordinatı
longitudeYesBoylam koordinatı
sridNoSpatial Reference System ID (varsayılan: 4326)

Implementation Reference

  • Handler for 'create-point' tool: validates input using CreatePointSchema, executes PostGIS query with ST_MakePoint to create point geometry, returns WKT, GeoJSON, coordinates, and SRID.
        case "create-point": {
            const { longitude, latitude, srid } = CreatePointSchema.parse(args);
            const result = yield client.query(`
      SELECT 
        ST_AsText(ST_SetSRID(ST_MakePoint($1, $2), $3)) as wkt,
        ST_AsGeoJSON(ST_SetSRID(ST_MakePoint($1, $2), $3)) as geojson
    `, [longitude, latitude, srid]);
            const response = {
                wkt: result.rows[0].wkt,
                geojson: JSON.parse(result.rows[0].geojson),
                coordinates: [longitude, latitude],
                srid: srid,
            };
            return {
                content: [
                    {
                        type: "text",
                        text: JSON.stringify(response, null, 2),
                    },
                ],
            };
        }
  • Zod validation schema for 'create-point' tool inputs: requires longitude and latitude (numbers), optional srid (default 4326).
    const CreatePointSchema = zod_1.z.object({
        longitude: zod_1.z.number(),
        latitude: zod_1.z.number(),
        srid: zod_1.z.number().optional().default(4326),
    });
  • server.js:81-102 (registration)
    Registration of 'create-point' tool in ListTools handler: specifies name, description, and input schema matching the Zod schema.
    {
        name: "create-point",
        description: "Koordinatlardan nokta geometrisi oluştur",
        inputSchema: {
            type: "object",
            properties: {
                longitude: {
                    type: "number",
                    description: "Boylam koordinatı",
                },
                latitude: {
                    type: "number",
                    description: "Enlem koordinatı",
                },
                srid: {
                    type: "number",
                    description: "Spatial Reference System ID (varsayılan: 4326)",
                },
            },
            required: ["longitude", "latitude"],
        },
    },
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. It states this creates geometry but doesn't mention whether this is a read-only operation, if it modifies data, what permissions are required, or what happens to the created geometry. For a creation tool with zero annotation coverage, this leaves significant behavioral gaps.

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 a single, efficient sentence in Turkish that directly states the tool's purpose. There's no wasted words or unnecessary elaboration - it's appropriately concise for what it communicates.

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

Completeness2/5

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

For a geometry creation tool with no annotations and no output schema, the description is insufficient. It doesn't explain what happens to the created point geometry, whether it's stored or returned, or how it integrates with other spatial operations. Given the complexity of spatial tools and the lack of structured metadata, the description should provide more context.

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?

The schema description coverage is 100%, so the schema already documents all three parameters thoroughly. The description doesn't add any parameter-specific information beyond what's in the schema. The baseline score of 3 is appropriate when the schema does the heavy lifting for parameter documentation.

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 action ('oluştur' - create) and resource ('nokta geometrisi' - point geometry) from coordinates. It's specific about what the tool does, though it doesn't explicitly differentiate from sibling tools like 'create-linestring' or 'create-polygon' which create other geometry types.

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?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention sibling tools like 'create-linestring' or 'create-polygon' for creating other geometry types, nor does it provide context about when point geometry creation is appropriate versus other operations.

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

Related 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/receptopalak/postgis-mcp'

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