James Sanford shared 1 year, 4 months ago

Under the covers with Mastodon. When you look up @Mastodon@mastodon.social, first a WebFinger request is sent to the domain.

curl 'https://mastodon.social/.well-known/webfinger?resource=acct:Mastodon@mastodon.social'

The response can include something like this:

  "links": [
    {
      "type": "application/activity+json",
      "href": "https://mastodon.social/users/Mastodon"
    }
  ]

Requesting that ActivityPub URL returns metadata including links to the outbox and inbox (for reading and sending messages) and their public key.

curl -H 'Accept: application/activity+json' 'https://mastodon.social/users/Mastodon'