You need to sign in to do that
Don't have an account?
Robert Jakubov
getting JSON_PARSER_ERROR....Unexpected character
Hi there,
I am getting the following error when call the REST API (modify Account information) from Python:
<type 'list'>: [{u'errorCode': u'JSON_PARSER_ERROR', u'message': u"Unexpected character ('B' (code 66)): expected a valid value (number, String, array, object, 'true', 'false' or 'null') at [line:1, column:2]"}]
I have the following JSON data input:
args={
'BillingCity' : 'NY'
}
and a header with the access Authorization token (not posted here).
Can anyone please help?
thanks
Rob
I am getting the following error when call the REST API (modify Account information) from Python:
<type 'list'>: [{u'errorCode': u'JSON_PARSER_ERROR', u'message': u"Unexpected character ('B' (code 66)): expected a valid value (number, String, array, object, 'true', 'false' or 'null') at [line:1, column:2]"}]
I have the following JSON data input:
args={
'BillingCity' : 'NY'
}
and a header with the access Authorization token (not posted here).
Can anyone please help?
thanks
Rob
https://json2apex.herokuapp.com/
Please let us know if this will help you
Thanks
Amit Chaudhary
the way I use the JSON input data is as following?
args={
"BillingCity":"NY"
}
and then pass to the request
req = requests.patch(
'https://na34.salesforce.com/services/data/v34.0/sobjects/Account/00161000003L6Tx',
headers=headers2,
data=json
)
response = req.json()
data=args