Guys has anyone idea why I get ""An unexpected err...
# general
p
Guys has anyone idea why I get ""An unexpected error has occurred." when try to call "https://restlets.api.netsuite.com/rest/roles"" with TBA?
b
weird question
the roles webservice only accepts NLAUTH headers
and TBA credential are tied to a specific role
p
Ok. But how I can get webservicesDomain becuase after then I need to prepare SOAP requests and I need from this?
b
wrong webservice
use the
DataCenterURLs rest service
p
great. now will be try... thx
Any idea why call on /rest/revoketoken?consumerKey=... I get "Invalid login attempt."
id guess missing token parameter or OAuth header
p
no. I have: 'Authorization': 'OAuth realm="xxx", oauth_nonce="116170328927962162291575291458", oauth_timestamp="1575291458", oauth_version="1.0", oauth_signature_method="HMAC-SHA256", oauth_consumer_key="...", oauth_token="...", oauth_signature="f2p%2FtOr4FrByJWUFiIA8d%2FRtbEp5bOGZd43994rHXmU%3D"'
b
can't really debug signature problems
but your signature does not look like base64
general advice is to try using something like postman which is known to be able to generate OAUTH1 headers correctly
p
ha... ok. I will check it... but all TBA pass via same class and I dont't see reason why now to get wrong signarture...
yes.this is good point. thx
b
looking a little closer at the signature, it appears to be using percent encoding on top of base64
are you sure the OAuth header is actually a header and not a url parameter?
p
this is a example from netsuite site: Authorization: OAuth realm="1234567", oauth_token="abceba68ac7c0001bcdcb5f9e3f5b64df79abc6e4db305064aa63eaa7bf00f00", oauth_consumer_key="60712990bc09623786e7047c226bcb3f86d49dca0b04efc21001dc76d97a81f5", oauth_nonce="XY9yd21nIABCsTkvJlfi", oauth_timestamp="1565704686", oauth_signature_method="HMAC-SHA256", oauth_version="1.0", oauth_verifier="111e630079c0222cf59cf18410e9939c848507457d7010003db01e63fa42abcd", oauth_signature="AbXYZmdHsSKjgp2WJ9tTOPQdQkQKyj00ZXi8FuvAsIg%3D" it too have %
yes. I am sure about that is header not GET params
b
got nothing for you beyond try postman