Download the PHP package lahirulhr/laravel-payhere without Composer
On this page you can find all versions of the php package lahirulhr/laravel-payhere. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download lahirulhr/laravel-payhere
More information about lahirulhr/laravel-payhere
Files in lahirulhr/laravel-payhere
Package laravel-payhere
Short Description API integration for PayHere payment gateway in Sri Lanka
License MIT
Homepage https://github.com/lahirulhr/laravel-payhere
Informations about the package laravel-payhere
Laravel PayHere

[

Laravel - PayHere was made to manage PayHere payment gateway on your laravel application with ease. currently this package supports all available methods on official PayHere documentation.
Read official Documentation for more information
Available API methods
✔️ Checkout API
✔️ Recurring API
✔️ Preapproval API
✔️ Charging API
✔️ Retrieval API
✔️ Subscription Manager API
✔️ Refund API
✔️ Authorize API
✔️ Capture API
Basic Usage
Installation
You can install the package via composer:
You can publish the config file with:
This is the contents of the published config file:
Usage
Checkout API
Checkout API lets you integrate PayHere with your website, web application or any other application in code level. It offers a simple HTML Form to initiate a payment request and redirect your customer to PayHere Payment Gateway to securely process the payment.
Handling the server callback
PayHere will be notified your application with response data using public url POST request callback. then this package will emit a new event with their callback data. you just need to listen on an event and do anything you want with payload data.
Available Events
- AuthorizeCallbackEvent
- CheckoutCallbackEvent
- PreapprovalCallbackEvent
- RecurringCallbackEvent
Example:
Recurring API
Recurring API is accept data array same as checkout API. the only things you need to change checkOut() method to recurring().
The following options are available for making adjustment to recurring period
Preapproval API
Use same as checkout method
Charging API
Charging API lets you charge your preapproved customers programatically on demand using the encrypted tokens. it will return response data array on success or return PayHereException if any error.
Retrieval API
Retrieval API lets you retrieve the details of the Successful payments processed through your PayHere
Subscription Manager
Subscription Manager API lets you view, retry & cancel your subscription customers programmatically you subscribed from Recurring API.
Refund API
Refund API lets you refund your existing payment programmatically.
Authorize API
Authorize API allows you to get your customer authorization for Hold on Card payments. this method will redirect user to payment page
Capture API
Capture API lets you capture your authorized Hold on Card payments programmatically on demand using the authorization tokens you retrieved from Payment Authorize API.
TODO
- [x]
Events for server callbacks - [ ] Custom payment redirection page
- [ ] Custom Error types
- [ ] Response Data Objects
- [ ] Optional Data handling
- [ ] Inbuilt subscription database
- [ ] Server callback log
Testing
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security Vulnerabilities
Please review our security policy on how to report security vulnerabilities.
Credits
- LaHiRu
- All Contributors
License
The MIT License (MIT). Please see License File for more information.
All versions of laravel-payhere with dependencies
guzzlehttp/guzzle Version ^7.8
illuminate/contracts Version ^9.0|^10.0|^11.0
spatie/laravel-package-tools Version ^1.9.2