Deprecated
Change state (legacy, alias of /togglestate.php)
POST
/togglebaker.php
Authenticated by a per-device token and the caller's IP address
(both must match a configured legacy device). Parameters always come
from the query string; on POST any request body is ignored.
Invalid parameters and failed authentication both respond with a
redirect to https://www.pixelbar.nl/ rather than an error status.
Authorizations
legacyToken
A per-device token issued by the Pixelbar board, accepted only from that device's registered IP address. Failures redirect to https://www.pixelbar.nl/ instead of returning 401.
Type
API Key (query: token)
Parameters
Query Parameters
token*
The device's token, issued by the Pixelbar board.
Type
Requiredstring
Min Length
1user*
Type
Requiredstring
Example
"your-name"Min Length
1state*
Type
Requiredstring
Valid values
"open""closed"Example
"open"Responses
Plain text. SUCCESS if the state changed, otherwise
ALLREADY TOGGLED TO THIS STATE (sic — the typo is preserved on purpose).
text/plain
JSON
"SUCCESS"