At the moment, the playback session API doesn't allow you to submit sessions from the past, so playback reporting plugins like the ListenBrainz and Last.fm plugin have no (proper) way to record such listens.1
A long time suggestion has been to add a timestamp to the ReportPlaybackStopped API
But because this would require a separate request for every recorded offline listen, I don't think this would be a good solution.
Instead, clients should be able to submit a list of listens once they are online again, which could then be submitted to the activity log and be broadcast to playback reporting plugins so that they could pick them up and submit them to an external service.
By making this an official API, behavior across various plugins could be streamlined and clients would only need to use the Jellyfin API and not need to bother with external services or third-party APIs.
Moreover, an official API should hopefully increase adoption among third-party music playback clients.
I've discussed this with the ListenBrainz plugin developer already and posted some further thoughts in lyarenei/jellyfin-plugin-listenbrainz#51.
There's also a draft for the API design in that ticket. I'd love to discuss the API proposition here further, and afterward work on getting this into the server, if accepted.
[1] The ListenBrainz plugin offers an alternative mode that does actually allow to retroactively submit listens, however, it comes with its own share of disadvantages as outlined in the docs above, and also requires one request per reported offline playback.
At the moment, the playback session API doesn't allow you to submit sessions from the past, so playback reporting plugins like the ListenBrainz and Last.fm plugin have no (proper) way to record such listens.1
A long time suggestion has been to add a timestamp to the ReportPlaybackStopped API But because this would require a separate request for every recorded offline listen, I don't think this would be a good solution. Instead, clients should be able to submit a list of listens once they are online again, which could then be submitted to the activity log and be broadcast to playback reporting plugins so that they could pick them up and submit them to an external service.
By making this an official API, behavior across various plugins could be streamlined and clients would only need to use the Jellyfin API and not need to bother with external services or third-party APIs. Moreover, an official API should hopefully increase adoption among third-party music playback clients.
I've discussed this with the ListenBrainz plugin developer already and posted some further thoughts in lyarenei/jellyfin-plugin-listenbrainz#51.
There's also a draft for the API design in that ticket. I'd love to discuss the API proposition here further, and afterward work on getting this into the server, if accepted.
[1] The ListenBrainz plugin offers an alternative mode that does actually allow to retroactively submit listens, however, it comes with its own share of disadvantages as outlined in the docs above, and also requires one request per reported offline playback.