Welcome to the Time Variance Authority (TVA) — the watchdog of time tracking! This automated system ensures that no Clockify entries go missing and keeps an eye out for any unusual time anomalies.
With automated updates delivered straight from the Clockify API to Slack, TVA helps maintain transparency and accountability across the timeline. Whether it's a missed entry or a suspicious log, we've got it covered.
- Detect and highlight missing Clockify entries
- Identify and flag suspicious time entries for review
- Ensure everyone's timeline stays clean and accurate
- Provide daily and monthly reporting through Slack
- AWS Lambda Functions with TypeScript
- Clockify API Integration
- Slack Notifications
- Node.js Runtime
- TypeScript for Type Safety
# Install dependencies
npm install
# Build TypeScript
npm run build
# The compiled JavaScript will be in the dist/ directory
# Zip the contents for AWS Lambda deployment
npm run build && cd dist && zip -r ../lambda.zip . && cd .. && zip -r lambda.zip node_modules/
- Daily Check: Runs at 4:30 AM (Mon-Fri)
- Monthly Report: Runs at 11:30 AM (Every Monday)
- Yash Vekaria
- Harish Vaja
- Minimum 8 hours per working day required
- Previous working day is checked daily
- Gaps greater than 4 hours trigger alerts
- Single entries longer than 10 hours are flagged as suspicious
- Monday to Friday only
- Weekends (Saturday & Sunday) excluded
- Configurable holidays excluded
The system monitors for:
- Missing hours (less than 8 hours/day)
- Long duration entries (exceeding 10 hours)
- Large gaps (more than 4 hours between entries)
- Overlapping time entries
CLOCKIFY_API_KEY
: Your Clockify API keySLACK_BOT_TOKEN
: Slack bot token for notificationsSLACK_CHANNEL_ID
: Target Slack channel for notificationsHOLIDAYS
: Comma-separated list of holidays in YYYY-MM-DD formatUSERS
: JSON string containing user configurations
- Automated checks for the previous working day
- Individual time entry analysis
- Immediate Slack notifications for discrepancies
- Comprehensive team-wise summaries
- Total hours tracked per team
- Progress tracking against expected hours
- Fetches time entries from Clockify
- Analyzes entries for discrepancies
- Groups data by teams when needed
- Sends formatted reports to Slack
- Handles rate limiting and error recovery
TVA ensures temporal compliance in time tracking, maintaining order across all timelines!