Error code while trying to get data through REST API
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-09-2018 06:10 AM
Hi All,
I am trying to integrate Asset Explorer Manage Engine with ServiceNow inorder to pull the Asset Data as well as data for CMDB CI's.
I have configured one Midserver for the same and created one Rest Message also with Authentication type as Basic and Basic auth profile as PersonalAuth.
When I click on test in HTTP Request, its throwing the below error in the response instead of pulling the records.
<?xml version="1.0" encoding="UTF-8"?>
<API version="1.0">
<response>
<operation name="">
<result>
<statuscode>3001</statuscode>
<status>Unknown error</status>
<message>Error when processing request - null</message>
</result>
</operation>
</response>
</API>
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-09-2018 06:20 AM
at first glance error seems to be from the Other end from which the REST API is bringing the date from.Few things you can try
1) Clear cache and try again the service in some REST Client such as POSTMAN.
2) Restart the Mid Server and redo step 1.
Mark helpful if it works for you.
Cheers!!
Anubhav
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-02-2021 10:12 PM
Faced this issue and and though the error is vague, I solved this issue by providing the AuthToken not as a header, but as part of the input data.
# Add Technician_Key key to data array
data = {
'INPUT_DATA': input_data,
'OPERATION_NAME' : 'add',
'format' : 'json',
'TECHNICIAN_KEY': "API-TOKEN"
}
# Remove header from the post request
response = requests.post(url,data=data,verify=False)