Forum Discussion
Create Wallboard from API REST calls
- 1 year ago
hello Darwood
I think you have done most of the hard work to get the authentication and connection done
Now for Web Activity Output Handling
• Use a Set Variable activity to capture the Web Activity response
• Configure the variable to store the complete JSON output
Create Copy Data Activity Setup
• Create a dummy source query using a Fabric Datawarehouse connection
• Use the “Additional Columns” section in the source to define your output schema
• Configure the destination as the Lakehouse Files section
• Map the fields from your variable to the destination columns
check this discussion it will be helpfulIf this helps. Please accept the solution
Thanks
hello Darwood
I think you have done most of the hard work to get the authentication and connection done
Now for Web Activity Output Handling
• Use a Set Variable activity to capture the Web Activity response
• Configure the variable to store the complete JSON output
Create Copy Data Activity Setup
• Create a dummy source query using a Fabric Datawarehouse connection
• Use the “Additional Columns” section in the source to define your output schema
• Configure the destination as the Lakehouse Files section
• Map the fields from your variable to the destination columns
check this discussion it will be helpful
If this helps. Please accept the solution
Thanks
- Darwood1 year agoFrequent Visitor
Thanks for the suggestion nilendraFabric
I am getting a data type error on the Set variable activity though when I try and run the Data Pipeline. I have tried using a string or array data type and I get the same sort of problem.
The settings for the Set variable activity are:
- Variable type: Pipeline variable
- Name: devicesJson
- Value: @activity('Devices').output (this is the name of the previous Web activity API call)
"The variable 'devicesJson' of type 'Array' cannot be initialized or updated with value of type 'Object'. The variable 'devicesJson' only supports values of types 'Array'."
- Darwood1 year agoFrequent Visitor
Ignore that last message. I didn't realise the output wrapped the result in a JSON object with a "response" property. I have updated the variable expression to
@json(activity('Devices').output.response) and the array variable seems to be correctly populated now. Still struggling to get the Additional Columns working in the Copy Data activity though... - Darwood1 year agoFrequent Visitor
ok so I'm almost there....
I have created a dummy query with additional columns and dynamic data and I can get the id value for the first record using a value of
@variables('devicesJson')[0].idHowever I want to bring across the values for every single record in the output. I can obviously change the 0 to a different number to get a particular record but I want them all. How would I do this please?