Install and enable
How to activate the MLM & Affiliate addon on a Bicrypto install — where the extension actually lives, what the seeder creates, and how to prove commissions are being generated before you advertise the programme.
There is nothing to unzip into a web root and nothing to compile. The addon's
code ships inside the platform; installing it means activating a licence and
flipping one row in the extension table. Everything else on this page is
about making sure the programme is actually generating commissions once you do.
Before you start
- A working Bicrypto install. See Server requirements if you do not have one yet.
- Your CodeCanyon purchase code for item 36667808, and the Envato username that bought it.
- Outbound HTTPS from the server to the licence host. Activation is a live call; it cannot be done offline.
- Shell access to run
pnpm seed, or the willingness to run an update cycle.
Nothing else. This addon adds no services, no environment variables and no external dependencies.
Step 1 — Activate and enable
-
Open the extensions screen. Sign in as an administrator and go to Admin → System → Extensions (
/admin/system/extension). The screen needs theaccess.extensionpermission; a Super Admin always has it. -
Find "Multi Level Marketing". Not "Affiliate" and not "MLM & Affiliate" — the row is titled Multi Level Marketing, its internal name is
mlm, and its product id is36667808. This is the only place in the entire admin where that name appears. -
Activate it with your Envato username and purchase code. Activation verifies against the licence server and writes an encrypted, machine-bound
.licfile underlic/36667808.lic. Moving the install to a different machine invalidates it. -
Switch the extension on. The licence file and the enabled flag are two separate things: a valid licence unblocks the gate, the status switch turns the feature on. You need both. The toggle writes
status = trueand clears the settings cache immediately. -
Confirm both menus appeared. The admin mega-menu grows a Business Tools → Affiliate Program entry, and signed-in members get Services → Affiliate Program. Both are gated on the
mlmextension being enabled, so if they are missing the toggle did not take.
On a managed or headless install you can do steps 3 and 4 in one command from the project root:
pnpm activate-product 36667808 YOUR-PURCHASE-CODEThat runs the same code path as the admin screen — it writes the licence file, flips the status flag and revalidates the security gate without a restart.
After enabling, every screen, URL, permission and settings key uses the word
affiliate. The only artefacts that say mlm are the extension row you just
switched on, the five database tables, and the affiliateMlmSystem setting.
Do not go looking for an MLM section in the admin — there is not one.
Step 2 — Seed the commission rules
The addon is useless without conditions: they are the rules that say what earns
a commission and how much. They live in mlm_referral_condition and are created
by a seeder, not by enabling the extension.
pnpm seedThis inserts 37 conditions covering every addon in the catalogue. It skips
any condition whose name already exists, so it is safe to run repeatedly and
it will never overwrite a rate you have edited.
15 of the 37 are active on a fresh database. The other 22 are seeded disabled on purpose. Several conditions can fire on the same activity, and every one of them used to ship active — a single deposit paid three commissions at once (10% + 5% + 2% = 17%) on a screen that read "10%". Exactly one rule per trigger is now enabled by default, so the number you see is the number you pay.
The 15 that start active:
| Trigger | Condition | Reward | Minimum |
|---|---|---|---|
| Deposit | DEPOSIT |
2% | 5 |
| Spot trade | SPOT_TRADE |
0.1% | 1 |
| Binary win | BINARY_WIN |
2% | 5 |
| Investment | INVESTMENT |
5% | 50 |
| AI investment | AI_INVESTMENT |
2% | 25 |
| Forex investment | FOREX_INVESTMENT |
100 fixed | 100 |
| ICO contribution | ICO_CONTRIBUTION |
15% | 10 |
| Staking | STAKING |
2% | 1 |
| E-commerce purchase | ECOMMERCE_PURCHASE |
5% | 5 |
| P2P trade (buyer side) | P2P_TRADE |
1% | 10 |
| P2P trade (seller side) | P2P_TRADE_COMPLETION |
0.5% | 10 |
| NFT purchase | NFT_PURCHASE |
2% | 5 |
| NFT sale | NFT_SALE |
2% | 5 |
| Copy trading | COPY_TRADING |
3% | 50 |
| Futures trade | FUTURES_TRADE |
0.1% | 10 |
New conditions are seeded to pay USDT into a SPOT wallet. Read Commission conditions before you change that — the reward currency is what all qualifying volume is converted into, and picking one your platform cannot price stops the rule paying anyone.
The seeder skips by name, so an install that has been running since before the defaults changed keeps whatever it had — including the historical state where every seeded condition was active and one deposit paid three commissions.
pnpm seed prints an audit of which active conditions currently collect on the
same activity. Read that output, then open Admin → Affiliate → Conditions
and turn off the ones you did not intend to run. The screen shows the combined
effective rate per rule, so you can see what a transaction really costs before
you decide.
Step 3 — Choose the structure
Go to Admin → Affiliate → Settings. The default is DIRECT, which pays the
immediate sponsor and nobody else. That is the right choice for most operators
and the only one that needs no further configuration.
If you want multi-level payouts, switch to BINARY or UNILEVEL, set a level
count between 2 and 7, and enter a percentage for each level. The percentages
are shares of the commission, not extra commission, and they must total 100% or
less — over 100% and the engine refuses to pay anything at all, silently.
The settings screen shows the running total for exactly this reason.
Full detail in Programme settings and Referral structures.
Step 4 — Prove it works
Do not announce the programme until you have seen a reward row appear.
-
Check the cron job registered. Open Admin → System → Cron and look for Process MLM Referral Conditions in the
mlmcategory. It runs hourly. The job only exists while the extension is enabled — it is added and removed as you toggle, without a restart — so its absence means the extension is off. -
Create a referral. Open a private browser window, register a throwaway account through
https://your-site/en/register?ref=<an existing user id>, then check Admin → Affiliate → Referrals. A row should exist. Its status isACTIVEunless you turned on Require Approval, in which case it isPENDINGand will earn nothing until you approve it. -
Trigger a commission. Have the new account do something a live rule pays on — a deposit above the condition's minimum is the easiest. Event-driven rules (deposits, staking, ICO, P2P, NFT, futures, copy trading) pay within seconds. Cron-driven rules wait for the next hourly run.
-
Check the reward exists. Admin → Affiliate → Rewards should show an unclaimed row against the referrer. The referrer also gets an in-app notification linking to
/affiliate/reward. -
Claim it. Sign in as the referrer, open Affiliate → Rewards and press Claim. The amount lands in the wallet named by the condition (
SPOT/USDTby default) and the reward row flips to claimed.
If step 3 or 4 produces nothing, work through Troubleshooting — there are five independent gates and each one fails quietly.
What the addon added to your database
Five tables, all prefixed mlm_:
| Table | Holds |
|---|---|
mlm_referral |
who referred whom, and whether the referral is PENDING, ACTIVE or REJECTED |
mlm_referral_condition |
the commission rules |
mlm_referral_reward |
earned commissions, claimed or not |
mlm_binary_node |
binary tree placement (display only) |
mlm_unilevel_node |
unilevel tree placement (display only) |
mlm_referral, mlm_referral_reward and mlm_referral_condition are
soft-deleting: an admin delete sets deletedAt rather than removing the row.
Turning it off
Switch the extension off on the same screen. The reward engine stops immediately
— it checks for the enabled mlm row before doing anything — and the hourly job
is deregistered within a scheduler cycle. Both menu entries disappear.
Nothing is deleted. Existing referrals, unclaimed rewards and tree nodes stay in the database exactly as they were, and re-enabling the extension resumes from there. Unclaimed rewards become claimable again the moment it is back on.