NactivityPub is an implementation of ActivityPub (and underlying ActivityStreams) standards for Common Lisp.
Features:
- Parsing and un-parsing ActivityStreams JSON-LD objects to/from CLOS objects with convenient accessors on those.
- Sending and fetching ActivityStreams objects from the ActivityStreams-enabled HTTP(S) URLs.
- Semantic info extraction with methods like
name*
,url*
,author*
,published*
,items*
. - No reliance on JSON parser—simply use (or implement, if it’s not yet there) your preferred JSON backend for NJSON, and don’t depend on additional JSON libraries.
Clone the Git repository to where the compiler can find it:
git clone --recursive https://github.com/atlas-engineer/nactivitypub ~/common-lisp/
And then load
- All the NactivityPub dependencies.
- NJSON backend you prefer, and
- NactivityPub itself:
(ql:quickload :njson/cl-json)
(ql:quickload :nactivitypub)
And hack away, fetching objects from ActivityPub-enabled pages and playing with those in REPL:
(nactivitypub:name* (nactivitypub:fetch-object "https://ephemeral.glitch.social/@aartaka"))
;; => "Stuffed Plush Capybara"
See package.lisp for a more high-level overview of the API, and docstrings of the exported methods for more granular info.
- [ ] Parse JSON-LD according to the standard.
- [ ] Fetch JSON-LD schemes and somehow transform those into CLOS objects/classes too.
- [ ] Add tests.