linxio-js
API Reference

Geofences

Geofence area and area-group HTTP endpoints.

The REST API names geofences as areas. Use archive endpoints for reversible operations and delete endpoints only when you intend to remove records permanently.

GET /areas

GET

List geofences

/areaslinxio.geofences.list(params)

Returns a paginated list of geofence areas.

Query parameters

limit
number
optional
Number of records per page.
page
number
optional
Page number to read.
fields[]
string[]
optional
Optional field projection.
sort
string
optional
Sort expression accepted by Linxio.

Response fields

data
LinxioGeofence[]
optional
Geofence records for the current page.
page / limit / total
number
optional
Pagination metadata.

GET /areas/{areaId}

GET

Get a geofence

/areas/{areaId}linxio.geofences.get(areaId)

Returns one geofence area by ID.

Path parameters

areaId
LinxioId
required
Geofence area identifier.

Response fields

id
LinxioId
optional
Geofence area identifier.
name
string
optional
Geofence display name.
type
circle | polygon | polyline | rectangle
optional
Geometry type.
coordinates
LatLng[]
optional
Geometry coordinates when supplied.
radius
number
optional
Circle radius in metres when supplied.

POST /areas

POST

Create a geofence

/areaslinxio.geofences.create(payload)

Creates a geofence area.

Body parameters

name
string
required
Display name.
type
circle | polygon | polyline | rectangle
required
Geometry type.
coordinates
LatLng[]
optional
Geometry coordinates. Circles typically use one centre point.
radius
number
optional
Circle radius in metres.
color
string
optional
Display colour accepted by Linxio.

Response fields

id
LinxioId
optional
Created geofence area ID.

PATCH /areas/{areaId}

PATCH

Update a geofence

/areas/{areaId}linxio.geofences.update(areaId, payload)

Updates a geofence area.

Path and body parameters

areaId
LinxioId
required
Geofence area identifier.
body
Partial<LinxioGeofencePayload>
required
Fields to update.

Response fields

id
LinxioId
optional
Updated geofence area ID.

PATCH /areas/{areaId}/archive

PATCH

Archive a geofence

/areas/{areaId}/archivelinxio.geofences.archive(areaId)

Soft-archives a geofence area.

Path parameters

areaId
LinxioId
required
Geofence area identifier.

Response

status
204 or JSON
optional
Successful archive response.

PATCH /areas/{areaId}/restore

PATCH

Restore a geofence

/areas/{areaId}/restorelinxio.geofences.restore(areaId)

Restores a previously archived geofence area.

Path parameters

areaId
LinxioId
required
Archived geofence area identifier.

Response

status
204 or JSON
optional
Successful restore response.

DELETE /areas/{areaId}

DELETE

Delete a geofence

/areas/{areaId}linxio.geofences.delete(areaId)

Permanently deletes a geofence area.

Path parameters

areaId
LinxioId
required
Geofence area identifier.

Response

status
204 or JSON
optional
Successful delete response.

GET /area-groups

GET

List geofence groups

/area-groupslinxio.geofences.listGroups()

Lists area groups.

Query parameters

none
void
optional
No query parameters are required.

Response fields

id
LinxioId
optional
Area group identifier.
name
string
optional
Area group display name.

GET /area-groups/{groupId}

GET

Get a geofence group

/area-groups/{groupId}linxio.geofences.getGroup(groupId)

Returns one area group by ID.

Path parameters

groupId
LinxioId
required
Area group identifier.

Response fields

id
LinxioId
optional
Area group identifier.
name
string
optional
Area group display name.

POST /area-groups

POST

Create a geofence group

/area-groupslinxio.geofences.createGroup(payload)

Creates an area group.

Body parameters

name
string
required
Area group display name.

Response fields

id
LinxioId
optional
Created area group ID.

PATCH /area-groups/{groupId}

PATCH

Update a geofence group

/area-groups/{groupId}linxio.geofences.updateGroup(groupId, payload)

Updates an area group.

Path and body parameters

groupId
LinxioId
required
Area group identifier.
name
string
optional
Updated group name.

Response fields

id
LinxioId
optional
Updated area group ID.

PATCH /area-groups/{groupId}/archive

PATCH

Archive a geofence group

/area-groups/{groupId}/archivelinxio.geofences.archiveGroup(groupId)

Soft-archives an area group.

Path parameters

groupId
LinxioId
required
Area group identifier.

Response

status
204 or JSON
optional
Successful archive response.

PATCH /area-groups/{groupId}/restore

PATCH

Restore a geofence group

/area-groups/{groupId}/restorelinxio.geofences.restoreGroup(groupId)

Restores a previously archived area group.

Path parameters

groupId
LinxioId
required
Archived area group identifier.

Response

status
204 or JSON
optional
Successful restore response.

DELETE /area-groups/{groupId}

DELETE

Delete a geofence group

/area-groups/{groupId}linxio.geofences.deleteGroup(groupId)

Permanently deletes an area group.

Path parameters

groupId
LinxioId
required
Area group identifier.

Response

status
204 or JSON
optional
Successful delete response.

On this page