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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

store tREST output in XML file

All,

 

I am trying to get the TOKEN from tableau serve by using tableau rest api methods, i was able to get the token by using Postman, but here i got strucked.

 

I have a simple REST component where i hardcoded the Body and used a 'logrow' component to capture the output, it works fine.

 

But when i try to store the same result, it is not properly writing. I need this file later to get the 'TOKEN'.

 

How to capture the response of tREST in an XML file for further processing?

 

Labels (5)
3 Replies
Anonymous
Not applicable
Author

Hi
The tRest returns a string, is it a XML format or Json format? If it is latter, use a tExtractJsonField to extract the data from the response and use a tAdvancedFileOutputXML to create a new XML file.

Regards
Shong
Anonymous
Not applicable
Author

do you mean  tRest will not return XML/JSON format? 

 

What is the simple job design to get the TOKEN and store it in a file or variable?

 

Anonymous
Not applicable
Author

The response of tRest is a string with XML/Json format, to use tExtractJsonField or tExtractXMLField to extract data from the response depends on it is a Json format or XML format. A simple job design looks like:
tRest--tExtractJsonField--tfileOutputDelimited