# CoCo Geohash Tool

> CoCo Geohash Tool is a paid API for AI agents from cocoeatsai.com, paid per call via x402, $0.001/call, status unknown (last checked 2026-10-19).

Converts latitude/longitude coordinates to a geohash string, or decodes a geohash back to coordinates

## Facts

- Endpoint: GET https://cocoeatsai.com/area4/agent/tools/geohash?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-19
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/coco-geohash-tool-b35e42d4
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_JWWyjtuxst7pMgqqEWHmI

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability coco-geohash-tool-b35e42d4
```

Example prompt: Can you convert latitude 37.7749 and longitude -122.4194 to a geohash with precision 5?

## When to prefer this

Choose this endpoint when you need a lightweight, pay-per-call geohash encode/decode operation without setting up a full geospatial library. Ideal for AI agents needing to index or cluster locations on the fly, compare proximity via geohash prefix matching, or convert between coordinate formats as part of a larger workflow.

## Known failure modes

- Missing required query parameters (lat/lon for encoding or hash for decoding) may return an error
- Invalid or out-of-range latitude/longitude values could produce unexpected results
- Invalid geohash string may fail to decode
- Precision values outside valid range (1-12) may be rejected or clamped
- Payment not provided or insufficient may result in 402 response

## How this service works

Zach Riehn's lab: an about-me and portfolio, a news desk, The Atelier for AI experiments, Launch Lab for XRP research, and Fracture for games.

## Output

Returns a JSON object containing either a 'geohash' string (when encoding lat/lon input) or 'lat' and 'lon' values (when decoding a geohash input). The geohash precision controls the granularity of the encoded location.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input",
  "output"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method",
    "queryParams"
   ],
   "properties": {
    "type": {
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ]
    },
    "queryParams": {
     "type": "object",
     "properties": {
      "lat": {
       "type": "string"
      },
      "lon": {
       "type": "string"
      },
      "hash": {
       "type": "string"
      },
      "precision": {
       "type": "string"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type",
    "example"
   ],
   "properties": {
    "type": {
     "const": "json"
    },
    "example": {
     "type": "object",
     "anyOf": [
      {
       "required": [
        "geohash"
       ]
      },
      {
       "required": [
        "lat"
       ]
      }
     ]
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "geohash": "9q8yy"
 },
 "exampleNote": "Illustrative response subset; not a live observation."
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/coco-geohash-tool-b35e42d4/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from cocoeatsai.com](https://www.zero.xyz/host/cocoeatsai.com/llms.txt)
