REST Integration Error - PUT method not supported for API
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-02-2015 09:17 AM
I am trying to use REST's PUT method to update ServieNow incident table, but I got the response error -{"error":{"message":"Method not Supported","detail":"PUT method not supported for API"},"status":"failure"}. Can any expert give me the direction?
- Labels:
-
Integrations
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-02-2015 09:23 AM
Hi Nancyhz,
Are you using any import set table in between? What is your end point?
Thanks
Srini
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-02-2015 09:35 AM
I used Table API, not any import table. End point is "http://96.127.54.21:16000/api/now/v1/table/incident

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-03-2015 07:49 AM
Hi Nancyhz,
If you are familiar with cURL you can try the following. You will need to update the Authorization header text '<base64_encoded_username_and_password>' to be the base64 encoded combination of the user name and password of the account you want to use to make the request and you should also update the <sys_id_value> to be the sys_id of the Incident record you want to update.
This is a sample cURL request that would make an update to an incident record using the ServiceNow REST Table API:
curl -X "PUT" "http://96.127.54.21:16000/api/now/table/incident/<sys_id_value>" \
-H "Content-Type: application/json" \
-H "Authorization: Basic <base64_encoded_username_and_password>" \
-H "Accept: application/json" \
-d "{\"short_description\":\"test short description update from REST API\"}"
Here is the same sample as HTTP:
PUT /api/now/table/incident/<sys_id_value> HTTP/1.1
Accept: application/json
Authorization: Basic <base64_encoded_username_and_password>
Content-Type: application/json
Host: 96.127.54.21:16000
Connection: close
Content-Length: 67
{"short_description":"test short description update from REST API"}
Hope that helps.
Bryan

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-02-2015 09:28 AM