Node with custom parameters depending on input/selection?

How can I create a custom node that has input parameters depending on an input or a selection?

Like for example with the SpawnActor or AddComponent nodes that have a additional parameters depending on the selected class.