Overview
This guide walks through the fastest path from a workingcowboy CLI to a deployed Python actor on the hosted Cowboy devnet. You will create a normal project directory, initialize a devnet wallet, scaffold a starter actor, deploy it, call it, and inspect the result.
What you’ll learn:
- How to scaffold a project and manage a wallet
- How to deploy and execute a Python actor
- Where to go next when you want to customize actor behavior
Prerequisites
- The
cowboyCLI is installed and available on yourPATH - Optional:
lassois installed if you prefer the interactive console
1. Create a Project Directory
Start from any directory where you keep projects:2. Initialize Devnet Config
.cowboy/ with a fresh secp256k1 keypair and a config pointing at the hosted Mesa devnet. The devnet faucet funds the generated wallet when available.
3. Scaffold the Hello Actor
actors/hello/main.py, a tiny SDK counter actor. The generated file includes durable actor storage, an init handler, public handlers, and module-level dispatch functions:
The generated file also includes the wrapper functions the PVM calls by handler name. Keep those wrappers in place when you edit the actor.
4. Deploy the Hello Actor
Deploy it:Actor address in the commands below. Compute that address ahead of time if you want:
5. Call the Actor
Execute a handler:6. Next Steps
Minimal Actor Walkthrough
Understand the actor programming model
CLI Reference
Every
cowboy subcommand, flags, and semanticsEnd-to-End Example
Study source-checkout examples when you want larger actor patterns
Fee Model
Learn how Cycles and Cells are metered and priced
Where to Find Things
- Your project config:
.cowboy/config.json - Your devnet key:
.cowboy/keys/dev - Your starter actor:
actors/hello/main.py - CLI reference: CLI Developer Experience
- SDK tutorial: Your First Actor
Troubleshooting
'cowboy: command not found'
'cowboy: command not found'
Install the
cowboy CLI using the distribution method provided by the Cowboy team, then open a new terminal and run cowboy version.'connection refused' on RPC
'connection refused' on RPC
Run
cowboy status to see which RPC URL the CLI is using. If you intended to use the hosted devnet, re-run cowboy init dev or pass --rpc-url explicitly. If you are intentionally using a local validator, make sure that validator is running before using cowboy init local.Actor deploy fails with 'insufficient gas'
Actor deploy fails with 'insufficient gas'
The default cycle/cell limits are conservative. For larger actors, pass
--cycles-limit and --cells-limit — see cowboy actor.
