Store/Save inbound REST calls into a custom transaction log table instead of going through the Node Logs

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-13-2019 01:09 PM
Is there a way to capture/insert the Inbound REST transaction immediately into a custom table when it gets invoked...
I would rather have everything in one table to look at and report, than going to the Node log File or Browser to search for transactions which is a significant effort to debug integrations.
Let me know if any thoughts or existing solutions or if there is something already available that I am missing.
Thanks in advance for the help.
- Labels:
-
Best Practices
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-13-2019 02:41 PM
If you created a Scripted Rest Api, then I am assuming you will have a Scripted Rest Resource[GET/POST etc] associated with it. You can log them in the Scripted Rest Resource.
gs.log(new JSON().encode(requestData));
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-13-2019 02:42 PM
instead of using native gs.log statements, you can create a custom table and use your scripting magic to update that table with the necessary information. Almost everything is achievable using scripts.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-13-2019 02:56 PM
Scripted APIs and Outbound calls this would work.
I just thought there would be a generic 1 shot way of grabbing inbound payloads even for Table APIs and other inbound APIs for seeing the transactions.
Looks like a dead end for me. And I am not looking to modify OOTB operations.
At some point I will work in a gliderecord insert for my Outbound scripts and scripted APIs.
Thanks all for your responses!