A minimal AP server-to-server client for Haskell and Rust
Find a file
2025-05-30 17:20:21 +02:00
hs Clean up & bump to v0.3.0 ig 2025-05-10 17:21:25 +02:00
rs Make Key struct cloneable 2025-05-30 17:20:21 +02:00
.gitignore Implement request signatures; add live tests 2025-04-19 10:20:21 +02:00
Cargo.lock Make Key struct cloneable 2025-05-30 17:20:21 +02:00
Cargo.toml Make public & private key components cloneable 2025-05-30 17:12:10 +02:00
flake.lock Improve nix infra; expose packages from flake 2025-05-10 16:21:51 +02:00
flake.nix Improve nix infra; expose packages from flake 2025-05-10 16:21:51 +02:00
LICENSE Add license & update README 2025-05-10 17:13:48 +02:00
README.md Add license & update README 2025-05-10 17:13:48 +02:00
reqin.cabal Make public & private key components cloneable 2025-05-30 17:12:10 +02:00
Setup.hs Reorganize; add Setup.hs 2025-03-08 23:18:56 +01:00

Reqin 🦈

Reqin is a toolkit for executing requests using and related to the ActivityPub protocol from the Rust and Haskell programming languages.

Specifically, Reqin supports resolving a social handle to a JRD, fetching an ActivityPub object using a signed request, and delivering an activity to an actor's inbox. It can also make arbitrary signed GET requests to any URL.

Reqin is minimal by design. It covers only what is needed for the ActivityPuppy server-to-server implementation and that's it. It's also only tested to compile on Linux.

The library is mostly implemented in asynchronous Rust. Bindings for Haskell with collaboration between its RTS and Tokio are also part of this library.

No guarantees about whether they're actually efficient tho <3

Usage

Here's a basic example: using the library to obtain a JRD for the handle @azrael@tech.lgbt.

{-# LANGUAGE OverloadedStrings #-}

module Main where

import Reqin
import qualified Data.Aeson as A

main :: IO ()
main = do
  -- Values you put there go into the user agent string.
  c <- newClient "my-fedi-app" "0.0.0"
  jrd :: A.Value <- requestHandle c (Handle "azrael" "tech.lgbt")
  print jrd