Metadata-Version: 2.1
Name: oppe
Version: 0.1.0
Summary: A Python API Wrapper for Oppe
Home-page: https://github.com/kilobyteno/oppe-for-python
Author: Kilobyte AS
License: MIT
Project-URL: Homepage, https://oppe.app
Project-URL: Documentation, https://docs.oppe.app
Project-URL: Github, https://github.com/kilobyteno/oppe-for-python
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
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: setuptools >=65.6.3
Requires-Dist: wheel >=0.41.2
Requires-Dist: python-dotenv >=1.0.0
Requires-Dist: requests >=2.31.0

# oppe-for-python
An API wrapper for [Oppe](https://oppe.app) written in Python.


## Installation

```bash
pip install oppe
```

## Usage

### Sending an event

```python
from oppe import Oppe
from oppe.exceptions import EventRequestError

oppe = Oppe(api_token='insert-api-token-here', project_id="uuid-of-project")

try:
    oppe.event(
        channel_id="uuid-of-channel",
        title="user-registered",
        description="A new user has registered.",
        emoji="👋",
        data={
            "user_id": 123,
        },
    )
except EventRequestError as e:
    # Handle error
    print(e)
```
