Skip to content
This repository has been archived by the owner on Apr 6, 2021. It is now read-only.

A sample Laravel app that will learn you how to use Jibimo Laravel package.

Notifications You must be signed in to change notification settings

j-tag/jibimo-laravel-sample

Repository files navigation

🏢 Jibimo API Laravel Sample App

This sample Laravel application is using Jibimo Laravel package available at https://github.com/J-TAG/jibimo-api-laravel-package to show you how to implement this package in your Laravel app.

GitHub release

🎁 Quick Start

This app will use Jibimo Laravel package which is implemented as separate commands in app/Console/Commands directory.

Simply install required packages using following composer command:

composer install --prefer-stable

And then add Jibimo configs in your .env file:

JIBIMO_BASE_URL="https://jibimo.com/api"
JIBIMO_API_TOKEN="..." #Your Jibimo API token

Now you can use Jibimo static class available at puresoft\jibimo\laravel like puresoft\jibimo\laravel\Jibimo::pay() or simply you can inject it to your method like this:

    public function myMethod(Jibimo $jibimo)
    {
        $response = $jibimo->pay(...);
        // ...
    }

Please take a look at commands that are available in app/Console/Commands to see examples of using this package.

🎩 Installation in Your Own Laravel App

In order for adding Jibimo Laravel package to your own project you can run the following command in your own project root directory:

composer require puresoft/jibimo-api-laravel --prefer-stable

Now you need to publish Jibimo configs using following command:

php artisan vendor:publish --provider=puresoft\jibimo\laravel\JibimoServiceProvider

This will create a jibimo.php file in your config folder and now you can set environment variables in your .env file as follow:

JIBIMO_BASE_URL="https://jibimo.com/api"
JIBIMO_API_TOKEN="..." #Your Jibimo API token

Please take a look at https://github.com/J-TAG/jibimo-api-laravel-package/blob/master/README.adoc for Jibimo Laravel package documentation.

💝 Contributing

If you enjoyed this project, please consider contributing to it and make it better.

And please don’t forget to give a star to this project.

Thank you and happy coding!