Open RecNes opened 2 years ago
Zeep library is generating string arrays with each child tag has it's own namespace definition:
<ns1:Images> <ns2:string xmlns:ns2="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> https://www.example.com/variant_image.png </ns2:string> <ns3:string xmlns:ns3="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> https://www.example.com/variant_image2.png </ns3:string> <ns4:string xmlns:ns4="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> https://www.example.com/variant_image3.png </ns4:string> </ns1:Images>
But, the API I'm dealing with is strictly want the namespace of the array must be defined on parent tag and, same namespace must be used on each child tag. Eg.
<ns1:Images xmlns:ns2="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <ns2:string>https://www.siteniz.com/variant_image.png</ns2:string> <ns2:string>https://www.siteniz.com/variant_image2.png</ns2:string> <ns2:string>https://www.siteniz.com/variant_image3.png</ns2:string> </ns1:Images>
Is there a way to force the zeep to generate string array XML like the format above?
Zeep library is generating string arrays with each child tag has it's own namespace definition:
But, the API I'm dealing with is strictly want the namespace of the array must be defined on parent tag and, same namespace must be used on each child tag. Eg.
Is there a way to force the zeep to generate string array XML like the format above?