更新时间:2019-11-20
企业管理员通过该接口查询部门及其一级子部门列表。
请求方法 |
GET |
---|---|
请求地址 |
/rest/usg/datacenter/v1/member/dept/{deptCode} |
传输协议 |
HTTPS |
参数 |
是否必须 |
类型 |
位置 |
描述 |
---|---|---|---|---|
Authorization |
是 |
String |
Header |
授权令牌。将执行鉴权响应的accessToken 进行Base64转码操作。 样例:Basic Base64(accessToken) |
deptCode |
是 |
String |
URL |
部门编码。 长度: 0-32位。 |
参数 |
类型 |
描述 |
---|---|---|
returnCode |
String |
业务返回码。 |
returnMessage |
String |
返回描述。 |
achievementTime |
String |
响应产生时间。 |
requestId |
String |
请求唯一标识。 |
data |
查询部门列表,返回该部门及其子部门。 |
参数 |
类型 |
描述 |
---|---|---|
corpId |
String |
企业ID。 |
deptCode |
String |
部门编码。 |
deptLevel |
Integer |
部门层级。 |
deptName |
String |
部门名称。 |
deptNamePath |
String |
部门路径。 |
isLeafNode |
Boolean |
是否叶子。 |
parentDeptCode |
String |
父部门编号。 |
deptCodePath |
String |
部门编码路径。 |
note |
String |
备注。 |
childDepts |
QueryDeptResultDTO[0..*] |
子部门列表。 |
GET /rest/usg/datacenter/v1/member/dept/27b Connection: keep-alive Authorization: Basic OENmOVBFUXZZV29ZMnVZYXQzdXVUcjhxdW9WYWdQSkJ4 Host: api.meeting.huaweicloud.com User-Agent: Apache-HttpClient/4.5.3 (Java/1.8.0_191)
HTTP/1.1 200 Date: Thu, 12 Apr 2019 08:37:33 GMT Content-Type: application/json;charset=UTF-8 Connection: keep-alive Pragma: No-cache Cache-Control: no-cache Server: api-gateway X-Request-Id: 539e8b710378987ffc5eb844b5e5c290 { "returnCode": "000000000", "returnMessage": "Success", "achievementTime": "2019-04-12 08:37:33.388", "requestId": "50544b84385b553b1054e05adc2a970f", "data": { "corpId": "42019", "deptCode": "27b", "deptLevel": 2, "deptName": "111111", "deptNamePath": "user001#111111", "isLeafNode": true, "parentDeptCode": "1", "deptCodePath": "1#27b", "note": "string", "childDepts": [] } }
curl -k -i -X GET -H 'Authorization: Basic VUVwVU82SWFISU0ySWlKaEdoRllRUXk0MUZnbk00Mkpk' https://api.meeting.huaweicloud.com/rest/usg/datacenter/v1/member/dept/27b