Skip to content

国资房产

建筑信息

描述

建筑信息

支持的模式

  • client_credentials

请求方法

GET

请求地址

https://api.ecnu.edu.cn/api/v1/asset/buildings

请求参数

参数名是否必填备注
pageNum分页第几页,从1开始
pageSize每页的数量

返回参数

参数名类型备注
totalNumnumber总共的条目数
pageSizenumber每页的大小
rowsobject array具体的返回
buildingIdstring建筑物编号
buildingNamestring建筑物名称
siteNamestring校区名称

请求示例

curl -i -H "Authorization: Bearer e447e4b4b8e23973b42c44b8d5415603" "https://api.ecnu.edu.cn/api/v1/asset/buildings?pageNum=1&pageSize=5"

返回示例

json
{
  "data": {
    "totalNum": 245,
    "pageSize": 5,
    "rows": [
      {
        "buildingName": "****大楼",
        "siteName": "普陀校区",
        "buildingId": "1"
      },
      {
        "buildingName": "****大楼",
        "siteName": "普陀校区",
        "buildingId": "100"
      },
      {
        "buildingName": "****大楼",
        "siteName": "普陀校区",
        "buildingId": "11"
      },
      {
        "buildingName": "****大楼",
        "siteName": "普陀校区",
        "buildingId": "110"
      },
      {
        "buildingName": "****大楼",
        "siteName": "普陀校区",
        "buildingId": "113"
      }
    ],
    "pageNum": 1
  },
  "errCode": 0,
  "requestId": "6a0f0e4b16251931256192991e5280",
  "errMsg": "success",
  "apiLog": null
}

房间详细信息

描述

房间详细信息

支持的模式

  • client_credentials

请求方法

GET

请求地址

https://api.ecnu.edu.cn/api/v1/asset/room/detail

请求参数

参数名是否必填备注
roomUUID房间编码

返回参数

参数名类型备注
roomUUIDstring房间唯一编码
buildingIdstring建筑物编码
buildingNamestring建筑物名称
siteNamestring校区名称
floorstring楼层
roomIdstring房间号
buildingAreanumber建筑面积,单位:M2
usableAreanumber使用面积,单位:M2
dvIdstring单位编码
dvNamestring使用单位
dpIdstring部门编码
dpNamestring部门名称
dvManagestring管理部门
roomTypestring类别代码
roomTypeNamestring类别名称
roomCatTypestring类型代码
roomCatNamestring类型名称
roomUseTypestring大类代码
roomUseNamestring大类名称
roomNamestring房间名称
roomUserCountint教职工人数

请求示例

curl -i -H "Authorization: Bearer e447e4b4b8e23973b42c44b8d5415603" "https://api.ecnu.edu.cn/api/v1/asset/room/detail?roomUUID=129_F04_421"

返回示例

json
{
  "data": [
    {
      "dvId": "***",
      "dpName": "",
      "roomUseType": "30",
      "dpId": "",
      "roomUseName": "生活用房",
      "roomTypeName": "学生居室",
      "buildingArea": 1,
      "siteName": "普陀校区",
      "roomCatName": "学生宿舍",
      "roomId": "***",
      "roomName": "***",
      "buildingId": "129",
      "buildingName": "***",
      "dvManage": "***",
      "dvName": "宿舍",
      "usableArea": 1,
      "roomUserCount": 0,
      "roomCatType": "***",
      "floor": "F04",
      "roomUUID": "***",
      "roomType": "***"
    }
  ],
  "requestId": "6a0f0ef016251937292311292e05d1",
  "errCode": 0,
  "errMsg": "success",
  "apiLog": null
}

根据使用人查询房间信息

描述

根据使用人查询房间信息

支持的模式

  • authorization_code
  • client_credentials
  • password

请求方法

GET

请求地址

https://api.ecnu.edu.cn/api/v1/asset/room/user

请求参数

参数名是否必填备注
userId学工号,当授权为authorization_code和password模式时可省略

返回参数

参数名类型备注
roomUUIDstring房间唯一编码
buildingIdstring建筑物编码
buildingNamestring建筑物名称
siteNamestring校区名称
floorstring楼层
roomIdstring房间号
roomNamestring房间名称
buildingAreanumber建筑面积,单位:M2
usableAreanumber使用面积,单位:M2
roomUserCountint教职工人数

请求示例

curl -i -H "Authorization: Bearer e447e4b4b8e23973b42c44b8d5415603" "https://api.ecnu.edu.cn/api/v1/asset/room/user?userId=201****7"

