diff options
-rw-r--r-- | README.md | 2 | ||||
-rw-r--r-- | pyfunkwhale/funkwhale.py | 11 |
2 files changed, 12 insertions, 1 deletions
@@ -71,7 +71,7 @@ List of features implemented or planned: - [x] Login with OAuth2 Authorization Code flow - [/] Artists - [x] List artists - - [ ] Retrieve a single artist + - [x] Retrieve a single artist - [ ] List available user libraries containing work from this artist - [ ] Albums - [ ] List albums diff --git a/pyfunkwhale/funkwhale.py b/pyfunkwhale/funkwhale.py index bca346a..99dcfae 100644 --- a/pyfunkwhale/funkwhale.py +++ b/pyfunkwhale/funkwhale.py @@ -40,3 +40,14 @@ class Funkwhale(object): params = self._build_params(arguments) return self.client.call('/artists/', 'get', params).json() + + def artist(self, _id, refresh: bool = False): + """ + Retrieve a single artist + """ + + arguments = locals() + + params = self._build_params(arguments) + + return self.client.call(f'/artists/{_id}', 'get', params).json() |