IT-NetCOM API
With an API key your systems (business software, spreadsheet, program) read the data of your devices, download their history and, if you wish, send commands. This page tells you everything you need to get started.
Getting started
- Sign in to IT-NetCOM as administrator and open “API keys”.
- Create a key: choose a name, what it can do and, if you wish, an expiry. Copy it at once: it is shown only once.
- Call the API at this address, with the key in the header of every request:
https://api.netcom.italyadsl.net/api/v1
Authentication
Every request carries the key in the Authorization header. Without a key, or with a revoked or expired one, the answer is 401. A key sees only the devices of your account.
Authorization: Bearer itn_…
- Read only: devices, measurements, history and alarms.
- Read and commands: also commands, cancelling commands and acknowledging alarms. To drive a relay the key must also be allowed on the page of that device.
Formats
- Requests and answers in JSON (UTF-8), except the CSV export.
- Times in ISO 8601. Answers are in UTC (they end with Z); in the start and end parameters always give the time zone, for instance 2026-11-01T00:00:00Z.
- Devices, alarms and commands are identified by UUIDs: you find them in the lists.
- Lists come in pages: limit says how many items, offset where to start, total how many there are.
- Every measurement has a quality: ok for valid values; the others stay in the history but do not enter the summaries.
- The CSV uses the semicolon as separator, with the columns time_utc, the readable time, value, quality, increment and counter_reset.
Limits
- The requests a minute per key depend on the profile of your account: at most 120 with the Free profile. Beyond that the answer is 429 with the Retry-After header: the seconds to wait.
- The history downloads in pages of up to 10,000 measurements per request, or all at once as CSV.
- Commands sent with a key count in the same daily quota of the device, if the profile has one; beyond the quota the answer is 429 with the code command_quota.
- How many keys can be active depends on the profile of your account (Free: one).
- The body of a request cannot exceed 1 MB.
Errors
| Code | What it means |
|---|---|
| 401 | Key missing, unknown, revoked or expired. |
| 403 | The key cannot do this: it is read only, or the relay is not allowed for it. |
| 404 | Path not available with a key, or a device, alarm or command that does not exist or is not yours. |
| 409 | The command has already left and cannot be cancelled, the alarm is not waiting for acknowledgement, or the command asks for a second confirmation. |
| 413 | Request body over 1 MB. |
| 422 | Missing or invalid parameters: the answer says which. |
| 429 | Too many requests a minute, or daily command quota used up. Retry-After says when to try again. |
Paths
Every path starts from https://api.netcom.italyadsl.net/api/v1. Any other path answers 404, whatever the key.
Devices
/devicesYour devices, with state, last contact, battery, open alarms and position.
site_id— only the devices of one sitelimit— how many items per page (default: 50)offset— which item to start from (default: 0)
/devices/{id}One device: the quantities it measures, the latest values (with the name of each quantity to use for the history), radio data.
/sitesThe sites the devices are grouped in.
/customersYour account, with its identifier.
/device-typesThe device types of the catalogue, with the quantities they declare.
Measurements and history
/devices/{id}/measurementsThe history of a quantity between two instants, in pages: for each measurement time, value, quality and, for counters, increment and reset.
quantityrequired — name of the quantity, as in last_values of /devices/{id}startrequired — start of the interval, ISO 8601 with time zoneendrequired — end of the interval, ISO 8601 with time zonelimit— how many items per page (default: 1000)offset— which item to start from (default: 0)
/devices/{id}/measurements.csvThe same history as a CSV file, all at once.
quantityrequired — name of the quantity, as in last_values of /devices/{id}startrequired — start of the interval, ISO 8601 with time zoneendrequired — end of the interval, ISO 8601 with time zone
/devices/{id}/aggregatesAverage, minimum, maximum, sum and count of measurements per hour or per day.
quantityrequired — name of the quantity, as in last_values of /devices/{id}startrequired — start of the interval, ISO 8601 with time zoneendrequired — end of the interval, ISO 8601 with time zoneperiod— hour or day (default: hour)tz— time zone in which to count the days, for instance Europe/Rome
/devices/{id}/radioSignal, signal-to-noise ratio and gateway of every message received.
startrequired — start of the interval, ISO 8601 with time zoneendrequired — end of the interval, ISO 8601 with time zonelimit— how many items per page (default: 1000)
/devices/{id}/thresholdsThe alarm thresholds that concern the device.
Alarms
/alarmsThe alarms, open or all, in pages.
state— open (only open ones) or all (default: open)device_id— only the alarms of one devicelimit— how many items per page (default: 50)offset— which item to start from (default: 0)
/alarms/summaryHow many alarms are open, by severity, and how many are waiting to be acknowledged.
/alarms/{id}/acknowledgeneeds “Read and commands”Acknowledges an open alarm.
Commands
/devices/{id}/command-typesThe commands the device accepts, with their parameters.
/devices/{id}/commandsneeds “Read and commands”Sends a command. Body: {"kind": "<command>", "params": {…}}. Answer 201 with the command and its state.
/devices/{id}/commandsThe commands sent to the device, the latest first.
limit— how many items per page (default: 50)offset— which item to start from (default: 0)
/commandsAll the commands sent to your devices.
limit— how many items per page (default: 50)offset— which item to start from (default: 0)
/commands/{id}One command with all its state changes.
/commands/{id}/cancelneeds “Read and commands”Cancels a command that has not left yet.
Service
/healthAnswers {"status": "ok"} when the service is running.
A command goes through created, queued (waiting at the gateway), transmitted, received (by the device) and verified (effect confirmed by the device); it ends in verified, failed, expired or cancelled. A device runs one command at a time.
Examples
The list of your devices:
curl -H "Authorization: Bearer itn_…" \ https://api.netcom.italyadsl.net/api/v1/devices
One device, with the names of the quantities in last_values:
curl -H "Authorization: Bearer itn_…" \ https://api.netcom.italyadsl.net/api/v1/devices/<id>
The November history of a quantity, as a CSV file:
curl -H "Authorization: Bearer itn_…" -o storico.csv \ "https://api.netcom.italyadsl.net/api/v1/devices/<id>/measurements.csv?quantity=<quantity>&start=2026-11-01T00:00:00Z&end=2026-12-01T00:00:00Z"
The same history in Python, in pages of 10,000 measurements:
import requests
API = "https://api.netcom.italyadsl.net/api/v1"
HEADERS = {"Authorization": "Bearer itn_…"}
device = requests.get(f"{API}/devices", headers=HEADERS).json()["items"][0]
detail = requests.get(f"{API}/devices/{device['id']}", headers=HEADERS).json()
quantity = detail["last_values"][0]["quantity"]
items, offset = [], 0
while True:
page = requests.get(f"{API}/devices/{device['id']}/measurements", headers=HEADERS, params={
"quantity": quantity, "start": "2026-11-01T00:00:00Z", "end": "2026-12-01T00:00:00Z",
"limit": 10000, "offset": offset}).json()
items += page["items"]
offset += len(page["items"])
if not page["items"] or offset >= page["total"]:
break
print(device["name"], quantity, len(items))
Switching relay 1 on (a “Read and commands” key allowed on the device):
curl -X POST -H "Authorization: Bearer itn_…" -H "Content-Type: application/json" \
-d '{"kind": "relay_set", "params": {"relay": 1, "state": 1}}' \
https://api.netcom.italyadsl.net/api/v1/devices/<id>/commands
Updated on 18 November 2026