@aiquants/auth-core 0.4.0 → 0.6.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/dist/index.d.mts +46 -1
- package/dist/index.d.ts +46 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -258,6 +258,43 @@ type AuthAllowlistEntry = (AuthAllowlistEntryBase & {
|
|
|
258
258
|
groupKey: string;
|
|
259
259
|
groupName: string;
|
|
260
260
|
});
|
|
261
|
+
/**
|
|
262
|
+
* One group as the upstream directory reports it. 上流ディレクトリが報告するグループ 1 件。
|
|
263
|
+
*
|
|
264
|
+
* ⚠️ **この形はディレクトリ連携の境界を 3 つ跨ぐ** — 上流アダプタが読み、永続化層が書き、管理 UI が
|
|
265
|
+
* 描く。各層で「同じ意味の別の型」を宣言すると、どの境界も構造的部分型で通ってしまい、**上流へ足した
|
|
266
|
+
* 欄が途中の層で黙って捨てられる**。コンパイラも型検査も何も言わない (実測: 必須欄を足しても
|
|
267
|
+
* `tsc --strict` は両方の境界で 0 を返す)。だから定義はここ 1 つに置き、各層はこれを import する。
|
|
268
|
+
*
|
|
269
|
+
* 正準キーは {@link externalId} である。{@link externalKey} は改名され得るため、比較にも保存にも
|
|
270
|
+
* 第一キーとして使ってはならない。
|
|
271
|
+
*/
|
|
272
|
+
type AuthDirectoryCatalogGroup = {
|
|
273
|
+
/** Stable upstream identifier. 上流の安定識別子。 */
|
|
274
|
+
externalId: string;
|
|
275
|
+
/** Operator-facing key such as the group address. 運用者向けキー (グループアドレス等)。 */
|
|
276
|
+
externalKey: string;
|
|
277
|
+
/** Display name as the upstream reports it. 上流が報告する表示名。 */
|
|
278
|
+
name: string;
|
|
279
|
+
/** Free-form description, when the upstream carries one. 上流が持つ場合の説明文。 */
|
|
280
|
+
description?: string;
|
|
281
|
+
/** Members the upstream reports for the group. 上流が報告するメンバー数。 */
|
|
282
|
+
memberCount?: number;
|
|
283
|
+
};
|
|
284
|
+
/**
|
|
285
|
+
* An upstream group list together with when the upstream was actually observed.
|
|
286
|
+
* 上流のグループ一覧と、上流を実際に観測した時刻。
|
|
287
|
+
*
|
|
288
|
+
* ⚠️ **時刻は省略できない。** この一覧は上流を直に叩いた結果とは限らず、資格情報を持つ別プロセスが
|
|
289
|
+
* 書いた **写し** であることが多い。時刻を伴わない一覧は「上流の現在」と読まれ、既に消えたグループを
|
|
290
|
+
* 選ばせる。`observedAt` が `null` は **一度も観測していない** ことを意味し、`groups` が空であることとは
|
|
291
|
+
* 独立である — 観測できて中身が空だった配備 (借用先の権限が狭い等) を「同期が動いていない」と
|
|
292
|
+
* 誤診させないため、2 つは必ず別々に運ぶ。
|
|
293
|
+
*/
|
|
294
|
+
type AuthDirectoryCatalogSnapshot = {
|
|
295
|
+
groups: AuthDirectoryCatalogGroup[];
|
|
296
|
+
observedAt: Date | null;
|
|
297
|
+
};
|
|
261
298
|
/**
|
|
262
299
|
* Health of the external directory synchronization, surfaced in the admin UI.
|
|
263
300
|
* 管理 UI に表示する外部ディレクトリ同期の健全性。
|
|
@@ -269,6 +306,14 @@ type AuthAllowlistEntry = (AuthAllowlistEntryBase & {
|
|
|
269
306
|
type AuthDirectoryStatus = {
|
|
270
307
|
/** False when directory integration is not wired for this deployment. 未結線なら false。 */
|
|
271
308
|
isEnabled: boolean;
|
|
309
|
+
/**
|
|
310
|
+
* Upstream system this deployment synchronizes against, e.g. `"google"`. 同期先の上流システム。
|
|
311
|
+
*
|
|
312
|
+
* 新しい連携を作る面は、どの上流へ繋ぐのかを **設定から** 受け取る必要がある。UI 側に
|
|
313
|
+
* 特定の供給元を焼き込むと、別の上流を使う配備では作った連携が同期側で
|
|
314
|
+
* 「別プロバイダ」として恒久的に拒否され、赤いバナーとしてしか現れない。
|
|
315
|
+
*/
|
|
316
|
+
provider: string;
|
|
272
317
|
/** Number of groups whose membership is externally sourced. 外部供給グループの件数。 */
|
|
273
318
|
linkedGroupCount: number;
|
|
274
319
|
/**
|
|
@@ -298,4 +343,4 @@ type AuthDirectoryStatus = {
|
|
|
298
343
|
pendingRequestCount: number;
|
|
299
344
|
};
|
|
300
345
|
|
|
301
|
-
export { type AuthAllowlistEntry, type AuthAllowlistOwner, type AuthDirectoryMembershipMode, type AuthDirectoryStatus, type AuthGroup, type AuthGroupExternalLink, type AuthGroupMember, type AuthMessages, type AuthUser, type AuthenticationPayload, type GoogleProfileBase, type MyGoogleProfile, type SessionProfile, defaultAuthMessages, emailDomainAllowlist, normalizeAuthEmail, parseAllowlistCsv, resolveAuthMessages };
|
|
346
|
+
export { type AuthAllowlistEntry, type AuthAllowlistOwner, type AuthDirectoryCatalogGroup, type AuthDirectoryCatalogSnapshot, type AuthDirectoryMembershipMode, type AuthDirectoryStatus, type AuthGroup, type AuthGroupExternalLink, type AuthGroupMember, type AuthMessages, type AuthUser, type AuthenticationPayload, type GoogleProfileBase, type MyGoogleProfile, type SessionProfile, defaultAuthMessages, emailDomainAllowlist, normalizeAuthEmail, parseAllowlistCsv, resolveAuthMessages };
|
package/dist/index.d.ts
CHANGED
|
@@ -258,6 +258,43 @@ type AuthAllowlistEntry = (AuthAllowlistEntryBase & {
|
|
|
258
258
|
groupKey: string;
|
|
259
259
|
groupName: string;
|
|
260
260
|
});
|
|
261
|
+
/**
|
|
262
|
+
* One group as the upstream directory reports it. 上流ディレクトリが報告するグループ 1 件。
|
|
263
|
+
*
|
|
264
|
+
* ⚠️ **この形はディレクトリ連携の境界を 3 つ跨ぐ** — 上流アダプタが読み、永続化層が書き、管理 UI が
|
|
265
|
+
* 描く。各層で「同じ意味の別の型」を宣言すると、どの境界も構造的部分型で通ってしまい、**上流へ足した
|
|
266
|
+
* 欄が途中の層で黙って捨てられる**。コンパイラも型検査も何も言わない (実測: 必須欄を足しても
|
|
267
|
+
* `tsc --strict` は両方の境界で 0 を返す)。だから定義はここ 1 つに置き、各層はこれを import する。
|
|
268
|
+
*
|
|
269
|
+
* 正準キーは {@link externalId} である。{@link externalKey} は改名され得るため、比較にも保存にも
|
|
270
|
+
* 第一キーとして使ってはならない。
|
|
271
|
+
*/
|
|
272
|
+
type AuthDirectoryCatalogGroup = {
|
|
273
|
+
/** Stable upstream identifier. 上流の安定識別子。 */
|
|
274
|
+
externalId: string;
|
|
275
|
+
/** Operator-facing key such as the group address. 運用者向けキー (グループアドレス等)。 */
|
|
276
|
+
externalKey: string;
|
|
277
|
+
/** Display name as the upstream reports it. 上流が報告する表示名。 */
|
|
278
|
+
name: string;
|
|
279
|
+
/** Free-form description, when the upstream carries one. 上流が持つ場合の説明文。 */
|
|
280
|
+
description?: string;
|
|
281
|
+
/** Members the upstream reports for the group. 上流が報告するメンバー数。 */
|
|
282
|
+
memberCount?: number;
|
|
283
|
+
};
|
|
284
|
+
/**
|
|
285
|
+
* An upstream group list together with when the upstream was actually observed.
|
|
286
|
+
* 上流のグループ一覧と、上流を実際に観測した時刻。
|
|
287
|
+
*
|
|
288
|
+
* ⚠️ **時刻は省略できない。** この一覧は上流を直に叩いた結果とは限らず、資格情報を持つ別プロセスが
|
|
289
|
+
* 書いた **写し** であることが多い。時刻を伴わない一覧は「上流の現在」と読まれ、既に消えたグループを
|
|
290
|
+
* 選ばせる。`observedAt` が `null` は **一度も観測していない** ことを意味し、`groups` が空であることとは
|
|
291
|
+
* 独立である — 観測できて中身が空だった配備 (借用先の権限が狭い等) を「同期が動いていない」と
|
|
292
|
+
* 誤診させないため、2 つは必ず別々に運ぶ。
|
|
293
|
+
*/
|
|
294
|
+
type AuthDirectoryCatalogSnapshot = {
|
|
295
|
+
groups: AuthDirectoryCatalogGroup[];
|
|
296
|
+
observedAt: Date | null;
|
|
297
|
+
};
|
|
261
298
|
/**
|
|
262
299
|
* Health of the external directory synchronization, surfaced in the admin UI.
|
|
263
300
|
* 管理 UI に表示する外部ディレクトリ同期の健全性。
|
|
@@ -269,6 +306,14 @@ type AuthAllowlistEntry = (AuthAllowlistEntryBase & {
|
|
|
269
306
|
type AuthDirectoryStatus = {
|
|
270
307
|
/** False when directory integration is not wired for this deployment. 未結線なら false。 */
|
|
271
308
|
isEnabled: boolean;
|
|
309
|
+
/**
|
|
310
|
+
* Upstream system this deployment synchronizes against, e.g. `"google"`. 同期先の上流システム。
|
|
311
|
+
*
|
|
312
|
+
* 新しい連携を作る面は、どの上流へ繋ぐのかを **設定から** 受け取る必要がある。UI 側に
|
|
313
|
+
* 特定の供給元を焼き込むと、別の上流を使う配備では作った連携が同期側で
|
|
314
|
+
* 「別プロバイダ」として恒久的に拒否され、赤いバナーとしてしか現れない。
|
|
315
|
+
*/
|
|
316
|
+
provider: string;
|
|
272
317
|
/** Number of groups whose membership is externally sourced. 外部供給グループの件数。 */
|
|
273
318
|
linkedGroupCount: number;
|
|
274
319
|
/**
|
|
@@ -298,4 +343,4 @@ type AuthDirectoryStatus = {
|
|
|
298
343
|
pendingRequestCount: number;
|
|
299
344
|
};
|
|
300
345
|
|
|
301
|
-
export { type AuthAllowlistEntry, type AuthAllowlistOwner, type AuthDirectoryMembershipMode, type AuthDirectoryStatus, type AuthGroup, type AuthGroupExternalLink, type AuthGroupMember, type AuthMessages, type AuthUser, type AuthenticationPayload, type GoogleProfileBase, type MyGoogleProfile, type SessionProfile, defaultAuthMessages, emailDomainAllowlist, normalizeAuthEmail, parseAllowlistCsv, resolveAuthMessages };
|
|
346
|
+
export { type AuthAllowlistEntry, type AuthAllowlistOwner, type AuthDirectoryCatalogGroup, type AuthDirectoryCatalogSnapshot, type AuthDirectoryMembershipMode, type AuthDirectoryStatus, type AuthGroup, type AuthGroupExternalLink, type AuthGroupMember, type AuthMessages, type AuthUser, type AuthenticationPayload, type GoogleProfileBase, type MyGoogleProfile, type SessionProfile, defaultAuthMessages, emailDomainAllowlist, normalizeAuthEmail, parseAllowlistCsv, resolveAuthMessages };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aiquants/auth-core",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.0",
|
|
4
4
|
"description": "Transport-agnostic auth core: shared session/profile types, email/domain allowlist policy, and localizable auth error messages. No framework or provider SDK dependency.",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"main": "dist/index.js",
|