URI
<group_uri>/members[.<format>]
Supported methods
Parent resource
Child resources
groupMember, groupMembersApply, groupMembersInvite
Introduction
The groupMembers resource represents single group member list information. The resource supports deleting group member information in batch, allows group creator (logged in) to delete group members, allows group member (logged in) to exit the group and remove all resource shared in the group.
Supported Methods:
- GET: Get member list of the specified group.
- DELETE: Delete group member information in batch.
- HEAD: Check whether the groupMembers resource exists, or have permission to access the groupMembers resource.
Supported output formats: rjson, json, html, xml.
Resource hierarchy
HTTP request methods
Implement the HTTP request on the following URI, where supermapiportal is the server name, with rjson being the output format.
http://supermapiportal:8090/iportal/web/groups/{id}/members.rjson
GET request
Get member list of the specified group.
Response structure
When you implement the GET request on the groupgroupMembers Member resource to acquire the specified member list information, the structure of the response is as follows:
| Field | Type | Description |
| content | List<GroupMember> | The content for the page. |
| currentPage | int | The current page. |
| pageSize | int | The page size. |
| searchParameter | SearchParameter | The search parameters for the current page. |
| total | int | The total number of records. |
| totalPage | int | The total number of pages. |
Response example
When you implement the GET request on the groupMembers resource http://localhost:8090/iportal/web/groups/1/members.rjson to acquire the information of member list of the specified group, the rjson format representation of the resource is as follows:
{
"content": [
{
"groupId": 1,
"groupRole": "CREATOR",
"id": 1,
"joinTime": 1416984287897,
"memberDescription": null,
"nickname": "admin",
"roleUpdateTime": null,
"userName": "admin"
},
{
"groupId": 1,
"groupRole": "MEMBER",
"id": 5,
"joinTime": 1416984478118,
"memberDescription": null,
"nickname": "wanghl",
"roleUpdateTime": null,
"userName": "xiaowang"
},
{
"groupId": 1,
"groupRole": "MEMBER",
"id": 7,
"joinTime": 1416984601991,
"memberDescription": null,
"nickname": "liyl",
"roleUpdateTime": null,
"userName": "xiaoli"
}
],
"currentPage": 1,
"pageSize": 9,
"searchParameter": {
"currentPage": 1,
"currentUser": null,
"groupId": 1,
"groupRole": null,
"keywords": null,
"orderBy": null,
"orderType": "ASC",
"pageSize": 9,
"userName": null
},
"total": 3,
"totalPage": 1
}
DELETE request
Delete the member with specified user name. Group create (logged in) can delete group member. Group member (logged in) can exit the group and remove all resource shared in the group.
Response structure
The representation structure of the resource returned is as follows:
| Field | Type | Description |
| succeed | boolean | Whether the group member has been deleted (or whether the group member leave the group) successfully or not. |
| error | Httperror | Error information. The field will not exist if deletion of group member is successful. |
Response example
When you implement the DELETE request on the groupMembers respirce http://localhost:8090/iportal/groups/6/members.rjson?userNames=["xiaoming","xiaoming2"] to delete members with user names userName 为 xiaoming and xiaoming2 in batch, the rjson format representation returned is as follows:
{ "succeed": true}
HEAD request
Asks for the response identical to the one that would correspond to a GET request, but without the response body. This is useful for retrieving meta-information written in response headers, without having to transport the entire content. The meta-information includes the media-type, content-encoding, transfer-encoding, content-length, etc.
HEAD request can be used to check if the groupMembers resource exists, or if the groupMembers resource can be accessed by clients. It can also determine if the groupMembers resource supports an output format <format> if performed on a URI with .<format> included.