fixing the register/getall api method call