[misskey] add 'info' extractor (#5347)

This commit is contained in:
Mike Fährmann
2025-06-06 20:20:38 +02:00
parent ac09cac978
commit 5cd3f3977e
2 changed files with 15 additions and 4 deletions

View File

@@ -1424,25 +1424,25 @@ Consider all listed sites to potentially be NSFW.
<tr>
<td>Misskey.io</td>
<td>https://misskey.io/</td>
<td>Avatars, Backgrounds, Favorites, Followed Users, Images from Notes, User Profiles</td>
<td>Avatars, Backgrounds, Favorites, Followed Users, User Profile Information, Images from Notes, User Profiles</td>
<td></td>
</tr>
<tr>
<td>Misskey.design</td>
<td>https://misskey.design/</td>
<td>Avatars, Backgrounds, Favorites, Followed Users, Images from Notes, User Profiles</td>
<td>Avatars, Backgrounds, Favorites, Followed Users, User Profile Information, Images from Notes, User Profiles</td>
<td></td>
</tr>
<tr>
<td>Lesbian.energy</td>
<td>https://lesbian.energy/</td>
<td>Avatars, Backgrounds, Favorites, Followed Users, Images from Notes, User Profiles</td>
<td>Avatars, Backgrounds, Favorites, Followed Users, User Profile Information, Images from Notes, User Profiles</td>
<td></td>
</tr>
<tr>
<td>Sushi.ski</td>
<td>https://sushi.ski/</td>
<td>Avatars, Backgrounds, Favorites, Followed Users, Images from Notes, User Profiles</td>
<td>Avatars, Backgrounds, Favorites, Followed Users, User Profile Information, Images from Notes, User Profiles</td>
<td></td>
</tr>

View File

@@ -113,6 +113,17 @@ class MisskeyUserExtractor(MisskeyExtractor):
return self.api.users_notes(self.api.user_id_by_username(self.item))
class MisskeyInfoExtractor(MisskeyExtractor):
"""Extractor for a Misskey user's profile data"""
subcategory = "info"
pattern = BASE_PATTERN + r"/@([^/?#]+)/info"
example = "https://misskey.io/@USER/info"
def items(self):
user = self.api.users_show(self.item)
return iter(((Message.Directory, user),))
class MisskeyAvatarExtractor(MisskeyExtractor):
"""Extractor for a Misskey user's avatar"""
subcategory = "avatar"