Request

Response

    Mutations

    changeGroupsRoleInProject

    mutation

    Change role of groups in a project.

    Template for Mutation:

    mutation ChangeGroupsRoleInProject($input: changeGroupsRoleInProjectInput!){
      changeGroupsRoleInProject(input: $input) {
        # ChangeGroupsRoleInProjectPayload Fields
      }
    }
    

    Arguments

    input*Input object for changing the role of groups in a project.
    * Required

    Possible Returns

    Value TypeDescription
    ChangeGroupsRoleInProjectPayload Return payload for change groups' role in project operation.


    Examples

    Example 1

    Change role of group in the project.

    Query:

     mutation ChnageGroupsRoleInProject($input: ChangeGroupsRoleInProjectInput!) {
     changeGroupsRoleInProject(input: $input) {
       project {
         id
         name
         groups{
           results{
               id
               name
               role
           }
         }
       }
     }
    }
    
    Show More

    Query Variables:

    {
     "input": {
       "groupIds": ["566929135"],
       "groupRole": "MANAGER",
       "projectId": "urn:adsk.workspace:beta.project:e0b62c50-ed1d-4322-a951-a05e2d75845a"
     }
    }
    

    Response:

    {
       "data": {
           "changeGroupsRoleInProject": {
               "project": {
                   "id": "urn:adsk.workspace:beta.project:e0b62c50-ed1d-4322-a951-a05e2d75845a",
                   "name": "Docs Project",
                   "groups": {
                       "results": [
                           {
                               "id": "327741550",
                               "name": "admins",
                               "role": "ADMINISTRATOR"
                           },
                           {
                               "id": "566929135",
                               "name": "DocGroup1793373238084",
                               "role": "MANAGER"
                           }
                       ]
                   }
               }
           }
       }
    }
    
    Show More