Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add third-party identifiers #361

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion maloja/apis/native_v1.py
Original file line number Diff line number Diff line change
Expand Up @@ -595,6 +595,7 @@ def post_scrobble(
duration:int=None,
length:int=None,
time:int=None,
identifiers:dict={},
nofix=None,
auth_result=None,
**extra_kwargs):
Expand All @@ -608,6 +609,7 @@ def post_scrobble(
:param int duration: Actual listened duration of the scrobble in seconds. Optional.
:param int length: Total length of the track in seconds. Optional.
:param int time: UNIX timestamp of the scrobble. Optional, not needed if scrobble is at time of request.
:param dict identifiers: Key-value dictionary of third-party identifiers (MusicBrainz ID, Spotify ID, etc) associated with the track
:param flag nofix: Skip server-side metadata parsing. Optional.

:return: status (String), track (Mapping)
Expand All @@ -621,7 +623,10 @@ def post_scrobble(
'album_artists':albumartists,
'scrobble_duration':duration,
'track_length':length,
'scrobble_time':time
'scrobble_time':time,
'identifiers':{
**identifiers
}
}

# for logging purposes, don't pass values that we didn't actually supply
Expand Down