Skip to main content
drupalreleases

Use direct release data with your AI assistant.

Learn more

Git Host

No security coverage Under active development

Connect your Drupal site to GitHub and GitLab: add a read-only token for each host once, and modules such as Git Field can read repositories, files and releases from it.

Git Host reads from github.com, GitHub Enterprise (Cloud with data residency, such as example.ghe.com, and Server), gitlab.com and self-managed GitLab. It keeps each host's token in a Key module key, sends it only to that host, and caches the hosts' responses for an hour. It has no user interface of its own: other modules use it.

Features

  • A "Git host token" key type, with the provider and host each token belongs to.
  • A git_host.api service that reads a repository's files, published releases and protected branches, and any other API endpoint, from any host with a key or a public host. It caches successful responses for an hour, and reads up to 1,000 items of a list.
  • Git provider plugins for GitHub and GitLab, which other modules can add to.

Developers: see Using the API.

Post-Installation

Public repositories on github.com and gitlab.com work without any setup, with the hosts' lower rate limits for requests without a token. For other hosts and private repositories:

  1. Create a read-only token for the host:
  2. Add the token as a key at Configuration > System > Keys (/admin/config/system/keys), with the "Git host token" key type. Choose the provider (GitHub or GitLab) and enter the host name only, such as github.com, example.ghe.com or gitlab.example.com. Each host can have one key. Key's providers keep the token out of the site's exported configuration: for example, the "Environment" provider reads it from an environment variable.

Additional Requirements

This module requires the Key module, which stores the tokens for each host.

Modules that use Git Host

  • Git Field: a field for Git repositories, with formatters that show data from them, and a dashboard of the sites you look after.

Ask your assistant about Git Host

Check compatibility with your Drupal and PHP version, maintenance and security coverage, from current release data. How it works

Depends on

Dependencies of the latest stable release

No dependencies recorded for this project.

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
1
Tracked since
Dec 2026
Latest release
1 hour ago
Releases (12 mo)
1 ▲ from 0
Maintenance
Active

Releases

Version Type Core PHP Release date
1.0.x-dev Dev 11 Dec 1, 2026