jamiesanson / Mammut

An Android Client for Mastodon
GNU General Public License v3.0
47 stars 4 forks source link

Mammut fails to detect that the instance is working #19

Open annando opened 3 years ago

annando commented 3 years ago

I'm currently implementing the Mastodon API at Friendica. At the moment I'm testing several apps. Mammut fails to register at my server. When entering the URL it answers with "it looks like this instance doesn't exist".

In the protocols I see that there is an request to /api/v1/instance which is answered with code 200 from the server side - so the connection is successful.

From the code it look like the message is generated here: https://github.com/jamiesanson/Mammut/blob/main/app/src/main/java/io/github/koss/mammut/feature/joininstance/JoinInstanceViewModel.kt#L63

I guess that Mammut is fetching the instance data and is looking for something that Friendica doesn't provide or does provide differently. What can I do from my side to convince Mammut that my instance is running?

annando commented 3 years ago

Update: There had been a malformated entry in /api/v1/instance that seemed to provoke the problem. This is fixed. But still the registration process does not work. When requesting the token the program is taking an outdated client id and client secret from a previous registration attempt.

According to my logs, Mammut is using the newly created client id to authorize the request, but then uses some old client id to fetch the token - which does fail.