Skip to content
GitmoapAPIBeta
Knowledgewiki
PATCH/groups/{group_id}/wiki

Enable, disable, or repoint a group's wiki

update_group_wiki
  • wiki:manage
    A token needs the wiki:manage scope: Enable or disable a wiki and change where it reads fromGranted by write_api.Every operation this scope unlocks
  • Audited · mutation

    x-gitmoap-audit: {"kind":"audited","arg":"mutation"}

The first call creates the wiki; settings you leave out take their defaults — enabled, with home as the home page. Later calls change only the fields you send. A group's wiki always keeps its pages in its own repository: a group has no default branch to read them from, so that source is refused. Maintainers and above.

Parameters

Path
  • group_idGroupId (string · uuid)Group ID

Request body

application/json
  • default_pageWikiPagePath (string) or nulloptional
  • enabledboolean or nulloptional
  • sourceWikiSourcededicatedin_repoor nulloptionalWhere a wiki's pages come from.
  • source_pathRepoPath (string) or nulloptional
Request body exampleSynthesized example
{}

Responses

200The wiki as storedapplication/json
  • created_atstring
  • default_pageWikiPagePath (string)The page served at the wiki's root.
  • enabledbooleanWhether the wiki is on. A disabled wiki is `false` here, never a `404`: whether a wiki exists is not a secret, and only its contents are.
  • page_countinteger · int32How many pages the wiki has.
  • scope_idstring
  • scope_typeScopeTypegrouprepository
  • sourceWikiSourcededicatedin_repoWhere a wiki's pages come from.
  • updated_atstring
  • wiki_idWikiId (string · uuid)
  • clone_urlstring or nulloptionalWhere this wiki can be cloned from. Absent when the wiki has no clone URL of its own, as for a wiki that reads its pages from a repository.
  • created_byActorSummary or nulloptional
  • head_shaCommitHash (string) or nulloptionalThe commit the index was last built from. Absent until the first sync.
  • indexed_atstring or nulloptional
  • source_pathRepoPath (string) or nulloptionalThe directory a in_repo wiki reads from. Absent for a dedicated one.
