What this tool does
The HTTP Data Plotter draws numbers out of HTTP requests sent to
https://services.iperfect.net/APIEndpoint/write.php onto a live
time-series chart. It is the HTTP twin of the MQTT, UDP and TCP Data
Plotters: same chart, same console, same
configuration — only the transport differs. It does not know anything
about your payload format; you tell it how to pull the numbers out, using one
regular expression and one short line of JavaScript per line on the chart.
temp:23.5;hum:40), press Split › on it and choose another separator; repeat as deep as needed. It reads values by position (comma/pipe
separated, or any custom separator you type), by JSON key, or as the number after a piece of text such as
temp=, with optional multiply/add for unit conversion. Set Value format to Hex → decimal (e.g. 1F = 31) or Hex signed (e.g. FFF6 = −10) for hex readings — hex values are picked automatically when you click them.
The RegEx guide below applies to the Advanced tab.
The endpoint writes every request into a journal on the server; this page
talks to ajax/http_endpoint.php on iperfect.net, which reads
that journal. That is the same path the
HTTP Endpoint tab uses.
Before you start
- Send to https://services.iperfect.net/APIEndpoint/write.php. Any method works; no key, headers or registration are needed.
- One request is one reading. The plotter reads the request
body. A request with an empty body is read by its
query string instead, so
GET write.php?temp=21.5&hum=40plots astemp=21.5&hum=40. - Your payload has to be text — plain text, CSV, JSON or form data. Binary bytes are shown as dots in the console and cannot be matched by a regular expression.
- Only the first 8 KB of a body is stored; a longer one is truncated and the console says so.
- HTTP is acknowledged: a
200reply means the request was recorded, so unlike UDP nothing is silently lost on the way. - Use a current Chrome, Edge or Firefox. The page only reads — it never sends anything back to your device.
Send data from your code
Any server, script, browser or device can POST to the endpoint and the
plotter will draw it. Pick your language, set the message, and press
Copy. Each snippet is a ready-to-use sendToIperfect(payload)
function plus one example call — almost none of them needs an extra library.
For a steady test stream from a shell:
while true; do
curl -s -H 'Content-Type: text/plain' \
--data-binary "node1,2340,17,$RANDOM.0,$RANDOM.0,$RANDOM.0" \
https://services.iperfect.net/APIEndpoint/write.php > /dev/null
sleep 1
done
<source ip> <METHOD> → <your text> for
every request that arrives — that is your proof the path works,
before any parsing is involved.
Quick start
- Start monitoring. The POST / GET URL is fixed; press Start Monitoring. The status pill turns green and reads Monitoring.
-
Read one request. Send something (see
section 3) and copy one line out of the
Incoming HTTP Requests console. Everything after the arrow is
what your expressions will see as
data. - Name your lines. In Axis Configuration set X-Axis data types to plot to how many lines you want, press Apply, then type a name into each row.
- Write the expressions. In RegEx Configuration set Expressions to plot to one + one per line and press Apply. Row 1 splits the payload (tick Is RegEx); the rest plot (leave it unticked).
- Save Configuration. The page reloads with your settings, so press Start Monitoring again. Points appear as requests arrive.
How parsing works
Every row in RegEx Configuration runs once per request, top to bottom. The Is RegEx tick is what decides how it runs:
| Is RegEx | What the row does |
|---|---|
| Ticked | The text is treated as a regular expression. The plotter
matches it against the request body and stores every match in
the regEx array. It draws nothing by itself. |
| Unticked | The text is treated as a line of JavaScript and executed
as written. This is where you call addPoint(). |
What you can use inside a row
| Name | Meaning |
|---|---|
data |
The body of the request that just arrived (or its query string when the body is empty). |
pkt |
The whole request record — pkt.from (sender IP),
pkt.method, pkt.query (query string),
pkt.ctype (Content-Type), pkt.ua
(User-Agent), pkt.len (body bytes),
pkt.hex, pkt.seq, pkt.time
(server clock). This one has no counterpart on the MQTT
plotter. |
regEx |
The array produced by your Is RegEx row. Counts from zero. |
dt |
The time the request was picked up, in milliseconds. Use it as the x-value of every point. |
highcharts |
The chart. highcharts.series[0] is your first named
line, [1] the second, and so on. |
dt is the moment the browser read the request, not
the moment it landed. With a 1000 ms poll, several requests from the
same poll share almost the same x-value. Lower the poll interval for
finer spacing, or plot
Date.parse(pkt.time.replace(" ","T")) to use the server's
arrival stamp instead.
Counting the index
/([^|,]+)/g means “every run of characters that is not a
comma or a pipe” — in other words, every field. Suppose a
request body reads:
Zone,2340,e1:0b:6f:40:82:fb,17,1.42,-0.87,9.61|ok
Splitting it gives these positions:
So the three numbers you want are regEx[4],
regEx[5] and regEx[6]. Do this with a request
copied from your own console — the layout above is only an
illustration of the counting.
Four rules worth remembering
- Put the Is RegEx row first. Rows run in order, so the array has to be filled before anything reads from it.
- Use only one Is RegEx row. A second one replaces the first one's result.
- End each addPoint with
,false. That skips a redraw per point; the chart redraws once after all rows have run, which keeps it smooth when a poll brings in a burst of requests. - Multiply by
1. Matches come out as text.(regEx[4])*1turns"1.42"into the number1.42. Without it the point plots as zero or not at all.
Worked example — three accelerometer axes
This is a complete, working configuration that plots AccelX, AccelY and AccelZ from a node sending the payload shown above. Copy it field for field.
| Field | Value |
|---|---|
| POST / GET URL | https://services.iperfect.net/APIEndpoint/write.php — fixed |
| Poll Interval | 1000 ms |
| Source Filter | left empty — plot every sender |
| X-Axis data types | 3 → named AccelX,
AccelY, AccelZ |
| Expressions to plot | 4 — one to split, three to plot |
| Expression 1 Is RegEx ticked | /([^|,]+)/g |
| Expression 2 | highcharts.series[0].addPoint([dt,(regEx[4])*1],false) |
| Expression 3 | highcharts.series[1].addPoint([dt,(regEx[5])*1],false) |
| Expression 4 | highcharts.series[2].addPoint([dt,(regEx[6])*1],false) |
Read it as: row 1 chops the payload into fields; rows 2–4 take fields 5, 6 and 7 and push them onto the first, second and third line of the chart, stamped with the arrival time.
Field reference
Top bar
| Control | What it does |
|---|---|
| Status pill | Not Monitoring · Starting · Monitoring · Error. The dot pulses while the poll loop is running. |
| Start Monitoring | Begins polling for new requests, from the next one onwards. |
| Stop | Stops polling. The chart keeps whatever it has drawn. |
| Help | Opens this guide. |
| HTTP Endpoint | Opens the raw monitor tab on iperfect.net in a new tab — see section 10. |
Connection strip
| Field | What it does |
|---|---|
| POST / GET URL | Fixed at https://services.iperfect.net/APIEndpoint/write.php,
the public endpoint the HTTP Endpoint tab uses. Click it to select
and copy. |
| Poll Interval (ms) | How often the page asks for new requests: 250–10000 ms, default 1000. Changing it while monitoring takes effect at once, no restart needed. Lower means finer x-spacing and more requests. |
| Source Filter | Optional. Only requests whose sender IP starts with this
text are logged and plotted — 192.168. for a
subnet, a full address for one device. Everything else is
ignored, not queued. |
Chart and console
| Control | What it does |
|---|---|
| 1M / 5M / All | Range selector. 1M keeps the last minute in view, which is usually what you want while watching live data. |
| Legend | Click a name to hide or show that line. |
| ☰ menu | Export as PNG, SVG or PDF, and View data table / download CSV of everything plotted so far. |
| Request console | Shows sender METHOD → text for each request,
plus start/stop notes. Holds the last 500 lines. |
| pkt counter | Requests accepted since the page loaded. System notes are not counted; filtered-out requests are not counted either. |
| Autoscroll / Clear | Follow the newest line, or empty the console. Clearing does not touch the chart. |
Configuration
| Field | What it does |
|---|---|
| X-Axis data types to plot | How many lines the chart has. Apply redraws the name rows below. |
| Series name | The label in the legend. The row's grey tag tells you which
highcharts.series[i] it is. |
| Visible Series | Tick boxes that hide or show a line without deleting its data. |
| Expressions to plot | How many expression rows. Apply redraws them. |
| Is RegEx | Ticked = match and fill regEx; unticked = run as
JavaScript. |
| Save Configuration | Stores everything in the page URL and reloads. Nothing you type takes effect until you press it. |
| Dump Parsed Data to Console | A stub kept for parity with the MQTT plotter; it does nothing on
its own. To inspect a parse, open the browser console (F12) and
read regEx after a request has arrived. |
Expression cookbook
Copy a row, change the index, done.
Splitting rows — tick Is RegEx
| Expression | Splits on |
|---|---|
/([^|,]+)/g |
commas and pipes — a,b|c |
/([^,]+)/g |
commas only — a,b,c |
/([^\s]+)/g |
spaces — a b c |
/(-?\d+\.?\d*)/g |
every number, ignoring all labels and separators |
/"(?:temp|hum)":(-?\d+\.?\d*)/g |
two named values out of JSON |
Plotting rows — leave Is RegEx unticked
| Expression | What it plots |
|---|---|
highcharts.series[0].addPoint([dt,(regEx[4])*1],false) |
field 5 onto the first line |
highcharts.series[0].addPoint([dt,parseFloat(data.split("temp=")[1])],false) |
a value straight out of key=value text, no split
row needed |
highcharts.series[0].addPoint([dt,pkt.len],false) |
body size in bytes — a cheap traffic graph |
highcharts.series[0].addPoint([dt,JSON.parse(data).temp],false) |
a field of a JSON payload |
highcharts.series[0].addPoint([dt,new URLSearchParams(data).get("temp")*1],false) |
a value from form data or a GET query string such as
temp=21.5&hum=40 |
if(pkt.from=="192.168.1.50"){highcharts.series[0].addPoint([dt,(regEx[4])*1],false)} |
one device onto one line, when several send the same format |
highcharts.series[0].addPoint([Date.parse(pkt.time.replace(" ","T")),(regEx[4])*1],false) |
the same value, stamped with the server's arrival time instead of the poll time |
Troubleshooting
| What you see | Why | Fix |
|---|---|---|
| Status goes to Error with a red bar | The monitor endpoint answered with a problem, or could not be reached | The bar carries the server's own message. Reload; if it persists the endpoint journal cannot be read on the server |
| Monitoring but the console stays empty | Nothing is reaching the endpoint | Send a test request (section 3). If that shows up, your device is the problem — check the URL (https, full path) and the HTTP status it gets back |
| Test request arrives, the device's does not | TLS failure on the device, or a redirect it does not follow | On ESP32 use WiFiClientSecure with
setInsecure() as in the snippet; print the status code
the device receives |
| (empty body, no query string) in the console | The request carried no data | Send the reading as the body, or as ?key=value on
the URL |
| Only some requests appear | A Source Filter that does not match | Clear the filter first. Remember the filter is a prefix match on the sender IP |
| older request(s) skipped in the console | More requests arrived between two polls than one poll returns (200), or the journal was trimmed | Lower the poll interval, or send less often |
| Console fills but the chart stays flat | Your regEx[…] indices point at the wrong
fields |
Recount from a real request; open the browser console and read
regEx |
| Lines plot as 0 | The field is text, not a number | Add *1, and check you are not pointing at a label |
| Points arrive in steps, not smoothly | Everything in one poll shares nearly the same dt |
Lower the poll interval, or stamp with
pkt.time (see the cookbook) |
| Console shows dots where text should be | The payload is binary | Send text. pkt.hex is available if you must work
with raw bytes |
| Chart shows one point at 05:30 | The placeholder point every new line starts with | Normal. It disappears from view once real data arrives; use 1M or 5M |
| Edits appear to do nothing | Save Configuration was not pressed | Press it — the page reloads with the new settings, then start again |
| Chart area shows a red “library unavailable” box | Highcharts could not be downloaded | Check internet access to code.highcharts.com or
cdn.jsdelivr.net |
| It slows down after a long run | Every point is kept in memory | Reload the page to start a fresh capture |
Plotter vs. HTTP Endpoint
Both read the same request journal through the same bridge. They differ in what they do with what arrives.
| HTTP Data Plotter | HTTP Endpoint tab | |
|---|---|---|
| Shows | A chart, plus a text console | A terminal: text, hex, or both |
| History | Skipped — starts from the next request | Shows the journal's stored requests when you start |
| Good for | Watching a value move over time | Seeing exactly what a device sent, byte for byte |
| Extras | Series, expressions, CSV/PNG export | Hex dump, Content-Type / User-Agent, request/byte counters, save log, clear journal, send a test request |
A useful pairing: open the monitor first to see the raw shape of a request, copy one line out of it, then come here and write the expressions against it.