SharePoint Online WorkFlow Forbidden error for a list with no edit user permission

Problem:

I have a list with permission for users to Add or View an Item. Once item added the users are not allowed to edit. In this list there is an ItemAdded SPD workflow which runs under App Step with elevated permission.

The App Step Elevated permission steps are well documented on MSDN

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

Even after all the App Step I got the following error in the item added workflow:

Retrying last request. Next attempt scheduled after 10/2/2018 4:50 PM.

Details of last request: HTTP Forbidden to https://{tenantname}.sharepoint.com/sites/test1/_api/web/lists(guid’95594e70-d007-44a8-9baa-cb714d15bda6′)/Items(204) Correlation Id: 866d4444-8807-5c84-a37c-0d1054fd9640

Instance Id: 6f29bdbe-4b05-4e18-8b5b-d3cc8b830a3f

After searching on the web to find why this was an error, I found the following article which helped me resolve the issue. In summary, I had to turn off the “Automatically update the workflow status to the current stage

SharePoint 2013: SharePoint Designer Workflow in Suspended or Canceled State

Cause

When the “Automatically update the workflow status to the current stage” name option is selected in SharePoint Designer, SharePoint must edit the list page to change the workflow status. A user needs edit permissions on the list to edit the workflow status. If a user does not have edit permissions on the list, the workflow enters a suspended state.

Sharing it…to save few hours. It took me few hours to figure out in spite of elevated App Only permission the SPD workflow fails for only Add or View Items permission list.

 

About Pankaj

I am a Developer and my linked profile is https://www.linkedin.com/in/pankajsurti/
This entry was posted in Uncategorized. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s