Skip to main content

Configurations

About

Welcome to the post deployment section, the last stage in the deployment of Private RainMaker. 🚀 This section should be reviewed only when deployment of RainMaker Services have been successfully completed.
As there are differences in the deployment of Private RainMaker between China and the global region. Two tabs are displayed to distinct global and China region. Please select the relevant tab based on the region of your deployment.


Configure SES to Send Email

About

When a new user is created, RainMaker sends an email notification to the end-users, which contains a verification code. By default Amazon Cognito is used to send these email notifications. However, Amazon Cognito's default email service limits the number of emails sent to 50 per day. This includes all types of emails, such as verification codes sent during user sign-up or password recovery. Therefore, Amazon SES needs to be configured for sending the email notifications to the user instead of relaying on Amazon Cognito. By using SES, it can also support message customizations.

Note

This feature is not supported for OAuth-only RainMaker yet.

Follow these steps to configure SES to send emails:

  1. Log in to the RainMaker dashboard with Superadmin credentials.
  2. Go to the Deployment Settings tab.
  3. Click Email Configurations.

message_template

  1. Enter the email subject.
  2. Choose an email address for sending emails.
  3. Enter your name for From Username.
  4. Enter email body in Template.
  5. Click Set Email Template.
  6. You will get a success message as shown below:

message_template3


Configure the Email Template for Verification Messages

About

When the user signs up, the RainMaker platform sends them an email containing a verification code. This verification code must be used to confirm accounts when logging in using the mobile Apps. You can customize the email template from the RainMaker dashboard, but admin privileges are required to make changes to the template.

Follow these steps to configure email template for verification messages:

  1. Log in to the RainMaker dashboard using your Admin account credentials.
  2. Click Deployment Settings.
  3. Click the Email Configurations tab.

