Skip to content

[FEAT]: Expose permissions, events, client_id and external_url on the github_app data source #3722

Open

Description

@vibbix

Describe the need

Describe the need

The github_app data source only exposes id, name, description, node_id and slug. GET /apps/{app_slug} also returns the app's permissions, events, client_id and external_url, and go-github already decodes all four onto github.App, but the provider drops them.

We register our GitHub Apps from manifests kept in our infrastructure repo, because GitHub has no API to create or edit an app. Since the October 2026 change, an installation token can read private apps in the same org, so a check against data.github_app would catch an app whose permissions or events drifted from its manifest. Right now name and description are all we can compare.

data "github_app" "this" {
  slug = "my-app"
}

check "permissions_match_manifest" {
  assert {
    condition     = data.github_app.this.permissions == tomap(local.manifest.default_permissions)
    error_message = "my-app's permissions no longer match its manifest."
  }
}

client_id is also what actions/create-github-app-token asks for now, which is #3395.

While adding permissions I noticed that flattenInstallationPermissions, which github_organization_app_installations uses, only copies 30 of the 88 fields on github.InstallationPermissions. Permissions outside that list, such as organization_administration, members and organization_custom_roles, never show up in that data source's permissions map. I'd fix it in the same change by round-tripping the struct through JSON, so every permission go-github knows about comes through.

I have a branch with both changes, tests and regenerated docs, and can open the PR.

GitHub Installation Type

  • GitHub.com (Free, Pro, or Team)
  • GitHub Enterprise Server (on-premises)
  • GitHub Enterprise Cloud with Personal Accounts (github.com)
  • GitHub Enterprise Cloud with Managed Users/EMU (github.com)
  • GitHub Enterprise Cloud with Data Residency (*.ghe.com)
  • I don't know

Relevant log output

Code of Conduct

  • I agree to follow this project's Code of Conduct

Activity

  1. added
    Type: Feature
    Status: Triage
    on Nov 6, 2026
  2. github-actions commented on Nov 6, 2026

    @github-actions

    👋 Hi, and thank you for opening this issue!

    This repo is maintained by GitHub and community members on a best-effort basis. We'll get to this as soon as we can.

    You can help us prioritize by adding details, reproduction steps, or a 👍 to issues that matter to you, and by joining the discussion on open issues and PRs.


    🤖 This is an automated message.

  3. robert-crandall commented on Nov 25, 2026

    @robert-crandall
    Contributor

    Linking #3721 from @vibbix here for reference. We closed it as part of our temporary move to an issue-first model (see CONTRIBUTING.md), and want to keep the context and implementation approach handy when we pick this issue up.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Status: TriageType: Feature

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions