# Optional Configuration Node

**URL:** <https://discourse.nodered.org/t/optional-configuration-node/49001>\
**Category:** Developing Nodes\
**Created:** [28 July 2021 08:20 UTC](https://discourse.nodered.org/t/optional-configuration-node/49001 "2021-07-28T08:20:38Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![midhun](https://avatars.discourse-cdn.com/v4/letter/m/c57346/32.png) [@midhun](https://discourse.nodered.org/u/midhun)\
**Post date:** [28 July 2021 08:20 UTC](https://discourse.nodered.org/t/optional-configuration-node/49001/1 "2021-07-28T08:20:38Z")

</div>

We are using multiple config nodes as part of a flow. Now we have a requirement which allows to pass id of a config node as part of msg.payload which made the config-node field optional. But, if no config node is chosen, a warning triangle is appearing on the node. Is it possible to specify config node is optional?

```auto
 defaults: {
            name: { value: 'WebService' },
            configRef: { type: 'host-details' }
}

```

---

<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:** [28 July 2021 08:24 UTC](https://discourse.nodered.org/t/optional-configuration-node/49001/2 "2021-07-28T08:24:50Z")

</div>

> [@midhun](#):
>
> Is it possible to specify config node is optional

Yes.

Add `required: false` to `configRef`

---

<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:** [11 August 2021 08:25 UTC](https://discourse.nodered.org/t/optional-configuration-node/49001/3 "2021-08-11T08:25:16Z")

</div>

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