added status codes so the client side can better interact