Previous topic

Json

Next topic

MessagePack

This Page

Soap 1.1

The spyne.protoco.soap.soap11 module contains the implementation of a subset of the Soap 1.1 standard.

Except the binary optimizations that mostly do not work, this protocol is production quality.

Initially released in soaplib-0.8.0.

class spyne.protocol.soap.soap11.Soap11(app=None, validator=None, wrapped=True, xml_declaration=True, cleanup_namespaces=False)[source]

Bases: spyne.protocol.xml._base.XmlDocument

The base implementation of a subset of the Soap 1.1 standard. The document is available here: http://www.w3.org/TR/soap11/

Parameters:
  • app – A spyne.application.Application instance.
  • validator – The validator to use. Currently the only supported value is ‘lxml’
  • wrapped – Whether the return type should be wrapped in another object. Default is ‘True’.
  • xml_declaration – Whether to add xml_declaration to the responses Default is ‘True’.
  • cleanup_namespaces – Whether to add clean up namespace declarations in the response document. Default is ‘False’.
allowed_http_verbs = ['POST']
create_in_document(ctx, charset=None)[source]
decompose_incoming_envelope(ctx, message=<class 'spyne.protocol._base.Request'>)[source]
deserialize(ctx, message)[source]

Takes a MethodContext instance and a string containing ONE soap message. Returns the corresponding native python object

Not meant to be overridden.

fault_to_http_response_code(fault)[source]
mime_type = 'text/xml; charset=utf-8'
serialize(ctx, message)[source]

Uses ctx.out_object, ctx.out_header or ctx.out_error to set ctx.out_body_doc, ctx.out_header_doc and ctx.out_document as an lxml.etree._Element instance.

Not meant to be overridden.

wrapped[source]
spyne.protocol.soap.soap11.resolve_hrefs(element, xmlids)[source]