Skip to content

GraphQL: Query one or all lists in an issue board

What does this MR do?

Add GraphQL query for boards lists

query group_boards {
  group(fullPath: "h5bp") {
    name
    boards(first: 1) {
      edges {
        node {
          name
          lists {
            edges {
              node {
                id
                listType
                maxIssueCount
                maxIssueWeight
                position
                label {
                  id
                  description
                  title
                }                
              }
            }
          }
        }
      }
    }
  }
}

with sample result of

{
  "data": {
    "group": {
      "id": "gid://gitlab/Group/28",
      "name": "H5bp",
      "boards": {
        "edges": [
          {
            "node": {
              "lists": {
                "edges": [
                  {
                    "node": {
                      "id": "gid://gitlab/List/1",
                      "listType": "backlog",
                      "maxIssueCount": 0,
                      "maxIssueWeight": 0,
                      "position": null,
                      "label": null
                    }
                  },
                  {
                    "node": {
                      "id": "gid://gitlab/List/5",
                      "listType": "label",
                      "maxIssueCount": 0,
                      "maxIssueWeight": 0,
                      "position": 0,
                      "label": {
                        "id": "gid://gitlab/GroupLabel/107",
                        "description": null,
                        "title": "To Do"
                      }
                    }
                  },
                  {
                    "node": {
                      "id": "gid://gitlab/List/6",
                      "listType": "label",
                      "maxIssueCount": 0,
                      "maxIssueWeight": 0,
                      "position": 1,
                      "label": {
                        "id": "gid://gitlab/GroupLabel/108",
                        "description": null,
                        "title": "Doing"
                      }
                    }
                  },
                  {
                    "node": {
                      "id": "gid://gitlab/List/2",
                      "listType": "closed",
                      "maxIssueCount": 0,
                      "maxIssueWeight": 0,
                      "position": null,
                      "label": null
                    }
                  }
                ]
              },
              "name": "Development"
            }
          }
        ]
      }
    }
  }
}

Screenshots

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Security

If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:

  • Label as security and @ mention @gitlab-com/gl-security/appsec
  • The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • Security reports checked/validated by a reviewer from the AppSec team

Closes #36758 (closed)

Edited by 🤖 GitLab Bot 🤖

Merge request reports