added add_params_array function