def email_direct_envelope(options, &block)
      xsd = 'http://www.w3.org/2001/XMLSchema'
      env = 'http://schemas.xmlsoap.org/soap/envelope/'
      xsi = 'http://www.w3.org/2001/XMLSchema-instance'
      data = options.clone
      data.delete(:method)
      data = data.to_xml(:skip_instruct => true, :skip_types => true).gsub("<hash>\n",'').gsub("</hash>\n",'')
      xml = Builder::XmlMarkup.new
      xml.env(:Envelope, 'xmlns:xsd' => xsd, 'xmlns:env' => env, 'xmlns:xsi' => xsi) do
        xml.env(:Body) do
          xml.__send__(options[:method].to_sym, 'xmlns' => self.target_namespace) do
            add_credentials!(xml)
            xml << data
          end
        end
      end
      raw = xml.target!
      raw = raw.gsub('<ai/>','')
      yield(raw) if block_given?
      raw
    end
def email_direct_envelope(options, &block)
      xsd = 'http://www.w3.org/2001/XMLSchema'
      env = 'http://schemas.xmlsoap.org/soap/envelope/'
      xsi = 'http://www.w3.org/2001/XMLSchema-instance'
      data = options.clone
      data.delete(:method)
      data = data.to_xml(:skip_instruct => true, :skip_types => true).gsub("<hash>\n",'').gsub("</hash>\n",'')
      xml = Builder::XmlMarkup.new
      xml.env(:Envelope, 'xmlns:xsd' => xsd, 'xmlns:env' => env, 'xmlns:xsi' => xsi) do
        xml.env(:Body) do
          xml.__send__(options[:method].to_sym, 'xmlns' => self.target_namespace) do
            add_credentials!(xml)
            xml << data
          end
        end
      end
      raw = xml.target!
      raw = raw.gsub('<ai/>','')
      yield(raw) if block_given?
      raw
    end
same as ServiceProxy email_direct_envelope method, except:
 1) inject options hash directly
 2) yields the raw xml (for incompatible activesupport style of array to xml)
    a hash with {"Lists" => [{:int => 1}, {:int => 2}]} will yields xml <Lists><List><int>1</int><List><int>2</int></Lists>
 3) replace strange </ai> in generated xml