API DocsRESTCalculated channel service

BatchResolveCalculatedChannel

Resolve a batch of calculated channels into expressions with references

POST
/api/v2/calculated-channels/resolve:batch

Request Body

application/jsonRequired

The request of a call to CalculatedChannelService_BatchResolveCalculatedChannels.

requests
Required
array<object>

All calculated channels to resolve.

curl -X POST "<API_URL>/api/v2/calculated-channels/resolve:batch" \
  -H "Authorization: Bearer <API_KEY>" \
  -H "Content-Type: application/json" \
  -d '{
    "requests": [
      {
        "calculatedChannelId": {
          "id": "string",
          "clientKey": "string"
        },
        "calculatedChannelConfiguration": {
          "assetConfiguration": {
            "allAssets": true,
            "selection": {
              "assetIds": [
                "string"
              ],
              "tagIds": [
                "string"
              ]
            }
          },
          "queryConfiguration": {
            "sel": {
              "expression": "string",
              "expressionChannelReferences": [
                {
                  "channelReference": "string",
                  "channelIdentifier": "string"
                }
              ]
            }
          }
        },
        "organizationId": "string",
        "assets": {
          "ids": {
            "ids": [
              "string"
            ]
          },
          "names": {
            "names": [
              "string"
            ]
          }
        },
        "run": {
          "id": "string",
          "clientKey": "string"
        }
      }
    ]
  }'

A successful response.

{
  "responses": [
    {
      "calculatedChannelId": {
        "id": "string",
        "clientKey": "string"
      },
      "resolved": [
        {
          "assetName": "string",
          "expressionRequest": {
            "channelReferences": {
              "property1": "string",
              "property2": "string"
            },
            "expression": "string",
            "expressionChannelReferences": [
              {
                "channelReference": "string",
                "channelId": "string"
              }
            ]
          },
          "outputDataType": "CHANNEL_DATA_TYPE_UNSPECIFIED"
        }
      ],
      "unresolved": [
        {
          "assetName": "string",
          "errorMessage": "string"
        }
      ]
    }
  ]
}