7 advanced webhook environment variables are now available 📦

Pleased to introduce advanced webhook environment variables on Bitrise!

These new variables give you deeper insights into build triggers, pull request comments, labels, changed files, and commit messages. Use them to optimize automation, boost workflow transparency, and manage resources more efficiently.

Who benefits

Perfect for DevOps teams and platform engineers looking to fine-tune their CI/CD processes.

What’s new

  1. BITRISE_TRIGGER_BY
  • Description: Identifies the entity that triggered the build.
  • Values: Git user’s name, Bitrise user’s name, or specified value for other triggers.
  • Availability: Present in all builds (occasionally empty).
  • Supported providers: All git providers.
  1. BITRISE_TRIGGER_METHOD
  • Description: Indicates the method by which the build was triggered.
  • Values: schedule, webhook, or manual.
  • Availability: Present in all builds.
  • Supported providers: All providers.
  1. BITRISE_GIT_PULL_REQUEST_COMMENT
  • Description: Captures the comment message and ID from a pull request.
  • Availability: Available when build is triggered by a pull request comment.
  • Supported providers: GitHub, GitLab, Bitbucket.
  1. BITRISE_GIT_PULL_REQUEST_COMMENT_ID
  • Description: Captures the comment ID from a pull request.
  • Availability: Available when build is triggered by a pull request comment.
  • Supported providers: GitHub, GitLab, Bitbucket.
  1. BITRISE_GIT_PULL_REQUEST_LABELS
  • Description: Provides a list of new and existing labels on a pull request.
  • Availability: Available when a build is triggered by label changes.
  • Supported providers: GitHub, GitLab.
  1. BITRISE_GIT_CHANGED_FILES
  • Description: Lists file paths changed by the pull request.
  • Availability: Available during push or PR events.
  • Supported providers: GitHub, GitLab, Bitbucket.
  1. BITRISE_GIT_COMMIT_MESSAGES
  • Description: Contains commit messages included by the pull request.
  • Availability: Available during push or PR events.
  • Supported providers: GitHub, GitLab, Bitbucket.

Example use cases

:speech_balloon: Automatic PR comment updates: Use comment IDs to post status updates directly to pull requests.

:test_tube: Conditional test execution: Run specific test suites based on changed files.

:scroll: Dynamic documentation updates: Automatically update documentation when relevant files are modified.

:cloud: Intelligent deployment decisions: Deploy to different environments based on commit messages or labels.

:hash: Slack notifications: Send alerts for specific pull request actions.

:closed_lock_with_key: Security scans on code changes: Trigger security scans when sensitive files are changed.

:writing_hand: Automatic changelog generation: Create changelog entries from pull request commit messages.

:face_with_monocle: Pull request quality checks: Ensure comments and commit messages meet quality standards.

These are some examples for inspiration. Let us know if you come across another create use case.

Read documentation here