# Mixed configuration property or optional?

**URL:** https://discourse.nodered.org/t/mixed-configuration-property-or-optional/80909
**Category:** Developing Nodes
**Created:** [30 August 2023 11:57 UTC](https://discourse.nodered.org/t/mixed-configuration-property-or-optional/80909 "2023-08-30T11:57:36Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![FezVrasta](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/fezvrasta/32/2182_2.png) [@FezVrasta](https://discourse.nodered.org/u/FezVrasta)
#### Post date: [30 August 2023 11:57 UTC](https://discourse.nodered.org/t/mixed-configuration-property-or-optional/80909/1 "2023-08-30T11:57:36Z")

</div>

Hi, I need to allow my node to accept one configuration node, but I want it to be one of many types.

I have `matter-server` and `matter-aggregator` and I would like the `server` property of my node to accept one from either lists. Is this possible?

If not, I would have to display two separate dropdowns and have the user pick from just one of them, but if I do that, Node-RED forces the user to select an option from each of the dropdowns even though I marked them as optional, ideas?

I guess if the above is not possible I will have to create my custom-made type dropdown, it's not a big deal but I would really like to do it only if there's not a better Node-RED standard way

---

<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: [30 August 2023 12:46 UTC](https://discourse.nodered.org/t/mixed-configuration-property-or-optional/80909/2 "2023-08-30T12:46:23Z")

</div>

Hi @FezVrasta

it isn't possible to have a single property to be selected from multiple types - you will need to have two separate properties.

It is possible to mark an config property as optional. For example, the HTTP Request node has an optional TLS config node property:

> <https://github.com/node-red/node-red/blob/master/packages/node_modules/%40node-red/nodes/core/network/21-httprequest.html#L230>

---

<div class="post-metadata">

### Author: ![FezVrasta](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/fezvrasta/32/2182_2.png) [@FezVrasta](https://discourse.nodered.org/u/FezVrasta)
#### Post date: [30 August 2023 14:44 UTC](https://discourse.nodered.org/t/mixed-configuration-property-or-optional/80909/3 "2023-08-30T14:44:10Z")

</div>

Thanks, I managed to make the optional property working, I'm not really sure why it kept complaining initially.

---

<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: [13 September 2023 14:44 UTC](https://discourse.nodered.org/t/mixed-configuration-property-or-optional/80909/4 "2023-09-13T14:44:25Z")

</div>

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