One Star

[resolved] Getting response from TRestClient

Hi I am using TRestClient component get method .
I want to get the response from tRestclient and want process on it ? can some one tell me how it should be done ?
How to get the response and assign to somer context variable ?how to do action on json and xml formats ?
I have attached screenshot for the reference.
1 ACCEPTED SOLUTION

Accepted Solutions
One Star

Re: [resolved] Getting response from TRestClient

Thank you for your reply ,i fetched that data through txmlmap and taken to context variable and processed it .
5 REPLIES
Seventeen Stars

Re: [resolved] Getting response from TRestClient

You should connect the output flow response to a tLogRow to get an idea what the component provides as result.
If you want to prepare the calls, you can use the input flow to put parameters to the request.
tRestClient ---> tLogRow
Community Manager

Re: [resolved] Getting response from TRestClient

If
tRestClient component returns an response with Document type, if you want to extract value from the Document, connect it to tXMLMap and extract the value, and then link tXMLMap to a tJavaRow and assign the value to context variable. For example:
tRestClient--main--tXMLMap--main--tJavaRow

Shong
----------------------------------------------------------
Talend | Data Agility for Modern Business
One Star

Re: [resolved] Getting response from TRestClient

Can someone show me the sample package configuration for the above web service ?
Community Manager

Re: [resolved] Getting response from TRestClient

As jlolling suggested, link tRestClient to a tLogRow and print the result on the console, show us the result and explain what's data would you like to extract?
Shong
----------------------------------------------------------
Talend | Data Agility for Modern Business
One Star

Re: [resolved] Getting response from TRestClient

Thank you for your reply ,i fetched that data through txmlmap and taken to context variable and processed it .