1. Create a LinkPay link in the merchant portal
2. Enable fields which you want to use and mark them as “URL Changeable”

3. Save
4. Add parameters to the code which will change this data automatically.

<?php
$linkpay_prefix = 'https://igw-demo.every-pay.com/lp'; // LinkPay URL
$api_secret = 'apisecret123456789'; //API SECRET FROM GENERAL SETTINGS
$params = [ //BELOW ADD ALL PARAMETERS WHICH YOU ENABLED UNDER LINKPAY LINK AND DATA
'transaction_amount' => '10',
'customer_name' => 'Your Customer Name',
'customer_email' => 'customer@email.com',
'order_reference' => 'YourOrderReference',
'linkpay_token' => '123abcd' //LINKPAY TOKEN FROM THE LINK
];
$query = http_build_query($params);

$query = str_replace("+","%20",$query);
$hmac = hash_hmac('sha256', $query, $api_secret);
$url = "${linkpay_prefix}?${query}&hmac=${hmac}";
echo $url;# outputs:
#

5. Generate a link.
6. Send it to your Customer

Information about how to integrate callback for LinkPay you can find here.

 

in Integration
Did this article answer your question?