Adding measurements to a REST API collector
Define what to extract from the API response and how to write it to Historian. A measurement maps value(s), timestamp(s), optional status, and tags from the JSON payload. Use JSONPath to point to the right fields, try: jsonpath.com.
MeasurementPath
The json path that leads to a value, or a list of values in the message. Default: $.Value
Examples
TimestampPath
The json path that leads to a timestamp, or a list of timestamps in the message Default: $.time
Examples
Make sure your timestamps match the configured TimestampLayout (RFC3339 or UNIX*). If the API uses epoch millis, set TimestampLayout = "UNIXMILLIS" (either at collector or measurement level).
StatusPath (optional)
The json path that leads to a status, or a list of statuses in the message. If not set, status will default to Good
Examples
TagNamesAndTagValuePaths (optional)
Map of tag name → JSONPath to enrich points with context (site, line, sensor, batch, …).
Examples
{ "siteId": "$.meta.siteId", "sensor": "$.records[0].fields.sensor_id" }A single-value tag applies to all points in the batch. If you provide tag lists, their length should match the number of values.
TimestampLayout (override)
Optional per-measurement override of the parsing layout. Use when a specific measurement’s timestamps differ from the collector default.
Examples
URL / QueryParameters / Body / Method / Headers (overrides)
Optional per-measurement overrides. Unset fields fall back to the collector settings.
Use cases
- Point a subset of measurements to a different endpoint path.
- Add a small extra filter (e.g., tag=temperature) for this measurement only.
- Switch a measurement from GET to POST when it needs a complex body.
Keep overrides minimal: each unique combination (URL/Method/Headers/QueryParameters/Body) can create an additional API call path.
Interval / IntervalOffset (overrides)
Per-measurement polling cadence and alignment. Use to slow down non-critical reads or to stagger calls across seconds.
Examples
CollectionType
Defines when values are written.
- polled (default): fetch each interval and write every response.
- monitored: fetch each interval but write only when the value changes.
Guidance
- Use polled for numeric time series that change frequently.
- Use monitored for states/booleans/strings (e.g., valve open/closed) to reduce noise.
Expected outcome
- Measurement appears in the list.
- Status changes to Good within ~10 seconds.
- Data preview shows live values.