Server Integration for PHP
PayKun offers plugins for the payment gateway integration in PHP. You can avail of our free integration assistance and easily integrate PayKun to start accepting online payments.
The advantages of choosing the PayKun plugin for the payment gateway integration in PHP include multiple online payment options, excellent checkout experience, high level of security compliances, high transaction success rate, etc.
This article will provide the steps to implement PayKun Payment Gateway Integration in PHP. It is very easy, you simply need to copy-paste and change according to your requirement.
Requirements for PHP Checkout
- Merchant ID
- Access Token Key
- API Secret Key
- PHP v5.3 or higher
Installation can be done using the following composer code or the required zip file. After that include **Payment.php** in your application and you can use the API as usual.
If your project uses composer, run the below command
composer require paykun/checkout
ZIP File download
- You can download the zip file from the below-given link if you are not using the composer code PayKun_PHP_zip file
- Unzip the given file
- Include Payment.php, Validator.php & Crypto.php in your project.
[ Note: If you are using any framework or you have autoloaded set up in your project then you don’t have to include these files manually]
TEST (Sandbox) MODE GENERATING / API ENCRYPTION KEY GUIDE
In order to activate the test Mode, first, follow the below-given steps for generating test mode credentials.
- Click on your profile picture then select test mode.
- And click on your active sandbox account.
- Copy your password.
- Click on the sandbox login.
- And then you will be redirected to the Sandbox Mode, then after you may generate your credentials as it is in live mode.
- Copy your Merchant ID which you will get by clicking on your profile picture
- Then go to the Settings Tab.
- Go to the Security Option.
- Click on Generate API Key and download your Access Token and Encryption Key(API Secret Key).
If you have generated an API key before then you will see the date of the API key generate, since you will not be able to retrieve the old API key (For security reasons) we have provided the re-generate option, so you can re-generate the API key in case you have lost the old one.
Note: Once you re-generate the API key your old API key will stop working immediately. So be cautious while using this option.
License: The PayKun PHP SDK is released under the MIT License.
Note – We provide API for fetching order detail, due to security concerns, and we call webhook for order detail.
Visit: PHP – Documentation for the Payment Gateway Integration in PHP