# Can anyone tell how to set the resource for AC grant in node red

**URL:** <https://discourse.nodered.org/t/can-anyone-tell-how-to-set-the-resource-for-ac-grant-in-node-red/66909>\
**Category:** General\
**Created:** [25 August 2022 13:42 UTC](https://discourse.nodered.org/t/can-anyone-tell-how-to-set-the-resource-for-ac-grant-in-node-red/66909 "2022-08-25T13:42:46Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Techie](https://avatars.discourse-cdn.com/v4/letter/t/71e660/32.png) [@Techie](https://discourse.nodered.org/u/Techie)\
**Post date:** [25 August 2022 13:42 UTC](https://discourse.nodered.org/t/can-anyone-tell-how-to-set-the-resource-for-ac-grant-in-node-red/66909/1 "2022-08-25T13:42:46Z")

</div>

i have the grant node in which i set the property msg.res = object as mentioned. can anyone tell how to set the resource as the node is for grant permission on a resource

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [25 August 2022 17:19 UTC](https://discourse.nodered.org/t/can-anyone-tell-how-to-set-the-resource-for-ac-grant-in-node-red/66909/2 "2022-08-25T17:19:12Z")

</div>

You will need to say what nodes you are using to help narrow down your question. What module did you install to get the node?

---

<div class="post-metadata">

**Author:** ![Techie](https://avatars.discourse-cdn.com/v4/letter/t/71e660/32.png) [@Techie](https://discourse.nodered.org/u/Techie)\
**Post date:** [26 August 2022 07:16 UTC](https://discourse.nodered.org/t/can-anyone-tell-how-to-set-the-resource-for-ac-grant-in-node-red/66909/3 "2022-08-26T07:16:57Z")

</div>

used this command: npm install node-red-contrib-accesscontrol  
module name is : node-red-contrib-accesscontrol.  
got 10 nodes among them one is AC grant.

---

<div class="post-metadata">

**Author:** ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)\
**Post date:** [26 August 2022 07:30 UTC](https://discourse.nodered.org/t/can-anyone-tell-how-to-set-the-resource-for-ac-grant-in-node-red/66909/4 "2022-08-26T07:30:34Z")

</div>

Have you tried the 2 examples in the [readme](https://flows.nodered.org/node/node-red-contrib-accesscontrol)?

Failing that, you could look at [the src for that node](https://github.com/EdoGimo/node-red-contrib-accesscontrol/blob/main/accesscontrol/grant.js#L46) to determine what `msg.xxxx` properties are accessed / used

Also, the node itself has built in help that states...

> **Note:** All fields can also be specified using the msg attributes: e.g., to get the content of "msg.role" write only "role" after changing the type. Regarding CRUD attributes, be sure to provide an array, otherwise the node may fail or work incorrectly.
> 
> #### AccessControl module's logic
> 
> Details on module logic at [npmjs.com/accesscontrol](https://www.npmjs.com/package/accesscontrol).

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [25 October 2022 07:30 UTC](https://discourse.nodered.org/t/can-anyone-tell-how-to-set-the-resource-for-ac-grant-in-node-red/66909/5 "2022-10-25T07:30:52Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
