There can be more than Notion and Miro. AFFiNE(pronounced [ə‘fain]) is a next-gen knowledge base that brings planning, sorting and creating all together. Privacy first, open-source, customizable and ready to use. https://affine.pro
  • TypeScript 82.2%
  • Rust 10.8%
  • Swift 4.7%
  • Kotlin 1.1%
  • JavaScript 0.4%
  • Other 0.6%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
DarkSky 8bbbfcf078
fix(native): recover refresh attempts after response loss (#15792)
fix #15654
fix #15551



#### PR Dependency Tree


* **PR #15792** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

<!-- coderabbit-ai-generated:v1 -->

## Summary by CodeRabbit

* **New Features**
* Session refreshes can now recover from interrupted requests using the
same refresh attempt, including after an app restart.
* **Bug Fixes**
* Retrying a successful refresh no longer unnecessarily rotates tokens
or invalidates the session. Invalid or mismatched retries continue to be
rejected, while expired credentials are handled without revoking an
otherwise valid session.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-11-04 22:32:21 +08:00
.cargo feat(server): migrate copilot to native (#14620) 2026-03-11 13:55:35 +08:00
.codesandbox refactor!: remove next.js (#3267) 2023-07-18 16:53:10 +00:00
.devcontainer feat(server): improve indexer perf (#15512) 2026-08-23 17:54:49 +08:00
.docker feat(server): improve config loading (#15649) 2026-09-30 00:39:36 +08:00
.github fix(client): add aarch64 linux release (#15752) 2026-10-27 15:52:32 +08:00
.husky chore: upgrade husky to latest (#5719) 2024-01-26 06:37:39 +00:00
.render feat: add Render Blueprint for one-click self-host (#15478) 2026-08-14 16:14:50 +08:00
.vscode chore: migrate oxlint & oxfmt (#15464) 2026-08-10 23:51:28 +08:00
.yarn feat: bump deps (#15698) 2026-10-10 23:28:25 +08:00
blocksuite fix(editor): preserve canvas input ownership in table selection (#15791) 2026-11-04 22:18:36 +08:00
docs feat(core): adapt new lifecycle (#15575) 2026-09-09 23:00:06 +08:00
packages fix(native): recover refresh attempts after response loss (#15792) 2026-11-04 22:32:21 +08:00
scripts chore: improve ci (#15743) 2026-10-26 16:49:45 +08:00
tests fix(editor): prevent code menu switches from toggling twice (#15782) 2026-11-02 21:43:59 +08:00
tools chore: improve ci (#15743) 2026-10-26 16:49:45 +08:00
.dockerignore chore: cleanup images (#14380) 2026-02-06 19:49:02 +08:00
.editorconfig feat(native): sync yocto codes (#14243) 2026-01-11 06:08:33 +08:00
.gitattributes
.gitignore chore: migrate oxlint & oxfmt (#15464) 2026-08-10 23:51:28 +08:00
.npmrc
.nvmrc chore: bump deps (#15729) 2026-10-22 16:38:31 +08:00
.oxfmtrc.json chore: migrate oxlint & oxfmt (#15464) 2026-08-10 23:51:28 +08:00
.oxlintrc.json chore: migrate oxlint & oxfmt (#15464) 2026-08-10 23:51:28 +08:00
.prettierignore chore: migrate oxlint & oxfmt (#15464) 2026-08-10 23:51:28 +08:00
.taplo.toml feat(server): improve config loading (#15649) 2026-09-30 00:39:36 +08:00
.yarnrc.yml chore: bump typescript 7 (#15465) 2026-08-11 03:09:54 +08:00
Cargo.lock fix(native): recover refresh attempts after response loss (#15792) 2026-11-04 22:32:21 +08:00
Cargo.toml feat(server): handle m4a slice (#15703) 2026-10-11 20:27:08 +08:00
CHANGELOG.md
codecov.yml
deny.toml feat(editor): migrate typst mermaid to native (#14499) 2026-03-20 04:04:40 +08:00
LICENSE docs: update docs 2025-12-29 19:08:49 +08:00
LICENSE-MIT docs: update licenses (#4180) 2023-09-15 07:50:00 +00:00
nyc.config.js chore: migrate oxlint & oxfmt (#15464) 2026-08-10 23:51:28 +08:00
package.json chore: bump up happy-dom version to v21 [SECURITY] (#15739) 2026-10-25 13:21:34 +08:00
README.md docs: refresh contributing & building guides, surface CLA signing flow (#15503) 2026-08-21 08:15:26 +08:00
render.yaml feat: add Render Blueprint for one-click self-host (#15478) 2026-08-14 16:14:50 +08:00
rust-toolchain.toml chore: bump up Rust to v1.97.1 (#15389) 2026-07-31 17:08:23 +08:00
rustfmt.toml feat(native): sync yocto codes (#14243) 2026-01-11 06:08:33 +08:00
SECURITY.md chore: update docs 2026-07-15 13:25:57 +08:00
tsconfig.eslint.json feat(docs): migrate bs docs 2026-04-29 17:23:23 +08:00
tsconfig.json feat(server): support refresh token (#15218) 2026-07-12 02:39:42 +08:00
tsconfig.node.json chore: standardize tsconfig (#9568) 2025-01-08 04:07:56 +00:00
tsconfig.web.json chore: bump typescript 7 (#15465) 2026-08-11 03:09:54 +08:00
typedoc.base.json docs: initial api reference docs (#5352) 2024-01-02 12:46:27 +00:00
typedoc.json refactor(infra): migrate to new infra (#5565) 2024-01-30 07:16:39 +00:00
vitest.config.ts test: migrate test & utils (#14569) 2026-03-07 04:12:27 +08:00
yarn.lock chore: improve ci (#15743) 2026-10-26 16:49:45 +08:00

AFFiNE.Pro
Write, Draw and Plan All at Once

affine logo

A privacy-focused, local-first, open-source, and ready-to-use alternative for Notion & Miro.
One hyper-fused platform for wildly creative minds.



AFFiNE - One app for all - Where Notion meets Miro | Product Hunt


Releases All Contributors TypeScript-version-icon


Docs, canvas and tables are hyper-merged with AFFiNE - just like the word affine (əˈfʌɪn | a-fine).

Getting started & staying tuned with us.

Star us, and you will receive all release notifications from GitHub without any delay!

What is AFFiNE

AFFiNE is an open-source, all-in-one workspace and an operating system for all the building blocks that assemble your knowledge base and much more -- wiki, knowledge management, presentation and digital assets. It's a better alternative to Notion and Miro.

Features

A true canvas for blocks in any form. Docs and whiteboard are now fully merged.

  • Many editor apps claim to be a canvas for productivity, but AFFiNE is one of the very few which allows you to put any building block on an edgeless canvas -- rich text, sticky notes, any embedded web pages, multi-view databases, linked pages, shapes and even slides. We have it all.

Multimodal AI partner ready to kick in any work

  • Write up professional work report? Turn an outline into expressive and presentable slides? Summary an article into a well-structured mindmap? Sorting your job plan and backlog for tasks? Or... draw and code prototype apps and web pages directly all with one prompt? With you, AFFiNE AI pushes your creativity to the edge of your imagination, just like Canvas AI to generate mind map for brainstorming.

Local-first & Real-time collaborative

  • We love the idea of local-first that you always own your data on your disk, in spite of the cloud. Furthermore, AFFiNE supports real-time sync and collaborations on web and cross-platform clients.

Self-host & Shape your own AFFiNE

  • You have the freedom to manage, self-host, fork and build your own AFFiNE. Plugin community and third-party blocks are coming soon. More tractions on Blocksuite. Check there to learn how to self-host AFFiNE.

Acknowledgement

“We shape our tools and thereafter our tools shape us”. A lot of pioneers have inspired us along the way, e.g.:

  • Quip & Notion with their great concept of “everything is a block”
  • Trello with their Kanban
  • Airtable & Miro with their no-code programmable datasheets
  • Miro & Whimiscal with their edgeless visual whiteboard
  • Remote & Capacities with their object-based tag system

There is a large overlap of their atomic “building blocks” between these apps. They are not open source, nor do they have a plugin system like Vscode for contributors to customize. We want to have something that contains all the features we love and also goes one step even further.

Thanks for checking us out, we appreciate your interest and sincerely hope that AFFiNE resonates with you! 🎵 Checking https://affine.pro/ for more details ions.

Contributing

Bug Reports Feature Requests Questions/Discussions AFFiNE Community
Create a bug report Submit a feature request Check GitHub Discussion Visit the AFFiNE's Discord
Something isn't working as expected An idea for a new feature, or improvements Discuss and ask questions A place to ask, learn and engage with others

Calling all developers, testers, tech writers and more! Contributions of all types are more than welcome, you can read more in docs/types-of-contributions.md. If you are interested in contributing code, read our docs/CONTRIBUTING.md and feel free to check out our GitHub issues to get stuck in to show us what you’re made of.

Before you start contributing, please sign our Contributor License Agreement — it takes less than a minute with your GitHub account. Pull requests cannot be merged until every committer has signed (the license/cla check on your PR). Full text: CLA.md.

For bug reports, feature requests and other suggestions you can also create a new issue and choose the most appropriate template for your feedback.

For translation and language support you can visit our Discord.

If you have questions, you are welcome to contact us. One of the best places to get more info and learn more is in the Discord where you can engage with other like-minded individuals.

Templates

AFFiNE now provides pre-built templates from our team. Following are the Top 10 most popular templates among AFFiNE users,if you want to contribute, you can contribute your own template so other people can use it too.

Blog

Welcome to the AFFiNE blog section! Here, you’ll find the latest insights, tips, and guides on how to maximize your experience with AFFiNE and AFFiNE AI, the leading Canvas AI tool for flexible note-taking and creative organization.

Ecosystem

Name
@affine/component AFFiNE Component Resources
@toeverything/theme AFFiNE theme

Upstreams

We would also like to give thanks to open-source projects that make AFFiNE possible:

  • Blocksuite - 💠 BlockSuite is the open-source collaborative editor project behind AFFiNE.

  • y-octo - 🐙 y-octo is a native, high-performance, thread-safe YJS CRDT implementation, serving as the core engine enabling the AFFiNE Client/Server to achieve "local-first" functionality.

  • OctoBase - 🐙 OctoBase is the open-source database behind AFFiNE, local-first, yet collaborative. A light-weight, scalable, data engine written in Rust.

  • yjs - Fundamental support of CRDTs for our implementation on state management and data sync on web.

  • electron - Build cross-platform desktop apps with JavaScript, HTML, and CSS.

  • React - The library for web and native user interfaces.

  • napi-rs - A framework for building compiled Node.js add-ons in Rust via Node-API.

  • Jotai - Primitive and flexible state management for React.

  • async-call-rpc - A lightweight JSON RPC client & server.

  • Vite - Next generation frontend tooling.

  • Other upstream dependencies.

Thanks a lot to the community for providing such powerful and simple libraries, so that we can focus more on the implementation of the product logic, and we hope that in the future our projects will also provide a more easy-to-use knowledge base for everyone.

Contributors

We would like to express our gratitude to all the individuals who have already contributed to AFFiNE! If you have any AFFiNE-related project, documentation, tool or template, please feel free to contribute it by submitting a pull request to our curated list on GitHub: awesome-affine.

contributors

Self-Host

Begin with Docker to deploy your own feature-rich, unrestricted version of AFFiNE. Our team is diligently updating to the latest version. For more information on how to self-host AFFiNE, please refer to our documentation.

Deploy to Render

Run on Sealos

Feature Request

For feature requests, please see discussions.

Building

Codespaces

From the GitHub repo main page, click the green "Code" button and select "Create codespace on master". This will open a new Codespace with the (supposedly auto-forked AFFiNE repo cloned, built, and ready to go).

Local

See BUILDING.md for instructions on how to build AFFiNE from source code.

Contributing

We welcome contributions from everyone. See docs/contributing/tutorial.md for details.

License

Editions

  • AFFiNE Community Edition (CE) is the current available version, it's free for self-host under the MIT license.

  • AFFiNE Enterprise Edition (EE) is yet to be published, it will have more advanced features and enterprise-oriented offerings, including but not exclusive to rebranding and SSO, advanced admin and audit, etc., you may refer to https://affine.pro/pricing for more information

See LICENSE for details.