I have tried web scraping for the first time by referring to the site below.
The following error occurred when I tried and obtained only API_KEY and CUSTOM_SEARCH_ENGINE and used the source code of the image collection as it was.
What is the problem?Thank you for your cooperation.python web-scraping
From the error message, the error occurred in the following places:
Therefore, I think there is a problem with the query_image content.
First, to see if the Google customsearch API is enabled, enter the following URL directly in the browser URL field:For API_KEY and CUSTOM_SEARCH_ENGINE, enter your number.
So, if you get an error, please check the API_KEY and CUSTOM_SEARCH_ENGINE settings again.The error is marked as Forbidden, so there is probably a problem with the configuration.Google API misconfiguration is common.
If you can see it correctly, print the query_img value, etc., and check if the query_img value is correct because
Custom Search APIs Explorer is located below.
© 2022 OneMinuteCode. All rights reserved.