Partner API: create a rule from an existing elevation request or event
Kris Garbet
In the Admin Portal we can use Convert to Rule on an elevation request after it's been approved, denied or allowed once, and on elevation events. The Partner API can only create a rule at decision time, through approve or deny with createRule on a pending request, and the Partner API KB says creating a rule from scratch isn't available yet. We're building technician tooling on the Partner API and often decide a rule is needed after a one-time approval. Please add an endpoint like POST /api/v1/elevation-requests/{id}/convert-to-rule (and the same for elevation events), taking ruleLevel, approved, elevationType and the same options the portal offers. Being able to set or change a rule's scope through PATCH would help too.
D

Daniel Rivera
Hi Kris, thanks for laying this out so clearly. You're right: today the Partner API can only create a rule when you approve or deny a pending request. It can't convert an already-decided request or an event, and it can't change a rule's scope. That wasn't part of the current beta, but the use case makes sense and we've logged it for the team to look at. Until then, Convert to Rule in the Admin Portal is the way to do it after the fact. We'll update this post as it moves.