Hacker News new | ask | show | jobs
by zimpenfish 1248 days ago
> There are very few reasons any client implementing MastoAPI shouldn't also support Akkoma/Pleroma.

Depends how you implement it. e.g. If you use `int64` for your IDs, Akkoma and GotoSocial won't work. Or if you send your POST parameters in the URL, Akkoma won't work. There's other subtle stuff too - toot codes unset optional fields as `null` in the JSON it sends (rather than leaving them out) which breaks both Akkoma and GotoSocial.

In summary, someone needs to write a decent MastoAPI spec and get everyone to agree on that rather than this ad-hoc balkanisation.

1 comments

The API (https://docs.joinmastodon.org/entities/Status/#id) explains that IDs are not numbers:

    Description: ID of the status in the database.
    Type: String (cast from an integer but not guaranteed to be a number)
    Version history:
0.1.0 - added

In other words, even the Mastodon API docs claim the ID isn't guaranteed not to be a string.

I'm sure there are undocumented differences, but if you base your data model on the spec then there's no reason to even assume you can just use a number.

That was added after the developers of Toot! (iOS app) claimed Pleroma was at fault for it not working with their app because they implemented MastoAPI wrong.

Toot! seems to work with Akkoma/Pleroma now, but notifications are still somewhat lossy.