Metadata-Version: 2.1
Name: libtvdb
Version: 0.12.1
Summary: A wrapper around the TVDB API.
Home-page: https://github.com/dalemyers/libtvdb
License: MIT
Keywords: tvdb,tv,tv database,tv show
Author: Dale Myers
Author-email: dale@myers.io
Requires-Python: >=3.11,<4.0
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Software Development :: Libraries
Requires-Dist: deserialize (>=2.1.0,<3.0.0)
Requires-Dist: requests (>=2.32.3,<3.0.0)
Project-URL: Repository, https://github.com/dalemyers/libtvdb
Description-Content-Type: text/markdown

# libtvdb

[![CI](https://github.com/dalemyers/libtvdb/workflows/CI/badge.svg)](https://github.com/dalemyers/libtvdb/actions)
[![PyPI version](https://badge.fury.io/py/libtvdb.svg)](https://badge.fury.io/py/libtvdb)
[![Python 3.11+](https://img.shields.io/badge/python-3.11+-blue.svg)](https://www.python.org/downloads/)

A wrapper around the [TVDB API](https://api.thetvdb.com/swagger).

## Installation

```bash
pip install libtvdb
```

## Examples

Searching for shows:

```python
import libtvdb

client = libtvdb.TVDBClient(api_key="...", pin="...")
shows = client.search_show("Doctor Who")

for show in shows:
    print(show.name)
```

## Development

This project uses [Poetry](https://python-poetry.org/) for dependency management.

```bash
# Install dependencies
poetry install

# Run tests
poetry run pytest

# Run linters and type checkers
poetry run ruff check libtvdb
poetry run black --check libtvdb tests
poetry run pylint libtvdb
poetry run mypy libtvdb
poetry run pyright libtvdb
```

## Advanced

You can set `libtvdb_api_key` and `libtvdb_pin` in your OS X keychain if you don't want to supply these every time. If any of the values supplied to the `TVDBClient` constructor are `None`, it will look into your keychain and load the appropriate value. If it can't find them, it will throw an exception.

