with blocks. Each one records when it started, when it finished, and how long it took — you do not call anything else.
Install
Instrument
Nest them however your code nests. You never pass ids around: each block remembers what it is inside, so anything you record picks up the right run and the right agent on its own.
async with works exactly the same.
Check it arrived
Run it once, then open Observe → Sessions and select your environment. Your run appears as a reconstructed trace. If nothing arrives, confirm the machine is connected withfailproofai config --status.
Full guide for custom agents
Every event method, what happens when your code raises, a worked example, threads and async, and instrumenting a framework with no adapter.

