在Python中将contenttype更改为application/soap+xml

2024-05-19 07:08:20 发布

您现在位置:Python中文网/ 问答频道 /正文

我继承了一个服务器,该服务器接收soap1.2消息并将其分派给另一个服务器(该服务器希望它是soap1.2)消息。问题是这篇文章是由python完成的,它是如何用content-type:text/xml发送的,尽管消息体包含1.2版的名称空间,比如。你知道吗

#modules imported
import xml.etree.ElementTree as ET
import logging
import math
import time
import importlib

#actual receiving soapMessage and posting
soapMsg = trigger.get_SoapMsg()
result,reason,data = httpConnection.request("POST",URL,soapMsg)

您能告诉我如何在v1.2中发送或至少将内容类型更改为application/soap+xml吗


Tags: textimport服务器名称modules消息分派type

热门问题