Manual
CLI
API
Log in Get started free

Connect GitHub

Finishes installing the GitHub App: GitHub sends the browser back with the installation, a code and the state you got from the overview.

Finishes installing the GitHub App: GitHub sends the browser back with the installation, a code and the state you got from the overview.

HTTP
POST /integrations/github/installations

Access: Session token only. API keys get 403 with insufficient_scope.

Role: Organisation owner or admin.

Request body #

JSON.

FieldTypeRequiredDescription
installationIdintegeryesThe id GitHub gives the installation, as sent back to the browser.
codestringyesThe code GitHub sent back to the browser.
statestringyesThe state from installUrl.
JSON
{ "installationId": 12345678, "code": "...", "state": "..." }

Response 200 #

The overview after connecting, as in GitHub overview.

Errors #

StatuserrorWhen
401unauthenticatedThe token is missing or not valid.
403forbiddenYou are not an owner or admin.
503github_not_configuredThe GitHub integration is not set up on this server.
400invalid_statestate is not the one the overview gave you, or was made by someone else.
502github_errorGitHub refused the request. message says why.
429rate_limitedToo many requests, see Rate limiting.

See Errors for the error format.