CarpaNet.Jetstream
1.0.3
See the version list below for details.
dotnet add package CarpaNet.Jetstream --version 1.0.3
NuGet\Install-Package CarpaNet.Jetstream -Version 1.0.3
<PackageReference Include="CarpaNet.Jetstream" Version="1.0.3" />
<PackageVersion Include="CarpaNet.Jetstream" Version="1.0.3" />
<PackageReference Include="CarpaNet.Jetstream" />
paket add CarpaNet.Jetstream --version 1.0.3
#r "nuget: CarpaNet.Jetstream, 1.0.3"
#:package CarpaNet.Jetstream@1.0.3
#addin nuget:?package=CarpaNet.Jetstream&version=1.0.3
#tool nuget:?package=CarpaNet.Jetstream&version=1.0.3
CarpaNet.Jetstream

CarpaNet.Jetstream lets you connect to a Bluesky Jetstream instance.

This library is experimental and not stable. Expect issues and bugs!
The package contains two clients:
JetstreamV2Client— the current Jetstream service (bluesky-social/jetstream): thenetwork.bsky.jetstream.subscribeEventslive websocket plus the sealed-archive replay API. Use this for new code.JetstreamClient— the legacy v1/subscribewire.
Jetstream v2
SubscribeAsync is a managed stream: automatic reconnect with backoff, seq-based resume and dedup, optional dict-zstd compression with automatic dictionary fetch/rotation, and seamless archive-backfill-to-live cutover.
using var client = new JetstreamV2Client(
new Uri(BlueskyServices.JetstreamUsEast),
new JetstreamV2ClientOptions { EnableCompression = true });
var options = new JetstreamV2SubscribeOptions
{
Collections = new[] { "app.bsky.feed.post" }, // exact NSIDs or wildcards like app.bsky.feed.*
// LiveCursor = lastSeq, // resume a live tail from a saved seq
// AfterSeq = 0, // or: replay the whole sealed archive first, then go live
// SnapshotOnly = true, // or: archive dump only, no websocket
};
await foreach (var evt in client.SubscribeAsync(options, cts.Token))
{
if (evt.Kind == JetstreamV2EventKind.Commit && evt.Commit is { } commit)
{
Console.WriteLine($"[{commit.Operation}] seq={evt.Seq} {commit.Collection}/{commit.Rkey}");
// Typed records via your generated context:
// var post = commit.GetRecord(ATProtoJsonContext.Default.AppBskyFeedPost);
}
}
Persist the last evt.Seq and pass it back (LiveCursor for live, AfterSeq for replay) to resume. Delivery is at-least-once — fold idempotently or dedup by seq. The archive endpoints (PlanSnapshotAsync, GetSegmentAsync, GetBlockAsync, plus the JetstreamSegmentFormat decoder) are also available directly.
Jetstream v1 (legacy)
byte[]? zstdDictionary = null;
if (zstdDictionaryPath != null)
{
zstdDictionary = File.ReadAllBytes(zstdDictionaryPath);
Console.WriteLine($"Loaded zstd dictionary from {zstdDictionaryPath} ({zstdDictionary.Length} bytes)");
}
else if (compress)
{
Console.WriteLine("Warning: --compress specified without --zstd-dictionary. Binary frames will fail to decompress.");
}
using var client = new JetstreamClient(new Uri(endpoint), zstdDictionary);
var options = new JetstreamSubscribeOptions
{
Cursor = cursor,
WantedCollections = collections.Count > 0 ? collections : null,
WantedDids = dids.Count > 0 ? dids : null,
Compress = compress,
};
try
{
await foreach (var evt in client.SubscribeAsync(options, cts.Token))
{
switch (evt.Kind)
{
// ... switch on events...
}
}
}
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 is compatible. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
| .NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
| .NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
| MonoAndroid | monoandroid was computed. |
| MonoMac | monomac was computed. |
| MonoTouch | monotouch was computed. |
| Tizen | tizen40 was computed. tizen60 was computed. |
| Xamarin.iOS | xamarinios was computed. |
| Xamarin.Mac | xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 2.0
- CarpaNet (>= 1.0.3)
- Microsoft.Extensions.Logging.Abstractions (>= 10.0.5)
- System.Formats.Cbor (>= 10.0.5)
- System.Text.Json (>= 10.0.5)
- ZstdSharp.Port (>= 0.8.7)
-
net10.0
- CarpaNet (>= 1.0.3)
- Microsoft.Extensions.Logging.Abstractions (>= 10.0.5)
- System.Formats.Cbor (>= 10.0.5)
- ZstdSharp.Port (>= 0.8.7)
-
net8.0
- CarpaNet (>= 1.0.3)
- Microsoft.Extensions.Logging.Abstractions (>= 10.0.5)
- System.Formats.Cbor (>= 10.0.5)
- System.Text.Json (>= 10.0.5)
- ZstdSharp.Port (>= 0.8.7)
-
net9.0
- CarpaNet (>= 1.0.3)
- Microsoft.Extensions.Logging.Abstractions (>= 10.0.5)
- System.Formats.Cbor (>= 10.0.5)
- System.Text.Json (>= 10.0.5)
- ZstdSharp.Port (>= 0.8.7)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.1.0-alpha.5 | 73 | 5/21/2026 |
| 1.1.0-alpha.4 | 92 | 4/13/2026 |
| 1.1.0-alpha.3 | 84 | 4/13/2026 |
| 1.1.0-alpha.2 | 79 | 4/13/2026 |
| 1.1.0-alpha.1 | 34 | 8/21/2026 |
| 1.0.3 | 35 | 8/21/2026 |
| 1.0.2 | 394 | 5/21/2026 |
| 1.0.1 | 122 | 3/30/2026 |
| 0.1.0-alpha.76 | 83 | 3/30/2026 |
| 0.1.0-alpha.71 | 78 | 3/24/2026 |
| 0.1.0-alpha.68 | 84 | 3/15/2026 |
| 0.1.0-alpha.58 | 75 | 3/8/2026 |
| 0.1.0-alpha.54 | 76 | 2/18/2026 |
| 0.1.0-alpha.52 | 75 | 2/18/2026 |
| 0.1.0-alpha.50 | 83 | 2/18/2026 |
| 0.1.0-alpha.47 | 82 | 2/17/2026 |
| 0.1.0-alpha.38 | 83 | 2/16/2026 |
| 0.1.0-alpha.37 | 83 | 2/16/2026 |
| 0.1.0-alpha.35 | 80 | 2/16/2026 |
| 0.1.0-alpha.34 | 77 | 2/15/2026 |