English
List Visible Knowledge Spaces
About 422 wordsAbout 1 min
2026-09-14
Description
Queries the knowledge spaces visible to the current user (with VIEW permission or above). The knowledge base is organized into three levels — knowledge space, knowledge folder, and knowledge entry: a space is the top-level container, holding multi-level folders to which knowledge entries belong. A typical integration flow starts with this API to obtain spaces, then drills down into folders and entries.
Request Specification
HTTP Method: POST + application/json
Request Path: https://${Cloud Domain}/cgi/crm/v2/knowledge/space/list?thirdTraceId=${Random String}
Request Headers: Refer to Common Parameters
Request Parameters
This API has no business parameters; pass an empty object in data.
Request Example
{
"data": {}
}Response Parameters
| Parameter | Type | Description |
|---|---|---|
| traceId | string | Unique request ID |
| errorDescription | string | Error description |
| errorMessage | string | Error message |
| errorCode | Int | Error Codes |
| data | object | Response data |
| spaces | Array | Knowledge spaces visible to the current user |
| spaces[].spaceId | String | Space ID |
| spaces[].name | String | Space name |
| spaces[].description | String | Space description |
| spaces[].coverImage | Array | Cover image list with a non-fixed element structure (display purposes only); an empty array [] when there is no cover |
| spaces[].spaceType | String | Space product type |
| spaces[].spaceChannel | String | Space channel |
| spaces[].spaceScope | String | Space scope: personal or enterprise |
| spaces[].order | Int | Sort order |
| spaces[].state | String | Space state |
| spaces[].permission | String | The current user's permission level on the space; see Query Effective Permission of a Resource for values |
| spaces[].createTime | Long | Creation time, in milliseconds |
| spaces[].updateTime | Long | Update time, in milliseconds |
Response Example
{
"traceId": "E-O.fktest4234.1000-20260914115000-xxxxxx",
"errorDescription": "success",
"errorMessage": "success",
"errorCode": 0,
"data": {
"spaces": [
{
"spaceId": "space-001",
"name": "Product Knowledge Base",
"description": "Product materials",
"coverImage": [],
"spaceType": "1",
"spaceChannel": "enterprise",
"spaceScope": "enterprise",
"order": 1,
"state": "1",
"permission": "VIEW",
"createTime": 1757772000000,
"updateTime": 1757772000000
}
]
}
}Notes
- Only spaces on which the current user has VIEW permission or above are returned;
spacesis an empty array when none is visible. The first call may automatically initialize the current user's personal knowledge space. - This API returns all visible spaces at once without pagination. Enterprise spaces come first, followed by personal spaces; within each group the order is ascending by
order. - Use
spaceScopeto distinguish personal spaces from enterprise spaces; do not rely onspaceType. - Do not use the message field in the response for logical judgment, as errorMessage may change.
