Skip to content

Global Concepts

joshpinto6 edited this page Jun 8, 2025 · 10 revisions

Warning

This page is still incomplete and considered a stub.

This page is dedicated to documenting the various concepts which are used by Regreso. All concepts are stored in Postgres.

Entities

User

A user is managed using Lucia Auth principles and is stored in the Postgres regreso_user table. Additionally, users have mandatory properties such as username, display_name, avatar_url (in (UploadThing), and bio. The following authentication properties are optional unless specified otherwise.

  • id: User ID (sequential integer, user_id in foreign keys)
  • email: Email (required)
  • email_verified: Email verification status (required)
  • github_id: GitHub OAuth ID
  • google_id: Google OAuth ID
  • recovery_code: Recovery Code (required)
  • table regreso_totp_credential: TOTP Credential
  • table regreso_passkey_credential Passkey Credential
  • table regreso_security_key_credential: Security key Credential

Session

Password Reset Session

Destination

Destinations must have one of the following types: note, location or file (coming soon). Destinations may have names and bodies (both optional), can be associated with lists, tags, and workspaces, and have auto-generated created_at and updated_at timestamps. At the moment, destinations must be associated with a user, but planned collaboration features may involve this changing.

Note

Destinations are also called "pins" in many Regreso URLs, due to its simplicity/shortness. Additionally, many variables/iterators use the abbreviation "dest".

List (Map)

Destinations can be added to lists using the destination_list association table. Lists have auto-generated created_at and updated_at timestamps and may be associated with a user, workspace, and tags. The following are properties of lists:

  • id: An integer list ID generated sequentially (list_id in foreign keys)
  • name: Name of the list
  • description: A description of the list
  • emoji: An emoji to represent the list

Note

Lists are thematically called "maps" everywhere in the Regreso frontend/URLs. Additionally, many variables/iterators use the abbreviation "lst".

Workspace (Trunk)

Important

Workspaces are implemented in the Postgres database, but not yet through the frontend or tRPC router. Follow the progress in #111.

Workspaces may be associated with a user and have the following properties:

  • id: An integer primary key generated sequentially (workspace_id in foreign keys)
  • name: Name of the list
  • description: A description of the list
  • emoji: An emoji to represent the list

Note

Workspaces are thematically called "trunks" everywhere in Regreso's frontend but "boxes" in URLs. Additionally, many variables/iterators use the abbreviation "wkspc".

Tag

Lists and destinations can be associated with tags through the destination_tag and list_tag tables respectively. Tags must be associated with a user and are unique on shortcut and name.

Note

Lists' tags are applied to their destinations when searching. Tags can also be searched for themselves or applied via their shortcut or name.

Tags have the following properties which are optional unless specified otherwise:

  • id: An integer primary key generated sequentially (tag_id in foreign keys)
  • name: Name of the tag (required)
  • shortcut: A shortened tag name which can be used to find/apply it

Note

Many variables/iterators use the abbreviation "tg" for tags.

Feed (Destination)

Important

Destination feeds are implemented in the Postgres database, but not yet through the frontend or tRPC router. Follow the progress in #224.

States

Archival (Burial)

And subsequently, excavation (unarchival)

Deletion (Burning, Destruction)

Permanently deleted

The App Structure pages and Global Concepts are great places to learn more about regreso!

Clone this wiki locally