Skip to content
GET /v1/nearby

Ports within a radius of a coordinate

Try it live

10 free calls per day — no sign-up, no API key. Goes through the oanor gateway.

Custom headers (optional)
api.oanor.com/seaports-api

It works. Grab an API key and use it in your project.

Get an API key

Code snippets

curl "https://api.oanor.com/seaports-api/v1/nearby" \
  -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/seaports-api/v1/nearby", {
  headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/seaports-api/v1/nearby");
curl_setopt($ch, CURLOPT_HTTPHEADER, ["x-oanor-key: oanor_test_..."]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$out = curl_exec($ch);
import requests
requests.get(
    "https://api.oanor.com/seaports-api/v1/nearby",
    headers={"x-oanor-key": "oanor_test_..."}
)

Example response

A real response from this endpoint, captured by the latest health check.

{
    "data": {
        "count": 10,
        "total": 27,
        "center": {
            "lat": 51.9,
            "lon": 4.48
        },
        "results": [
            {
                "id": "31140",
                "name": "Rotterdam",
                "country": "Netherlands",
                "latitude": 51.9,
                "longitude": 4.48333,
                "un_locode": "NL RTM",
                "water_body": "North Sea; North Atlantic Ocean",
                "distance_km": 0.2,
                "harbor_size": "Large",
                "harbor_type": "River (Basins)"
            },
            {
                "id": "31130",
                "name": "Schiedam",
                "country": "Netherlands",
                "latitude": 51.9,
                "longitude": 4.4,
                "un_locode": "NL SCI",
                "water_body": "North Sea; North Atlantic Ocean",
                "distance_km": 5.5,
                "harbor_size": "Very Small",
                "harbor_type": "River (Basins)"
            },
            {
                "id": "31120",
                "name": "Vlaardingen",
                "country": "Netherlands",
                "latitude": 51.9,
                "longitude": 4.35,
                "un_locode": "NL VLA",
                "water_body": "North Sea; North Atlantic Ocean",
                "distance_km": 8.9,
                "harbor_size": "Very Small",
                "harbor_type": "River (Basins)"
            },
            {
                "id": "31150",
                "name": "Dordrecht",
                "country": "Netherlands",
                "latitude": 51.81667,
                "longitude": 4.65,
                "un_locode": "NL DOR",
                "water_body": "North Sea; North Atlantic Ocean",
                "distance_km": 14.9,
                "harbor_size": "Medium",
                "harbor_type": "River (Natural)"
            },
            {
                "id": "31100",
                "name": "Maassluis",
                "country": "Netherlands",
                "latitude": 51.91667,
                "longitude": 4.25,
                "un_locode": "NL MSL",
                "water_body": "North Sea; North Atlantic Ocean",
                "distance_km": 15.9,
                "harbor_size": "Very Small",
                "harbor_type": "Canal or Lake"
            },
            {
                "id": "31080",
                "name": "Hoek Van Holland",
                "country": "Netherlands",
                "latitude": 51.95,
                "longitude": 4.13333,
                "un_locode": "NL HVH",
                "water_body": "North Sea; North Atlantic Ocean",
                "distance_km": 24.4,
                "harbor_size": "Very Small",
                "harbor_type": "River (Basins)"
            },
            {
                "id": "31085",
                "name": "Europoort",
                "country": "Netherlands",
                "latitude": 51.95,
                "lon
…