返回示例

json
{
  "data": [
    {
      "buildingName": "****",
      "usableArea": 1,
      "siteName": "闵行校区",
      "buildingArea": 1,
      "roomUserCount": 5,
      "floor": "***",
      "roomUUID": "****",
      "roomId": "***",
      "roomName": "***",
      "buildingId": "***"
    }
  ],
  "errCode": 0,
  "requestId": "65841f9216252046320577924e7bbe",
  "errMsg": "success",
  "apiLog": null
}

根据建筑查询房间信息

描述

根据建筑查询房间信息

支持的模式

  • client_credentials

请求方法

GET

请求地址

https://api.ecnu.edu.cn/api/v1/asset/room/building

请求参数

参数名是否必填备注
pageNum分页第几页,从1开始
pageSize每页的数量
buildingId建筑物编码
roomCatType房间类型编码(若不填则返回所有)

返回参数

参数名类型备注
totalNumnumber总共的条目数
pageSizenumber每页的大小
rowsobject array具体的返回
buildingIdstring建筑物编号
buildingNamestring建筑物名称
siteNamestring校区名称
roomUUIDstring房间唯一编码
floorstring楼层
roomIdstring房间号
roomNamestring房间名称
roomCatTypestring房间类型编码
roomCatNamestring房间类型名称

请求示例

curl -i -H "Authorization: Bearer e447e4b4b8e23973b42c44b8d5415603" "https://api.ecnu.edu.cn/api/v1/asset/room/building?pageSize=2&pageNum=1&buildingId=1029"

返回示例

json
{
  "data": {
    "totalNum": 5,
    "pageSize": 10,
    "rows": [
      {
        "buildingName": "****",
        "siteName": "闵行校区",
        "roomCatType": "303",
        "floor": "F01",
        "roomUUID": "1001****",
        "roomCatName": "****用房",
        "roomId": "101",
        "roomName": "****活动室",
        "buildingId": "1001"
      },
      {
        "buildingName": "****",
        "siteName": "闵行校区",
        "roomCatType": "303",
        "floor": "F01",
        "roomUUID": "1001****",
        "roomCatName": "****用房",
        "roomId": "101",
        "roomName": "****活动室",
        "buildingId": "1001"
      },
      {
        "buildingName": "****",
        "siteName": "闵行校区",
        "roomCatType": "303",
        "floor": "F01",
        "roomUUID": "1001****",
        "roomCatName": "****用房",
        "roomId": "101",
        "roomName": "****活动室",
        "buildingId": "1001"
      },
      {
        "buildingName": "****",
        "siteName": "闵行校区",
        "roomCatType": "303",
        "floor": "F01",
        "roomUUID": "1001****",
        "roomCatName": "****用房",
        "roomId": "101",
        "roomName": "****活动室",
        "buildingId": "1001"
      },
      {
        "buildingName": "****",
        "siteName": "闵行校区",
        "roomCatType": "303",
        "floor": "F01",
        "roomUUID": "1001****",
        "roomCatName": "****用房",
        "roomId": "101",
        "roomName": "****活动室",
        "buildingId": "1001"
      },
    ],
    "pageNum": 1
  },
  "errCode": 0,
  "requestId": "0bc1742116488070513461537e4847",
  "errMsg": "success"
}

根据建筑查询房间与房门信息

描述

根据建筑查询房间与房门的信息

支持的模式

  • client_credentials

请求方法

GET

请求地址

https://api.ecnu.edu.cn/api/v1/asset/door/building

请求参数

参数名是否必填备注
pageNum分页第几页,从1开始
pageSize每页的数量
buildingId建筑物编码

返回参数

参数名类型备注
totalNumnumber总共的条目数
pageSizenumber每页的大小
rowsobject array具体的返回
siteNamestring校区名称
buildingIdstring建筑物编号
buildingNamestring建筑物名称
floorstring楼层
doorUUIDstring房门唯一编码
doorIdstring房门号
doorNamestring房门名称
dwgNamestring图纸名称
roomUUIDstring房间唯一编码,如果无关联房间则为空字符串
roomIdstring房间号,如果无关联房间则为空字符串
roomNamestring房间名称,如果无关联房间则为空字符串
roomCatTypestring房间类型编码,如果无关联房间则为空字符串
roomCatNamestring房间类型名称,如果无关联房间则为空字符串

请求示例

curl -i -H "Authorization: Bearer e447e4b4b8e23973b42c44b8d5415603" "https://api.ecnu.edu.cn/api/v1/asset/door/building?pageSize=2&pageNum=1&buildingId=160"

