---
title: "Get GitHub Enterprise Server statistics"
method: GET
path: "/enterprise-installation/{enterprise_or_org}/server-statistics"
tags: ["server-statistics", "enterprise-admin"]
---

# Get GitHub Enterprise Server statistics

`GET /enterprise-installation/{enterprise_or_org}/server-statistics`

Returns aggregate usage metrics for your GitHub Enterprise Server 3.5+ instance for a specified time period up to 365 days.

To use this endpoint, your GitHub Enterprise Server instance must be connected to GitHub Enterprise Cloud using GitHub Connect. You must enable Server Statistics, and for the API request provide your enterprise account name or organization name connected to the GitHub Enterprise Server. For more information, see "[Enabling Server Statistics for your enterprise](/admin/configuration/configuring-github-connect/enabling-server-statistics-for-your-enterprise)" in the GitHub Enterprise Server documentation.

OAuth app tokens and personal access tokens (classic) need:
  - the `read:enterprise` scope if you connected your GitHub Enterprise Server to an enterprise account and enabled Server Statistics
  - the `read:org` scope if you connected your GitHub Enterprise Server to an organization account and enabled Server Statistics

## Path parameters

- `enterprise_or_org` string, required

## Query parameters

- `date_start` string
- `date_end` string

## Response `200`

Response

- object[] — Response of S4 Proxy endpoint that provides GHES statistics
  - `server_id` string
  - `collection_date` string
  - `schema_version` string
  - `ghes_version` string
  - `host_name` string
  - `github_connect` object
    - `features_enabled` string[]
  - `ghe_stats` object
    - `comments` object
      - `total_commit_comments` integer
      - `total_gist_comments` integer
      - `total_issue_comments` integer
      - `total_pull_request_comments` integer
    - `gists` object
      - `total_gists` integer
      - `private_gists` integer
      - `public_gists` integer
    - `hooks` object
      - `total_hooks` integer
      - `active_hooks` integer
      - `inactive_hooks` integer
    - `issues` object
      - `total_issues` integer
      - `open_issues` integer
      - `closed_issues` integer
    - `milestones` object
      - `total_milestones` integer
      - `open_milestones` integer
      - `closed_milestones` integer
    - `orgs` object
      - `total_orgs` integer
      - `disabled_orgs` integer
      - `total_teams` integer
      - `total_team_members` integer
    - `pages` object
      - `total_pages` integer
    - `pulls` object
      - `total_pulls` integer
      - `merged_pulls` integer
      - `mergeable_pulls` integer
      - `unmergeable_pulls` integer
    - `repos` object
      - `total_repos` integer
      - `root_repos` integer
      - `fork_repos` integer
      - `org_repos` integer
      - `total_pushes` integer
      - `total_wikis` integer
    - `users` object
      - `total_users` integer
      - `admin_users` integer
      - `suspended_users` integer
  - `dormant_users` object
    - `total_dormant_users` integer
    - `dormancy_threshold` string
  - `actions_stats` ServerStatisticsActions — Actions metrics that are included in the Server Statistics payload/export from GHES
    - `number_of_repos_using_actions` integer — The total number of repositories in a GHES installation that have Actions enabled
    - `percentage_of_repos_using_actions` string — The percentage of repositories in a GHES installation that have Actions enabled
  - `packages_stats` ServerStatisticsPackages — Packages metrics that are included in the Server Statistics payload/export from GHES
    - `registry_enabled` boolean — Whether GitHub Packages is enabled globally in a GHES installation
    - `registry_v2_enabled` boolean — Whether a beta registry is enabled in a GHES installation
    - `ecosystems` object[] — The details of the package ecosystems that are enabled in a GHES installation
      - `name` 'npm' | 'maven' | 'docker' | 'nuget' | 'rubygems' | 'containers' — The name of the package ecosystem
      - `enabled` 'TRUE' | 'FALSE' | 'READONLY' — Shows if a package system is enabled, disabled, or read-only in a GHES installation
      - `published_packages_count` integer — The total number of published packages in a package ecosystem in a GHES installation
      - `private_packages_count` integer — The total number of private packages in a package ecosystem in a GHES installation
      - `public_packages_count` integer — The total number of public packages in a package ecosystem in a GHES installation
      - `internal_packages_count` integer — The total number of internal packages in a package ecosystem in a GHES installation
      - `user_packages_count` integer — The total number of user packages in a package ecosystem in a GHES installation
      - `organization_packages_count` integer — The total number of organization packages in a package ecosystem in a GHES installation
      - `daily_download_count` integer — The total number of packages in an ecosystem that have been downloaded in the 24 hours prior to `collection_date` for a GHES installation
      - `daily_update_count` integer — The total number of packages in an ecosystem that have been updated in the 24 hours prior to `collection_date` for a GHES installation
      - `daily_delete_count` integer — The total number of packages in an ecosystem that have been deleted in the 24 hours prior to `collection_date` for a GHES installation
      - `daily_create_count` integer — The total number of packages in an ecosystem that have been created in the 24 hours prior to `collection_date` for a GHES installation

---

[API](https://skmtc.net/github/apis/ghec.md) · [All operations](https://skmtc.net/github/apis/ghec/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/github/ghec/revisions/daeba3129b5f/schema)
