10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
# File 'lib/active_merchant_payline/integration/lib/web_payment.rb', line 10
def authorize
xml= Builder::XmlMarkup.new
xml.instruct!
xmlns= {
'xmlns:soapenv' => 'http://schemas.xmlsoap.org/soap/envelope/',
'xmlns:impl' => 'http://impl.ws.payline.experian.com',
'xmlns:obj' => 'http://obj.ws.payline.experian.com'
}
xml.tag! "soapenv:Envelope", xmlns do
xml.tag! "soapenv:Header"
xml.tag! "soapenv:Body" do
do_web_payment_envelope(xml)
end
end
http= Net::HTTP.new('https://homologation.payline.com/', 443)
http.use_ssl= true
path= 'V4/services/DirectPaymentAPI'
data= xml.target!
resp, data = http.post(path, data)
puts resp.inspect
puts data.inspect
end
|