adding class that contains methods for endpoints and processes the request