Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello Everyone,
I'm new to Talend just learning how to use the the components.
this is use case csv -> map -> json -> rest api
For the components, I implemented like this
tFileInputDelimited -> tMap -> tFileOutputJson . I got the JSON I needed
CSV file :
id,source,date,dataType,value
1,/source1,2013-12-07 05:43Z,2,1.068
2,/source2,2013-12-07 06:23Z,1,12345678
JSON body request should be something like this:
[
{
"id":1,
"source":"/source1",
"date": "2013-12-07 05:40Z",
"dataType":2,
"value":1.09
}
]
now how to send the json to rest api as request?
You dint have to save the JSON as a file. There is one more simple way you can create the JSON post it into rest API and extract the Response
PFA the Screenshot. I have a sample workflow that shows how you can achieve it.
If this is what you are looking for then, Press the "Accept as Solution " Button and Give a Kudos.
Thanks,
AR