Brapi Find Locations
brapi_find_locationsFind research stations / field sites by country, abbreviation, type, location ID, or free-text. Countries filter by ISO 3166-1 alpha-3 code via countryCodes, or by free-form English country name via countryNames (resolved client-side to alpha-3 — "Uganda" → "UGA"). Optional bbox parameter restricts rows to a latitude/longitude window. When the spec-correct GeoJSON [lon, lat, alt] reading produces zero matches and at least one row carries a Point geometry, the bbox filter retries once with axes swapped (handles non-conformant servers that store [lat, lon, alt]) and surfaces a warning + coordinateAxisOrder: "swapped". When the upstream total exceeds loadLimit, the full result set is materialized as a dataframe — query it with brapi_dataframe_query (SQL).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| bbox | No | Optional post-fetch bounding box. All four corners must be set to activate the filter. | |
| alias | No | Connection alias registered via brapi_connect. Omit to read the connection registered under alias `default` — i.e. a prior brapi_connect call that did not specify an alias. Calls that used a non-default alias must pass that same alias here. | |
| loadLimit | No | Cap on rows returned inline. Omit for the deployment default. Rows beyond the cap land in a dataframe; query with brapi_dataframe_query (SQL) instead of paging row-by-row. | |
| locations | No | Filter by locationDbIds. | |
| countryCodes | No | ISO 3166-1 alpha-3 country codes. | |
| countryNames | No | Free-form English country names or aliases (e.g. "Uganda", "United States", "USA") resolved client-side to ISO 3166-1 alpha-3 codes and merged into countryCodes. Names that do not resolve surface as a warning. Prefer countryCodes when you already have alpha-3 codes. | |
| extraFilters | No | Extra BrAPI filters forwarded verbatim. Valid keys vary by endpoint; brapi_describe_filters enumerates them. Named params on this tool take precedence on conflict. | |
| abbreviations | No | Short location abbreviations. | |
| locationNames | No | Filter by display name. | |
| locationTypes | No | Location type — e.g. "Research Station", "Field". |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| alias | No | Alias of the registered BrAPI connection the call used. | |
| error | No | Present when the call failed. Absent on success. | |
| notice | No | Guidance when no rows were returned — how to broaden filters or retry. | |
| hasMore | No | True when more rows exist beyond the returned set. | |
| results | No | Location rows returned in-context (up to loadLimit). Bbox filter is applied after the upstream fetch. | |
| warnings | No | Advisory messages (bbox malformed, filter overrides, capability gaps). | |
| dataframe | No | Dataframe handle when the full result set was materialized as a dataframe. Query it with brapi_dataframe_query (SQL). | |
| totalCount | No | Total rows reported by the server (or the post-bbox count when a bbox filter is active). | |
| distributions | No | Value frequency per field across the full result set. | |
| returnedCount | No | Length of results[] after any bbox filtering. | |
| appliedFilters | No | The final filter map sent to the server (named + extraFilters). | |
| refinementHint | No | Suggested next-step query refinement when the result set is large. | |
| coordinateAxisOrder | No | Axis interpretation used when reading GeoJSON Point coordinates. "spec" follows the GeoJSON RFC 7946 [lon, lat, alt?] convention. "swapped" indicates the upstream server stores [lat, lon, alt?] (non-conformant) and bbox + rendered coordinates were interpreted accordingly. |