Package org.gitlab4j.api
Class GroupApi
- java.lang.Object
-
- org.gitlab4j.api.AbstractApi
-
- org.gitlab4j.api.GroupApi
-
- All Implemented Interfaces:
org.gitlab4j.models.Constants
public class GroupApi extends AbstractApi
This class implements the client side API for the GitLab groups calls.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.gitlab4j.models.Constants
org.gitlab4j.models.Constants.ActionType, org.gitlab4j.models.Constants.ApplicationScope, org.gitlab4j.models.Constants.ArchiveFormat, org.gitlab4j.models.Constants.AutoCancelPendingPipelines, org.gitlab4j.models.Constants.AutoDevopsDeployStrategy, org.gitlab4j.models.Constants.BuildGitStrategy, org.gitlab4j.models.Constants.CommitBuildState, org.gitlab4j.models.Constants.ContributorOrderBy, org.gitlab4j.models.Constants.DefaultBranchProtectionLevel, org.gitlab4j.models.Constants.DeploymentOrderBy, org.gitlab4j.models.Constants.DeploymentStatus, org.gitlab4j.models.Constants.DeployTokenScope, org.gitlab4j.models.Constants.Encoding, org.gitlab4j.models.Constants.EpicOrderBy, org.gitlab4j.models.Constants.EventScope, org.gitlab4j.models.Constants.GroupOrderBy, org.gitlab4j.models.Constants.GroupSearchScope<T extends java.lang.Object>, org.gitlab4j.models.Constants.ImpersonationState, org.gitlab4j.models.Constants.IssueOrderBy, org.gitlab4j.models.Constants.IssueScope, org.gitlab4j.models.Constants.IssueState, org.gitlab4j.models.Constants.JobScope, org.gitlab4j.models.Constants.LineType, org.gitlab4j.models.Constants.MergeRequestOrderBy, org.gitlab4j.models.Constants.MergeRequestScope, org.gitlab4j.models.Constants.MergeRequestSearchIn, org.gitlab4j.models.Constants.MergeRequestState, org.gitlab4j.models.Constants.MilestoneState, org.gitlab4j.models.Constants.PackageOrderBy, org.gitlab4j.models.Constants.PackageStatus, org.gitlab4j.models.Constants.PipelineOrderBy, org.gitlab4j.models.Constants.PipelineScope, org.gitlab4j.models.Constants.PipelineSource, org.gitlab4j.models.Constants.ProjectAccessTokenScope, org.gitlab4j.models.Constants.ProjectCreationLevel, org.gitlab4j.models.Constants.ProjectFeatureVisibilityAccessLevel, org.gitlab4j.models.Constants.ProjectOrderBy, org.gitlab4j.models.Constants.ProjectSearchScope<T extends java.lang.Object>, org.gitlab4j.models.Constants.SearchScope<T extends java.lang.Object>, org.gitlab4j.models.Constants.SortOrder, org.gitlab4j.models.Constants.SquashOption, org.gitlab4j.models.Constants.StateEvent, org.gitlab4j.models.Constants.SubgroupCreationLevel, org.gitlab4j.models.Constants.TagOrderBy, org.gitlab4j.models.Constants.TargetType, org.gitlab4j.models.Constants.TodoAction, org.gitlab4j.models.Constants.TodoState, org.gitlab4j.models.Constants.TodoType, org.gitlab4j.models.Constants.TokenType
-
-
Field Summary
-
Fields inherited from class org.gitlab4j.api.AbstractApi
gitLabApi
-
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description org.gitlab4j.api.models.Badge
addBadge(java.lang.Object groupIdOrPath, java.lang.String linkUrl, java.lang.String imageUrl)
Add a badge to a group.org.gitlab4j.api.models.Badge
addBadge(java.lang.Object groupIdOrPath, java.lang.String name, java.lang.String linkUrl, java.lang.String imageUrl)
Add a badge to a group.org.gitlab4j.api.models.Group
addGroup(java.lang.String name, java.lang.String path)
Creates a new project group.org.gitlab4j.api.models.Group
addGroup(java.lang.String name, java.lang.String path, java.lang.String description, java.lang.Boolean membershipLock, java.lang.Boolean shareWithGroupLock, org.gitlab4j.api.models.Visibility visibility, java.lang.Boolean lfsEnabled, java.lang.Boolean requestAccessEnabled, java.lang.Long parentId, java.lang.Integer sharedRunnersMinutesLimit)
Deprecated.Will be removed in version 6.0, replaced byaddGroup(String, String, String, Visibility, Boolean, Boolean, Long)
org.gitlab4j.api.models.Group
addGroup(java.lang.String name, java.lang.String path, java.lang.String description, org.gitlab4j.api.models.Visibility visibility, java.lang.Boolean lfsEnabled, java.lang.Boolean requestAccessEnabled, java.lang.Long parentId)
Creates a new project group.org.gitlab4j.api.models.Group
addGroup(org.gitlab4j.api.models.Group group)
void
addLdapGroupLink(java.lang.Object groupIdOrPath, java.lang.String cn, java.lang.Integer groupAccess, java.lang.String provider)
Adds an LDAP group link.void
addLdapGroupLink(java.lang.Object groupIdOrPath, java.lang.String cn, org.gitlab4j.api.models.AccessLevel groupAccess, java.lang.String provider)
Adds an LDAP group link.org.gitlab4j.api.models.Member
addMember(java.lang.Object groupIdOrPath, java.lang.Long userId, java.lang.Integer accessLevel)
Adds a user to the list of group members.org.gitlab4j.api.models.Member
addMember(java.lang.Object groupIdOrPath, java.lang.Long userId, java.lang.Integer accessLevel, java.util.Date expiresAt)
Adds a user to the list of group members.org.gitlab4j.api.models.Member
addMember(java.lang.Object groupIdOrPath, java.lang.Long userId, org.gitlab4j.api.models.AccessLevel accessLevel)
Adds a user to the list of group members.org.gitlab4j.api.models.Member
addMember(java.lang.Object groupIdOrPath, java.lang.Long userId, org.gitlab4j.api.models.AccessLevel accessLevel, java.util.Date expiresAt)
Adds a user to the list of group members.void
addSamlGroupLink(java.lang.Object groupIdOrPath, java.lang.String samlGroupName, java.lang.Integer groupAccess)
Adds an SAML group link.void
addSamlGroupLink(java.lang.Object groupIdOrPath, java.lang.String samlGroupName, java.lang.Integer groupAccess, java.lang.Integer memberRoleId)
Adds an SAML group link.void
addSamlGroupLink(java.lang.Object groupIdOrPath, java.lang.String samlGroupName, org.gitlab4j.api.models.AccessLevel groupAccess)
Adds an SAML group link.void
addSamlGroupLink(java.lang.Object groupIdOrPath, java.lang.String samlGroupName, org.gitlab4j.api.models.AccessLevel groupAccess, int memberRoleId)
Adds an SAML group link.org.gitlab4j.api.models.GroupHook
addWebhook(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.GroupHookParams groupHookParams)
Add a group hookorg.gitlab4j.api.models.AccessRequest
approveAccessRequest(java.lang.Object groupIdOrPath, java.lang.Long userId, org.gitlab4j.api.models.AccessLevel accessLevel)
Approve access for the specified user to the specified group.org.gitlab4j.api.models.Group
createGroup(org.gitlab4j.api.models.GroupParams params)
Creates a new project group.org.gitlab4j.api.models.GroupAccessToken
createGroupAccessToken(java.lang.Object groupIdOrPath, java.lang.String name, java.lang.String description, java.util.Date expiresAt, org.gitlab4j.api.models.ImpersonationToken.Scope[] scopes, org.gitlab4j.api.models.AccessLevel accessLevel)
Create a group access token.org.gitlab4j.api.models.GroupAccessToken
createGroupAccessToken(java.lang.Object groupIdOrPath, java.lang.String name, java.util.Date expiresAt, org.gitlab4j.api.models.ImpersonationToken.Scope[] scopes, org.gitlab4j.api.models.AccessLevel accessLevel)
org.gitlab4j.api.models.Variable
createVariable(java.lang.Object groupIdOrPath, java.lang.String key, java.lang.String value, java.lang.Boolean isProtected)
Create a new group variable.org.gitlab4j.api.models.Variable
createVariable(java.lang.Object groupIdOrPath, java.lang.String key, java.lang.String value, java.lang.Boolean isProtected, java.lang.Boolean masked)
Create a new group variable.void
deleteCustomAttribute(java.lang.Object groupIdOrPath, java.lang.String key)
Delete a custom attribute for the specified group.void
deleteGroup(java.lang.Object groupIdOrPath)
Removes group with all projects inside.void
deleteLdapGroupLink(java.lang.Object groupIdOrPath, java.lang.String cn)
Deletes an LDAP group link.void
deleteLdapGroupLink(java.lang.Object groupIdOrPath, java.lang.String cn, java.lang.String provider)
Deletes an LDAP group link for a specific LDAP provider.void
deleteSamlGroupLink(java.lang.Object groupIdOrPath, java.lang.String samlGroupName)
Deletes an SAML group link.void
deleteVariable(java.lang.Object groupIdOrPath, java.lang.String key)
Deletes a group variable.void
denyAccessRequest(java.lang.Object groupIdOrPath, java.lang.Long userId)
Deny access for the specified user to the specified group.org.gitlab4j.api.models.Badge
editBadge(java.lang.Object groupIdOrPath, java.lang.Long badgeId, java.lang.String linkUrl, java.lang.String imageUrl)
Edit a badge of a group.org.gitlab4j.api.models.Badge
editBadge(java.lang.Object groupIdOrPath, java.lang.Long badgeId, java.lang.String name, java.lang.String linkUrl, java.lang.String imageUrl)
Edit a badge of a group.java.util.Optional<org.gitlab4j.api.models.CustomAttribute>
geOptionalCustomAttribute(java.lang.Object groupIdOrPath, java.lang.String key)
Deprecated.usegetOptionalCustomAttribute(Object, String)
insteadjava.util.List<org.gitlab4j.api.models.AccessRequest>
getAccessRequests(java.lang.Object groupIdOrPath)
Get a List of the group access requests viewable by the authenticated user.Pager<org.gitlab4j.api.models.AccessRequest>
getAccessRequests(java.lang.Object groupIdOrPath, int itemsPerPage)
Get a Pager of the group access requests viewable by the authenticated user.java.util.stream.Stream<org.gitlab4j.api.models.AccessRequest>
getAccessRequestsStream(java.lang.Object groupIdOrPath)
Get a Stream of the group access requests viewable by the authenticated user.java.util.List<org.gitlab4j.api.models.Member>
getAllMembers(java.lang.Object groupIdOrPath)
Gets a list of group members viewable by the authenticated user, including inherited members through ancestor groups.Pager<org.gitlab4j.api.models.Member>
getAllMembers(java.lang.Object groupIdOrPath, int itemsPerPage)
Gets a Pager of group members viewable by the authenticated user, including inherited members through ancestor groups.java.util.List<org.gitlab4j.api.models.Member>
getAllMembers(java.lang.Object groupIdOrPath, int page, int perPage)
Deprecated.Will be removed in version 6.0java.util.List<org.gitlab4j.api.models.Member>
getAllMembers(java.lang.Object groupIdOrPath, java.lang.String query, java.util.List<java.lang.Long> userIds)
Gets a list of group members viewable by the authenticated user, including inherited members through ancestor groups.Pager<org.gitlab4j.api.models.Member>
getAllMembers(java.lang.Object groupIdOrPath, java.lang.String query, java.util.List<java.lang.Long> userIds, int itemsPerPage)
Gets a Pager of group members viewable by the authenticated user, including inherited members through ancestor groups.java.util.stream.Stream<org.gitlab4j.api.models.Member>
getAllMembersStream(java.lang.Object groupIdOrPath)
Gets a Stream of group members viewable by the authenticated user, including inherited members through ancestor groups.java.util.stream.Stream<org.gitlab4j.api.models.Member>
getAllMembersStream(java.lang.Object groupIdOrPath, java.lang.String query, java.util.List<java.lang.Long> userIds)
Gets a Stream of group members viewable by the authenticated user, including inherited members through ancestor groups.org.gitlab4j.api.models.AuditEvent
getAuditEvent(java.lang.Object groupIdOrPath, java.lang.Long auditEventId)
Get a specific audit event of a group.java.util.List<org.gitlab4j.api.models.AuditEvent>
getAuditEvents(java.lang.Object groupIdOrPath, java.util.Date created_after, java.util.Date created_before)
Get a List of the group audit events viewable by Maintainer or an Owner of the group.Pager<org.gitlab4j.api.models.AuditEvent>
getAuditEvents(java.lang.Object groupIdOrPath, java.util.Date created_after, java.util.Date created_before, int itemsPerPage)
Get a Pager of the group audit events viewable by Maintainer or an Owner of the group.java.util.stream.Stream<org.gitlab4j.api.models.AuditEvent>
getAuditEventsStream(java.lang.Object groupIdOrPath, java.util.Date created_after, java.util.Date created_before)
Get a Stream of the group audit events viewable by Maintainer or an Owner of the group.java.io.InputStream
getAvatar(java.lang.Object groupIdOrPath)
Gets the group avatar.org.gitlab4j.api.models.Badge
getBadge(java.lang.Object groupIdOrPath, java.lang.Long badgeId)
Gets a badge of a group.java.util.List<org.gitlab4j.api.models.Badge>
getBadges(java.lang.Object groupIdOrPath)
Gets a list of a group’s badges and its group badges.java.util.List<org.gitlab4j.api.models.Badge>
getBadges(java.lang.Object groupIdOrPath, java.lang.String badgeName)
Gets a list of a group’s badges, case-sensitively filtered on bagdeName if non-null.org.gitlab4j.api.models.CustomAttribute
getCustomAttribute(java.lang.Object groupIdOrPath, java.lang.String key)
Get a single custom attribute for the specified group.java.util.List<org.gitlab4j.api.models.CustomAttribute>
getCustomAttributes(java.lang.Object groupIdOrPath)
Get all custom attributes for the specified group.Pager<org.gitlab4j.api.models.CustomAttribute>
getCustomAttributes(java.lang.Object groupIdOrPath, int itemsPerPage)
Get a Pager of custom attributes for the specified group.java.util.stream.Stream<org.gitlab4j.api.models.CustomAttribute>
getCustomAttributesStream(java.lang.Object groupIdOrPath)
Get a Stream of all custom attributes for the specified group.java.util.List<org.gitlab4j.api.models.Group>
getDescendantGroups(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.GroupFilter filter)
Get a list of visible descendant groups of a given group for the authenticated user using the provided filter.Pager<org.gitlab4j.api.models.Group>
getDescendantGroups(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.GroupFilter filter, int itemsPerPage)
Get a Pager of visible descendant groups of a given group for the authenticated user using the provided filter.java.util.stream.Stream<org.gitlab4j.api.models.Group>
getDescendantGroupsStream(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.GroupFilter filter)
Get a Stream of visible descendant groups of a given group for the authenticated user using the provided filter.org.gitlab4j.api.models.Group
getGroup(java.lang.Object groupIdOrPath)
Get all details of a group.org.gitlab4j.api.models.GroupAccessToken
getGroupAccessToken(java.lang.Object groupIdOrPath, java.lang.Long tokenId)
Get a group access token by ID.java.util.List<org.gitlab4j.api.models.GroupAccessToken>
getGroupAccessTokens(java.lang.Object groupIdOrPath)
Get a list of group access tokens.java.util.List<org.gitlab4j.api.models.Group>
getGroups()
Get a list of groups.Pager<org.gitlab4j.api.models.Group>
getGroups(int itemsPerPage)
Get a Pager of groups.java.util.List<org.gitlab4j.api.models.Group>
getGroups(int page, int perPage)
Get a list of groups (As user: my groups, as admin: all groups) and in the specified page range.java.util.List<org.gitlab4j.api.models.Group>
getGroups(java.lang.String search)
Get all groups that match your string in their name or path.Pager<org.gitlab4j.api.models.Group>
getGroups(java.lang.String search, int itemsPerPage)
Get all groups that match your string in their name or path.java.util.List<org.gitlab4j.api.models.Group>
getGroups(java.lang.String search, int page, int perPage)
Get all groups that match your string in their name or path.java.util.List<org.gitlab4j.api.models.Group>
getGroups(org.gitlab4j.api.models.GroupFilter filter)
Get a list of visible groups for the authenticated user using the provided filter.Pager<org.gitlab4j.api.models.Group>
getGroups(org.gitlab4j.api.models.GroupFilter filter, int itemsPerPage)
Get a Pager of visible groups for the authenticated user using the provided filter.java.util.stream.Stream<org.gitlab4j.api.models.Group>
getGroupsStream()
Get a Stream of groups.java.util.stream.Stream<org.gitlab4j.api.models.Group>
getGroupsStream(java.lang.String search)
Get all groups that match your string in their name or path as a Stream.java.util.stream.Stream<org.gitlab4j.api.models.Group>
getGroupsStream(org.gitlab4j.api.models.GroupFilter filter)
Get a Stream of visible groups for the authenticated user using the provided filter.java.util.List<org.gitlab4j.api.models.LdapGroupLink>
getLdapGroupLinks(java.lang.Object groupIdOrPath)
Get the list of LDAP group links.org.gitlab4j.api.models.Member
getMember(java.lang.Object groupIdOrPath, long userId)
Get a group member viewable by the authenticated user.org.gitlab4j.api.models.Member
getMember(java.lang.Object groupIdOrPath, java.lang.Long userId, java.lang.Boolean includeInherited)
Gets a group team member, optionally including inherited member.java.util.List<org.gitlab4j.api.models.Member>
getMembers(java.lang.Object groupIdOrPath)
Get a list of group members viewable by the authenticated user.Pager<org.gitlab4j.api.models.Member>
getMembers(java.lang.Object groupIdOrPath, int itemsPerPage)
Get a Pager of group members viewable by the authenticated user.java.util.List<org.gitlab4j.api.models.Member>
getMembers(java.lang.Object groupIdOrPath, int page, int perPage)
Get a list of group members viewable by the authenticated user in the specified page range.java.util.stream.Stream<org.gitlab4j.api.models.Member>
getMembersStream(java.lang.Object groupIdOrPath)
Get a Stream of group members viewable by the authenticated user.java.util.Optional<org.gitlab4j.api.models.Badge>
getOptionalBadge(java.lang.Object groupIdOrPath, java.lang.Long badgeId)
Get an Optional instance with the value for the specified badge.java.util.Optional<org.gitlab4j.api.models.CustomAttribute>
getOptionalCustomAttribute(java.lang.Object groupIdOrPath, java.lang.String key)
Get an Optional instance with the value for a single custom attribute for the specified group.java.util.Optional<org.gitlab4j.api.models.Group>
getOptionalGroup(java.lang.Object groupIdOrPath)
Get all details of a group as an Optional instance.java.util.Optional<org.gitlab4j.api.models.Member>
getOptionalMember(java.lang.Object groupIdOrPath, long userId)
Get a group member viewable by the authenticated user as an Optional instance.java.util.Optional<org.gitlab4j.api.models.Member>
getOptionalMember(java.lang.Object groupIdOrPath, java.lang.Long userId, java.lang.Boolean includeInherited)
Gets a group team member, optionally including inherited member.java.util.Optional<org.gitlab4j.api.models.Variable>
getOptionalVariable(java.lang.Object groupIdOrPath, java.lang.String key)
Get the details of a group variable as an Optional instance.java.util.List<org.gitlab4j.api.models.Project>
getProjects(java.lang.Object groupIdOrPath)
Get a list of projects belonging to the specified group ID.Pager<org.gitlab4j.api.models.Project>
getProjects(java.lang.Object groupIdOrPath, int itemsPerPage)
Get a Pager of projects belonging to the specified group ID.java.util.List<org.gitlab4j.api.models.Project>
getProjects(java.lang.Object groupIdOrPath, int page, int perPage)
Get a list of projects belonging to the specified group ID in the specified page range.java.util.List<org.gitlab4j.api.models.Project>
getProjects(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.GroupProjectsFilter filter)
Get a list of projects belonging to the specified group ID and filter.Pager<org.gitlab4j.api.models.Project>
getProjects(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.GroupProjectsFilter filter, int itemsPerPage)
Get a Pager of projects belonging to the specified group ID and filter.java.util.stream.Stream<org.gitlab4j.api.models.Project>
getProjectsStream(java.lang.Object groupIdOrPath)
Get a Stream of projects belonging to the specified group ID.java.util.stream.Stream<org.gitlab4j.api.models.Project>
getProjectsStream(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.GroupProjectsFilter filter)
Get a Stream of projects belonging to the specified group ID and filter.java.util.List<org.gitlab4j.api.models.SamlGroupLink>
getSamlGroupLinks(java.lang.Object groupIdOrPath)
Get the list of SAML group links.java.util.List<org.gitlab4j.api.models.Group>
getSubGroups(java.lang.Object groupIdOrPath)
Get a list of visible direct subgroups in this group.Pager<org.gitlab4j.api.models.Group>
getSubGroups(java.lang.Object groupIdOrPath, int itemsPerPage)
Get a Pager of visible direct subgroups in this group.java.util.List<org.gitlab4j.api.models.Group>
getSubGroups(java.lang.Object groupIdOrPath, java.util.List<java.lang.Integer> skipGroups, java.lang.Boolean allAvailable, java.lang.String search, org.gitlab4j.models.Constants.GroupOrderBy orderBy, org.gitlab4j.models.Constants.SortOrder sortOrder, java.lang.Boolean statistics, java.lang.Boolean owned)
Get a list of visible direct subgroups in this group.Pager<org.gitlab4j.api.models.Group>
getSubGroups(java.lang.Object groupIdOrPath, java.util.List<java.lang.Integer> skipGroups, java.lang.Boolean allAvailable, java.lang.String search, org.gitlab4j.models.Constants.GroupOrderBy orderBy, org.gitlab4j.models.Constants.SortOrder sortOrder, java.lang.Boolean statistics, java.lang.Boolean owned, int itemsPerPage)
Get a Pager of visible direct subgroups in this group.java.util.List<org.gitlab4j.api.models.Group>
getSubGroups(java.lang.Object groupIdOrPath, java.util.List<java.lang.Integer> skipGroups, java.lang.Boolean allAvailable, java.lang.String search, org.gitlab4j.models.Constants.GroupOrderBy orderBy, org.gitlab4j.models.Constants.SortOrder sortOrder, java.lang.Boolean statistics, java.lang.Boolean owned, int page, int perPage)
Get a list of visible direct subgroups in this group.java.util.stream.Stream<org.gitlab4j.api.models.Group>
getSubGroupsStream(java.lang.Object groupIdOrPath)
Get a Stream of visible direct subgroups in this group.java.util.stream.Stream<org.gitlab4j.api.models.Group>
getSubGroupsStream(java.lang.Object groupIdOrPath, java.util.List<java.lang.Integer> skipGroups, java.lang.Boolean allAvailable, java.lang.String search, org.gitlab4j.models.Constants.GroupOrderBy orderBy, org.gitlab4j.models.Constants.SortOrder sortOrder, java.lang.Boolean statistics, java.lang.Boolean owned)
Get a Stream of visible direct subgroups in this group.java.util.List<org.gitlab4j.api.models.UploadedFile>
getUploadFiles(java.lang.Object groupIdOrPath)
Get all uploads of the group sorted by created_at in descending order.org.gitlab4j.api.models.Variable
getVariable(java.lang.Object groupIdOrPath, java.lang.String key)
Get the details of a group variable.java.util.List<org.gitlab4j.api.models.Variable>
getVariables(java.lang.Object groupIdOrPath)
Get list of a group’s variables.Pager<org.gitlab4j.api.models.Variable>
getVariables(java.lang.Object groupIdOrPath, int itemsPerPage)
Get a Pager of variables belonging to the specified group.java.util.List<org.gitlab4j.api.models.Variable>
getVariables(java.lang.Object groupIdOrPath, int page, int perPage)
Get a list of variables for the specified group in the specified page range.java.util.stream.Stream<org.gitlab4j.api.models.Variable>
getVariablesStream(java.lang.Object groupIdOrPath)
Get a Stream of variables belonging to the specified group.void
ldapSync(java.lang.Object groupIdOrPath)
Syncs the group with its linked LDAP group.java.util.List<org.gitlab4j.api.models.Iteration>
listGroupIterations(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.IterationFilter filter)
Lists group iterations.org.gitlab4j.api.models.Badge
previewBadge(java.lang.Object groupIdOrPath, java.lang.String linkUrl, java.lang.String imageUrl)
Returns how the link_url and image_url final URLs would be after resolving the placeholder interpolation.void
removeBadge(java.lang.Object groupIdOrPath, java.lang.Long badgeId)
Remove a badge from a group.void
removeMember(java.lang.Object groupIdOrPath, java.lang.Long userId)
Removes member from the group.org.gitlab4j.api.models.AccessRequest
requestAccess(java.lang.Object groupIdOrPath)
Requests access for the authenticated user to the specified group.void
revokeGroupAccessToken(java.lang.Object groupIdOrPath, java.lang.Long tokenId)
Revoke a group access token.org.gitlab4j.api.models.GroupAccessToken
rotateGroupAccessToken(java.lang.Object groupIdOrPath, java.lang.Long tokenId)
Rotate a group access token.org.gitlab4j.api.models.GroupAccessToken
rotateGroupAccessToken(java.lang.Object groupIdOrPath, java.lang.Long tokenId, java.util.Date expiresAt)
Rotate a group access token.org.gitlab4j.api.models.CustomAttribute
setCustomAttribute(java.lang.Object groupIdOrPath, java.lang.String key, java.lang.String value)
Set a custom attribute for the specified group.org.gitlab4j.api.models.Group
setGroupAvatar(java.lang.Object groupIdOrPath, java.io.File avatarFile)
Uploads and sets the project avatar for the specified group.org.gitlab4j.api.models.Group
shareGroup(java.lang.Object groupIdOrPath, java.lang.Long shareWithGroupId, org.gitlab4j.api.models.AccessLevel groupAccess, java.util.Date expiresAt)
Share group with another group.org.gitlab4j.api.models.Project
transferProject(java.lang.Object groupIdOrPath, java.lang.Object projectIdOrPath)
Transfer a project to the Group namespace.void
unshareGroup(java.lang.Object groupIdOrPath, java.lang.Long sharedWithGroupId)
Unshare the group from another group.org.gitlab4j.api.models.Group
updateGroup(java.lang.Object groupIdOrPath, java.lang.String name, java.lang.String path, java.lang.String description, java.lang.Boolean membershipLock, java.lang.Boolean shareWithGroupLock, org.gitlab4j.api.models.Visibility visibility, java.lang.Boolean lfsEnabled, java.lang.Boolean requestAccessEnabled, java.lang.Long parentId, java.lang.Integer sharedRunnersMinutesLimit)
Deprecated.Will be removed in version 6.0, replaced byupdateGroup(Object, String, String, String, Visibility, Boolean, Boolean, Long)
org.gitlab4j.api.models.Group
updateGroup(java.lang.Object groupIdOrPath, java.lang.String name, java.lang.String path, java.lang.String description, org.gitlab4j.api.models.Visibility visibility, java.lang.Boolean lfsEnabled, java.lang.Boolean requestAccessEnabled, java.lang.Long parentId)
Updates a project group.org.gitlab4j.api.models.Group
updateGroup(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.GroupParams params)
Updates the project group.org.gitlab4j.api.models.Group
updateGroup(org.gitlab4j.api.models.Group group)
Updates a project group.org.gitlab4j.api.models.Member
updateMember(java.lang.Object groupIdOrPath, java.lang.Long userId, java.lang.Integer accessLevel)
Updates a member of a group.org.gitlab4j.api.models.Member
updateMember(java.lang.Object groupIdOrPath, java.lang.Long userId, java.lang.Integer accessLevel, java.util.Date expiresAt)
Updates a member of a group.org.gitlab4j.api.models.Member
updateMember(java.lang.Object groupIdOrPath, java.lang.Long userId, org.gitlab4j.api.models.AccessLevel accessLevel)
Updates a member of a group.org.gitlab4j.api.models.Member
updateMember(java.lang.Object groupIdOrPath, java.lang.Long userId, org.gitlab4j.api.models.AccessLevel accessLevel, java.util.Date expiresAt)
Updates a member of a group.org.gitlab4j.api.models.Variable
updateVariable(java.lang.Object groupIdOrPath, java.lang.String key, java.lang.String value, java.lang.Boolean isProtected)
Update a group variable.org.gitlab4j.api.models.Variable
updateVariable(java.lang.Object groupIdOrPath, java.lang.String key, java.lang.String value, java.lang.Boolean isProtected, java.lang.Boolean masked)
Update a group variable.-
Methods inherited from class org.gitlab4j.api.AbstractApi
addFormParam, addFormParam, delete, delete, get, get, getApiClient, getApiVersion, getDefaultPerPage, getDefaultPerPageParam, getDefaultPerPageParam, getGroupIdOrPath, getLabelIdOrName, getNamespaceIdOrPath, getPageQueryParams, getPageQueryParams, getPerPageQueryParam, getProjectIdOrPath, getUserIdOrUsername, getWithAccepts, handle, head, isApiVersion, patch, patch, post, post, post, post, post, put, put, put, putUpload, putUpload, putWithFormData, putWithFormData, upload, upload, upload, upload, urlEncode, validate
-
-
-
-
Constructor Detail
-
GroupApi
public GroupApi(GitLabApi gitLabApi)
-
-
Method Detail
-
getGroups
public java.util.List<org.gitlab4j.api.models.Group> getGroups() throws GitLabApiException
Get a list of groups. (As user: my groups, as admin: all groups)
WARNING: Do not use this method to fetch groups from https://gitlab.com, gitlab.com has many 1,000's of public groups and it will a long time to fetch all of them. Instead usegetGroups(int itemsPerPage)
which will return a Pager of Group instances.GitLab Endpoint: GET /groups
- Returns:
- the list of groups viewable by the authenticated user
- Throws:
GitLabApiException
- if any exception occurs
-
getGroups
public java.util.List<org.gitlab4j.api.models.Group> getGroups(int page, int perPage) throws GitLabApiException
Get a list of groups (As user: my groups, as admin: all groups) and in the specified page range.GitLab Endpoint: GET /groups
- Parameters:
page
- the page to getperPage
- the number of Group instances per page- Returns:
- the list of groups viewable by the authenticated userin the specified page range
- Throws:
GitLabApiException
- if any exception occurs
-
getGroups
public Pager<org.gitlab4j.api.models.Group> getGroups(int itemsPerPage) throws GitLabApiException
Get a Pager of groups. (As user: my groups, as admin: all groups)GitLab Endpoint: GET /groups
- Parameters:
itemsPerPage
- the number of Group instances that will be fetched per page- Returns:
- the list of groups viewable by the authenticated user
- Throws:
GitLabApiException
- if any exception occurs
-
getGroupsStream
public java.util.stream.Stream<org.gitlab4j.api.models.Group> getGroupsStream() throws GitLabApiException
Get a Stream of groups. (As user: my groups, as admin: all groups)GitLab Endpoint: GET /groups
- Returns:
- a Stream of groups viewable by the authenticated user
- Throws:
GitLabApiException
- if any exception occurs
-
getGroups
public java.util.List<org.gitlab4j.api.models.Group> getGroups(java.lang.String search) throws GitLabApiException
Get all groups that match your string in their name or path.- Parameters:
search
- the group name or path search criteria- Returns:
- a List containing matching Group instances
- Throws:
GitLabApiException
- if any exception occurs
-
getGroups
public java.util.List<org.gitlab4j.api.models.Group> getGroups(java.lang.String search, int page, int perPage) throws GitLabApiException
Get all groups that match your string in their name or path.- Parameters:
search
- the group name or path search criteriapage
- the page to getperPage
- the number of Group instances per page- Returns:
- a List containing matching Group instances
- Throws:
GitLabApiException
- if any exception occurs
-
getGroups
public Pager<org.gitlab4j.api.models.Group> getGroups(java.lang.String search, int itemsPerPage) throws GitLabApiException
Get all groups that match your string in their name or path.- Parameters:
search
- the group name or path search criteriaitemsPerPage
- the number of Group instances that will be fetched per page- Returns:
- a Pager containing matching Group instances
- Throws:
GitLabApiException
- if any exception occurs
-
getGroupsStream
public java.util.stream.Stream<org.gitlab4j.api.models.Group> getGroupsStream(java.lang.String search) throws GitLabApiException
Get all groups that match your string in their name or path as a Stream.- Parameters:
search
- the group name or path search criteria- Returns:
- a Stream containing matching Group instances
- Throws:
GitLabApiException
- if any exception occurs
-
getGroups
public java.util.List<org.gitlab4j.api.models.Group> getGroups(org.gitlab4j.api.models.GroupFilter filter) throws GitLabApiException
Get a list of visible groups for the authenticated user using the provided filter.GitLab Endpoint: GET /groups
- Parameters:
filter
- the GroupFilter to match against- Returns:
- a List<Group> of the matching groups
- Throws:
GitLabApiException
- if any exception occurs
-
getGroups
public Pager<org.gitlab4j.api.models.Group> getGroups(org.gitlab4j.api.models.GroupFilter filter, int itemsPerPage) throws GitLabApiException
Get a Pager of visible groups for the authenticated user using the provided filter.GitLab Endpoint: GET /groups
- Parameters:
filter
- the GroupFilter to match againstitemsPerPage
- the number of Group instances that will be fetched per page- Returns:
- a Pager containing matching Group instances
- Throws:
GitLabApiException
- if any exception occurs
-
getGroupsStream
public java.util.stream.Stream<org.gitlab4j.api.models.Group> getGroupsStream(org.gitlab4j.api.models.GroupFilter filter) throws GitLabApiException
Get a Stream of visible groups for the authenticated user using the provided filter.GitLab Endpoint: GET /groups
- Parameters:
filter
- the GroupFilter to match against- Returns:
- a Stream<Group> of the matching groups
- Throws:
GitLabApiException
- if any exception occurs
-
getSubGroups
public java.util.List<org.gitlab4j.api.models.Group> getSubGroups(java.lang.Object groupIdOrPath) throws GitLabApiException
Get a list of visible direct subgroups in this group.GitLab Endpoint: GET /groups/:id/subgroups
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, required- Returns:
- a List<Group> containing the group's sub-groups
- Throws:
GitLabApiException
- if any exception occurs- Since:
- GitLab 10.3.0
-
getSubGroups
public Pager<org.gitlab4j.api.models.Group> getSubGroups(java.lang.Object groupIdOrPath, int itemsPerPage) throws GitLabApiException
Get a Pager of visible direct subgroups in this group.GitLab Endpoint: GET /groups/:id/subgroups
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requireditemsPerPage
- the number of Group instances that will be fetched per page- Returns:
- a Pager containing matching Group instances
- Throws:
GitLabApiException
- if any exception occurs- Since:
- GitLab 10.3.0
-
getSubGroupsStream
public java.util.stream.Stream<org.gitlab4j.api.models.Group> getSubGroupsStream(java.lang.Object groupIdOrPath) throws GitLabApiException
Get a Stream of visible direct subgroups in this group.GitLab Endpoint: GET /groups/:id/subgroups
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, required- Returns:
- a Stream<Group> containing the group's sub-groups
- Throws:
GitLabApiException
- if any exception occurs- Since:
- GitLab 10.3.0
-
getSubGroups
public java.util.List<org.gitlab4j.api.models.Group> getSubGroups(java.lang.Object groupIdOrPath, java.util.List<java.lang.Integer> skipGroups, java.lang.Boolean allAvailable, java.lang.String search, org.gitlab4j.models.Constants.GroupOrderBy orderBy, org.gitlab4j.models.Constants.SortOrder sortOrder, java.lang.Boolean statistics, java.lang.Boolean owned) throws GitLabApiException
Get a list of visible direct subgroups in this group.GitLab Endpoint: GET /groups/:id/subgroups
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requiredskipGroups
- skip the group IDs passedallAvailable
- show all the groups you have access to (defaults to false for authenticated users)search
- return the list of authorized groups matching the search criteriaorderBy
- order groups by NAME or PATH. Default is NAMEsortOrder
- order groups in ASC or DESC order. Default is ASCstatistics
- include group statistics (admins only)owned
- limit to groups owned by the current user- Returns:
- a List<Group> of the matching subgroups
- Throws:
GitLabApiException
- if any exception occurs- Since:
- GitLab 10.3.0
-
getSubGroups
public java.util.List<org.gitlab4j.api.models.Group> getSubGroups(java.lang.Object groupIdOrPath, java.util.List<java.lang.Integer> skipGroups, java.lang.Boolean allAvailable, java.lang.String search, org.gitlab4j.models.Constants.GroupOrderBy orderBy, org.gitlab4j.models.Constants.SortOrder sortOrder, java.lang.Boolean statistics, java.lang.Boolean owned, int page, int perPage) throws GitLabApiException
Get a list of visible direct subgroups in this group.GitLab Endpoint: GET /groups/:id/subgroups
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requiredskipGroups
- skip the group IDs passedallAvailable
- show all the groups you have access to (defaults to false for authenticated users)search
- return the list of authorized groups matching the search criteriaorderBy
- order groups by NAME or PATH. Default is NAMEsortOrder
- order groups in ASC or DESC order. Default is ASCstatistics
- include group statistics (admins only)owned
- limit to groups owned by the current userpage
- the page to getperPage
- the number of Group instances per page- Returns:
- a List<Group> of the matching subgroups
- Throws:
GitLabApiException
- if any exception occurs- Since:
- GitLab 10.3.0
-
getSubGroups
public Pager<org.gitlab4j.api.models.Group> getSubGroups(java.lang.Object groupIdOrPath, java.util.List<java.lang.Integer> skipGroups, java.lang.Boolean allAvailable, java.lang.String search, org.gitlab4j.models.Constants.GroupOrderBy orderBy, org.gitlab4j.models.Constants.SortOrder sortOrder, java.lang.Boolean statistics, java.lang.Boolean owned, int itemsPerPage) throws GitLabApiException
Get a Pager of visible direct subgroups in this group.GitLab Endpoint: GET /groups/:id/subgroups
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requiredskipGroups
- skip the group IDs passedallAvailable
- show all the groups you have access to (defaults to false for authenticated users)search
- return the list of authorized groups matching the search criteriaorderBy
- order groups by NAME or PATH. Default is NAMEsortOrder
- order groups in ASC or DESC order. Default is ASCstatistics
- include group statistics (admins only)owned
- limit to groups owned by the current useritemsPerPage
- the number of Group instances that will be fetched per page- Returns:
- a Pager containing matching Group instances
- Throws:
GitLabApiException
- if any exception occurs- Since:
- GitLab 10.3.0
-
getSubGroupsStream
public java.util.stream.Stream<org.gitlab4j.api.models.Group> getSubGroupsStream(java.lang.Object groupIdOrPath, java.util.List<java.lang.Integer> skipGroups, java.lang.Boolean allAvailable, java.lang.String search, org.gitlab4j.models.Constants.GroupOrderBy orderBy, org.gitlab4j.models.Constants.SortOrder sortOrder, java.lang.Boolean statistics, java.lang.Boolean owned) throws GitLabApiException
Get a Stream of visible direct subgroups in this group.GitLab Endpoint: GET /groups/:id/subgroups
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requiredskipGroups
- skip the group IDs passedallAvailable
- show all the groups you have access to (defaults to false for authenticated users)search
- return the list of authorized groups matching the search criteriaorderBy
- order groups by NAME or PATH. Default is NAMEsortOrder
- order groups in ASC or DESC order. Default is ASCstatistics
- include group statistics (admins only)owned
- limit to groups owned by the current user- Returns:
- a Stream<Group> of the matching subgroups
- Throws:
GitLabApiException
- if any exception occurs- Since:
- GitLab 10.3.0
-
getDescendantGroups
public java.util.List<org.gitlab4j.api.models.Group> getDescendantGroups(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.GroupFilter filter) throws GitLabApiException
Get a list of visible descendant groups of a given group for the authenticated user using the provided filter.GitLab Endpoint: GET /groups/:id/descendant_groups
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requiredfilter
- the GroupFilter to match against- Returns:
- a List<Group> of the matching groups
- Throws:
GitLabApiException
- if any exception occurs
-
getDescendantGroups
public Pager<org.gitlab4j.api.models.Group> getDescendantGroups(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.GroupFilter filter, int itemsPerPage) throws GitLabApiException
Get a Pager of visible descendant groups of a given group for the authenticated user using the provided filter.GitLab Endpoint: GET /groups/:id/descendant_groups
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requiredfilter
- the GroupFilter to match againstitemsPerPage
- the number of Group instances that will be fetched per page- Returns:
- a Pager containing matching Group instances
- Throws:
GitLabApiException
- if any exception occurs
-
getDescendantGroupsStream
public java.util.stream.Stream<org.gitlab4j.api.models.Group> getDescendantGroupsStream(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.GroupFilter filter) throws GitLabApiException
Get a Stream of visible descendant groups of a given group for the authenticated user using the provided filter.GitLab Endpoint: GET /groups/:id/descendant_groups
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requiredfilter
- the GroupFilter to match against- Returns:
- a Stream<Group> of the matching groups
- Throws:
GitLabApiException
- if any exception occurs
-
getProjects
public java.util.List<org.gitlab4j.api.models.Project> getProjects(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.GroupProjectsFilter filter) throws GitLabApiException
Get a list of projects belonging to the specified group ID and filter.GitLab Endpoint: GET /groups/:id/projects
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathfilter
- the GroupProjectsFilter instance holding the filter values for the query- Returns:
- a List containing Project instances that belong to the group and match the provided filter
- Throws:
GitLabApiException
- if any exception occurs
-
getProjects
public Pager<org.gitlab4j.api.models.Project> getProjects(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.GroupProjectsFilter filter, int itemsPerPage) throws GitLabApiException
Get a Pager of projects belonging to the specified group ID and filter.GitLab Endpoint: GET /groups/:id/projects
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathfilter
- the GroupProjectsFilter instance holding the filter values for the queryitemsPerPage
- the number of Project instances that will be fetched per page- Returns:
- a Pager containing Project instances that belong to the group and match the provided filter
- Throws:
GitLabApiException
- if any exception occurs
-
getProjectsStream
public java.util.stream.Stream<org.gitlab4j.api.models.Project> getProjectsStream(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.GroupProjectsFilter filter) throws GitLabApiException
Get a Stream of projects belonging to the specified group ID and filter.GitLab Endpoint: GET /groups/:id/projects
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathfilter
- the GroupProjectsFilter instance holding the filter values for the query- Returns:
- a Stream containing Project instances that belong to the group and match the provided filter
- Throws:
GitLabApiException
- if any exception occurs
-
getProjects
public java.util.List<org.gitlab4j.api.models.Project> getProjects(java.lang.Object groupIdOrPath) throws GitLabApiException
Get a list of projects belonging to the specified group ID.GitLab Endpoint: GET /groups/:id/projects
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- a list of projects belonging to the specified group ID
- Throws:
GitLabApiException
- if any exception occurs
-
getProjects
public java.util.List<org.gitlab4j.api.models.Project> getProjects(java.lang.Object groupIdOrPath, int page, int perPage) throws GitLabApiException
Get a list of projects belonging to the specified group ID in the specified page range.GitLab Endpoint: GET /groups/:id/projects
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathpage
- the page to getperPage
- the number of Project instances per page- Returns:
- a list of projects belonging to the specified group ID in the specified page range
- Throws:
GitLabApiException
- if any exception occurs
-
getProjects
public Pager<org.gitlab4j.api.models.Project> getProjects(java.lang.Object groupIdOrPath, int itemsPerPage) throws GitLabApiException
Get a Pager of projects belonging to the specified group ID.GitLab Endpoint: GET /groups/:id/projects
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathitemsPerPage
- the number of Project instances that will be fetched per page- Returns:
- a Pager of projects belonging to the specified group ID
- Throws:
GitLabApiException
- if any exception occurs
-
getProjectsStream
public java.util.stream.Stream<org.gitlab4j.api.models.Project> getProjectsStream(java.lang.Object groupIdOrPath) throws GitLabApiException
Get a Stream of projects belonging to the specified group ID.GitLab Endpoint: GET /groups/:id/projects
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- a Stream of projects belonging to the specified group ID
- Throws:
GitLabApiException
- if any exception occurs
-
getGroup
public org.gitlab4j.api.models.Group getGroup(java.lang.Object groupIdOrPath) throws GitLabApiException
Get all details of a group.GitLab Endpoint: GET /groups/:id
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- the Group instance for the specified group path
- Throws:
GitLabApiException
- if any exception occurs
-
getOptionalGroup
public java.util.Optional<org.gitlab4j.api.models.Group> getOptionalGroup(java.lang.Object groupIdOrPath)
Get all details of a group as an Optional instance.GitLab Endpoint: GET /groups/:id
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- the Group for the specified group path as an Optional instance
-
createGroup
public org.gitlab4j.api.models.Group createGroup(org.gitlab4j.api.models.GroupParams params) throws GitLabApiException
Creates a new project group. Available only for users who can create groups.GitLab Endpoint: POST /groups
- Parameters:
params
- a GroupParams instance holding the parameters for the group creation- Returns:
- the created Group instance
- Throws:
GitLabApiException
- if any exception occurs
-
updateGroup
public org.gitlab4j.api.models.Group updateGroup(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.GroupParams params) throws GitLabApiException
Updates the project group. Only available to group owners and administrators.GitLab Endpoint: PUT /groups
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathparams
- the GroupParams instance holding the properties to update- Returns:
- updated Group instance
- Throws:
GitLabApiException
- at any exception
-
addGroup
public org.gitlab4j.api.models.Group addGroup(java.lang.String name, java.lang.String path) throws GitLabApiException
Creates a new project group. Available only for users who can create groups.GitLab Endpoint: POST /groups
- Parameters:
name
- the name of the group to addpath
- the path for the group- Returns:
- the created Group instance
- Throws:
GitLabApiException
- if any exception occurs
-
addGroup
public org.gitlab4j.api.models.Group addGroup(org.gitlab4j.api.models.Group group) throws GitLabApiException
- Throws:
GitLabApiException
-
addGroup
public org.gitlab4j.api.models.Group addGroup(java.lang.String name, java.lang.String path, java.lang.String description, org.gitlab4j.api.models.Visibility visibility, java.lang.Boolean lfsEnabled, java.lang.Boolean requestAccessEnabled, java.lang.Long parentId) throws GitLabApiException
Creates a new project group. Available only for users who can create groups.GitLab Endpoint: POST /groups
- Parameters:
name
- the name of the group to addpath
- the path for the groupdescription
- (optional) - The group's descriptionvisibility
- (optional) - The group's visibility. Can be private, internal, or public.lfsEnabled
- (optional) - Enable/disable Large File Storage (LFS) for the projects in this grouprequestAccessEnabled
- (optional) - Allow users to request member accessparentId
- (optional) - The parent group id for creating nested group- Returns:
- the created Group instance
- Throws:
GitLabApiException
- if any exception occurs
-
updateGroup
public org.gitlab4j.api.models.Group updateGroup(org.gitlab4j.api.models.Group group) throws GitLabApiException
Updates a project group. Available only for users who can create groups.GitLab Endpoint: PUT /groups
- Parameters:
group
- to update- Returns:
- updated group instance
- Throws:
GitLabApiException
- at any exception
-
updateGroup
public org.gitlab4j.api.models.Group updateGroup(java.lang.Object groupIdOrPath, java.lang.String name, java.lang.String path, java.lang.String description, org.gitlab4j.api.models.Visibility visibility, java.lang.Boolean lfsEnabled, java.lang.Boolean requestAccessEnabled, java.lang.Long parentId) throws GitLabApiException
Updates a project group. Available only for users who can create groups.GitLab Endpoint: PUT /groups
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathname
- the name of the group to addpath
- the path for the groupdescription
- (optional) - The group's descriptionvisibility
- (optional) - The group's visibility. Can be private, internal, or public.lfsEnabled
- (optional) - Enable/disable Large File Storage (LFS) for the projects in this grouprequestAccessEnabled
- (optional) - Allow users to request member accessparentId
- (optional) - The parent group id for creating nested group- Returns:
- the updated Group instance
- Throws:
GitLabApiException
- if any exception occurs
-
addGroup
@Deprecated public org.gitlab4j.api.models.Group addGroup(java.lang.String name, java.lang.String path, java.lang.String description, java.lang.Boolean membershipLock, java.lang.Boolean shareWithGroupLock, org.gitlab4j.api.models.Visibility visibility, java.lang.Boolean lfsEnabled, java.lang.Boolean requestAccessEnabled, java.lang.Long parentId, java.lang.Integer sharedRunnersMinutesLimit) throws GitLabApiException
Deprecated.Will be removed in version 6.0, replaced byaddGroup(String, String, String, Visibility, Boolean, Boolean, Long)
Creates a new project group. Available only for users who can create groups.GitLab Endpoint: POST /groups
- Parameters:
name
- the name of the group to addpath
- the path for the groupdescription
- (optional) - The group's descriptionmembershipLock
- (optional, boolean) - Prevent adding new members to project membership within this groupshareWithGroupLock
- (optional, boolean) - Prevent sharing a project with another group within this groupvisibility
- (optional) - The group's visibility. Can be private, internal, or public.lfsEnabled
- (optional) - Enable/disable Large File Storage (LFS) for the projects in this grouprequestAccessEnabled
- (optional) - Allow users to request member access.parentId
- (optional) - The parent group id for creating nested group.sharedRunnersMinutesLimit
- (optional) - (admin-only) Pipeline minutes quota for this group- Returns:
- the created Group instance
- Throws:
GitLabApiException
- if any exception occurs
-
updateGroup
@Deprecated public org.gitlab4j.api.models.Group updateGroup(java.lang.Object groupIdOrPath, java.lang.String name, java.lang.String path, java.lang.String description, java.lang.Boolean membershipLock, java.lang.Boolean shareWithGroupLock, org.gitlab4j.api.models.Visibility visibility, java.lang.Boolean lfsEnabled, java.lang.Boolean requestAccessEnabled, java.lang.Long parentId, java.lang.Integer sharedRunnersMinutesLimit) throws GitLabApiException
Deprecated.Will be removed in version 6.0, replaced byupdateGroup(Object, String, String, String, Visibility, Boolean, Boolean, Long)
Updates a project group. Available only for users who can create groups.GitLab Endpoint: PUT /groups
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathname
- the name of the group to addpath
- the path for the groupdescription
- (optional) - The group's descriptionmembershipLock
- (optional, boolean) - Prevent adding new members to project membership within this groupshareWithGroupLock
- (optional, boolean) - Prevent sharing a project with another group within this groupvisibility
- (optional) - The group's visibility. Can be private, internal, or public.lfsEnabled
- (optional) - Enable/disable Large File Storage (LFS) for the projects in this grouprequestAccessEnabled
- (optional) - Allow users to request member accessparentId
- (optional) - The parent group id for creating nested groupsharedRunnersMinutesLimit
- (optional) - (admin-only) Pipeline minutes quota for this group- Returns:
- the updated Group instance
- Throws:
GitLabApiException
- if any exception occurs
-
deleteGroup
public void deleteGroup(java.lang.Object groupIdOrPath) throws GitLabApiException
Removes group with all projects inside.GitLab Endpoint: DELETE /groups/:id
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Throws:
GitLabApiException
- if any exception occurs
-
getMembers
public java.util.List<org.gitlab4j.api.models.Member> getMembers(java.lang.Object groupIdOrPath) throws GitLabApiException
Get a list of group members viewable by the authenticated user.GitLab Endpoint: GET /groups/:id/members
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- a list of group members viewable by the authenticated user
- Throws:
GitLabApiException
- if any exception occurs
-
getMembers
public java.util.List<org.gitlab4j.api.models.Member> getMembers(java.lang.Object groupIdOrPath, int page, int perPage) throws GitLabApiException
Get a list of group members viewable by the authenticated user in the specified page range.GitLab Endpoint: GET /groups/:id/members
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathpage
- the page to getperPage
- the number of Member instances per page- Returns:
- a list of group members viewable by the authenticated user in the specified page range
- Throws:
GitLabApiException
- if any exception occurs
-
getMembers
public Pager<org.gitlab4j.api.models.Member> getMembers(java.lang.Object groupIdOrPath, int itemsPerPage) throws GitLabApiException
Get a Pager of group members viewable by the authenticated user.GitLab Endpoint: GET /groups/:id/members
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathitemsPerPage
- the number of Member instances that will be fetched per page- Returns:
- a list of group members viewable by the authenticated user
- Throws:
GitLabApiException
- if any exception occurs
-
getMembersStream
public java.util.stream.Stream<org.gitlab4j.api.models.Member> getMembersStream(java.lang.Object groupIdOrPath) throws GitLabApiException
Get a Stream of group members viewable by the authenticated user.GitLab Endpoint: GET /groups/:id/members
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- a Stream of group members viewable by the authenticated user
- Throws:
GitLabApiException
- if any exception occurs
-
getMember
public org.gitlab4j.api.models.Member getMember(java.lang.Object groupIdOrPath, long userId) throws GitLabApiException
Get a group member viewable by the authenticated user.GitLab Endpoint: GET /groups/:id/members/:id
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathuserId
- the member ID of the member to get- Returns:
- a member viewable by the authenticated user
- Throws:
GitLabApiException
- if any exception occurs
-
getOptionalMember
public java.util.Optional<org.gitlab4j.api.models.Member> getOptionalMember(java.lang.Object groupIdOrPath, long userId)
Get a group member viewable by the authenticated user as an Optional instance.GitLab Endpoint: GET /groups/:id/members/:id
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathuserId
- the member ID of the member to get- Returns:
- a member viewable by the authenticated user as an Optional instance
-
getMember
public org.gitlab4j.api.models.Member getMember(java.lang.Object groupIdOrPath, java.lang.Long userId, java.lang.Boolean includeInherited) throws GitLabApiException
Gets a group team member, optionally including inherited member.GitLab Endpoint: GET /groups/:id/members/all/:user_id
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathuserId
- the user ID of the memberincludeInherited
- if true will the member even if inherited thru an ancestor group- Returns:
- the member specified by the project ID/user ID pair
- Throws:
GitLabApiException
- if any exception occurs
-
getOptionalMember
public java.util.Optional<org.gitlab4j.api.models.Member> getOptionalMember(java.lang.Object groupIdOrPath, java.lang.Long userId, java.lang.Boolean includeInherited)
Gets a group team member, optionally including inherited member.GitLab Endpoint: GET /groups/:id/members/all/:user_id
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathuserId
- the user ID of the memberincludeInherited
- if true will the member even if inherited thru an ancestor group- Returns:
- the member specified by the group ID/user ID pair as the value of an Optional
-
getAllMembers
public java.util.List<org.gitlab4j.api.models.Member> getAllMembers(java.lang.Object groupIdOrPath) throws GitLabApiException
Gets a list of group members viewable by the authenticated user, including inherited members through ancestor groups. Returns multiple times the same user (with different member attributes) when the user is a member of the group and of one or more ancestor group.GitLab Endpoint: GET /groups/:id/members/all
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- a list of group members viewable by the authenticated user, including inherited members through ancestor groups
- Throws:
GitLabApiException
- if any exception occurs
-
getAllMembers
@Deprecated public java.util.List<org.gitlab4j.api.models.Member> getAllMembers(java.lang.Object groupIdOrPath, int page, int perPage) throws GitLabApiException
Deprecated.Will be removed in version 6.0Gets a list of group members viewable by the authenticated user, including inherited members through ancestor groups. Returns multiple times the same user (with different member attributes) when the user is a member of the group and of one or more ancestor group.GitLab Endpoint: GET /groups/:id/members/all
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathpage
- the page to getperPage
- the number of Member instances per page- Returns:
- a list of group members viewable by the authenticated user, including inherited members through ancestor groups in the specified page range
- Throws:
GitLabApiException
- if any exception occurs
-
getAllMembers
public Pager<org.gitlab4j.api.models.Member> getAllMembers(java.lang.Object groupIdOrPath, int itemsPerPage) throws GitLabApiException
Gets a Pager of group members viewable by the authenticated user, including inherited members through ancestor groups. Returns multiple times the same user (with different member attributes) when the user is a member of the group and of one or more ancestor group.GitLab Endpoint: GET /groups/:id/members/all
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathitemsPerPage
- the number of Member instances that will be fetched per page- Returns:
- a Pager of group members viewable by the authenticated user, including inherited members through ancestor groups
- Throws:
GitLabApiException
- if any exception occurs
-
getAllMembersStream
public java.util.stream.Stream<org.gitlab4j.api.models.Member> getAllMembersStream(java.lang.Object groupIdOrPath) throws GitLabApiException
Gets a Stream of group members viewable by the authenticated user, including inherited members through ancestor groups. Returns multiple times the same user (with different member attributes) when the user is a member of the group and of one or more ancestor group.GitLab Endpoint: GET /groups/:id/members/all
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- a Stream of group members viewable by the authenticated user, including inherited members through ancestor groups
- Throws:
GitLabApiException
- if any exception occurs
-
getAllMembers
public java.util.List<org.gitlab4j.api.models.Member> getAllMembers(java.lang.Object groupIdOrPath, java.lang.String query, java.util.List<java.lang.Long> userIds) throws GitLabApiException
Gets a list of group members viewable by the authenticated user, including inherited members through ancestor groups. Returns multiple times the same user (with different member attributes) when the user is a member of the group and of one or more ancestor group.GitLab Endpoint: GET /groups/:id/members/all
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathquery
- a query string to search for membersuserIds
- filter the results on the given user IDs- Returns:
- the group members viewable by the authenticated user, including inherited members through ancestor groups
- Throws:
GitLabApiException
- if any exception occurs
-
getAllMembers
public Pager<org.gitlab4j.api.models.Member> getAllMembers(java.lang.Object groupIdOrPath, java.lang.String query, java.util.List<java.lang.Long> userIds, int itemsPerPage) throws GitLabApiException
Gets a Pager of group members viewable by the authenticated user, including inherited members through ancestor groups. Returns multiple times the same user (with different member attributes) when the user is a member of the group and of one or more ancestor group.GitLab Endpoint: GET /groups/:id/members/all
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathquery
- a query string to search for membersuserIds
- filter the results on the given user IDsitemsPerPage
- the number of Project instances that will be fetched per page- Returns:
- a Pager of the group members viewable by the authenticated user, including inherited members through ancestor groups
- Throws:
GitLabApiException
- if any exception occurs
-
getAllMembersStream
public java.util.stream.Stream<org.gitlab4j.api.models.Member> getAllMembersStream(java.lang.Object groupIdOrPath, java.lang.String query, java.util.List<java.lang.Long> userIds) throws GitLabApiException
Gets a Stream of group members viewable by the authenticated user, including inherited members through ancestor groups. Returns multiple times the same user (with different member attributes) when the user is a member of the group and of one or more ancestor group.GitLab Endpoint: GET /groups/:id/members/all
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathquery
- a query string to search for membersuserIds
- filter the results on the given user IDs- Returns:
- a Stream of the group members viewable by the authenticated user, including inherited members through ancestor groups
- Throws:
GitLabApiException
- if any exception occurs
-
addMember
public org.gitlab4j.api.models.Member addMember(java.lang.Object groupIdOrPath, java.lang.Long userId, java.lang.Integer accessLevel) throws GitLabApiException
Adds a user to the list of group members.GitLab Endpoint: POST /groups/:id/members
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathuserId
- the user ID of the member to add, requiredaccessLevel
- the access level for the new member, required- Returns:
- a Member instance for the added user
- Throws:
GitLabApiException
- if any exception occurs
-
addMember
public org.gitlab4j.api.models.Member addMember(java.lang.Object groupIdOrPath, java.lang.Long userId, org.gitlab4j.api.models.AccessLevel accessLevel) throws GitLabApiException
Adds a user to the list of group members.GitLab Endpoint: POST /groups/:id/members
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathuserId
- the user ID of the member to add, requiredaccessLevel
- the access level for the new member, required- Returns:
- a Member instance for the added user
- Throws:
GitLabApiException
- if any exception occurs
-
addMember
public org.gitlab4j.api.models.Member addMember(java.lang.Object groupIdOrPath, java.lang.Long userId, org.gitlab4j.api.models.AccessLevel accessLevel, java.util.Date expiresAt) throws GitLabApiException
Adds a user to the list of group members.GitLab Endpoint: POST /groups/:id/members
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requireduserId
- the user ID of the member to add, requiredaccessLevel
- the access level for the new member, requiredexpiresAt
- the date the membership in the group will expire, optional- Returns:
- a Member instance for the added user
- Throws:
GitLabApiException
- if any exception occurs
-
addMember
public org.gitlab4j.api.models.Member addMember(java.lang.Object groupIdOrPath, java.lang.Long userId, java.lang.Integer accessLevel, java.util.Date expiresAt) throws GitLabApiException
Adds a user to the list of group members.GitLab Endpoint: POST /groups/:id/members
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requireduserId
- the user ID of the member to add, requiredaccessLevel
- the access level for the new member, requiredexpiresAt
- the date the membership in the group will expire, optional- Returns:
- a Member instance for the added user
- Throws:
GitLabApiException
- if any exception occurs
-
updateMember
public org.gitlab4j.api.models.Member updateMember(java.lang.Object groupIdOrPath, java.lang.Long userId, java.lang.Integer accessLevel) throws GitLabApiException
Updates a member of a group.GitLab Endpoint: PUT /groups/:groupId/members/:userId
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requireduserId
- the user ID of the member to update, requiredaccessLevel
- the new access level for the member, required- Returns:
- the updated member
- Throws:
GitLabApiException
- if any exception occurs
-
updateMember
public org.gitlab4j.api.models.Member updateMember(java.lang.Object groupIdOrPath, java.lang.Long userId, org.gitlab4j.api.models.AccessLevel accessLevel) throws GitLabApiException
Updates a member of a group.GitLab Endpoint: PUT /groups/:groupId/members/:userId
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requireduserId
- the user ID of the member to update, requiredaccessLevel
- the new access level for the member, required- Returns:
- the updated member
- Throws:
GitLabApiException
- if any exception occurs
-
updateMember
public org.gitlab4j.api.models.Member updateMember(java.lang.Object groupIdOrPath, java.lang.Long userId, org.gitlab4j.api.models.AccessLevel accessLevel, java.util.Date expiresAt) throws GitLabApiException
Updates a member of a group.GitLab Endpoint: PUT /groups/:groupId/members/:userId
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requireduserId
- the user ID of the member to update, requiredaccessLevel
- the new access level for the member, requiredexpiresAt
- the date the membership in the group will expire, optional- Returns:
- the updated member
- Throws:
GitLabApiException
- if any exception occurs
-
updateMember
public org.gitlab4j.api.models.Member updateMember(java.lang.Object groupIdOrPath, java.lang.Long userId, java.lang.Integer accessLevel, java.util.Date expiresAt) throws GitLabApiException
Updates a member of a group.GitLab Endpoint: PUT /groups/:groupId/members/:userId
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requireduserId
- the user ID of the member to update, requiredaccessLevel
- the new access level for the member, requiredexpiresAt
- the date the membership in the group will expire, optional- Returns:
- the updated member
- Throws:
GitLabApiException
- if any exception occurs
-
removeMember
public void removeMember(java.lang.Object groupIdOrPath, java.lang.Long userId) throws GitLabApiException
Removes member from the group.GitLab Endpoint: DELETE /groups/:id/members/:user_id
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requireduserId
- the user ID of the member to remove- Throws:
GitLabApiException
- if any exception occurs
-
ldapSync
public void ldapSync(java.lang.Object groupIdOrPath) throws GitLabApiException
Syncs the group with its linked LDAP group. Only available to group owners and administrators.GitLab Endpoint: POST /groups/:id/ldap_sync
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Throws:
GitLabApiException
- if any exception occurs
-
getLdapGroupLinks
public java.util.List<org.gitlab4j.api.models.LdapGroupLink> getLdapGroupLinks(java.lang.Object groupIdOrPath) throws GitLabApiException
Get the list of LDAP group links.GitLab Endpoint: GET /groups/:id/ldap_group_links
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- a list of LDAP group links
- Throws:
GitLabApiException
- if any exception occurs
-
addLdapGroupLink
public void addLdapGroupLink(java.lang.Object groupIdOrPath, java.lang.String cn, org.gitlab4j.api.models.AccessLevel groupAccess, java.lang.String provider) throws GitLabApiException
Adds an LDAP group link.GitLab Endpoint: POST /groups/:id/ldap_group_links
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathcn
- the CN of a LDAP groupgroupAccess
- the minimum access level for members of the LDAP groupprovider
- the LDAP provider for the LDAP group- Throws:
GitLabApiException
- if any exception occurs
-
addLdapGroupLink
public void addLdapGroupLink(java.lang.Object groupIdOrPath, java.lang.String cn, java.lang.Integer groupAccess, java.lang.String provider) throws GitLabApiException
Adds an LDAP group link.GitLab Endpoint: POST /groups/:id/ldap_group_links
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathcn
- the CN of a LDAP groupgroupAccess
- the minimum access level for members of the LDAP groupprovider
- the LDAP provider for the LDAP group- Throws:
GitLabApiException
- if any exception occurs
-
deleteLdapGroupLink
public void deleteLdapGroupLink(java.lang.Object groupIdOrPath, java.lang.String cn) throws GitLabApiException
Deletes an LDAP group link.GitLab Endpoint: DELETE /groups/:id/ldap_group_links/:cn
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathcn
- the CN of the LDAP group link to delete- Throws:
GitLabApiException
- if any exception occurs
-
deleteLdapGroupLink
public void deleteLdapGroupLink(java.lang.Object groupIdOrPath, java.lang.String cn, java.lang.String provider) throws GitLabApiException
Deletes an LDAP group link for a specific LDAP provider.GitLab Endpoint: DELETE /groups/:id/ldap_group_links/:provider/:cn
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathcn
- the CN of the LDAP group link to deleteprovider
- the name of the LDAP provider- Throws:
GitLabApiException
- if any exception occurs
-
getSamlGroupLinks
public java.util.List<org.gitlab4j.api.models.SamlGroupLink> getSamlGroupLinks(java.lang.Object groupIdOrPath) throws GitLabApiException
Get the list of SAML group links.GitLab Endpoint: GET /groups/:id/saml_group_links
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- a list of SAML group links
- Throws:
GitLabApiException
- if any exception occurs
-
addSamlGroupLink
public void addSamlGroupLink(java.lang.Object groupIdOrPath, java.lang.String samlGroupName, org.gitlab4j.api.models.AccessLevel groupAccess) throws GitLabApiException
Adds an SAML group link.GitLab Endpoint: POST /groups/:id/saml_group_links
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathsamlGroupName
- the name of the SAML groupgroupAccess
- the minimum access level for members of the SAML group- Throws:
GitLabApiException
- if any exception occurs
-
addSamlGroupLink
public void addSamlGroupLink(java.lang.Object groupIdOrPath, java.lang.String samlGroupName, org.gitlab4j.api.models.AccessLevel groupAccess, int memberRoleId) throws GitLabApiException
Adds an SAML group link.GitLab Endpoint: POST /groups/:id/saml_group_links
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathsamlGroupName
- the name of the SAML groupgroupAccess
- the minimum access level for members of the SAML groupmemberRoleId
- the id of the custom member role to assign- Throws:
GitLabApiException
- if any exception occurs
-
addSamlGroupLink
public void addSamlGroupLink(java.lang.Object groupIdOrPath, java.lang.String samlGroupName, java.lang.Integer groupAccess) throws GitLabApiException
Adds an SAML group link.GitLab Endpoint: POST /groups/:id/saml_group_links
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathsamlGroupName
- the name of the SAML groupgroupAccess
- the minimum access level for members of the SAML group- Throws:
GitLabApiException
- if any exception occurs
-
addSamlGroupLink
public void addSamlGroupLink(java.lang.Object groupIdOrPath, java.lang.String samlGroupName, java.lang.Integer groupAccess, java.lang.Integer memberRoleId) throws GitLabApiException
Adds an SAML group link.GitLab Endpoint: POST /groups/:id/saml_group_links
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathsamlGroupName
- the name of the SAML groupgroupAccess
- the minimum access level for members of the SAML groupmemberRoleId
- the id of the custom member role to assign- Throws:
GitLabApiException
- if any exception occurs
-
deleteSamlGroupLink
public void deleteSamlGroupLink(java.lang.Object groupIdOrPath, java.lang.String samlGroupName) throws GitLabApiException
Deletes an SAML group link.GitLab Endpoint: DELETE /groups/:id/saml_group_links/:cn
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathsamlGroupName
- the name of the SAML group to delete- Throws:
GitLabApiException
- if any exception occurs
-
getVariables
public java.util.List<org.gitlab4j.api.models.Variable> getVariables(java.lang.Object groupIdOrPath) throws GitLabApiException
Get list of a group’s variables.GitLab Endpoint: GET /groups/:id/variables
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- a list of variables belonging to the specified group
- Throws:
GitLabApiException
- if any exception occurs
-
getVariables
public java.util.List<org.gitlab4j.api.models.Variable> getVariables(java.lang.Object groupIdOrPath, int page, int perPage) throws GitLabApiException
Get a list of variables for the specified group in the specified page range.GitLab Endpoint: GET /groups/:id/variables
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathpage
- the page to getperPage
- the number of Variable instances per page- Returns:
- a list of variables belonging to the specified group in the specified page range
- Throws:
GitLabApiException
- if any exception occurs
-
getVariables
public Pager<org.gitlab4j.api.models.Variable> getVariables(java.lang.Object groupIdOrPath, int itemsPerPage) throws GitLabApiException
Get a Pager of variables belonging to the specified group.GitLab Endpoint: GET /groups/:id/variables
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathitemsPerPage
- the number of Variable instances that will be fetched per page- Returns:
- a Pager of variables belonging to the specified group
- Throws:
GitLabApiException
- if any exception occurs
-
getVariablesStream
public java.util.stream.Stream<org.gitlab4j.api.models.Variable> getVariablesStream(java.lang.Object groupIdOrPath) throws GitLabApiException
Get a Stream of variables belonging to the specified group.GitLab Endpoint: GET /groups/:id/variables
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- a Stream of variables belonging to the specified group
- Throws:
GitLabApiException
- if any exception occurs
-
getVariable
public org.gitlab4j.api.models.Variable getVariable(java.lang.Object groupIdOrPath, java.lang.String key) throws GitLabApiException
Get the details of a group variable.GitLab Endpoint: GET /groups/:id/variables/:key
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathkey
- the key of an existing variable, required- Returns:
- the Variable instance for the specified group variable
- Throws:
GitLabApiException
- if any exception occurs
-
getOptionalVariable
public java.util.Optional<org.gitlab4j.api.models.Variable> getOptionalVariable(java.lang.Object groupIdOrPath, java.lang.String key)
Get the details of a group variable as an Optional instance.GitLab Endpoint: GET /groups/:id/variables/:key
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathkey
- the key of an existing variable, required- Returns:
- the Variable for the specified group variable as an Optional instance
-
createVariable
public org.gitlab4j.api.models.Variable createVariable(java.lang.Object groupIdOrPath, java.lang.String key, java.lang.String value, java.lang.Boolean isProtected) throws GitLabApiException
Create a new group variable.GitLab Endpoint: POST /groups/:id/variables
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requiredkey
- the key of a variable; must have no more than 255 characters; only A-Z, a-z, 0-9, and _ are allowed, requiredvalue
- the value for the variable, requiredisProtected
- whether the variable is protected, optional- Returns:
- a Variable instance with the newly created variable
- Throws:
GitLabApiException
- if any exception occurs during execution
-
createVariable
public org.gitlab4j.api.models.Variable createVariable(java.lang.Object groupIdOrPath, java.lang.String key, java.lang.String value, java.lang.Boolean isProtected, java.lang.Boolean masked) throws GitLabApiException
Create a new group variable.GitLab Endpoint: POST /groups/:id/variables
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requiredkey
- the key of a variable; must have no more than 255 characters; only A-Z, a-z, 0-9, and _ are allowed, requiredvalue
- the value for the variable, requiredisProtected
- whether the variable is protected, optionalmasked
- whether the variable is masked, optional- Returns:
- a Variable instance with the newly created variable
- Throws:
GitLabApiException
- if any exception occurs during execution
-
updateVariable
public org.gitlab4j.api.models.Variable updateVariable(java.lang.Object groupIdOrPath, java.lang.String key, java.lang.String value, java.lang.Boolean isProtected) throws GitLabApiException
Update a group variable.GitLab Endpoint: PUT /groups/:id/variables/:key
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requiredkey
- the key of an existing variable, requiredvalue
- the value for the variable, requiredisProtected
- whether the variable is protected, optional- Returns:
- a Variable instance with the updated variable
- Throws:
GitLabApiException
- if any exception occurs during execution
-
updateVariable
public org.gitlab4j.api.models.Variable updateVariable(java.lang.Object groupIdOrPath, java.lang.String key, java.lang.String value, java.lang.Boolean isProtected, java.lang.Boolean masked) throws GitLabApiException
Update a group variable.GitLab Endpoint: PUT /groups/:id/variables/:key
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requiredkey
- the key of an existing variable, requiredvalue
- the value for the variable, requiredisProtected
- whether the variable is protected, optionalmasked
- whether the variable is masked, optional- Returns:
- a Variable instance with the updated variable
- Throws:
GitLabApiException
- if any exception occurs during execution
-
deleteVariable
public void deleteVariable(java.lang.Object groupIdOrPath, java.lang.String key) throws GitLabApiException
Deletes a group variable.GitLab Endpoint: DELETE /groups/:id/variables/:key
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requiredkey
- the key of an existing variable, required- Throws:
GitLabApiException
- if any exception occurs
-
transferProject
public org.gitlab4j.api.models.Project transferProject(java.lang.Object groupIdOrPath, java.lang.Object projectIdOrPath) throws GitLabApiException
Transfer a project to the Group namespace. Available only for admin users.GitLab Endpoint: POST /groups/:id/projects/:project_id
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path, requiredprojectIdOrPath
- the project in the form of an Long(ID), String(path), or Project instance, required- Returns:
- the transferred Project instance
- Throws:
GitLabApiException
- if any exception occurs during execution
-
getAuditEvents
public java.util.List<org.gitlab4j.api.models.AuditEvent> getAuditEvents(java.lang.Object groupIdOrPath, java.util.Date created_after, java.util.Date created_before) throws GitLabApiException
Get a List of the group audit events viewable by Maintainer or an Owner of the group.GET /groups/:id/audit_events
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathcreated_after
- Group audit events created on or after the given time.created_before
- Group audit events created on or before the given time.- Returns:
- a List of group Audit events
- Throws:
GitLabApiException
- if any exception occurs
-
getAuditEvents
public Pager<org.gitlab4j.api.models.AuditEvent> getAuditEvents(java.lang.Object groupIdOrPath, java.util.Date created_after, java.util.Date created_before, int itemsPerPage) throws GitLabApiException
Get a Pager of the group audit events viewable by Maintainer or an Owner of the group.GET /groups/:id/audit_events
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathcreated_after
- Group audit events created on or after the given time.created_before
- Group audit events created on or before the given time.itemsPerPage
- the number of Audit Event instances that will be fetched per page- Returns:
- a Pager of group Audit events
- Throws:
GitLabApiException
- if any exception occurs
-
getAuditEventsStream
public java.util.stream.Stream<org.gitlab4j.api.models.AuditEvent> getAuditEventsStream(java.lang.Object groupIdOrPath, java.util.Date created_after, java.util.Date created_before) throws GitLabApiException
Get a Stream of the group audit events viewable by Maintainer or an Owner of the group.GET /groups/:id/audit_events
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathcreated_after
- Group audit events created on or after the given time.created_before
- Group audit events created on or before the given time.- Returns:
- a Stream of group Audit events
- Throws:
GitLabApiException
- if any exception occurs
-
getAuditEvent
public org.gitlab4j.api.models.AuditEvent getAuditEvent(java.lang.Object groupIdOrPath, java.lang.Long auditEventId) throws GitLabApiException
Get a specific audit event of a group.GitLab Endpoint: GET /groups/:id/audit_events/:id_audit_event
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathauditEventId
- the auditEventId, required- Returns:
- the group Audit event
- Throws:
GitLabApiException
- if any exception occurs
-
getAccessRequests
public java.util.List<org.gitlab4j.api.models.AccessRequest> getAccessRequests(java.lang.Object groupIdOrPath) throws GitLabApiException
Get a List of the group access requests viewable by the authenticated user.GET /group/:id/access_requests
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- a List of project AccessRequest instances accessible by the authenticated user
- Throws:
GitLabApiException
- if any exception occurs
-
getAccessRequests
public Pager<org.gitlab4j.api.models.AccessRequest> getAccessRequests(java.lang.Object groupIdOrPath, int itemsPerPage) throws GitLabApiException
Get a Pager of the group access requests viewable by the authenticated user.GET /groups/:id/access_requests
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathitemsPerPage
- the number of AccessRequest instances that will be fetched per page- Returns:
- a Pager of group AccessRequest instances accessible by the authenticated user
- Throws:
GitLabApiException
- if any exception occurs
-
getAccessRequestsStream
public java.util.stream.Stream<org.gitlab4j.api.models.AccessRequest> getAccessRequestsStream(java.lang.Object groupIdOrPath) throws GitLabApiException
Get a Stream of the group access requests viewable by the authenticated user.GET /groups/:id/access_requests
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- a Stream of group AccessRequest instances accessible by the authenticated user
- Throws:
GitLabApiException
- if any exception occurs
-
requestAccess
public org.gitlab4j.api.models.AccessRequest requestAccess(java.lang.Object groupIdOrPath) throws GitLabApiException
Requests access for the authenticated user to the specified group.POST /groups/:id/access_requests
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- the created AccessRequest instance
- Throws:
GitLabApiException
- if any exception occurs
-
approveAccessRequest
public org.gitlab4j.api.models.AccessRequest approveAccessRequest(java.lang.Object groupIdOrPath, java.lang.Long userId, org.gitlab4j.api.models.AccessLevel accessLevel) throws GitLabApiException
Approve access for the specified user to the specified group.PUT /groups/:id/access_requests/:user_id/approve
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathuserId
- the user ID to approve access foraccessLevel
- the access level the user is approved for, if null will be developer (30)- Returns:
- the approved AccessRequest instance
- Throws:
GitLabApiException
- if any exception occurs
-
denyAccessRequest
public void denyAccessRequest(java.lang.Object groupIdOrPath, java.lang.Long userId) throws GitLabApiException
Deny access for the specified user to the specified group.DELETE /groups/:id/access_requests/:user_id
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathuserId
- the user ID to deny access for- Throws:
GitLabApiException
- if any exception occurs
-
getBadges
public java.util.List<org.gitlab4j.api.models.Badge> getBadges(java.lang.Object groupIdOrPath) throws GitLabApiException
Gets a list of a group’s badges and its group badges.GitLab Endpoint: GET /groups/:id/badges
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- a List of Badge instances for the specified group
- Throws:
GitLabApiException
- if any exception occurs
-
getBadges
public java.util.List<org.gitlab4j.api.models.Badge> getBadges(java.lang.Object groupIdOrPath, java.lang.String badgeName) throws GitLabApiException
Gets a list of a group’s badges, case-sensitively filtered on bagdeName if non-null.GitLab Endpoint: GET /groups/:id/badges?name=:name
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathbadgeName
- The name to filter on (case-sensitive), ignored if null.- Returns:
- All badges of the GitLab item, case insensitively filtered on name.
- Throws:
GitLabApiException
- If any problem is encountered
-
getBadge
public org.gitlab4j.api.models.Badge getBadge(java.lang.Object groupIdOrPath, java.lang.Long badgeId) throws GitLabApiException
Gets a badge of a group.GitLab Endpoint: GET /groups/:id/badges/:badge_id
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathbadgeId
- the ID of the badge to get- Returns:
- a Badge instance for the specified group/badge ID pair
- Throws:
GitLabApiException
- if any exception occurs
-
getOptionalBadge
public java.util.Optional<org.gitlab4j.api.models.Badge> getOptionalBadge(java.lang.Object groupIdOrPath, java.lang.Long badgeId)
Get an Optional instance with the value for the specified badge.GitLab Endpoint: GET /groups/:id/badges/:badge_id
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathbadgeId
- the ID of the badge to get- Returns:
- an Optional instance with the specified badge as the value
-
addBadge
public org.gitlab4j.api.models.Badge addBadge(java.lang.Object groupIdOrPath, java.lang.String linkUrl, java.lang.String imageUrl) throws GitLabApiException
Add a badge to a group.GitLab Endpoint: POST /groups/:id/badges
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathlinkUrl
- the URL of the badge linkimageUrl
- the URL of the image link- Returns:
- a Badge instance for the added badge
- Throws:
GitLabApiException
- if any exception occurs
-
addBadge
public org.gitlab4j.api.models.Badge addBadge(java.lang.Object groupIdOrPath, java.lang.String name, java.lang.String linkUrl, java.lang.String imageUrl) throws GitLabApiException
Add a badge to a group.GitLab Endpoint: POST /groups/:id/badges
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathname
- The name to give the badge (may be null)linkUrl
- the URL of the badge linkimageUrl
- the URL of the image link- Returns:
- A Badge instance for the added badge
- Throws:
GitLabApiException
- if any exception occurs
-
editBadge
public org.gitlab4j.api.models.Badge editBadge(java.lang.Object groupIdOrPath, java.lang.Long badgeId, java.lang.String linkUrl, java.lang.String imageUrl) throws GitLabApiException
Edit a badge of a group.GitLab Endpoint: PUT /groups/:id/badges
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathbadgeId
- the ID of the badge to getlinkUrl
- the URL of the badge linkimageUrl
- the URL of the image link- Returns:
- a Badge instance for the editted badge
- Throws:
GitLabApiException
- if any exception occurs
-
editBadge
public org.gitlab4j.api.models.Badge editBadge(java.lang.Object groupIdOrPath, java.lang.Long badgeId, java.lang.String name, java.lang.String linkUrl, java.lang.String imageUrl) throws GitLabApiException
Edit a badge of a group.GitLab Endpoint: PUT /groups/:id/badges
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathbadgeId
- the ID of the badge to editname
- The name of the badge to edit (may be null)linkUrl
- the URL of the badge linkimageUrl
- the URL of the image link- Returns:
- a Badge instance for the edited badge
- Throws:
GitLabApiException
- if any exception occurs
-
removeBadge
public void removeBadge(java.lang.Object groupIdOrPath, java.lang.Long badgeId) throws GitLabApiException
Remove a badge from a group.GitLab Endpoint: DELETE /groups/:id/badges/:badge_id
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathbadgeId
- the ID of the badge to remove- Throws:
GitLabApiException
- if any exception occurs
-
previewBadge
public org.gitlab4j.api.models.Badge previewBadge(java.lang.Object groupIdOrPath, java.lang.String linkUrl, java.lang.String imageUrl) throws GitLabApiException
Returns how the link_url and image_url final URLs would be after resolving the placeholder interpolation.GitLab Endpoint: GET /groups/:id/badges/render
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathlinkUrl
- the URL of the badge linkimageUrl
- the URL of the image link- Returns:
- a Badge instance for the rendered badge
- Throws:
GitLabApiException
- if any exception occurs
-
setGroupAvatar
public org.gitlab4j.api.models.Group setGroupAvatar(java.lang.Object groupIdOrPath, java.io.File avatarFile) throws GitLabApiException
Uploads and sets the project avatar for the specified group.GitLab Endpoint: PUT /groups/:id
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathavatarFile
- the File instance of the avatar file to upload- Returns:
- the updated Group instance
- Throws:
GitLabApiException
- if any exception occurs
-
getAvatar
public java.io.InputStream getAvatar(java.lang.Object groupIdOrPath) throws GitLabApiException
Gets the group avatar. Only working with GitLab 14.0 and above.GitLab Endpoint: GET /groups/:id/avatar
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or path- Returns:
- an InputStream to read the raw file from
- Throws:
GitLabApiException
- if any exception occurs
-
shareGroup
public org.gitlab4j.api.models.Group shareGroup(java.lang.Object groupIdOrPath, java.lang.Long shareWithGroupId, org.gitlab4j.api.models.AccessLevel groupAccess, java.util.Date expiresAt) throws GitLabApiException
Share group with another group. Returns 200 and the group details on success.GitLab Endpoint: POST /groups/:id/share
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathshareWithGroupId
- the ID of the group to share with, requiredgroupAccess
- the access level to grant the group, requiredexpiresAt
- expiration date of the share, optional- Returns:
- a Group instance holding the details of the shared group
- Throws:
GitLabApiException
- if any exception occurs
-
unshareGroup
public void unshareGroup(java.lang.Object groupIdOrPath, java.lang.Long sharedWithGroupId) throws GitLabApiException
Unshare the group from another group.GitLab Endpoint: DELETE /groups/:id/share/:group_id
- Parameters:
groupIdOrPath
- the group ID, path of the group, or a Group instance holding the group ID or pathsharedWithGroupId
- the ID of the group to unshare with, required- Throws:
GitLabApiException
- if any exception occurs
-
getCustomAttributes
public java.util.List<org.gitlab4j.api.models.CustomAttribute> getCustomAttributes(java.lang.Object groupIdOrPath) throws GitLabApiException
Get all custom attributes for the specified group.GitLab Endpoint: GET /groups/:id/custom_attributes
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instance- Returns:
- a list of group's CustomAttributes
- Throws:
GitLabApiException
- if any exception occurs
-
getCustomAttributes
public Pager<org.gitlab4j.api.models.CustomAttribute> getCustomAttributes(java.lang.Object groupIdOrPath, int itemsPerPage) throws GitLabApiException
Get a Pager of custom attributes for the specified group.GitLab Endpoint: GET /groups/:id/custom_attributes
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instanceitemsPerPage
- the number of items per page- Returns:
- a Pager of group's custom attributes
- Throws:
GitLabApiException
- if any exception occurs
-
getCustomAttributesStream
public java.util.stream.Stream<org.gitlab4j.api.models.CustomAttribute> getCustomAttributesStream(java.lang.Object groupIdOrPath) throws GitLabApiException
Get a Stream of all custom attributes for the specified group.GitLab Endpoint: GET /groups/:id/custom_attributes
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instance- Returns:
- a Stream of group's custom attributes
- Throws:
GitLabApiException
- if any exception occurs
-
getCustomAttribute
public org.gitlab4j.api.models.CustomAttribute getCustomAttribute(java.lang.Object groupIdOrPath, java.lang.String key) throws GitLabApiException
Get a single custom attribute for the specified group.GitLab Endpoint: GET /groups/:id/custom_attributes/:key
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instancekey
- the key for the custom attribute- Returns:
- a CustomAttribute instance for the specified key
- Throws:
GitLabApiException
- if any exception occurs
-
geOptionalCustomAttribute
@Deprecated public java.util.Optional<org.gitlab4j.api.models.CustomAttribute> geOptionalCustomAttribute(java.lang.Object groupIdOrPath, java.lang.String key)
Deprecated.usegetOptionalCustomAttribute(Object, String)
insteadGet an Optional instance with the value for a single custom attribute for the specified group.GitLab Endpoint: GET /groups/:id/custom_attributes/:key
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instance, requiredkey
- the key for the custom attribute, required- Returns:
- an Optional instance with the value for a single custom attribute for the specified group
-
getOptionalCustomAttribute
public java.util.Optional<org.gitlab4j.api.models.CustomAttribute> getOptionalCustomAttribute(java.lang.Object groupIdOrPath, java.lang.String key)
Get an Optional instance with the value for a single custom attribute for the specified group.GitLab Endpoint: GET /groups/:id/custom_attributes/:key
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instance, requiredkey
- the key for the custom attribute, required- Returns:
- an Optional instance with the value for a single custom attribute for the specified group
-
setCustomAttribute
public org.gitlab4j.api.models.CustomAttribute setCustomAttribute(java.lang.Object groupIdOrPath, java.lang.String key, java.lang.String value) throws GitLabApiException
Set a custom attribute for the specified group. The attribute will be updated if it already exists, or newly created otherwise.GitLab Endpoint: PUT /groups/:id/custom_attributes/:key
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instancekey
- the key for the custom attributevalue
- the value for the customAttribute- Returns:
- a CustomAttribute instance for the updated or created custom attribute
- Throws:
GitLabApiException
- if any exception occurs
-
deleteCustomAttribute
public void deleteCustomAttribute(java.lang.Object groupIdOrPath, java.lang.String key) throws GitLabApiException
Delete a custom attribute for the specified group.GitLab Endpoint: DELETE /groups/:id/custom_attributes/:key
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instancekey
- the key of the custom attribute to delete- Throws:
GitLabApiException
- if any exception occurs
-
listGroupIterations
public java.util.List<org.gitlab4j.api.models.Iteration> listGroupIterations(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.IterationFilter filter) throws GitLabApiException
Lists group iterations.GitLab Endpoint: GET /groups/:id/iterations
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instancefilter
- the iteration filter- Returns:
- the list of group iterations
- Throws:
GitLabApiException
- if any exception occurs
-
getGroupAccessTokens
public java.util.List<org.gitlab4j.api.models.GroupAccessToken> getGroupAccessTokens(java.lang.Object groupIdOrPath) throws GitLabApiException
Get a list of group access tokens.GitLab Endpoint: GET /groups/:id/access_tokens
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instance- Returns:
- the list of GroupAccessToken instances
- Throws:
GitLabApiException
- if any exception occurs
-
getGroupAccessToken
public org.gitlab4j.api.models.GroupAccessToken getGroupAccessToken(java.lang.Object groupIdOrPath, java.lang.Long tokenId) throws GitLabApiException
Get a group access token by ID.GitLab Endpoint: GET /groups/:id/access_tokens/:token_id
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instancetokenId
- ID of the group access token- Returns:
- the GroupAccessToken instance
- Throws:
GitLabApiException
- if any exception occurs
-
createGroupAccessToken
@Deprecated public org.gitlab4j.api.models.GroupAccessToken createGroupAccessToken(java.lang.Object groupIdOrPath, java.lang.String name, java.util.Date expiresAt, org.gitlab4j.api.models.ImpersonationToken.Scope[] scopes, org.gitlab4j.api.models.AccessLevel accessLevel) throws GitLabApiException
Create a group access token. You must have the Owner role for the group to create group access tokens.GitLab Endpoint: POST /groups/:id/access_tokens
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instancename
- the name of the group access token, requiredexpiresAt
- the expiration date of the group access token, optionalscopes
- an array of scopes of the group access tokenaccessLevel
- Access level. Valid values areAccessLevel.GUEST
,AccessLevel.REPORTER
,AccessLevel.DEVELOPER
,AccessLevel.MAINTAINER
, andAccessLevel.OWNER
.- Returns:
- the created GroupAccessToken instance
- Throws:
GitLabApiException
- if any exception occurs
-
createGroupAccessToken
public org.gitlab4j.api.models.GroupAccessToken createGroupAccessToken(java.lang.Object groupIdOrPath, java.lang.String name, java.lang.String description, java.util.Date expiresAt, org.gitlab4j.api.models.ImpersonationToken.Scope[] scopes, org.gitlab4j.api.models.AccessLevel accessLevel) throws GitLabApiException
Create a group access token. You must have the Owner role for the group to create group access tokens.GitLab Endpoint: POST /groups/:id/access_tokens
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instancename
- the name of the group access token, requiredexpiresAt
- the expiration date of the group access token, optionalscopes
- an array of scopes of the group access tokenaccessLevel
- Access level. Valid values areAccessLevel.GUEST
,AccessLevel.REPORTER
,AccessLevel.DEVELOPER
,AccessLevel.MAINTAINER
, andAccessLevel.OWNER
.- Returns:
- the created GroupAccessToken instance
- Throws:
GitLabApiException
- if any exception occurs
-
rotateGroupAccessToken
public org.gitlab4j.api.models.GroupAccessToken rotateGroupAccessToken(java.lang.Object groupIdOrPath, java.lang.Long tokenId) throws GitLabApiException
Rotate a group access token. Revokes the previous token and creates a new token that expires in one week.GitLab Endpoint: POST /groups/:id/access_tokens/:token_id/rotate
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instancetokenId
- ID of the group access token- Returns:
- the updated GroupAccessToken instance
- Throws:
GitLabApiException
- if any exception occurs
-
rotateGroupAccessToken
public org.gitlab4j.api.models.GroupAccessToken rotateGroupAccessToken(java.lang.Object groupIdOrPath, java.lang.Long tokenId, java.util.Date expiresAt) throws GitLabApiException
Rotate a group access token. Revokes the previous token and creates a new token that expires in one week.GitLab Endpoint: POST /groups/:id/access_tokens/:token_id/rotate
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instancetokenId
- ID of the group access tokenexpiresAt
- Expiration date of the access token- Returns:
- the updated GroupAccessToken instance
- Throws:
GitLabApiException
- if any exception occurs
-
revokeGroupAccessToken
public void revokeGroupAccessToken(java.lang.Object groupIdOrPath, java.lang.Long tokenId) throws GitLabApiException
Revoke a group access token.GitLab Endpoint: DELETE /groups/:id/access_tokens/:token_id
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instancetokenId
- ID of the group access token- Throws:
GitLabApiException
- if any exception occurs
-
addWebhook
public org.gitlab4j.api.models.GroupHook addWebhook(java.lang.Object groupIdOrPath, org.gitlab4j.api.models.GroupHookParams groupHookParams) throws GitLabApiException
Add a group hookGitLab Endpoint: POST /groups/:id/hooks
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instancegroupHookParams
- webhook creation options- Throws:
GitLabApiException
- if any exception occurs
-
getUploadFiles
public java.util.List<org.gitlab4j.api.models.UploadedFile> getUploadFiles(java.lang.Object groupIdOrPath) throws GitLabApiException
Get all uploads of the group sorted by created_at in descending order. You must have at least the Maintainer role to use this endpoint.GitLab Endpoint: GET /groups/:id/uploads
- Parameters:
groupIdOrPath
- the group in the form of an Long(ID), String(path), or Group instance, required- Returns:
- list of uploaded files
- Throws:
GitLabApiException
- if any exception occurs
-
-