Streaming results with the CLI and API
You can stream a test run’s results as they come in, from the Snouty CLI or the Antithesis API.
To follow a run in the web app instead, use the Run View (currently in beta).
Stream property results
Stream a run’s properties to get notifications when Antithesis first encounters a property, and when properties pass or fail.
With the API
Call the property stream endpoint:
curl --fail $AUTH -N -X POST \https://$ANTITHESIS_TENANT.antithesis.com/api/v0/runs/$RUN/stream \-d '{}'# → {"type": "NEW_PROPERTIES_ADDED", "data": [{"id": "27a7cb0b...", "name": "Writes are durable",# "status": "Undetermined", "example_count": 0, "counterexample_count": 0, ...}]}# {"type": "PROPERTIES_FAILED", "data": [{"id": "27a7cb0b...", "name": "Writes are durable",# "status": "Failing", "example_count": 0, "counterexample_count": 1, ...}]}# {"type": "RUN_FINALIZED", "data": []}With Snouty CLI
Run snouty runs stream to print one line for each event as it happens:
snouty runs stream <run-id>Each sample line gives the moment of an example or counterexample, which you can pass to snouty runs logs to read the logs at that moment. Snouty only sends a selection of samples, not all of them.
Use the --property flag to follow only specific properties, or --json to print each event as a JSON object.
The stream only shows events that happen after it starts. To get the current results as well, start the stream first, wait until Snouty reports that the stream is open, and then run snouty runs properties $RUN.
Stream event logs
Stream a run’s events to get new matches as Antithesis finds them. Queries use event sets.
With the API
Call the search endpoint with is_streaming set to true:
curl --fail $AUTH -N -X POST \https://$ANTITHESIS_TENANT.antithesis.com/api/v0/runs/$RUN/events/search \-d '{"query": "contains({output_text: \"connection refused\"})", "is_streaming": true}'Matching events arrive as newline-delimited JSON, one event per line.
With Snouty CLI
Run snouty runs search with the --follow flag to stream new results as they arrive:
snouty runs search $RUN --follow \'contains({output_text: "connection refused"})'Use the --limit flag (default 50) to cap the total number of events printed.