updated search to reduce API calls