title: Spyne custom XML response
body: <p>I am using Spyne with Django CMS.
  A web service is calling my system and I want to reply with the below. 
  Can I use Spyne for customize response? Or do I have to go through models?</p>
  
  <p>Please advise.</p>
  
  <pre><code>&lt;soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"&gt;
   &lt;soapenv:Header/&gt;
   &lt;soapenv:Body&gt;
  &lt;tns:initTestQueryResponse xmlns:tns="http://test.com/interface/test/v2"
      xmlns:xs="http://www.w3.org/2001/XMLSchema"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:schemaLocation="http://test.com/interface/test/v2 testQuery.xsd"
      xmlns:v21="http://test.com/model/generic-query/v2"
      xmlns:v22="http://test.com/model/common/v2"&gt;
      &lt;tns:field key="ID" type="ID"&gt;
          &lt;v21:description lang="en"&gt;Identifier&lt;/v21:description&gt;
      &lt;/tns:field&gt;
      &lt;tns:field key="CUSTOMER_NAME" type="TEXT"&gt;
          &lt;v21:description lang="en"&gt;Customer Name&lt;/v21:description&gt;
          &lt;v21:layoutOptions bold="true" italic="false" direction="HORIZONTAL"/&gt;
      &lt;/tns:field&gt;
      &lt;tns:section key="CUSTOMER"&gt;
          &lt;v21:description lang="en"&gt;Customer&lt;/v21:description&gt;
      &lt;/tns:section&gt;
      &lt;tns:advancedQuery&gt;
          &lt;tns:criteriaGroup key="CUSTOMER" operator="OR"&gt;
              &lt;v21:criterion key="ID" /&gt;
              &lt;v21:criterion key="CUSTOMER_NAME" /&gt;
          &lt;/tns:criteriaGroup&gt;
      &lt;/tns:advancedQuery&gt;
      &lt;tns:advanceQueryPerson&gt;
          &lt;tns:criteriaGroup key="CUSTOMER" operator="OR"&gt;
              &lt;v21:criterion key="ID" /&gt;
              &lt;v21:criterion key="CUSTOMER_NAME" /&gt;
          &lt;/tns:criteriaGroup&gt;
      &lt;/tns:advanceQueryPerson&gt;
      &lt;tns:context&gt;
          &lt;v22:status&gt;OK&lt;/v22:status&gt;
      &lt;/tns:context&gt;
  &lt;/tns:initTestQueryResponse&gt;
  &lt;/soapenv:Body&gt;
  &lt;/soapenv:Envelope&gt;
  </code></pre>
  
  <p>This the request</p>
  
  <pre><code>&lt;soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"&gt;
     &lt;soapenv:Header/&gt;
     &lt;soapenv:Body&gt;
        &lt;p:initTestQueryRequest xmlns:p="http://test.com/interface/test/v2"
                               xmlns:p1="http://test.com/model/common/v2"
                               xmlns:p2="http://test.com/model/generic-query/v2"
                               xmlns:p3="http://test.com/model/test/v2"
                               xmlns:p4="http://test.com/model/service-fault/v2"
                               xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                               xsi:schemaLocation="http://test.com/interface/test/v2 ../service/test/v2/TestQuery.xsd "
                               xsi:type="anyType"/&gt;
     &lt;/soapenv:Body&gt;
  &lt;/soapenv:Envelope&gt;
  </code></pre>