Movatterモバイル変換


[0]ホーム

URL:


HashiConf 2025Don't miss the live stream of HashiConf Day 2 happening now View live stream

You are viewing documentation for version v202502-2.View latest version.

You can create a GitHub App installation using the HCP Terraform UI. Learn how tocreate a GitHub App installation.

Note: To use this resource in Terraform Enterprise installations, you must configure the GitHub App in the site admin area.

Note: You can only use this API if you have already authorized the Terraform Cloud GitHub App. Manage yourGitHub App token fromAccount Settings >Tokens.

List Installations

This endpoint lists GitHub App installations available to the current user.

GET /github-app/installations

Query Parameters

Queries only return GitHub App Installations that the current user has access to within GitHub.

ParameterDescription
filter[name]Optional. If present, returns a list of available GitHub App installations that match the GitHub organization or login.
filter[installation_id]Optional. If present, returns a list of available GitHub App installations that match the installation ID within GitHub. (Not HCP Terraform)

Sample Request

$ curl \  --header "Authorization: Bearer $TOKEN" \  --header "Content-Type: application/vnd.api+json" \  https://app.terraform.io/api/v2/github-app/installations

Sample Response

{    "data": [        {            "id": "ghain-BYrbNeGQ8nAzKouu",            "type": "github-app-installations",            "attributes": {                "name": "octouser",                "installation-id": 54810170,                "icon-url": "https://avatars.githubusercontent.com/u/29916665?v=4",                "installation-type": "User",                "installation-url": "https://github.com/settings/installations/54810170"            }        }    ]}

Show Installation

GET /github-app/installation/:gh_app_installation_id

ParameterDescription
:gh_app_installation_idThe Github App Installation ID

Sample Request

$ curl \  --header "Authorization: Bearer $TOKEN" \  --header "Content-Type: application/vnd.api+json" \  https://app.terraform.io/api/v2/github-app/installation/ghain-R4xmKTaxnhLFioUq

Sample Response

{    "data": {        "id": "ghain-R4xmKTaxnhLFioUq",        "type": "github-app-installations",        "attributes": {            "name": "octouser",            "installation-id": 54810170,            "icon-url": "https://avatars.githubusercontent.com/u/29916665?v=4",            "installation-type": "User",            "installation-url": "https://github.com/settings/installations/54810170"        }    }}
Edit this page on GitHub

[8]ページ先頭

©2009-2025 Movatter.jp