Set param as 'required' iff required, else set as 'optional'
Merge pull request #251 from earldouglas/not-so-required

Set param as 'required' iff required, else set as 'optional'