Skip to content

Quickstart — cURL

From zero to first response in under 60 seconds. No SDK install.

1. Get a free key

Sign up at /start with your work email. We email a magic link; clicking it reveals a key that begins with gr_free_.

2. Make your first call

export GR_KEY=gr_free_xxx_your_key_here

curl -H "X-API-Key: $GR_KEY" \
  "https://api.gridrock.ai/v1/geo/reverse?lat=19.0760&lng=72.8777" | jq

You should see a JSON response with city, ward, pincode, H3 cell, and an _agent envelope describing what the response means.

3. Look at the headers

X-RateLimit-Limit: 5
X-RateLimit-Remaining: 4
X-RateLimit-Reset: 1714816800
X-Request-Cost: 5
X-Cache-TTL: 86400

Every response carries cost & quota headers — your code (or your agent) never has to guess.

4. Try the showcase endpoint

curl -H "X-API-Key: $GR_KEY" \
  "https://api.gridrock.ai/v1/intel/hex/8861aacd1bfffff" | jq

That single call returns labels + admin + transit + POIs + env signals — the kitchen-sink shape we built for LLM tool-use.

Next