Elementary sends alerts using Microsoft Teams Adaptive Cards format, which provides rich formatting and interactive capabilities. You can create a webhook URL using either Microsoft Teams Connectors (legacy, being deprecated) or Power Automate Workflows (recommended).
Search for "When a HTTP request is received" as your trigger
In the flow, add a "Post adaptive card in a chat or channel" action
Configure the team and channel where you want to post
Save the flow and copy the HTTP POST URL
Important Notes:
When using Power Automate Workflows, Elementary CLI cannot directly verify if messages were successfully delivered. You'll need to monitor your workflow runs in Power Automate to check for any delivery issues.
Workflows can't post in private channels as a flow bot, but can post on behalf of a user
Workflows can only be created in your default environment
Lastly, pass the webhook URL (from either method) to the CLI as a param or in the config.yml file:
To alert on source freshness, you will need to run edr run-operation upload-source-freshness right after each execution of dbt source freshness.
This operation will upload the results to a table, and the execution of edr monitor will send the actual alert.
Note that dbt source freshness and upload-source-freshness needs to run from the same machine.
Note that upload-source-freshness requires passing --project-dir argument.
In order to monitor continuously, use your orchestrator to execute it regularly (we recommend running it right after
your dbt job ends to monitor the latest data updates).
Read more about how to deploy Elementary in production.
If you need help or wish to consult on this, reach out to us
on Slack.