PAY.Link
Endpoints

Sandbox
POST https://base.merchantwarrior.com/paylink/ Copy

Production
POST https://api.merchantwarrior.com/paylink/ Copy

Introduction

The Merchant Warrior MWPAY.Link service enables you to generate a unique payment link that when accessed will allow your customer to complete a payment via a secure Hosted Payment Page.

Each MWPAY.Link that is generated will have a unique code attached to it. You can also link your own internal Reference ID to a unique code in order to reconcile transactions that take place via a unique payment link. The MWPAY.Link service can also notify your systems in real-time after a customer has completed a payment.

MWPAY.Link URLs are useful for scenarios such as sending bills via email and/or SMS, e-invoices, donations etc.

You will need to obtain a Merchant UUID, API Key and API passphrase in order to use this feature. These details will be issued to you when you create your MW account.

Generate PayLink

This method details how to generate a unique payment link

Required Parameters

Parameter Description
merchantUUID

The value of this parameter is provided to you by Merchant Warrior.
Example: 123456789abcd

apiKey

The value of this parameter is provided to you by Merchant Warrior.
Example: 1a3b5c

transactionAmount

The amount must be formatted to have two decimal places. Any amounts without two decimal places or amounts less than one cent will be rejected.
Example: 10.00

transactionCurrency

One of the following: AUD, CAD, EUR, GBP, JPY, NZD, SGD, USD. This is provider dependant. Please check with MW before attempting to process transactions in any currency other than AUD. This field is case insensitive.
Example: AUD

transactionProduct

A product (or sale) id or description. We recommend using an order/product id. This field's primary purpose is to help the transaction be identifiable for reporting and accounting purposes.
Example: ABC4321
Valid length: Up to 255 characters. Some Acquirers limit this field to 40 characters.

returnURL

The customer will be redirected to this URL upon completion of the transaction. This parameter can also be hardcoded via the merchant administration interface.
Example: https://www.example.com/return.php

notifyURL

Asynchronous POST notifications will be sent to this URL. This parameter can also be hardcoded via the merchant administration interface.
Example: https://www.example.com/notify.php

urlHash

The urlHash field is a combination of your API Passphrase, and specific parameters sent in the transaction. It must be specified if you specify either returnURL or notifyURL. See Web URL Hash for information on how to construct the hash correctly.
Example: 511999e54b9ad51ce4c28d7f0550ac81
Valid Length: 32 characters

hash

The verification hash is a combination of the MD5 of your API Passphrase, and specific parameters sent in the transaction. See Transaction Type Hash for information on how to construct the hash correctly.
Example: e9ddc296b76b3398934bfc06239073df
Valid length: 32 characters

Optional Parameters

Parameter Description
referenceText

This parameter is used to describe the order/product ID or reference. It will be placed next to the transactionProduct mentioned above in the payment page.
Example: Booking #
Valid length: Up to 50 characters

linkReferenceID

This is a merchant's unique reference ID that can be used to match a uniqueCode with a merchant's internal reference ID.
Example: A257240023321
Valid length: Up to 40 characters

expiry

The expiration of the unique payment link. This paramater should be formatted as a DateTime (yyyy-mm-dd hh:mm:ss). By default the unique payment link will expire after 7 days.
Example: 2017-05-01 17:45:12

sendEmail

This value is a boolean denoting whether to automatically send an email to the customer with the unique payment link
Example: 1

reminderFrequency

How often to send a reminder email to the customer if the unique payment link is unpaid. Reminder emails will only be sent if the sendEmail parameter was set to true. If this value is not set, or 0, no reminder emails will be sent
Example: 7

customerName

This field can only contain alphanumeric characters, as well as the full stop, comma, apostrophe, ampersand, space and hyphen characters.
Example: Mr. Example Person
Valid length: Between 2 and 255 characters

customerCountry

Two letter ISO 3166-1 alpha-2 country code.
Example: AU
Valid length: 2 characters

customerState

Freeform field, keep consistent for your records and reporting.
Example: Queensland
Valid length: Up to 75 characters

customerCity

Freeform field, keep consistent for your records and reporting.
Example: Brisbane
Valid length: Up to 75 characters

customerAddress

Freeform field.
Example: 123 Test Street
Valid length: Up to 255 characters

customerPostCode

This can also accomodate ZIP/Post codes for international transactions.
Example: 4000
Valid length: Between 4 and 10 characters

customerPhone

Anything other than +,-, space and 0-9 will be stripped.
Example: 0401234567 or 61731234567
Valid length: Up to 25 characters

customerEmail

Must be valid if present. Sending this optional parameter is highly recommended.
Example: [email protected]
Valid length: Up to 255 characters

custom1

Freeform field.
Valid length: Up to 500 characters

custom2

Freeform field.
Valid length: Up to 500 characters

custom3

Freeform field.
Valid length: Up to 500 characters