Search code examples
githubgithub-apigithub-for-windows

Is there a way of getting only the issues without a certain label using the GitHub Api


I have the following

  -H "Accept: application/vnd.github.v3+json" \ 
  -H "Authorization: token <TOKEN>" \
  https://api.github.com/repos/OWNER/REPO/issues?labels=label

Currently I am only able to get the issues that have a certain label using the GitHub api, is there a way to get all the issues that doesn’t have a specific label using the GitHub api?


Solution

  • Based on github DOC, It's not possible

    labels                             string
    A list of comma separated label names. Example: bug,ui,@high
    

    One solution would be to implement it. You can get all the issue then iterate using a loop to remove the issue that has the specific label