Download the PHP package faridibin/paystack-laravel without Composer

On this page you can find all versions of the php package faridibin/paystack-laravel. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package paystack-laravel

Paystack Laravel

Latest Version on Packagist Total Downloads License

A Laravel wrapper for faridibin/paystack-php with service provider, facade, webhook handling, and event dispatching.

Requirements

Installation

The service provider is auto-discovered — no manual registration needed.

Publish Configuration

This creates config/paystack.php in your application.

Environment Variables

Add your Paystack secret key to .env:

Usage

Facade

Available Services

Commerce

Facade call Service
Paystack::products() Products
Paystack::paymentPages() Payment Pages

Payments

Facade call Service
Paystack::transactions() Transactions
Paystack::splits() Transaction Splits
Paystack::customers() Customers
Paystack::charge() Charge
Paystack::bulkCharges() Bulk Charges
Paystack::refunds() Refunds
Paystack::subaccounts() Subaccounts
Paystack::disputes() Disputes
Paystack::settlements() Settlements
Paystack::paymentRequests() Payment Requests
Paystack::dedicatedAccount() Dedicated Accounts
Paystack::terminal() Terminal
Paystack::applepay() Apple Pay

Recurring

Facade call Service
Paystack::plans() Plans
Paystack::subscriptions() Subscriptions

Transfers

Facade call Service
Paystack::transfers() Transfers
Paystack::recipients() Transfer Recipients
Paystack::control() Transfer Control

Other

Facade call Service
Paystack::integration() Integration
Paystack::verification() Verification
Paystack::miscellaneous() Miscellaneous
Paystack::balance() Balance
Paystack::directDebit() Direct Debit
Paystack::virtualTerminal() Virtual Terminal
Paystack::storefront() Storefront
Paystack::order() Order

Service Configuration

Enable only the services you need in config/paystack.php:

Calling a group method with no arguments enables all services in that group:

Webhook Handling

Endpoint

The package registers a webhook route automatically:

Incoming requests are validated against the X-Paystack-Signature header and the caller's IP address (Paystack's published IP whitelist) before any event is dispatched.

Events

Every valid webhook dispatches WebhookReceived. If a specific handler exists on the controller, WebhookHandled is also dispatched after it runs.

Specific webhook events

The package ships a dedicated event class for every Paystack webhook type:

Event class Paystack event
ChargeSuccessEvent charge.success
ChargeDisputeCreatedEvent charge.dispute.create
ChargeDisputeRemindEvent charge.dispute.remind
ChargeDisputeResolvedEvent charge.dispute.resolve
TransferSucceededEvent transfer.success
TransferFailedEvent transfer.failed
TransferReversedEvent transfer.reversed
SubscriptionCreatedEvent subscription.create
SubscriptionDisabledEvent subscription.disable
SubscriptionNotRenewedEvent subscription.not_renew
SubscriptionExpiringCardsEvent subscription.expiring_cards
InvoiceCreatedEvent invoice.create
InvoiceUpdateEvent invoice.update
InvoicePaymentFailedEvent invoice.payment_failed
PaymentrequestPendingEvent paymentrequest.pending
PaymentrequestSucceededEvent paymentrequest.success
RefundProcessedEvent refund.processed
RefundPendingEvent refund.pending
RefundFailedEvent refund.failed
RefundProcessingEvent refund.processing
CustomeridentificationSuccessEvent customeridentification.success
CustomeridentificationFailedEvent customeridentification.failed
DedicatedaccountAssignSuccessEvent dedicatedaccount.assign.success
DedicatedaccountAssignFailedEvent dedicatedaccount.assign.failed

Custom webhook handling

Extend the webhook controller and add on<EventName> methods. The method name is derived by converting the Paystack event to camel case (e.g. charge.success → onChargeSuccess):

Then register the route pointing to your controller in your application's routes/web.php:

Routes

Method URI Name
GET /paystack/transaction/{id} paystack.transaction.fetch
POST /paystack/webhook paystack.webhook.handle

Disable all routes:

Testing

License

MIT


All versions of paystack-laravel with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
faridibin/paystack-php Version ^0.3.0
illuminate/support Version ^11.0|^12.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package faridibin/paystack-laravel contains the following files

Loading the files please wait ...