Advanced
The two escape hatches — replacing the built-in REST surface with your own controllers, and binding a rich-text editor directly to the shared document.
The defaults cover the common path: the provider mounts ten routes, the hooks consume them, and you
write authorize. Two situations reach past that.
You need the HTTP surface to be yours — a versioned API, response shapes a frontend already depends on, guards that differ per route, or a rule of your own layered on top of the library's. The library keeps owning the hard parts (sync, storage, versions, comments) and hands you the controllers — and, with them, the permission checks it was making for you.
You are binding an editor with its own CRDT integration — Tiptap, ProseMirror, CodeMirror. Those do not go through an adapter; they bind to the shared document directly, and the wiring has a few details worth getting right the first time.
Editors
useCollabEditor and the adapter seam — how a scene maps into a document key, the three built-in adapters, writing your own, and when to drop down to the raw Y.Doc instead.
Custom controllers
Take over the HTTP surface without losing the library's token semantics — the three levels of control, a complete working controller, and the authorization you take over along with it.