GitLab API

GitlabTool

Actions1095

Commits → getApiV4ProjectsIdRepositoryCommitsShaDiff

AI-generated

Summary

Retrieve the diff details of a specific commit (identified by sha) in a GitLab project repository, optionally paginating results and controlling diff format.

Inputs

  • id (required) — The ID or URL-encoded path of the GitLab project where the commit exists.
  • sha (required) — The commit SHA, or the name of a branch or tag whose commit diff is to be retrieved.
  • page — The page number to retrieve when paginating the diff results.
  • per_page — The number of diff items to include per page.
  • unidiff — Boolean flag to return the diff in Unified diff format.
  • skipAuthentication — If set to true, skips using authentication credentials.

Output shape

a paginated list of diff objects representing changes made in the specified commit

The output contains commit diff information according to GitLab API v4 schema; pagination parameters affect the number of results. The 'unidiff' flag adjusts formatting of the diff returned.

Links

Discussion