git.repositories.updateChange description, visibility, default branch or archive state
Request syntax
PATCH /git/api/repositories/{repoId}
{
"description": "string",
"homepage": "string",
"topics": "array of string",
"visibility": "enum",
"defaultBranch": "string",
"isArchived": "boolean",
"allowMergeCommit": "boolean",
"allowSquashMerge": "boolean",
"allowRebaseMerge": "boolean",
"deleteBranchOnMerge": "boolean",
"defaultWorkflowPermissions": "enum"
}Path parameters
repoIdRequiredstring
Constraints: uuid
Request body
descriptionOptionalstring
One line about the repository, shown in lists and the About column
Constraints: max 500 chars
homepageOptionalstring
The About link (http or https); null removes it
Constraints: url, max 300 chars
May be null.
topicsOptionalarray of string
Topics: lowercase letters, digits and hyphens, at most 20
Constraints: /^[a-z0-9][a-z0-9-]{0,49}$/
visibilityOptionalenum
Who can see it; making it public also needs git:PublishRepository
One of:
private,internal,publicdefaultBranchOptionalstring
The branch clones check out and pull requests target by default
Constraints: 1-100 chars
isArchivedOptionalboolean
true archives it (read-only: pushes, merges and edits refused); false unarchives
allowMergeCommitOptionalboolean
Pull requests may merge with a merge commit
allowSquashMergeOptionalboolean
Pull requests may be squash-merged
allowRebaseMergeOptionalboolean
Pull requests may be rebase-merged
deleteBranchOnMergeOptionalboolean
Delete the source branch when a pull request is merged
defaultWorkflowPermissionsOptionalenum
What a workflow job's GITHUB_TOKEN may do when its file sets no `permissions:`: restricted (contents and packages read; new repositories) or permissive (read and write)
One of:
restricted,permissive
Response
200 with the repository after the change (its `cloneUrl` is null in this answer). 400 when the change would leave no merge method allowed.
A JSON response is wrapped as { "success": true, "data": … }; the CLI prints the whole body with --json.
Fields of data
idAlwaysstring
The repository idorgIdAlwaysstring
The organization it belongs tonameAlwaysstring
Its name, unique in the organization and part of the clone URLdescriptionAlwaysstring, may be null
One line about it; null when nonehomepageAlwaysstring, may be null
The About link; null when nonetopicsAlwaysarray of string
Its topicsvisibilityAlwaysone of private, internal, public
Who can see itdefaultBranchAlwaysstring
The branch clones check out and pull requests target by defaultisEmptyAlwaysboolean
Nothing has been pushed yetisArchivedAlwaysboolean
Read-only: pushes, merges and edits are refusedallowMergeCommitAlwaysboolean
Pull requests may merge with a merge commitallowSquashMergeAlwaysboolean
Pull requests may be squash-mergedallowRebaseMergeAlwaysboolean
Pull requests may be rebase-mergeddeleteBranchOnMergeAlwaysboolean
A merged pull request's source branch is deletedsizeBytesAlwaysnumber
Stored size in bytes, what storage is billed onrefsVersionAlwaysnumber
A counter that grows each time a branch or tag moveslastPushedAtAlwaysstring, may be null
When the last push landed (ISO 8601); null before the firstimportStateAlwaysobject, may be null
The import or fork copy that filled the repository; null for one created emptyimportState.statusAlwaysone of queued, running, succeeded, failed
Where the import standsimportState.providerAlwaysone of github, gitlab, git
Where it comes from: GitHub, GitLab, or any git URLimportState.sourceUrlAlwaysstring
The source as given, without credentialsimportState.includeAlwaysobject
What was asked for besides the git historyimportState.include.pullRequestsAlwaysboolean
Pull requests are brought overimportState.include.wikiAlwaysboolean
The wiki is brought over as repository {name}.wikiimportState.include.pullRequestLimitWhen presentnumber
At most this many pull requests, newest firstimportState.pullsWhen presentobject
The pull requests' progress; absent until the import reaches themimportState.pulls.totalAlwaysnumber, may be null
Pull requests the source has, in all states; null when it does not sayimportState.pulls.importedAlwaysnumber
Pull requests imported so farimportState.pulls.limitAlwaysnumber
At most this many are importedimportState.pulls.backfillAlwaysone of running, done, failed
The background import of the older closed pull requestsimportState.pulls.nextClosedPageAlwaysnumber, may be null
The page of the source's closed pull requests read next; null when doneimportState.pulls.errorAlwaysstring, may be null
Why the background import failed; null if notimportState.importerIamUserIdAlwaysstring, may be null
The IAM user who started it; imported pull requests are written as themimportState.startedAtAlwaysstring, may be null
When it started (ISO 8601); null while queuedimportState.finishedAtAlwaysstring, may be null
When it ended (ISO 8601); null until thenimportState.errorAlwaysstring, may be null
Why it failed; null unless it didimportState.importedAlwaysobject, may be null
What came over; null until the import finishedimportState.imported.branchesAlwaysnumber
Branches brought overimportState.imported.tagsAlwaysnumber
Tags brought overimportState.imported.pullRequestsAlwaysnumber
Pull requests brought overimportState.imported.wikiRepositoryIdAlwaysstring, may be null
The wiki repository created; null without a wikiimportState.imported.notesAlwaysarray of string
Remarks on what could not be carried over as ismirrorAlwaysobject, may be null
Set while it mirrors a source (pushes refused); null for an ordinary repositorymirror.providerAlwaysone of github, gitlab, git
Where it comes from: GitHub, GitLab, or any git URLmirror.sourceUrlAlwaysstring
The source followed, without credentialsmirror.intervalMinutesAlwaysnumber
Minutes between full fetchesmirror.lastSyncedAtAlwaysstring, may be null
When the last sync finished (ISO 8601); null before the firstmirror.lastErrorAlwaysstring, may be null
Why the last sync failed; null when it did notmirror.pullsUpdatedThroughWhen presentstring
Pull requests changed on the source up to this time (ISO 8601) are inmirror.pullsUpdatedAtCorrectedAtWhen presentstring
When the imported pull requests' update times were taken from the sourcemirror.mergeMethodsReadAtWhen presentstring
When the source's merge methods were last applied here (ISO 8601)mirror.continuousWhen presentboolean
The source is checked every minute and fetched as soon as a ref movedmirror.shadowCiWhen presentobject
Running the source's workflows here to compare; absent when never setmirror.shadowCi.enabledAlwaysboolean
Shadow CI runs on mirrored pushesmirror.shadowCi.branchesAlwaysarray of string
Branch patterns it runs for; the default branch when emptymirror.hasTokenAlwaysboolean
A token for the source is kept (it is never shown)pushMirrorAlwaysobject, may be null
Where every push is copied to; null without a push mirror. The token is never shownpushMirror.urlAlwaysstring
The remote repository pushes are copied topushMirror.lastPushedAtAlwaysstring, may be null
When the last push to it finished (ISO 8601); null before the firstpushMirror.lastStatusAlwaysone of ok, failed, may be null
How the last push went; null before the firstpushMirror.lastErrorAlwaysstring, may be null
Why the last push failed; null when it did notpushMirror.rejectedRefsAlwaysarray of string
Refs the remote refused in the last push because they moved there on their ownforkedFromRepoIdAlwaysstring, may be null
The repository it was forked from; null for an original or a deleted parentsecretPushProtectionAlwaysboolean
Pushes that add a known credential format are refuseddependencyAlertsAlwaysboolean
Lockfiles on the default branch are checked against the vulnerability databasemaxFileSizeMbAlwaysnumber, may be null
Largest file a push may add, in MB; null for the platform default of 100defaultWorkflowPermissionsAlwaysone of restricted, permissive
What a workflow job's token may do when its file sets no `permissions:`createdAtAlwaysstring
When it was created (ISO 8601)updatedAtAlwaysstring
When its settings last changed (ISO 8601)cloneUrlAlwaysstring, may be null
The HTTPS clone URL; null in the answer to `update`
Checked against the handlers: every route test validates their answers against this schema.
Errors
- 400The request does not pass the schema above. The body is { "error": …, "issues": […] }, one issue per field.
- 401No credentials, or an access key that is unknown, revoked or expired.
- 403The caller's policies do not allow git:UpdateRepository on this resource. The body names the action and the resource, and the refusal is recorded in the audit log.
- 404The resource does not exist in your organization.
Examples
The required parameters only, with example values. Replace id and the other placeholders with your own.
dcloud git repositories update repoIdcurl -X PATCH "https://console.platform-development.deutschecloud.app/git/api/repositories/repoId" \
-H "Authorization: EWS-ACCESS-KEY $ACCESS_KEY" \
-H "Content-Type: application/json" \
-d '{}'Generated from the API description, the same one the API checks requests against and the CLI is built from. MCP tool: dcloud_git_repositories_update.