Does anyone have any luck authenticating from Sale...
# suitescript
a
Does anyone have any luck authenticating from Salesforce -> NetSuite via an NS RESTlet using TBA OAuth 1.0? Trying to not have to use Boomi or Celigo. I was easily able to connect to salesforce out of NetSuite. But our salesforce developer needs some help.
s
Our company does this. You’ll need to use custom Apex code for it, such as this: https://gist.github.com/surjikal/7539745
You’ll have to add the realm to the header, as Netsuite requires that.
e
You just need to provide consumer and user access tokens and realm. No different from any application that needs to connect to a RESTlet.
a
Getting an invalid signature... I can't see anything from the NetSuite side. Our SF developer sent me this. Obviously removed some stuff for security reasons. HttpRequest req = new HttpRequest(); req.setEndpoint('myRestletUrl'); req.setMethod('GET'); req = OAuth.signRequest(req, '1234','2345','5678','realm with _SB1', 'Mozilla/5.0'); Http h = new Http(); HTTPResponse resp = h.send(req); System.debug('HTTPResponse ' + resp); @scottvonduhn + this class you sent me in that github repo.