Download the PHP package maxiewright/laravel-wipay without Composer
On this page you can find all versions of the php package maxiewright/laravel-wipay. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download maxiewright/laravel-wipay
More information about maxiewright/laravel-wipay
Files in maxiewright/laravel-wipay
Package laravel-wipay
Short Description WiPay Caribbean Laravel Integration
License MIT
Homepage https://github.com/maxiewright/laravel-wipay
Informations about the package laravel-wipay
Laravel WiPay
Laravel package for WiPay Caribbean hosted checkout, return verification, webhook handling, and encrypted merchant credential storage.
The package supports two credential modes:
- Platform mode uses credentials from
config/wipay.php. - Merchant mode uses encrypted, owner-bound merchant credential records stored by your application.
Installation
Install the package with Composer:
Publish the config and migration, then migrate:
Merchant API keys are stored with Laravel encrypted casts, so your application must have a stable APP_KEY.
Configuration
Set platform credentials when your app receives payments through one WiPay account:
Supported market request URLs are configured for TT, BB, GY, and JM. Override WIPAY_*_REQUEST_URL values if WiPay gives you a different endpoint.
Platform Checkout
Use platform checkout when the application owns the WiPay account.
For direct form integrations, call form() instead of create() and post the returned fields to action().
Merchant Credentials
Use merchant credentials when each shop, vendor, or tenant has its own WiPay account.
Then create a checkout for that owner:
Merchant checkout never falls back to platform credentials. Missing or disabled merchant credentials throw WipayUnavailableException.
Payment Links
Configured WiPay payment links are exposed without creating a checkout.
merchantLinks($owner) returns empty links when that owner has no enabled merchant credentials.
Return Verification
Verify WiPay return payloads before marking an order paid.
For merchant credentials, pass the mode and owner:
Webhooks
Enable the package webhook route when WiPay should post server-side updates to your app:
Listen for webhook events in your application:
When verifying webhooks the package will prefer a dedicated webhook secret when available rather than the API key. Behavior:
- Platform mode: uses
config('wipay.platform.webhook_secret')if set (non-empty). - Merchant mode: uses the merchant credential
webhook_secretwhen present. - If a webhook secret is not available, fallback to the API key is controlled by
config('wipay.hash.allow_webhook_api_key_fallback')(defaultfalse). When that flag istrueverification will fall back to the API key; whenfalsewebhook verification will be rejected with themissing_secretreason.
Return verification also emits WipayPaymentVerified or WipayPaymentRejected. Webhook handling emits WipayWebhookVerified or WipayWebhookRejected and always responds with HTTP 200.
Testing
Use Wipay::fake() to avoid live HTTP calls and assert checkout fields.
Run the package test suite with:
License
The MIT License (MIT). Please see License File for more information.
All versions of laravel-wipay with dependencies
illuminate/contracts Version ^11.0||^12.0||^13.0
illuminate/database Version ^11.0||^12.0||^13.0
illuminate/http Version ^11.0||^12.0||^13.0
illuminate/routing Version ^11.0||^12.0||^13.0
illuminate/support Version ^11.0||^12.0||^13.0
spatie/laravel-package-tools Version ^1.16