![Python 3.7, 3.8, 3.9](https://img.shields.io/badge/Python-3.7%2C%203.8%2C%203.9-3776ab.svg?maxAge=2592000)
[![Imports: isort](https://img.shields.io/badge/%20imports-isort-%231674b1?style=flat&labelColor=ef8336)](https://pycqa.github.io/isort/)
### Ghana Online Shops Scraper
A simple unofficial python package to scrape data from
[Tonaton](https://www.tonaton.com),
[JumiaGH](https://www.jumia.com.gh).
Affiliated to [Bank of Ghana Fx Rates](https://pypi.org/project/bank-of-ghana-fx-rates/)
[GhanaNews-Scraper](https://pypi.org/project/ghananews-scraper/).
### How to install
```shell
pip install ghanashops-scraper
```
### Example Google Colab Notebook
Click Here: [![Google Colab Notebook](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/drive/15i2Nh8inWTpg3GT2tLeRdP6ByI4j656b?usp=sharing)
### Outputs
- All outputs will be saved in a `.csv` file. Other file formats not yet supported.
- Format:
- ["product_description", "price", "location", "photo", "page_url"]
- ![tv.png](tv.png)
### Usage
+ Scrape shop data from [Tonaton](https://tonaton.com)
+ Example of search queries: cars, laptops, phones, vehicles, rent, houses, tablets, shoes, refrigerator
```python
from tonaton.scraper import Tonaton
search_query = "iphones"
tonaton = Tonaton(query=search_query)
tonaton.download()
```
### Limiting the number of pages to scrape.
+ Note: some pages may take longer depending on the count. Recommend `limiting` your pages.
```python
from tonaton.scraper import Tonaton
search_query = "laptops"
tonaton = Tonaton(query=search_query, limit_pages=10)
tonaton.download()
```
### Using Asyncio
+ DO NOT USE IN JUPYTER NOTEBOOKS OR GOOGLE COLAB. OTHER WAYS ARE ACCEPTED
```python
import asyncio
from tonaton.scrapy import Tonaton
search_query = "buses"
tonaton = Tonaton(query=search_query, limit_pages=10)
if __name__ == '__main__':
asyncio.run(tonaton.get_data())
tonaton.download()
```
BuyMeCoffee
-----------
[![Build](https://www.buymeacoffee.com/assets/img/custom_images/yellow_img.png)](https://www.buymeacoffee.com/theodondrew)
Credits
-------
- `Theophilus Siameh`
- Follow me on Twitter
- <div>
<a href="https://twitter.com/tsiameh"><img src="https://img.shields.io/twitter/follow/tsiameh?color=blue&logo=twitter&style=flat" alt="tsiameh twitter"></a>
</div>
Raw data
{
"_id": null,
"home_page": "https://github.com/donwany/ghanashops-scraper",
"name": "ghanashops-scraper",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.7",
"maintainer_email": "",
"keywords": "Scraper,Data,tonaton,jumia,GhanaNews,GhanaWeb,JoyNews,MyJoyOnline,News,Web Scraper,Ghana Scraper",
"author": "Theophilus Siameh",
"author_email": "theodondre@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/79/39/123328c30210be6ba1f41746ef9a831006d5df8ec480d5cce6e64e57ec31/ghanashops-scraper-0.0.11.tar.gz",
"platform": "any",
"description": "![Python 3.7, 3.8, 3.9](https://img.shields.io/badge/Python-3.7%2C%203.8%2C%203.9-3776ab.svg?maxAge=2592000)\n[![Imports: isort](https://img.shields.io/badge/%20imports-isort-%231674b1?style=flat&labelColor=ef8336)](https://pycqa.github.io/isort/)\n\n### Ghana Online Shops Scraper\n A simple unofficial python package to scrape data from \n [Tonaton](https://www.tonaton.com),\n [JumiaGH](https://www.jumia.com.gh).\n Affiliated to [Bank of Ghana Fx Rates](https://pypi.org/project/bank-of-ghana-fx-rates/)\n [GhanaNews-Scraper](https://pypi.org/project/ghananews-scraper/).\n\n### How to install\n```shell\npip install ghanashops-scraper\n```\n\n### Example Google Colab Notebook\n Click Here: [![Google Colab Notebook](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/drive/15i2Nh8inWTpg3GT2tLeRdP6ByI4j656b?usp=sharing)\n\n### Outputs\n - All outputs will be saved in a `.csv` file. Other file formats not yet supported.\n - Format: \n - [\"product_description\", \"price\", \"location\", \"photo\", \"page_url\"]\n - ![tv.png](tv.png)\n\n### Usage\n + Scrape shop data from [Tonaton](https://tonaton.com)\n + Example of search queries: cars, laptops, phones, vehicles, rent, houses, tablets, shoes, refrigerator\n```python\nfrom tonaton.scraper import Tonaton\n\nsearch_query = \"iphones\"\ntonaton = Tonaton(query=search_query)\ntonaton.download()\n```\n### Limiting the number of pages to scrape.\n + Note: some pages may take longer depending on the count. Recommend `limiting` your pages.\n```python\nfrom tonaton.scraper import Tonaton\n\nsearch_query = \"laptops\"\ntonaton = Tonaton(query=search_query, limit_pages=10)\ntonaton.download()\n```\n\n### Using Asyncio\n + DO NOT USE IN JUPYTER NOTEBOOKS OR GOOGLE COLAB. OTHER WAYS ARE ACCEPTED\n```python\nimport asyncio\nfrom tonaton.scrapy import Tonaton\n\nsearch_query = \"buses\"\ntonaton = Tonaton(query=search_query, limit_pages=10)\n\nif __name__ == '__main__':\n asyncio.run(tonaton.get_data())\n tonaton.download()\n```\n\n\n\nBuyMeCoffee\n-----------\n[![Build](https://www.buymeacoffee.com/assets/img/custom_images/yellow_img.png)](https://www.buymeacoffee.com/theodondrew)\n\nCredits\n-------\n- `Theophilus Siameh`\n- Follow me on Twitter\n- <div>\n <a href=\"https://twitter.com/tsiameh\"><img src=\"https://img.shields.io/twitter/follow/tsiameh?color=blue&logo=twitter&style=flat\" alt=\"tsiameh twitter\"></a>\n </div>\n\n",
"bugtrack_url": null,
"license": "MIT License",
"summary": "A python package to scrape data from Ghana online shops",
"version": "0.0.11",
"project_urls": {
"Homepage": "https://github.com/donwany/ghanashops-scraper"
},
"split_keywords": [
"scraper",
"data",
"tonaton",
"jumia",
"ghananews",
"ghanaweb",
"joynews",
"myjoyonline",
"news",
"web scraper",
"ghana scraper"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "12202867421305a28b016ef85e0589cd9b508400aecf37abaf5084c248db15e2",
"md5": "4ac0e156e5e4dd9e0411d94a45126295",
"sha256": "127caffa8ab9ffe76b2dadf33cd149b0305453d86bdc01452e35f66265fec14d"
},
"downloads": -1,
"filename": "ghanashops_scraper-0.0.11-py3-none-any.whl",
"has_sig": false,
"md5_digest": "4ac0e156e5e4dd9e0411d94a45126295",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.7",
"size": 11371,
"upload_time": "2023-05-03T05:04:44",
"upload_time_iso_8601": "2023-05-03T05:04:44.659365Z",
"url": "https://files.pythonhosted.org/packages/12/20/2867421305a28b016ef85e0589cd9b508400aecf37abaf5084c248db15e2/ghanashops_scraper-0.0.11-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "7939123328c30210be6ba1f41746ef9a831006d5df8ec480d5cce6e64e57ec31",
"md5": "51e4c580c1774802bd020a2a2157ec65",
"sha256": "de8551fd0f1c07a2a360622cfd0eba9c7aa834d843a18efc11581db8f69d407a"
},
"downloads": -1,
"filename": "ghanashops-scraper-0.0.11.tar.gz",
"has_sig": false,
"md5_digest": "51e4c580c1774802bd020a2a2157ec65",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.7",
"size": 5655,
"upload_time": "2023-05-03T05:04:47",
"upload_time_iso_8601": "2023-05-03T05:04:47.538917Z",
"url": "https://files.pythonhosted.org/packages/79/39/123328c30210be6ba1f41746ef9a831006d5df8ec480d5cce6e64e57ec31/ghanashops-scraper-0.0.11.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-05-03 05:04:47",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "donwany",
"github_project": "ghanashops-scraper",
"github_not_found": true,
"lcname": "ghanashops-scraper"
}