connectbase-client 5.0.0 → 5.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,45 @@
3
3
  본 SDK 의 모든 주요 변경사항을 [Keep a Changelog](https://keepachangelog.com/ko/1.1.0/) 형식으로 기록합니다.
4
4
  버전은 [Semantic Versioning](https://semver.org/lang/ko/) 을 따릅니다.
5
5
 
6
+ ## [5.1.0] - 2026-07-30
7
+
8
+ ### Added — 앱 멤버 관리자 조회 `cb.appMembers` (이메일 포함)
9
+
10
+ 앱 소유자가 자기 앱 멤버의 이메일을 조회할 경로가 없었다 (platform-issue 019fb13c). 플랫폼은
11
+ 이메일을 보관하는데(RLS `auth.email`, 본인 `getMe().email`) 관리자 방향 읽기 경로에서만 빠져
12
+ 있었다. `cb.appMembers.list()` / `cb.appMembers.get()` 을 추가했다.
13
+
14
+ ```typescript
15
+ // service_role 함수 안에서 (management_scopes: ["app_member:read"])
16
+ // 문의로 들어온 이메일이 어느 회원인지 대조
17
+ const found = await ctx.cbAdmin.appMembers.list(ctx.appId, { search: 'user@example.com' })
18
+ console.log(found.total_count, found.app_members[0]?.email, found.app_members[0]?.nickname)
19
+
20
+ // 자체 어드민 회원 목록
21
+ const page = await ctx.cbAdmin.appMembers.list(ctx.appId, { page: 1, pageSize: 50 })
22
+
23
+ // 회원 상세 — 로그인 수단까지
24
+ const detail = await ctx.cbAdmin.appMembers.get(ctx.appId, found.app_members[0].id)
25
+ console.log(detail.email, detail.identities.map((i) => i.type)) // ['GOOGLE']
26
+ ```
27
+
28
+ - **서버사이드 전용**: 콘솔 JWT 또는 service_role 함수(`ctx.cbAdmin`)가 필요하다. Public Key
29
+ (`cb_pk_`) 단독 브라우저 인스턴스에서 호출하면 던진다 — 다른 회원의 개인정보를 클라이언트에서
30
+ 읽는 경로를 만들지 않기 위한 의도적 제약이다. 멤버가 **자기** 정보를 볼 때는 `cb.auth.getMe()`.
31
+ - service_role 함수에서 쓰려면 함수 `management_scopes` 에 **`app_member:read`** 를 opt-in 한다
32
+ (신규 스코프). 이메일을 열어주므로 어드민/CS 흐름에만 부여할 것.
33
+ - `search` 는 **닉네임 · 이메일 · 로그인 identity(email/username)** 를 함께 부분 일치(대소문자
34
+ 무시)한다. `total_count` 도 이 필터를 반영한다.
35
+ - `email` 은 `app_members.email` 컬럼 우선, 비어 있으면 EMAIL identity 의 `provider_uid` 로
36
+ fallback 한다(backfill 이전 가입 멤버). 이메일이 정말 없는 멤버는 빈 문자열이다.
37
+ - 쓰기(생성/삭제/정지/수정)와 활동 로그 조회는 콘솔 전용이라 이 스코프로 열리지 않는다.
38
+
39
+ 새 타입: `AppMemberList`, `AppMemberListItem`, `AppMemberDetail`, `AppMemberIdentitySummary`,
40
+ `AppMemberIdentityDetail`, `AppMemberProviderType`, `ListAppMembersOptions`.
41
+
42
+ 관련 MCP 도구 `list_members` / `get_member` 도 같은 데이터를 돌려주며, `list_members` 에
43
+ `search` 인자가 추가됐다.
44
+
6
45
  ## [5.0.0] - 2026-07-27
7
46
 
8
47
  ### BREAKING — AI 스트리밍 `onError` 가 문자열이 아닌 `AIError` 객체를 전달