Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/md-aamroni/paypal
PayPal API Payment in Laravel
https://github.com/md-aamroni/paypal
paypal paypal-checkout paypal-rest-api
Last synced: 5 days ago
JSON representation
PayPal API Payment in Laravel
- Host: GitHub
- URL: https://github.com/md-aamroni/paypal
- Owner: md-aamroni
- License: mit
- Created: 2024-04-01T15:10:02.000Z (10 months ago)
- Default Branch: master
- Last Pushed: 2024-04-01T19:46:51.000Z (10 months ago)
- Last Synced: 2024-12-08T04:46:12.057Z (about 1 month ago)
- Topics: paypal, paypal-checkout, paypal-rest-api
- Language: PHP
- Homepage:
- Size: 24.4 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
### Install
```shell
composer require aamroni/paypal
```### Config Example
Collect your public and secret keys, and configure as necessary in config/payment.php```php
'paypal' => [
'client' => env('PAYPAL_CLIENT_KEY'),
'secret' => env('PAYPAL_SECRET_KEY'),
'redirect' => [
'success' => sprintf('%s/paypal/success', env('APP_URL')),
'cancel' => sprintf('%s/paypal/cancel', env('APP_URL')),
],
'currency' => 'USD',
'tax_rate' => 0,
'insurance' => 0,
'additional' => 0,
'shipping' => [
'discount' => 0,
'netPrice' => 0
]
],
```### Checkout Example
```php
checkout(invoice: $invoice, products: $products, shipping: $shipping, purchase: $purchase);dd($paypal);
```