maven - Calling IDX MLS SOAP APIs of ihomefinder from Java Spring MVC -
i want use ihomefinder's test apis data , insert own database. using spring mvc , link provided them configured in pom.xml data http://axisws.idxre.com:8080/axis2/services/ihfpartnerservices?wsdl. various searches found provided apis in package com.ihomefinder.api
included pom.xml
here pom.xml code:
<dependencies> <dependency> <groupid>org.springframework.boot</groupid> <artifactid>spring-boot-starter-ws</artifactid> <version>1.3.1.release</version> </dependency> </dependencies> <build> <plugins> <plugin> <groupid>org.jvnet.jaxb2.maven2</groupid> <artifactid>maven-jaxb2-plugin</artifactid> <version>0.13.1</version> <executions> <execution> <goals> <goal>generate</goal> </goals> </execution> </executions> <configuration> <schemalanguage>wsdl</schemalanguage> <generatepackage>com.ihomefinder.api</generatepackage> <schemas> <schema> <url>http://axisws.idxre.com:8080/axis2/services/ihfpartnerservices?wsdl</url> </schema> </schemas> </configuration> </plugin> </plugins> </build>
now trying login test username , password provided them, hit login service need create object of request class not found in package com.ihomefinder.api
.
here java code using make request:
import javax.xml.bind.jaxbelement; import org.springframework.ws.client.core.support.webservicegatewaysupport; import org.springframework.ws.soap.client.core.soapactioncallback; import com.ihomefinder.api.login; import com.ihomefinder.api.objectfactory; public class idxmls extends webservicegatewaysupport { public void main() { // todo auto-generated method stub objectfactory objectfactory = new objectfactory(); jaxbelement<string> user = objectfactory.createloginusername("username"); jaxbelement<string> pass = objectfactory.createloginpassword("password"); login login = new login(); login.setusername(user); login.setpassword(pass); integer int1 = (integer) getwebservicetemplate().marshalsendandreceive(login, new soapactioncallback("http://axisws.idxre.com:8080/axis2/services/login")); system.out.println(int1); } public static void main(string[] args) { idxmls idxmls = new idxmls(); idxmls.main(); } }
i think above code not perfect things missing. can me correct code can response api?
it looks you're using our partner api soap client. our current reseller api rest api, , entry point url is:
https://www.idxhome.com/restservices/reseller/login
documentation reseller api not publicly posted @ time. please email @ support@ihomefinder.com, , happy provide documentation.
Comments
Post a Comment