Skip to main content

Place and radius search

Use near when a person or agent supplies a city, town, postal area or travel destination. The API resolves the place to coordinates and searches nearby clubs.

curl 'https://api.eae.golf/v1/clubs?near=Hamburg&country=DE&radius_km=50&limit=20' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Accept: application/json'

Place parameters

ParameterRequiredDescription
nearYesHuman-readable place used as the search centre
countryNoTwo-letter ISO country code used to disambiguate the place
radius_kmNoRadius from 1 to 200 km, defaulting to 50 km

Use a country code when a name may identify places in several countries:

GET /v1/clubs?near=Hamburg&country=DE

Resolved search metadata

The response explains how the place was interpreted:

{
"meta": {
"search": {
"mode": "place",
"input": "Hamburg",
"resolvedName": "Hamburg, Germany",
"countryCode": "DE",
"latitude": 53.5511,
"longitude": 9.9937,
"radiusKm": 50
}
}
}

Results are ordered by distance and expose location.distanceMeters.

Use coordinates when an application already has a precise location:

curl 'https://api.eae.golf/v1/clubs?lat=53.5511&lon=9.9937&radius_km=50&limit=20' \
--header 'Authorization: Bearer YOUR_API_KEY'

lat and lon must be supplied together. radius_km requires either near or both coordinates. Do not combine near with lat and lon.

Exact town filtering

town is not geographic. It matches the postal town stored on the club record:

GET /v1/clubs?town=Hamburg

This intentionally excludes clubs in neighbouring municipalities. Prefer near=Hamburg for normal discovery.

Combine geographic and club filters

curl 'https://api.eae.golf/v1/clubs?near=Hamburg&country=DE&radius_km=80&public=true&independent_players=true&maximum_green_fee=80&limit=20' \
--header 'Authorization: Bearer YOUR_API_KEY'

All filters use AND. This request returns clubs within 80 km of Hamburg that have confirmed public access, accept independent players and have no known green fee above €80.

Pagination

Pass the returned cursor with the same search parameters:

GET /v1/clubs?near=Hamburg&country=DE&radius_km=50&limit=20&cursor=NEXT_CURSOR_VALUE

Do not change the place, radius or other filters while following a cursor.

Errors

CodeMeaning
location_not_foundThe supplied place could not be resolved
geocoding_unavailablePlace resolution is not configured
geocoding_api_key_invalidThe configured geocoding API key is invalid
geocoding_configuration_errorThe provider rejected the server configuration, API restrictions or billing setup
geocoding_quota_exceededThe provider quota has been exhausted
geocoding_failedThe location provider could not complete the request

Clients may retry geocoding_failed after a short delay. Changing the input is more appropriate for location_not_found.