Page tree
Skip to end of metadata
Go to start of metadata

/api/reports/views/:id/table/indicators/:iid/conditions

This method returns the conditional formatting of a selected table indicator.

Resource Information

Resource URL

https://service.belladati.com/api/reports/views/:id/table/indicators/:iid/conditions

HTTP Method

GET

Request Parameters

Parameters

Detail

Example

id

ID of the table. This ID is part of the /api/reports/:id response.

123
iidID of the indicator. This ID is part of the /api/views/:id/table/indicators response.AVn6TNRofe

Response Structure

{ 
  "conditions" : [
	{
		 ...
	},
	{
		...
	}
  ]
 
}

JSON response contains array of conditions. Each contains multiple objects with following definition:

NameDescription
evaluationTypeType of conditional formatting (INDICATOR or FORMULA)
symbolSymbol of the conditional formatting (ARROW_UP, ARROW_DOWN, WARNING, etc. - see Types and enumerations)
compareValueCompare value
compareFormulaCompare formula (used when compareType=FORMULA_INDICATOR or evaluationType=FORMULA)
conditionUse conditions (EQ, BW, GTW, etc. - see Types and enumerations)
valueSecondary value, used for conditions BW, NOT_BW, GBY, LBY
compareTypeType of compare value (CONSTANT, PREV_VALUE, FORMULA_INDICATOR, INDICATOR)
colorColor of text
backgroundBackground color
indexOrder of the condition
descriptionDescription
cssClasscustom css class

Sample request/response

Using curl:

curl -H "Authorization: OAuth realm=\"https://service.belladati.com/\", oauth_consumer_key=\"myConsumer\", oauth_token=\"mh7an9dkrg59\", oauth_timestamp=\"135131231\", oauth_nonce=\"randomString\"" https://service.belladati.com/api/reports/views/1234/table/indicators/AVn6TNRofe/conditions

The JSON format response:

{
    "conditions": [
        {
            "evaluationType": "INDICATOR",
            "compareValue": 0,
            "condition": "GBY",
            "compareType": "CONSTANT",
            "color": "#1aff00",
            "background": "#e60e0e",
            "index": 0,
            "value": 2
        },
        {
            "evaluationType": "INDICATOR",
            "compareValue": 886076,
            "symbol": "ARROW_UP",
            "condition": "NOT_BW",
            "compareType": "CONSTANT",
            "color": "#17e6b5",
            "background": "#4f2bff",
            "index": 1,
            "value": 10000
        },
        {
            "evaluationType": "INDICATOR",
            "condition": "PGBY",
            "compareType": "PREV_VALUE",
            "color": "#547f4f",
            "index": 2,
            "description": "prev value",
            "value": 4
        },
        {
            "evaluationType": "INDICATOR",
            "condition": "GTE",
            "compareType": "FORMULA_INDICATOR",
            "compareFormula": "1000",
            "color": "#547f4f",
            "index": 3,
            "description": "ind formula"
        },
        {
            "evaluationType": "INDICATOR",
            "condition": "GTE",
            "compareType": "INDICATOR",
            "color": "#547f4f",
            "index": 4,
            "description": "indicator",
            "compareIndicator": "7as7FSMLAb"
        },
        {
            "evaluationType": "FORMULA",
            "condition": "GTE",
            "compareType": "CONSTANT",
            "compareFormula": "1000\t",
            "color": "#547f4f",
            "index": 5,
            "description": "formula"
        }
    ]
}

Next steps

  • No labels