Public
Demo: org-scoped content portal with Val Town OAuth
Val Town is a collaborative website to build and scale JavaScript apps.
Deploy APIs, crons, & store data – all from the browser, and deployed in milliseconds.

πŸŽ‰ Org Portal Demo

A demo of org-scoped content on Val Town β€” like Google Docs sharing but for entire apps.

The Flow

Rendering mermaid diagram...

Three States

  1. Not logged in β†’ Beautiful landing page explaining what this is, with a "Log in with Val Town" button
  2. Logged in, NOT an org member β†’ Friendly "request access" screen (like clicking a Google Doc you don't have access to)
  3. Logged in, IS an org member β†’ The actual app content

How It Works

  • Uses std/oauth for zero-config Val Town login
  • session.isOrgMember automatically checks if the user belongs to this val's org
  • No API keys, no database, no env vars needed (besides optional encryption key for perf)
  • Sessions stored in encrypted cookies β€” fully stateless

The Vision

This could be a new paradigm for Val Town org adoption:

  • Internal tools that only your team can access
  • Shared dashboards scoped to your org
  • Request access flow so outsiders can ask to join
  • Shareable URLs β€” send the link to anyone, they'll see the right thing