Skip to main content
Technical Preview

Overview

Clarify by Searis is a cloud time-series tool where operators and engineers explore and annotate industrial data together. This connector lets the broker push readings from the unified namespace straight into Clarify signals and read rolled-up or calculated data back onto MQTT, without a separate collector. The template has one client connector, ClarifyApi (ClarifyRestApi.lot) on https://api.clarify.io, with 8 events: the OAuth 2.0 token call, 3 writes and 4 reads. Nothing is deleted.
Clarify is a JSON-RPC 2.0 API, not a classic REST API. Every method is a POST to /v1/rpc with the method name in the body, and the X-API-Version: 1.1 header selects the API version. Each event in this template sends the payload field request (the full JSON-RPC object) unchanged, so put the method that matches the topic in it. The events follow the public Clarify API reference 1.1.

Events

Replies arrive on the same topic with /response appended.

Authentication

Credentials of an integration can write data into Clarify, and with the admin or clarify namespace granted they can read organisation-wide data. Keep the client secret and passwords in Hub secrets with GET SECRET, keep the access token on an internal topic, and grant the integration only the namespaces it needs.
Create an integration in Clarify under Admin panel, then Integrations, and create credentials on its Access control tab. Clarify offers two kinds:
  • OAuth 2.0 client credentials (recommended): publish client_id and client_secret from clarify-credentials.json to historian/clarify/token/get. The reply carries access_token, valid for about 24 hours (expires_in 86400). Send it as Bearer <access_token>. Token calls are rate limited, so reuse the token until it expires.
  • Basic Auth: send Basic <base64 of username:password>. The user name is also the integration ID.
Every /v1/rpc event sends the payload field authorization as the Authorization header.

Namespaces

integration.insert and integration.saveSignals work for every integration and only touch its own signals. admin.selectSignals and admin.publishSignals need the admin namespace, and clarify.selectItems, clarify.dataFrame and clarify.evaluate need the clarify namespace. Grant them on the integration in the Clarify admin panel.

Payload conventions

  • request is the JSON-RPC 2.0 object: jsonrpc "2.0", method, id and params. Set id (for example "1") to get a reply; without it Clarify treats the call as a notification and answers 204 with no body.
  • integration in params is the integration ID from the credentials file.
  • InsertData takes a data frame: times is a list of RFC 3339 timestamps and series maps each signal input key to a list of values of the same length (null for gaps). An unknown input key creates a new signal.
  • Resource queries (query) use Clarify’s filter syntax, for example {"labels.line": {"$in": ["line1"]}}, plus limit, skip and total.
  • Data queries (data) take filter.times with $gte / $lt and an ISO 8601 rollup such as PT1H or P1D.
Insert two readings:
Hourly rollup for the last day:
Clarify answers HTTP 200 for JSON-RPC errors such as invalid params (-32602), forbidden (-32003, often a namespace that is not granted) or too many requests (-32011). Always check for an error object in the /response payload, not only the HTTP status.

Limits

Clarify rate-limits each method: integration.insert, integration.saveSignals, clarify.dataFrame and clarify.evaluate allow 1 request per second, admin.publishSignals 5, and admin.selectSignals and clarify.selectItems 10. Requests are capped at about 8 MiB of JSON. Signals should average no more than one sample per minute (bursts up to one per second), so batch several readings into one InsertData call. clarify.dataFrame and clarify.evaluate read at most 50 items per call, and raw data (no rollup) is limited to a 40-day window.

Connector

Example actions

These actions refresh the token twice a day, keep it on an internal topic, push a press pressure reading into Clarify, and request an hourly rollup.

Status

Technical preview, blocked. The template passes 73 smoke checks: static checks of the connector, every event against a local mock of the Clarify JSON-RPC API built from the public reference, negative controls, and three unauthenticated calls to the real api.clarify.io that confirm the token endpoint and the RPC endpoint reject invalid credentials. No call has run yet with real Clarify credentials. To finish testing, create an integration with OAuth client credentials, set CLARIFY_CLIENT_ID, CLARIFY_CLIENT_SECRET and CLARIFY_INTEGRATION_ID, run python3 smoke_clarify.py with CLARIFY_ALLOW_WRITE=1 (and CLARIFY_READ=1 and CLARIFY_ADMIN=1 if those namespaces are granted), then deploy the connector on a broker and do an MQTT round trip.
Last modified on October 21, 2026