Skip to content

Update email-on-need-review.yml #8

Update email-on-need-review.yml

Update email-on-need-review.yml #8

name: Send Email on Need Review Issue
on:
issues: [edited]
jobs:
GPT_send_email:
# if: "github.event_name == 'project_card' && github.event.project_card.column_name == 'Needs Review'"
runs-on: ubuntu-latest
# "value": "An issue has been moved into the 'Needs Review' column.\n\nIssue Title: ${{ github.event.project_card.content.title }}\nIssue URL: ${{ github.event.project_card.content_url }}"
steps:
- name: Send Email Notification
env:
SENDGRID_API_KEY: '${{ secrets.SENDGRID_API_KEY }}'
run: |
curl --request POST \
--url https://api.sendgrid.com/v3/mail/send \
--header "Authorization: Bearer $SENDGRID_API_KEY" \
--header 'Content-Type: application/json' \
--data '{
"personalizations": [
{
"to": [
{
"email": "avi.micah@gmail.com"
}
],
"subject": "Issue Needs Review"
}
],
"from": {
"email": "avi.micah@gmail.com"
},
"content": [
{
"type": "text/plain",
"value": "An issue has been moved into the '\''Needs Review'\'' column.\n\nIssue Title: title\nIssue URL: https://github.com/SFUnity/Mayhem-2024-Offseason"
}
]
}'