-2

First Of All sorry about my bad English :D and Thanks for your help...

I have to write a Delphi web service with xsd schema and the wsdl similar to wsdl at the bottom. Is it possible with Delphi. I have to write a service according to the existing web service client, the wsdl at the bottom belongs to an php web service with nusoap library.

I seem to hear you write this web service with php nusoap, but as you know that Delphi web service can be standalone exe and I need it's ability for our product.

I can write this web service with php no problem, but if it is possible, I want to write this web service with Delphi as a standalone.

I could write this web service with Delphi as standalone.The problem is that WSDL. My service's WSDL have to similar with the WSDL at the bottom. Can I do my service's wsdl similar to wsdl at the bottom? If it is possible,how can I do?

I'm using Delphi XE4.

Thanks again.

<?xml version="1.0" encoding="windows-1252"?>
<definitions xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="urn:wnposwsdl2" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns="http://schemas.xmlsoap.org/wsdl/" targetNamespace="urn:wnposwsdl2">
<types>
<xsd:schema targetNamespace="urn:wnposwsdl2">
 <xsd:import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
 <xsd:import namespace="http://schemas.xmlsoap.org/wsdl/"/>
 <xsd:complexType name="wnposreply">
  <xsd:all>
   <xsd:element name="rtype" type="xsd:string"/>
   <xsd:element name="rid" type="xsd:string"/>
   <xsd:element name="rval1" type="xsd:string"/>
   <xsd:element name="rval2" type="xsd:string"/>
   <xsd:element name="rmessage1" type="xsd:string"/>
   <xsd:element name="rmessage2" type="xsd:string"/>
   <xsd:element name="rmessage3" type="xsd:string"/>
  </xsd:all>
 </xsd:complexType>
 <xsd:complexType name="posregister">
  <xsd:all>
   <xsd:element name="serialno" type="xsd:string"/>
   <xsd:element name="posid" type="xsd:string"/>
   <xsd:element name="siteid" type="xsd:string"/>
   <xsd:element name="sitename" type="xsd:string"/>
  </xsd:all>
 </xsd:complexType>
 <xsd:complexType name="customercard">
  <xsd:all>
   <xsd:element name="cctype" type="xsd:string"/>
   <xsd:element name="customercode" type="xsd:string"/>
   <xsd:element name="ccnumber" type="xsd:string"/>
   <xsd:element name="validfrom" type="xsd:string"/>
   <xsd:element name="validto" type="xsd:string"/>
   <xsd:element name="pin" type="xsd:string"/>
   <xsd:element name="ccstatus" type="xsd:string"/>
   <xsd:element name="total_d" type="xsd:float"/>
   <xsd:element name="total_c" type="xsd:float"/>
  </xsd:all>
 </xsd:complexType>
 <xsd:complexType name="customer">
  <xsd:all>
   <xsd:element name="code" type="xsd:string"/>
   <xsd:element name="name" type="xsd:string"/>
   <xsd:element name="address1" type="xsd:string"/>
   <xsd:element name="address2" type="xsd:string"/>
   <xsd:element name="county" type="xsd:string"/>
   <xsd:element name="city" type="xsd:string"/>
   <xsd:element name="zip" type="xsd:string"/>
   <xsd:element name="tel" type="xsd:string"/>
   <xsd:element name="gsm" type="xsd:string"/>
   <xsd:element name="email" type="xsd:string"/>
   <xsd:element name="web" type="xsd:string"/>
   <xsd:element name="listprice" type="xsd:string"/>
   <xsd:element name="defdiscount" type="xsd:string"/>
  </xsd:all>
 </xsd:complexType>
 <xsd:complexType name="payment">
  <xsd:all>
   <xsd:element name="id" type="xsd:int"/>
   <xsd:element name="val" type="xsd:float"/>
  </xsd:all>
 </xsd:complexType>
 <xsd:complexType name="ccard">
  <xsd:all>
   <xsd:element name="customercard" type="tns:customercard"/>
   <xsd:element name="customer" type="tns:customer"/>
  </xsd:all>
 </xsd:complexType>
 <xsd:complexType name="ccardarray">
  <xsd:complexContent>
   <xsd:restriction base="SOAP-ENC:Array">
    <xsd:attribute ref="SOAP-ENC:arrayType" wsdl:arrayType="tns:ccard[]"/>
   </xsd:restriction>
  </xsd:complexContent>
 </xsd:complexType>
 <xsd:complexType name="customertrans">
  <xsd:all>
   <xsd:element name="ccnumber" type="xsd:string"/>
   <xsd:element name="posserialno" type="xsd:string"/>
   <xsd:element name="ftransid" type="xsd:string"/>
   <xsd:element name="ftype" type="xsd:string"/>
   <xsd:element name="ftm" type="xsd:string"/>
   <xsd:element name="fno" type="xsd:string"/>
   <xsd:element name="excode" type="xsd:string"/>
   <xsd:element name="genexp" type="xsd:string"/>
   <xsd:element name="sign" type="xsd:string"/>
   <xsd:element name="amount" type="xsd:float"/>
  </xsd:all>
 </xsd:complexType>
 <xsd:complexType name="customertransarray">
  <xsd:complexContent>
   <xsd:restriction base="SOAP-ENC:Array">
    <xsd:attribute ref="SOAP-ENC:arrayType" wsdl:arrayType="tns:customertrans[]"/>
   </xsd:restriction>
  </xsd:complexContent>
 </xsd:complexType>
 <xsd:complexType name="payments">
  <xsd:complexContent>
   <xsd:restriction base="SOAP-ENC:Array">
    <xsd:attribute ref="SOAP-ENC:arrayType" wsdl:arrayType="tns:payment[]"/>
   </xsd:restriction>
  </xsd:complexContent>
 </xsd:complexType>
 <xsd:complexType name="itemtrans">
  <xsd:all>
   <xsd:element name="ttype" type="xsd:string"/>
   <xsd:element name="subtype" type="xsd:string"/>
   <xsd:element name="code" type="xsd:string"/>
   <xsd:element name="quantity" type="xsd:float"/>
   <xsd:element name="bprice" type="xsd:float"/>
   <xsd:element name="itemgroupcode" type="xsd:string"/>
  </xsd:all>
 </xsd:complexType>
 <xsd:complexType name="itemtransarray">
  <xsd:complexContent>
   <xsd:restriction base="SOAP-ENC:Array">
    <xsd:attribute ref="SOAP-ENC:arrayType" wsdl:arrayType="tns:itemtrans[]"/>
   </xsd:restriction>
  </xsd:complexContent>
 </xsd:complexType>
 <xsd:complexType name="receiptheader">
  <xsd:all>
   <xsd:element name="fno" type="xsd:string"/>
   <xsd:element name="ftm" type="xsd:string"/>
   <xsd:element name="siteid" type="xsd:string"/>
   <xsd:element name="customercard" type="tns:customercard"/>
   <xsd:element name="payments" type="tns:payments"/>
   <xsd:element name="nettotal" type="xsd:float"/>
   <xsd:element name="calculatedtotalpoint" type="xsd:float"/>
  </xsd:all>
 </xsd:complexType>
 <xsd:complexType name="receipt">
  <xsd:all>
   <xsd:element name="ftransid" type="xsd:int"/>
   <xsd:element name="serialno" type="xsd:string"/>
   <xsd:element name="ctranstype" type="xsd:string"/>
   <xsd:element name="header" type="tns:receiptheader"/>
   <xsd:element name="items" type="tns:itemtransarray"/>
  </xsd:all>
 </xsd:complexType>
 <xsd:complexType name="receiptarray">
  <xsd:complexContent>
   <xsd:restriction base="SOAP-ENC:Array">
    <xsd:attribute ref="SOAP-ENC:arrayType" wsdl:arrayType="tns:receipt[]"/>
   </xsd:restriction>
  </xsd:complexContent>
 </xsd:complexType>
 <xsd:complexType name="spendingcheck">
  <xsd:all>
   <xsd:element name="ctrans" type="tns:customertrans"/>
   <xsd:element name="basket" type="tns:receipt"/>
  </xsd:all>
 </xsd:complexType>
