PIP package to scrape and parse Google Search Results using SerpWow. Visit https://serpwow.com to get a free API key.
Project description
This Python package allows you to scrape and parse Google Search Results using SerpWow. In addition to Search you can also use this package to access the SerpWow Locations API and Account API.
Installation
You can install google-search-results-serpwow with:
$ pip install google-search-results-serpwow
and upgrade with:
$ pip install google-search-results-serpwow --upgrade
Simple Example
from google_search_results import GoogleSearchResults
import json
# create the serpwow object, passing in our API key
serpwow = GoogleSearchResults("api_key")
# set up a dict for the search parameters
params = {
"q" : "pizza"
}
# retrieve the search results as JSON
result = serpwow.get_json(params)
# pretty-print the result
print(json.dumps(result, indent=2, sort_keys=True)
Getting an API Key
To get a free API Key head over to app.serpwow.com/signup.
Searching with a location
from google_search_results import GoogleSearchResults
import json
# create the serpwow object, passing in our API key
serpwow = GoogleSearchResults("api_key")
# set up a dict for the query (q) and location parameters
# note that the "location" parameter should be a value
# returned from the Locations API
params = {
"q" : "pizza",
"location" : "New York,New York,United States"
}
# retrieve the search results as JSON
result = serpwow.get_json(params)
# pretty-print the result
print(json.dumps(result, indent=2, sort_keys=True)
Account API Example
The Account API allows you to check your current SerpWow usage and billing information.
from google_search_results import GoogleSearchResults
import json
# create the serpwow object, passing in our API key
serpwow = GoogleSearchResults("api_key")
# get our account info
result = serpwow.get_account()
# pretty-print the result
print(json.dumps(result, indent=2, sort_keys=True)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for google-search-results-serpwow-1.0.5.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 17cd4bbed52cde443f6827abd8945ab5846f20d8a4d99ed94911eafabdbb44b7 |
|
MD5 | c5760c5e8a59b0176e2d577fcd8add8a |
|
BLAKE2b-256 | dede800918de0d371a0fe275a159c2f0bf3d6d9ac3683db6b053bea01a891c53 |
Close
Hashes for google_search_results_serpwow-1.0.5-py2-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 88a83517af333bf8de5a300a92a30b776e2018e94de054314b04fc4c6b200224 |
|
MD5 | f90a73b3e38dae0cf8799448521dd6b4 |
|
BLAKE2b-256 | dd76608e2fc93cd1b42fd558a65ef23ae4bb2ec4e9b391f727f5355f14be0d8a |