myfatoorah/symfony-bundle

The official MyFatoorah Payment Gateway for Symfony.

2.1.0 2023-03-12 11:28 UTC

This package is not auto-updated.

Last update: 2024-04-08 11:50:07 UTC


README

This is the official MyFatoorah Payment Gateway Symfony Bundle. MyFatoorah Symfony is based on myfatoorah/library composer package. Both MyFatoorah Symfony and PHP library composer packages are developed by MyFatoorah Technical Team to handle MyFatoorah API endpoints.

Main Features

  • Create MyFatoorah invoices.
  • Check the MyFatoorah payment status.

Installation

Make sure Composer is installed globally, as explained in the installation chapter of the Composer documentation.

Step1: Download the Bundle

Install the bundle via myfatoorah/symfony-bundle composer. Open a command console, enter your project directory and execute the following command to download the latest stable version of this bundle:

composer require myfatoorah/symfony-bundle

Step2: Import MyFatoorahSymfonyBundle routing files

Add the below route in the config/routes.yaml file of your project:

myfatoorah_symfony:
    resource: '@MyFatoorahSymfonyBundle/Resources/config/routing.yaml'

Step3: Only for Applications that don't use Symfony Flex

You will need to enable the bundle manually by adding it to the list of registered bundles in the config/bundles.php file of your project:

//config/bundles.php
return [
    // ...
    MyFatoorah\SymfonyBundle\MyFatoorahSymfonyBundle::class => ['all' => true]
];

Merchant Configurations

Edit the vendor/myfatoorah/symfony-bundle/src/Resources/config/services.yaml file with your correct vendor data.

Demo configuration

  1. You can use the test API token key mentioned here.
  2. Make sure the test mode is true.
  3. You can use one of the test cards.

Live Configuration

  1. You can use the live API token key mentioned here.
  2. Add your country code.
  3. Make sure the test mode is false.