public interface AutoMergeSettingsService
| Modifier and Type | Field and Description |
|---|---|
static boolean |
AUTO_MERGE_GLOBAL_ENABLED
Whether auto-merge is globally enabled.
|
| Modifier and Type | Method and Description |
|---|---|
void |
delete(Scope scope)
Deletes the pull request auto-merge settings associated with a particular
scope. |
AutoMergeSettings |
getOrDefault(Scope scope)
Retrieves the pull request auto-merge settings for a particular
scope. |
AutoMergeSettings |
set(AutoMergeSettingsCreateRequest request)
Creates or updates the pull request auto-merge settings for a particular
repository scope
or project scope. |
static final boolean AUTO_MERGE_GLOBAL_ENABLED
void delete(@Nonnull Scope scope)
scope.scope - a repository scope or project scopeAuthorisationException - when the currently authenticated user does not have at least admin permission
for the provided scope, e.g. Permission.REPO_ADMIN for a
RepositoryScope or Permission.PROJECT_ADMIN for a
ProjectScopeArgumentValidationException - if the provided scope is global scopeForbiddenException - if the repository's project has restricted its auto-merge settings@Nonnull AutoMergeSettings getOrDefault(@Nonnull Scope scope)
scope. If no settings are found,
inherited settings are returned if they exist. Otherwise, global pull request auto-merge
settings are returned.
If the provided scope is a repository scope and the repository's project has restricted
its auto-merge settings, then the project's auto-merge settings will be returned.scope - a repository scope or project scopeAuthorisationException - when the currently authenticated user does not have at least read permission
for the provided scope, e.g. Permission.REPO_READ for a
RepositoryScope or Permission.PROJECT_VIEW for a
ProjectScope@Nonnull AutoMergeSettings set(@Nonnull AutoMergeSettingsCreateRequest request)
repository scope
or project scope.request - the request containing the pull request auto-merge settingsAuthorisationException - when the currently authenticated user does not have at least admin permission
for the provided scope, e.g. Permission.REPO_ADMIN for a
RepositoryScope or Permission.PROJECT_ADMIN for a
ProjectScopeForbiddenException - if the repository's project has restricted its auto-merge settingsCopyright © 2023 Atlassian. All rights reserved.