Skip to content

feat: Add support for Enterprise GitHub App Installation APIs - #3830

Merged
gmlewis merged 10 commits into
google:masterfrom
Not-Dhananjay-Mishra:issue-3829-part-1
Nov 18, 2025
Merged

feat: Add support for Enterprise GitHub App Installation APIs#3830
gmlewis merged 10 commits into
google:masterfrom
Not-Dhananjay-Mishra:issue-3829-part-1

Conversation

@Not-Dhananjay-Mishra

@Not-Dhananjay-MishraNot-Dhananjay-Mishra commented Nov 15, 2025

Copy link
Copy Markdown
Contributor

Relates-to: #3829

This PR add support for the following API endpoints -

  • GET /enterprises/{enterprise}/apps/installable_organizations
  • GET /enterprises/{enterprise}/apps/installable_organizations/{org}/accessible_repositories
  • GET /enterprises/{enterprise}/apps/organizations/{org}/installations
  • POST /enterprises/{enterprise}/apps/organizations/{org}/installations
  • DELETE /enterprises/{enterprise}/apps/organizations/{org}/installations/{installation_id}

REST API endpoints for Github App Installation

@codecov

codecovBot commented Nov 15, 2025

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 92.41%. Comparing base (148abf3) to head (884c2d1).
⚠️ Report is 5 commits behind head on master.

Additional details and impacted files
@@ Coverage Diff @@## master #3830 +/- ##
==========================================
+ Coverage 92.38% 92.41% +0.03% 
==========================================
Files 196 197 +1 Lines 14094 14152 +58 ==========================================
+ Hits 13021 13079 +58 
Misses 884 884 Partials 189 189 

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@gmlewisgmlewis changed the title feat: Add Support for Few Enterprise GitHub App Installation APIsfeat: Add support for Enterprise GitHub App Installation APIsNov 15, 2025

@gmlewisgmlewis left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you, @Not-Dhananjay-Mishra!
LGTM.
Awaiting second LGTM+Approval from any other contributor to this repo before merging.

cc: @stevehipwell - @alexandear - @zyfy29

@gmlewisgmlewis added the NeedsReview PR is awaiting a review before merging. label Nov 15, 2025
Comment threadgithub/enterprise_app_installation.go Outdated

@stevehipwellstevehipwell left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've just reviewed the API surface and I think some of the function names need re-working before doing a deeper review.

Comment threadgithub/enterprise_app_installation.go Outdated
Comment threadgithub/enterprise_app_installation.go Outdated
@Not-Dhananjay-Mishra

Not-Dhananjay-Mishra commented Nov 17, 2025

Copy link
Copy Markdown
ContributorAuthor

@stevehipwell Thanks for the suggestions, I have change the name for both -
ListInstallableEnterpriseOrganization -> ListInstallableAppOrganizations
ListOrganizationAccessibleRepositories -> ListOrganizationAppAccessibleRepositories

@stevehipwellstevehipwell left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I still don't think the API is consistent, how about the following changes to make the API consistent by using an App prefix with all unnecessary padding removed?

  • ListInstallableAppOrganizations -> ListAppInstallableOrganizations
  • ListOrganizationAppAccessibleRepositories -> ListAppAccessibleOrganizationRepositories
  • ListAppOrganizationInstallations -> ListAppInstallations
  • InstallEnterpriseOrganizationApp -> InstallApp
  • UninstallEnterpriseOrganizationApp -> UninstallApp

@Not-Dhananjay-Mishra

Copy link
Copy Markdown
ContributorAuthor
* `ListInstallableAppOrganizations` -> `ListAppInstallableOrganizations`
* `ListOrganizationAppAccessibleRepositories` -> `ListAppAccessibleOrganizationRepositories`
* `ListAppOrganizationInstallations` -> `ListAppInstallations`
* `InstallEnterpriseOrganizationApp` -> `InstallApp`
* `UninstallEnterpriseOrganizationApp` -> `UninstallApp`

I have implemented the following changes as requested

Comment threadgithub/enterprise_app_installation.go
Comment threadgithub/enterprise_app_installation.go Outdated
Comment threadgithub/enterprise_app_installation.go Outdated
Comment threadgithub/enterprise_app_installation.go Outdated
@Not-Dhananjay-Mishra

Copy link
Copy Markdown
ContributorAuthor

@alexandear Thanks for all suggestions, I made some changes as requested -

  • added missing field in InstallableOrganization
  • AppInstallationRequest -> InstallAppRequest
  • Repository -> Repositories in InstallAppRequest
  • fix *string and omitempty usage in both struct

@stevehipwellstevehipwell left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My changes have been implemented and I'm happy to approve but I think @alexandear did a more thorough review so his approval would likely carry more weight.

@gmlewis

Copy link
Copy Markdown
Collaborator

Thank you, @stevehipwell and @alexandear!
Merging.

@gmlewisgmlewis removed the NeedsReview PR is awaiting a review before merging. label Nov 18, 2025
@gmlewis
gmlewis merged commit ea7dd81 into google:masterNov 18, 2025
7 checks passed
@Not-Dhananjay-Mishra
Not-Dhananjay-Mishra deleted the issue-3829-part-1 branch February 5, 2026 15:30
jlaportebot added a commit to jlaportebot/go-github that referenced this pull request Jun 28, 2026
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@Not-Dhananjay-Mishra@gmlewis@alexandear@stevehipwell