Add exception if connection fails
Updated search API