Design a Bitcoin Wallet API Response
Goal
Draft a response envelope with success status, request ID, and typed result fields.
Exercise
Represent monetary amounts as integer satoshis, distinguish confirmed and pending values, and return explicit error codes for unsupported networks and incomplete scans.
Verify your result
- Write down the expected behavior before running the exercise.
- Test one valid case and at least two invalid or unexpected cases.
- Confirm that errors are visible and that no sensitive values appear in logs.
- Save the observations so the procedure can be repeated.
Safety note
Avoid floating-point BTC values for transaction accounting.
Next step
Read the [related guide](/docs/bitcoin-utxo-balance-reconciliation) before extending the exercise.
