Push API

Updated by Travis Bates

This article details how to enter and subscribe devices to an external server endpoint to receive the data.

Read more about push API services


Format

The body data is sent as www-formdata.

  • In PHP this is $_POST
  • In Python fastapi this is request.form()
  • In Python flask this is request.form
  • In Python Django it is request.POST
  • In Node JS with Express app.use(express.urlencoded());


Enter endpoint
  • Select API.
  • Click the Endpoints tab.
  • Click the + Add Endpoint button.
  • Enter a URL. The URL must be prepended with "http://", "https://" or "//" to be valid.
  • Enter a header key and header value. The header value cannot be empty.
  • Click Save.

Subscribe devices
  • Click the Edit button to the right of the number of Subscribed Devices.
  • Select the desired device(s) by turning the toggle on (blue toggle).
  • Click Save.
Limit of two endpoints per device.
Only the user who created the endpoint can edit the URL or the headers.


Test endpoint

Send a test packet or view an example payload. Must have at least one subscribed device.


Disabled endpoint

If the endpoint has a connection failure (i.e client-server is down, typo in the URL) the endpoint will be disabled after 5 concurrent failures. An email will be sent to notify the user of the connection failure.

Example: in-app notice of connection failure.

Example: in-app notice of connection failure.


How did we do?