Skip to content

Commit

Permalink
fix: Use Aniyomi's tracker API clients
Browse files Browse the repository at this point in the history
  • Loading branch information
jmir1 committed Jan 28, 2024
1 parent 0d1ce0d commit d52e1c9
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 18 deletions.
13 changes: 2 additions & 11 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -237,21 +237,12 @@
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />

<data android:scheme="tachiyomi" />
<data android:scheme="aniyomi"/>

<data android:host="myanimelist-auth" />
<data android:host="anilist-auth" />
<data android:host="bangumi-auth" />
<data android:host="shikimori-auth" />
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.VIEW" />

<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />

<data android:scheme="aniyomi"/>

<data android:host="myanimelist-auth" />
<data android:host="simkl-auth"/>
</intent-filter>
</activity>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -614,7 +614,7 @@ class AnilistApi(val client: OkHttpClient, interceptor: AnilistInterceptor) {
}

companion object {
private const val clientId = "385"
private const val clientId = "5338"
private const val apiUrl = "https://graphql.anilist.co/"
private const val baseUrl = "https://anilist.co/api/v2/"
private const val baseMangaUrl = "https://anilist.co/manga/"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -315,14 +315,14 @@ class BangumiApi(
)

companion object {
private const val clientId = "bgm10555cda0762e80ca"
private const val clientSecret = "8fff394a8627b4c388cbf349ec865775"
private const val clientId = "bgm293165b66d7e58156"
private const val clientSecret = "21d5f5c19ac24b4bc9c855ffa2387030"

private const val apiUrl = "https://api.bgm.tv"
private const val oauthUrl = "https://bgm.tv/oauth/access_token"
private const val loginUrl = "https://bgm.tv/oauth/authorize"

private const val redirectUrl = "tachiyomi://bangumi-auth"
private const val redirectUrl = "aniyomi://bangumi-auth"

fun authUrl(): Uri =
loginUrl.toUri().buildUpon()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -321,15 +321,15 @@ class ShikimoriApi(
)

companion object {
private const val clientId = "1aaf4cf232372708e98b5abc813d795b539c5a916dbbfe9ac61bf02a360832cc"
private const val clientSecret = "229942c742dd4cde803125d17d64501d91c0b12e14cb1e5120184d77d67024c0"
private const val clientId = "aOAYRqOLwxpA8skpcQIXetNy4cw2rn2fRzScawlcQ5U"
private const val clientSecret = "jqjmORn6bh2046ulkm4lHEwJ3OA1RmO3FD2sR9f6Clw"

private const val baseUrl = "https://shikimori.one"
private const val apiUrl = "$baseUrl/api"
private const val oauthUrl = "$baseUrl/oauth/token"
private const val loginUrl = "$baseUrl/oauth/authorize"

private const val redirectUrl = "tachiyomi://shikimori-auth"
private const val redirectUrl = "aniyomi://shikimori-auth"

fun authUrl(): Uri = loginUrl.toUri().buildUpon()
.appendQueryParameter("client_id", clientId)
Expand Down

0 comments on commit d52e1c9

Please sign in to comment.