- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-03-2015 05:35 AM
I am trying to set up a successful POST REST call to the ImportSet API. However, I think I have my user permissions mixed up and I don't know how to sort them out. When I post as a user with admin permissions, the record is successfully created and I get the response back with the JSON that I was expecting. However, when I post as a user with more limited permissions, the response comes back as '201 Created', but there is no response body and the record is never created in the destination table. I am extremely new to ServiceNow, but I've been tasked with getting a basic conceptual demo working of posting content to SN via REST.
Could someone help me understand how Users/Roles/ACLs should be set up for this to work?
Here is what I have done:
Create a custom Application. In that application create a destination table and a WebService/Import Set with a transform map that will dump records into that table.
Create a custom role inside my application for end users. It looks generically something like this: application_prefix.custom_role
Create a user for use in this scenario and assign them the custom role. Also give them the rest_service role as described in the documentation.
Assign that role as the application's "end user access" role on the application's design page.
Assign that role as the user role for both the base table and the web service table and check the "Create access controls" box.
What am I missing here? I'm sure it's something fairly simple, I just don't know where to start looking! And why is the REST API returning nothing and returning a false success response?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-03-2015 11:29 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-03-2015 07:16 AM
Hi Erica,
Just to add you may find the below link helpful.
http://wiki.servicenow.com/index.php?title=Base_System_Roles#gsc.tab=0
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-03-2015 10:59 AM
Thank you for the link...Just to see what happened, I added the import_set_loader role to my user. I got the following error
------
{
"error": {
"message": "java.lang.NullPointerException: null value in entry: transform_map=null",
"detail": "null value in entry: transform_map=null Check logs for error trace or enable glide.rest.debug property to verify REST request processing"
},
"status": "failure"
}
------
However the row was created in the table.
I checked the logs, but didn't see any errors. ::sigh:: this is frustrating.
When it gets to the bottom line, my goal is to have a user with the least amount of permissions required to allow querying from the REST API both tables and import sets.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-03-2015 11:29 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-20-2020 11:02 PM
Work for me as well, thanks!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-03-2015 12:49 PM
Hi Erica,
What is the behavior if you just give "ITIL" role to the user in addition to the roles you have already given.