Skip to content

Instantly share code, notes, and snippets.

@jedie
Created February 20, 2019 12:50
Show Gist options
  • Save jedie/41aa1f7ea5afe200cde8a71f4e7172bc to your computer and use it in GitHub Desktop.
Save jedie/41aa1f7ea5afe200cde8a71f4e7172bc to your computer and use it in GitHub Desktop.
"GET /checkout/ HTTP/1.1" 302 0
"GET /checkout/shipping-address/ HTTP/1.1" 200 16093
"POST /checkout/shipping-address/ HTTP/1.1" 302 0
"GET /checkout/shipping-method/ HTTP/1.1" 302 0
"GET /checkout/payment-method/ HTTP/1.1" 200 5257
"POST /checkout/payment-method/ HTTP/1.1" 302 0
"GET /checkout/payment-details/ HTTP/1.1" 200 4084
"GET /checkout/preview/ HTTP/1.1" 200 11707
Order #100004: beginning submission process for basket #4
opening (https://test.docdatapayments.com/ps/services/paymentservice/1_3?wsdl)
opening (https://test.docdatapayments.com:443/ps/services/paymentservice/1_3?xsd=1)
sending:
URL: https://test.docdatapayments.com:443/ps/services/paymentservice/1_3
HEADERS: {'Content-Type': 'text/xml; charset=utf-8', 'SOAPAction': b'"create"', 'Content-type': 'text/xml; charset=utf-8', 'Soapaction': b'"create"'}
MESSAGE:
b'<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns0="http://www.docdatapayments.com/services/paymentservice/1_3/" xmlns:ns1="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP-ENV:Header/>
<ns1:Body>
<ns0:createRequest version="1.3">
<ns0:merchant name="foobar-foobar" password="foobar"/>
<ns0:merchantOrderReference>100024</ns0:merchantOrderReference>
<ns0:paymentPreferences>
<ns0:profile>test</ns0:profile>
<ns0:numberOfDaysToPay>7</ns0:numberOfDaysToPay>
</ns0:paymentPreferences>
<ns0:shopper id="1">
<ns0:name>
<ns0:first>-</ns0:first>
<ns0:last>-</ns0:last>
</ns0:name>
<ns0:email>test@example.tld</ns0:email>
<ns0:language code="en"/>
<ns0:gender>U</ns0:gender>
</ns0:shopper>
<ns0:totalGrossAmount currency="EUR">498</ns0:totalGrossAmount>
<ns0:billTo>
<ns0:name>
<ns0:first>Hans</ns0:first>
<ns0:last>Muster</ns0:last>
</ns0:name>
<ns0:address>
<ns0:street>Examplestreet 1</ns0:street>
<ns0:houseNumber>N/A</ns0:houseNumber>
<ns0:postalCode>1234AB</ns0:postalCode>
<ns0:city>Examplecity</ns0:city>
<ns0:country code="NL"/>
</ns0:address>
</ns0:billTo>
<ns0:includeCosts>false</ns0:includeCosts>
<ns0:invoice>
<ns0:totalNetAmount currency="EUR">498</ns0:totalNetAmount>
<ddp:totalVatAmount xmlns:ddp="http://www.docdatapayments.com/services/paymentservice/1_3/" rate="0" currency="EUR">0</ddp:totalVatAmount>
<ns0:item number="5">
<ns0:name>Reviewing Java</ns0:name>
<ns0:code>9780557043552</ns0:code>
<ddp:quantity xmlns:ddp="http://www.docdatapayments.com/services/paymentservice/1_3/" unitOfMeasure="PCS">1</ddp:quantity>
<ns0:description>A simple Java review book and your best guide to learning Java programming. This book covers the ...</ns0:description>
<ns0:netAmount currency="EUR">199</ns0:netAmount>
<ns0:grossAmount currency="EUR">199</ns0:grossAmount>
<ns0:vat rate="0">
<ns0:amount currency="EUR">0</ns0:amount>
</ns0:vat>
<ns0:totalNetAmount currency="EUR">199</ns0:totalNetAmount>
<ns0:totalGrossAmount currency="EUR">199</ns0:totalGrossAmount>
<ns0:totalVat rate="0">
<ns0:amount currency="EUR">0</ns0:amount>
</ns0:totalVat>
</ns0:item>
<ns0:item number="6">
<ns0:name>Expert C Programming</ns0:name>
<ns0:code>9780131774292</ns0:code>
<ddp:quantity xmlns:ddp="http://www.docdatapayments.com/services/paymentservice/1_3/" unitOfMeasure="PCS">1</ddp:quantity>
<ns0:description>Deep C Secrets Peter van der Linden. #include &lt;setjmp.h&gt; banana ( ) { printf ( &quot; in banana ( ) ...</ns0:description>
<ns0:netAmount currency="EUR">299</ns0:netAmount>
<ns0:grossAmount currency="EUR">299</ns0:grossAmount>
<ns0:vat rate="0">
<ns0:amount currency="EUR">0</ns0:amount>
</ns0:vat>
<ns0:totalNetAmount currency="EUR">299</ns0:totalNetAmount>
<ns0:totalGrossAmount currency="EUR">299</ns0:totalGrossAmount>
<ns0:totalVat rate="0">
<ns0:amount currency="EUR">0</ns0:amount>
</ns0:totalVat>
</ns0:item>
<ns0:shipTo>
<ns0:name>
<ns0:first>Hans</ns0:first>
<ns0:last>Muster</ns0:last>
</ns0:name>
<ns0:address>
<ns0:street>Examplestreet 1</ns0:street>
<ns0:houseNumber>N/A</ns0:houseNumber>
<ns0:postalCode>1234AB</ns0:postalCode>
<ns0:city>Examplecity</ns0:city>
<ns0:country code="NL"/>
</ns0:address>
</ns0:shipTo>
</ns0:invoice>
<ns0:integrationInfo>
<ns0:webshopPlugin>django-oscar-docdata</ns0:webshopPlugin>
<ns0:webshopPluginVersion>1.3.0</ns0:webshopPluginVersion>
<ns0:programmingLanguage>Python</ns0:programmingLanguage>
</ns0:integrationInfo>
</ns0:createRequest>
</ns1:Body>
</SOAP-ENV:Envelope>'
received:
CODE: HTTPStatus.OK
HEADERS: Date: Wed, 20 Feb 2019 10:50:28 GMT
Server: Apache
Vary: Accept-Encoding
Connection: close
Transfer-Encoding: chunked
Content-Type: text/xml;charset=utf-8
Set-Cookie: SESSPERSIST=00|XG0w9; path=/; HttpOnly; Secure
MESSAGE:
b'<?xml version='1.0' encoding='UTF-8'?><S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"><S:Body><createResponse xmlns="http://www.docdatapayments.com/services/paymentservice/1_3/" ddpXsdVersion="1.3.14"><createSuccess><success code="SUCCESS">Operation successful.</success><key>A26A593801CF5FEBD8A6A084282F6238</key></createSuccess></createResponse></S:Body></S:Envelope>'
Sending alerts for 'Reviewing Java'
Sent 0 notifications and 0 messages
Sending alerts for 'Expert C Programming'
Sent 0 notifications and 0 messages
Order #100004: redirecting to https://test.docdatapayments.com/ps/menu?command=show_payment_cluster&payment_cluster_key=A26A593801CF5FEBD8A6A084282F6238&merchant_name=foobar-foobar&return_url_success=http%3A%2F%2F127.0.0.1%3A8000%2Fapi%2Fdocdata%2Freturn%2F%3Fcallback%3DSUCCESS%26order_id%3DA26A593801CF5FEBD8A6A084282F6238&return_url_pending=http%3A%2F%2F127.0.0.1%3A8000%2Fapi%2Fdocdata%2Freturn%2F%3Fcallback%3DPENDING%26order_id%3DA26A593801CF5FEBD8A6A084282F6238&return_url_canceled=http%3A%2F%2F127.0.0.1%3A8000%2Fapi%2Fdocdata%2Freturn%2F%3Fcallback%3DCANCELLED%26order_id%3DA26A593801CF5FEBD8A6A084282F6238&return_url_error=http%3A%2F%2F127.0.0.1%3A8000%2Fapi%2Fdocdata%2Freturn%2F%3Fcallback%3DERROR%26order_id%3DA26A593801CF5FEBD8A6A084282F6238&client_language=EN-US&default_pm=PAYPAL_EXPRESS_CHECKOUT
"POST /checkout/preview/ HTTP/1.1" 302 0
Returned from Docdata for A26A593801CF5FEBD8A6A084282F6238, callback: ERROR
sending:
URL: https://test.docdatapayments.com:443/ps/services/paymentservice/1_3
HEADERS: {'Content-Type': 'text/xml; charset=utf-8', 'SOAPAction': b'"status"', 'Content-type': 'text/xml; charset=utf-8', 'Soapaction': b'"status"'}
MESSAGE:
b'<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns0="http://www.docdatapayments.com/services/paymentservice/1_3/" xmlns:ns1="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP-ENV:Header/>
<ns1:Body>
<ns0:statusRequest version="1.3">
<ns0:merchant name="foobar-foobar" password="foobar"/>
<ns0:paymentOrderKey>A26A593801CF5FEBD8A6A084282F6238</ns0:paymentOrderKey>
<ns0:integrationInfo>
<ns0:webshopPlugin>django-oscar-docdata</ns0:webshopPlugin>
<ns0:webshopPluginVersion>1.3.0</ns0:webshopPluginVersion>
<ns0:programmingLanguage>Python</ns0:programmingLanguage>
</ns0:integrationInfo>
</ns0:statusRequest>
</ns1:Body>
</SOAP-ENV:Envelope>'
received:
CODE: HTTPStatus.OK
HEADERS: Date: Wed, 20 Feb 2019 10:50:29 GMT
Server: Apache
Vary: Accept-Encoding
Connection: close
Transfer-Encoding: chunked
Content-Type: text/xml;charset=utf-8
Set-Cookie: SESSPERSIST=00|XG0w+; path=/; HttpOnly; Secure
MESSAGE:
b'<?xml version='1.0' encoding='UTF-8'?><S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"><S:Body><statusResponse xmlns="http://www.docdatapayments.com/services/paymentservice/1_3/" ddpXsdVersion="1.3.14"><statusSuccess><success code="SUCCESS">Operation successful.</success><report><approximateTotals exchangedTo="EUR" exchangeRateDate="2019-02-20 11:50:29"><totalRegistered>498</totalRegistered><totalShopperPending>0</totalShopperPending><totalAcquirerPending>0</totalAcquirerPending><totalAcquirerApproved>0</totalAcquirerApproved><totalCaptured>0</totalCaptured><totalRefunded>0</totalRefunded><totalChargedback>0</totalChargedback><totalReversed>0</totalReversed></approximateTotals><consideredSafe><value>false</value><level>SAFE</level></consideredSafe><apiInformation conversionApplied="false"><originalVersion>1.3</originalVersion></apiInformation></report></statusSuccess></statusResponse></S:Body></S:Envelope>'
sending:
URL: https://test.docdatapayments.com:443/ps/services/paymentservice/1_3
HEADERS: {'Content-Type': 'text/xml; charset=utf-8', 'SOAPAction': b'"cancel"', 'Content-type': 'text/xml; charset=utf-8', 'Soapaction': b'"cancel"'}
MESSAGE:
b'<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns0="http://www.docdatapayments.com/services/paymentservice/1_3/" xmlns:ns1="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP-ENV:Header/>
<ns1:Body>
<ns0:cancelRequest version="1.3">
<ns0:merchant name="foobar-foobar" password="foobar"/>
<ns0:paymentOrderKey>A26A593801CF5FEBD8A6A084282F6238</ns0:paymentOrderKey>
</ns0:cancelRequest>
</ns1:Body>
</SOAP-ENV:Envelope>'
received:
CODE: HTTPStatus.OK
HEADERS: Date: Wed, 20 Feb 2019 10:50:29 GMT
Server: Apache
Vary: Accept-Encoding
Connection: close
Transfer-Encoding: chunked
Content-Type: text/xml;charset=utf-8
MESSAGE:
b'<?xml version='1.0' encoding='UTF-8'?><S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"><S:Body><cancelResponse xmlns="http://www.docdatapayments.com/services/paymentservice/1_3/" ddpXsdVersion="1.3.14"><cancelSuccess><success code="SUCCESS">Operation successful.</success><result>NO_PAYMENTS</result></cancelSuccess></cancelResponse></S:Body></S:Envelope>'
sending:
URL: https://test.docdatapayments.com:443/ps/services/paymentservice/1_3
HEADERS: {'Content-Type': 'text/xml; charset=utf-8', 'SOAPAction': b'"status"', 'Content-type': 'text/xml; charset=utf-8', 'Soapaction': b'"status"'}
MESSAGE:
b'<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns0="http://www.docdatapayments.com/services/paymentservice/1_3/" xmlns:ns1="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP-ENV:Header/>
<ns1:Body>
<ns0:statusRequest version="1.3">
<ns0:merchant name="foobar-foobar" password="foobar"/>
<ns0:paymentOrderKey>A26A593801CF5FEBD8A6A084282F6238</ns0:paymentOrderKey>
<ns0:integrationInfo>
<ns0:webshopPlugin>django-oscar-docdata</ns0:webshopPlugin>
<ns0:webshopPluginVersion>1.3.0</ns0:webshopPluginVersion>
<ns0:programmingLanguage>Python</ns0:programmingLanguage>
</ns0:integrationInfo>
</ns0:statusRequest>
</ns1:Body>
</SOAP-ENV:Envelope>'
received:
CODE: HTTPStatus.OK
HEADERS: Date: Wed, 20 Feb 2019 10:50:29 GMT
Server: Apache
Vary: Accept-Encoding
Connection: close
Transfer-Encoding: chunked
Content-Type: text/xml;charset=utf-8
MESSAGE:
b'<?xml version='1.0' encoding='UTF-8'?><S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"><S:Body><statusResponse xmlns="http://www.docdatapayments.com/services/paymentservice/1_3/" ddpXsdVersion="1.3.14"><statusSuccess><success code="SUCCESS">Operation successful.</success><report><approximateTotals exchangedTo="EUR" exchangeRateDate="2019-02-20 11:50:29"><totalRegistered>498</totalRegistered><totalShopperPending>0</totalShopperPending><totalAcquirerPending>0</totalAcquirerPending><totalAcquirerApproved>0</totalAcquirerApproved><totalCaptured>0</totalCaptured><totalRefunded>0</totalRefunded><totalChargedback>0</totalChargedback><totalReversed>0</totalReversed></approximateTotals><consideredSafe><value>false</value><level>SAFE</level></consideredSafe><apiInformation conversionApplied="false"><originalVersion>1.3</originalVersion></apiInformation></report></statusSuccess></statusResponse></S:Body></S:Envelope>'
Payment cluster A26A593801CF5FEBD8A6A084282F6238 status changed new -> cancelled
"GET /api/docdata/return/?callback=ERROR&order_id=A26A593801CF5FEBD8A6A084282F6238 HTTP/1.1" 302 0
INFO:django.server:"GET /api/docdata/return/?callback=ERROR&order_id=A26A593801CF5FEBD8A6A084282F6238 HTTP/1.1" 302 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment