• Blog
  • Docs
  • Pricing
  • We’re hiring!
Log inSign up
mgm

mgm

santa

Basic Secret Santa site, revealing gift-giving partners
Public
Like
santa
Home
Code
4
README.md
favicon.svg
H
main.ts
utils.ts
Branches
1
Pull requests
Remixes
History
Environment variables
1
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.
Sign up now
Code
/
README.md
Code
/
README.md
Search
11/27/2025
Viewing readonly version of main branch: v43
View latest version
README.md

πŸŽ… Secret Santa Web Application

A festive web application for Secret Santa gift exchanges with encrypted assignment links.

Features

  • πŸŽ„ Splashy Christmas-themed UI with falling snowflakes and festive animations
  • πŸ” Encrypted assignment links for secure Secret Santa assignments
  • 🎁 Interactive gift reveal - click the gift box to discover your assignment
  • πŸ“± Responsive design that works on all devices
  • ✨ Celebration effects when the assignment is revealed

How It Works

  1. Welcome Page (/) - Shows a festive landing page for users without a valid token
  2. Assignment Page (/{encrypted-token}) - Decrypts the token and shows:
    • A personalized greeting to the giver
    • An interactive gift box that reveals the receiver when clicked
    • Festive animations and celebration effects

Technical Details

Encryption

  • Uses AES-GCM encryption to secure assignment data
  • Tokens are URL-safe Base64 encoded
  • Requires ENCRYPTION_KEY environment variable (hex format)

Expected Token Data Structure

The decrypted token should contain:

{ "giver": "John Doe", "receiver": "Jane Smith" }

Alternative field names are supported:

  • from instead of giver
  • to instead of receiver

Files

  • main.ts - Main HTTP handler with HTML page generation
  • utils.ts - Encryption/decryption utilities
  • favicon.svg - Gift box favicon for the site
  • README.md - This documentation

Environment Variables

  • ENCRYPTION_KEY - Hex-encoded encryption key for AES-GCM decryption

Usage

  1. Generate encrypted tokens containing giver/receiver pairs
  2. Share links in format: https://your-domain.com/{encrypted-token}
  3. Recipients click the gift box to reveal their Secret Santa assignment

Styling

  • Uses TailwindCSS for responsive styling
  • Custom Christmas fonts (Mountains of Christmas)
  • Animated snowflakes and celebration effects
  • Festive color scheme with gradients and glowing effects
FeaturesVersion controlCode intelligenceCLIMCP
Use cases
TeamsAI agentsSlackGTM
DocsShowcaseTemplatesNewestTrendingAPI examplesNPM packages
PricingNewsletterBlogAboutCareers
We’re hiring!
Brandhi@val.townStatus
X (Twitter)
Discord community
GitHub discussions
YouTube channel
Bluesky
Open Source Pledge
Terms of usePrivacy policyAbuse contact
Β© 2026 Val Town, Inc.