Skip to content

Send Email Reminders #362

Send Email Reminders

Send Email Reminders #362

Workflow file for this run

name: Send Email Reminders
on:
schedule:
- cron: '0 0 * * *'
workflow_dispatch:
jobs:
call-api:
runs-on: ubuntu-latest
steps:
- name: Log current time
run: date -u
- name: Call lesson-plan reminders
run: |
curl -s -X GET "${{ secrets.NEXT_PUBLIC_PROD_URL }}/api/emails/reminders/lessonPlans" \
-H "Authorization: Bearer ${{ secrets.CRON_SECRET }}"
- name: Call fill summaries
run: |
curl -s -X GET "${{ secrets.NEXT_PUBLIC_PROD_URL }}/api/emails/reminders/fillSummaries" \
-H "Authorization: Bearer ${{ secrets.CRON_SECRET }}"
- name: Call upcoming filled class reminders
run: |
curl -s -X GET "${{ secrets.NEXT_PUBLIC_PROD_URL }}/api/emails/reminders/upcomingFilled" \
-H "Authorization: Bearer ${{ secrets.CRON_SECRET }}"
- name: Call unfilled absence opportunities
run: |
curl -s -X GET "${{ secrets.NEXT_PUBLIC_PROD_URL }}/api/emails/reminders/unfilledAbsences" \
-H "Authorization: Bearer ${{ secrets.CRON_SECRET }}"
- name: Call daily declaration digests
run: |
curl -s -X GET "${{ secrets.NEXT_PUBLIC_PROD_URL }}/api/emails/reminders/dailyDigest" \
-H "Authorization: Bearer ${{ secrets.CRON_SECRET }}"