diff --git a/source/includes/_team_users.md b/source/includes/_team_users.md index 2784658e88e..e01f593adb8 100644 --- a/source/includes/_team_users.md +++ b/source/includes/_team_users.md @@ -183,7 +183,6 @@ end user_details = { userId: 1, - isPrimary: true } result = Learnamp::TeamUsers.new(token).add(1, user_details) @@ -198,8 +197,25 @@ Add a user to a team. ### Required Scope This endpoint requires the `team_users:create` scope. +### Data in Body + +Parameter | Example value | Description +--------- | ------- | ----------- +userId | 1 | User ID of user to add to team +response | Teams::Simple | Optional: (blank value is the default) or "Teams::Simple" or "Teams::Extended". Value of "Teams::Simple" will include basic team information in the response. Value of "Teams::Extended: will include full team information in the response, including full list of users, sub-teams and tags in the JSON response. Only use the "Teams::Extended" response if all this data is required. + > 201 Created - successful response: +```json +{ + "id": 1, + "teamId": 3, + "userId": 1 +} +``` + +> 201 Created - successful response, using response = Teams::Extended param + ```json { "id": 1, @@ -369,11 +385,22 @@ teamId | 1200 | ID of the team teamName | "Marketing" | Name of the team userId | 1 | User ID of user to add to team userEmail | "user@email.com" | Email of the new team member +response | Teams::Simple | Optional: (blank value is the default) or "Teams::Simple" or "Teams::Extended". Value of "Teams::Simple" will include basic team information in the response. Value of "Teams::Extended: will include full team information in the response, including full list of users, sub-teams and tags in the JSON response. Only use the "Teams::Extended" response if all this data is required. Parameters `teamId` and `teamName` are mutually exclusive - only one of them can be present in the request payload. Same rule applies for `userId` and `userEmail`. > 201 Created - successful response: +```json +{ + "id": 1, + "teamId": 3, + "userId": 1 +} +``` + +> 201 Created - successful response, using response = Teams::Extended param + ```json { "id": 1,