mcndt / noteshare.space

A service for sharing encrypted Markdown notes from Obsidian. Notes are end-to-end-encrypted and are only stored temporarily.
https://noteshare.space
MIT License
202 stars 19 forks source link

[Feature request] Updating published notes #30

Closed Ellpeck closed 1 year ago

Ellpeck commented 2 years ago

Is your feature request related to a problem? Please describe. Currently, when editing a note that you previously published (for example, when you shared a budget breakdown with a friend and they noticed an issue), you have to re-share the note, which also involves sending a new link to the share partner.

Describe the solution you'd like A command named something like Updated shared note would be nice that, when invoked, updates the note at the location that the previous link was already pointing to.

It would be extra useful to have a feature that causes selected notes to be updated automatically whenever they change (or whenever they're saved to disk by Obsidian).

Thanks!

mcndt commented 2 years ago

Thanks for the request!

I think editing published notes is a good idea, both from a UX perspective as well as cost-saving on hosting (less duplicate content that isn't being read).

I think an Obsidian-idiomatic solution would be to put the Noteshare URL in a note's frontmatter:

---
quickshare_url: https://noteshare.space/note/{id}#{key}
---

The plugin can then use this resource for updating (or deleting) the note. This also works nicely with self-hosted instances as the plugin can tell which host to use from that URL.

(Note for my future self:) I'm still working out the best way to proof to the server that you are the same user client who posted the original note. The most obvious solution I could come up with is that the server generates an "ownership token" when posting a note, that serves as a authentication token for PUT/DELETE methods. That token will have to be stored in e.g. the data.json file. Another solution could be some kind of zero-knowledge proof scheme, but since pretty much everything about a note is mutable, it's pretty hard to come up with anything concrete.

mcndt commented 1 year ago

closing this issue because it is encompassed by https://github.com/mcndt/obsidian-quickshare/issues/25