Adding Members

How to add members

Adding team members can be done from the UI or via the Managment API.

Adding from the UI

  1. From the user interface, navigate to the settings tab.
  2. Click Invite User inside of the Team settings, roles and permissions card.
  3. Define the user email and role.
  4. Click invite and wait for the user to accept the invite inside of their email, and accept the invite inside of the dashboard.

Adding via Mutations

Inside of the API Explorer, make sure that you change the dropdown from stage: master to Managment API.

The Management API allows you to sendInvite that correlates to a specific project VIA it's projectId. Your projectId can be found VIA the URL of your project, consisting of 32 number and letter characters.

Lastly, in the data argument, the role needs to be specified with roleId. To get the IDs of roles in your project, use this query with your projectId replaced.

{
  viewer {
    project(id: "49c0e6285d7043758fb1e8ca43c9b658") {
      existingRoles {
        name
        id
      }
    }
  }
}

Finally, returning the name of the project that the invite just sent out to confirm success. The full mutation should look something like this:

mutation {
  sendInvite(
    data: {
      email: "kenna@graphcms.com"
      projectId: "49c0e6285d7043758fb1e8ca43c9b658"
      roleId: "c5fe30f0ce3b42b5b42efb9b5aa16bcf"
    }
  ) {
    invite {
      project {
        name
      }
    }
  }
}

Team Member Roles and Permissions

When first adding a member, you will be prompted to select the user role. Changing after-the-fact is also possible.

To change the role of a user, navigate to the settings tab. Clicking on the user avatar, a modal will appear with a dropdown of user roles available.

'Change Member Role'