Has anyone experience of using the SetAlternateApproverAndOutOfOffice API (in AppPortal 2019 R1).
Does it behave exactly as it says in the doco – or is there anything I need to watch out for?
Thanks
Jul 21, 2022 09:33 AM
I didn't even know this API existed or that there was documentation on it. 😀 It looks pretty straight-forward and should work as documented. But I will call out that the alternate approver feature (not specific to the API) does not allow groups or multiple individuals, and there is no recursive behavior. So, if you set an alternate approver that is also out of office, the approvals will not be routed to that alternate's alternate.
Jul 21, 2022 09:57 AM
We're looking like a couple of rookies 😀 I guess I did not realize we had an API to do this either. Seems to me that I created a custom web service to do just the same thing, at one point. In any event, I just ran a brief test, and the API worked as expected. the uniqueUserName is the person who is out of the office, the uniqueApproverName is the alternate approver, and outOfOffice would be set to true if the uniqueUser is out of the office. When the API is invoked, the changes should be seen in the table WD_ApproverStatus.
Jul 21, 2022 10:07 AM
I didn't even know this API existed or that there was documentation on it. 😀 It looks pretty straight-forward and should work as documented. But I will call out that the alternate approver feature (not specific to the API) does not allow groups or multiple individuals, and there is no recursive behavior. So, if you set an alternate approver that is also out of office, the approvals will not be routed to that alternate's alternate.
Jul 21, 2022 09:57 AM
We're looking like a couple of rookies 😀 I guess I did not realize we had an API to do this either. Seems to me that I created a custom web service to do just the same thing, at one point. In any event, I just ran a brief test, and the API worked as expected. the uniqueUserName is the person who is out of the office, the uniqueApproverName is the alternate approver, and outOfOffice would be set to true if the uniqueUser is out of the office. When the API is invoked, the changes should be seen in the table WD_ApproverStatus.
Jul 21, 2022 10:07 AM
One more question on this please.... when you tested and used uniqueUserName and uniqueApproverName .... where those names the values from the UniqueName column in the WD_User table?
Ours look like DOMAINNAME/Username
Thanks
Jul 27, 2022 11:02 AM
I can't speak for what Charlie tested, but yes, any time you see a reference to "Unique...Name", this is referring to the DOMAIN\UserName format that you would find in the UniqueName column of WD_User.
Jul 27, 2022 11:11 AM
Brilliant - thanks for that.
Jul 21, 2022 10:14 AM