Skip to content

Add /api/event creation endpoint with Calendar and Slack scheduling#58

Open
sogav21 wants to merge 1 commit into
corecodeio:mainfrom
sogav21:bounty/event-route-slack-calendar
Open

Add /api/event creation endpoint with Calendar and Slack scheduling#58
sogav21 wants to merge 1 commit into
corecodeio:mainfrom
sogav21:bounty/event-route-slack-calendar

Conversation

@sogav21
Copy link
Copy Markdown

@sogav21 sogav21 commented May 11, 2026

Fixes #48

Summary

  • Adds POST /api/event behind the existing auth + write:event permission flow
  • Creates a Google Calendar event in CALENDAR_CELEBRATION_ID and persists the resulting event metadata in the Event table
  • Supports the requested event types: daily message, celebration, and meet
  • Schedules Slack delivery for daily message events using node-schedule, saving ts_daily_message after posting
  • Adds focused unit coverage for daily-message scheduling and Google Meet creation

Validation

  • node --check api/src/controllers/eventControllers/createEvent.controller.js
  • node --check api/src/controllers/eventControllers/index.js
  • node --check api/src/routes/event.router.js
  • node --check api/src/utils/schedule/scheduleDailyMessage.js
  • npx jest --runTestsByPath tests/event.controller.spec.js --runInBand from api/

Note

The full existing API test suite still fails before reaching this change because the current tests target /api_student_v1/user/log-in and require real/fake Stytch + Slack configuration. The focused event controller tests pass.

@netlify
Copy link
Copy Markdown

netlify Bot commented May 11, 2026

Deploy Preview for incredible-centaur-b58d2c ready!

Name Link
🔨 Latest commit 746c652
🔍 Latest deploy log https://app.netlify.com/projects/incredible-centaur-b58d2c/deploys/6a01d72ff8bc35000850f05b
😎 Deploy Preview https://deploy-preview-58--incredible-centaur-b58d2c.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Creation of route of daily events and sending messages by slack

1 participant