Certain values used in the REST API can be quite lengthy or overly complicated to use multiple times in an API call. Sisense provides several types of Configuration parameters that you can use to refer to values.
For example, if you have previously used an access_token through Oauth2 authentication, Sisense stores this value in memory and allows you to recall this value by referring to it as [@access_token].
There are three types of configuration parameters:
In Memory Parameters: These parameters are saved by Sisense In Memory and can be referred in later REST API calls.
Configuration Reference Parameters: These parameters refer to other parameters used in the configuration JSON file.
In Memory parameters are saved in Sisense memory and can be referenced for future API calls by adding the prefix [@parameter_name] as the value of the parameter. Sisense currently supports the following In Memory parameters:
[@accesstoken]: Reference to the credential parameter "access_token" returned as a result of Oauth2 authentication.
[@today]: Current date formatted as "yyyy-MM-dd". This In memory parameter can be used with the Days parameter, for example, [@today-1] means yesterday, [@today+30] means the current date plus 30 days ,etc.
[@now]: Current time. This parameter can also be modified, for example, [@now - 60] means a minute ago, [@now + 3600] is an hour(3600 seconds) ahead, etc.
[@accumulative] Reference to the AccumulativeSettings object. This object determines where an accumulative builds starts. This reference must be included in each table you want support accumulative builds. For more information, see AccumulativeSettings.
Configuration Reference parameters refer to the values of parameters listed in your configuration JSON file.
For example, the shortcut [@Settings.Provider] refers to the value you defined as the value of Provider in the Settings object.
Result Reference parameters refer to data returned after execution in JSON format as a JSON Document. Usually this document contains the results with the data requested represented as a JSON Array and some additional metadata needed for determining if there is more data, or some parameters for the next page.
For example, the Result Reference parameters can refer to:
All of the executed data: [@Tables.ActionName.@.]
Some data taken from the enitre returned document: [@Tables.Comment.@.next_page]
All requested data results as a JSON Array, not transformed with no metadata included: [@Tables.Comment.@.~]
All returned records as a single JSON Array with documents already transformed: [@Table.Comment.@.Doc.All]
Some value from a transformed document taken by path: [@Table.Comment.@.Doc.via.channel]
In the example below, the data is represented as a "comments" field in the JSON Document with additional fields like "next_page" and some metadata. As "comments" is an array, it can have many records in which each of them is another JSON Document. Sisense can transform these documents' structure. There are options to reference these transformed documents or to return the Action execution results as a single document with only the relevant fields.
The example below can be the result of Credentials.Auth Action execution. This kind of Action is executed only once and all results are cached.