qrypto-engine / api /tiers.py
Qempireautomation's picture
Add plan definitions
bcb13c2 verified
Raw History Blame Contribute Delete
2.2 kB
"""Plan definitions. Prices are suggestions — change them in one place here.
Free Crypto paper trading. 1 trader (Scout or Builder). $100 virtual.
Pro Live crypto on your own Binance/Kraken + stocks & bond ETFs via Alpaca. All 3 traders, 3 running.
Enterprise Adds precious metals (PAXG/XAUT gold tokens, GLD/IAU/SLV ETFs), 10 traders, 5 venues, API access.
"""
from __future__ import annotations
TIERS: dict[str, dict] = {
"free": {
"name": "Floor Pass",
"price_usd_month": 0,
"max_bots": 1,
"live_trading": False,
"strategies": ["scout", "builder"],
"asset_classes": ["crypto"],
"venues": [],
"max_exchange_accounts": 0,
"paper_start_quote": 100.0,
"api_access": False,
"blurb": "Walk the floor with virtual money. Learn how the traders work before a dollar is at risk.",
},
"pro": {
"name": "Pro Desk",
"price_usd_month": 19.99,
"max_bots": 3,
"live_trading": True,
"strategies": ["scout", "anchor", "builder"],
"asset_classes": ["crypto", "stocks", "bonds"],
"venues": ["binance", "kraken", "alpaca"],
"max_exchange_accounts": 2,
"paper_start_quote": 1000.0,
"api_access": False,
"blurb": "All three traders, live, on your own exchange and brokerage accounts. Crypto, stocks and bond ETFs.",
},
"enterprise": {
"name": "Vault",
"price_usd_month": 99.0,
"max_bots": 10,
"live_trading": True,
"strategies": ["scout", "anchor", "builder"],
"asset_classes": ["crypto", "stocks", "bonds", "metals"],
"venues": ["binance", "kraken", "alpaca"],
"max_exchange_accounts": 5,
"paper_start_quote": 10000.0,
"api_access": True,
"blurb": "Gold and silver join the floor. Ten traders, five accounts, API access, priority support.",
},
}
ORDER = ["free", "pro", "enterprise"]
def tier(name: str) -> dict:
return TIERS.get(name, TIERS["free"])
def at_least(user_tier: str, required: str) -> bool:
return ORDER.index(user_tier if user_tier in ORDER else "free") >= ORDER.index(required)