zoedsoupe
pesque is a Personal Data Server (PDS) for ATProto, written in Elixir. I know most of elixir developers use bluesky and i really love digital sovereign and federation protocols, so it became natural t build a PDS in the language i love.
A PDS is the server that holds your account and your repository in the AT Protocol: it stores records, signs commits, hands those commits to anyone who asks, and answers describeServer well enough that a client can decide to talk to it.
What it does
- Account creation, with invite codes, did:web by default and did:plc when configured
- OAuth (PAR, PKCE, DPoP) alongside legacy session tokens, so both new and old clients work
- Signed repositories, public reads, blob storage, and a server-push firehose with cursor replay
- Identity, handle resolution, service auth, and rate limiting
What makes it different
State is one SQLite file and one directory of blobs. The idea was to deviate explicit from the official TypeScript implementation since the focus here is to provide a simpler implementation a single operator or a small community can maintain and self-host their own data/PDS, without handling complex deployments with Postgres, S3 and etc.
The protocol primitives (CIDs, DAG-CBOR, the Merkle Search Tree, CAR archives, TIDs, JWTs, secp256k1) are implemented in-house since this is the funny coding part of the challenge =p.
The code is split three ways and the dependency direction only points down: a pure protocol core (Pesque.CBOR, Pesque.CID, Pesque.Mst, Pesque.Car, Pesque.Commit), an imperative shell that touches the world (Pesque.RepoStore, Pesque.Storage, Pesque.Accounts), and an HTTP edge (PesqueWeb.*). Writes serialize through one process per repository, which is the consistency model a PDS actually needs.
Status
Already workings asking for feedback and improvements! I’ll try to migrate my own account from did:plc (zoedsoupe.zeetech.io) to my own instance and will try to document the experience + found bugs.
Not implemented yet: signPlcOperation and requestPlcOperationSignature (the old PDS signs the move), and granular OAuth consent.
Running it
Needs Elixir 1.19+ and a C toolchain (the SQLite driver compiles from source).
MIX_ENV=prod mix deps.get, release
To host an account:
mix pesque.create_account --handle alice.example.com --email alice@example.com
Guides
- Installation, identity, operations and migration guides live in
docs/guides - The architecture reference (module map, write path, storage layout) is in
docs/reference/architecture.md
Feedback
I’d love feedback, especially from people who know ATProto or have operated a PDS, and from anyone who reads the protocol code and disagrees with a choice. What’s missing, what’s wrong, what you’d want next.
Trending in Announcing
Other Trending Topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #library
- #deployment
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #elixirconf
- #channels
- #exunit
- #code-sync
- #discussion
- #podcasts
- #javascript
- #onsite
- #dialyzer
- #docker
- #authentication
- #ai
- #elixirconf-us
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #blog-post
- #ecto-query
- #elixir-ls
- #phoenix_html
- #iex
- #graphql
- #genstage
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #security
- #elixirconf-eu
- #processes
- #api
- #forms
- #hex









