The base URL is
https://api.radar.io. Send your API key in the Authorization header. For key types, the error format, and rate limits, see Authentication, errors, and rate limits.
For SDK setup, ranging requirements, and beacon events, see Track indoor location with beacons.
Beacon object
A beacon represents a Bluetooth beacon monitored in your project. Every beacon has a Radar_id. A beacon can also have a tag and an externalId that together identify it in your own system.
Example beacon
This beacon is an iBeacon at a store register.List beacons
Lists beacons. Beacons are sorted descending bycreatedAt.
- Endpoint:
GET /v1/beacons - Authentication: Secret key
- Rate limit: 10 requests per second
Query parameters
To look up a beacon by its
tag and externalId, send both as filters. The matching beacon is the only item in beacons.
Response
A200 response contains meta, with a hasMore boolean, and beacons, an array of beacon objects. To get the next page, pass the createdAt of the last beacon as createdBefore. See Pagination.
Example
This request lists the beacons with the tagstore-register.
Errors
Get a beacon
Gets a beacon by its Radar_id.
- Endpoint:
GET /v1/beacons/:id - Authentication: Secret key
- Rate limit: 10 requests per second
Path parameters
Response
A200 response contains meta and beacon, a beacon object.
Example
This request gets a beacon by its Radar_id.
Errors
A
404 response looks like this:
Create a beacon
Creates a beacon. This operation fails if a beacon with the sametag and externalId already exists. To create or update in one call, use Upsert a beacon.
- Endpoint:
POST /v1/beacons - Authentication: Secret key
- Rate limit: 10 requests per second
Body parameters
Response
A200 response contains meta and beacon, the created beacon object.
Example
This request creates an iBeacon.Errors
A
409 response looks like this:
Upsert a beacon
Upserts a beacon. Reference the beacon bytag and externalId, or by Radar _id. If a beacon with the specified tag and externalId exists, Radar updates it. If not, Radar creates it. Because the result is the same when you repeat the request, this is the recommended way to sync beacons from your own system.
- Endpoint:
PUT /v1/beacons/:tag/:externalIdorPUT /v1/beacons/:id - Authentication: Secret key
- Rate limit: 10 requests per second
- Used by: Track indoor location with beacons
Path parameters
Body parameters
When you reference the beacon by Radar
_id, you can also send tag and externalId in the body to set them.
Response
A200 response contains meta and beacon, the created or updated beacon object.
Example
This request creates or updates an iBeacon bytag and externalId.
Errors
Delete a beacon
Deletes a beacon by its Radar_id.
- Endpoint:
DELETE /v1/beacons/:id - Authentication: Secret key
- Rate limit: 10 requests per second
Path parameters
Response
A200 response contains only meta.
Example
This request deletes a beacon by its Radar_id.
Errors
CSV import columns
A beacon CSV file has a header row followed by one row per beacon. To import one, open the Beacons page, click Import, and select the file. Past imports are listed on the beacon import history page. For an example file, see Create beacons.
A row with a
tag and externalId that already exist updates that beacon. To replace a failed unit or rotate identifiers, import the beacon again with the same tag and externalId and the new identifiers.