</xsd:schema>
</types>
<message name="register_posRequest">
  <part name="posrecord" type="tns:posregister"/></message>
<message name="register_posResponse">
  <part name="return" type="tns:wnposreply"/></message>
<message name="query_cardRequest">
  <part name="customercard" type="tns:customercard"/></message>
<message name="query_cardResponse">
  <part name="return" type="tns:wnposreply"/></message>
<message name="register_customerRequest">
  <part name="ccardarray" type="tns:ccardarray"/></message>
<message name="register_customerResponse">
  <part name="return" type="tns:wnposreply"/></message>
<message name="check_receiptRequest">
  <part name="receipt" type="tns:receiptarray"/></message>
<message name="check_receiptResponse">
  <part name="return" type="tns:wnposreply"/></message>
<message name="add_ctransRequest">
  <part name="customertrans" type="tns:customertrans"/></message>
<message name="add_ctransResponse">
  <part name="return" type="tns:wnposreply"/></message>
<message name="update_ctransRequest">
  <part name="customertrans" type="tns:customertrans"/></message>
<message name="update_ctransResponse">
  <part name="return" type="tns:wnposreply"/></message>
<message name="add_spendingRequest">
  <part name="spendingcheck" type="tns:spendingcheck"/></message>
<message name="add_spendingResponse">
  <part name="return" type="tns:wnposreply"/></message>
