Anchor-based Solana smart contracts for the Timba game platform.
- Runs token-based Coinflip and Giveaway games.
- Uses a commit-reveal flow for verifiable randomness.
- Settles payouts on-chain and accrues protocol fees per token config.
- Supports both SPL Token and Token-2022 flows.
- Provides timeout + oracle-buffer protections so players can recover funds if completion stalls.
For the full trust model and security details, see SECURITY.md.
programs/timba/src- on-chain program (instructions, state, events, errors).tests- integration and behavior tests (anchor testrunner).scripts/update-idl.ts- copies generated IDL/types to sibling consumers.target/idlandtarget/types- generated artifacts committed for downstream tooling.
- Rust
- Solana CLI
- Anchor CLI (
0.32.1) - Node.js
- Bun
The repo also includes a .devcontainer for containerized setup in VS Code/Cursor/Codespaces.
bun install
anchor build
anchor test# Build program and regenerate IDL/types
anchor build
# Run full test suite
anchor test
# Sync generated IDL/types to sibling repos
bun run update-idl
# Formatting checks
bun run lint
bun run lint:fix32Jr4JnXWvqq9GqPQynkooHsszaucUUvZfNLh2hdX2L5
- MAINNET_DEPLOYMENT.md - deployment and shutdown checklist.
- SECURITY.md - security model and user guidance.
- LICENSE - Business Source License 1.1 (BUSL-1.1).