List the Git Sync installations for a site and its spaces

get
Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Path parameters
organizationIdstringRequired

A unique entity identifier

Pattern: ^[a-zA-Z0-9_-]+$
siteIdstringRequired

The unique id of the site

Responses
200

Git Sync installations for the site and its spaces

application/json
get/orgs/{organizationId}/sites/{siteId}/spaces/git/installations
GET /v1/orgs/{organizationId}/sites/{siteId}/spaces/git/installations HTTP/1.1
Host: api.gitbook.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "items": [
    {
      "projectDirectory": "text",
      "commitMessageTemplate": "text",
      "previewExternalBranches": true,
      "agentInstructions": [
        "agents"
      ],
      "priority": "git",
      "provider": "github",
      "providerConfiguration": {
        "repositoryId": 1,
        "branch": "text"
      }
    },
    {
      "object": "git-sync-installation",
      "id": "text",
      "parentInstallationId": "text",
      "target": {
        "type": "space",
        "spaceId": "text",
        "siteId": "text"
      },
      "status": "unauthenticated",
      "repositoryConnection": {
        "object": "git-repository-connection",
        "id": "text",
        "provider": "github",
        "repositoryId": "text",
        "repositoryName": "text",
        "repositoryUrl": "https://example.com",
        "defaultBranch": "text",
        "authState": "pending",
        "capabilities": {
          "pullRequests": true,
          "commitStatuses": true
        },
        "createdAt": "2026-01-01T00:00:00.000Z",
        "updatedAt": "2026-01-01T00:00:00.000Z"
      },
      "repositoryRef": {
        "object": "git-repository-ref",
        "id": "text",
        "name": "text",
        "type": "branch",
        "latestObservedCommitId": "text",
        "latestImportedCommitId": "text",
        "updatedAt": "2026-01-01T00:00:00.000Z"
      },
      "syncRoot": {
        "object": "git-sync-root",
        "id": "text",
        "installationId": "text",
        "target": {
          "type": "space",
          "spaceId": "text",
          "siteId": "text"
        },
        "defaultMergeAuthorityPolicy": "provider",
        "status": "active",
        "createdAt": "2026-01-01T00:00:00.000Z",
        "updatedAt": "2026-01-01T00:00:00.000Z"
      },
      "createdAt": "2026-01-01T00:00:00.000Z",
      "createdBy": "text",
      "authorizedBy": "text",
      "updatedAt": "2026-01-01T00:00:00.000Z",
      "urls": {
        "location": "https://example.com"
      }
    }
  ]
}

Last updated

Was this helpful?

Powered by GitBook