The Bitaxe features the following endpoints:
GET
/api/system/infoGet system information/api/system/asicGet ASIC settings information/api/system/statisticsGet system statistics (data logging should be activated)/api/system/statistics/dashboardGet system statistics for dashboard/api/system/wifi/scanScan for available WiFi networks/api/themeGet current theme settings
POST
/api/system/restartRestart the system/api/system/identifyIdentify the device/api/system/OTAUpdate system firmware/api/system/OTAWWWUpdate AxeOS/api/themeUpdate theme settings
PATCH
/api/systemUpdate system settings
Examples
Section titled “Examples”GET
Get system information:
curl http://YOUR-BITAXE-IP/api/system/infoGet ASIC settings information:
curl http://YOUR-BITAXE-IP/api/system/asicGet system statistics (data logging should be activated):
curl http://YOUR-BITAXE-IP/api/system/statisticsYou can filter statistics by specific columns using the columns query parameter:
curl "http://YOUR-BITAXE-IP/api/system/statistics?columns=hashrate,hashrate_1m,hashrate_10m,hashrate_1h,asicTemp,vrTemp,power"Get dashboard statistics:
curl http://YOUR-BITAXE-IP/api/system/statistics/dashboardGet available WiFi networks:
curl http://YOUR-BITAXE-IP/api/system/wifi/scanGet current theme settings:
curl http://YOUR-BITAXE-IP/api/themePOST
Restart the system:
curl -X POST http://YOUR-BITAXE-IP/api/system/restartIdentify the device (let it say Hi!):
curl -X POST http://YOUR-BITAXE-IP/api/system/identifyUpdate system firmware:
curl -X POST \ -H "Content-Type: application/octet-stream" \ --data-binary "@esp-miner.bin" \ http://YOUR-BITAXE-IP/api/system/OTAUpdate AxeOS web interface:
curl -X POST \ -H "Content-Type: application/octet-stream" \ --data-binary "@www.bin" \ http://YOUR-BITAXE-IP/api/system/OTAWWWUpdate theme settings:
curl -X POST http://YOUR-BITAXE-IP/api/theme \ -H "Content-Type: application/json" \ -d '{"theme": "dark", "colors": {...}}'PATCH
The PATCH functionality allows you to change settings on the Bitaxe.
Some settings still require a restart but changing the fanspeed can be achieved live:
curl -X PATCH http://YOUR-BITAXE-IP/api/system \ -H "Content-Type: application/json" \ -d '{"fanspeed": 50}'Response
Section titled “Response”The file openapi.yaml contains response values for each API endpoint.
For example, general information about the Bitaxe can be collected using the /api/system/info, which provides the following data:
{ "power": 18.7522583, "voltage": 5093.75, "current": 12015.625, "temp": 60.125, "temp2": -1, "vrTemp": 62, "maxPower": 40, "nominalVoltage": 5, "hashRate": 1072.2407227, "hashRate_1m": 1088.9354248, "hashRate_10m": 1072.3271484, "hashRate_1h": 1071.8736572, "expectedHashrate": 1071, "errorPercentage": 0, "bestDiff": 49224525, "bestSessionDiff": 2038368, "poolDifficulty": 1000, "isUsingFallbackStratum": 1, "poolAddrFamily": 2, "isPSRAMAvailable": 1, "freeHeap": 8212708, "freeHeapInternal": 104027, "freeHeapSpiram": 8140652, "coreVoltage": 1150, "coreVoltageActual": 1144, "frequency": 525, "ssid": "HomeNET", "macAddr": "10:F5:12:33:BB:F0", "hostname": "bitaxe", "ipv4": "10.1.10.111", "ipv6": "FE80::F2F5:BDFF:FE44:B2F0", "wifiStatus": "Connected!", "wifiRSSI": -44, "apEnabled": 0, "sharesAccepted": 4768, "sharesRejected": 13, "sharesRejectedReasons": [{ "message": "Stale", "count": 13 }], "uptimeSeconds": 18574, "smallCoreCount": 2040, "ASICModel": "BM1370", "stratumURL": "public-pool.io", "stratumPort": 21496, "stratumUser": "bc1qnp980s5fpp8l94p5cvttmtdqy8rvrq74qly2yrfmzkdsntqzlc5qkc4rkq.bitaxe", "stratumSuggestedDifficulty": 1000, "stratumExtranonceSubscribe": 0, "fallbackStratumURL": "solo.ckpool.org", "fallbackStratumPort": 3333, "fallbackStratumUser": "bc1qnp980s5fpp8l94p5cvttmtdqy8rvrq74qly2yrfmzkdsntqzlc5qkc4rkq.bitaxe", "fallbackStratumSuggestedDifficulty": 1000, "fallbackStratumExtranonceSubscribe": 0, "responseTime": 188.482, "version": "v2.12.2", "axeOSVersion": "v2.12.2", "idfVersion": "v5.5.1", "boardVersion": "601", "resetReason": "Software reset via esp_restart", "runningPartition": "factory", "overheat_mode": 0, "overclockEnabled": 0, "display": "SSD1306 (128x32)", "rotation": 0, "invertscreen": 0, "displayTimeout": -1, "autofanspeed": 1, "fanspeed": 48.4200668, "manualFanSpeed": 100, "minFanSpeed": 25, "temptarget": 60, "fanrpm": 3915, "fan2rpm": 0, "statsFrequency": 0, "blockFound": 0, "blockHeight": 931409, "scriptsig": "...._i.F.W...ckpool./solo.ckpool.org/", "networkDifficulty": 146472570619930, "hashrateMonitor": { "asics": [{ "total": 1072.2407227, "domains": [273.5812073, 276.209198, 268.4890747, 252.1910095], "errorCount": 1415 }] }}