200 exampleSynthesized example
{
"created_at": "2026-10-11T21:19:15Z",
"default_page": "default-page-7329",
"enabled": true,
"page_count": 5,
"scope_id": "1aa0c2e9-ea54-4902-86a7-1b1610b6f028",
"scope_type": "group",
"source": "dedicated",
"updated_at": "2026-10-15T15:53:40Z",
"wiki_id": "eeffbb21-e2d1-4649-976e-d930137dcff9",
"clone_url": "https://gitmoap.example/acme/5c7b4b6e",
"created_by": {
"email": "lin@acme.example",
"id": "id-3002",
"username": "mara",
"avatar_url": "https://gitmoap.example/acme/0d389f68"
},
"head_sha": "b9cf4f40de25a478198b19dd690754d61ecd8927",
"indexed_at": "2026-10-10T05:55:27Z",
"source_path": "source-path-55f5"
}
400An in-repo wiki must name the directory it reads fromapplication/json
Error codes
  • BAD_REQUESTThe request is malformed: a parameter or a body field is not a well-formed value of its type
  • errorErrorBody
    • The ErrorBody schema
    • codestringThe coarse category, tied to the status: NOT_FOUND, CONFLICT, INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all.
    • messagestringWhat went wrong, for a person. Written to be read, not parsed: match on reason or code.
    • fieldstring or nulloptionalOn a 400 that refused one field's value, the field, as its JSON path: email, items[0].name. Put the message under that input. Absent on every other error.
    • reasonstring or nulloptionalThe specific code, when the error has one: LAST_ORGANIZATION_OWNER, BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and on code otherwise.
    • required_scopestring or nulloptionalThe scope the access token was missing, on INSUFFICIENT_SCOPE.
    • violationsanyoptionalPresent on the structured-validation errors (PROVIDER_VALIDATION_FAILED per-node, PIPELINE_VALIDATION_FAILED DAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
400 exampleSynthesized example
{
"error": {
"code": "code-3c2e",
"message": "Inline scalar newtypes but keep their brand"
}
}
401Unauthenticated — no credential, or an invalid oneapplication/json
Error codes
  • UNAUTHORIZEDNo credential was sent, or the one sent is invalid, expired or revoked
  • errorErrorBody
    • The ErrorBody schema
    • codestringThe coarse category, tied to the status: NOT_FOUND, CONFLICT, INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all.
    • messagestringWhat went wrong, for a person. Written to be read, not parsed: match on reason or code.
    • fieldstring or nulloptionalOn a 400 that refused one field's value, the field, as its JSON path: email, items[0].name. Put the message under that input. Absent on every other error.
    • reasonstring or nulloptionalThe specific code, when the error has one: LAST_ORGANIZATION_OWNER, BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and on code otherwise.
    • required_scopestring or nulloptionalThe scope the access token was missing, on INSUFFICIENT_SCOPE.
    • violationsanyoptionalPresent on the structured-validation errors (PROVIDER_VALIDATION_FAILED per-node, PIPELINE_VALIDATION_FAILED DAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
401 exampleSynthesized example
{
"error": {
"code": "code-e0d9",
"message": "Label every synthesized example"
}
}
403Maintainer is required to change a wiki's settingsapplication/json
Error codes
  • FORBIDDENYou are signed in but may not do this here; reason names the permission or the rule that refused it
  • INSUFFICIENT_SCOPEThe access token lacks the scope this operation needs; required_scope names it
  • PERMISSION_REQUIREDYou need a permission you do not hold here; the message names it
  • errorErrorBody
    • The ErrorBody schema
    • codestringThe coarse category, tied to the status: NOT_FOUND, CONFLICT, INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all.
    • messagestringWhat went wrong, for a person. Written to be read, not parsed: match on reason or code.
    • fieldstring or nulloptionalOn a 400 that refused one field's value, the field, as its JSON path: email, items[0].name. Put the message under that input. Absent on every other error.
    • reasonstring or nulloptionalThe specific code, when the error has one: LAST_ORGANIZATION_OWNER, BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and on code otherwise.
    • required_scopestring or nulloptionalThe scope the access token was missing, on INSUFFICIENT_SCOPE.
    • violationsanyoptionalPresent on the structured-validation errors (PROVIDER_VALIDATION_FAILED per-node, PIPELINE_VALIDATION_FAILED DAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
403 exampleSynthesized example
{
"error": {
"code": "code-ea92",
"message": "Stream pipeline status into the run header"
}
}
404No such scope, or it is not visible to the callerapplication/json
Error codes
  • NOT_FOUNDThe resource does not exist — or exists and you cannot see it: a private resource you have no access to answers exactly as an absent one does
  • errorErrorBody
    • The ErrorBody schema
    • codestringThe coarse category, tied to the status: NOT_FOUND, CONFLICT, INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all.
    • messagestringWhat went wrong, for a person. Written to be read, not parsed: match on reason or code.
    • fieldstring or nulloptionalOn a 400 that refused one field's value, the field, as its JSON path: email, items[0].name. Put the message under that input. Absent on every other error.
    • reasonstring or nulloptionalThe specific code, when the error has one: LAST_ORGANIZATION_OWNER, BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and on code otherwise.
    • required_scopestring or nulloptionalThe scope the access token was missing, on INSUFFICIENT_SCOPE.
    • violationsanyoptionalPresent on the structured-validation errors (PROVIDER_VALIDATION_FAILED per-node, PIPELINE_VALIDATION_FAILED DAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
404 exampleSynthesized example
{
"error": {
"code": "code-baa9",
"message": "Stream pipeline status into the run header"
}
}
409The request conflicts with the resource's current state; `reason` says howapplication/json
Error codes
  • CONFLICTThe request conflicts with the resource's current state; reason says how
  • LEGAL_ACCEPTANCE_REQUIREDAccept the current Terms of Service before changing anything; reading stays open
  • errorErrorBody
    • The ErrorBody schema
    • codestringThe coarse category, tied to the status: NOT_FOUND, CONFLICT, INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all.
    • messagestringWhat went wrong, for a person. Written to be read, not parsed: match on reason or code.
    • fieldstring or nulloptionalOn a 400 that refused one field's value, the field, as its JSON path: email, items[0].name. Put the message under that input. Absent on every other error.
    • reasonstring or nulloptionalThe specific code, when the error has one: LAST_ORGANIZATION_OWNER, BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and on code otherwise.
    • required_scopestring or nulloptionalThe scope the access token was missing, on INSUFFICIENT_SCOPE.
    • violationsanyoptionalPresent on the structured-validation errors (PROVIDER_VALIDATION_FAILED per-node, PIPELINE_VALIDATION_FAILED DAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
409 exampleSynthesized example
{
"error": {
"code": "code-fbca",
"message": "Inline scalar newtypes but keep their brand"
}
}

CLI

gitmoap wiki update-group-wiki

  • --group-ididGroup ID (id or group path)
  • --default-pagestringoptional
  • --enabledflagoptional
  • --sourcededicated | in_repooptional
  • --source-pathstringoptional