Hi,
I have datasources script in python which runs fine and also I can see the element also got created, but when I click on that element it shows that no visible data pages available.
in http://localhost:34567/swagger/index.html when test on api/parameters I see that I get "Sequence contains no element" what can be the reason?
Hi Apurva,
With DataAPI, an array symbolizes a table. If you have an array inside another array, we try to create a linked table with a foreign key relationship. This means that the "ServiceInvolved" property in your JSON would be a linked table, but because it does not have a key-value pair structure, it fails to resolve the parameter structure.
I did a quick local test and with your JSON I got the same error but if I adapt it not to include the "ServiceInvolved" property
{
"components": [{
"AlarmId": 3614501,
"ElementId": 290,
"ElementName": "Sky-News-TXCore",
"Severity": "Critical",
"ParameterDescription": "Memory Usage (Servers Info) sky-news-pi-ams",
"ParameterValue": "70.000000",
"StartTime": "/Date(1736263098000)/",
"ClusterName": "Contribution"
}, {
"AlarmId": 3614481,
"ElementId": 312,
"ElementName": "MUN-X20-FRM-003_1_2_4_19",
"Severity": "Critical",
"ParameterDescription": "Signal Loss (Decoder Services) 3/Auto First Service [239.202.1.4:5000] 3G-1BD",
"ParameterValue": "BLACK_FRAME",
"StartTime": "/Date(1736262135000)/",
"ClusterName": "Contribution"
}
] }
I get it to work with the following result
If you still want to keep the "ServiceInvolved" property I would suggest adapting the structure to be something more like
{
"components": [{
"AlarmId": 3614501,
"ElementId": 290,
"ElementName": "Sky-News-TXCore",
"Severity": "Critical",
"ParameterDescription": "Memory Usage (Servers Info) sky-news-pi-ams",
"ParameterValue": "70.000000",
"StartTime": "/Date(1736263098000)/",
"ServiceInvolved": "TX Core",
"ClusterName": "Contribution"
}, {
"AlarmId": 3614481,
"ElementId": 312,
"ElementName": "MUN-X20-FRM-003_1_2_4_19",
"Severity": "Critical",
"ParameterDescription": "Signal Loss (Decoder Services) 3/Auto First Service [239.202.1.4:5000] 3G-1BD",
"ParameterValue": "BLACK_FRAME",
"StartTime": "/Date(1736262135000)/",
"ServiceInvolved": "",
"ClusterName": "Contribution"
}
] }
And you would get something like