While working on Fedimojis, I’d like to check that the link entered by the user is actually a Mastodon server, to avoid bugs or loading thousands of emojis from Pixelfed instances that don’t distinguish between local and external emojis.

How can I do this?

Most software responds to /.well-known/nodeinfo with this info iirc

retiolus
creator
link
fedilink
710M

Okay! So you first need to check /.well-known/nodeinfo to get /nodeinfo/2.0.json!

In the case of Pixelfed it’s in /api/nodeinfo/2.0.json

aliceif
link
fedilink
510M

@retiolus@lemmy.cat pretty much all software should be implementing nodeinfo: https://github.com/jhass/nodeinfo
usually reachable via HTTP on an endpoint like url/nodeinfo/2.0.json

A community dedicated to fediverse news and discussion.

Fediverse is a portmanteau of “federation” and “universe”.

Getting started on Fediverse;

  • 0 users online
  • 6 users / day
  • 1 user / week
  • 70 users / month
  • 614 users / 6 months
  • 1 subscriber
  • 964 Posts
  • 13.2K Comments
  • Modlog