Jump to content

Search the Community

Showing results for tags 'soap'.

More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • Delphi Questions and Answers
    • Algorithms, Data Structures and Class Design
    • VCL
    • FMX
    • RTL and Delphi Object Pascal
    • Databases
    • Network, Cloud and Web
    • Windows API
    • Cross-platform
    • Delphi IDE and APIs
    • General Help
    • Delphi Third-Party
  • C++Builder Questions and Answers
    • General Help
  • General Discussions
    • Embarcadero Lounge
    • Tips / Blogs / Tutorials / Videos
    • Job Opportunities / Coder for Hire
    • I made this
  • Software Development
    • Project Planning and -Management
    • Software Testing and Quality Assurance
  • Community
    • Community Management

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start




Found 8 results

  1. Hello, There is an application that consumes a SOAP web service. From time to time this web service is not stable and sending various html error messages instead of a valid response. Using Delphi 10.4.2 I would like to read incoming html data and display this to the user. Currently, all we can display is "Received content of invalid Content-Type setting: text/html - SOAP expect "text/xml" error message. I have searched the internet. Someone suggested to modify Soap.SOAPHTTPTrans.THTTPReqResp.CheckContentType and prevent it from raising an exception but this does not sound like a decent solution and might cause other troubles with other applications using SOAP. What I am after is a solution to be used just with this specific application of ours. I wonder if there is an alternative solution that can be used. Thanks & Regards, Ertan
  2. Hello, I am using Delphi 10.3.3, targeting Win32 executable. There is a SOAP web service that I have build a class for it. That class runs just fine on a test project. However, when I put it in my main project, I get below error DocumentElement http://schemas.xmlsoap.org/soap/envelope/:Envelope expected, :Envelope found I checked, there is only one single unit for this web service in my whole computer and both projects are using that unit. I have used different SOAP web services in the past. Some of them rarely raise "HTML found" kind of error messages, but never got ":Envelope found" until now. None of my web searches lead me to same error message that I receive. I have all requests and responses saved in text files. Comparing them I can see no difference. It is only number of records returned changes due to filter parameters. I also used Fiddler Telerik and captured whole response using both test project and main project. They are identical as far as I can tell. Test project response starts as: HTTP/1.1 200 OK Content-Type: text/xml;charset=UTF-8 Connection: keep-alive Set-Cookie: JSESSIONIDSSO=529DA436282217EF9D8D9F21515121D3; Path=/; Secure Set-Cookie: JSESSIONID=82E5260FE1737AA7C77DCE37D71B7132; Path=/listingapi/ws; Secure Server-Timing: intid;desc=d2369e80a9274e5b Date: Sun, 06 Jun 2021 19:41:44 GMT Vary: Accept-Encoding Content-Length: 15213 <env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'> <env:Header/> <env:Body> <ns1:getSalesByDateRangeResponse xmlns:ns1='http://sale.individual.ws.listingapi.gg.com'> <return> <ackCode>success</ackCode> <responseTime>06/06/2021 22:41:44</responseTime> <timeElapsed>1 ms</timeElapsed> <saleCount>11</saleCount> <sales> <sale> Main project response starts as: HTTP/1.1 200 OK Content-Type: text/xml;charset=UTF-8 Connection: keep-alive Set-Cookie: JSESSIONIDSSO=7A2E4B6940B5E0E44F86FF95BBCD6C3D; Path=/; Secure Set-Cookie: JSESSIONID=0ED54949FAC10990F8F24B27B9174216; Path=/listingapi/ws; Secure Server-Timing: intid;desc=1a968daea7e9c9d9 Date: Sun, 06 Jun 2021 19:41:17 GMT Vary: Accept-Encoding Content-Length: 9877 <env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'> <env:Header/> <env:Body> <ns1:getSalesByDateRangeResponse xmlns:ns1='http://sale.individual.ws.listingapi.gg.com'> <return> <ackCode>success</ackCode> <responseTime>06/06/2021 22:41:17</responseTime> <timeElapsed>225 ms</timeElapsed> <saleCount>7</saleCount> <sales> <sale> Web service WSDL can be reached from: https://dev.gittigidiyor.com:8443/listingapi/ws/IndividualSaleService?wsdl I appreciate any help, please. Thanks & Regards, Ertan
  3. The Delphi WSDL Importer has done an impressive job of taking a (local) WSDL file and generating some very useful code (that almost works!) To debug, I have looked at the outgoing request with Fiddler, and based on this, I've been able to alter the WSDL file to effect a required change in the request header. However, the problem remains that Delphi is generating a tag with "NAV_CustomerItemPriceV1" but the server needs "ReadMultiple" - ( which seems sensible of Delphi as the resource that it uses is called NAV_CustomerItemPriceV1) Despite further manual changes to the WSDL and to the code generated by Delphi, I can't force a change in this tag. I have seen posts where people have suggested intercepting the XML, but I'm not sure how to do this (or how to access the events on THTTPRIO) TIA Incorrect: <NAV_CustomerItemPriceV1 xmlns="http://tempuri.org/"> <customerNo>account_no</customerNo> <apiKey>api_key</apiKey> <itemList> <Item No="T14727IO" xmlns="urn:microsoft-dynamics-nav/xmlports/NAV_CustomerItemPriceV1" /> <Item No="ZT62062-T1E0100Z" xmlns="urn:microsoft-dynamics-nav/xmlports/NAV_CustomerItemPriceV1" /> </itemList> </NAV_CustomerItemPriceV1> Correct: <ReadMultiple xmlns="http://tempuri.org/"> <customerNo>account_no</customerNo> <apiKey>api_key</apiKey> <itemList> <Item No="T14727IO" xmlns="urn:microsoft-dynamics-nav/xmlports/NAV_CustomerItemPriceV1" /> <Item No="ZT62062-T1E0100Z" xmlns="urn:microsoft-dynamics-nav/xmlports/NAV_CustomerItemPriceV1" /> </itemList> </ReadMultiple>
  4. Our web applications have been moved to IIS on a server running Microsoft Windows Server 2019 Standard. I have two SOAP applications (Delphi 10.3.3) running on the server. One of the SOAP applications is accessed by external third-party clients and works fine. The second SOAP application handles geocoding tasks for internal users and is accessed using our main client application (Delphi XE2). When users access the geocoding SOAP over https, they get the message: "A certificate is required to complete client authentication - URL:https:.../indigoservice.exe/soap/IIsservices - SOAPAction:urn:IsServicesIntf-IIServices#GeocodeArea" I can't install certificates on users computers and so I don't know how to resolve this issue. I made changes to the SOAP source to run over http and opened the http port on the server. That didn't work either as users get the message: Class not registered, ClassID: {C0EAC9EB-1D02-4BD9-8DAB-4BF922C8CD13}. I can rewrite the routine without using SOAP but would like to get this online ASAP. What can be done to get this working? Thanks
  5. Hello, I am using Delphi 10.3.3 and trying to consume a SOAP web service method. Wsdl that I need to use is below: https://dev.gittigidiyor.com:8443/listingapi/ws/IndividualSaleService?wsdl Delphi 10.3.3 successfully imports that wsdl page. Imported unit generates an output XML for "getPagedSales" method as following (included only relevant parts of XML): <?xml version="1.0"?> <SOAP-ENV:Envelope 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/"> <SOAP-ENV:Body> <getPagedSales xmlns="http://sale.individual.ws.listingapi.gg.com"> When same wsdl is imported using SOAP-UI application, generated sample request output starting as following: <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sale="http://sale.individual.ws.listingapi.gg.com"> <soapenv:Header/> <soapenv:Body> <sale:getPagedSales> If you look closely and compare both, the SOAP-UI generated XML, envelope has "sale" in it as well as method name is put after "sale". My problem is that web service is not accepting Delphi request and returning an error as following: <env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'> <env:Header/> <env:Body> <env:Fault xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'> <faultcode>env:Client</faultcode> <faultstring>Endpoint {http://application.anonymous.ws.listingapi.gg.com}ApplicationServicePort does not contain operation meta data for: {http://sale.individual.ws.listingapi.gg.com}getPagedSales</faultstring> </env:Fault> </env:Body> </env:Envelope> My question is: Is it possible to modify wsdl imported unit in a way so that out of the box SOAP adds that "sale" in relevant places of requests not just for getPagedSale mothod, but for all sale service methods? I know it is possible to use THTTPRIO.OnBeforeExecute() and send identical XML to that of SOAP-UI generated (which web service will be accepting). However, I am just trying to avoid that if it is possible. Thanks & Regards, Ertan
  6. Hello, There is that WSDL here: http://messaging.yemeksepeti.com/messagingwebservice/integration.asmx?WSDL I need to read data from method named "GetRestaurantList" actually that is my starting method. I hopefully will need to use other methods later. I do not get exception on user level. But there is below error in Delphi while in debug run. First chance exception at $767DC762. Exception class ESOAPDomConvertError with message 'Conversion from class TList<System.IInterface> to SOAP is not supported - SOAP classes must derive from TRemotable'. Process YemekSepeti_WebServis.exe (9024) Here is the raw response from server: <?xml version="1.0" encoding="UTF-8"?> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <soap:Body> <GetRestaurantListResponse xmlns="http://tempuri.org/"> <GetRestaurantListResult> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns="" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" id="RestaurantList"> <xs:element name="RestaurantList" msdata:IsDataSet="true" msdata:Locale=""> <xs:complexType> <xs:choice minOccurs="0" maxOccurs="unbounded"> <xs:element name="Restaurants"> <xs:complexType> <xs:sequence> <xs:element name="CatalogName" type="xs:string" minOccurs="0" /> <xs:element name="CategoryName" type="xs:string" minOccurs="0" /> <xs:element name="DisplayName" type="xs:string" minOccurs="0" /> <xs:element name="ServiceTime" type="xs:int" minOccurs="0" /> <xs:element name="Speed" type="xs:decimal" minOccurs="0" /> <xs:element name="Serving" type="xs:decimal" minOccurs="0" /> <xs:element name="Flavour" type="xs:decimal" minOccurs="0" /> </xs:sequence> </xs:complexType> </xs:element> </xs:choice> </xs:complexType> </xs:element> </xs:schema> <diffgr:diffgram xmlns:diffgr="urn:schemas-microsoft-com:xml-diffgram-v1" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata"> <RestaurantList xmlns=""> <Restaurants diffgr:id="Restaurants1" msdata:rowOrder="0"> <CatalogName>testname</CatalogName> <CategoryName>4f1cc1a8-bf2e-4eab-8dd5-34f37857911a</CategoryName> <DisplayName>Pizza, Test</DisplayName> <ServiceTime>45</ServiceTime> </Restaurants> </RestaurantList> </diffgr:diffgram> </GetRestaurantListResult> </GetRestaurantListResponse> </soap:Body> </soap:Envelope> Honestly, this is the first time I am reading such a response myself. Is there any way that I can consume that web service? Any help is appreciated. Thanks & regards, Ertan
  7. Hello, I have a WSDL file (attached) that I need to use with WSDL Importer of Delphi 10.3. Using all defaults there is a remark in generated pascal file // ************************************************************************ // // The following types, referred to in the WSDL document are not being represented // in this file. They are either aliases[@] of other types represented or were referred // to but never[!] declared in the document. The types from the latter category // typically map to predefined/known XML or Embarcadero types; however, they could also // indicate incorrect WSDL documents that failed to declare or import a schema type. // ************************************************************************ // // !:getInvoiceViewRequest - "http:/fitcons.com/eInvoice/"[Lit][] // !:getEnvelopeStatusResponse - "http:/fitcons.com/eInvoice/"[Lit][] // !:getEnvelopeStatusRequest - "http:/fitcons.com/eInvoice/"[Lit][] // !:getUserListResponse - "http:/fitcons.com/eInvoice/"[Lit][] // !:getUserListRequest - "http:/fitcons.com/eInvoice/"[Lit][] // !:getInvoiceViewResponse - "http:/fitcons.com/eInvoice/"[Lit][] // !:getUBLResponse - "http:/fitcons.com/eInvoice/"[Lit][] // !:ProcessingFault - "http:/fitcons.com/eInvoice/"[Flt][] // !:sendUBLResponse - "http:/fitcons.com/eInvoice/"[Lit][] // !:sendUBLRequest - "http:/fitcons.com/eInvoice/"[Lit][] // !:getUBLRequest - "http:/fitcons.com/eInvoice/"[Lit][] // !:getUBLListResponse - "http:/fitcons.com/eInvoice/"[Lit][] // !:getUBLListRequest - "http:/fitcons.com/eInvoice/"[Lit][] As expected, generated file is not compiled under Delphi. Unfortunately, I am not provided any Internet link instead of that WSDL file. I wonder if it is possible to have a working service interface for Delphi using only attached WSDL file. Thanks & regards, Ertan ClientEInvoiceServices-2.0.wsdl
  8. Hello, I tried to find solution to my problem in several places already including stackoverflow When consuming a SOAP web service, response to a request comes in fine, but it is not populated in response object in code. I already provided details in above link. Let me know if they really need to be in this post, please. I added all files needed to test my case. I did not provide username and password as they are irrelevant to my problem. Below is an example code to use provided units. uses EFinans.EArsivFatura; procedure TForm1.Button1Click(Sender: TObject); var Input: TFaturaOlusturInput; begin // required before calling any EFinans.EArsivFatura procedure/function EFinans.EArsivFatura.URLEArsivFatura := 'https://earsiv.efinans.com.tr/earsiv/ws/EarsivWebService'; EFinans.EArsivFatura.Username := 'someuser'; EFinans.EArsivFatura.Password := 'somepassword'; // preparing parameters Input.donenBelgeFormati := Ord(TGelenBelgeFormatlari.gePDF); Input.goruntuOlusturulsunMu := 1; // 0=hayır, 1=evet Input.islemId := TGUID.NewGuid.ToString().Substring(1, 36).ToLower(); Input.vkn := '123456789'; Input.sube := '000000'; Input.kasa := '0000'; Input.numaraVerilsinMi := 0; Input.faturaSeri := EmptyStr; Input.sablonAdi := 'einvoice_efinans_15_06_04_3.xslt'; Input.erpKodu := 'ERP1'; Input.gzip := 1; if not EFinans.EArsivFatura.AFaturaOlustur(Input, TGidenBelgeFormatlari.PDF, 'test.zip', 'test.pdf') then begin ShowMessage(EFinans.EArsivFatura.LastError); Exit(); end; end; Above sample code will get you an error response from web service. That response will be saved in "response.xml" file in same directory as your EXE. If you debug and put a break point in line 237 of EFinans.EArsivFatura.pas you should see that Response.return is nil. That is my problem. I have same problem in other methods, too. Just trying to see how I fix this single one now. Thanks & regards, Ertan EarsivWebService1.pas EFinans.EarsivFatura.Utils.pas EFinans.EArsivFatura.pas response.xml test.zip