GitHub Action
AWS SNS
Send an SMS from GitHub Actions.
- A AWS Account. Sign up for free
- A A AmazonSNS User
-
Set up your credentials as secrets in your repository settings using
AWS_REGION
,AWS_ACCESS_KEY_ID
,AWS_SECRET_ACCESS_KEY
,FROM_PHONE_NUMBER
,SMS_TEXT_CONTENT
-
Add the following to your workflow
- name: "Sending SMS Notification"
uses: rafaelvicio/sns-sms@1.0.1
with:
FROM_PHONE_NUMBER: "+5561123456789"
SMS_TEXT_CONTENT: "Hello from AWS SNS"
env:
AWS_REGION: ${{ secrets.AWS_REGION }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
Required Phone number to send the SMS to
Required The message you want to send
A AWS Region. Can alternatively be stored in environment
A AWS Access Key ID. Can alternatively be stored in environment
A AWS Secret Access Key. Can alternatively be stored in environment
The SID of the message resource associated with the SMS sent.
This GitHub Action uses a couple of Node.js modules to work.
License and other copyright information for each module are included in the release branch of each action version under node_modules/{module}
.
More information for each package can be found at https://www.npmjs.com/package/{package}