Basic class structure. Implemented error 400 and 501