Talend Connect
Virtual Summit
JOIN US!
And visit the Customer
& Community Lounge.
May 27-28, wherever you are.

How to use the tRest component output

Highlighted
One Star

How to use the tRest component output

Hi!
I'm using the 'tRest' component to perform a HTTP Post. When that request succeeds, I receive information in XML format. How can I access that information in the next component? My next step is to convert that information in a CSV format. And if I want to save the information I get from the HTTP Post into a XML file, how can I do that?
Thanks.
Highlighted
Community Manager

Re: How to use the tRest component output

Hi
You can use a tExtractXMLField to extract the value from the response of tRest in XML format.
Shong
----------------------------------------------------------
Talend | Data Agility for Modern Business
Highlighted
One Star

Re: How to use the tRest component output

Should I be able to use the response of the tRest component (the String called 'Body') in the 'tExtractXMLField'? I can't access it from any component...
Thanks
Highlighted
Community Manager

Re: How to use the tRest component output

Yes, you can extract the value from the body filed on tExtractXMLField, the job looks like:
tRest--main--tExtractXMLField--main--tAdvancedFileOutputXML
If you can't still get it work, please show us the content of the response of tRest component, what's the response looks like after you call the web service with tRest?
Shong
----------------------------------------------------------
Talend | Data Agility for Modern Business

2019 GARTNER MAGIC QUADRANT FOR DATA INTEGRATION TOOL

Talend named a Leader.

Get your copy

OPEN STUDIO FOR DATA INTEGRATION

Kickstart your first data integration and ETL projects.

Download now

Best Practices for Using Context Variables with Talend – Part 1

Learn how to do cool things with Context Variables

Blog

Migrate Data from one Database to another with one Job using the Dynamic Schema

Find out how to migrate from one database to another using the Dynamic schema

Blog

Best Practices for Using Context Variables with Talend – Part 4

Pick up some tips and tricks with Context Variables

Blog