Implemented all API methods.