Create a Coach
In order to create a coach we require to use a combination of two mutations createUser
and makeCoach
.
createUser
will create the new user inside the console while makeCoach
will grant access to the coaching portal.
Both should be run on our "console API", so you will need to generate the "Authorization Token" which is required as an authorization header (example below).
Generate Token
Argument Name | Is required? | Type | Description |
Yes | string | Console Admin email | |
password | Yes | string | Object that contains the password fields. |
Create User
Field Name | Type | Description |
String | Coach user email | |
name | String | Coach name |
password | String | Coach password |
roles | Array | Viewer |
active | Boolean | True if the coach will be active. Otherwise, False |
Make Coach
Field Name | Type | Description |
String | Coach user email | |
name | String | Coach name |
isCoachAdmin | Boolean | Set to True to make coach |
Available Fields
The following fields will be displayed in the response:
Field Name | Type | Description |
| Boolean | True if the coach information has been created successfully. Otherwise, False |
| String | Description of the result |
Examples
Generate access token
Create coach
Last updated