I’ve been taking a look at the ActivityPub spec for a few evenings, and while it is a very well-written spec, what I actually wanted was examples of Mastodon’s implementation.
It turns out that Mastodon provides these! If you point
curl -H 'Accept: application/ld+json' at most Mastodon resources, you will get back the purest JSON-LD. So for instance, to get the
ActivityPub version of my profile, you would run:
curl -H 'Accept: application/ld+json' https://indieweb.social/@raphaelluckom
And if you look at the response to that request, you will see that it contains the URLs of many other interesting endpoints, such as my outbox, inbox, and the public key used by Mastodon on my behalf.
I hope this helps others trying to get a handle on the protocol as it is used, and I’d love to hear about what you’re working on!