본문으로 건너뛰기

멤버

워크스페이스에 속한 멤버(상담원·관리자) 정보를 조회합니다. id는 membership UUID이며, 활성(소프트 삭제되지 않은) 멤버십·계정만 노출됩니다. 이는 온라인 상태(status)와 무관합니다 — 휴가·근무 외 멤버도 포함됩니다. emaillast_login_at은 의도적으로 포함되며, is_super_admin·locale·서명 등 내부 필드는 노출되지 않습니다.

목록 조회

GET /members — 멤버 목록을 cursor pagination으로 조회합니다.

  • Scope: members:read
  • 쿼리: limit(기본 50, 최대 100), cursor

limit[1, 100] 범위를 벗어나면 400 INVALID_QUERY를 반환하며 자동 보정하지 않습니다. cursor는 발급 후 24시간이 지나면 만료됩니다. 정렬은 created_at 내림차순입니다.

curl "https://api.talk.zeroworks.ai/api/public/v1/members?limit=50" \
-H "Authorization: Bearer ztpat_..."

응답

{
"success": true,
"data": [
{
"id": "9b1c2d3e-...",
"email": "agent@example.com",
"name": "김상담",
"role": "agent",
"status": "active",
"last_login_at": "2026-05-01T09:30:00Z",
"created_at": "2026-01-01T00:00:00Z",
"updated_at": "2026-05-01T09:30:00Z"
}
],
"meta": { "has_more": true, "next_cursor": "eyJ..." }
}

last_login_at은 해당 계정의 인증 수단 중 가장 최근 로그인 시각입니다. avatar_url·last_login_at은 값이 없으면 null이 아니라 키가 생략됩니다 ("key" in obj로 판별).

role은 멤버십 권한이며 다음 닫힌 집합 중 하나입니다: owner·admin·agent·viewer. (bot은 멤버십 행이 아니므로 이 엔드포인트에서 반환되지 않습니다.)

status는 멤버의 온라인 접속 상태입니다(멤버십 활성 여부가 아님). 다음 닫힌 집합 중 하나입니다: active(접속)·away(자리 비움)·vacation(휴가)·off_duty(근무 외).

단건 조회

GET /members/{id} — 단일 멤버를 조회합니다. {id}는 membership UUID입니다.

  • Scope: members:read
curl "https://api.talk.zeroworks.ai/api/public/v1/members/9b1c2d3e-..." \
-H "Authorization: Bearer ztpat_..."

응답

{
"success": true,
"data": {
"id": "9b1c2d3e-...",
"email": "agent@example.com",
"name": "김상담",
"role": "agent",
"status": "active",
"last_login_at": "2026-05-01T09:30:00Z",
"created_at": "2026-01-01T00:00:00Z",
"updated_at": "2026-05-01T09:30:00Z"
}
}

ID 형식이 올바르지 않으면 400 INVALID_INPUT, 워크스페이스에 해당 멤버가 없으면 404 NOT_FOUND를 반환합니다.