Skip to main content
A self-contained script that lists markets and places a bet using a keypair wallet.
TypeScript
Call saveSecret (or store result.userKeypair.privateKey) immediately after the bet lands. If the process exits before you save it, you lose the ability to read your side in the UI. Your funds are still safe - you can still claim.

What’s next

React setup

Wire up CypherProvider and configure React Query.

Place bet action

Full parameter reference for placeBet.

Query hooks

Fetch markets, positions, and global state.

Encryption

How secrets work and how to decrypt positions.