Skip to main content
Version: 1.1beta1

admin.selectSignals

Require access to Admin namespace

For an integration to access this method, it must have been granted access to the Admin namespace in Clarify.

This method retrieves signal meta-data as well as items published from these signals.

Example

# BASIC_AUTH_USERNAME=<Username from Basic Auth credentials>
# BASIC_AUTH_PASSWORD=<Password from Basic Auth credentials>
# INTEGRATION_ID=${BASIC_AUTH_USERNAME}
curl --request POST \
--url 'https://api.clarify.io/v1/rpc' \
--header 'content-type: application/json' \
--header 'Authorization: Bearer <YOUR ACCESS TOKEN>' \
--header 'X-API-Version: 1.1' \
--data \
'
{
"jsonrpc": "2.0",
"method": "admin.selectSignal",
"id": 10,
"params": {
"integration": "'${INTEGRATION_ID}'",
"signals": {
"include": true,
"filter": {"name":{"$in": ["a", "b"]}},
"limit": 2
},
"items": {
"include": true
}
}
}
'

Method parameters

NameTypePropertiesDescription
integrationIntegration IDrequiredIntegration to show signals for.
signalsResource querydefault = {}Query which signals to select, and configure signal inclusion.
itemsItems querydefault = {}Configure item inclusion. By default, no meta-data is included.

Response result

type: object

Properties

NameTypePresenceDescription
signalsmap of Signal ID => Signal select viewWhen signals.include is trueSignals mapped by ID.
itemsmap of Item ID => Item select viewWhen data.include is trueItem meta-data mapped by ID.

Limits

Signals query:

  • signals.limit can maximum be 1000.

Schema references

Items query

NameTypePropertiesDescription
includebooleandefault={}Set to true to include items exposed by the selected signals.

Integration ID

Integration ID uniquely identities a integration resource entry.

type: string(regex: "^[a-v0-9]{20}$")

Item ID

Item ID uniquely identities a item resource entry.

type: string(regex: "^[a-v0-9]{20}$")

Item select view

The item select view lists all exposed item fields.

type: object

Properties

NameTypeDescription
idstring(regex: "^[a-v0-9]{20}$")
metaResource meta
annotationsmap of string(regex: "^[A-Za-z0-9-_/]{1,128}$") => stringArbitrary configuration parameters. Customer-provided annotations should use a relevant prefix, e.g. company-domain/application-name/.
namestringThe default signal display name.
typestring(numeric or enum)The default signal type.
descriptionstringThe default signal description
labelsmap of string(regex: "^[A-Za-z0-9-_/]{1,128}$") => array of stringThe default signal labels.
engUnitstringDefault signal display unit, used in numeric representations.
enumValuesmap of string(integer in range 0-9999) => stringDefault item enum values, used to replace numeric values with text in enumerated representations.
sourceTypestring("measurement" or "aggregation" or "prediction")Default item source type.
sampleIntervalnull or string(RFC 3339 duration)How often the signal is sampled (on average).
gapDetectionnull or string(RFC 3339 duration)The default item gap detection. A gap will be drawn whenever there is no data for a duration longer than the specified value.

Example

{
"name": "Ice Cream Temperature",
"type": "numeric",
"description": "Temperature measurement of the ice cream",
"labels": {
"flavours": ["sweet", "sour"],
"location": ["pier", "banana stand"]
},
"engUnit": "°C",
"sourceType": "measurement",
"sampleInterval": "PT1M",
"gapDetection": "PT5M"
}

Resource meta

type: object

Properties

NameTypeDescription
contentHashstringHash of "relevant" fields in the resource (better definition in expected next API version)
createdAtstring(RFC 3339 timestamp)When the resource was created.
updatedAtstring(RFC 3339 timestamp)When the resource was updated.

Resource query

Query a resource in Clarify.

type: object

Properties

NameTypePropertiesDescription
includebooleandefault = nullSet to true to include matched resources in the response.
filterResource filterdefault = {}Filter which resources to include.
limitintegerdefault = 10Number of resources to include in the result.
skipintegerdefault = 0Skip the first N items.

Signal ID

Signal ID uniquely identities a signal resource entry.

type: string(regex: "^[a-v0-9]{20}$")

Signal select view

The signal select view lists all exposed signal fields.

type: object

Properties

NameTypeDescription
idstring(regex: "^[a-v0-9]{20}$")
metaResource meta
annotationsmap of string(regex: "^[A-Za-z0-9-_/]{1,128}$") => stringArbitrary configuration parameters. Customer-provided annotations should use a relevant prefix, e.g. company-domain/application-name/.
namestringThe default signal display name.
typestring(numeric or enum)The default signal type.
descriptionstringThe default signal description
labelsmap of string(regex: "^[A-Za-z0-9-_/]{1,128}$") => array of stringThe default signal labels.
engUnitstringDefault signal display unit, used in numeric representations.
enumValuesmap of string(integer in range 0-9999) => stringDefault item enum values, used to replace numeric values with text in enumerated representations.
sourceTypestring("measurement" or "aggregation" or "prediction")Default item source type.
sampleIntervalnull or string(RFC 3339 duration)How often the signal is sampled (on average).
gapDetectionnull or string(RFC 3339 duration)The default item gap detection. A gap will be drawn whenever there is no data for a duration longer than the specified value.
itemItem IDThe default item gap detection. A gap will be drawn whenever there is no data for a duration longer than the specified value.

Example

{
"name": "Ice Cream Temperature",
"type": "numeric",
"description": "Temperature measurement of the ice cream",
"labels": {
"flavours": ["sweet", "sour"],
"location": ["pier", "banana stand"]
},
"engUnit": "°C",
"sourceType": "measurement",
"sampleInterval": "PT1M",
"gapDetection": "PT5M"
}