mirror of
https://github.com/sigma67/ytmusicapi.git
synced 2026-04-25 07:16:00 +03:00
[GH-ISSUE #444] Ability to add playlist item to start of playlist #333
Labels
No labels
a/b
bug
documentation
enhancement
good first issue
help wanted
invalid
pull-request
question
wontfix
yt-error
yt-update
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/ytmusicapi#333
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @zeitmeister on GitHub (Sep 26, 2023).
Original GitHub issue: https://github.com/sigma67/ytmusicapi/issues/444
Is your feature request related to a problem? Please describe.
Describe the solution you'd like
add_playlist_itemthat allows the item to be added start of the playlist (push) instead of the end (append).Describe alternatives you've considered
moveItemparameters on theedit_playlistfunction but then i guess i would have to get the playlist programatically and retrieve the setvideoId of the top most track for every track that i would like to move which would result in a god awful amount of requests.Additional context
@sigma67 commented on GitHub (Sep 26, 2023):
I don't think it's possible. There is no way to do this on the web either. You can create a new playlist with the old one as the source playlist and the new videoId in front, but I doubt that's what you want.
And yeah, as you noted correctly, the only way to do this with the existing playlist would be with
edit_playlistandmoveItem.@zeitmeister commented on GitHub (Sep 27, 2023):
Yeah I understand. I did however find a way to make it the way I want. You can go to your playlist in YouTube interface (not YouTube music) and there you can edit your playlist settings to add videos to top of playlist!
So I'm closing this ticket.
@sigma67 commented on GitHub (Sep 27, 2023):
Can you add more detail on how you do that for others that might find this issue?
Depending on how the API interaction works it might then be possible to do this via the API. Afaik the playlist API is mostly equivalent between YTM and YT.
@zeitmeister commented on GitHub (Sep 27, 2023):
The payload of the request that youtube makes when i check the settings is:
So perhaps this could be implemented?
@sigma67 commented on GitHub (Sep 27, 2023):
Ah, it's a setting toggle. Interesting. Will have to experiment, but behind the scenes it's the same Innertube API, so it might be possible.
I'm just not sure how that would integrate with the existing API, we'd probably modify
edit_playlistwith a new parameter.@sigma67 commented on GitHub (Sep 27, 2023):
Thanks for the report. Last time I really touched this function was more than 3 years ago, so I barely remembered ^^