Open nonab opened 4 days ago
Current version is very legacy, so I've checked my latest code to update master
and looks like it stopped to work.
Probably they have changed API again, as month ago my legacy mobile app said that it won't work any longer and I need to update.
Can't say when I will have time to work on it. I will post update here.
My app (based on this code ported to C#) seems to still be working just fine)
My app (based on this code ported to C#) seems to still be working just fine)
Do you know a method to retrieve chapter data?
My app (based on this code ported to C#) seems to still be working just fine)
Do you know a method to retrieve chapter data?
Usually first try to .get_shelf
to get IDs for your books there.
Then i.e. to download books (in this example books IDs are hardcoded):
audiobook_ids = [
('c387a9b3-4426-4137-9da9-aaec57aa53ca', 'hiszpanski-rozmowki-powiedz-to'),
('a10e3321-a874-4879-868d-154eef9804cd', 'dygat-podroz')
]
for audiobook in audiobook_ids:
audiobook_id, audiobook_name = audiobook
Path(f"./{audiobook_name}").mkdir(exist_ok=True)
tracks_list = self.api.get_audiobook_track_list(audiobook_id)
print(tracks_list)
for track in tracks_list['_embedded']['app:track']:
file_data = self.api.get_track(track['_links']['app:file']['href'])
r = self.api._session.get(file_data['url'])
Path(f"./{audiobook_name}/{track['title']}.mp3").write_bytes(r.content)
i wasn't able to find it but in readme you say it's possible. can you show me how ?