If you choose our REST API instead of the Secure Form, you’ll probably want to accept payments on your own website and improve the purchasing experience. This means you may have to collect some information from customers and pass it to PayLane along with a payment request.
Most of the information required to send a payment request doesn’t have to be collected from the customer – at least not every time. For example customer information (name, email, address) can be retrieved from your database – assuming that you allow customers to create accounts on your site (e-store, web-app).
Also data such as the sale information (amount, currency, description) can be generated or retrieved automatically; however, it is a good practice to display such info on the payment screen. This way the customer will be assured that they’re paying the correct amount.
Payment methods
Depending on the selected payment method you may have to collect some information from the customer during the payment process.
In the most common situation you will present an HTML form for the customer to fill. After the form is submitted, you just send a request to PayLane systems.
Examples
In most cases cards will require providing card information and direct debits will require account information.
Standard payment forms for these payment methods may look like this:
Cards:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | <form action="#" id="payment-form" method="post"> <label>Card number:</label> <input type="text" id="card_number" name="card[card_number]" size="19" /> <label>Name on card:</label> <input type="text" id="name_on_card" name="card[name_on_card]" size="50" /> <label>Expiration date:</label> <input type="text" id="expiration_month" name="card[expiration_month]" size="2" /> <input type="text" id="expiration_year" name="card[expiration_year]" size="4" /> <label>CVV/CVC number:</label> <input type="text" id="card_code" name="card[card_code]" size="4" /> <button type="submit">Pay with PayLane</button> </form> |
Direct Debits:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | <form action="#" id="payment-form" method="post"> <label>Account number:</label> <input type="text" id="account_number" name="account[account_number]" size="11" /> <label>Account holder:</label> <input type="text" id="account_holder" name="account[account_holder]" size="30"/> <label>Account country:</label> <input type="text" id="account_country" name="account[account_country]" size="2" /> <label>Bank code:</label> <input type="text" id="bank_code" name="account[bank_code]" size="8" /> <button type="submit">Pay with PayLane</button> </form> |