API Reference
API Reference

Create a new geofence

Creates a new geofence for the authenticated user (or target user_id).

  • Circle type requires center_latitude, center_longitude, and radius.
  • Polygon type requires coordinates array with a minimum of 3 points.
Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Body Params
integer

User ID to create geofence for (defaults to authenticated user)

string
required
length ≤ 255

Name of the geofence

string

Description of the geofence

string
enum
required

Type of geofence

Allowed:
float
-90 to 90

Center latitude (required for circle type)

float
-180 to 180

Center longitude (required for circle type)

integer
1 to 100000

Radius in meters (required for circle type, 1m to 100km)

coordinates
array of objects

Coordinate points (required for polygon, min 3). Each point accepts either {latitude, longitude} or {lat, lng} keys.

coordinates
string
length ≤ 255
string
length ≤ 100
string
length ≤ 100
string
length ≤ 20
string
length ≤ 100
boolean
Defaults to true

Send notification when entering geofence

boolean
Defaults to true

Send notification when exiting geofence

string
enum
Defaults to active

Status of the geofence

Allowed:
string
length ≤ 7
Defaults to #3388ff

Display color in hex format (e.g.,

Responses
200

Validation error

401

Unauthorized - Invalid or expired token

403

Unauthorized - Cannot create geofences for this user

Language
Credentials
Bearer
JWT
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json