Auto reject approval after "x" days in workflow

booher04
Tera Guru

Is there a way within the workflow of a catalog item to reject an approval automatically if it's not approved within a certain(x) amount of business days?  I know it can be done through a scheduled job, but we have a need to make this auto reject within the workflow as it will be a different amount of days based on the catalog item.  

12 REPLIES 12

Harsh Vardhan
Giga Patron

have you tried using "Timer" activity ? wait for that specific days and then use run script activity after that to reject the approval . 

How would that work in conjunction with the approval?  Would you run from the previous activity to both the approval and the timer? 

Stefan K_
Tera Expert

Such use cases should always be handled with flow designer, not workflow (unless you especially want to make more complicated configuration)

Thanks Stefan - we currently do not use flow designer which is why I was asking about the workflow portion but I think we are going to use a scheduled job and just use a standard "x" amount of days.  I will look into flow designer as well.

Ankur Bawiskar
Tera Patron
Tera Patron

@booher04 

You can leverage Flow designer for this without scripting

1) Trigger - Record created on sysapproval_approver

2) then use Wait for a duration of time - give Wait for 72 hours; schedule as 24x7

3) the use If flow action and check if record is not approved

a) if yes then reject it

4) use update record action and set state as Rejected

find_real_file.png

Regards
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader