SOAP code generator from a wsdl file lazarus / 38-Networking and Web Programming ---------------------------------------------------------------------- Bogen85 · 2024-09-24 01:19 Is there any tool for free pascal to generate a unit (or units?) for communicating with a SOAP API server given the .wsdl file from that server? ---------------------------------------------------------------------- paweld · 2024-09-24 04:59 Web Service Toolkit: https://wiki.lazarus.freepascal.org/Web_Service_Toolkit ---------------------------------------------------------------------- Bogen85 · 2024-09-24 07:59 Quote from: paweld on September 24, 2024, 06:59:14 amWeb Service Toolkit: https://wiki.lazarus.freepascal.org/Web_Service_Toolkit Thanks. This is not in the current sources for Lazarus (been renamed? removed?). Have not tracked it down yet. ---------------------------------------------------------------------- paweld · 2024-09-24 08:08 You can find it in Online Package Manager under the name WST. Or download from: https://sourceforge.net/p/lazarus- ccr/svn/HEAD/tree/wst/ (svn) or https://gitea.brudnopis.ovh/paweld/lazarus-ccr/src/branch/master/wst (git) ---------------------------------------------------------------------- korba812 · 2024-09-24 08:11 WST sources can be found in Lazarus-CCR repository: https://sourceforge.net/p/lazarus-ccr/svn/HEAD/tree/wst/ ---------------------------------------------------------------------- Bogen85 · 2024-09-24 08:54 Thank you. ws_helper is GPL. That is fine. However, is the generated code able to be used in non GPL software? ---------------------------------------------------------------------- Bogen85 · 2024-09-24 09:08 Alright, that was simple enough Code: Bash  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i git clone https://gitea.brudnopis.ovh/paweld/lazarus-ccr.gitcd lazarus- ccr/wst/trunk/ws_helperlazbuild ws_helper.lpi./ws_helper  Code: Text  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i ws_helper, Web Service Toolkit 0.7 Copyright (c) 2006-2017 by Inoussa OUEDRAOGOws_helper [-uMODE] [-gOPTION] [-cOPTION] [-p] [-b] [-i] [-w] [-x] [-y] [-d] [-j] -[fSPECIFACTIONS] [-oPATH] [-aPATH] inputFilename  -u MODE Generate the pascal translation of the WSDL input file       MODE value may be U for used types or A for all types  -g  Code generation option, with the following options :         A  : object arrays are generated as "array" derived from TBaseObjectArrayRemotable        C  : object arrays are generated as "collection" derived from TObjectCollectionRemotable        EP : enum type's items are prefixed with the enum name        EN : enum type's items are not prefixed with the enum name, the default        FN : do not create fields for "choice"'s items in constructor        FO : create fields for "choice"'s items in constructor, the default        SS : XSD'string type is mapped to Object Pascal' String        SU : XSD'string type is mapped to Object Pascal' UnicodeString  -p  Generate service proxy  -b  Generate service binder  -i  Generate service minimal implementation. This will erase any existing implementation file!  -o  PATH  Relative output directory  -a  PATH  Absolute output directory  -w  Generate WSDL file; Can be used to get wsdl from pascal  -x  Generate XSD file; Can be used to get xsd from pascal  -y  Generate easy access interface for wrapped parameters  -d  Generate documentation as comment in the interface file  -c  Indicate the parser's case sensitivity :         S  : the paser is case sensitive        I  : the paser is not case sensitive  -j  Generate Java Language interface files for  -f  Specify unit(s) renaming option : oldName= NewName(;oldName= NewName)* Now just need to know what license (if any) the generated code would be bound by. ---------------------------------------------------------------------- Bogen85 · 2024-09-24 09:10 There is this: https://wiki.lazarus.freepascal.org/Web_Service_Toolkit#License But not sure if that what the generated call falls under. ---------------------------------------------------------------------- Bogen85 · 2024-09-24 09:20 Code: Bash  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i $ ws_helper -o out -p -b -c I ./server.wsdl ws_helper, Web Service Toolkit 0.7 Copyright (c) 2006-2017 by Inoussa OUEDRAOGOParsing the file : ./server.wsdlInformation : Parsing the port type "VoIPms"Information : Parsing operation "addCharge"Information : Parsing "xsd1:addChargeInput" ...Error : Unable to find the parser, namespace : "http://schemas.xmlsoap.org/soap/encoding/". soapenc:Array typeException : Unable to find the parser, namespace : "http://schemas.xmlsoap.org/soap/encoding/". ---------------------------------------------------------------------- Thaddy · 2024-09-24 09:29 Quote from: Bogen85 on September 24, 2024, 11:10:18 amThere is this: https://wiki.lazarus.freepascal.org/Web_Service_Toolkit#License But not sure if that what the generated call falls under. In this case the generated calls fall under your own license. Changes to the generator itself are lgpl with linker exception. That is not always the case, e.g. a generator may have inadvertently generated copyrighted code or even patented code, so you need to be careful. (OpenAI bitten me in some cases.)