Get the information of a specified space by spaceId
Request
Basic information
| Field | Value |
|---|---|
| HTTP URL | https://api.dingtalk.io/v1.0/drive/managements/spaces/query |
| HTTP Method | POST |
| Supported app types | appType-Internal app appType-Third-party enterprise app |
| Permission requirements | permission-Drive.SpaceManage.Read-Read permission for Drive app space management information |
Request header
| Name | Type | Required | Description |
|---|---|---|---|
| x-acs-dingtalk-access-token | String | Yes | The access credential for calling this API. Obtain it in one of the following ways: - For an internal app, call the Get the access token of an internal app API. - For a third-party enterprise app, call the Get the access token of an organization authorized to a third-party app API. |
Request body
| Name | Type | Required | Description |
|---|---|---|---|
| spaceIds | Array of String | Yes | The list of space IDs. You can pass in up to 30 IDs. Call the Get the space list API to obtain them. |
| unionId | String | Yes | The unionId of the user. Call the Query user details API to obtain it. |
Request example
HTTPResponse
Response body
| Name | Type | Description |
|---|---|---|
| spaces | Array | The list of spaces. |
| spaceId | String | The space ID. |
| spaceName | String | The space name. |
| spaceType | String | The space type. - personal: Personal space - org: Organization space |
| quota | Long | The total quota of the space. - -1: The space quota is unlimited. If the space has organization attributes, it cannot exceed the organization space quota. |
| usedQuota | Long | The used quota of the space. |
| permissionMode | String | The authorization mode. Valid values: - acl: ACL authorization - custom: Custom authorization |
| createTime | String | The created time, in ISO 8601 format, for example, 2022-07-29T14:55Z. |
| modifyTime | String | The modified time, in ISO 8601 format, for example, 2022-07-29T14:55Z. |
Response body example
Error codes
If an error occurs when calling this API, find the solution by error message in the Global error codes documentation.| HttpCode | Error code | Error message | Description |
|---|---|---|---|
| 400 | param.error | Invalid Param | Parameter error |
| 500 | request.overlimit | You have sent too many requests. | Requests are too frequent |
| 500 | unsupported.operation | Does not support the operation | This operation is not supported |
| 500 | no.priviledge | You are not authorized to perform this operation. | You are not authorized to perform this operation |
| 500 | unknown.error | Unknown Error | Unknown error |