Station related resources of Eventstreamr controller API.
GET /api/stations
will return all stations.
[
{
"ip":"10.4.1.195",
"settings":
{
"roles":[],
"nickname":"",
"macaddress":"00-21-5c-02-02-27",
"room":""
},
"_id":"xZljygFs4qRG3jaQ"
}
]
GET /api/station/[MACADDRESS]
will return the specified station.
{
"ip":"10.4.1.195",
"settings":
{
"roles":[],
"nickname":"",
"macaddress":"00-21-5c-02-02-27",
"room":""
},
"_id":"xZljygFs4qRG3jaQ"
}
POST /api/station
will create a new station from the parameters passed
{
"macaddress": "00-B0-D0-86-BB-F7",
"roles": [
"controller"
],
"room": "ROOM_ID",
"nickname": "",
}
This will return 201 Created
along with the current JSON representation of the station if the creation was a success.
PUT /api/station/[MACADDRESS]
will update a station with the parameters passed.
{
"status": "active"
}
This will return a 200 OK
if the update was a success along with the current JSON representation of the station.
DELETE /api/station/[MACADDRESS]
This will return 204 No Content