feed_generator

A Bluesky custom feed generator template

A template for a Bluesky custom feed generator in Dart: a firehose indexer, a swappable ranking algorithm and store, and the three endpoints AppView calls, served over shelf.

ActivePersonalOpen source

Record

Kind
Tool
Role
Author
Started
July 2026
Updated
August 2026
Licence
BSD-3-Clause

Technology5

Evidence12 sources

The pubspec sets `publish_to: none` and describes the directory as a clone-and-edit template for building a Bluesky custom feed generator with atproto.dart, on Dart SDK `>=3.8.0 <4.0.0`sourcegithub.com The README describes a feed generator as an HTTP service Bluesky's AppView calls for an ordered list of post URIs, and documents the three endpoints this one serves — /.well-known/did.json, app.bsky.feed.describeFeedGenerator and app.bsky.feed.getFeedSkeletondocsgithub.com The README configures the service from FEEDGEN_* environment variables, and states that only bin/publish_feed.dart reads FEEDGEN_PUBLISHER_PASSWORD, so the internet-facing server never holds the write-capable credentialdocsgithub.com bin/server.dart starts the firehose indexer, verifies the AppView's inbound service-auth JWT through atproto_identity, and serves the handler behind a shelf Pipeline carrying an error backstop, a 15-second request timeout and a per-IP rate limitsourcegithub.com The FeedAlgorithm interface declares one method, getFeedSkeleton, described in the source as the one method a feed developer implementssourcegithub.com The shipped WhatsHotAlgorithm is the implementation meant to be replaced: its own doc comment calls it a minimal reverse-chronological sample feed and says to replace the body of getFeedSkeleton with your own rankingsourcegithub.com bin/publish_feed.dart registers the feed on the network by writing an app.bsky.feed.generator record, and is idempotent so it can be re-run after a changesourcegithub.com The firehose indexer subscribes to the public relay and takes a pluggable cursor store; its own doc comment says reconnection, backoff and cursor persistence live in the Firehose class, and that the default store keeps the cursor in memory — enough to survive a relay hiccup, not a restartsourcegithub.com bin/server.dart is what makes the indexer's cursor durable, constructing it with FileCursorStore.at(config.cursorPath) so a restart resumes where the process stopped rather than skipping to the live edgesourcegithub.com The first commit adding templates/feed_generator is "feat(feed_generator): scaffold template project and config", dated 2026-07-16repogithub.com The root pubspec.yaml lists templates/feed_generator as a member of the Dart pub workspace, alongside the fourteen packages and scriptssourcegithub.com The template ships its own BSD-3-Clause LICENSE file, copyright 2023-2026 Shinya Katolicencegithub.com

Links1

Relations4 edges

atproto.dartPart ofDart SDK monorepo for AT Protocol and Bluesky blueskyDepends onA Dart/Flutter SDK for Bluesky Social atproto_coreDepends onShared core layer for the atproto.dart SDK atproto_identityDepends onAT Protocol identity resolution for Dart