0

I found a project at the address https://github.com/delbaoliveira/website/projects/1. I am using the GitHub GraphQL API to retrieve the desired notes. enter image description here I also created a similar project, but the returned result is undefined. I suspect that the variable columnId is incorrect.

enter image description here

So, how can I obtain the columnId? Please help me!

Alex Cuba
  • 73
  • 4

1 Answers1

0

You can get columnId with this query:

query { 
  repository(name: "website", owner: "delbaoliveira") {
    project(number: 1) {
      name
      columns(first: 1) {
        nodes {
          id
          name
        }
      }
    }
  }
}

But also you can go ahead and get column data without columnId like this:

query { 
  repository(name: "website", owner: "delbaoliveira") {
    project(number: 1) {
      name
      columns(first: 1) {
        nodes {
          name
          cards {
            nodes {
              note
            }
          }
        }
      }
    }
  }
}
Eugene
  • 169
  • 1
  • 6