diff --git a/.vscode/settings.json b/.vscode/settings.json index d5bbfd87..f8b5c2c0 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -37,5 +37,6 @@ "reportUnknownMemberType": "none" }, "markdown.extension.toc.unorderedList.marker": "-", - "markdown.extension.toc.updateOnSave": true + "markdown.extension.toc.updateOnSave": true, + "python.analysis.autoImportCompletions": true } diff --git a/README.md b/README.md index 47871a4f..3d086003 100644 --- a/README.md +++ b/README.md @@ -545,7 +545,7 @@ See [CONTRIBUTING.md](CONTRIBUTING.md) for more information. | [`interactions-py`](https://pypi.org/project/discord-py-interactions) | MIT | Base | Wrapper | The backend of this bot! | | [Is It Down Right Now?](https://www.isitdownrightnow.com/) | - | Utility | API | Used for checking if a website is down | | [Jikan](https://jikan.moe/) | MIT | Anime, Profile, Verify | 3rd Party MAL API | Used for showing anime information, verify user, and show user's profile | -| [Kitsu](https://kitsu.io/) | Apache-2.0 | Anime | Database | Used for adding additional information to anime information, mainly background and poster | +| [Kitsu](https://kitsu.app/) | Apache-2.0 | Anime | Database | Used for adding additional information to anime information, mainly background and poster | | [Last.fm](https://www.last.fm/) | - | Profile | Database | Used for getting user's last.fm profile and scrobble summary | | [MyAnimeList](https://myanimelist.net/) | - | Anime | Database | Search and show anime information | | [nattadasu/animeApi](https://github.com/nattadasu/animeApi) | AGPL-3.0 | Random, Relation | Relation | Linking ID from a database to another database | diff --git a/classes/kitsu.py b/classes/kitsu.py index 3279771a..565f368f 100644 --- a/classes/kitsu.py +++ b/classes/kitsu.py @@ -16,7 +16,7 @@ class Kitsu: def __init__(self): """Initialize the Kitsu API Wrapper""" self.session = None - self.base_url = "https://kitsu.io/api/edge/" + self.base_url = "https://kitsu.app/api/edge/" self.params = None async def __aenter__(self): diff --git a/extensions/mediaautosend.py b/extensions/mediaautosend.py index 574f9077..25c8d3f1 100644 --- a/extensions/mediaautosend.py +++ b/extensions/mediaautosend.py @@ -57,12 +57,12 @@ async def kitsu_id_to_other_id( ) -> str | None: """Convert a Kitsu ID to another ID""" if not kitsu_id.isdigit(): - async with aiohttp.ClientSession() as session, session.get(f"https://kitsu.io/api/edge/{media_kind}?filter[slug]={kitsu_id}") as resp: + async with aiohttp.ClientSession() as session, session.get(f"https://kitsu.app/api/edge/{media_kind}?filter[slug]={kitsu_id}") as resp: if resp.status != 200: return None data = await resp.json() kitsu_id = data["data"][0]["id"] - async with aiohttp.ClientSession() as session, session.get(f"https://kitsu.io/api/edge/{media_kind}/{kitsu_id}/mappings") as resp: + async with aiohttp.ClientSession() as session, session.get(f"https://kitsu.app/api/edge/{media_kind}/{kitsu_id}/mappings") as resp: if resp.status != 200: return data = await resp.json() @@ -150,7 +150,7 @@ async def on_message_create(self, event: MessageCreate) -> None: case r"(?:https?://)?(?:www\.)?kitsu\.io/anime/(?P[\w\-]+)" as ids: media_id: str = ids["mediaid"] if not media_id.isdigit(): - async with aiohttp.ClientSession() as session, session.get(f"https://kitsu.io/api/edge/anime?filter[slug]={media_id}") as resp: + async with aiohttp.ClientSession() as session, session.get(f"https://kitsu.app/api/edge/anime?filter[slug]={media_id}") as resp: if resp.status != 200: return data = await resp.json() diff --git a/extensions/relations.py b/extensions/relations.py index cd8eca19..42514dc2 100644 --- a/extensions/relations.py +++ b/extensions/relations.py @@ -523,7 +523,7 @@ async def relations_shows( ) postsrc = "Notify.moe" elif anime_api.kitsu is not None: - poster = f"https://media.kitsu.io/anime/poster_images/{anime_api.kitsu}/large.jpg" + poster = f"https://media.kitsu.app/anime/poster_images/{anime_api.kitsu}/large.jpg" postsrc = "Kitsu" postsrc = f" Poster from {postsrc}" if postsrc else "" diff --git a/modules/platforms.py b/modules/platforms.py index 1deca39a..fa2f5e1a 100644 --- a/modules/platforms.py +++ b/modules/platforms.py @@ -282,7 +282,7 @@ def media_id_to_platform( "emoid": "1073441859910774784", }, "kitsu": { - "uid": f"https://kitsu.io/anime/{media_id}", + "uid": f"https://kitsu.app/anime/{media_id}", "emoid": "1073439152462368950", }, "myanimelist": {