m7kvqbe1 / github-action-move-issues

A GitHub Action to move issues between GitHub Projects columns
3 stars 1 forks source link

Add instructions to get the PAT #2

Closed koppor closed 2 weeks ago

koppor commented 2 weeks ago

The action requires ${{ secrets.PAT_TOKEN }}. I assume, it is a "personal access token (classic)" with scope "write:org" and "public_repo", but I am not 100% sure yet. It should be clarified in README.md.

m7kvqbe1 commented 2 weeks ago

I believe it would be the following at the most granular level:

public_repo, write:org, read:org read:project

I will confirm tomorrow and update README accordingly.

koppor commented 2 weeks ago

I would guess that read on projects is not enough because they are updated.

image

koppor commented 2 weeks ago

If only read:project, I get following error

Error: Error moving issue: Request failed due to following response errors:
 - Your token has not been granted the required scopes to execute this query. The 'addProjectV2ItemById' field requires one of the following scopes: ['project'], but your token has only been granted the: ['public_repo', 'read:project'] scopes. Please modify your token's scopes at: https://github.com/settings/tokens.
koppor commented 2 weeks ago

For me, just public_repo and project was enough to get an issue moved.