Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in NYC Sept 4th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Inderpreet
Contributor
Contributor

How to extract QSense app into a JSON file without Data

Hi

We are a data governance project and one of the requirements is to extract the metadata from QSense reports. Our in house extractor requires the input to be in the form of a JSON file.

We looked through the community and support online, but no success.

Our client uses the QMC and there is no option to extract the project into a JSON file. Using the available options on console, they are able to provide us .qvf only.

How to convert this .qvf into a JSON format? or is there any api available from Qlik product which can help us extract the metadata into a JSON format.

The client restrictions does not allow us to install any third party APIs or tools in their environment, but anything provided by product itself would be acceptable.

Kindly advise.

Labels (2)
3 Replies
alex_colombo
Employee
Employee

Hey @Inderpreet , you can use qlik-cli, which can help you on unbuilding an app, transofrming your app into multiple json files with all the information about the app. Opposite, you can use build command for reading json files and re-create the app.

DaveChannon
Employee
Employee

As @alex_colombo says, the easiest way is qlik-cli, and this is what we use in for the Qlik Cloud Monitoring apps (example diff here, and code here).

You can also use Qlik Application Automation (there is a template in the picker), or qlik/api or another framework to go directly to the engine and pull the object definitions.

Marc
Employee
Employee

I guess it depends on what you are trying to extract and from where.

For customer managed you can use QlikSenseCLI it will be in the tools directory of your QS install folder

 

.for just the App Metadata you could do something like this

Import-Module 'C:\Program Files\Qlik\Sense\Tools\QlikSenseCLI'
Connect-QlikSense -TrustAllCertificates
Get-QSApp -Full -Raw | Out-File -FilePath C:\Temp\AppMetadata.json
 
if you wanted to collect the app and app object metadata you could do something like this.
note the inclusion of a filter as an example

Import-Module 'C:\Program Files\Qlik\Sense\Tools\QlikSenseCLI'
Connect-QlikSense -TrustAllCertificates
$QSApps = Get-QSApp -Full -Filter "Stream.name eq 'Everyone'"
Foreach($App in $QSApps){
    $AppObjects = Get-QSAppObject -Filter "App.id eq $($App.id)" -Full
    $AppInfo = @{App = $App; Objects = $AppObjects}
    $AppInfo|ConvertTo-Json -Compress | Out-File -FilePath "C:\Temp\$($App.id)_$($App.name).json"
}