PilotFoxDocs

Get live visitor locations

GET
/api/v1/sites/{siteId}/geo/live

The visitors seen in the last minutes (5 by default, 30 at most), most recent first, with their approximate location and when they were last seen. 503 when live presence cannot be read.

Requires sessions:read on the site (an API key, or a signed-in member's role). Share links: 401.

Authorization

headerx-api-key<token>

An organization API key (ak_…), with the permissions and the sites it was created with. For servers and scripts: no cookie and no Origin check. Also accepted as Authorization: Bearer ak_… (apiKeyBearer). A request carries one credential: a key sent with a share token or a live session cookie is 400 (details.reason: ambiguous_credentials).

Scope: sessions:read

Path Parameters

siteId*string

Query Parameters

minutes?integer
Range1 <= value <= 30
Default5

Response Body

OK

application/json
  1. response
data*array<>
meta*
Example Request
curl -X GET 'https://pilotfox.app/api/v1/sites/string/geo/live'
Example Response200
{  "data": [    {      "visitor_id": "string",      "lat": 0,      "lon": 0,      "country": "string",      "city": "string",      "last_seen_ms": 0    }  ],  "meta": {    "window": {      "from": "string",      "to": "string",      "tz": "string",      "bucket": "minute"    },    "compare": {      "from": "string",      "to": "string"    },    "totalCount": -9007199254740991,    "nextCursor": "string",    "truncated": true,    "cache": "hit"  }}