Arsalan Shah
4 years ago
A general-purpose wallet system for users, allowing them to add balance to their account. The site administrator can utilize the user's wallet balance through a set of available APIs.
ossn_com.php).Wallet now supports seamless payments, allowing users to securely save their card for future charges. This feature is only available when Stripe is configured as the payment gateway. The card is blocked after 3 failed attempts and admin need to delete card before user can add same card or new card. Make sure you disable Stripe Link integration https://support.stripe.com/questions/how-to-turn-off-link
Users receive email notifications for every credit or debit transaction, including both successful and failed attempts.
Tax collection is possible in settings only if you have configured to card stripe, and configured tax in stripe.
define('WALLET_CURRENCY_CODE', 'USD'); // Your 3-letter currency code (e.g., USD)
define('WALLET_MINIMUM_LOAD', 10); // Minimum wallet load (integer only)
define('WALLET_SEAMLESS_CHARGE', 1); // Minimum charge to store card for seamless payments
CURL https://www.yourwebsite.com/api/v1.0/wallet/debit
CURL https://www.yourwebsite.com/api/v1.0/wallet/credit
| Parameter | Type | Description | Required |
|---|---|---|---|
| api_key_token | string | Your API token | Yes |
| guid | integer | User GUID | Yes |
| amount | float/integer | Amount to debit or credit | Yes |
| description | string | Transaction description | Yes |
{
"merchant": "Open Source Social Network",
"url": "https:\/\/yourwebsite.com\/",
"time_token": 1637513403,
"payload": {
"status": "success",
"amount": "50",
"guid": "1"
},
"code": "100",
"message": "Request successfully executed"
}
<?php
// Credit wallet
try {
$user_guid = ossn_loggedin_user()->guid;
$wallet = new Wallet\Wallet($user_guid);
$amount = 20;
$description = 'Some description';
var_dump($wallet->credit($amount, $description));
} catch (Wallet\NoUserException $e) {
echo $e->getMessage();
} catch (Wallet\CreditException $e) {
echo $e->getMessage();
}
// Debit wallet
try {
$user_guid = ossn_loggedin_user()->guid;
$wallet = new Wallet\Wallet($user_guid);
$amount = 20;
$description = 'Some description';
var_dump($wallet->debit($amount, $description));
} catch (Wallet\NoUserException $e) {
echo $e->getMessage();
} catch (Wallet\DebitException $e) {
echo $e->getMessage();
}
// Get wallet balance
$user_guid = ossn_loggedin_user()->guid;
$wallet = new Wallet\Wallet($user_guid);
echo $wallet->getBalance();
// Set new balance
$user_guid = ossn_loggedin_user()->guid;
$wallet = new Wallet\Wallet($user_guid);
echo $wallet->setBalance(<new amount>);
9.0
4.0

Arsalan Shah
Replied 1 month ago
9.6 added support to accept floats by Stripe Gateway
Arsalan Shah
Replied 1 month ago
9.5 added french and german
Arsalan Shah
Replied 4 months ago
Membership Tier compomnent https://www.openteknik.com/product/view/45991/membership-tier-management
If tier is expired (renew is not possible / user card is declined for recurring payments access is blocked user become non paid member) its all automatic.
Colin Turner
Replied 4 months ago
Hello Arsalan, I am creating a premium-only network with OSSN. That is, there's no free access and no tiers. It costs $20 a year to be a member. Can this software handle this case? ie. No tiers, and expired memberships blocked access to the site?
Arsalan Shah
Replied 9 months ago
There are 500+ payment gateways and wallets i can not put all in here. 🤣🤣🤣🤣🤣
Eric redegeld
Replied 9 months ago
Tip, europe is changing to https://wero-wallet.eu/merchants
Mizhack Aguilar
Replied 1 year ago
It's eflymoney.com
I just created a new discussion
Arsalan Shah
Replied 1 year ago
What is your website url?
Create new discussion instead https://www.opensource-socialnetwork.org/discussion/add
Mizhack Aguilar
Replied 1 year ago
Okay. I did go to Github and reported the issue. Thanks.
Mizhack Aguilar
Replied 1 year ago
This is the admin page.
