Project-GC Lua Sandbox API
Loading...
Searching...
No Matches
GetFinds

Member Function Documentation

◆ GetFinds()

GetFinds ( $profileId,
$params = [] )

Returns an associative array with the finds from given profileId.

Coordinates for Premium geocaches will not be returned if the logged in user is not a Premium member with Geocaching.com.

Parameters
int$profileId(required) An integer with the users profile id.
array$params(optional) An optional associative array of options for filtering/sorting/limit.
  • limit (integer): Max number of rows to return
  • excludeDupFinds (bool): Exclude duplicate finds on the same geocache. Only the oldest will be return. Defaults to false.
  • excludeTravelingGeocaches (bool): Exclude geocaches listed in the offical BMAFMJR bookmark list. Defaults to false.
  • includeLabCaches (bool): If set to true, will include labcache finds. Note that most fields returned will be null. The field cache_id is NOT guaranteed to be unique between geocaches and labcaches. Filters are ignored, even for dates.
  • order: NEWESTFIRST to sort with the newest finds first, or OLDESTFIRST for the opposite
  • fields (array): An array with fields names that you want in your return result. If you expect more than 5000 finds you more or less need to use this to decrease the memory usage.
  • gccode, cache_id, cache_name, type, difficulty, terrain, size, owner_id, placed_by, latitude, longitude, elevation, hidden, last_publish_date, country, region, county, archived, disabled, premium, attributes_set, attributes_unset, last_find_date, last_archive_date, num_finds, latest_logs, favorite_points, favorite_points_pct, favorite_points_wilson, last_cache_harvest, last_log_harvest, log_id, visitdate, length, words, ftf, cache_description
  • filter (array): An associative array with filters
  • country (string or array)
  • region (string or array)
  • county (string or array)
  • minVisitDate (string): YYYY-MM-DD, the date will be included, ie: >= date
  • maxVisitDate (string): YYYY-MM-DD, the date will be included, ie: <= date
  • minHiddenDate (string): YYYY-MM-DD, the date will be included, ie: >= date
  • maxHiddenDate (string): YYYY-MM-DD, the date will be included, ie: <= date
  • gccodes (array): List of gccodes
  • types (array): An array of valid types
  • sizes (array): An array of valid sizes
  • difficulties (array): An array of valid values
  • terrains (array): An array of valid values
  • minFavoritePoints (int): Minimum amount of favorite points required
  • minFavoritePointsPercent (int): Minimum amount of favorite points percent required
  • minFavoritePointsWilson (int): Minimum amount of favorite points wilson score required
  • monthnames (array): List of January/February/March/April/May/June/July/August/September/October/November/December
  • daynames (array): List of Monday/Tuesday/Wednesday/Thursday/Friday/Saturday/Sunday
  • radius (array): An associative array
  • algorithm (string): Can be any value of ['Vincenty', 'Haversine']. Defaults to 'Vincenty'.
  • distance (integer): Number of meters.
  • latitude (float): Latitude.
  • longitude (float): Longitude.
  • minMax (string): Can be any value of ['min', 'max']. Defaults to 'max'.
Returns
array|false