return $this->response->withType("application/json")->withStringBody(json_encode($result));
By RakshaD at Oct 23 2020