List Members¶
GET /api/v1/workspace/members/list
Overview¶
Retrieves active members in the current Workspace, along with direct and inherited roles and the personal API Key switch, in a paginated manner.
Before Calling and Usage Steps¶
Defaults are pageIndex=1 and pageSize=10, sorted by account name. The results include direct members and members added through management backend account groups; roles are located in roles, mgroups[].roles, and member_group[].roles, respectively. Read the account array from content.data and pagination from the top-level pageInfo. Use uuid to prepare parameters for APIs such as owner, @member, and role modification; email is not a common account ID for these APIs. All operations apply to the Workspace to which the current DF-API-KEY belongs. To access another Workspace, use the corresponding Key and site Endpoint.
Request Headers¶
| Parameter | Type | Required | Description |
|---|---|---|---|
| DF-API-KEY | string | Y | Workspace OpenAPI authentication credential. Example: <DF-API-KEY>How to obtain or enter: Obtain an OpenAPI Key with the required permission from API Key management in the target Workspace. |
Query Request Parameters¶
| Parameter | Type | Required | Description |
|---|---|---|---|
| search | string | Fuzzy search by name/email/Workspace nickname. Null allowed: False Example: oncallHow to obtain or enter: Enter text from the account name, email, or nickname in this Workspace; omit or leave blank to not filter. Nicknames can be searched, but this public list does not always return this field. |
|
| pageIndex | integer | Page number. Defaults to 1; minimum 1. Null allowed: False $minValue: 1 Example: 1How to obtain or enter: The first page is 1; increase page by page thereafter. |
|
| pageSize | integer | Number of entries per page. Defaults to 10. Null allowed: False $minValue: 1 $maxValue: 100 Example: 10How to obtain or enter: Select an integer from 1 to 100 as needed. |
Additional Parameter Notes¶
This public API returns account and role information and excludes passwords, MFA secrets, and primary mobile numbers. Do not apply additional fields from the frontend Members page: for example, information such as pending approval and recent Key calls on the frontend is not a fixed output of this API.
Request Example¶
curl --get 'https://openapi.guance.com/api/v1/workspace/members/list' \
-H 'DF-API-KEY: <DF-API-KEY>' \
--data-urlencode pageIndex=1 \
--data-urlencode pageSize=10
Response¶
HTTP 200, application/json. The example below shows the main fields that can be read directly.
| Field | Type | Description |
|---|---|---|
| content.data | array<object> |
Members on the current page; [] if there are no results. |
| content.data[].id | integer | Site account record ID; use uuid when calling other APIs. |
| content.data[].uuid | string | Account UUID, an account identifier such as acnt_. |
| content.data[].status | integer | Site account status; this list queries only active accounts. |
| content.data[].creator | string | Identity that created the account. |
| content.data[].updator | string | Identity that most recently updated the account. |
| content.data[].createAt | integer | Account creation time, in Unix seconds. |
| content.data[].updateAt | integer | Account update time, in Unix seconds; can be -1 if not updated. |
| content.data[].deleteAt | integer | Account deletion time, in Unix seconds; -1 if not deleted. |
| content.data[].name | string | Account name. |
| content.data[].username | string | Login username. |
| content.data[].email | string | Account email. |
| content.data[].countryCode | string | Account phone country/region code. |
| content.data[].exterId | string | External account identifier. |
| content.data[].source | string | Account source. For example, agent indicates an agent account; other values are provided according to the registration/sync source. |
| content.data[].nameSpace | string | Identity namespace. It is empty for regular accounts, and is the corresponding identity source identifier for SSO accounts. |
| content.data[].userType | string | common when nameSpace is empty; otherwise saml. |
| content.data[].extend | object | Extended account information; the structure is provided by the account source. |
| content.data[].extend.user_icon | string | Avatar resource or URL when present, used to generate userIconUrl. |
| content.data[].extend.Other fields | JSON | Other extended attributes defined by the account source. |
| content.data[].userIconUrl | string or null | Generated avatar URL; null when there is no avatar. |
| content.data[].isUsed | boolean or integer | Record flag indicating whether the account has ever been used. |
| content.data[].agreeTerms | integer | Account terms acknowledgment flag. |
| content.data[].canaryPublic | boolean | Account public canary flag. |
| content.data[].enableMFA | boolean | Whether MFA is enabled for the account. |
| content.data[].language | string | Account language preference. |
| content.data[].tokenHoldTime | integer | Login session retention duration for the account, in seconds; special values are provided according to the account configuration. |
| content.data[].tokenMaxValidDuration | integer | Maximum login session validity period, in seconds; special values are provided according to the account configuration. |
| content.data[].timezone | string | Account time zone. |
| content.data[].attributes | object or array | Identity source attributes. |
| content.data[].attributes.Custom fields | JSON | Attributes defined by the identity source. |
| content.data[].customAttributes | object or array | Custom account attributes. |
| content.data[].customAttributes.Custom fields | JSON | Custom attribute values. |
| content.data[].statusPageSubs | integer | Status Page subscription flag. |
| content.data[].defaultWorkspace | string | Default Workspace identifier for the account. |
| content.data[].brandKey | string | Account brand identifier. |
| content.data[].scheduleMobile | string | Mobile contact for the account's notification schedule; may be empty. |
| content.data[].scheduleEmail | string | Email contact for the account's notification schedule; may be empty. |
| content.data[].ifScheduleMobileEnable | boolean | Whether the scheduled mobile contact is enabled. |
| content.data[].ifScheduleEmailEnable | boolean | Whether the scheduled email contact is enabled. |
| content.data[].accountStatus | string | Extended status provided by the account source. |
| content.data[].roles | array<object> |
Summary of directly associated Workspace roles; for inherited roles, see mgroups and member_group separately. |
| content.data[].roles[].uuid | string | Role UUID. |
| content.data[].roles[].name | string | Role display name. |
| content.data[].mgroups | array<object> |
Groups joined/authorized through management backend account groups. |
| content.data[].mgroups[].uuid | string | Management account group UUID. |
| content.data[].mgroups[].name | string | Management account group name. |
| content.data[].mgroups[].roles | array<object> |
Roles granted by this management group in this Workspace. |
| content.data[].mgroups[].roles[].uuid | string | Role UUID. |
| content.data[].mgroups[].roles[].name | string | Role display name. |
| content.data[].member_group | array<object> |
Teams the account belongs to in this Workspace. |
| content.data[].member_group[].uuid | string | Team UUID. |
| content.data[].member_group[].name | string | Team name. |
| content.data[].member_group[].roles | array<object> |
Summary of roles granted by the team in this Workspace. |
| content.data[].member_group[].roles[].uuid | string | Role UUID. |
| content.data[].member_group[].roles[].name | string | Role display name. |
| content.data[].enablePersonalAPIKey | integer | Personal API Key usage switch in the current Workspace: 1 enabled, 0 disabled. Calculated by combining direct roles and roles inherited from groups; owner is always 1, wsAdmin defaults to 1 when there is no explicit configuration, and others default to 0. |
| content.declaration | object or null | Workspace shared declaration; not recursively inserted into each account. |
| pageInfo | object | Top-level pagination information. |
| pageInfo.pageIndex | integer | Page number. |
| pageInfo.pageSize | integer | Page capacity. |
| pageInfo.count | integer | Number of items actually returned on the current page. |
| pageInfo.totalCount | integer | Total number of matching accounts. |
{
"code": 200,
"content": {
"data": [
{
"id": 101,
"uuid": "acnt_example",
"name": "On-call Engineer",
"username": "xxx@guance.com",
"email": "xxx@guance.com",
"status": 0,
"creator": "SYS",
"updator": "",
"createAt": 1785430800,
"updateAt": -1,
"deleteAt": -1,
"nameSpace": "",
"userType": "common",
"source": "local",
"countryCode": "",
"exterId": "",
"extend": {},
"userIconUrl": null,
"isUsed": 1,
"agreeTerms": 1,
"canaryPublic": false,
"enableMFA": false,
"language": "zh",
"tokenHoldTime": 3600,
"tokenMaxValidDuration": 86400,
"timezone": "Asia/Shanghai",
"attributes": {},
"customAttributes": {},
"statusPageSubs": 0,
"defaultWorkspace": "wksp_example",
"brandKey": "guance",
"scheduleMobile": "",
"scheduleEmail": "",
"ifScheduleMobileEnable": false,
"ifScheduleEmailEnable": false,
"accountStatus": "",
"roles": [
{
"uuid": "readOnly",
"name": "Read-only Member"
}
],
"mgroups": [],
"member_group": [],
"enablePersonalAPIKey": 0
}
],
"declaration": {}
},
"errorCode": "",
"message": "",
"success": true,
"traceId": "TRACE-EXAMPLE",
"pageInfo": {
"pageIndex": 1,
"pageSize": 10,
"count": 1,
"totalCount": 1
}
}
Error Responses¶
For authentication, rate limiting, and common request errors, see Common Error Definitions.
| HTTP Status | errorCode | Trigger Condition | Message or Response Description | Resolution |
|---|---|---|---|---|
| 406 | ft.ParameterValidationFailed | A request field is missing, or a field value violates the declared validation conditions | Parameter parsing failed | Verify the parameter location, field name, type, and value. |
| 500 | ft.InternalServerError | Failed to read member profile or associated roles | Internal error | Retry later; if the failure persists, provide the traceId. |