Looking for advice: I'd like to store a history of...
# suitescript
d
Looking for advice: I'd like to store a history of API callouts from NetSuite (from a transaction). I was thinking of simply creating 'User Notes' every time there's a callout: Good? Bad? [Seems overkill to introduce a custom record for this]
n
Honestly, Id probably just store this externally vs internally depending on what you are doing with the info. If its just for error handling, externally would work fine. Another alternative could be file storage and reading/writing to a file that lives in netsuite.
d
I have a log record that is used. I've written an extension to the N/https module that forces all of the calls to be logged when used. I also use it for incoming calls with suitelets and restlets.
👍 1
n
Custom record is just easier to manage. Plus you can always extend the custom record with other integrations as well. @darrenhillconsulting
e
I'd agree with a custom record, especially with deletions
d
Thanks everyone
s
if you don't need the info inside netsuite, I'd go with a real logging service.
g
if you care about the callouts that much then an external service gives a lot of extra features that are hard (for the money) to replicate and you’ll wonder how you lived w/o them. if it’s temporary, escalated information i do exactly what @dcrsmith does
t
@darrenhillconsulting There is a table - outboundRequest - exposed via SuiteQL that might help.
👍 1
🔥 1
d
Really? Thanks @tdietrich ... I'll have a look
t
There's not much stored in it, but you never know.
d
Yep, exactly what I need. Thanks again @tdietrich!
t
Awesome! Glad to have helped.