0

I asked a similar question a few days ago and got a very good response on how to get started.

I have a SharePoint site using a SPFx react app that I created. The app is contains a sophisticated form for contractors to fill out. When the contractor fills out the form and hits submit, it adds an item to the list using a snippet like this:

pnp.sp.web.lists.getByTitle("Contracts").items.add({
    //pushing items to a the contracts list
}));

I created a new role called contractors, I do not want them to be able to view any other list, be able to click on site contents and check data on the site, or if it's possible be able to view the list, because it will contain other people's information. I think the best way would be to somehow hide the toolbar for this role.

Here is a link to a screenshot of my current edit permission level, currently the way it's set up I'm getting a Error making HttpClient request in queryable: [403] . When I select all or give more access it works, I'm trying to give them the most basic access while allowing them to add/edit item on the list.

Here is the screenshot: https://ibb.co/y5Z4rwJ

4
  • This is clear as mud. Who is getting the error? When is the error happening? Is it a user in the Contractors group that gets it? Where is the error being displayed?
    – jpollar
    May 25 '21 at 18:30
  • @jpollar the user is in a contractors group correct. He get's this error as soon as he submits the form. When submitting the form it sends a request to add an item to a list. This error is found in inspect console
    – hisusu32
    May 25 '21 at 19:10
  • are you getting a line number telling you exactly where the code fails?
    – jpollar
    May 25 '21 at 19:32
  • are users in the Contractors group able to add items to the list directly within SharePoint without getting the 403?
    – jpollar
    May 25 '21 at 19:41
0

As per the permission level screenshot provided by you https://ibb.co/y5Z4rwJ, the "Use Remote Interfaces" permission is not selected which is required for rest services. Please select "Use Remote Interfaces" permission level and then check if the functionality works fine

Reference: Permissions check box "Use Remote Interfaces" when unchecked prevents users from accessing site. why?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.