Skip to content

Mattermost configuration

German Malykh edited this page Aug 18, 2022 · 4 revisions

1. Mattermost notification configuration

To receive Mattermost notifications, you need to fill in the part of the configuration file referring to Mattermost

Configuration template for Mattermost notifications:

  "mattermost": {
    "url": "...",
    "token": "...",
    "chat": "..."
  }
  • "url" - Mattermost Server URL
  • "token" - Bot token
  • "chat" - Chat ID

Next, let's look at how to get this data

1.1. Create Mattermost Workspace (if you don`t have it)



  • Sign Up with Google or GitHub



  • Choose your deployment method and click to "Continue"



  • Enter your organization name and click to "Continue"



  • Create a password and click to "Continue"



  • Mattermost redirects you in the created organization



1.2. Create Bot Account

  • Log in to Mattermost with your administrator account
  • Click Main Menu icon and then click System Console



  • Scroll down to INTEGRATIONS section and click Bot Accounts



  • Select true for Enable Bot Account Creation, and click Save



  • Click the Main Menu icon on the System Console, then click Switch to your team



  • Click the Main Menu icon from the main screen of Mattermost, and click Integrations



  • Select Bot Accounts



  • Add a new bot account
    • Click Bot Accounts > Add Bot Account
    • Specify Username and System Admin for Role



  • Click Create Bot Account. A successful notification dialog displays. On this dialog you can find a Token



  • Copy this Token. You will need this token for configuration steps later

1.3. Adding bot to Channel

  • Open your Workspace and click on "Create New Channel"



  • Enter channel name, select "Private Channel" and create channel



  • Click on "Add members to this private channel", input any symbole and click on option "Invite them to the team"



  • Found bot and click on "Invite"



  • Confirm invitation for bot



  • Click on "Add members to this private channel", found and add your bot



  • Click on "Info" and copy this chat id. You will need this ID for configuration steps later



The final configuration will look like this:

   "mattermost": {
    "url": "allurenotification.cloud.mattermost.com",
    "token": "o1b4d6sceifazdoa1xd1bqgg2a",
    "chat": "u2u6edx22prddm22zb1z2kdqhr"
  }

2. Adding allure-notifications.jar to your autotests project

3. Mattermostbot notification example