3.31. /view-invoice-xml

Introduction

To start Swift transaction use /api/v2/auth-cash/ and get receipt-id in order status response. Swift invoice in XML is initiated through HTTPS GET request by using URLs specified below. Use HMAC-SHA1 for authentication. See Statuses.

API URLs

Integration

Production

https://sandbox.goldenapple.com.cy/paynet/view-invoice-xml/ENDPOINTID/RECEIPTID

https://gate.goldenapple.com.cy/paynet/view-invoice-xml/ENDPOINTID/RECEIPTID

Request Example

POST /paynet/view-invoice-xml/6657/6d0442b3-f4f9-3264-8cfd-f811195b693a HTTP/1.1
Host: sandbox.goldenapple.com.cy
User-Agent: curl/7.83.0
Accept: */*
Authorization: OAuth realm="",oauth_version="1.0",oauth_consumer_key="test_merch",oauth_timestamp="1687422393",oauth_nonce="I4FlRMNDFfe",oauth_signature_method="HMAC-SHA1",oauth_signature="sW7XXVhkxXAwE61CLnwCpjxJpD0%3D"
Content-Length: 140
Content-Type: application/x-www-form-urlencoded
Connection: close

oauth_consumer_key=test_merch
&oauth_nonce=I4FlRMNDFfe
&oauth_signature_method=HMAC-SHA1
&oauth_timestamp=1687422393
&oauth_version=1.0

Success Response Example

HTTP/1.1 200
Server: server
Date: Thu, 22 Jun 2023 08:26:51 GMT
Content-Type: text/xml;charset=utf-8
Content-Length: 833
Connection: close
X-XSS-Protection: 1
Strict-Transport-Security: max-age=31536000
Strict-Transport-Security: max-age=31536000

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<root>
<pdf_template_name>swift_local.xslt</pdf_template_name>
<additional_params/>
<date>22.06.2023</date>
<bank_name>TestBank</bank_name>
<bank_address>Lima, Peru</bank_address>
<company_name>Company</company_name>
<company_address>P. Sherman 42 Wallaby way</company_address>
<iban>1122334455</iban>
<swift>123IAMS123</swift>
<customer>
<firstname>John</firstname>
<lastname>Smith</lastname>
<address>98102, United States, WA, Seattle, 100 Main st</address>
<phone>12063582043</phone>
<cell_phone>19023384543</cell_phone>
</customer>
<rate>1</rate>
<quantity>1</quantity>
<currency>EUR</currency>
<amount>10</amount>
<order_desc>Test Order Description</order_desc>
<invoice_no>6657-587</invoice_no>
<order_invoice_no>902B4FF5</order_invoice_no>
<reference_id>1</reference_id>
</root>

Fail Response Example

HTTP/1.1 404
Server: server
Date: Thu, 22 Jun 2023 08:30:18 GMT
Content-Type: text/xml;charset=utf-8
Content-Length: 750
Connection: close
X-XSS-Protection: 1
Strict-Transport-Security: max-age=31536000

...
<body>
    <p>Sorry, that page doesn't exist!</p>
</body>

Postman Collection

Request Builder

HTTP method
endpointId
receiptId
version
consumer key
consumer secret
timestamp

nonce

signature method

normalized parameters
signature base string
signature
authorization header