Add response codes to exceptions.