Added Identifier to base and implementation
This commit is contained in:
@@ -88,6 +88,14 @@ class MusicProviderClient(ABC):
|
||||
"""
|
||||
Abstract base class defining the interface for music provider clients.
|
||||
"""
|
||||
@property
|
||||
@abstractmethod
|
||||
def _identifier(self) -> str:
|
||||
"""
|
||||
A unique identifier for the music provider.
|
||||
Must be implemented by all subclasses.
|
||||
"""
|
||||
pass
|
||||
|
||||
@abstractmethod
|
||||
def authenticate(self, credentials: dict) -> None:
|
||||
|
||||
@@ -32,6 +32,9 @@ class SpotifyClient(MusicProviderClient):
|
||||
"""
|
||||
Spotify implementation of the MusicProviderClient.
|
||||
"""
|
||||
@property
|
||||
def _identifier(self) -> str:
|
||||
return "Spotify"
|
||||
|
||||
def __init__(self, cookie_file: Optional[str] = None):
|
||||
self.base_url = "https://api-partner.spotify.com"
|
||||
|
||||
Reference in New Issue
Block a user