Build tools that read a Tyson HAT's state, set its chamber target, select temperature scaling presets, and manage supported controls. These are the interfaces used by the HAT's dashboard.
Reference firmware: 3.10.4, Bambu-connected build. The paths are not versioned and there is no independent API compatibility promise. Read firmware_version before using an integration. This reference does not establish a Prusa firmware interface or replace a model's hardware installation manual.
| Guide | Contents |
|---|---|
| Getting started | Connect, read state, send your first request, and use the Python example client. |
| Dashboard login and API access | Separate dashboard ID/password and developer-code authentication, sessions, upgrades and recovery. |
| HTTP control API | Hotend scaling, bed scaling/control, fan commands and print controls. |
| WebSocket API | Live state, chamber targets, acknowledgements and reconnect handling. |
| State and discovery | State fields, HAT/printer discovery, scans, diagnostics and thumbnails. |
| Configuration | Chamber settings, hardware visibility, filters, power limits and network settings. |
| Calibration and firmware | Backup/restore formats, channel selection and firmware upload. |
| Errors and compatibility | Status codes, partial success, origin rules and firmware differences. |
| Transport | Address | Payload |
|---|---|---|
| HTTP | http://HAT_IP/ on port 80 |
GET responses are normally JSON; control POSTs normally use URL-encoded form fields. |
| WebSocket | ws://HAT_IP:81/ |
JSON state and command messages; Origin must identify the HAT's HTTP origin. |
| HAT discovery | mDNS, UDP 5353 | _http._tcp.local. with a TYSON_HAT_ service-name prefix. |
New HATs require dashboard login admin / admin and start with developer API access off. Disable All Security makes both browser and API access open and saves that choice. Dashboard Login requires an ID/password for browsers. Enable Developer API Access separately for X-Tyson-Access-Code authentication, or use a valid dashboard session. See Dashboard login and API access. X-Tyson-Request: 1 remains a required mutation header, not an authentication secret. Use the HAT's trusted local network. The public documentation website does not proxy controller commands.
| Method | Endpoint | Reference |
|---|---|---|
| GET | /api/state |
State and discovery |
| GET | /access/status |
LAN access code |
| POST | /access/login, /access/logout, /access/dashboard, /access/configure |
LAN access code |
| WebSocket | Port 81, / |
WebSocket API |
| POST | /api/scaler |
HTTP control API |
| POST | /api/bed |
HTTP control API |
| POST | /api/chamber/fan |
HTTP control API |
| POST | /api/print/control |
HTTP control API |
| POST | /api/dac |
HTTP control API |
| GET | /api/printers |
State and discovery |
| GET | /api/wifi/scan |
State and discovery |
| GET, POST | /api/diagnostics/trace |
State and discovery |
| GET | /api/print/thumbnail |
State and discovery |
| GET, POST | /api/calibration/hotend-mapping |
Calibration and firmware |
| GET, POST | /api/calibration/hotend-presets |
Calibration and firmware |
| GET, POST | /api/calibration/bed |
Calibration and firmware |
| POST | /api/firmware |
Calibration and firmware |
| POST | /settings/control |
Configuration |
| POST | /settings/hardware |
Configuration |
| POST | /settings/rtd-filter |
Configuration |
| POST | /settings/heater-power |
Configuration |
| POST | /wifi/scan, /wifi/save, /wifi/reset |
Configuration |
| POST | /mqtt/save, /mqtt/test |
Configuration |
| POST | /settings/factory-reset |
Configuration |
There is no general JSON POST endpoint for chamber temperature. Use set_setpoint over WebSocket. Likewise, the bed's operational temperature target comes from the connected printer; /api/bed configures scaling/control and calibration rather than setting a normal printer bed target.
Hotend presets map the printer's 300°C endpoint to 300, 350, 400, 425 or 450°C actual temperature. Bed presets map the printer's 110°C endpoint to 110, 165 or 220°C actual temperature. Arbitrary ratios are not accepted by these endpoints.
Selecting a preset, installing/enabling hardware in Settings, and enabling calibrated mapping/control are different operations. Always check the resulting state instead of assuming that a successful settings request enabled heating or completed calibration.
The documentation bundle includes examples/python/tyson_client.py, a small standard-library HTTP example with explicit commands and no automatic write retries. It is an example integration, not a complete SDK. See Getting started for usage and the WebSocket page for chamber target messages.
This reference was checked against main/main.cpp, main/web_request_policy.h, the controller/scaler/bed policy headers, and main/web/app.js in the firmware source. Examples use the documentation-only address 192.0.2.42; substitute your own HAT address. They were tested with fixtures, not by changing a live printer.