Skip to content

update deployment issue workflow so that the issues have project metadata fields updated for better sorting and filtering #3

@tallguyjenks

Description

@tallguyjenks

Have to use the new graph API to access beta projects

Project ID's

related article

can use their graph api explorer and run this query to find the project ID's for the org:

{
  organization(login: "CoveredCA") {
    login
    projectsV2(first: 100) {
      edges {
        node {
          id
          title
        }
      }
    }
  }
}

Field ID's

gh api graphql -f query='
            query($org: String!, $number: Int!) {
              organization(login: $org){
                projectV2(number: $number) {
                  id
                  fields(first:20) {
                    nodes {
                      ... on ProjectV2Field {
                        id
                        name
                      }
                      ... on ProjectV2SingleSelectField {
                        id
                        name
                        options {
                          id
                          name
                        }
                      }
                    }
                  }
                }
              }
            }' -f org=$ORGANIZATION -F number=$PROJECT_NUMBER

run update operations on a given item

gh api graphql -f query='
    mutation {
        updateProjectV2ItemFieldValue(
            input: {
                projectId: "PVT_kwDOAfwVjc4AV0R8"
                itemId: "40946050"
                fieldId: "121975948"
                value: {
                    text: "hello world"
                }
            }
        )
        {
            projectV2Item {
                id
            }
        }
    }'

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions