Download the PHP package kodedjackson/bachs-laravel without Composer

On this page you can find all versions of the php package kodedjackson/bachs-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 bachs-laravel

Bachs Laravel

A fluent, native Laravel integration for the Bachs.io payment API.

This package provides a clean Facade for interacting with the Bachs API (like creating Checkout Sessions and Products) and automatically handles secure webhook signature verification out of the box.

Installation

You can install the package via composer:

Publish the configuration file:

This will create a config/bachs.php file in your application where you can configure your default settings.

Configuration

Add your Bachs API keys to your .env file. You can find these in your Bachs developer dashboard.

(Note: When moving to production, change your Base URL to https://api.bachs.io/v1 and use your live keys).

Usage

1. Creating a Checkout Session

You can create a hosted checkout session by passing a pricing array for raw amounts, or a product_cart array for catalog items.

2. Creating a Product

You can create a product in your Bachs catalog. If you omit the currency, the package will automatically use your configured default (BACHS_CURRENCY).

Handling Webhooks (Fulfilling Orders)

Bachs recommends never relying on the browser redirect to fulfill an order. Instead, you should listen for webhooks.

This package automatically exposes a secure webhook endpoint at POST /bachs/webhook. It verifies the cryptographic signature of the incoming request and dispatches native Laravel events.

Step 1: Configure your Dashboard

In your Bachs developer portal, set your webhook URL to: https://yourdomain.com/bachs/webhook

Subscribe to the collection.succeeded event, and paste the generated signing secret into your .env file as BACHS_WEBHOOK_SECRET.

Step 2: Listen for the Event

When a payment is successful, the package fires the Kodedjackson\Bachs\Events\CollectionSucceeded event.

You can listen for this event in your application (e.g., inside EventServiceProvider or a dedicated listener) to fulfill the order:

Security Vulnerabilities

If you discover any security-related issues, please email directly instead of using the issue tracker.

License

The MIT License (MIT).


All versions of bachs-laravel with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
illuminate/support Version ^10.0|^11.0|^12.0|^13.0
guzzlehttp/guzzle Version ^7.8
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 kodedjackson/bachs-laravel contains the following files

Loading the files please wait ...