-
Notifications
You must be signed in to change notification settings - Fork 11
api_probe
Daniel Ramsay edited this page Mar 19, 2023
·
3 revisions
For preparing to register a probe
Generates a new probeHMAC value, stores it in the DB and returns it to the user, only if they are active (e.g. status not pending, banned etc)
Field | Example Payload |
---|---|
[email protected] | |
date | YYYY-MM-DD HH:mm:ss |
signature | User Private Key `hex_hmac(sha512, email + ':' + date, $secret)` |
{
"success":true,
"probe_hmac":"abc1234"
}
For registering a probe. The probe UUID is constructed via the follow pseudo code.
$probeSeed = $macAddress; //Or Android ID or something else unique
//probeHMAC is acquired from the /prepare/probe endpoint
$UUID = md5($probeSeed . "-" . $probeHMAC)
Field | Example Payload |
---|---|
[email protected] | |
probe_seed | e456ddb7ea1f4b7b66d0a06b44e5c850 |
probe_uuid | 30a5307cba6a493b2f6bf9d1d8b4ebd1 |
signature | User Private Key
|
probe_type | raspi / android / atlas / web |
country_code | ISO 3166-1-alpha-2 location of the probe |
{
"success":true,
"secret":"fcAhIPCtu02f4SHUrM5LZjEiLurZiDixPTOx"
}
Returns ISP details for a given IP address.
If the {ip} argument is omitted, information is returned for the request's originating IP
Field | Example Payload |
---|---|
probe_uuid | 30a5307cba6a493b2f6bf9d1d8b4ebd1 |
date | YYYY-MM-DD HH:mm:ss |
signature | Probe Private Key
|
{
"success":true,
"ip":"1.2.3.4",
"isp": "ABC Internet Ltd"
}
To get the latest (or a specific) version of the ORG probe config
Field | Example Payload |
---|---|
version | "latest" or [version number] |
Format | "json" or "xml" |
Config file, in json or XML format