Lists the GitHub accounts the caller may see the App installed on, each…
Lists the GitHub accounts the caller may see the App installed on, each confirmed against the App's own list, plus where to add another.
GET /v1/integrations/github/installations
| Address | https://api.hanzo.ai/v1/integrations/github/installations |
| Method | GET |
| Operation | get_integrations_github_installations |
| Auth | Authorization: Bearer $HANZO_API_KEY |
Lists the GitHub accounts the caller may see the App installed on, each confirmed against the App's own list, plus where to add another.
The confirmation is the point. A connection row holds an installation id, and an id whose installation was since removed on GitHub is a row that mints nothing — every list and import against it fails with a token error, which reads as "our git integration is broken" rather than "that install is gone". Checking the App's view turns that into a fact the caller can act on.
ORG-SCOPED for a tenant, deliberately. The App is installed across every customer, so the raw list is the customer list; a tenant sees only accounts its own org has bound. It discovers a NEW account by installing it (InstallURL), which is GitHub's own consent screen — not by reading ours.
A SUPER ADMIN sees the App's whole install list, because that list is the platform's own inventory rather than any one tenant's data, and platform sudo is the single cross-tenant scope this house has. Without it an App installed out-of-band — granted straight from GitHub, so no connect flow ever ran and no connection row exists — is invisible to everyone: the console card reads "not connected" and an operator asked "which GitHub orgs do you see" can only answer for accounts already bound, which is precisely the accounts that were never the question.
Request
GET /v1/integrations/github/installations takes no parameters and no body — the credential is the whole request.
Response
| Status | Body | Meaning |
|---|---|---|
200 | githubInstallationsOut | ok |
200 body — 7 fields.
| Field | In | Type | Always | Description |
|---|---|---|---|---|
installUrl | body | string | — | InstallURL is where to grant a new account, so a UI with an empty list has somewhere to send the reader instead of a dead end. |
installations | body | githubInstallationView[] | — | Installations is every account the caller may see: the ones its own org has bound, or — for a super admin — every account the App is installed on. |
installations[].connected | body | boolean | — | Connected reports whether THIS org has already bound this account. |
installations[].grant | body | string | — | Grant is "all" or "selected" — how many of the account's repositories the install covers. |
installations[].htmlUrl | body | string | — | HTMLURL is the account's page on GitHub. |
installations[].login | body | string | — | Login is the GitHub account name — the org or user the App is installed on. |
installations[].type | body | string | — | Type is "Organization" or "User". |
Failure carries the platform error shape — see Errors.
Examples
hanzo integrations github installationsimport { Configuration, IntegrationsApi } from 'hanzoai';
const api = new IntegrationsApi(new Configuration({ accessToken: process.env.HANZO_API_KEY }));
const { data } = await api.getIntegrationsGithubInstallations();from hanzoai.cloud import ApiClient, Configuration
from hanzoai.cloud.api import IntegrationsApi
client = ApiClient(Configuration(access_token=os.environ["HANZO_API_KEY"]))
result = IntegrationsApi(client).get_integrations_github_installations()cfg := cloud.NewConfiguration()
cfg.AddDefaultHeader("Authorization", "Bearer "+os.Getenv("HANZO_API_KEY"))
client := cloud.NewAPIClient(cfg)
resp, _, err := client.IntegrationsAPI.GetIntegrationsGithubInstallations(context.Background()).Execute()
if err != nil {
return err
}use hanzo_cloud::apis::{configuration::Configuration, integrations_api};
let mut cfg = Configuration::new();
cfg.bearer_access_token = std::env::var("HANZO_API_KEY").ok();
let result = integrations_api::get_integrations_github_installations(&cfg, Default::default()).await?;import ai.hanzo.cloud.ApiClient;
import ai.hanzo.cloud.api.IntegrationsApi;
ApiClient client = new ApiClient();
client.setRequestInterceptor(b -> b.header("Authorization", "Bearer " + System.getenv("HANZO_API_KEY")));
var result = new IntegrationsApi(client).getIntegrationsGithubInstallations();curl https://api.hanzo.ai/v1/integrations/github/installations \
-H "Authorization: Bearer $HANZO_API_KEY"The door reaches integrations through the integrations tool, which names its 45 operations with its own verbs — this one among them, under a name only the door declares. describe explains any of them:
curl -X POST https://api.hanzo.ai/v1/mcp \
-H "Content-Type: application/json" \
-d '{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "describe",
"arguments": {
"op": "list_connectors"
}
}
}'How is this guide?