bet365/soap ignores namespace-prefix on elements of type "sequence"

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

bet365/soap ignores namespace-prefix on elements of type "sequence"

Luca Bormann

Hi everyone,

 

i am using the following erlang-package to work with some WSDL-Services.

 

https://github.com/bet365/soap

 

the most part is working fine!

…but my WSDL-service expect that elements of type „sequence“ (including all sub-elements) have an existing namespace-prefix in the xml.

The problem is that the „bet365/soap“-package is ignoring this, when i try to request with the generated client.

 

Please look at my simple examples:

 

--------------------------------------------------------------------------------------

Simple Example for what is needed):

--------------------------------------------------------------------------------------

 

<soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope" xmlns:urn="urn:s:v2">

   <soap:Header/>

   <soap:Body>

      <urn:getArticles>

         <client>my-client</client>

         <articleRequest Id="99999">

 

            <!-- List 1 to 50 elements:-->

            <urn:article>

               <urn:id>1234</urn:id >

               <urn:quantity>4</urn:quantity >

            </urn:article >

 

         </articleRequest >

      </urn:getArticles >

   </soap:Body>

</soap:Envelope>

 

--------------------------------------------------------------------------------------

Simple Example for what is generated by the „bet365/soap“-package:

--------------------------------------------------------------------------------------

 

<soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope" xmlns:urn="urn:s:v2">

   <soap:Header/>

   <soap:Body>

      <urn:getArticles>

         <client>my-client</client>

         <articleRequest Id="99999">

 

            <!-- List 1 to 50 elements:-->

            <article>

               <id>1234</id >

               <quantity>4</quantity >

            </article >

 

         </articleRequest >

      </urn:getArticles >

   </soap:Body>

</soap:Envelope>

 

--------------------------------------------------------------------------------------

Can someone help?

Maybe there is an option to pass to „bet365/soap“-package when generating the client?

Maybe there is a code-change needed in „bet365/soap“-package?

 

Many thanks!



_______________________________________________
erlang-questions mailing list
[hidden email]
http://erlang.org/mailman/listinfo/erlang-questions
Reply | Threaded
Open this post in threaded view
|

Re: bet365/soap ignores namespace-prefix on elements of type "sequence"

Willem de Jong-2
Hello Luca,

It is hard to say what the code should do without knowing the WSDL. If you can share it with me I can take a look.

In general it is a good idea to use a tool like SoapUI to make sure that the WSDL is correct and to see some example messages.

Regards,
Willem 

2018-05-24 16:44 GMT+02:00 Luca Bormann <[hidden email]>:

Hi everyone,

 

i am using the following erlang-package to work with some WSDL-Services.

 

https://github.com/bet365/soap

 

the most part is working fine!

…but my WSDL-service expect that elements of type „sequence“ (including all sub-elements) have an existing namespace-prefix in the xml.

The problem is that the „bet365/soap“-package is ignoring this, when i try to request with the generated client.

 

Please look at my simple examples:

 

--------------------------------------------------------------------------------------

Simple Example for what is needed):

--------------------------------------------------------------------------------------

 

<soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope" xmlns:urn="urn:s:v2">

   <soap:Header/>

   <soap:Body>

      <urn:getArticles>

         <client>my-client</client>

         <articleRequest Id="99999">

 

            <!-- List 1 to 50 elements:-->

            <urn:article>

               <urn:id>1234</urn:id >

               <urn:quantity>4</urn:quantity >

            </urn:article >

 

         </articleRequest >

      </urn:getArticles >

   </soap:Body>

</soap:Envelope>

 

--------------------------------------------------------------------------------------

Simple Example for what is generated by the „bet365/soap“-package:

--------------------------------------------------------------------------------------

 

<soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope" xmlns:urn="urn:s:v2">

   <soap:Header/>

   <soap:Body>

      <urn:getArticles>

         <client>my-client</client>

         <articleRequest Id="99999">

 

            <!-- List 1 to 50 elements:-->

            <article>

               <id>1234</id >

               <quantity>4</quantity >

            </article >

 

         </articleRequest >

      </urn:getArticles >

   </soap:Body>

</soap:Envelope>

 

--------------------------------------------------------------------------------------

Can someone help?

Maybe there is an option to pass to „bet365/soap“-package when generating the client?

Maybe there is a code-change needed in „bet365/soap“-package?

 

Many thanks!



_______________________________________________
erlang-questions mailing list
[hidden email]
http://erlang.org/mailman/listinfo/erlang-questions



_______________________________________________
erlang-questions mailing list
[hidden email]
http://erlang.org/mailman/listinfo/erlang-questions