Remove usage of private hapi apis