Skip to content
English
  • There are no suggestions because the search field is empty.

HR Learn: API v2 - Group API

The Group API performs actions related to groups in the HR Learn LMS.

The Group API performs actions related to groups in the HR Learn LMS. The following methods are available via this API:

Create group

HTTP Action

POST

Base URL

https://[Your HR Learn LMS Portal URL]

Endpoint URL

/api/group/v2/create

Request Parameters

Parameter Data Type Description
Name (required) string

 

IsSelfJoinAllowed (optional) boolean Are users allowed to join themselves to this group?
MembershipIsPublicized (optional) boolean

Should the user be aware of their membership to the group?

This value must be true of IsSelfJoinAllowed or IsFeedActive is true.

IsFeedActive (optional) boolean Is the group discussion feed enabled?
IsFeedModerated (optional) boolean Is the group discussion feed moderated?
ShortDescription (optional) string  
LongDescription (optional) string  
SearchTags (optional) string  
Details (optional) array object<string, string, string, string, string>

Array of objects that define language-specific properties for the group. Object should have the following parameters:

  • "Language" - The language the properties. This should be a standard language code, a list of acceptable values can be found here.
  • "Name" - The group's name in the specified language.
  • "ShortDescription" - The group's short description in the specified language.
  • "LongDescription" - The group's long description in the specified language.
  • "SearchTags" - The group's search tags in the specified language.

Example:

{   "Name": "My Group",   "IsSelfJoinAllowed": false,   "MembershipIsPublicized": true,   "IsFeedActive": true,   "IsFeedModerated": false,   "ShortDescription": "This is my group.",   "LongDescription": null,   "SearchTags": null,   "Details": [{ 	"Language": "es-ES", 	"Name": "Mi grupo", 	"ShortDescription": "Este es mi grupo.", 	"LongDescription": null, 	"SearchTags": null 	}] } 

Response

The id of the group that was created.

Example:

123

Search groups

HTTP Action

POST

Base URL

https://[Your HR Learn LMS Portal URL]

Endpoint URL

/api/group/v2/search

Request Parameters

Parameter Data Type Description
Type (required) string

The type of search to perform, can be one of the following values:

  • "fts" - performs a full text search across titles and descriptions
  • "name" - performs a search by name
SearchParam (required) string The term you are searching for.

Example:

{   "Type": "name",    "SearchParam": "My Group" } 

Response

An array of group objects matching the search criteria.

Example:

[ 	{ 		"Id": 123, 		"IdSite": 2, 		"Name": "My Group", 		"PrimaryGroupToken": null, 		"ObjectGUID": null, 		"DistinguishedName": null, 		"Avatar": null, 		"LanguageSpecificProperties": [ 			{ 				"LangString": "en-US", 				"Name": "My Group", 				"ShortDescription": "This is my group.", 				"LongDescription": "", 				"SearchTags": "" 			} 		], 		"IsSelfJoinAllowed": false, 		"MembershipIsPublicized": true, 		"IsFeedActive": true, 		"IsFeedModerated": false, 		"ShortDescription": "This is my group.", 		"LongDescription": null, 		"SearchTags": null, 		"IsCallingUserAMember": false, 		"NumberOfMembers": 2 	} ]

Get group details

HTTP Action

GET

Base URL

https://[Your HR Learn LMS Portal URL]

Endpoint URL

/api/group/v2/{id}

Request Parameters

NONE

Response

A group object matching the {id} of the group.

Example:

{ 	"Id": 123, 	"IdSite": 2, 	"Name": "My Group", 	"PrimaryGroupToken": null, 	"ObjectGUID": null, 	"DistinguishedName": null, 	"Avatar": null, 	"LanguageSpecificProperties": [ 		{ 			"LangString": "en-US", 			"Name": "My Group", 			"ShortDescription": "This is my group.", 			"LongDescription": "", 			"SearchTags": "" 		} 	], 	"IsSelfJoinAllowed": false, 	"MembershipIsPublicized": true, 	"IsFeedActive": true, 	"IsFeedModerated": false, 	"ShortDescription": "This is my group.", 	"LongDescription": null, 	"SearchTags": null, 	"IsCallingUserAMember": false, 	"NumberOfMembers": 2 } 



Update group

HTTP Action

PUT

Base URL

https://[Your HR Learn LMS Portal URL]

Endpoint URL

/api/group/v2/{id}

Request Parameters

Parameter Data Type Description
Name (required) string

 

IsSelfJoinAllowed (optional) boolean Are users allowed to join themselves to this group?
MembershipIsPublicized (optional) boolean

Should the user be aware of their membership to the group?

This value must be true of IsSelfJoinAllowed or IsFeedActive is true.

IsFeedActive (optional) boolean Is the group discussion feed enabled?
IsFeedModerated (optional) boolean Is the group discussion feed moderated?
ShortDescription (optional) string  
LongDescription (optional) string  
SearchTags (optional) string  
Details (optional) array object<string, string, string, string, string>

Array of objects that define language-specific properties for the group. Object should have the following parameters:

  • "Language" - The language the properties. This should be a standard language code, a list of acceptable values can be found here.
  • "Name" - The group's name in the specified language.
  • "ShortDescription" - The group's short description in the specified language.
  • "LongDescription" - The group's long description in the specified language.
  • "SearchTags" - The group's search tags in the specified language.

Example:

{   "Name": "My Group",   "IsSelfJoinAllowed": false,   "MembershipIsPublicized": true,   "IsFeedActive": true,   "IsFeedModerated": false,   "ShortDescription": "This is my group.",   "LongDescription": null,   "SearchTags": null,   "Details": [{ 	"Language": "es-ES", 	"Name": "Mi grupo", 	"ShortDescription": "Este es mi grupo.", 	"LongDescription": null, 	"SearchTags": null 	}] } 

Response

The id of the group that was updated.

Example:

123



Delete group

HTTP Action

DELETE

Base URL

https://[Your HR Learn LMS Portal URL]

Endpoint URL

/api/group/v2/{id}

Request Parameters

NONE

Response

NONE (200 - OK)

Get group members

HTTP Action

GET

Base URL

https://[Your HR Learn LMS Portal URL]

Endpoint URL

/api/group/v2/{id}/users

Request Parameters

NONE

Response

An array of user objects who are members of the group specified by {id}.

Example:

[ 	{ 		"Id": 7, 		"FirstName": "Group", 		"LastName": "User", 		"Username": "groupuser", 		"Email": "groupuser@myorganization.tld", 		"Avatar": null 	} ]

Attach user(s) to group

HTTP Action

POST

Base URL

https://[Your HR Learn LMS Portal URL]

Endpoint URL

/api/group/v2/{id}/attachusers

Request Parameters

Parameter Data Type Description
UserIds array<integer>

An array of user ids to attach to the group.

Example:

{		     "UserIds": [ 123 ] } 

Response

NONE (200 - OK)



Remove user(s) from group

HTTP Action

POST

Base URL

https://[Your HR Learn LMS Portal URL]

Endpoint URL

/api/group/v2/{id}/removeusers

Request Parameters

Parameter Data Type Description
UserIds array<integer>

An array of user ids to remove from the group.

Example:

{		     "UserIds": [ 123 ] } 

Response

NONE (200 - OK)