Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

NetSuite - Returning an header is not NLAuth scheme error , when I am using OAuth

Tags:

oauth

netsuite

I am trying to call a Restlet from a User Event Script which returns Customer information using Token Based Authentication .

But I receive an user error which says header is not NLAuth scheme

I know this means that I have to use the NLAuth scheme , but why is it giving this error?

Here is the authorization header I am using

 var headers =  { 'Authorization': 'Oauth realm="XXXXX", oauth_consumer_key="XXXXX" , oauth_token="XXXXX", oauth_nonce="XXX",oauth_timestamp="XXXX", oauth_signature_method="HMAC-SHA1", oauth_version="1.0",oauth_signature="XXXXXXXXXX="',
                'content-type': 'application/json'
                };
like image 735
Bharath Avatar asked Oct 30 '22 06:10

Bharath


1 Answers

You need to capitalize the "a" in "Oauth" Oauth -> OAuth

like image 166
Robert La Rocca Avatar answered Nov 24 '22 06:11

Robert La Rocca