

Scroll down to "Bot Token Scopes" and add the chat.write and channels:read scopes.Ĭlick on "Install to Workspace" and then "Allow." Give your app a short description and then click "Save Changes."Īfter creating your Slack app, select the "OAuth & Permissions" link. (If using your company's account, you may want or need to create a new workspace.) (You'll need to log in or register a new account if you don't have one.)Ĭlick on the button to create a new Slack app, name it "RChat," and select one of your Slack workspaces. The Slack app simply allows us to send a message to a Slack channel. Optionally, create database indexes by using mongorestore to import the empty database from the dump folder. Open it and make a note of the Realm "App Id": The Lambda function will use the Slack SDK (using credentials we'll store in AWS Secrets Manager).įrom the Atlas UI, click on the Realm logo and you will see the RChat app. EventBridge stores those events in an event bus, and a rule will route it to a Lambda function. We'll add a Realm Trigger that forwards any new ChatMessage documents to EventBridge.
SLACK CLIENT SECRET HOW TO
This post details how to add a new feature to the RChat application – forwarding messages to a Slack channel.

Realm also syncs the chat message with all other members of the chat room. RChat creates new ChatMessage objects which Realm Sync writes to the ChatMessage Atlas collection. We'll use an existing mobile chat application ( RChat). Once in EventBridge, you can route events to other services which can act on them. In this article, we'll show you how to configure Realm and AWS to turn Atlas database changes into Amazon EventBridge events – all without adding a single line of code. You can enrich those applications by integrating with AWS's broad ecosystem of services. Realm makes it easy to develop compelling mobile applications backed by a serverless MongoDB Realm back end and the MongoDB Atlas database service. This post was developed with the help of AWS.
