University of Peradeniya crestSCS Documentation
University of Peradeniya crestSCS Documentation
Department website

Start here

Repository handbookRepository overviewDevelopment

System design

ArchitectureAuthentication and authorizationPublic dataAPI contractsSchemas
UI system

Applications

Department Web applicationPeople applicationProjects applicationPortal application
Application internals
Portal internalsPortal routing and accessPortal editor state and mutationsPortal data loading and failures

Services

API serviceGitHub App serviceMailer service

Shared packages

Schemas packageUI packageTypeScript configuration packageESLint configuration package

Development workflow

Testing and verificationDependency managementDocumentation authoringUI quality assurance

Operations

Continuous integrationEnvironment variablesOperationsSecurityTroubleshooting

Reference

Route referenceGlossary
Application internalsPortal internals

Runtime map of Portal routes, trust boundaries, editor workflows, data loading, and failure handling.

Portal internals

apps/portal is the authenticated management application. It presents human-friendly workflows for account settings, public profiles, projects, courses, proxy relationships, and administration. It does not own identity, permissions, or published records: those decisions belong to services/api and its downstream services.

Ownership boundaries

ConcernPortal responsibilityAuthoritative owner
session-aware navigationshow the appropriate entry or account actionsAPI and Better Auth
route prefilteringavoid obviously invalid navigationPortal proxy
authorizationrender only after API-backed permission checksAPI
working editsmaintain and validate a local draftPortal editor
published recorddisplay separately from the draftpublic data repository
mutation progresspoll and explain accepted asynchronous operationsGitHub App operation state

Read Routing and access before changing protected routes, Editor state and mutations before changing an editor, and Data loading and failures before changing server fetches, redirects, or error behavior.

Shared transport and domain types must be imported directly from @scs/schemas. Portal-specific composed components remain in apps/portal; only reusable shadcn primitives belong in @scs/ui.

Application internals

Code-derived guides to the repository's interactive applications and their runtime boundaries.

Portal routing and access

How Portal routes, session hints, server authorization, and navigation divide responsibility.

On this page

Portal internalsOwnership boundaries