Skip to main content
Nintex Community Menu Bar

REST API Break Role Inheritance Nintex O365 not working

  • Jan 16, 2018 10:47 PM UTC
  • 5 replies
  • 121 views
  • Translate All

Forum|alt.badge.img+1

I am using Nintex Office 365 workflows and using REST API to break role inheritance but it always throws Forbidden error message. I have achieved same in Nintex on Premise and it is working fine.

Any suggestions. 

5 replies

Forum|alt.badge.img+16
  • Jan 17, 2018 4:44 PM UTC

Forum|alt.badge.img+1
  • Author
  • Jan 17, 2018 8:44 PM UTC

Hi Fernando,

Yes, I tried this one and getbytitle also. In both the cases I get Forbidden error message. I also tried to use the action 'Update Item Permissions' and that too doesn't seems to be working.

Translate

Forum|alt.badge.img+9
  • Nintex Employee
  • Jan 18, 2018 11:19 PM UTC

Hi Taurundeep,

Who is the initiator of the workflow, generally the API request made from the workflow will be executed as the initiator of the workflow. Do they have access to perform permission modifications on this item? Alternatively using the request inside of an Action Set with elevated permissions enabled may help?

Thanks,

Callum

Translate

Forum|alt.badge.img+1

Hi Tarundeep Singh, you need to elevate the permissions using App step. 

  1. IN Manage Site Feature, activate feature "workflow can use app step".
  2. Now go to Site settings -> Site App Permissions , there you will find an entry for Workflow as i:oi.t|clientID@tenantID.
  3. Copy the Client ID and give it full control over site. To know how to give workflow full access please follow this blog. SharePoint Blog: Item Level Permission - SPD Workflow 2013 - Part 2 . follow same steps as mentioned for SPD workflow.
  4. Now In Nintex workflow, wrap your http action in Action Container and allow it to run as an app step.
  5. This way you will be able to do your task. 
Translate

Forum|alt.badge.img+7
  • Nintex Partner
  • Jan 29, 2018 9:31 AM UTC

Hi Tarun,

Hope it will help you. 

1) Nintex App Permission

Create a workflow with elevated permissions by using the SharePoint Workflow platform | Microsoft Docs 

2) Add REST in Web Service Like below

SitrURL +      "_api/web/lists/getByTitle('Documents')/breakroleinheritance(copyRoleAssignments=true, clearSubscopes=true)";

Translate