Metadata-Version: 2.1
Name: ebird-pages
Version: 0.2.0
Summary: Scrapers for pages on the eBird web site
Author-email: Project Babbler <projectbabbler@gmail.com>
License: MIT License
Project-URL: Repository, https://github.com/ProjectBabbler/ebird-pages.git
Project-URL: Issues, https://github.com/ProjectBabbler/ebird-pages/issues
Project-URL: Changelog, https://github.com/ProjectBabbler/ebird-pages/blob/master/CHANGELOG.md
Keywords: eBird,web,scraper
Classifier: Development Status :: 3 - Alpha
Classifier: Environment :: Console
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Natural Language :: English
Classifier: Topic :: Utilities
Classifier: Topic :: Internet
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE.txt
Requires-Dist: beautifulsoup4>=4.12.3
Requires-Dist: lxml>=5.3.0
Requires-Dist: requests>=2.32.3

[![Build Status](https://travis-ci.org/ProjectBabbler/ebird-pages.svg?branch=master)](https://travis-ci.org/ProjectBabbler/ebird-pages)
[![PyPI version](https://badge.fury.io/py/ebird-pages.svg)](https://badge.fury.io/py/ebird-pages)
[![Supported Python Versions](https://img.shields.io/pypi/pyversions/ebird-pages.svg)](https://img.shields.io/pypi/pyversions/ebird-pages)

# eBird Pages

Although eBird has an API, not all the information from the database is
available. The API, for example, does not return links to any uploaded 
photos; comments on an individual observation are also missing. eBird Pages 
is a set of scrapers for extracting data from various pages on the eBird 
web site. It complements the API, giving access to all the data that eBird 
makes publicly available.

## Install

```sh
pip install ebird-pages
```

## Usage

Scraping the data from a page is as simple as a function call. For example
to get all the data from a checklist use get_checklist() and pass in the 
unique identifier generated when the checklist was submitted to the eBird
database:

```python
from ebird.pages import get_checklist

data = get_checklist('S38429565')
```
The function returns a dict with keys for the location, date, observers, etc.

You can also get the complete list of checklists from the "Recent Checklists"
page, e.g. https://ebird.org/region/US-MA/recent-checklists. From there you 
can download each checklist:

```python
import time

from ebird.pages import get_checklist, get_recent_checklists

for item in get_recent_checklists("US-MA"):
    checklist = get_checklist(item["identifier"])
    # Be nice and don't hit the servers as fast as possible
    time.sleep(10)
```


## Compatibility

ebird-pages works with all currently supported versions of Python (3.8+). 

## License

eBird Pages is available under the terms of the [MIT](https://opensource.org/licenses/MIT) license.
