Function index

Reference

Function index

Every named function or module in this atlas, where it runs, and the page that explains it. Names match the code layout in the repository.

NameLayerPurposePage
verifyJWTAPI middlewareValidate token, set req.userSecurity
attachRoleAPI middlewareLoad roles, require approved, set req.roleSecurity
authorizeRouteAPI middlewareRoute vs nav_item_rolesSecurity
injectRLSContextAPI middlewareBEGIN, set_config identity, expose req.dbSecurity
protectAPI middlewareThe four stages in orderSecurity
keyByUserOrIpAPI limitsRate-limit keySecurity
generalApiLimiter, aiGenerationLimiter, certificateIssueLimiterAPI limitsPer-user rate limitsSecurity
saveUploadAPI filesValidate and write an uploadIngestion and embeddings
createResource, enqueueEmbedJobAPI resourcesInsert row and queue jobIngestion and embeddings
claim_jobai-serviceTake one queued job atomicallyIngestion and embeddings
extract_text, chunk_textai-serviceText extraction and chunkingIngestion and embeddings
embedai-serviceOllama embedding call, 768 dimsIngestion and embeddings
store_chunks, mark_done, mark_failedai-servicePersist and finish a jobIngestion and embeddings
generateQuestionnaireAPI assessmentsDraft route handlerAssessments
selectChunks, buildPromptAPI assessmentsContext and prompt for the providerAssessments
getProvider, provider.generateAPI aiVertex or Ollama behind AI_PROVIDERAssessments
parseAndValidateAPI aiCheck the model replyAssessments
saveDraft, publishQuestionnaireAPI assessmentsPersist and publishAssessments
submitAttempt, scoreAttemptAPI assessmentsServer-side scoring, one attemptAssessments
embedTrainerProfile, embedCourseai-serviceRefresh competency embeddingsCompetency matching
suggestTrainers, matcherPoolAPI competencyTop-5 ranking under BYPASSRLSCompetency matching
streamResourceAPI filesAuthenticated downloadFiles and certificates
issueCertificate, issueCohortCertificatesAPI certificatesRender, store, recordFiles and certificates
renderCertificateHtml, escapeHtml, renderPdfAPI certificatesTemplate and Gotenberg callFiles and certificates
fetchNav, NavRenderer, CoursesAppportalSidebar and section routerWeb and mobile
appRedirect, AuthRepository.refreshmobilego_router guard and token refreshWeb and mobile
Capacity Connect · Team Syntax Squad · SIH 2026 · PS 26075Code samples are implementation sketches.