Sample code

Paystation have integration options available for PHP, C#, ASP, and Node, and provide support for both fully hosted (3 party) and merchant hosted (2 party) processing.  

Please note that merchant hosted processing requires PCI compliance and bank approval.

You can download the appropriate sample code below. If required, full API documentation is available from the Paystation APIs site. The code samples on this page show how to initiate a payment with Paystation, and how to interpret our response. We assume that you have sufficient knowledge on how to store orders and customer details in a database before initiating the payment request, and are able to tie our response back to that request.

Be sure to generate a unique MS (Merchant Session) value for each payment attempt. The usual situation where this catches people out is when a payment attempt returns with an error and another attempt is made to pay for the same order. In our view this is a new and different payment and requires a new MS value.

3 party hosted sample code

3 party hosted API documents are available from the Paystation APIs page.

 

Back to Top