#
Alarms
An alarm is a set of data that signifies an event. It's Firewalla's core features that summarizes stuff that needs attention so users can better understand and protect their network.
#
Get Alarms
This API gets all alarms within current MSP.
GET https://msp_domain/v2/alarms
Header
Query String
Response
200 Success
{
"count": 1,
"results": [
{
"aid": 1,
"type": "5",
"message": "Found a new device iPhone connected to your network.",
"ts": 1664522841.895,
"gid": "00000000-0000-0000-0000-000000000000"
}
],
"next_cursor": null
}
401 Permission Denied
Examples
- Get-Active-Alarms-By-Specific-Box,
Query String
Pagination
#
Get An Alarm
This API gets a specific alarm.
GET https://msp_domain/v2/alarms/:gid/:aid
Header
Path
Response
200 Success
A JSON representation of Alarms
{
"aid": 1,
"type": "5",
"message": "Found a new device iPhone connected to your network.",
"ts": 1664522841.895,
"gid": "00000000-0000-0000-0000-000000000000",
"device": {
"name": "iPhone",
"mac": "AA:BB:CC:DD:EE:FF",
"ip": "192.168.1.2",
"network": {
"id": "00000000-0000-0000-0000-000000000000",
"name": "Lan 1"
},
"group": {
"id": "1",
"name": "Guest"
}
}
}
401 Permission Denied
Examples
// https://github.com/axios/axios
const axios = require("axios");
// Change these variables to what you have
const msp_domain = process.env.msp_domain || "mydomain.firewalla.net";
const token = process.env.token || "your_personal_access_token";
const gid = "00000000-0000-0000-0000-000000000000";
const aid = 1;
axios({
method: "get",
url: `https://${msp_domain}/v2/alarms/${gid}/${aid}`,
headers: {
"Authorization": `Token ${token}`
}
}).then(res => {
console.log(res.data);
})
curl --request GET \
--url "https://${msp_domain}/v2/alarms/${gid}/${aid}" \
--header "Authorization: Token ${your_personal_access_token}"
#
Delete An Alarm
This API deletes an existing alarm.
DELETE https://msp_domain/v2/alarms/:gid/:aid
Header
Path
Response
200 Success
401 Permission Denied
404 Not Found
Examples
// https://github.com/axios/axios
const axios = require("axios");
// Change these variables to what you have
const msp_domain = process.env.msp_domain || "mydomain.firewalla.net";
const token = process.env.token || "your_personal_access_token";
const gid = "00000000-0000-0000-0000-000000000000";
const aid = 1;
axios({
method: "delete",
url: `https://${msp_domain}/v2/alarms/${gid}/${aid}`,
headers: {
"Authorization": `Token ${token}`
}
}).then(res => {
console.log(res.data);
})
curl --request DELETE \
--url "https://${msp_domain}/v2/alarms/${gid}/${aid}" \
--header "Authorization: Token ${your_personal_access_token}"