⚡ OFFICIAL DEVELOPER API REFERENCE V1

Huntly Developer API Reference

Integrate verified real-time fuel prices, GPS coordinates, and brand metadata from 80,000+ stations with sub-20ms edge latency via Vercel Global Edge.

1. Overview & Architecture

The Huntly B2B API provides standardized, real-time access to fuel station telemetry and pump prices across 6 certified European markets (France, Germany, Italy, Spain, Portugal, United Kingdom) and Quebec (Canada). Powered by Vercel Global Edge nodes and an optimized PostGIS spatial database.

Global Base URL:
https://www.gethuntly.eu/api/v1
✨ Copertura Ufficiale: Italia, Francia, Germania, Spagna, Portogallo, Regno Unito e Quebec (Canada) con granularità per singola stazione e coordinate GPS geoverificate. I dati di Svizzera e Belgio sono forniti come medie nazionali collaborative.

2. Authentication (X-Huntly-Key)

All protected API endpoints require an active API key passed in the `X-Huntly-Key` HTTP header. Alternatively, the standard `Authorization: Bearer <API_KEY>` header is supported.

Mandatory HTTP Header:
X-Huntly-Key: hnt_sbx_9a8b7c6d5e4f3a2b1c0d

Sandbox keys (`hnt_sbx_...`) include 500 free requests per month without requiring a credit card. Starter and Professional plans offer scalable quotas with automatic monthly billing.

3. Quickstart

Make your first API call in under 60 seconds with your favorite tool or runtime:

curl -X GET "https://www.gethuntly.eu/api/v1/fuel/nearby?lat=41.9028&lng=12.4964&radius_km=5&fuel_type=diesel" \
  -H "X-Huntly-Key: YOUR_API_KEY"
GET/api/v1/fuel/nearby

Real-time spatial search within a specified radius around GPS coordinates (PostGIS ST_DWithin).

ParameterTypeRequiredDefaultDescription
latfloatSì—Latitude in decimal degrees (-90.0 to 90.0)
lngfloatSì—Longitude in decimal degrees (-180.0 to 180.0)
radius_kmfloatNo10Search radius in kilometers (min 0.5, max 50)
fuel_typestringNoallFuel type filter: `diesel`, `benzina`, `gpl`, `metano`. If omitted, all types are returned.
limitintegerNo20Maximum number of stations returned (min 1, max 100)
Esempio Risposta JSON (200 OK):
200 OK — application/json
{
  "status": "success",
  "meta": {
    "query": {
      "latitude": 41.9028,
      "longitude": 12.4964,
      "radius_km": 5,
      "fuel_type": "diesel",
      "limit": 20
    },
    "results_count": 1,
    "tier": "sandbox",
    "quota_remaining": 492,
    "timestamp": "2026-10-10T12:00:00.000Z"
  },
  "data": [
    {
      "id": "shop_01j7h8k...",
      "name": "Eni Station Roma Termini",
      "brand": "Eni",
      "address": "Via Giovanni Giolitti 40",
      "city": "Roma",
      "country": "IT",
      "coordinates": {
        "latitude": 41.8982,
        "longitude": 12.5034
      },
      "distance_km": 0.78,
      "fuel": {
        "type": "diesel",
        "price": 1.639,
        "service_type": "self",
        "last_updated": "2026-10-10T06:15:00.000Z"
      }
    }
  ]
}
GET/api/v1/fuel/stations

Filter fuel stations by administrative region (City or 2-letter ISO Country Code).

ParameterTypeRequiredDefaultDescription
countrystringOpzionale*—2-letter ISO country code: `IT`, `FR`, `DE`, `ES`, `PT`, `UK`, `CA`.
citystringOpzionale*—City name (e.g. Roma, Madrid, Paris, Berlin, Milano). Case-insensitive search.
fuel_typestringNoallFuel type filter: `diesel`, `benzina`, `gpl`, `metano`. If omitted, all types are returned.
limitintegerNo50Numero di risultati (min 1, max 200)
⚠️ Nota Filtro: At least one parameter between `country` or `city` must be provided to avoid runaway database table scans.
GET/api/v1/health

Public endpoint (no key required) for edge health monitoring and capability discovery.

200 OK — Pubblico (Nessuna chiave richiesta)
{
  "status": "ok",
  "service": "Huntly European Fuel & Retail B2B API",
  "version": "v1.0.0",
  "timestamp": "2026-10-10T12:00:00.000Z",
  "coverage": {
    "countries": ["IT", "FR", "ES", "DE", "PT", "NL", "BE", "CA-QC"],
    "stations_monitored": "80,000+"
  }
}

7. Rate Limiting & HTTP Headers

Every HTTP response includes diagnostic headers to track quota usage in real time:

Header HTTPTipoDescrizione
X-RateLimit-LimitintegerMaximum monthly calls allowed by your active subscription plan.
X-RateLimit-RemainingintegerRemaining calls for the current billing cycle.
X-RateLimit-ResetISO-8601 stringISO timestamp when the monthly quota will reset.
Cache-ControlstringValori di caching Edge (`s-maxage=600`, `stale-while-revalidate`) per azzerare le latenze tra chiamate identiche.

8. HTTP Status Codes & Handling

CodeMeaningTypical Scenario
200OKRequest succeeded successfully.
400Bad RequestMissing or invalid query parameters (e.g. invalid latitude or radius > 50km).
401UnauthorizedMissing, invalid, or revoked API key.
429Too Many RequestsMonthly quota exceeded (upgrade plan or contact sales).
500Internal ErrorInternal server error. Automatically alerted to our engineering team.

Need technical assistance?

Our engineering team provides dedicated support for enterprise integrations, custom data pipelines, and SLA agreements.

📧 Email infos@gethuntly.eu