2

I am trying to call service PushConstContractParcels of a wsdl soap service the problem is that I don't know how to send schema parameter in zeep package

<s:element name="PushConstContractParcels">
 <s:complexType>
  <s:sequence>
    <s:element minOccurs="0" maxOccurs="1" name="ConstContractDT">
     <s:complexType>
      <s:sequence>
       <s:element ref="s:schema"/>
       <s:any/>
  </s:sequence>
 </s:complexType>
</s:element>
    <s:element minOccurs="0" maxOccurs="1" name="ContractCode" type="s:string"/>
    <s:element minOccurs="0" maxOccurs="1" name="Password" type="s:string"/>
   </s:sequence>
 </s:complexType>
</s:element>

here is the element and its variables

ns0:PushConstContractParcels(ConstContractDT: {schema: , _value_1: ANY}, ContractCode: xsd:string, Password: xsd:string)

and this is my code in order to get the result

dataset = [settings.POST_CONTRACT_NUMBER, '1233333333', settings.POST_NODE_CODE, 1, False, 'ali', 'gholi',
               '1371/7/02', '16:22', None, None, None, None, None]

client = Client(settings.POST_CONTRACT_URL)

response = client.service.PushConstContractParcels(dataset, Contractcode, password)

I don't realize how to send {schema: , _value_1: ANY} variable as the parameter in the client.service. I also used (xsd:any) any object in zeep but I think it is not appropriate

Amir Naimi
  • 133
  • 3
  • 13
  • can you add the error message when you send the request. Also you can check the created request-xml when you acitvate the logging. This way you can see how the sent request changes when you change your input. https://stackoverflow.com/questions/40367295/get-data-from-soap-envelope-zeep – jan-seins May 02 '18 at 13:55

0 Answers0