Public
Like
glimpse2-runbook-view-glimpse-save-login
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.
Viewing readonly version of main branch: v1View latest version
Business logic coordination between routes and services.
Controllers should:
- Handle business logic and orchestration between services
- Handle environment variables and configuration
- Coordinate multiple service calls
- Implement business rules and validation
- Handle service business logic layer (result.success)
The handleUrlWebhook
function follows the webhook handler pattern:
- Takes Hono Context as parameter
- Returns HTTP responses directly
- Handles webhook payload parsing and validation
- Implements business logic for URL updates
- Provides comprehensive logging and error handling
The glimpseHandler
function follows the data API pattern:
- Takes Hono Context as parameter
- Returns JSON data responses
- Filters and transforms service data
- Handles error responses with appropriate status codes