Feature request
- Add playback progress syncing for Hardcover, not just status updates.
- BookPlayer currently appears to mark a matched Hardcover book as “Currently Reading” after the reading threshold, and “Read” when finished.
- It would be useful if BookPlayer also updated the active Hardcover read record with the current audiobook position during playback.
I know #1362 (comment) says that it's not possible yet, but I noticed other apps like Grimmory do this now. I've linked their code below.
Narrative
GIVEN:
- I have connected Hardcover in BookPlayer.
- A local audiobook is matched to a Hardcover book.
- I am listening to the audiobook in BookPlayer.
WHEN:
- Playback progresses past the configured Hardcover reading threshold.
- Playback continues over time.
- The audiobook is eventually finished.
THEN:
- The book should be marked as “Currently Reading” in Hardcover, as it is today.
- BookPlayer should periodically sync the current listening position to Hardcover during playback.
- For audiobooks, this could use Hardcover’s
user_book_read progress field, ideally progress_seconds.
- When the book is finished, BookPlayer should send the final progress and mark the Hardcover read as finished / read.
Design
Possible implementation approach:
- Keep the existing
HardcoverService progress subscription.
- After the reading threshold is crossed, ensure the book exists in the user’s Hardcover library as
reading.
- Find or create an open
user_book_read record for the Hardcover userBookID.
- During playback, throttle progress updates so Hardcover is not called too often, for example every 60 seconds or only when progress changes meaningfully.
- Send the local playback position as
progress_seconds.
- On finish, update the read record one last time with final
progress_seconds and finished_at, then mark the book as read.
Other projects appear to do similar Hardcover progress syncing:
- Grimmory syncs progress to Hardcover and updates or inserts
user_book_read entries:
- Audiobookshelf Hardcover Sync uses
DatesReadInput with progress_seconds and updates user_book_read:
Feature request
I know #1362 (comment) says that it's not possible yet, but I noticed other apps like Grimmory do this now. I've linked their code below.
Narrative
GIVEN:
WHEN:
THEN:
user_book_readprogress field, ideallyprogress_seconds.Design
Possible implementation approach:
HardcoverServiceprogress subscription.reading.user_book_readrecord for the HardcoveruserBookID.progress_seconds.progress_secondsandfinished_at, then mark the book asread.Other projects appear to do similar Hardcover progress syncing:
user_book_readentries:DatesReadInputwithprogress_secondsand updatesuser_book_read: