Is there a REST API to update multiple rows in a table as a batch?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-31-2021 05:22 AM
Hi There -
I noticed that there is a BATCH API (https://developer.servicenow.com/dev.do#!/reference/api/paris/rest/batch-api) to send multiple requests to ServiceNow as a batch. The example shows support for batching multiple GET and POST requests. However, it fails when we batch PUT requests to update specific fields for a table. We tested this in Paris and Quebec releases.
Is there any way to batch multiple PUT requests?
Please help provide link to appropriate documentation. Thanks in advance for your time. Have a good day!!
Best,
Surya.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-31-2021 05:34 AM
Hi
why don't you build a simple Scripted REST API which you would pass four parameters
1) table name
2) encoded query string
3) field name
4) new value
That way you have the full control over behavior and the result.
Kind regards
Maik
If my answer replied your question please mark appropriate response as correct so that the question will appear as resolved for other users who may have a similar question in the future.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-23-2022 04:32 AM
Hello, Surya and Maik.
I'm new to ServiceNow Integration. Have you made this work? Can you share the script you used in the Scripted REST API to update the multiple rows via API?
Thank you in advance.
Best regards,
Catherine
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-01-2021 12:11 PM
Thank you
Thanks again!!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-01-2021 07:15 PM
Hi
Thank you for marking my response as helpful.
If my response helped you please mark it correct to close the question so that it benefits future readers as well.
If not, please tell me what you are still missing!
Many thanks & kind regards
Maik