License Management
This guide describes how to add and remove users to a plan.
Adding a user to a plan (provision a license)
Invite an existing or non-existing user to a plan via email. If the user doesn't already have a Pluralsight account, the email will prompt them to create one. Once the invite is accepted, the user will then be added to the plan and consume a license.
Note: you can also use the teamIds
input argument to add the given user to the given teams upon accepting the invite
REQUEST
Copy
mutation {
inviteMember(input: {
email: "test@test.com"
teamIds: ["team-id-1"]
note: "some note"
}) {
planUserId
email
teamIds
note
}
}
RESPONSE
{
"data": {
"inviteMember": {
"planUserId": "20acd1ef-37ca-4f88-a182-d468ef1d6878",
"email": "test@test.com",
"teamIds": ["team-id-1"],
"note": "some note"
}
}
}
Note: if you need to create a Pluralsight User without adding them to a plan, see create user mutation
Removing a user from a plan (deprovision a license)
Use the removeUser
mutation to remove a user from a plan. This will also remove them from any assigned teams.
REQUEST
Copy
mutation {
removeUser(input: {
userId: "817060e5-7220-44e7-b2f1-a915b450068c"
}) {
userId
}
}
RESPONSE
{
"data": {
"removeUser": {
userId: "817060e5-7220-44e7-b2f1-a915b450068c"
}
]
}
}