AI Investments
What the AI Investments addon actually does — duration-based investment plans whose outcome you configure, settled automatically from the user's wallet — what it requires, and where to start.
AI Investments gives your users a way to commit funds from their platform wallet to a named plan for a fixed term. They pick a plan, pick a duration, and enter an amount. The amount leaves their wallet immediately. When the term is up, the platform credits the wallet back with a result you decided in advance.
It is an addon on top of Bicrypto core. There is no separate database, no ScyllaDB, no on-chain component and no external service to sign up for.
The one thing to understand before you enable it
There is no model, no strategy, no market data and no order placed anywhere in this addon. The word "AI" describes how the product is presented to your users, not how the return is produced.
Every plan carries a default result — WIN, LOSS or DRAW — and a
profit percentage. When an investment matures, the settlement code reads
those two values and credits the wallet accordingly. A WIN pays the principal
plus the profit out of your own float. A LOSS keeps part of the principal and
credits it to the Super Admin's wallet. A DRAW returns the principal and
nothing else.
That is the entire mechanism. Treat every percentage point you publish as a percentage point you are liable for.
Everything else on these pages follows from that. The plan's minAmount and
maxAmount are how you cap a single ticket, the admin dashboard's Capital
Deployed figure is your outstanding liability, and the payout terms are
snapshotted onto the investment at purchase precisely because they are a promise
you have made to a specific user.
What it requires
| Requirement | Why |
|---|---|
| Bicrypto core | Wallets, users, roles, permissions, KYC, the notification system and the cron process all come from core. This addon adds no infrastructure of its own. |
| The cron process running | Maturity settlement is a scheduled hourly task. Without it, matured investments are only settled when the owner happens to open the list — see Lifecycle. |
| A Super Admin user with wallets | A LOSS settlement credits the forfeited principal to the oldest Super Admin's wallet and books it as platform revenue. With no Super Admin, that revenue is dropped and logged as [CRITICAL]. |
Ecosystem addon — only for ECO investments |
An investment is denominated in the market's quote currency and paid from the wallet type the trade panel is showing. On an ecosystem market that is the ECO wallet, which only exists if Ecosystem is installed. SPOT investments need nothing extra. |
| MLM & Affiliate addon — optional | The seeded AI_INVESTMENT referral condition only fires if the mlm extension is enabled. |
Nothing else. This addon does not depend on Futures, P2P, Copy Trading or any other product.
What ships
Four tables, created automatically on boot: ai_investment_plan,
ai_investment_duration, ai_investment_plan_duration and ai_investment.
Plans and investments are soft-deleted; durations and the join table are not.
Four admin screens under /admin/ai/investment — Dashboard, Plans,
Durations and Investment Logs. There is no settings screen: the entire
configuration surface is the plan row. See
Configuration surface.
One user surface, inside the trade workspace. When the extension is enabled,
an AI Investment tab appears alongside Standard Trading in the order form on
both /trade and /trade/pro. The list of a user's own investments lives in the
Orders panel of the Pro workspace only.
One scheduled task, processAiInvestments, running hourly. It is the only
automatic money mover in the product.
Fifteen permission keys under *.ai.investment*, one KYC feature gate
(invest_ai) and three seeded notification templates.
The user-facing route at /investment — Overview, Plans (/investment/plan) and
My investments (/investment/portfolio) — belongs to core's General Investment
feature and reads /api/finance/investment. It has nothing to do with this
addon; its operator console is /admin/finance/investment, not
/admin/ai/investment. The AI Investments purchase form is the tab inside the
trade workspace.
How the money moves
Follow one 1,000 USDT investment in a plan configured with a 5% profit
percentage and a default result of WIN, on a 30 DAY duration:
-
The user invests. The trade panel is showing
BTC/USDT, so the currency isBTCand the pair isUSDT. 1,000 USDT is debited from theirSPOTUSDT wallet as anAI_INVESTMENTtransaction. Anai_investmentrow is created withsymbol=BTC/USDT,status=ACTIVE, and a snapshot of the plan's profit percentage and default result — so editing the plan tomorrow cannot reprice a deal that has already been struck. -
Nothing happens for 30 days. No price is read, no position is opened, no value changes. The row sits at
ACTIVEand the 1,000 USDT is off the user's balance. -
The term expires.
createdAtplus 30 days is in the past, so the next hourly run picks the investment up. It reads the snapshot: 5% of 1,000 is 50, and the result isWIN. -
The wallet is credited 1,050 USDT as an
AI_INVESTMENT_ROItransaction. The investment is markedCOMPLETEDwithresult=WIN,roiPercentage= 5 andprofit= 50. -
The platform books its own side. A
WINrecords 50 USDT as a platform loss — money you paid out. Had the plan been configuredLOSS, the user would have received 950 USDT and the 50 would have been credited to the Super Admin's wallet as platform revenue instead.
A user may cancel an ACTIVE investment at any point before it matures and get
the full principal back — there is no early-exit fee anywhere in this product.
Where to start
Enable the extension row, confirm the hourly task is scheduled, grant the fifteen permissions and decide on the KYC gate.
Every field on the plan form, which four of them users can see, and which two decide what everybody gets paid.
How a term is measured, why a month is always 30 days, and the delete that used to destroy live investments.
Creation, maturity, cancellation and the exact settlement arithmetic — including what happens when the terms cannot be derived at all.
The dashboard, the three tables, and which admin actions move money versus which only write a column.
There is no settings page. This is the list of everything that is actually configurable, and where each lever lives.
Reference material sits behind all of them: API and data model lists every endpoint with its permission key and every table with its columns. Troubleshooting covers the failures that look like nothing is wrong.