Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Webservice request without object repository
#1
Hi,

I would like to send the following soap request

Code:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sch="http://sita.aero/pts/bcs/sif/schemas"> <soapenv:Header/> <soapenv:Body> <sch:SIFRequest>?</sch:SIFRequest> </soapenv:Body> </soapenv:Envelope>

To the following wsdl

Code:
<?xml version="1.0" encoding="UTF-8" standalone="no" ?> - <wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:sch="http://sita.aero/pts/bcs/sif/schemas" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://sita.aero/pts/bcs/sif/schemas" targetNamespace="http://sita.aero/pts/bcs/sif/schemas"> - <wsdl:types> + <xs:schema xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" xmlns:xs="http://www.w3.org/2001/XMLSchema" attributeFormDefault="unqualified" elementFormDefault="qualified" jaxb:version="2.0" targetNamespace="http://sita.aero/pts/bcs/sif/schemas"> - <xs:annotation> - <xs:appinfo> - <jaxb:globalBindings> <jaxb:javaType name="java.util.Calendar" parseMethod="javax.xml.bind.DatatypeConverter.parseDateTime" printMethod="javax.xml.bind.DatatypeConverter.printDateTime" xmlType="xs:dateTime" /> </jaxb:globalBindings> </xs:appinfo> </xs:annotation> <xs:element name="SIFRequest" /> - <xs:element name="SIFResponse"> - <xs:complexType> - <xs:sequence> - <xs:element maxOccurs="unbounded" minOccurs="0" name="TravellerAlert"> - <xs:complexType> - <xs:sequence> <xs:element name="FlightCode" type="xs:string" /> <xs:element name="ArrAirportCode" type="xs:string" /> <xs:element name="ArrSchDatetime" type="xs:dateTime" /> <xs:element name="TravellerName" type="xs:string" /> <xs:element name="BirthDate" type="xs:dateTime" /> <xs:element name="Nationality" type="xs:string" /> <xs:element name="DocType" type="xs:string" /> <xs:element name="DocNumber" type="xs:string" /> - <xs:element name="Notes"> - <xs:simpleType> - <xs:restriction base="xs:string"> <xs:maxLength value="50" /> </xs:restriction> </xs:simpleType> </xs:element> </xs:sequence> </xs:complexType> </xs:element> - <xs:element maxOccurs="1" name="ServiceStatus" nillable="false"> - <xs:simpleType> - <xs:restriction base="xs:integer"> <xs:pattern value="[0-2]" /> </xs:restriction> </xs:simpleType> </xs:element> </xs:sequence> </xs:complexType> </xs:element> </xs:schema> </wsdl:types> - <wsdl:message name="SIFResponse"> <wsdl:part element="tns:SIFResponse" name="SIFResponse" /> </wsdl:message> - <wsdl:message name="SIFRequest"> <wsdl:part element="tns:SIFRequest" name="SIFRequest" /> </wsdl:message> - <wsdl:portType name="TravellerAlert"> - <wsdl:operation name="SIF"> <wsdl:input message="tns:SIFRequest" name="SIFRequest" /> <wsdl:output message="tns:SIFResponse" name="SIFResponse" /> </wsdl:operation> </wsdl:portType> - <wsdl:binding name="TravellerAlertSoap11" type="tns:TravellerAlert"> <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http" /> - <wsdl:operation name="SIF"> <soap:operation soapAction="" /> - <wsdl:input name="SIFRequest"> <soap:body use="literal" /> </wsdl:input> - <wsdl:output name="SIFResponse"> <soap:body use="literal" /> </wsdl:output> </wsdl:operation> </wsdl:binding> - <wsdl:service name="TravellerAlertService"> - <wsdl:port binding="tns:TravellerAlertSoap11" name="TravellerAlertSoap11"> <soap:address location="http://cadev2:80/sif-interface/travellerAlertService/" /> </wsdl:port> </wsdl:service> </wsdl:definitions>

Using QTP. I would prefer to not use the object repository as it is important that the tests are portable.I also want the request to be done in a single QTP test ( no need to read xml in from external file).

Thanks in advance.
Reply
#2
Please ensure to include your code between [code] tags while asking or replying to questions. I have done this for you for this time.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  http request parsing gerfred 1 2,321 06-18-2015, 05:54 PM
Last Post: gerfred
  Bad Request anujkabra1985 0 2,236 05-08-2015, 02:44 AM
Last Post: anujkabra1985
  Error while adding Object to Object repository at run time SaranKumarV 3 9,395 02-02-2015, 01:40 AM
Last Post: dubeyvin
  How ot get big XML as a responce from web service (QTP, POST request) fdmerle 0 3,611 09-19-2014, 10:34 PM
Last Post: fdmerle
  Is there anyway that we can automate adding objects to Object Repository ArunaSiva 0 2,087 06-18-2014, 04:16 PM
Last Post: ArunaSiva

Forum Jump:


Users browsing this thread: 2 Guest(s)