Skip to main content
Server path: /gitlab-repository | Type: Application | PCID required: Yes

Tools

ToolDescription
gitlab_repository_compare_repositoryCompare two branches, tags, or commits
gitlab_repository_create_branchCreate a repository branch
gitlab_repository_get_branchRetrieve a repository branch
gitlab_repository_get_commitRetrieve a commit
gitlab_repository_get_commit_diffRetrieve a commit diff
gitlab_repository_get_fileRetrieve a file from a repository
gitlab_repository_get_projectGet a single project
gitlab_repository_get_treeGet a project repository tree
gitlab_repository_list_branchesList all repository branches
gitlab_repository_list_commitsList all repository commits
gitlab_repository_list_projectsList all projects

gitlab_repository_compare_repository

Compare two branches, tags, or commits Parameters:
ParameterTypeRequiredDefaultDescription
idstringYesThe ID or URL-encoded path of the project
fromstringYesThe commit, branch name, or tag name to start comparison
tostringYesThe commit, branch name, or tag name to stop comparison
from_project_idintegerNoThe project to compare from
straightbooleanNoComparison method, true for direct comparison between from and to (from..to), false to compare using merge base (fromto)
unidiffbooleanNoA diff in a Unified diff format

gitlab_repository_create_branch

Create a repository branch Parameters:
ParameterTypeRequiredDefaultDescription
idstringYesThe ID or URL-encoded path of the project
branchstringYesThe name of the branch
refstringYesCreate branch from commit sha or existing branch

gitlab_repository_get_branch

Retrieve a repository branch Parameters:
ParameterTypeRequiredDefaultDescription
idstringYesThe ID or URL-encoded path of the project
branchstringYesThe branch name

gitlab_repository_get_commit

Retrieve a commit Parameters:
ParameterTypeRequiredDefaultDescription
idstringYesThe ID or URL-encoded path of the project
shastringYesA commit sha, or the name of a branch or tag
statsbooleanNoInclude commit stats

gitlab_repository_get_commit_diff

Retrieve a commit diff Parameters:
ParameterTypeRequiredDefaultDescription
idstringYesThe ID or URL-encoded path of the project
shastringYesA commit sha, or the name of a branch or tag
pageintegerNoCurrent page number
per_pageintegerNoNumber of items per page
unidiffbooleanNoA diff in a Unified diff format

gitlab_repository_get_file

Retrieve a file from a repository Parameters:
ParameterTypeRequiredDefaultDescription
idstringYesThe project ID
file_pathstringYesThe URL-encoded path to the file.
refstringYesThe name of branch, tag or commit

gitlab_repository_get_project

Get a single project Parameters:
ParameterTypeRequiredDefaultDescription
idstringYesThe ID or URL-encoded path of the project
statisticsbooleanNoInclude project statistics
with_custom_attributesbooleanNoInclude custom attributes in the response
licensebooleanNoInclude project license data

gitlab_repository_get_tree

Get a project repository tree Parameters:
ParameterTypeRequiredDefaultDescription
idstringYesThe ID or URL-encoded path of the project
refstringNoThe name of a repository branch or tag, if not given the default branch is used
pathstringNoThe path of the tree
recursivebooleanNoUsed to get a recursive tree
pageintegerNoCurrent page number
per_pageintegerNoNumber of items per page
paginationstringNoSpecify the pagination method (“none” is only valid if “recursive” is true)
page_tokenstringNoRecord from which to start the keyset pagination

gitlab_repository_list_branches

List all repository branches Parameters:
ParameterTypeRequiredDefaultDescription
idstringYesThe ID or URL-encoded path of the project
pageintegerNoCurrent page number
per_pageintegerNoNumber of items per page
searchstringNoReturn list of branches matching the search criteria
regexstringNoReturn list of branches matching the regex
sortstringNoReturn list of branches sorted by the given field
page_tokenstringNoName of branch to start the pagination from

gitlab_repository_list_commits

List all repository commits Parameters:
ParameterTypeRequiredDefaultDescription
idstringYesThe ID or URL-encoded path of the project
ref_namestringNoThe name of a repository branch or tag, if not given the default branch is used
sincestringNoOnly commits after or on this date will be returned
untilstringNoOnly commits before or on this date will be returned
pathstringNoThe file path
followbooleanNoFollow file renames when filtering by path
authorstringNoSearch commits by commit author
allbooleanNoEvery commit will be returned
with_statsbooleanNoStats about each commit will be added to the response
first_parentbooleanNoOnly include the first parent of merges
orderstringNoList commits in order
trailersbooleanNoParse and include Git trailers for every commit
pageintegerNoCurrent page number
per_pageintegerNoNumber of items per page

gitlab_repository_list_projects

List all projects Parameters:
ParameterTypeRequiredDefaultDescription
order_bystringNoReturn projects ordered by field. storage_size, repository_size, wiki_size, packages_size are only available to admins. Similarity is available when searching and is limited to projects the user has access to.
sortstringNoReturn projects sorted in ascending and descending order
archivedbooleanNoLimit by archived status
visibilitystringNoLimit by visibility
searchstringNoReturn list of projects matching the search criteria
search_namespacesbooleanNoInclude ancestor namespaces when matching search criteria
ownedbooleanNoLimit by owned by authenticated user
starredbooleanNoLimit by starred status
importedbooleanNoLimit by imported by authenticated user
membershipbooleanNoLimit by projects that the current user is a member of
with_issues_enabledbooleanNoLimit by enabled issues feature
with_merge_requests_enabledbooleanNoLimit by enabled merge requests feature
with_programming_languagestringNoLimit to repositories which use the given programming language
min_access_levelintegerNoLimit by minimum access level of authenticated user
id_afterintegerNoLimit results to projects with IDs greater than the specified ID
id_beforeintegerNoLimit results to projects with IDs less than the specified ID
last_activity_afterstringNoLimit results to projects with last_activity after specified time. Format: ISO 8601 YYYY-MM-DDTHH:MM:SSZ
last_activity_beforestringNoLimit results to projects with last_activity before specified time. Format: ISO 8601 YYYY-MM-DDTHH:MM:SSZ
repository_storagestringNoWhich storage shard the repository is on. Available only to admins
topicstring[]NoComma-separated list of topics. Limit results to projects having all topics
topic_idintegerNoLimit results to projects with the assigned topic given by the topic ID
updated_beforestringNoReturn projects updated before the specified datetime. Format: ISO 8601 YYYY-MM-DDTHH:MM:SSZ
updated_afterstringNoReturn projects updated after the specified datetime. Format: ISO 8601 YYYY-MM-DDTHH:MM:SSZ
include_pending_deletebooleanNoInclude projects in pending delete state. Can only be set by admins
marked_for_deletion_onstringNoDate when the project was marked for deletion
activebooleanNoLimit by projects that are not archived and not marked for deletion
wiki_checksum_failedbooleanNoLimit by projects where wiki checksum is failed
repository_checksum_failedbooleanNoLimit by projects where repository checksum is failed
include_hiddenbooleanNoInclude hidden projects. Can only be set by admins
pageintegerNoCurrent page number
per_pageintegerNoNumber of items per page
simplebooleanNoReturn only the ID, URL, name, and path of each project
statisticsbooleanNoInclude project statistics
with_custom_attributesbooleanNoInclude custom attributes in the response