Files
tvj-epg/epg/models.py
T
Lyncoln af59324d99
Build and Publish TVJ EPG Image / build (push) Successful in 29s
Refactor EPG into shared engine with configurable TVJ channels
2026-09-10 09:49:40 -04:00

28 lines
713 B
Python

"""Common channel and programme definitions shared by providers and writers."""
from dataclasses import dataclass
from datetime import datetime
from xml.etree.ElementTree import Element
@dataclass(frozen=True)
class Channel:
id: str
name: str
stream_url: str
provider: str = "univtec"
channel_id: str = ""
feed_url: str = "https://insight-api-shared.univtec.com/interface/epg"
tenant: str = "rjr"
icon: str = ""
group: str = "General"
@dataclass(frozen=True)
class Programme:
start: datetime
stop: datetime
title: str
description: str
# Optional XMLTV elements normalized by the provider (category, rating, etc.).
metadata: tuple[Element, ...] = ()