Utils

Common utility functions.

Available Utils

  • email.utils.ts - Email processing utilities (filename parsing, interviewee name extraction)
  • pdfExtractor.ts - PDF text extraction utilities
  • process-timing.utils.ts - Process timing calculations and formatting utilities
  • notion-properties.utils.ts - Notion property creation and formatting utilities
    • createTotalQuestionsProperty(count) - Creates number property for total questions count
    • createCompletedQuestionsProperty(count) - Creates number property for completed questions count
    • extractPageIdFromWebhook(webhookBody) - Extracts page ID from Notion webhook payload
    • extractFullNameFromPage(page) - Extracts full name from Notion page Name property
  • text-redaction.utils.ts - Text redaction utilities for sensitive information
    • redactPersonName(text, fullName) - Redacts person's name from text, replacing with "Respondent"