It makes sense to add the parameter validation to UI form.
Otherwise, errors in data formats may be left unnoticed