Plans and leases
A bot runs on a lease: USDG you deposit for the days you pick. Stop it whenever you want and the unused time comes back.
Plans
| Plan | Price | Modules |
|---|---|---|
| Basic (plan 1) | 0.20 USDG a day | Buy bot, price alerts, welcome and anti-spam, any combination |
| AI (plan 2) | 0.60 USDG a day | Everything in Basic, plus AI answers from your docs |
The price is set per day and charged per second. A lease runs from 1 to 90 days per call; you can extend it before it ends.
Opening a lease
USDG.approve(BotyardLeases, deposit)
BotyardLeases.open(planId, seconds) // seconds = days x 86400quote(planId, seconds) returns the deposit before you sign. The price is locked in the lease at open. The app and the API build both calls for you.
Extend, stop, settle
extend(id, seconds)adds 1 to 90 more days at the locked price, while the lease is running.close(id), by the lease owner, stops the meter at that second. The worker sees it, stops the bot, deletes its token from the worker and settles.settle(id, usedSeconds), by the worker: the used time is charged, and the rest of the deposit goes back to the owner in the same transaction.- When a lease reaches its end, the worker stops the bot and settles it the same way.
settleExpired(id)can be called by anyone three days after a lease's end, so your refund never depends on the worker.
Where a charge goes
Of every settled charge, 20% goes to the burn vault, which buys $YARD and burns it, and 80% to the treasury that pays for the worker, Telegram traffic and inference. The refund is the deposit minus the charge.
deposit = 0.20 x 7 = 1.40 USDG
charge = 0.20 x 2 = 0.40 USDG (0.08 to the burn vault, 0.32 to the treasury)
refund = 1.40 - 0.40 = 1.00 USDG back to your walletHow many bots
A wallet can have 3 live leases at a time, and 10 when it holds at least the holder threshold of $YARD (read with balanceOf when the lease opens, see $YARD). The service runs up to 200 live bots in total. All three limits are enforced by the contract.