URI

<groupMembers_uri>/inviteinfo[.<format>]

Supported methods

GET, POST, HEAD

Parent resource

groupMembers

Introduction

The groupMembersInvite resource is invitation list information for a single group. Only group creator has the permission to get all invitation list information of the current group and send invitation to other users that are not in the group. Batch invitation is supported.

Supported Methods:

  • GET: Get all invitation list information of the current group. Only the group creator has the permission.
  • POST: Send invitation to other users that are not in the group. Batch invitation is supported. Only the group creator has the permission.
  • HEAD: Check whether the groupMembersInvite resource exists, or whether there is permission to access the groupMembersInvite 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/inviteinfo.rjson

GET request

Get all invitation list information of the current group. Only the group creator has the permission.

Request parameter

If the parameter has not been set, list information for all invitations in the current group will be returned. If the parameter has been set, the specified application list information will be returned. Parameters must be contained in the URI.

Name Type Description
currentPage int Query according to current page.
pageSize int Query according to page size.
feedbackStatus FeedbackStatus Query according to feedback status. The feedback status includes: WAITING, ACCEPTED, REUSED.
orderType OrderType Query according to sort ascending order.
orderBy InviteOrderby Query according to sort order.

Response structure

When you implement the GET request on the groupMembersInvite Member resource to return invitation list information of the current group, the structure of the response is as follows:

Field Type Description
content List<GroupInviteInfo> 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

The returned rjson format representation after implementing the GET request on the groupMembersInvite resource http://localhost:8090/iportal/web/groups/1/members/inviteinfo.rjson:

{

    "content": [

        {

            "feedbackInfo": null,

            "feedbackStatus": "WAITING",

            "feedbackTime": 1415324175031,

            "groupId": 1,

            "groupName": "FA",

            "id": 1,

            "inviteReason": "Work",

            "inviteTime": 1415324175031,

            "invitee": "wanghl",

            "inviteeNick": "xiaowang",

            "inviter": "admin",

            "inviterNick": "admin"

        },

        {

            "feedbackInfo": null,

            "feedbackStatus": "WAITING",

            "feedbackTime": 1415324389343,

            "groupId": 1,

            "groupName": "FA",

            "id": 2,

            "inviteReason": "Edit",

            "inviteTime": 1415324389343,

            "invitee": "liyl",

            "inviteeNick": "xiaoli",

            "inviter": "admin",

            "inviterNick": "admin"

        }

    ],

    "currentPage": 1,

    "pageSize": 9,

    "searchParameter": null,

    "total": 2,

    "totalPage": 1

}

If you want to acquire the specified invitation list information, filter according to sort order and feedback status for example, then you need to set orderType=ASC&feedbackStatus=WAITING, that is implementing the GET request on the groupMembersInvite resource http://localhost:8090/iportal/web/groups/1/members/inviteinfo.rjson?orderType=ASC&feedbackStatus=WAITING. The rjson format representation returned is as follows:

{

    "content": [

        {

            "feedbackInfo": null,

            "feedbackStatus": "WAITING",

            "feedbackTime": 1415324175031,

            "groupId": 1,

            "groupName": "FA",

            "id": 1,

            "inviteReason": "Work",

            "inviteTime": 1415324175031,

            "invitee": "wanghl",

            "inviteeNick": "xiaowang",

            "inviter": "admin",

            "inviterNick": "admin"

        },

        {

            "feedbackInfo": null,

            "feedbackStatus": "WAITING",

            "feedbackTime": 1415324389343,

            "groupId": 1,

            "groupName": "FA",

            "id": 2,

            "inviteReason": "Edit",

            "inviteTime": 1415324389343,

            "invitee": "liyl",

            "inviteeNick": "xiaoli",

            "inviter": "admin",

            "inviterNick": "admin"

        }

    ],

    "currentPage": 1,

    "pageSize": 9,

    "searchParameter": null,

    "total": 2,

    "totalPage": 1

}

POST request

Send invitation to other users that are not in the group. Batch invitation is supported. Only the group creator has the permission.

Request parameter

Following arguments need to be included in the request sent.

Name Type Description
groupId Integer Group id invited to join in.
applyReason String Reason to invite to join in the group.
inviteNames List<String> The name of the invited user.

Response structure

The representation structure of the resource returned is as follows:

Field Type Description
succeed boolean Whether the invitation has been successfully sent.
error Httperror Error information. The field will not exist if the operation is successful.

Response example

When you implement the POST request on the groupMembersInviteresource http://localhost:8090/iportal/web/groups/1/members/inviteinfo.rjson to apply for joining into the current group, the request body sent is as follows:

{

    "groupId": 1,

    "inviteNames": [

        "liyl",

        "wanghl"

    ],

    "inviteReason": "Cooperative Work"

}

The response result in rjson format 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 groupMembersInvite resource exists, or if the groupMembersInvite resource can be accessed by clients. It can also determine if the groupMembersInvite resource supports an output format <format> if performed on a URI with .<format> included.

See