Is your feature request related to a problem? Please describe. Any time I want to use the sail cli to pipe output to another program, I have to spend effort cleaning up the headers, status line, and logging before I can parse the JSON. It seems the cli is not consistent in what it prints to stdout vs stderr.
Describe the solution you'd like. It would be wonderful to have only the JSON go to stdout and all the other status lines go to stderr so that it cleanly works for piping data to subsequent programs. This would be a change to behavior, so another options would be to have a minimal output flag where I only get the JSON body response in stdout and can pipe that to jq or any other program for analysis.
Describe alternatives you've considered. Seeing as the JSON seems to be on the second to last line if I combine stdout and stderr, I can pass the output into other commands like
sail api get /v2026/some-endpoint 2>&1 | tail -n 2 | head -n 1 | jq .
This is really tedious, and somewhat fragile.
Additional context This feature would be great for ai agents, which would benefit from being able to run the CLI, but don't intuitively know how to parse your output cleanly
Is your feature request related to a problem? Please describe. Any time I want to use the sail cli to pipe output to another program, I have to spend effort cleaning up the headers, status line, and logging before I can parse the JSON. It seems the cli is not consistent in what it prints to stdout vs stderr.
Describe the solution you'd like. It would be wonderful to have only the JSON go to stdout and all the other status lines go to stderr so that it cleanly works for piping data to subsequent programs. This would be a change to behavior, so another options would be to have a minimal output flag where I only get the JSON body response in stdout and can pipe that to
jqor any other program for analysis.Describe alternatives you've considered. Seeing as the JSON seems to be on the second to last line if I combine stdout and stderr, I can pass the output into other commands like
This is really tedious, and somewhat fragile.
Additional context This feature would be great for ai agents, which would benefit from being able to run the CLI, but don't intuitively know how to parse your output cleanly