Hi,
I'm trying to create a PowerShell script that can export and import all tasks in an environment using Qlik-Cli. I'm using the Import-QlikObject function, but I get the following error:
Invoke-RestMethod : The remote server returned an error: (400) Bad Request.
The code I'm currently using is:
Connect-Qlik -ComputerName $env:COMPUTERNAME -UseDefaultCredentials -TrustAllCerts
Get-QlikTask -full -raw | ConvertTo-Json | Out-File "tasks.json"
$Tasks = Get-Content -raw "tasks.json" | ConvertFrom-Json | Import-QlikObject
Am I doing something wrong? Is there a different and better way to export and import tasks?
Thanks.