wrkjobq -then 4 delete
Register Hereor login if you are already a member
I’m looking for the command /api that works behind the screens when I enter 4 to end the job. Does that exist?
Assuming that you are entering "4" on some system screen, you can probably see the command simply by pressing <F4> instead of pressing <Enter>.
What are you expecting to do with it once you find it?
It seems to me that the appropriate direction might be to change those jobs to respond to external control commands. Or other alternatives also seem better.
For example, if they were set to run in their own subsystem, they would be much easier to control. You could use iSeries Navigator to open a list of jobs in that subsystem, select them all and end them all at once. You can create a shortcut on your desktop to open the list of jobs.
In short, there are various ways of getting things accomplished. It's not always necessary to know commands or APIs.