octokit / rest.js

GitHub REST API client for JavaScript
https://octokit.github.io/rest.js
MIT License
548 stars 63 forks source link

[BUG]: Gists create endpoint "Resource not accessible by integration" #325

Closed carlos-ss closed 1 year ago

carlos-ss commented 1 year ago

What happened?

When attempting to create a gist using await octokit.rest.gists.create({...}) the internal request fails as a 403 with the response data: { message: 'Resource not accessible by integration', documentation_url: 'https://docs.github.com/rest/reference/gists#create-a-gist' }

I have added the permissions described in the doc.

The permission config was tested by using await octokit.rest.gists.list() When permission is set to 'No access" the request data is just an empty array When permission for the Gists is set to 'Read and Write' , I get gists previously created

I get the same results making a postman request directly to the api

Versions

@octokit/rest 19.0.13 Node 19.9.0

Relevant log output

No response

Code of Conduct

kfcampbell commented 1 year ago

@carlos-ss thanks for the report! API bugs should be filed at our rest-api-description repository.

carlos-ss commented 1 year ago

Sounds good, TY

kfcampbell commented 1 year ago

@carlos-ss I accidentally mislead you; you should go here instead to report API bugs, sorry!