Join group
This API is used to join an existing group.
Enabling the Service
Before using this feature, you must enable the profile hosting service by submitting a ticket.
Request method
POST: https://data center domain/entrust/group/join.json
Rate limit: 100 requests per second
Signature rules: All server API requests require signature verification. See API request signature.
Body parameters
The HTTP request body uses application/x-www-form-urlencoded
format and supports the following form parameters:
Parameter | Type | Required | Description |
---|---|---|---|
groupId | String | Yes | Group ID |
userIds | Array | Yes | User IDs to join the group: maximum 100 users per request |
Request example
POST /entrust/group/join.json HTTP/1.1
Host: api.rong-api.com
App-Key: uwd1c0sxdlx2
Nonce: 14314
Timestamp: 1408710653491
Signature: 45beb7cc7307889a8e711219a47b7cf6a5b000e8
Content-Type: application/x-www-form-urlencoded
groupId=groupId1&userIds=userId
Response
The HTTP response body contains a JSON object with the following structure:
Return value | Type | Description |
---|---|---|
code | Number | Status code. 200 indicates success. |
groupId | String | Group ID |
name | String | Group name |
groupProfile | String | Basic group information in JSON format |
groupExtProfile | String | Extended group information in JSON format |
permissions | String | Group permissions in JSON format |
owner | String | Group Owner |
createTime | Long | Group creation time |
memberCount | Number | Number of group members |
Keys in groupProfile
:
Key | Type | Description |
---|---|---|
introduction | String | Group introduction (max 512 characters) |
announcement | String | Group announcement (max 1024 characters) |
portraitUrl | String | Group avatar URL (max 128 characters) |
Keys in permissions
:
Key | Type | Length/Range | Description |
---|---|---|---|
joinPerm | Number | Values:
| Group join permission |
removePerm | Number | Values:
| Member removal permission |
memInvitePerm | Number | Values:
| Invitation permission |
invitePerm | Number | Values:
| Invitation handling method |
profilePerm | Number | Values:
| Group profile and permission modification |
memProfilePerm | Number | Values:
| Member profile modification permission |
Response example
HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
{
"code": 200,
"groupId":"gorupId1",
"createTime":1717717737377,
"owner":"userId1",
"name":"gName1",
"groupExtProfile":"{\"ext_key1\":\"value1\",\"ext_key2\":\"value2\"}",
"memberCount":10
}