Examples
Every example on these pages is a real file in the examples/ directory of the repository, included here verbatim. Clone the repo and run any of them directly.
They are licensed under CC0 and so are fully dedicated to the public domain, so use them as the base for your own bots without worrying about copyright.
Tip
Replace 'my-handle' and 'my-password' before running anything. Use an app password, not your account password. See Authentication.
Post, reply, embed images and video, read a timeline, like, repost, and follow.
Sessions, pagination, rich text, link cards, direct messages, proxies, and error handling.
Subscribe to the whole networkβs repository and label events, and decode the commits.
The same stream as plain JSON, filtered server-side, plus archive backfill.
Two more live elsewhere because they need their surrounding prose:
Custom lexicons: generating and using a package from your own lexicon files.
Building a feed generator: a complete service, walked through end to end.