Added optional parameter enforceArity that will require that the number of parameters required for each api method call is enforced