@passflow/core 0.49.0 → 0.49.2

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.cts CHANGED
@@ -2258,27 +2258,36 @@ export type PassflowInvitePayload = {
2258
2258
  invite_token: string;
2259
2259
  scopes: string[];
2260
2260
  };
2261
+ /**
2262
+ * One member of a tenant group, as listed in `PassflowTenantResponse.users_in_groups`:
2263
+ * the user's profile fields plus the roles the user holds in that group.
2264
+ */
2261
2265
  export type PassflowUserWithRoles = {
2262
- user_id: string;
2263
- username: string;
2264
- email: string;
2265
- phone_number: string;
2266
- tenant_id: string;
2267
- group_id: string;
2268
- role_id: string;
2266
+ id: string;
2267
+ username?: string;
2268
+ email?: string;
2269
+ /** Always present; an empty string when the user has no phone number. */
2270
+ phone?: string;
2269
2271
  preferred_username?: string;
2270
2272
  given_name?: string;
2273
+ middle_name?: string;
2271
2274
  family_name?: string;
2272
2275
  nickname?: string;
2273
2276
  picture?: string;
2274
- roles: {
2277
+ email_verified?: boolean;
2278
+ phone_verified?: boolean;
2279
+ /** Maps role id to role name. Absent when the user has no role in the group. */
2280
+ roles?: {
2275
2281
  [role_id: string]: string;
2276
2282
  };
2283
+ /** How the user entered the tenant, e.g. `owner`, `invite`, `auto_join`. Absent for older memberships. */
2284
+ joined_via?: string;
2277
2285
  };
2278
2286
  export type PassflowGroup = {
2279
2287
  id: string;
2280
2288
  name: string;
2281
- default: boolean;
2289
+ /** True for the tenant's default group. Absent when false. */
2290
+ default?: boolean;
2282
2291
  updated_at: string;
2283
2292
  created_at: string;
2284
2293
  };
@@ -2290,12 +2299,14 @@ export type PassflowRole = {
2290
2299
  export type PassflowTenantResponse = {
2291
2300
  tenant_id: string;
2292
2301
  tenant_name: string;
2293
- users_in_groups?: PassflowUserInGroup[];
2302
+ /** Maps group id to the members of that group. Absent when the tenant has no members. */
2303
+ users_in_groups?: Record<string, PassflowUserWithRoles[]>;
2294
2304
  groups?: PassflowGroup[];
2295
2305
  roles?: PassflowRole[];
2296
2306
  };
2297
2307
  /**
2298
- * Represents a user's membership in a group with their assigned roles
2308
+ * @deprecated The server never sends this shape: `users_in_groups` maps a group id to
2309
+ * `PassflowUserWithRoles[]`.
2299
2310
  */
2300
2311
  export type PassflowUserInGroup = {
2301
2312
  user: {
@@ -5413,6 +5424,7 @@ export declare class InvitationService {
5413
5424
  */
5414
5425
  export interface User {
5415
5426
  id: string;
5427
+ /** Display name: preferred username, else given and family name, else nickname, else username. */
5416
5428
  name: string | null;
5417
5429
  email: string | null;
5418
5430
  phone: string | null;
package/dist/index.d.ts CHANGED
@@ -2258,27 +2258,36 @@ export type PassflowInvitePayload = {
2258
2258
  invite_token: string;
2259
2259
  scopes: string[];
2260
2260
  };
2261
+ /**
2262
+ * One member of a tenant group, as listed in `PassflowTenantResponse.users_in_groups`:
2263
+ * the user's profile fields plus the roles the user holds in that group.
2264
+ */
2261
2265
  export type PassflowUserWithRoles = {
2262
- user_id: string;
2263
- username: string;
2264
- email: string;
2265
- phone_number: string;
2266
- tenant_id: string;
2267
- group_id: string;
2268
- role_id: string;
2266
+ id: string;
2267
+ username?: string;
2268
+ email?: string;
2269
+ /** Always present; an empty string when the user has no phone number. */
2270
+ phone?: string;
2269
2271
  preferred_username?: string;
2270
2272
  given_name?: string;
2273
+ middle_name?: string;
2271
2274
  family_name?: string;
2272
2275
  nickname?: string;
2273
2276
  picture?: string;
2274
- roles: {
2277
+ email_verified?: boolean;
2278
+ phone_verified?: boolean;
2279
+ /** Maps role id to role name. Absent when the user has no role in the group. */
2280
+ roles?: {
2275
2281
  [role_id: string]: string;
2276
2282
  };
2283
+ /** How the user entered the tenant, e.g. `owner`, `invite`, `auto_join`. Absent for older memberships. */
2284
+ joined_via?: string;
2277
2285
  };
2278
2286
  export type PassflowGroup = {
2279
2287
  id: string;
2280
2288
  name: string;
2281
- default: boolean;
2289
+ /** True for the tenant's default group. Absent when false. */
2290
+ default?: boolean;
2282
2291
  updated_at: string;
2283
2292
  created_at: string;
2284
2293
  };
@@ -2290,12 +2299,14 @@ export type PassflowRole = {
2290
2299
  export type PassflowTenantResponse = {
2291
2300
  tenant_id: string;
2292
2301
  tenant_name: string;
2293
- users_in_groups?: PassflowUserInGroup[];
2302
+ /** Maps group id to the members of that group. Absent when the tenant has no members. */
2303
+ users_in_groups?: Record<string, PassflowUserWithRoles[]>;
2294
2304
  groups?: PassflowGroup[];
2295
2305
  roles?: PassflowRole[];
2296
2306
  };
2297
2307
  /**
2298
- * Represents a user's membership in a group with their assigned roles
2308
+ * @deprecated The server never sends this shape: `users_in_groups` maps a group id to
2309
+ * `PassflowUserWithRoles[]`.
2299
2310
  */
2300
2311
  export type PassflowUserInGroup = {
2301
2312
  user: {
@@ -5413,6 +5424,7 @@ export declare class InvitationService {
5413
5424
  */
5414
5425
  export interface User {
5415
5426
  id: string;
5427
+ /** Display name: preferred username, else given and family name, else nickname, else username. */
5416
5428
  name: string | null;
5417
5429
  email: string | null;
5418
5430
  phone: string | null;