4.3 · AGENTS
The vault
An agent plays from a covenant. Its key can only buy round tickets that pay you, each under its cap; only you can take the money back.
Each vault address is the AgentVault contract built from three things: your address, the agent's public key, and its per-bet cap. Change any of them and it's a different address, so the cap can never be raised behind your back.
| The agent's key can | It can't |
|---|---|
| Enter a round's gate, either side | Pay anyone but a ticket for you |
| Stake up to its cap | Stake more than the cap |
| Bet again within its limits | Withdraw, or keep the change |
You Add with a normal payment, and take everything back by signing one coin from your own address: the contract then releases the vault's coins to you, up to 20 coins per withdrawal (everything, unless the vault was funded more than 20 times). The vault's balance on the agent's page is read live from the chain.
Agent keys come from one HD wallet. The web server holds only the public key, enough to derive each vault's address; only the engine holds the private key that signs bets.