- Python 3.11+
- Bitcoin Core 26.0+ running in
regtestmode pipandvenv
Each activity is independent. The setup steps are the same for all three:
cd atividade-1/backend # or atividade-2 / atividade-3
cp ../.env.example .env # fill in your RPC credentials
python3 -m venv .venv && source .venv/bin/activate
pip install -r requirements.txt
uvicorn app.main:app --port 8001 --reloadSee docs/en-US/setup-bitcoin-core.md for Bitcoin Core configuration.
- No Bitcoin libraries. Use the
rpc_client.pypattern from the existing activities —requests+HTTPBasicAuth+ JSON-RPC 2.0. - No shared modules across activities. Each activity must be fully self-contained.
- No database. In-memory state only (
dequeordict). - Structured 503. Routes that depend on the node return
{"detail": {"error": "node_unavailable", "detail": "..."}}with HTTP 503 when the node is offline — never HTTP 500.
Test against a live bitcoind -regtest node. The smoke tests in docs/en-US/smoke-tests.md cover the full flow for each activity.
- Fork the repository.
- Create a feature branch:
git checkout -b feature/my-change. - Make your changes and validate against a live regtest node.
- Open a pull request with a clear description of what changed and why.
Open a GitHub issue describing the expected behaviour, the actual behaviour, and the Bitcoin Core version you are using.