Added ErrorCode Class and Fix reference error

* fix class reference error
* added ErrorCode class and update response code