Web Commits API

  • Tier: Free
  • Offering: GitLab.com, GitLab Self-Managed, GitLab Dedicated
History

Use this API to retrieve information about commits created with the Web UI.

Get public signing key

Get the GitLab public key for signing web commits.

Copy to clipboard
GET /web_commits/public_key

If successful, returns 200 and the following response attribute:

AttributeTypeDescription
public_keystringGitLab public key for signing web commits.

Example request:

Copy to clipboard
curl --url "https://gitlab.example.com/api/v4/web_commits/public_key"

Example response:

Copy to clipboard
[
  {
    public_key: "ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAIEAiPWx6WM4lhHNedGfBpPJNPpZ7yKu+dnn1SJejgt4596k6YjzGGphH2TUxwKzxcKDKKezwkpfnxPkSMkuEspGRt/aZZ9wa++Oi7Qkr8prgHc4soW6NUlfDzpvZK2H5E7eQaSeP3SAwGmQKUFHCddNaP0L+hM7zhFNzjFvpaMgJw0=\""
  }
]