I have a ghost user. I believe this user started to exist after someone mistakenly added me to their Home a long time ago (I was offering to help test something…didn’t realize they added me as a Home user until it wiped out all my shared stuff!). Anyway, I think one of their Managed Users is still attached to me in some way:
So I am the user that tortured xnaas and screwed up. Based on the fact that it is ONLY this user, it must be related to him being a managed user? I have more users and none of them showed up. He was added as a managed user since he is a child. Not sure how that helps him resolve this though.
If you just want to get rid of this user, you can try these solutions:
Make the API call to https://plex.tv/api/home/users/{userId}?X-Plex-Token={YOUR_TOKEN} using DELETE as the command. This can be done using curl or an application like Postman.
Just to triple check, that user isn’t at the bottom of the Friends listing in Users & Sharing?
Try these urls: https://plex.tv/api/friends/15557155?X-Plex-Token={YOUR_TOKEN}
or https://plex.tv/api/invites/requested/15557155?friend=0&server=1&home=0&X-Plex-Token={YOUR_TOKEN}
You were so close by using the python-plexapi as a reference. Here is the area that uses the url that worked.
code:
def removeFriend(self, user):
""" Remove the specified user from all sharing.
Parameters:
user (str): MyPlexUser, username, email of the user to be added.
"""
user = self.user(user)
url = self.FRIENDUPDATE if user.friend else self.REMOVEINVITE
url = url.format(userId=user.id)
return self.query(url, self._session.delete)