Integrations & Setup
...
REST-API
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 example #1 { "siteid" "$ meta siteid", "sensor" "$ records\[0] fields sensor id" } example #2 { "station" "$ data\[ ] station", "line" "$ data\[ ] line" } 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