once you have the run id of the batch you need to get the run id of each member (BatchJobRun.getMemberJobRunsByBatchJobRun) and then you can use the JobRun.hadErrors or whatever against each one. there may be some additional unreleased commands you need to run to convert outputs of the commands.
also if the batch job is 'by server' then you are going to have:
parent batch job run -> batch job run for target1 -> member job runs for target1
-> batch job run for target2 ...
Thank you for responding; I will try that now and see what I can get.
By the way, I am using the blcli reference at Home - BMC Server Automation Command Line Interface 8.9 to look up what kind of commands I can run. I notice that the one you mentioned is not there, and I have seen others mentioned on these forums from time to time that are not there. Are they documented (or at least listed) somewhere else?
Someone else asked me about doing something similar recently and i sent them the attached scripts i wrote a few years ago. not sure if they still work but the flow should still be the same. they might be useful or they will just confuse you more