File tree Expand file tree Collapse file tree 2 files changed +9
-27
lines changed Expand file tree Collapse file tree 2 files changed +9
-27
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -59,18 +59,23 @@ jobs:
59
59
- name : Send custom email
60
60
run : |
61
61
ENCODED_AUTH=${{ secrets.SENDGRID_KEY }}
62
+ FROM=${{ secrets.EMAIL_FROM }}
63
+ TO=${{ secrets.EMAIL_TO }}
64
+ COUNT=${{ steps.parse.outputs.count }}
65
+ REPOSITORY=${{ github.repository }}
66
+ UNIQUES=${{ steps.parse.outputs.uniques }}
62
67
63
68
curl -X POST https://api.sendgrid.com/v3/mail/send \
64
69
-H "Authorization: Bearer $ENCODED_AUTH" \
65
70
-H "Content-Type: application/json" \
66
71
-d '{
67
72
"personalizations": [{
68
- "to": [{"email": "mohamed.amine.hamdouni@corbado.com" }],
69
- "subject": "Hello from GitHub Actions "
73
+ "to": [{"email": $TO }],
74
+ "subject": "Weekly GitHub Clone Stats for $REPOSITORY "
70
75
}],
71
- "from": {"email": "test@corbado.com" },
76
+ "from": {"email": $FROM },
72
77
"content": [{
73
78
"type": "text/plain",
74
- "value": "This is a custom body sent using base64 auth. "
79
+ "value": "Hi there! Here are the clone stats for $REPOSITORY this week:\n\n🔁 Total Clones: $COUNT\n👤 Unique Cloners: $UNIQUES\n\n– GitHub Bot "
75
80
}]
76
81
}'
You can’t perform that action at this time.
0 commit comments