Collections access "data access forbidden"

Hey guys, hope y’all doing great!

I have a problem on my staging et preproduction Forest remote environments.
I added some new collections, when I’m trying to get the info, I have a data access forbidden and I’m using the admin role :confused:
This problem appears only on staging and preproduction, on production it’s working fine and I can access to the data.

Thanks in advance for your help!

  • forest-express-sequelize: “^7.0.0”
  • Express Version: “~4.17.1”
  • Sequelize Version: “~5.15.1”

Hi @caid,

Thanks for your message :raised_hands:

Did you create a role, and assigned it to yourself?
Is this role having the rights on those remote environments?

See this part of the documentation for further information.

Let me know :wink:

Hey @adriguy !

Yes I’ve created some roles, I also assignated to myself and to other colleagues, I authorized them to have access but still, they do not :confused:
Thanks for the documentation, I’m gonna have a look!

@caid do you have access to the collection?
If you added a new collection, you need to enable it in the role settings (for all needed environments) and finally to make it visible in the layout.

PS: Would you mind to share your project name?
It’d enable me to have a closer look to your configuration and help you out efficiently.

@adriguy no even as an admin I do not have the access :confused:
Yes I enabled them for the role I want and it’s also visible in the collection list on the left.
Sure, the project is “NostruCare”.

Thanks a lot @adriguy !

@caid the admin permission level doesn’t give access to the data.
It is the role that enables you to access data.

From what I can see, you personally have the Dev role, and you should have access to some collections on both Staging and Preprod.
Could you please give me an example of a couple environment / collection you don’t have access to?
And show me a screenshot of what you see?


@adriguy ahh yes, my bad, we are on developpers role :slight_smile:
Yes sure, it’s the collections : discounts, sponsorships and sponsorship offers.

Thanks a lot @adriguy !

Ok, so from what I can see in your role settings, it is normal that you can’t access the discounts collection in remote or preproduction environments.
You need to give access to this collection for every environments needed in the role settings.

See an example:
The accesses can be different from one environment to another one. Here, there are some permissions for the Production environment (note that Production is selected on the left menu).

But not for the Staging5 environment (note that Staging5 is selected on the left menu).

Is this a bit clearer to you?

Hey @adriguy

Really sorry for my late reply.
Yes that was the first thing I did, to give the access to the different roles, but still it’s not working (maybe I did it incorrectly).
That’s what I had for the dev role :

I should have the access the the discounts collection as Developper in every environment, but it’s working only on production.


Hi @caid,

On this page, you need to click on the Preprod tab (on the left side) and then set up the collections permissions as you wish!
And same thing for the Staging.

I’m doing it on this video, hopefully it would help you doing it yourself!

1 Like

Hey @adriguy

It’s working now and it was entirely my fault… I didn’t know that we have to choose the environment on the left side (it’s obvious btw…).
This is why on production I was able to access to these new collections because production is selected by default :joy:

Thank you very much for your explanations and time ! :pray:

1 Like

No problem @caid, happy to know it’s all good on your side now :wink:

1 Like