Bitbucket Deployment Notification and Changelog
When a Bitbucket deployment to staging or production succeeds, the flow compiles the commits/PRs since the last release into a changelog, posts it to a Teams release channel, emails stakeholders, and appends it to a SharePoint release-notes page. Keeps everyone informed of what shipped without manual release notes.
Provided as-is, without warranty of any kind. Review and test each pattern in a non-production environment before deploying it to live automations. See our Terms.
Overview
This flow auto-generates and distributes deployment release notes from Bitbucket. When code is pushed to a configured deployment branch (e.g. main, release, production), it compiles the commits in that push into a changelog, archives the changelog as a Markdown file in a SharePoint release-notes library, posts a summary to a Teams release channel, and emails the changelog to stakeholders via Outlook.
Why it matters: Hand-written changelogs get skipped under deadline pressure. Generating them automatically from the push commit set keeps developers, operations, and stakeholders informed of exactly what shipped — with zero manual effort.
As-built status: Solution created, flow published in the Off state, Flow Checker 0 errors / 0 warnings. Going live requires only connection authorization, environment-variable values, and registering the Bitbucket repo webhook (auto-registered when the flow is turned On).
Use Case
A development / release team wants automatic, distributed release notes whenever a deployment lands on a protected branch. Audience: Developers and Operations.
Flow Architecture
When Code Is Pushed
Bitbucket CreateHookRepositoryPush (webhook)Fires on every push to the monitored repo (account = workspace, slug = repo).
Initialize accumulators and branch list
Initialize VariableSeed the Markdown changelog accumulator, the HTML list-item accumulator, and load the configurable deployment-branch list from the env var.
Compose Pushed Branch / Check Deployment Branch
Compose + Condition (If)Extract the pushed branch from the first push change and proceed only when it is in the deployment-branch list (non-deployment pushes are ignored).
Compile changelog
Foreach (concurrency 1, nested) + Append to String VariableIterate each branch change, then each commit, appending one changelog line per commit (Markdown + HTML), then compose the full Markdown release-notes document (title, branch, workspace, timestamp, commits).
Create Release Notes File
SharePoint CreateFileArchive the changelog .md file to the release-notes library.
Post Changelog To Teams
Teams PostMessageToConversationPost the changelog summary to the release channel.
Email Stakeholders
Outlook SendEmailV2Email the changelog to release stakeholders.
Environment Variables
| Schema name | Type | Default | Description |
|---|---|---|---|
| flowlibs_DeploymentBranches | String | main,master,release,production | Comma-separated branches that count as deployments |
| flowlibs_ReleaseNotesFolderPath | String | /Shared Documents/Release Notes | SharePoint server-relative library/folder for the archived file |
| flowlibs_ReleaseStakeholderEmails | String | release-stakeholders@your-org.com | Email recipients of the changelog |
| flowlibs_BitbucketWorkspace | String | your-workspace | Bitbucket workspace (account param) |
| flowlibs_BitbucketRepoSlug | String | REPLACE_WITH_REPO_SLUG | Bitbucket repository (slug param) |
| flowlibs_SharePointSiteURL | String | https://your-tenant.sharepoint.com | SharePoint site (dataset param) |
| flowlibs_TeamsGroupId | String | REPLACE_WITH_TEAMS_GROUP_ID | Teams group id for the release channel |
| flowlibs_TeamsChannelId | String | REPLACE_WITH_TEAMS_CHANNEL_ID | Teams channel id for the release channel |
Connectors & Connections
| Connector | API name | Actions used |
|---|---|---|
| Bitbucket | shared_bitbucket | CreateHookRepositoryPush |
| SharePoint | shared_sharepointonline | CreateFile |
| Microsoft Teams | shared_teams | PostMessageToConversation |
| Office 365 Outlook | shared_office365 | SendEmailV2 |
Note — All connections are referenced as solution connection references; the flow is portable between environments as long as a connection is mapped at import time.
Customization Guide
Almost every realistic variant of this flow can be implemented by changing environment variable values. A few cases require small edits inside the flow definition — those are called out explicitly below.
- Deployment branches
- Edit flowlibs_DeploymentBranches to match your branching model (e.g. release/* patterns can be matched by expanding the condition logic).
- Conventional commits
- Extend Append_Markdown_Line / Append_HTML_Line to group commits by feat: / fix: / chore: prefixes.
- Ticket links
- Parse Jira/issue keys from commit messages and hyperlink them in the changelog.
- Archive format
- Change the file extension/body in Compose_Release_Notes_Document + Create_Release_Notes_File to produce HTML or .txt notes, or point at a different library via flowlibs_ReleaseNotesFolderPath.
- Recipients & channel
- Repoint flowlibs_ReleaseStakeholderEmails, flowlibs_TeamsGroupId, flowlibs_TeamsChannelId.
Key Expressions
The flow is intentionally light on Power Fx / WDL gymnastics — the heaviest expressions are the branch-name concatenation and the approval outcome check. They are listed below in the order they appear in the flow.
EXPR.01Pushed branch
Extracts the pushed branch name from the first push change.
EXPR.02Is-deployment test
True when the pushed branch is in the deployment-branch list.
EXPR.03Commit author (with fallback)
Resolves the commit author with raw/Unknown fallbacks.
EXPR.04Release-notes filename
Unique filename per deployment.
Customize & download
Generate a ready-to-import copy of this solution with your environment-variable values baked in — available on Base, Pro, or Team.
Upgrade to customize
Comments
Sign in to join the conversation.
Sign inNo comments yet. Be the first to share your experience with this flow.