A private and public composable atproto PDS, and an alternative to MCP and A2A where work travels as signed records, not calls.
FastATP has no shared secrets. No password, token, or session crosses the wire, and a signing key never leaves the device it was made on. A private repo is reachable only by the peers its owner admits, and admitting one is a signed record that deleting revokes. Work is signed records too, so it needs no call held open, and every step can be checked later by anyone.
You commit a signed, content-addressed record to your own repo. It is authored by your key, addressed by DID, and verifiable by anyone, forever. Any peer you have admitted picks it up, acts on its own clock, and commits a signed reply. No authority issues a token. No connection is held open. No message can be forged, and every hop of provenance survives.
The difference from MCP and A2A in one line: a call returns a value and vanishes; a FastATP record is durable evidence that exists or doesn't. There is nothing to time out, only a signed record that anyone, anywhere, later, offline, can verify came from exactly who it claims.
FastATP implements the identity and signing primitives of the AT Protocol (atproto) for use outside the social web. It is unaffiliated with Bluesky and avoids social-web assumptions. A pressure sensor, a payroll job, and a language model are the same kind of peer here: identity and signed records for agents, workloads, and IoT, not an AI SDK. The signing core is transport-agnostic: it turns typed records into signed bytes and back, and never opens a socket itself.
Run as a server, a FastATP peer is a personal data server (PDS) you run as a
library: it serves its own DID document, hosts signed repos, and speaks the
atproto firehose and sync routes, so relays, mirrors, and the atproto SDK read
it like any other host. It is a PDS at the sync level, by design. It has no
sessions, no login routes, and no app.bsky, because the wire is the contract,
and a login is the thing the wire replaces.
PHILOSOPHY.mdis the canonical statement of what this is and what it forbids. This README is its front door.
Tutorials
Runnable guides, one per pull request, each building on the one before it. Every guide runs against the fastatp in the tree: its machines on a private LAN inside Docker, each a personal data server of its own, read along and typed, watched as a show in the browser, or played headless, so a guide breaks in the same change as the code it teaches. You need Docker with the compose plugin, nothing else.
Asking a coding agent about FastATP? Point it at
tutorials/AGENTS.md.
It can run the first guide itself with cd tutorials/lab && ./lab.sh test,
about five minutes on fresh machines, and answer you from what the machines
did.
| # | Guide | What it shows | Status |
|---|---|---|---|
| 1 | GETTING_STARTED.md |
Three sovereign peers on a private LAN: a PDS on each machine, signed records, verified following, a private channel behind a real WireGuard tunnel | runs |
| 2 | CONDUCTOR_AND_ORCHESTRA.md |
The engine that plays guide 1, taken apart, then put to work: a conductor orchestrates three machines with signed records, from one note to a tune, and nobody holds a connection open for a task | runs |
| 3 | HOOT.md |
Tool calling as signed records: an agent drops one request, two ride companies bid sealed from each other, a bank holds and pays, a car drives, and alice checks every step back to alice's own words | runs |
| 4 | GEESE.md |
A person reaching an app from a browser tab with no secret on the wire: sign up, log in, and let a second device in and out, while the app keeps the account without holding its key | runs |
To watch the first one as a show, with every machine's terminal, the network diagram, and the wire on one screen:
cd tutorials/lab
./lab.sh clean # start from the first minted identity
./lab.sh conductor # boots alice, bob and eve with the demo engine
Open http://localhost:8080, pick a chapter and press Next. The show is
four chapters of a few minutes each; a question every handful of presses,
answered by what the next press shows; a key concept stops the show until
Got it. Every step really runs on the machines, and the engine playing it
is FastATP too: the score, the code, and the pictures are records and blobs in
the conductor's own repo. ./lab.sh test plays the same show with nobody
watching and exits 0 when the whole guide played.
tutorials/README.md
has the three ways to run a guide and how to write one.
How it compares
MCP and A2A are, at heart, RPC with a login: reach an endpoint, present a credential some authority issued you, invoke a method, depend on that authority and that connection. They are excellent at that. FastATP removes the authority, makes every message self-verifying evidence, treats long-running and multi-party work as the default, and applies to any workload.
| Dimension | MCP | A2A | FastATP |
|---|---|---|---|
| Mental model | Client calls a server's tool | Agent calls a remote agent | Peer commits signed records; peers act on their own clock |
| Interaction | Request and response RPC | Task RPC (streaming, webhooks, or polling) | Async durable signed records |
| Identity | Server URL + OAuth | Agent Card at a URL + declared auth | DID (did:web, did:key) |
| Trust root | OAuth / token issuer | Web auth declared in the card (OAuth 2, OpenID Connect, API keys, mutual TLS) | None: cryptographic keys, per-record signatures |
| Message verifiable after the fact? | No built-in message signatures | No built-in message signatures (an Agent Card may be signed) | Yes: by anyone, offline, across hops |
| Topology | Host–client–server | Client-agent ↔ remote-agent | Symmetric peers |
| Authorization / revocation | Server-side token scopes | App logic + web auth | Signed capabilities + WireGuard admission; absence = unreachable; either side can cut the other off |
| Long-running work | An official extension (tasks, polled) | Supported (streaming, webhooks, polling) | Native: no connection held |
| Discovery | Configured by hand; an optional server/discover call |
Agent Card at a well-known URL, registries, or direct configuration | User-built, untrusted directory; no privileged registry |
| Domain | LLM tools / context | AI agents | Any workload: agents, services, IoT |
| Transport | stdio, Streamable HTTP | JSON-RPC, gRPC, HTTP+JSON/REST | Transport-agnostic (firehose / HTTP / MQTT / serial) |
Compared in November 2026 against the MCP specification, revision 2026-07-28, and the A2A specification, version 1.0.0.
When MCP or A2A is the better choice
Reach for them instead when:
- You want one model to use local tools right now, in one session. MCP is simpler and FastATP is overkill.
- You are building AI-agent interop inside existing web-auth infrastructure and want a turnkey, widely-supported protocol today. A2A is more batteries-included for that narrow case.
FastATP wins decisively when you need no trusted third party, cryptographic provenance that composes across hops, durable async or long-running work, a way for either side to cut the other off, or non-AI workloads. MCP and A2A do not give you all of these together.
FastATP and the atproto SDK
The atproto SDK
(PyPI, MIT, by MarshalX) is the Python
ecosystem's standard for AT Protocol. It is production-grade, battle-tested
against the live network, and the right choice for building on Bluesky or
talking to existing PDS hosts. FastATP and the SDK are complementary halves
of one wire: the SDK is a superb client of hosts, and FastATP is a way to
be a host, a personal data server (PDS) as a library. An SDK application
can read a FastATP-hosted repo today (see
examples/sensorthings_interop,
where an independent SDK-based package flattens a FastATP CAR export unmodified),
and a FastATP peer serves SDK users like any other host.
| Dimension | atproto SDK |
FastATP |
|---|---|---|
| What it is | Client library for AT Protocol services | Library for being an AT Protocol peer: your own personal data server (PDS) |
| Primary use case | Build on Bluesky; talk to PDS hosts; consume the network | Host your own signed repos; agent↔agent and user↔agent workflows |
| Auth model | Sessions / OAuth against a host (as the network's services expect) | No login surface: keys sign, capability records authorize, absence is revocation |
| Lexicon approach | Generated models from the official corpus, batteries included | User-defined: author any conforming lexicon in Pydantic; export valid lexicon JSON |
| Firehose role | Consume (production-hardened client) | Emit and consume, with full verification (signatures + MST inversion) |
| Repo role | Read via host APIs | Sign, host, prove, serve: MST repo, commits, CAR, prove() record proofs |
| Hosting | n/a (clients have hosts) | PDS-as-a-library: firehose + sync routes on your own box |
| Choose it when… | You're building an app or bot on the existing network: it's mature, complete, and maintained by the ecosystem's standard-bearer | You need to be your own host: no trusted third party, secure SaaS without a login wall, sovereign agents |
The sharpest way to see the difference: with FastATP, a secure multi-tenant
app needs no login wall. Users sign locally, hosts never hold a secret,
and presence of a signed capability record is authorization, and its absence is
revocation. To be precise about auth: OAuth is never in FastATP, but a
developer can build OAuth (or any auth UX) on top of it at the edge.
examples/bluesky_signup
does exactly that, with the OAuth library as the builder's dependency, never
FastATP's.
FastATP and its nearest neighbors
Other projects also sign data between identities their users own. These are the closest: what each shares with FastATP, where FastATP differs, and when the other is the better choice. Checked against each project's own documentation in November 2026.
| Project | What it shares | Where FastATP differs | Reach for it when |
|---|---|---|---|
| Urbit | An identity you own, and a personal server that talks peer to peer | An Urbit ID is registered on Ethereum and issued down a fixed hierarchy; a FastATP identity is a DID with no registry and no chain. Urbit is a whole operating system; FastATP is a library | You want a personal computer and its network, not a library |
| UCAN | Capabilities signed by DIDs, with no central issuer | A UCAN travels with each request, and taking one back is a separate revocation step; a FastATP capability is a record in a repo, in force while it is there and gone when it is deleted | You need to hand authority on in chains, to services that take requests |
| DIDComm | Messages between DIDs, with no login, over any transport | DIDComm signs and encrypts each message; FastATP never encrypts a record, keeps it in a repo others can sync and verify later, and gets privacy from who can reach the repo | You need each message encrypted end to end between the parties |
| Nostr | Signed data, not calls, with a key behind every identity | A Nostr identity is the key itself, with no standard way to rotate it, and events go out to relays; a FastATP identity is a DID whose keys can rotate, records have schemas, and a repo can be private | You want to publish to an open network of relays today |
| SPIFFE | Identity for workloads, with no shared secrets | A SPIFFE identity is issued by a trust domain's server once it has attested the workload; a FastATP peer makes its own key, and no authority issues anything | Your workloads live inside one organization that already runs the platform |
| Secure Scuttlebutt | A signed log per identity, replicated between peers | A Scuttlebutt feed is append-only, and nothing in it can be deleted or changed; a FastATP repo holds the present state, so deleting a record is how access is revoked | You want a log that works offline and never forgets |
Install
pip install fastatp
FastATP is 0.x: a minor release may break, a patch release never does. 0.2 to 0.3 can change or remove public API; 0.2.0 to 0.2.1 only fixes or adds. To take fixes without surprises, pin the minor line:
pip install "fastatp~=0.3.0" # at least 0.3.0, below 0.4Breaking changes are listed under Breaking in the
CHANGELOG.md.
FastATP speaks one wire format: atproto's. Records live in a signed, present-state repository; a record travels as a proof slice (signed commit + Merkle path + record) that anyone can verify with nothing but a DID resolver, over a firehose, HTTP, MQTT, or a serial line.
Five-minute prove / verify
A device signs a telemetry record; anyone verifies it later with only a DID resolver: no live connection to the device, no shared secret.
import asyncio
from datetime import datetime, timezone
from fastatp import Peer, Lexicon, build_did_document
from fastatp.crypto import generate_keypair
class PressureReading(Lexicon):
nsid = "com.example.telemetry.pressureReading"
pressure_psi: int
timestamp: datetime
async def main() -> None:
key = generate_keypair("k256")
did = "did:web:example.com:device-1"
doc = build_did_document(did=did, signing_key=key.public_key())
producer = Peer(did=did, signing_key=key) # or any fastatp.Signer: a TPM, an HSM
repo = await producer.create_repo()
await repo.put_record(
PressureReading.nsid,
"boot",
PressureReading(pressure_psi=1450, timestamp=datetime.now(timezone.utc)),
)
proof = repo.prove(PressureReading.nsid, "boot") # bytes; ride any transport
# In production the verifier resolves DIDs over HTTPS (web_resolver).
async def resolver(d: str):
return doc if d == did else None
record = await Peer(resolver=resolver).verify(proof, expected_signer=did)
print(record.pressure_psi) # 1450, proven to come from device-1's key
asyncio.run(main())
Dispatch, reply, admit: the PeerApp framework
PeerApp is a FastAPI-shaped layer over the primitives: route any lexicon to a
handler, reply with signed records, and admit or evict peers, where either side
can cut the other off. It ships mechanism, never application schemas: you
define your own request/reply lexicons.
from fastatp import PeerApp
app = PeerApp(server) # a PeerServer for this peer's DID
@app.on(InspectionRequest) # your lexicon, in your namespace
async def handle(req, ctx):
# work happens on your clock: there is no call waiting on the other side
result = InspectionResult(context_id=req.context_id, finding="within spec")
await app.emit(InspectionResult.nsid, generate_tid(), result) # a durable signed reply
# a private, one-shot reply on an ephemeral channel only the requester can read:
# await app.reply_private(ctx, result, ttl=120)
# consumer side, same call site as the public path:
# reply = await agent.call(tool_did, req, reply_type=InspectionResult, private=True)
The requester is a sensor, a service, or an agent, the same peer either way.
See examples/workorder.py
(public request/reply over a WireGuard-admitted firehose) and
examples/board_rendezvous.py
(a documentless requester and a private service meet at a public board and
exchange a private reply, end to end).
What's in the box
- Identity:
did:webanddid:key, DID documents, Multikey, low-S compact ECDSA (secp256k1 / P-256). The pen is a handle:Signerlets a key that never leaves a TPM, HSM, or secure element sign commits, and the package normalizes and verifies every signature before it is committed (no adapter shipped;docs/HOSTED-PEERS.mdsketches one). Optional self-certifyingdid:webcontinuity (Identity.bootstrap,ContinuityResolver): a twin named by a hash, with a chain signed at every key rotation, lets a reader that already knows the twin reject a key swapped in by someone who holds only the domain, with no registry. It does not vouch for an identity on first contact: a reader meeting the plain domain name for the first time has nothing to compare. - Lexicon layer: define any atproto-conforming schema as a Pydantic model
from a type palette;
to_lexicon_json()emits a validlexicon: 1document, and the bridge round-trips everycom.atproto.*schema. - Canonical records and repos: atproto-identical DAG-CBOR + CIDs (checked
against the interop vectors);
Repokeeps a signed Merkle Search Tree of the current state, with CAR export/import. Blocks a commit no longer needs are removed with it, so a repo holds its present state and no history. - Hosting and firehose:
PeerServeris the personal data server: it hosts one or many repos (routed by DID) behind acom.atproto.sync.subscribeRepos-shaped WebSocket with cursor resume;DIDServer, beside it, serves the peer's DID document;RepoMirrorverifies every commit against the producer's DID. A repo whose pen lives elsewhere is hosted frozen: the host serves it and takes the owner's signed pushes, and can never commit to it itself. Readers still verify; frozen is enforced in the host's code, not a property of its disk. - Authorization: signed capability records decide why a peer is allowed; a WireGuard peer set enforces it physically (absence = cryptographic unreachability). The reconciler keeps the two in step, in place of a coordination server, and either side can cut the other off. Records are never encrypted: confidentiality is reachability + isolation, not ciphertext.
- Private-response channels: ephemeral
did:keyrepos + signed attestations for one-shot private replies, with a per-repo doorman enforcing isolation. - Storage is one decision:
Storagebundles a repo's blocks, head, and blobs. The built-inSqliteStorageis whatIdentity.bootstrap(state_dir=)uses; bring your own database as a class with the same three stores (docs/HOSTED-PEERS.md, "Bring your own database"). The head store is a compare-and-swap, so several identical processes writing the same repos in one database can never fork them, and a restarted peer resumes its firehose seq. What the store does not do: refresh one process's in-memory repo from another's commits, or fan a commit out to subscribers connected elsewhere; an app that runs several processes builds that on the head store.
Philosophy
Read PHILOSOPHY.md.
It is canonical and governs the package. In one question: does this make
FastATP more like signed mail between sovereign peers, or more like RPC with a
login? The former is the direction; the latter is the thing it is deliberately
not.
Development
uv venv && uv pip install -e ".[dev]"
uv run pytest # conformance vectors are vendored in tests/vectors/
uv run ruff check fastatp tests && uv run mypy fastatp
Clone to develop; a pip install never needs a Rust toolchain (the browser
peer ships pre-built). Running the full suite (browser/WASM, WireGuard, and
cross-implementation tests) is covered in
docs/TESTING.md.
The tutorials are tests too: cd tutorials/lab && ./lab.sh test [GUIDE]
plays a guide headless against the fastatp in the tree (GETTING_STARTED
unless you name another, such as CONDUCTOR_AND_ORCHESTRA), and
uv run pytest fails when a guide's quoted files drift from the files
themselves. Every pull request plays every guide in CI, so a tutorial cannot
stop working without the change that broke it failing its tests.
See CONTRIBUTING.md
before opening a pull request, and
SECURITY.md
to report a vulnerability privately.
Releases
Releases are built in CI from a version tag: the workflow builds the browser
bundle, runs the full suite, builds the sdist and wheel, verifies their
contents, and publishes through PyPI trusted publishing. There are no API
tokens and no shared secrets anywhere in the pipeline, the same rule the
library lives by. Release candidates go to TestPyPI first; each publish waits
for maintainer approval. Changes are recorded in
CHANGELOG.md;
the versioning rule and release routine are in
CONTRIBUTING.md.
License
MIT. Copyright Jacob Lapenna.
Metadata
Release files for fastatp 0.3.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| fastatp-0.3.1.tar.gz | 898.8 kB | With provenance | Details for fastatp-0.3.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| fastatp-0.3.1-py3-none-any.whl | Python 3 | none | any | Details for fastatp-0.3.1-py3-none-any.whl |
Total release size: 1.3 MB
Release files / fastatp-0.3.1.tar.gz
| Download URL | fastatp-0.3.1.tar.gz |
|---|---|
| Size | 898.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
48690db4392002dc6eb8117eddce0f1f1e834a509e286f45e0339f6d69214266
|
|
BLAKE2b-256 checksum How to use checksums |
8785ce08a57729f99660bca8fe0f5c7bfb93343088391d31fe5ea464a8f69850
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 29, 2026.
Transparency logRelease files / fastatp-0.3.1-py3-none-any.whl
| Download URL | fastatp-0.3.1-py3-none-any.whl |
|---|---|
| Size | 404.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
407e98a4283ee798d546c7bd22509b0689e482b9c40dd97a9b2453e68ed4f569
|
|
BLAKE2b-256 checksum How to use checksums |
f283c08e8d2ae62f2a720946e9cdcda394535192d3676597565864dbc5921c46
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 29, 2026.
Transparency logSecurity for fastatp 0.3.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for fastatp-0.3.1.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 29, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.