Deluge Custom Function: Adding a request as Logged In Technician
I have a custom function written in deluge that is attached to an RLC transition, which creates a new request based on some specifications in the current request. Currently, I have it authenticating the api call using a generic admin account technician key.
What I would like to do is have the api call authenticate using the current Logged In Technicians information, so that the new request that is created shows that it was Created By the technician that actually clicked the button to generate the request. I want to do this so that we can run reports on how many of these requests were generated by each technician.
The REST API documentation says this:
If the user is logged in, then authtoken is not needed.Instead the login user credentials are taken to perform the required operations."
How can I apply that to my Deluge Custom function? I have tried simply removing the authtoken from the headers of the request, but that did not work. Do I have to pass in some information from the context map?