Skip to content

feat: add support for 10 new APIs and drop enterprise-level SCIM APIs which are only in GitHub Enterprise Server #471

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 6 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 23 additions & 9 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
},
"description": "Shared TypeScript definitions for Octokit projects",
"dependencies": {
"@octokit/openapi-types": "^13.11.0"
"@octokit/openapi-types-ghec": "^14.0.0"
Copy link
Contributor

Choose a reason for hiding this comment

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

sorry my comment was about this change

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@gr2m Thanks for jumping in! Just to be clear, are you proposing that types.ts would be basic non-GHEC types only, and then you would use plugin-enterprise-cloud.js for GHEC-exclusive APIs? That is definitely an option.

Copy link
Contributor

Choose a reason for hiding this comment

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

},
"scripts": {
"build": "pika-pack build",
Expand Down Expand Up @@ -96,6 +96,6 @@
]
},
"octokit": {
"openapi-version": "7.13.0"
"openapi-version": "8.0.0"
}
}
17 changes: 14 additions & 3 deletions scripts/update-endpoints/fetch-json.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,14 @@ const QUERY = `

main();

const removeEnterpriseCloudFromDocumentationUrl = (endpoint) => ({
...endpoint,
documentationUrl: endpoint.documentationUrl.replace(
"/enterprise-cloud@latest/",
""
),
});

async function main() {
const {
data: { endpoints },
Expand All @@ -43,8 +51,11 @@ async function main() {

writeFileSync(
path.resolve(__dirname, "generated", "endpoints.json"),
prettier.format(JSON.stringify(endpoints), {
parser: "json",
})
prettier.format(
JSON.stringify(endpoints.map(removeEnterpriseCloudFromDocumentationUrl)),
{
parser: "json",
}
)
);
}
Loading