REST API Documentation
Base URL: https://api.node07.xyz • Format: application/json; charset=utf-8 • POST limit: 8 КБ • Rate limit: 15 req/s
/api/ping
Check internet connectivity and node uptime. Minimal payload size allows parsing without large RAM buffers.
$ curl -s https://api.node07.xyz/api/ping
{"status":"ok","message":"pong","node":"node07","uptime_sec":3600,"requests":42191}
| Field | Type | Description |
|---|---|---|
status | string | Node status (always "ok" during normal operation) |
message | string | Control response "pong" |
uptime_sec | int | Continuous server uptime in seconds |
/api/time
Fetch accurate time over HTTP/HTTPS to sync controller RTC clocks in networks where UDP port 123 (NTP) is blocked.
$ curl -s https://api.node07.xyz/api/time
{"unix":1794808000,"iso":"2026-11-16T05:46:40+00:00","utc":"2026-11-16 05:46:40"}
| Field | Type | Description |
|---|---|---|
unix | int | Seconds since January 1, 1970 (UTC) |
iso | string | Date and time in ISO-8601 format |
utc | string | Human-readable time string in UTC timezone |
/api/headers
Returns HTTP headers received by the server from the controller. Helps debug User-Agent, auth tokens, and proxies.
$ curl -s https://api.node07.xyz/api/headers
{"headers":{"host":"api.node07.xyz","user-agent":"ESP32HTTPClient"},"protocol":"HTTP/1.1"}
| Field | Type | Description |
|---|---|---|
headers | object | Dictionary of all incoming HTTP headers in lowercase |
protocol | string | Client HTTP protocol version |
/api/uuid
Generate a random unique UUID v4 identifier. Useful for assigning unique device IDs on boards without hardware RNG.
$ curl -s https://api.node07.xyz
{"uuid":"550e8400-e29b-41d4-a716-446655440000"}
| Field | Type | Description |
|---|---|---|
uuid | string | Random 128-bit identifier in UUID v4 format |
/api/echo
Echo endpoint to verify JSON telemetry payloads from firmware. Accepts up to 8192 bytes and echoes it back with a timestamp.
$ curl -s -X POST https://api.node07.xyz/api/echo -H "Content-Type: application/json" -d '{"temp":23.5}'
{"received":{"temp":23.5},"timestamp":1794808000}
| Field | Type | Description |
|---|---|---|
received | any | Parsed JSON object from request body (or raw) |
timestamp | int | Unix timestamp when the packet was received |
HTTP Response Codes
| Code | Status | Reason |
|---|---|---|
200 | OK | Request processed successfully |
400 | Bad Request | Invalid header Content-Length |
404 | Not Found | Unknown API route |
413 | Payload Too Large | POST request body exceeds 8 KB limit |
429 | Too Many Requests | Request rate limit exceeded (15 req/s) |
Negative Response Examples
For application-level errors, the API returns a JSON object with the error. When web server rate limiting (429) is triggered, a standard Nginx response is returned.
{"error": "not found"}
{"error": "payload too large"}
{"error": "bad length"}
<html><head><title>429 Too Many Requests</title></head>...