Skip to content

Technical Specification

Gail Terman edited this page Jul 10, 2022 · 4 revisions

Tech Stack Options

Database

  • rethink db
  • mongo
  • mysql

Backends

  • can we just use the db as the backend? probably
  • express
  • flask

Frontends

Web

  • angular
  • svelte
  • react-native-web

Phone App

  • nativescript
    • angular
    • svelte
  • react-native
  • flutter

Database Design

Play

  • id: string
  • deviceId: string
  • title: string
  • currPlayers: number
  • maxPlayers: number
  • startTime: ISO-8601
  • endTime: ISO-8601
  • location: string
  • bggId: string - for v2
  • status: "waiting" | "started" | "cancelled"
  • eventId: string
  • featured: boolean - for v2

Event - maybe v2?

  • id: string
  • name: string
  • startDate: ISO-8601
  • endDate: ISO-8601
  • eventPassword: (hashed) string
  • adminPassword: (hashed) string

Actions (for flux/redux/etc)

Play

  • SavePlay(play: Play)
    • SetLocation(location: string, id?: string)
    • AddPlayer(id?: string)
    • DropPlayer(id?: string)
    • StartPlay(id?: string)
    • CancelPlay(id?: string)
  • DeletePlay(id: string)
  • SelectPlay(id: string)
  • UnselectPlay
  • GetPlays
  • GetPlay(id?: string)

Event

  • GetEvents
  • GetEvent(id?: string)
  • SelectEvent(id: string)
  • UnselectEvent
  • SaveEvent(event: Event)
  • ValidateEventAccess(password: string)
  • ValidateAdminAccess(password: string)

Security & Authorization

User

  • uses deviceId as unique identifier in the system
  • no password or anything
  • to see event info, must have jwt saying they have event access?

Admin

  • has additional access privs on their event jwt (?)

Server

  • only releases information if you have the right auth in your jwt

If the id is not specified, it will use the current selected play if there is one, or throw an error

Clone this wiki locally