BeFrank is a socially-oriented Solana token where each transaction automatically contributes to a Welfare Fund, while the recipient receives the full amount. This repository contains the smart contract and test suite built using the Anchor framework.
- SPL token with 6 decimals
- Sender-paid transaction fees:
- 0.5% to Welfare Fund
- 0.25% to Staking Pool
- 0.25% to Ecosystem Fund
- Anchor-based Solana smart contract
- Typescript Mocha test stub included
- Node.js (v16 or later)
- Yarn
- Solana CLI (
solana --version) - Anchor CLI (
anchor --version)
yarn installanchor buildsolana config set --url devnet
anchor deployanchor testinitialize: Initializes the token and mints total supplytransfer_with_fee: Sends tokens and splits the 1% fee to predefined accounts
programs/befrank_token/src/lib.rs– main smart contract logictests/befrank_test.ts– integration test
MIT License
- Solana CLI
- Anchor CLI
- Node.js + Yarn
solana config set --url https://api.devnet.solana.com
solana-keygen new --outfile ~/.config/solana/befrank-devnet.json
solana config set --keypair ~/.config/solana/befrank-devnet.json
solana airdrop 2
anchor build
anchor deploysolana config set --url https://api.mainnet-beta.solana.com
solana config set --keypair ~/.config/solana/befrank-mainnet.json
# Ensure wallet is funded manually
anchor build
anchor deployanchor test