Download the PHP package sdpayhub/laravel-payzy without Composer
On this page you can find all versions of the php package sdpayhub/laravel-payzy. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download sdpayhub/laravel-payzy
More information about sdpayhub/laravel-payzy
Files in sdpayhub/laravel-payzy
Package laravel-payzy
Short Description Enterprise-grade Laravel payment package with a unified API for Razorpay, Stripe, PayPal, Paytm, PhonePe, and Authorize.net.
License MIT
Homepage https://github.com/shukladeepak08/sdpayhub-laravel-payzy
Informations about the package laravel-payzy
Payzy
One simple API for Laravel payments. Use Razorpay, Stripe, PayPal, Paytm, PhonePe, or Authorize.net without learning six different SDKs.
Why Payzy?
| What you get | Why it matters |
|---|---|
| Same response shape on every gateway | Switch from Razorpay to Stripe by changing one string |
| Built-in webhook verification | Protects you from fake payment callbacks |
| Replay protection | Same webhook cannot be reused to fake a payment |
| Idempotency keys | Retries do not create duplicate charges |
| Secrets never logged | API keys are masked automatically |
| Typed exceptions | Catch payment errors clearly, not generic \Exception |
Requirements
- PHP 8.1 or newer
- Laravel 10, 11, or 12
Install (3 steps)
1. Install the package
2. Publish the config
3. Add your keys to .env
Use sandbox keys while testing. Never commit .env.
First payment (copy & paste)
Important: amount format
Pass amounts in smallest currency units:
| Currency | Example | Meaning |
|---|---|---|
| INR | 1000 |
₹10.00 |
| USD | 1000 |
$10.00 |
Switch gateway
Only change the gateway name. The rest of your code stays the same.
Common operations
Every method returns the same PaymentResponse object:
Webhooks (important)
Payzy registers this route for you:
Examples:
https://your-app.com/payzy/webhooks/razorpayhttps://your-app.com/payzy/webhooks/stripe
Setup checklist
- Put the URL in your gateway dashboard (Razorpay / Stripe / etc.).
- Put the webhook secret in
.env(RAZORPAY_WEBHOOK_SECRET,STRIPE_WEBHOOK_SECRET, …). - Run a queue worker so webhooks stay fast:
Payzy will:
- Verify the signature
- Reject old or repeated events (replay protection)
- Queue the work and return
202 Accepted
Avoid duplicate charges
Always send an idempotency key for checkout / create / refund calls:
If the same key is reused with a different payload, Payzy throws IdempotencyConflictException.
Cache note
Payzy stores idempotency results in Laravel’s cache. On a fresh Laravel app, prefer:
If you use CACHE_STORE=database, run migrations first so the cache table exists. Otherwise create/refund with an explicit idempotency key will fail with a clear configuration error.
Listen for events
Useful events:
PaymentCreatedPaymentSuccessPaymentFailedRefundCreatedRefundCompletedWebhookReceivedWebhookFailed
Handle errors
Supported gateways
| Gateway | Payments | Refunds | Webhooks | Customers | Subscriptions |
|---|---|---|---|---|---|
| Razorpay | Yes | Yes | Yes | Yes | Yes |
| Stripe | Yes | Yes | Yes | Yes | Yes |
| PayPal | Yes | Yes | Yes | — | Yes |
| Paytm | Yes | Yes | Yes | — | — |
| PhonePe | Yes | Yes | Yes | — | — |
| Authorize.net | Yes | Yes | Yes | — | — |
Extra .env keys
Security basics (please read)
- Keep all secrets in
.env— never hardcode keys in PHP files. - Use
PAYZY_MODE=sandboxuntil you are ready for live traffic. - Always configure webhook secrets and keep verification enabled.
- Serve webhook URLs over HTTPS only.
- Run
php artisan queue:workin production so webhook handlers are queued. - Do not disable SSL verification (Payzy never does this for you).
Report security issues privately — see SECURITY.md.
Testing this package
Packagist auto-update (maintainers)
If Packagist shows “This package is not auto-updated”, GitHub is not notifying Packagist on push. Fix it once:
- Open Packagist → your profile → Show API Token.
- On GitHub: Settings → Webhooks → Add webhook
- Payload URL:
https://packagist.org/api/github?username=YOUR_PACKAGIST_USERNAME - Content type:
application/json - Secret: your Packagist API token
- Events: Just the push event
- Payload URL:
- Back on the package page, click Update so tags and the README sync immediately.
After that, every push and tag appears on Packagist automatically (including the README below the install command).
Need more detail?
- Upgrade notes: UPGRADING.md
- How to contribute: CONTRIBUTING.md
- Changelog: CHANGELOG.md
License
MIT — see LICENSE.
All versions of laravel-payzy with dependencies
illuminate/contracts Version ^10.0|^11.0|^12.0
illuminate/support Version ^10.0|^11.0|^12.0
illuminate/http Version ^10.0|^11.0|^12.0
illuminate/routing Version ^10.0|^11.0|^12.0
illuminate/events Version ^10.0|^11.0|^12.0
illuminate/log Version ^10.0|^11.0|^12.0
illuminate/cache Version ^10.0|^11.0|^12.0
illuminate/queue Version ^10.0|^11.0|^12.0
illuminate/database Version ^10.0|^11.0|^12.0