Overview

The OrgDORAMetrics module collects data across all repositories in a GitHub organization to provide a high-level view of delivery performance and reliability. It uses GitHub’s GraphQL API to batch-fetch pull request and issue data, then aggregates across projects for organization-wide insights.

Authentication & Permissions

  • GitHub App Installation Token The GitHub App must be installed on the target organization. Required permissions for the installation token:

    • Contents: Read
    • Pull requests: Read
    • Metadata: Read
    • Issues: Read (for incident data)
  • Or Personal Access Token (PAT) If using a PAT instead, ensure it includes:

    • repo (or public_repo plus repo:status, repo_deployment)
    • read:org (to list and access all repositories)
    • read:discussion or read:issue (to fetch incident issues)

Metrics

Deployment Frequency

  • Total number of pull requests merged into main across the organization in the selected date range.

Lead Time for Changes

  • Average time from the first commit on each pull request to its merge, averaged across all repositories.

Change Failure Rate

  • Proportion of merged pull requests that failed status checks or required rework, measured organization-wide.

Mean Time to Recovery (MTTR)

  • Average time to close issues labeled incident across all repositories.

First Review Time

  • Average time from pull request creation to the first review comment, aggregated across the organization.

First Approval Time

  • Average time from pull request creation to its first approval, organization-wide.

First-to-Last Approval Time

  • Average interval between the first and last approval on each pull request, averaged across the organization.

Last Approval-to-Merge Time

  • Average time from the final approval to merge, across all pull requests.

Time to Open

  • Average time between the earliest commit in a pull request branch and pull request creation, zeroing negative intervals, aggregated.

Time to Merge

  • Average duration from pull request creation to merge completion, across the organization.