configure2

  1. Keep the template type as Welcome Email Notification.
    • You can change the Subject of the Email.
    • You can change the Template, as per your requirement. This template can be simple text or a valid HTML.
    • Please note that you will need to have the string {####} in the template. This is a placeholder string, which is filled by the AWS service with the verification code.
  2. After your changes are done, click Set Email Template.

configure3

info

With this setup, the verification email sent to new users will use the customized template.


Configure Cognito Domain

about

Cognito domain is required for implementing sign-in using third party identity providers (e.g., Google, Apple) and for linking your Alexa or Google Voice Assistants account with your RainMaker account.
The Cognito domain is used to form the URL of sign-in and sign-up webpages, that are used for third party identity providers and voice assistant integrations.

info

This is not relevant for OAuth-only RainMaker.

Follow these steps to configure the Cognito domain name:

  1. Log in to RainMaker dashboard with Superadmin credentials.
  2. Go to Deployment Settings tab.
  3. Go to Identity Configurations tab.
  4. Enter the value for the custom domain name as shown below:

customdomain

note

Cognito domain names can only contain lower-case letters, numbers, and hyphens.

  1. Click Save and refresh the page to view the full URL if it is not generated automatically.

customdomain_2


Configure Cognito Callback URL (Optional)

about

The callback URLs are needed while using the third party authenticating services and linking your account in Alexa/Google Voice Assistants with your account in RainMaker. After successful sign-in, users are redirected to one of the URLs specified in callback URLs.

Follow these steps to configure the Callback URLs are given below:

  1. Log in to RainMaker dashboard with Superadmin credentials.
  2. Go to Deployment Settings tab.
  3. Go to Cognito Configurations tab.
  4. Enter your callback URLs as shown below. Multiple callback URLs can be specified by entering a comma after each URL.

appclient


Configure MFA (Optional)

about

Admin users can set up multi-factor authentication (MFA) for higher security. This will send a verification code to the admin's phone number at each login.

Increase the SNS sending limit if not done already before going further.

info

This is not supported for OAuth-only RainMaker yet.

Follow these steps to configure MFA:

  1. Log in to RainMaker dashboard with your admin account.
    Go to Deployment Settings > MFA Configuration.

    configure4

  2. To add or update phone number on which you wish to receive the verification code, enter the number along with the country code and click Update.

    configure4

    tip

    You may skip step 2 and 3 if you have already added the phone number.

  3. Verify the phone number by entering the verification code sent to the updated phone number.

    configure4

  4. Your phone number is now updated. You can enable MFA using the toggle.

    configure4

    tip

    You can also disable MFA any time using the same toggle.

  5. MFA settings updated successfully.

    tip

    The settings will reflect from the next login onwards.

    If enabled, an MFA prompt will appear after the initial password authentication:

    configure4


Configure the Location-based Triggers for Weather API Configurations

about

This process enables location-based weather triggers for automation through the integration of the OpenWeather API with RainMaker.
By configuring the API key and setting up polling intervals, devices or systems can automatically respond to weather conditions such as temperature or humidity. This enhances automation by allowing actions like turning on or off devices based on real-time weather data, providing greater customization and efficiency. It adds intelligent, dynamic responses to weather changes, improving convenience and energy management in smart environments.

Follow these steps to configure location-based weather triggers for Weather API Configurations:


  1. Create Open-Weather account
    • Begin the process by signing up for an account at https://home.openweathermap.org/users/sign_up.
    • After signing up, check your email for a verification message and follow the instructions to confirm your email address.
    • Once your email is verified, you will receive an email containing the API key, which will become active within the next couple of hours.

  1. Steps for configuring weather-based automation in RainMaker
    • In Postman, log in to RainMaker using Superadmin credentials.

      weather-API_1

    • Access and configure the deployment settings for location triggers by clicking on the following Swagger link:

      https://swaggerapis.rainmaker.espressif.com/?urls.primaryName=RainMaker%20Superadmin%20APIs#/Deployment%20Setting/cofigureServiceConfiguration
    • Under the Request body, choose Location Trigger Configurations from the dropdown list to see the sample JSON request.

      weather-API_2

    • In Postman, create a new API request.

      PUT - {{url}}/v1/admin/deployment_settings/config/location_trigger

      Follow Get Base Url steps to fetch the {{url}}.

Params
KeyValue
servicelocation_trigger
Header
KeyValue
Authorization{{access_key}}
Body

Select node_id, choose JSON from the dropdown list. Add the following JSON to the body, and click Send.

 {
"weather_trigger_api_key": "<add_your_key>",

"weather_trigger_polling_interval": 30,

"weather_trigger_host_url": "https://api.openweathermap.org/data/2.5/weather?units=metric"

}
tip

Refer to the screenshot below for an example of the required input.

weather-API_3


  1. Test the triggers

    Header
KeyValue
Authorization{{access_key}}
Body

Change the node_id value according to the node on which you want to apply automation trigger.

weather-API_5


Configure the DNS Names

info

This feature is optional for Global RainMaker, but mandatory for China.

about

When the RainMaker backend and the frontend stacks are deployed successfully, you can access the API end points and the Dashboard using the URLs generated. Alternatively, you can configure to use the domain names which are specific to your organization, by configuring the Route 53 service.

Follow these steps to configure the Route 53 service:


  1. Create a hosted Zone in Route 53

  1. Map the hosted zone to the DNS registrar

  1. Map the API Gateway endpoint with the DNS name

    • Once the mapping between the hosted zone and your current DNS provider is done, you will need to configure the API Gateway endpoint to Route 53 hosted zone.
    tip

    Follow Get Base Url steps to fetch the API Gateway endpoint.

    Take note

    Please note, choose the API endpoint type as Edge.

    After the configuration is done, the API Gateway and Custom domain names configuration will be as shown:

    dns1

    The Route 53 configuration for API Gateway will be as shown:

    dns2

    dns3


  1. Configure the Domain name mapping for the RainMaker dashboard

    • When the RainMaker frontend stack is deployed, the required UI components are deployed and a CloudFront distribution is created.

    • This sets up the Content Delivery Network for caching the UI and provides SSL connectivity for the UI dashboard.

    • You can create your organization specific domain name for this, so that the admin users will be able to access the Dashboard using the domain name.

    • To check your CloudFront distribution, search for the CloudFront service from the AWS console.

      dns4 dns5

    • The steps to configure Route 53 DNS mapping for CloudFront distribution are as shown in the link below:

    After the CloudFront distribution is configured with the DNS mapping, the CloudFront screen will be as shown:

    dns7

    The following is the Route 53 screen you'll see when setting up a CloudFront distribution:

    dns8