edlugz / tanda
This package provides you with the means to make requests to the Tanda API
Requires
- php: ^8.1
- guzzlehttp/guzzle: ^7.8
- illuminate/support: ^10.0
Requires (Dev)
- orchestra/testbench: ^v8.15.0
- phpunit/phpunit: ^10.0
- dev-main
- v1.0.41
- v1.0.40
- v1.0.39
- v1.0.38
- v1.0.37
- v1.0.36
- v1.0.35
- v1.0.34
- 1.0.33
- v1.0.32
- v1.0.31
- v1.0.30
- v1.0.29
- v1.0.28.1
- v1.0.28
- v1.0.27
- v1.0.26
- v1.0.25
- v1.0.24
- v1.0.23
- v1.0.22
- v1.0.21
- v1.0.20
- v1.0.19
- v1.0.18
- v1.0.17
- v1.0.16
- v1.0.15
- v1.0.14
- v1.0.13
- v1.0.12
- v1.0.11
- v1.0.10
- v1.0.9
- v1.0.8
- v1.0.7
- v1.0.6
- v1.0.5
- v1.0.4
- v1.0.3
- v1.0.2
- v1.0.1
- v1.0.0
- dev-analysis-RPgQJx
This package is auto-updated.
Last update: 2024-11-02 18:10:15 UTC
README
This is where your description should go. Take a look at contributing.md to see a to do list.
Installation
Via Composer
composer require edlugz/tanda
Publish Migration Files
php artisan vendor:publish --provider="EdLugz\Tanda\TandaServiceProvider" --tag="migrations"
Fill in all the details you will be requiring for your application. Here are the env variables for quick copy paste.
TANDA_RESULT_URL TANDA_C2B_RESULT_URL TANDA_CLIENT_ID TANDA_CLIENT_SECRET TANDA_ORG_ID TANDA_BASE_URL=
Usage
Using the facade
Sub Wallet
Tanda::subwallet()->create($name, $ipnUrl, $username, $password, $customFieldsKeyValue = []); Tanda::subwallet()->get(); Tanda::subwallet()->update($walletId, $name, $username, $password, $ipnUrl);
C2B - Fund Wallet (send stk push to mobile number)
Tanda::C2B()->request($serviceProviderId, $merchantWallet, $mobileNumber, $amount, $customFieldsKeyValue = []);
P2P - send to internal wallets
Tanda::P2P()->send($senderWallet, $receiverWallet, $amount, $customFieldsKeyValue = []);
B2C - send to bank accounts and mobile wallets
Tanda::B2C()->bank($merchantWallet, $bankCode, $amount, $accountNumber, $narration, $customFieldsKeyValue = []); Tanda::B2C()->mobile($merchantWallet, $serviceProviderId, $amount, $mobileNumber, $customFieldsKeyValue = []);
B2B - to paybills and till numbers
Tanda::B2B()->buygoods($merchantWallet, $amount, $till, $contact, $customFieldsKeyValue = []); Tanda::B2B()->paybill($merchantWallet, $amount, $paybill, $accountNumber, $contact, $customFieldsKeyValue = []);
Airtime - prepaid airtime (pinless topup)
Tanda::airtime()->prepaid($serviceProviderId, $amount, $mobileNumber, $customFieldsKeyValue = []);
Utility - kplc, nairobi water and paid tv
Tanda::utility()->postpaid($serviceProviderId, $amount, $accountNumber, $customFieldsKeyValue = []); Tanda::utility()->prepaid($amount, $accountNumber, $contact, $customFieldsKeyValue = []); Tanda::utility()->tv($serviceProviderId, $amount, $accountNumber, $customFieldsKeyValue = []);
Transaction - check status
Tanda::transaction()->status($transactionId);
Helper functions - get mno network based on mobile number
Tanda::helper()->serviceProvider($mobileNumber);
Helper functions - receive payout results
Tanda::helper()->payout($data);
Helper functions - receive c2b results
Tanda::helper()->c2b($data);
Change log
Please see the changelog for more information on what has changed recently.
Contributing
Please see contributing.md for details and a todolist.
Security
If you discover any security related issues, please email eddy.lugaye@gmail.com instead of using the issue tracker.
Credits
License
MIT. Please see the license file for more information.