[GH-ISSUE #104] got my account suspended #78

Closed
opened 2026-02-27 22:07:53 +03:00 by kerem · 3 comments
Owner

Originally created by @Xart3mis on GitHub (Nov 14, 2020).
Original GitHub issue: https://github.com/sigma67/ytmusicapi/issues/104

Originally created by @Xart3mis on GitHub (Nov 14, 2020). Original GitHub issue: https://github.com/sigma67/ytmusicapi/issues/104
kerem closed this issue 2026-02-27 22:07:54 +03:00
Author
Owner

@sigma67 commented on GitHub (Nov 14, 2020):

What did you do? Did you abuse it? I've been using this project since it exists and never had any issue. Like many others using this API.

<!-- gh-comment-id:727233035 --> @sigma67 commented on GitHub (Nov 14, 2020): What did you do? Did you abuse it? I've been using this project since it exists and never had any issue. Like many others using this API.
Author
Owner

@Xart3mis commented on GitHub (Nov 17, 2020):

i didnt abuse it-
here's the code lol, i ran it every month or so to share my likes with my friends

import json
from ytmusicapi import YTMusic

ytmusic = YTMusic('headers_auth.json')
Json = open('data.json', 'w', encoding='utf-8', errors='')

PlaylistName = str(input('Name Of Playlist>>'))

playlists = ytmusic.get_library_playlists()

PlaylistID = None

for i in playlists:
    playlist = json.dumps(i)
    Json.write(f'\n{playlist}\n')
    #print(playlist + '\n')

    if i['title'] == PlaylistName:
        PlaylistID = i['playlistId']
        print(i["title"])

Json.write('\n\n')
likes = ytmusic.get_liked_songs(limit=100)

# print()

likes = json.dumps(likes)
likes = json.loads(likes)

likedSongs = likes['tracks']

# print(likedSongs)

videoIDs = []

for s in likedSongs:
    RawLikes = json.dumps(s)
    Json.write(f'{RawLikes}\n\n')

    ID = json.loads(RawLikes)['videoId']
    videoIDs.append(ID)

print(videoIDs)
Json.write(f'\n{videoIDs}\n\n')

ytmusic.add_playlist_items(PlaylistID, videoIDs)
print('DONE')

<!-- gh-comment-id:729123359 --> @Xart3mis commented on GitHub (Nov 17, 2020): i didnt abuse it- here's the code lol, i ran it every month or so to share my likes with my friends ``` import json from ytmusicapi import YTMusic ytmusic = YTMusic('headers_auth.json') Json = open('data.json', 'w', encoding='utf-8', errors='') PlaylistName = str(input('Name Of Playlist>>')) playlists = ytmusic.get_library_playlists() PlaylistID = None for i in playlists: playlist = json.dumps(i) Json.write(f'\n{playlist}\n') #print(playlist + '\n') if i['title'] == PlaylistName: PlaylistID = i['playlistId'] print(i["title"]) Json.write('\n\n') likes = ytmusic.get_liked_songs(limit=100) # print() likes = json.dumps(likes) likes = json.loads(likes) likedSongs = likes['tracks'] # print(likedSongs) videoIDs = [] for s in likedSongs: RawLikes = json.dumps(s) Json.write(f'{RawLikes}\n\n') ID = json.loads(RawLikes)['videoId'] videoIDs.append(ID) print(videoIDs) Json.write(f'\n{videoIDs}\n\n') ytmusic.add_playlist_items(PlaylistID, videoIDs) print('DONE') ```
Author
Owner

@sigma67 commented on GitHub (Nov 17, 2020):

And how do you know it was the reason your account was suspended? Seems like some very basic calls, which many others are using without issue

<!-- gh-comment-id:729281611 --> @sigma67 commented on GitHub (Nov 17, 2020): And how do you know it was the reason your account was suspended? Seems like some very basic calls, which many others are using without issue
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/ytmusicapi#78
No description provided.