Bing Search Scraper - A Python library for retrieving search results from Bing
Project description
Bing Search Scraper
Overview
Easily scrape Bing search results using Python. This library leverages requests
for making HTTP requests and BeautifulSoup
for parsing HTML content. It offers both synchronous and asynchronous functionality for efficient retrieval of results.
Installation
Install via pip:
pip install bing-results-scraper
Usage
Synchronous Usage:
from bing_results_scraper import BingScraper
# Create a scraper instance
bing = BingScraper()
# Fetch results for a single query
results = bing.get_results(q='Query')
# Access the results
print(results['organic_results'])
Asynchronous Usage:
from bing_results_scraper import AsyncBingScraper
# Create an asynchronous scraper instance
async_bing = AsyncBingScraper()
# Fetch results for multiple queries
queries = ['Query 1', 'Query 2', 'Query 3']
results = async_bing.get_results(queries)
# Access the results for each query
for result in results:
print(result['organic_results'])
Features
- Synchronous and asynchronous scraping options
- Customizable headers
- Automatic query URL encoding
- Response status handling
- Retries for failed requests
- Parsed organic result data extraction
- Clear output structure
Contributing
Contributions are welcome! Please follow the standard fork-and-pull request workflow on GitHub.
Author
Renukumar
- LinkedIn: https://www.linkedin.com/in/renukumar-r/
- GitHub: https://github.com/Renukumar-R
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 bing-results-scraper-0.2.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3097a380c3a5e2c06eac787b33a8e1100dff36b13f98c1b01af39cb4817c3f3b |
|
MD5 | 8edb333463b3290c8d44d72f6b7bf73c |
|
BLAKE2b-256 | bfef92069bf2546f7552a3fda12b2f1883a5cef57e7330cc6aca0f028c8d8e37 |
Close
Hashes for bing_results_scraper-0.2.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e2950069aa7d8b39352c3bcf636c9a33d014c565b29b27cb8a48a97ee237df2b |
|
MD5 | 331503bcf6a12c871912634363102b4f |
|
BLAKE2b-256 | d8a573c089e6168d3bb6adf75a8bcea8f9b3c6cc580eb90a55451dd127212708 |