Github token has no access to new container REST APIs #26268
|
Hello, I just saw the changelog entry which now introduced access for the container registry. However, switching from PAT to the GITHUB_TOKEN and adding permissions (push works fine with new token), now my custom action to list and then delete containers from ghcr.io throws:
when using following API with a non PAT token: docs.github.comPackages - GitHub Docs//docs.github.com/en/rest/reference/packages Could someone confirm or check this when using the GITHUB_TOKEN, did I miss something? Best regards |
Replies: 10 comments 6 replies
|
Related changelog post: Packages: Container registry now supports GITHUB_TOKEN - GitHub Changelog |
|
kc1r74p:
Hi, @kc1r74p, welcome to the community. The |
|
Thanks @byrneh, However which other API exists to read and delete containers if not those ? Best regards |
|
kc1r74p:
Hi, |
|
byrneh:
I checked the user specific one as well, and it fails with the same message. Thanks none the less for checking! Best regards, |
|
For now, PATs are still required for the REST API. We plan to support GITHUB_TOKEN on the REST API in the future, however. Shayne |
|
Hi @shayneburgess , is there any progress here? 1 year later? Deleting a package via API and GITHUB_TOKEN seems like a pretty basic feature? |
|
@shayneburgess, any progress? I think deleting a pakcage via API and GITHUB_TOKEN is very usefull for me. |
|
The documentation says that apps and fine grained tokens are supported. No special permission should be required. It still fails with a 400 error code "Invalid argument" |
|
Are there any updates on this - it would be great if GITHUB_TOKEN would work on this, or even App Installation Tokens.. |
For now, PATs are still required for the REST API. We plan to support GITHUB_TOKEN on the REST API in the future, however.
Shayne