⚡ OFFICIËLE DEVELOPER API REFERENTIE V1

Huntly Developer API Referentie

Integreer actuele brandstofprijzen, GPS-coördinaten en metadata van ruim 80.000 tankstations met minimale edge-latentie via Vercel Global Edge.

1. Overzicht & Architectuur

De B2B API van Huntly biedt gestandaardiseerde realtime toegang tot brandstofgegevens in 6 gecertificeerde EU-markten (Nederland/VK, Frankrijk, Duitsland, Italië, Spanje, Portugal) en Quebec (Canada).

Globale Basis 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. Authenticatie (X-Huntly-Key)

Alle beveiligde endpoints vereisen een actieve API-sleutel in de `X-Huntly-Key` header of via `Authorization: Bearer <API_KEY>`.

Verplichte HTTP Header:
X-Huntly-Key: hnt_sbx_9a8b7c6d5e4f3a2b1c0d

Sandbox-sleutels (`hnt_sbx_...`) bevatten 500 gratis verzoeken per maand zonder creditcard.

3. Snelstart (Quickstart)

Voer uw eerste API-aanroep uit in minder dan 60 seconden:

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

Georuimtelijke zoekactie binnen een gekozen straal rond GPS-coördinaten (PostGIS ST_DWithin).

ParameterTypeVerplichtStandaardBeschrijving
latfloatSì—Breedtegraad in decimale graden (-90.0 tot 90.0)
lngfloatSì—Lengtegraad in decimale graden (-180.0 tot 180.0)
radius_kmfloatNo10Zoekstraal in kilometers (min 0.5, max 50)
fuel_typestringNoallBrandstoffilter: `diesel`, `benzina`, `gpl`, `metano`.
limitintegerNo20Maximaal aantal stations (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

Filteren op administratief gebied (Stad of 2-letterige ISO-landcode).

ParameterTypeVerplichtStandaardBeschrijving
countrystringOpzionale*—2-letterige ISO-code: `IT`, `FR`, `DE`, `ES`, `PT`, `UK`, `CA`.
citystringOpzionale*—Stadsnaam (bijv. Amsterdam, Rotterdam, Rome, Parijs).
fuel_typestringNoallBrandstoffilter: `diesel`, `benzina`, `gpl`, `metano`.
limitintegerNo50Numero di risultati (min 1, max 200)
⚠️ Nota Filtro: Minstens `country` of `city` is verplicht.
GET/api/v1/health

Publiek endpoint voor uptime- en statuscontrole van het cluster.

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. Snelheidsbeperkingen & HTTP Headers

Elke HTTP-respons bevat headers om uw verbruik bij te houden:

Header HTTPTipoDescrizione
X-RateLimit-LimitintegerMaandelijkse limiet op basis van uw actieve abonnement.
X-RateLimit-RemainingintegerResterende aanroepen in de huidige maandcyclus.
X-RateLimit-ResetISO-8601 stringISO-tijdstip waarop het maandquotum wordt hersteld.
Cache-ControlstringValori di caching Edge (`s-maxage=600`, `stale-while-revalidate`) per azzerare le latenze tra chiamate identiche.

8. HTTP Statuscodes & Foutafhandeling

CodeBetekenisTypisch Scenario
200OKVerzoek succesvol verwerkt.
400Bad RequestOntbrekende of ongeldige parameters (bijv. straal > 50km).
401UnauthorizedAPI-sleutel ongeldig of ingetrokken.
429Too Many RequestsMaandquotum overschreden.
500Internal ErrorInterne serverfout.

Technische ondersteuning nodig?

Ons team helpt u graag bij enterprise-integraties en SLA-contracten.

📧 Mail naar infos@gethuntly.eu