applab/sadad

Applab Sadad

v1.0.1 2022-04-04 08:17 UTC

This package is auto-updated.

Last update: 2024-05-26 15:24:06 UTC


README

68747470733a2f2f6170706c61622e71612f77702d636f6e74656e742f75706c6f6164732f323032302f31312f706167652d6c6f676f2e737667

Sadad Payment Paltform

Sadad is a Qatari Platform to send/receive payment via online [store / Website / portal ] and mobile [applications]

Below are a full list of features:

  • Web Checkout
  • API Integration
    • Transactions - List Transactions
    • Transaction - Get Single Transaction
    • Transaction - Refund Transaction

About Applab

AppLab is a leading company specialized in online platforms development. Online Platforms include Back-end, Databases, Web Applications and Mobile

About Sadad Platform

Sadad Sadad is a Qatari Platform to send/receive payment via online.

Installing Applab Sadad

The recommended way to install Applab Sadad is through Composer.

composer require applab/sadad

Publish configuration and migrations

php artisan vendor:publish --provider="Applab\Sadad\SadadServiceProvider"

The service provider is loaded automatically using package discovery.

Usage

Configuration

The package ships with a configuration file called applab-sadad.php which is published to the config directory during installation. Below is an outline of the settings.

sadadId 

Issued when creating your sadad account

secretKey

Issued when register your domain

domain

Your registered domain name

WebCheckout 2.1

Customer is on your website’s checkout page and fills up the details and places order.

    $webCheckoutOneReq=new WCORequest();     
    $webCheckoutOneReq->total_amount=100;
    $webCheckoutOneReq->order_id=$webCheckoutReq->getOrderId();
    $webCheckoutOneReq->customer_mobile="974XXXXXXXX";
    $webCheckoutOneReq->callback_url=url('sadad-purchased/'.$webCheckoutReq->order_id);      
    $products[]=['title'=>"product name",'id'=>123,'quantity'=>1,'amount'=>1,'type'=>'line_item'];
    $webCheckoutOneReq->setProducts($products);
    return Sadad::webCheckoutOne($webCheckoutOneReq);//default view

exclude your callback url in verify CSRF Token middleware to get the post response from SADAD

Merchant Integration APIs

Transactions List

  $filters=[];
  Sadad::getTransactions($filter)

Transaction details

  Sadad::getTransaction('SD33XXXXXXXXXX8')

Transaction refund

  Sadad::refundTransaction('SD33XXXXXXXXXX8')

Security Vulnerabilities

If you discover a security vulnerability within this package, please send an e-mail to Manu Applab via manu@applab.qa. All security vulnerabilities will be promptly addressed.

License

This package is open-sourced software licensed under the MIT license.