API and automation

VNISH API and automation guide

Use this guide to plan monitoring, scripting and farm data workflows around VNISH-managed Antminers without exposing credentials or changing tuning automatically too early.

API intentMonitoringAutomationFarm data
NeedUse API-style workflow whenUse VOU/UI when
MonitoringYou need repeated stats collectionYou need quick manual checks
AlertsYou want custom Telegram/Slack/NOC rulesBuilt-in alerts are enough
ReportingYou need fleet-level CSV/dashboard dataYou only manage a few miners
AutomationYou need scheduled actions by tariff or temperatureYou are still validating firmware stability

What to automate first

Start with read-only monitoring: hashrate, wattage, chip temperature, fan speed, pool status and error counters. Avoid automated tuning changes until you have stable baselines.

Safe integration pattern

Poll miners in small batches, store timestamps, keep credentials out of scripts and alert on trends rather than one noisy sample. Always leave manual recovery access.

API vs VOU

VOU is better for human-driven discovery and update batches. API-style integrations are better for dashboards, maintenance alerts and operations reporting.

Frequently asked questions

Does this page publish private API credentials?+

No. Never publish miner credentials or tokens in the site, scripts or public repos.

What should an API dashboard show first?+

Hashrate, efficiency, board temperatures, fan behavior, pool health, reject rate and last error state.

Can automation change tuning automatically?+

It can in some environments, but read-only monitoring is the safer first step. Automated tuning changes should be tested on a small pilot group.

Related VNISH guides

Continue through the model, install and recovery pages before flashing production miners.

Validate a read-only integration against one installed build

  1. Record the full firmware version, model and control board. Open the API documentation supplied with that build; do not assume an endpoint or authentication method from another release.
  2. Choose a documented read-only status operation. Keep credentials outside command history and source files; restrict access to the private management network.
  3. Check the HTTP result, response content type, timestamp and required fields. Missing readings must stay unknown, not become zero.
  4. Compare returned values with the device interface before using them for alerts. Handle authentication failures and rate limits without retrying indefinitely.

Consumer-side validation example

The Python example below reads a saved JSON response. Replace the required field names with the schema documented for your installed build. It makes no network request and does not change miner settings.

import json
from pathlib import Path

status = json.loads(Path("status-response.json").read_text(encoding="utf-8"))
if not isinstance(status, dict):
    raise ValueError("Expected a JSON object; check the documented response schema")
required_fields = []  # Fill from the documentation for your firmware build.
if not required_fields:
    raise ValueError("Configure required_fields before using this check")
missing = [name for name in required_fields if name not in status]
if missing:
    raise ValueError(f"Missing status fields: {missing}")
print("Required fields are present; validate units and timestamps separately")

This illustrates validation logic, not a tested API contract for every VNISH version. Continue with the control-board guide and management security checklist.

Documentation reviewed September 28, 2026. This is an independent operator guide; compatibility must be checked against the installed version. Source: project documentation.

Validate an integration against the installed build

Record the miner model, control board and full firmware version before selecting an API client. This guide does not publish a universal endpoint or authentication contract: these must come from documentation for that build.

  1. Start with one miner on a restricted management network and a read-only operation.
  2. Check the response timestamp, units and missing fields against the miner’s own interface.
  3. Apply timeouts and backoff after failures; retain the last observation time instead of displaying stale readings as live.
  4. Keep credentials outside source code and logs. Test any write action separately, with a documented recovery procedure.