Leapcraft Client API (1.0.0)

Download OpenAPI specification:

Welcome to the Leapcraft Client API. This API provides RESTful methods to manage devices and fetch telemetry data—either as real-time raw events or processed averages.

Key Entities

  • API KEY: A unique key issued to every client. Keep this protected.
  • Device: Hardware sensors (AirBird, Ambinode, etc.).
  • Topology: Defines the relationship between sensing devices and a central hub.
  • Telemetry (Raw): The latest single data point recorded by the sensor.
  • Telemetry (Averages): Time-series metrics processed at specific resolutions (daily, weekly, monthly).
  • Things: Fetches a list of "things" with their associated parameters.

Authentication

The API uses Bearer Token Authentication.

  1. Use your api_key at /auth/client/token to exchange it for a transactional token.
  2. Include the token in the header: Authorization: Bearer <your_token>.

Authentication

Get access token

Request Body schema: application/x-www-form-urlencoded
api_key
required
string

Responses

Request samples

curl -X POST https://api.leapcraft.com/v1/auth/client/token \
  -H "Content-Type: application/x-www-form-urlencoded" \
  -d "api_key=YOUR_API_KEY"

Response samples

Content type
application/json
{
  • "type": "bearer",
  • "token": "9e65a545de443ccbe72c0bbfbe638f2fFJwyr..."
}

Devices

List all devices

Authorizations:
bearerAuth
query Parameters
limit
integer
Default: 100

limit = -1 to get full list

page
integer
Default: 1

Returned values are the value of limit multiplied by page. The first page is 1

Responses

Request samples

curl -X GET "https://api.leapcraft.com/v1/devices?limit=100" \
  -H "Authorization: Bearer YOUR_TOKEN"

Response samples

Content type
application/json
[
  • {
    }
]

Get device details

Authorizations:
bearerAuth
path Parameters
physical_id
required
string

Responses

Request samples

curl -X GET "https://api.leapcraft.com/v1/devices/testsim00004" \
  -H "Authorization: Bearer YOUR_TOKEN"

Response samples

Content type
application/json
{
  • "serial": "LC-2026-X88",
  • "meta": { }
}

Telemetry

Fetch Telemetry (Raw or Averages)

Authorizations:
bearerAuth
path Parameters
physical_id
required
string
query Parameters
type
required
string
Enum: "latest" "averages"
resolution
string
Enum: "daily" "weekly" "monthly"

Required if type=averages

from
string <date-time>

Start timestamp. Required if type=averages.

to
string <date-time>

End timestamp. Required if type=averages.

Responses

Request samples

curl -X GET "https://api.leapcraft.com/v1/telemetry/testsim00004?type=averages&resolution=daily&from=2021-05-26T00:00:00.000&to=2021-05-27T11:42:58.721" \
  -H "Authorization: Bearer YOUR_TOKEN"

Response samples

Content type
application/json
Example
{
  • "physical_id": "D2:C1:AA:FF:3E:09",
  • "timestamp": "2026-03-29T15:24:05Z",
  • "data": {
    },
  • "created_at": "2026-03-29T15:24:07Z"
}

Topology

Get all topologies

Authorizations:
bearerAuth

Responses

Request samples

curl -X GET "https://api.leapcraft.com/v1/topologies" \
  -H "Authorization: Bearer YOUR_TOKEN"

Response samples

Content type
application/json
[
  • {
    }
]

Get topology details

Authorizations:
bearerAuth
path Parameters
topology_id
required
string

The gateway ID of the topology

Responses

Request samples

curl -X GET "https://api.leapcraft.com/v1/topologies/0123245cf74c60d7ee" \
  -H "Authorization: Bearer YOUR_TOKEN"

Response samples

Content type
application/json
{
  • "gateway_id": "0123245cf74c60d7ee",
  • "created_at": "2020-12-16 13:51:58",
  • "name": null,
  • "devices": [
    ]
}

Notifications

Get alerts and notifications

Authorizations:
bearerAuth
query Parameters
physical_id
string
limit
integer <= 50
Default: 20
offset
integer
Default: 0

Responses

Request samples

curl -X GET "https://api.leapcraft.com/v1/notifications?limit=20&offset=0" \
  -H "Authorization: Bearer YOUR_TOKEN"

Response samples

Content type
application/json
[
  • {
    }
]

Things

Retrieve a list of things

Authorizations:
bearerAuth
query Parameters
limit
integer
Default: 10

Use -1 to gell all items.

Responses

Response samples

Content type
application/json
[
  • {
    }
]