DEV Community

Cover image for Zero to SaaS - Bookmarksy.io Initial Data Model approach
Brandon
Brandon

Posted on

Zero to SaaS - Bookmarksy.io Initial Data Model approach

I haven't talked about the data model for bookmarksy.io yet but I spent yesterday evening building out the core data model for bookmarks/categories.

Here's the approach.

First, the definitions:

  • Bookmark - a twitter bookmark.
  • Category - a group of bookmarks that share a domain.

The flow:

  1. User registers
  2. Categories service seeds their account with a default category "Uncategorized" (all bookmarks will initially exist as part of this category)
  3. Then, when a user reads their dashboard (these things happen asynchronously):
    • categories are loaded
    • bookmarks are loaded
    • bookmarks are hydrated (reach out to twitter to capture any new bookmarks)
    • hydrated bookmarks are loaded into "uncategorized"

So far, this flow exists and is stable, with the exception of bookmark hydration. I have yet to come up with a non blocking, performant solution but am working on it!

I think, given the potential variety of categories, having them account scoped makes the most sense. This will likely lead to some de-normalization but it's an acceptable trade off

If you're like me and have a tonne of bookmarks you never read, check
https://bookmarksy.io
out and join the waitlist!

Top comments (0)