0

私はこのスキームを持っています:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:tns="tns" xmlns:nam="https://iotchet.ru/namespases">
   <soapenv:Header>
      <tns:RequestHeader>
         <!--Optional:-->
         <tns:sessionkey>b01daba7289e4e8baa87dbd1eb8c4f6b</tns:sessionkey>
      </tns:RequestHeader>
   </soapenv:Header>
   <soapenv:Body>
      <tns:SendContainer>
         <!--Optional:-->
         <tns:Container>
            <nam:name>test</nam:name>
            <nam:content></nam:content>
         </tns:Container>
      </tns:SendContainer>
   </soapenv:Body>
</soapenv:Envelope>

ここで私は要求します:

from pysimplesoap.client import SoapClient

client = SoapClient(wsdl='http://localhost:5555/api/containerize?wsdl')
client.SendContainer(Container={'name': 'test', 'content': 'test'})

クライアント要求にヘッダーを追加する方法が見つかりません。

4

1 に答える 1