Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Add API route to list org secrets #26485
Add API route to list org secrets #26485
Changes from 10 commits
a1ac892
3fd8201
ae362b5
8a502a2
b54742d
9f48dfc
bdf18bb
e6c2a01
ab59235
473b027
5dc1f25
ff80b03
dba1714
d72bcee
50ce300
f5e05f8
26beefd
3e162be
1a829f8
f15ad0e
4c7efe4
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Erm… User secrets exist too already.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That and we were not sure if we keep them action-only.
I think it is better to omit the
actions/
part from the URL.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Or do you explicitly only want to return the action secrets here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just following the spec: https://docs.github.com/en/rest/actions/secrets?apiVersion=2022-11-28#list-organization-secrets
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So, what do we do in this case?
Deviate from the GitHub standard?
Add extra routes, and mark this one as deprecated with a comment
only for compatibility with the GitHub API
?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm sorry if my previous response was unclear. Please provide more details or elaborate on what you want me to explain. Thank you.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/orgs/{org}/secrets
//users/{user}/secrets
insteadThat leaves the question what to do with the missing URL.
I suggest adding three routes in this PR: The two mentioned above, and the one you already implemented.
However, as the third should only be used by existing scripts and nothing else, I recommend marking this route as
// deprecated: true
with a comment that it is only intended for GitHub API compatibility and that our routes are the other two above instead.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As I said in #24200 (comment) , we can provide other API routes for more purposes but share the data table.
So LGTM.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.