FeaturesTemplatesShowcaseTownie
AI
BlogDocsPricing
Log inSign up
lightweight
lightweightglimpse2-runbook-view-glimpse-save-login-react
Remix of lightweight/glimpse2-runbook-view-glimpse-save-login
Public
Like
glimpse2-runbook-view-glimpse-save-login-react
Home
Code
8
_townie
13
backend
7
frontend
4
shared
3
.vtignore
README.md
deno.json
H
main.tsx
Branches
2
Pull requests
Remixes
History
Environment variables
6
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
/
backend
/
README.md
Code
/
backend
/
README.md
Search
9/5/2025
Viewing readonly version of main branch: v2
View latest version
README.md

Backend

This directory contains all server-side code organized by functionality.

Architecture

  • routes/ - HTTP route handlers organized by functionality
  • api/ - JSON API endpoints for frontend/backend communication
  • tasks/ - Webhook handlers for Notion integrations
  • views/ - Server-side rendered views for frontend
  • services/ - External API integrations (pure API calls only)
  • controllers/ - Business logic coordination between routes and services
  • crons/ - Scheduled task handlers
  • types/ - Shared TypeScript type definitions
  • utils/ - Common utility functions

Layer Responsibilities

Services: Single-purpose functions that make direct API calls to external systems. Pure functions that handle HTTP transport layer.

Controllers: Business logic and orchestration between services. Handle environment variables and configuration.

Routes: HTTP request/response handling only. Call controllers, never services directly.

Go to top
X (Twitter)
Discord community
GitHub discussions
YouTube channel
Bluesky
Product
FeaturesPricing
Developers
DocsStatusAPI ExamplesNPM Package Examples
Explore
ShowcaseTemplatesNewest ValsTrending ValsNewsletter
Company
AboutBlogCareersBrandhi@val.town
Terms of usePrivacy policyAbuse contact
© 2025 Val Town, Inc.