Skip to content

Commit 75d0b79

Browse files
committed
updating discord bot to leverage notification role for moving forward
1 parent 5259179 commit 75d0b79

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

lambdas/discord-bot/src/handler.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
NEWSLETTER_CHANNEL_NAME = os.environ["NEWSLETTER_CHANNEL_NAME"]
2323
JOB_BOARD_CHANNEL_NAME = os.environ["JOB_BOARD_CHANNEL_NAME"]
2424
ACTIVELY_HIRING_ROLE_ID = os.environ["ACTIVELY_HIRING_ROLE_ID"]
25+
NOTIFY_ROLE_ID = os.environ["NOTIFY_ROLE_ID"]
2526

2627
# Logging Configuration
2728
logging.getLogger().setLevel(logging.INFO)
@@ -135,7 +136,7 @@ def process_video(body: str, channel_id: str):
135136
if payload is None:
136137
return "There was an issue processing the XML.", 500
137138

138-
message = f"Hey @everyone - Check out Damien's latest video - {payload['videoName']} {payload['videoUrl']}"
139+
message = f"Hey <@&{NOTIFY_ROLE_ID}> - Check out Damien's latest video - {payload['videoName']} {payload['videoUrl']}"
139140
response = dynamodb_client.get_item(
140141
TableName=TABLE_ARN,
141142
Key={

terraform/core/main.tf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -263,6 +263,7 @@ module "discord_bot" {
263263
"CONTENT_CORNER_CHANNEL_NAME" : "📹-content-corner"
264264
"JOB_BOARD_CHANNEL_NAME" : "🏢-job-board"
265265
"ACTIVELY_HIRING_ROLE_ID" : "1329874561818165309"
266+
"NOTIFY_ROLE_ID" : "1338013529843826728"
266267
}
267268

268269
create_permission = true

0 commit comments

Comments
 (0)