Has anyone managed to get s3 bucket npm library wo...
# suitescript
d
Has anyone managed to get s3 bucket npm library worked into a SuiteScript project?
c
I've only used private npmjs packages. Have you already started trying to implement an s3 bucket library and hit a snag, or is this at the start of the process?
d
I've done it before, but it was a little sloppy. I was hoping someone had figured out how to
shim
the official aws-sdk s3 library into a project
👍 1
c
it has so many dependencies, i imagine it's a nightmare
d
right @CD
a
Zigman has a connector suiteapp for s3. I just had to do something similar on the gcp side with cloudstorage. Ended up just going to api route and writing a custom lib. Auth was the trickiest part
s
I once got the AWS SDK working in NS, but it was an much older version of the SDK and older version of SuiteScript. Not sure if the current version of each would be easier or harder but it was a bit of effort. I feel some effort is worth it to be able to leverage the 'official' SDK.
e
I got it to work by including the AWS SDK in a library module with these NS modules defined.
define(['N/xml', 'N/http', 'N/https', 'N/error'], function(nsXml, nsHttp, nsHttps, nsError) {
c
Hey @Eric B, thanks for the update on AWS SDK. Can you pls share a SDK documentation or library file that you have included in SDK? Thankyou!