Added support for conditionally required parameters