def integration_test_yelp_retrieve_place_details(): client_api_key = os.environ['RYR_COLLECTOR_YELP_API_KEY'] client = CollectorClient('yelp', api_key=client_api_key) client.authenticate() epoch_search_summary = PlaceSearchSummary( 'krzzyozIVGC7pX1lfVO40w', 'Epoch Coffee', '221 West North Loop Boulevard, Austin', ) place_details = client.retrieve_place_details( epoch_search_summary.place_id, epoch_search_summary.name, epoch_search_summary.address, ) print(json.dumps(place_details))
def integration_test_full_google_yelp_workflow(): """""" places_api_key = os.environ['RYR_COLLECTOR_GOOGLE_PLACES_API_KEY'] yelp_api_key = os.environ['RYR_COLLECTOR_YELP_API_KEY'] epoch_latlong = (30.3186037, -97.72454019999999) gmaps_places = GoogleCollector() gmaps_places.authenticate(api_key=places_api_key) s = gmaps_places.search_places(epoch_latlong) epoch_search_summary = gmaps_places.retrieve_search_summary(1) yelp = CollectorClient('yelp', api_key=yelp_api_key) yelp.authenticate() place_details = yelp.retrieve_place_details( epoch_search_summary.place_id, epoch_search_summary.name, epoch_search_summary.address, ) print(json.dumps(place_details))