· Jan 24, 2019

How to make a XML Message ?

Hi All,

Actually I am trying to implement a RESt API where in I will get ZIPCODE as request and I need to call external API which will take ZIPCODE as input and give State and City in response.

But the problem is the request is in XML Format and also response is in XML format.

Example :<CSLookupRequest USERID="USERID">
<ZipCode ID='0'>

and in Response 

<?xml version="1.0" encoding="UTF-8"?>
    <ZipCode ID="0">

So Basically,
1) How can I create a XML message where in I can pass ZIPCODE and send in Request URL and

2) How to read the XML response like State and City from XML.

Discussion (2)0
Log in or sign up to continue