Skip to content

Latest commit

 

History

History
13 lines (8 loc) · 1.89 KB

README.md

File metadata and controls

13 lines (8 loc) · 1.89 KB

Serverless Slack Queue

This is a Web API project meant to be deployed to AWS as a serverless app. It can then receive Slack slash commands and send the requests to SQS queues for further processing. This allows the slash commands to return quickly to Slack, notifying the user that their request was received, while queueing the request for processing by one or more workers that will read the data from the queues.

To configure the project, enter the following information in appsettings.json:

Once the project is deployed, it waits for incoming commands from Slack. Once a command is received, the application tries to send the message body to a queue called "slack_{command}" where {command} is the shorthand of the Slack slash command. If the queue is not found, the application will try to create a queue and notify the user to resend the command.

Before deploying the application make sure to go through serverless.template and validate that the parameters are to your liking. Points to note are the reserved concurrent executions set to 10, the timeout set to 10 seconds, the memory size set to 1024 MBs and the policies used. If you want to limit the policy scope, you can create an appropriate role and assign it to the Role entry just above Policies. Note that the application needs to have enough rights to send messages to SQS and also create new queues.

The easiest way to deploy the application is to use the AWS Toolkit for Visual Studio.