Who Canceled my Approval Job?


Sometimes an approval job that you have set to on-hold will be canceled by someone else, but you're not sure who. When you make a call to the API to find see if it has any helpful information, you get this:


How Do I Find The User?

You can take the user id provided by the API call, and make another call to our API using the get Job Details endpoint.

From there you should get a response that would look something like this:


"pipeline_id" : <pipeline_id>,
"canceled_by" : <user_id>,
"id" :<id>
"name" : <name>,
"project_slug" : <project_slug>,
"status" : "canceled",
"started_by" : <user_id>,
"pipeline_number" : <pipeline_number>,
"created_at" : <created_by>,
"stopped_at" : <stopped_at>


This provides you with a value for the UID who the job was "canceled_by". Take that User ID and pass it to the Get User API endpoint. You should receive a response that looks like this:


"name": "Martin",
"login": "martincircleci",
"id": <user_id>


Additional Resources:

Was this article helpful?
0 out of 1 found this helpful



Article is closed for comments.