Skip to main content

Create Team

重要提示

该功能仅支持旗舰版、服务商合作使用,详情请联系客服

API Overview

  • Function: Create Team
  • Request Method: POST
  • Request URL: /api/orgs?appid={appid}&access_token={access_token}

Request Parameters

Parameter NameTypeLocationDescriptionExample
namestringbodyTeam NameExample Company Ltd.
user_idintegerbodyCreator's User ID (obtained from Create Third-party User)60000208205

Response Parameters

Parameter NameTypeDescription
org_idintegerTeam ID (used for reading team information)
team_idintegerTeam Contact Directory ID (used for reading/writing contact members)

Request Example

POST https://open.wesurvey.com/api/orgs

{
"name": "Example Company Ltd.",
"user_id": 60000208205
}

Response Examples

  • Successful Request
{
"code": "OK",
"error": {
"type": ""
},
"data": {
"org_id": 60000208206,
"team_id": 43
},
"request_id": "d84e884b-3bc5-419d-9cc0-d6d6d14e68b6"
}
  • Failed Request
{
"code": "ResourceExhausted",
"error": {
"type": "org_resource_exhausted"
},
"data": {},
"request_id": "d84e884b-3bc5-419d-9cc0-d6d6d14e68b6"
}

Error Codes

error.type CodeDescription
org_resource_exhaustedTeam quota limit reached. Each user can only create 5 teams
org_create_errorFailed to create team