Hy all, Is anyone able to make a PATCH api reque...
# general
n
Hy all, Is anyone able to make a PATCH api request like POST/GET from netsuite using suitescript at server side script ?
n
here are some snips of what worked when we wrote a SS script to update salesforce.
headers = {
'Content-type'			:'application/json',
'Accept-Encoding'		:'gzip',
'Authorization'			: 'Bearer '+sessionKey,
'Sforce-Auto-Assign'	: 'FALSE',
'X-HTTP-Method-Override' : 'PATCH'
}
var queryUrl 	=	instanceUrl+'/services/data/'+version+'/sobjects/Opportunity/0061K0000xxxxxx?_HttpMethod=PATCH';
var response = <http://https.post|https.post>({
url    	: queryUrl,
body	: JSON.stringify(updateBody),
headers : headers
});
 (edited)
n
Thanks will try this.
Sorry @Netsuite Tragic it doesn't working for me.
May be the header is not accepted by my destination server.
n
What response are you receiving?
n
The server returning 404 if request other than patch