<portType name="wnposwsdl2PortType">
  <operation name="register_pos">
    <documentation>Register pos...</documentation>
    <input message="tns:register_posRequest"/>
    <output message="tns:register_posResponse"/>
  </operation>
  <operation name="query_card">
    <documentation>Query customer card...</documentation>
    <input message="tns:query_cardRequest"/>
    <output message="tns:query_cardResponse"/>
  </operation>
  <operation name="register_customer">
    <documentation>Registers customer(s)/card(s)/giftcard(s) to be used by the server, approval required by the db manager....</documentation>
    <input message="tns:register_customerRequest"/>
    <output message="tns:register_customerResponse"/>
  </operation>
  <operation name="check_receipt">
    <documentation>Check receipt for gift or point collection..</documentation>
    <input message="tns:check_receiptRequest"/>
    <output message="tns:check_receiptResponse"/>
  </operation>
  <operation name="add_ctrans">
    <documentation>Add trans..</documentation>
    <input message="tns:add_ctransRequest"/>
    <output message="tns:add_ctransResponse"/>
  </operation>
  <operation name="update_ctrans">
    <documentation>Update added trans change stage...</documentation>
    <input message="tns:update_ctransRequest"/>
    <output message="tns:update_ctransResponse"/>
  </operation>
  <operation name="add_spending">
    <documentation>Add spending ..</documentation>
    <input message="tns:add_spendingRequest"/>
    <output message="tns:add_spendingResponse"/>
  </operation>
</portType>
<binding name="wnposwsdl2Binding" type="tns:wnposwsdl2PortType">
  <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
  <operation name="register_pos">
    <soap:operation soapAction="urn:wnposwsdl2#register_pos" style="rpc"/>
    <input><soap:body use="encoded" namespace="urn:wnposwsdl2" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></input>
    <output><soap:body use="encoded" namespace="urn:wnposwsdl2" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></output>
  </operation>
  <operation name="query_card">
    <soap:operation soapAction="urn:wnposwsdl2#query_card" style="rpc"/>
    <input><soap:body use="encoded" namespace="urn:wnposwsdl2" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></input>
    <output><soap:body use="encoded" namespace="urn:wnposwsdl2" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></output>
  </operation>
  <operation name="register_customer">
    <soap:operation soapAction="urn:wnposwsdl2#register_customer" style="rpc"/>
    <input><soap:body use="encoded" namespace="urn:wnposwsdl2" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></input>
    <output><soap:body use="encoded" namespace="urn:wnposwsdl2" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></output>
  </operation>
  <operation name="check_receipt">
    <soap:operation soapAction="urn:wnposwsdl2#check_receipt" style="rpc"/>
    <input><soap:body use="encoded" namespace="urn:wnposwsdl2" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></input>
    <output><soap:body use="encoded" namespace="urn:wnposwsdl2" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></output>
  </operation>
  <operation name="add_ctrans">
    <soap:operation soapAction="urn:wnposwsdl2#customertrans" style="rpc"/>
    <input><soap:body use="encoded" namespace="urn:wnposwsdl2" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></input>
    <output><soap:body use="encoded" namespace="urn:wnposwsdl2" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></output>
  </operation>
  <operation name="update_ctrans">
    <soap:operation soapAction="urn:wnposwsdl2#customertrans" style="rpc"/>
    <input><soap:body use="encoded" namespace="urn:wnposwsdl2" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></input>
    <output><soap:body use="encoded" namespace="urn:wnposwsdl2" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></output>
  </operation>
  <operation name="add_spending">
    <soap:operation soapAction="urn:wnposwsdl2#spendingcheck" style="rpc"/>
    <input><soap:body use="encoded" namespace="urn:wnposwsdl2" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></input>
    <output><soap:body use="encoded" namespace="urn:wnposwsdl2" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></output>
  </operation>
</binding>
<service name="wnposwsdl2">
  <port name="wnposwsdl2Port" binding="tns:wnposwsdl2Binding">
    <soap:address location="http://ksistemdomain.com:88/web.biz/server/wnposserver.php"/>
  </port>
</service>
</definitions>
marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
ErkanK
  • 95
  • 7
  • see http://stackoverflow.com/questions/846207/how-to-build-stand-alone-soap-web-services-using-delphi – mjn Aug 05 '15 at 16:52
  • and http://chapmanworld.com/2015/03/30/creating-and-consuming-soap-services-in-delphi/ – mjn Aug 05 '15 at 16:54

1 Answers1

-2

Sure, you can use Delphi to write a SOAP Service out of your wsdl file. then you can use the result dll to call your service.

you can check out this link for more info.

Nada N. Hantouli
  • 1,310
  • 1
  • 12
  • 20
  • This is not an answer, because there is no actual content here. All the content is off-site at an external link. This should be a comment to the original post instead. – Ken White Mar 07 '19 at 12:58