When to use this endpoint

Use for CRM1’s Locations map. This reads cached user location fields rather than querying GPS history.

Authentication and permissions

Authenticate with signed API-key fields or a logged-in CRM session. Session requests use the dispatcher’s CSRF protection when configured.

Configured TeamAccess row scope is applied in the queries. Ordinary collection requests do not need artificial record IDs. Explicit IDs still pass dispatcher record authorization; unavailable IDs can be rejected there rather than silently omitted.

Explicit User GPS View (pageUserGps) is required.

Parameters

This endpoint has no operation-specific parameters.

Example request

$result = FM_api('Users_getLatLon', [
]);

Example response

[
  [
    "1042",
    "54.35",
    "-6.65",
    "1793700000"
  ]
]

Errors and unusual responses

ResponseCondition
{"error":"not logged in"}No authenticated tenant context is available. Invalid signed credentials can be rejected by the dispatcher before the handler runs.

Legacy application errors may be returned with HTTP 200. Check the decoded response for error, not only the HTTP status.

Behaviour and edge cases

  • Includes every tenant row with a truthy last_latlon_time. No active, parent, temporary-user, age/freshness or coordinate-validity filter is added.
  • Each row is [user ID,latitude,longitude,last location Unix timestamp], preserving database scalar values. There is no object per row, sort, pagination or feature-bit gate in the handler.

Side effects

  • Reads data without changing business records, edit markers, activity history or notifications. Shared setting reads can populate their normal settings cache.

See it in Fieldmotion

CRM1

Open Locations in CRM1; pageLocations requests Users_getLatLon and uses array positions to plot markers.

CRM2

No direct production caller was found in CRM2. Current User layouts use the mapped getRequestedDetails/getDataTable flow; do not assume those contracts match this legacy reader.

Related endpoints

  • User_get — Inspect the older complete user-row contract.
  • Users_list — Read the basic selectable user list and its explicit scope predicate.