返回示例

json
{
	"data": {
		"totalNum": 1081,
		"pageSize": 2,
		"rows": [{
			"siteName": "普陀校区",
			"buildingId": "160",
			"buildingName": "****大楼",
			"floorId": "F20",
			"doorUUID": "01_******",
			"doorId": "**2B",
			"doorName": "**2B",
			"dwgName": "160-F20",
			"roomUUID": "01_**",
			"roomId": "**2B",
			"roomCatType": "SERV",
			"roomCatName": "SERV",
			"roomName": "水箱间"
		},{
			"siteName": "普陀校区",
			"buildingId": "160",
			"buildingName": "****大楼",
			"floorId": "F20",
			"doorUUID": "01_******",
			"doorId": "**2B",
			"doorName": "**2B",
			"dwgName": "160-F20",
			"roomUUID": "01_**",
			"roomId": "**2B",
			"roomCatType": "SERV",
			"roomCatName": "SERV",
			"roomName": "水箱间"
		}],
		"pageNum": 1
	},
	"errCode": 0,
	"requestId": "D6C7332D-EC16-4692-8BC4-D6FCE0C1DA73",
	"errMsg": "success",
	"apiLog": null
}

根据房间号查使用人工号

描述

根据房间号查使用人工号

支持的模式

  • client_credentials

请求方法

GET

请求地址

https://api.ecnu.edu.cn/api/v1/asset/roomuser

请求参数

参数名是否必填备注
roomUUID房间编码

返回参数

参数名类型备注
userIdstring使用人工号
roomUUIDstring房间唯一编码

请求示例

curl -i -H "Authorization: Bearer e447e4b4b8e23973b42c44b8d5415603" "https://api.ecnu.edu.cn/api/v1/asset/roomuser?roomUUID=1029_****"

返回示例

json
{
  "data": [
    {
      "userId": "20*****0",
      "roomUUID": "1029_*****"
    },
    {
      "userId": "20*****0",
      "roomUUID": "1029_*****"
    }
  ],
  "errCode": 0,
  "requestId": "65841f9216252059301317078e7bbb",
  "errMsg": "success",
  "apiLog": null
}

全量同步所有的房间与房门信息

描述

全量同步所有的房间与房门信息

支持的模式

  • client_credentials

请求方法

GET

请求地址

https://api.ecnu.edu.cn/api/v1/asset/roomdoors

请求参数

参数名是否必填备注
pageNum分页第几页,从1开始
pageSize每页的数量

返回参数

参数名类型备注
totalNumnumber总共的条目数
pageSizenumber每页的大小
rowsobject array具体的返回
siteNamestring校区名称
buildingIdstring建筑物编号
buildingNamestring建筑物名称
floorstring楼层
doorUUIDstring房门唯一编码
doorIdstring房门号
roomIdstring房间号
buildingAreanumber房间的建筑面积,单位:M2
usableAreanumber房间的使用面积,单位:M2
dvIdstring房间的单位编码
dvNamestring房间的使用单位
dpIdstring房间的部门编码
dpNamestring房间的部门名称
dvManagestring房间的管理部门
roomTypestring房间的类别代码
roomTypeNamestring房间的类别名称
roomCatTypestring房间的类型代码
roomCatNamestring房间的类型名称
roomUseTypestring房间的大类代码
roomUseNamestring房间的大类名称
roomNamestring房间名称

请求示例

curl -i -H "Authorization: Bearer e447e4b4b8e23973b42c44b8d5415603" "https://api.ecnu.edu.cn/api/v1/asset/roomdoors?pageSize=1&pageNum=1"

返回示例

json
{
	"data": {
		"totalNum": 83440,
		"pageSize": 1,
		"rows": [{
			"siteName": "普陀校区",
			"buildingId": "1",
			"buildingName": "****",
			"floor": "F01",
			"doorUUID": "01_****",
			"doorId": "101",
			"roomId": "101",
			"buildingArea": 28.67,
			"usableArea": 28.67,
			"dvId": "****",
			"dvName": "****",
			"dpId": "****",
			"dpName": "****",
			"dvManage": "****",
			"roomType": "****",
			"roomTypeName": "****",
			"roomCatType": "****",
			"roomCatName": "****",
			"roomUseType": "****",
			"roomUseName": "****",
			"roomName": "****"
		}],
		"pageNum": 1
	},
	"errCode": 0,
	"requestId": "621FBD89-69F7-40C1-803C-4F66E5AED213",
	"errMsg": "success"
}