@seamless-auth/types 0.1.2 → 0.2.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.
Files changed (75) hide show
  1. package/CHANGELOG.md +36 -0
  2. package/README.md +30 -0
  3. package/dist/index.d.ts +15 -2
  4. package/dist/index.d.ts.map +1 -1
  5. package/dist/index.js +15 -2
  6. package/dist/index.js.map +1 -1
  7. package/dist/schemas/admin/schema.d.ts +99 -0
  8. package/dist/schemas/admin/schema.d.ts.map +1 -0
  9. package/dist/schemas/admin/schema.js +38 -0
  10. package/dist/schemas/admin/schema.js.map +1 -0
  11. package/dist/schemas/auth/auth.schema.d.ts +158 -0
  12. package/dist/schemas/auth/auth.schema.d.ts.map +1 -1
  13. package/dist/schemas/auth/auth.schema.js +82 -0
  14. package/dist/schemas/auth/auth.schema.js.map +1 -1
  15. package/dist/schemas/authEvent/schema.d.ts +251 -0
  16. package/dist/schemas/authEvent/schema.d.ts.map +1 -1
  17. package/dist/schemas/authEvent/schema.js +94 -1
  18. package/dist/schemas/authEvent/schema.js.map +1 -1
  19. package/dist/schemas/common/schema.d.ts +23 -0
  20. package/dist/schemas/common/schema.d.ts.map +1 -0
  21. package/dist/schemas/common/schema.js +19 -0
  22. package/dist/schemas/common/schema.js.map +1 -0
  23. package/dist/schemas/credential/schema.d.ts +86 -0
  24. package/dist/schemas/credential/schema.d.ts.map +1 -1
  25. package/dist/schemas/credential/schema.js +31 -3
  26. package/dist/schemas/credential/schema.js.map +1 -1
  27. package/dist/schemas/me/schema.d.ts +104 -0
  28. package/dist/schemas/me/schema.d.ts.map +1 -0
  29. package/dist/schemas/me/schema.js +24 -0
  30. package/dist/schemas/me/schema.js.map +1 -0
  31. package/dist/schemas/messaging/schema.d.ts +73 -0
  32. package/dist/schemas/messaging/schema.d.ts.map +1 -0
  33. package/dist/schemas/messaging/schema.js +63 -0
  34. package/dist/schemas/messaging/schema.js.map +1 -0
  35. package/dist/schemas/metrics/schema.d.ts +86 -0
  36. package/dist/schemas/metrics/schema.d.ts.map +1 -0
  37. package/dist/schemas/metrics/schema.js +79 -0
  38. package/dist/schemas/metrics/schema.js.map +1 -0
  39. package/dist/schemas/oauth/schema.d.ts +68 -0
  40. package/dist/schemas/oauth/schema.d.ts.map +1 -0
  41. package/dist/schemas/oauth/schema.js +43 -0
  42. package/dist/schemas/oauth/schema.js.map +1 -0
  43. package/dist/schemas/organization/schema.d.ts +228 -0
  44. package/dist/schemas/organization/schema.d.ts.map +1 -0
  45. package/dist/schemas/organization/schema.js +90 -0
  46. package/dist/schemas/organization/schema.js.map +1 -0
  47. package/dist/schemas/role/schema.d.ts +20 -0
  48. package/dist/schemas/role/schema.d.ts.map +1 -0
  49. package/dist/schemas/role/schema.js +58 -0
  50. package/dist/schemas/role/schema.js.map +1 -0
  51. package/dist/schemas/session/schema.d.ts +17 -0
  52. package/dist/schemas/session/schema.d.ts.map +1 -1
  53. package/dist/schemas/session/schema.js +7 -0
  54. package/dist/schemas/session/schema.js.map +1 -1
  55. package/dist/schemas/stepUp/schema.d.ts +31 -0
  56. package/dist/schemas/stepUp/schema.d.ts.map +1 -0
  57. package/dist/schemas/stepUp/schema.js +19 -0
  58. package/dist/schemas/stepUp/schema.js.map +1 -0
  59. package/dist/schemas/systemConfig/schema.d.ts +368 -0
  60. package/dist/schemas/systemConfig/schema.d.ts.map +1 -0
  61. package/dist/schemas/systemConfig/schema.js +141 -0
  62. package/dist/schemas/systemConfig/schema.js.map +1 -0
  63. package/dist/schemas/totp/schema.d.ts +26 -0
  64. package/dist/schemas/totp/schema.d.ts.map +1 -0
  65. package/dist/schemas/totp/schema.js +23 -0
  66. package/dist/schemas/totp/schema.js.map +1 -0
  67. package/dist/schemas/user/schema.d.ts +54 -3
  68. package/dist/schemas/user/schema.d.ts.map +1 -1
  69. package/dist/schemas/user/schema.js +34 -7
  70. package/dist/schemas/user/schema.js.map +1 -1
  71. package/dist/schemas/webauthn/schema.d.ts +61 -0
  72. package/dist/schemas/webauthn/schema.d.ts.map +1 -0
  73. package/dist/schemas/webauthn/schema.js +58 -0
  74. package/dist/schemas/webauthn/schema.js.map +1 -0
  75. package/package.json +23 -7
package/CHANGELOG.md ADDED
@@ -0,0 +1,36 @@
1
+ # @seamless-auth/types
2
+
3
+ ## 0.2.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 1ed40c9: Consolidate the domain models and API contracts that were duplicated across the
8
+ ecosystem repos into this package. New modules: `common`, `role`, `messaging`,
9
+ `systemConfig`, `oauth`, `webauthn`, `totp`, `stepUp`, `organization`, `me`,
10
+ `metrics`, and `admin`. The `user`, `credential`, `session`, `authEvent`, and
11
+ `auth` modules gained the request, response, and query schemas that consumers
12
+ were previously declaring for themselves.
13
+
14
+ Three existing schemas changed. All three accept more than they used to, so they
15
+ are not breaking at runtime, but each changes an inferred TypeScript type:
16
+ - `TransportSchema` covers the full WebAuthn `AuthenticatorTransportFuture` set.
17
+ The old enum rejected `hybrid`, which is what cross-device passkeys report.
18
+ - `CreateUserSchema` and `UpdateUserSchema` accept a null phone, matching what
19
+ the auth API already accepts.
20
+ - `OrganizationSchema` parses `createdAt` and `updatedAt` as ISO date strings
21
+ rather than `z.any()`.
22
+
23
+ `AUTH_EVENT_TYPES` now holds 74 entries: the union of the auth API's and the
24
+ admin dashboard's lists, minus the `bootstrap_admin_*` pair for functionality
25
+ that has been removed.
26
+
27
+ ### Patch Changes
28
+
29
+ - 19cc93c: Correct the published package metadata. The `exports` map now declares its `types`
30
+ condition explicitly, so consumers on `node16` or `nodenext` module resolution
31
+ resolve declarations through it rather than falling back. The `license` field uses
32
+ the current `AGPL-3.0-only` SPDX identifier instead of the deprecated `AGPL-3.0`,
33
+ and `CHANGELOG.md` ships with the package.
34
+
35
+ `npm run build` now clears `dist/` first, so a build no longer carries stale
36
+ artifacts from a previous branch into the tarball.
package/README.md CHANGED
@@ -42,6 +42,9 @@ import { UserSchema } from '@seamless-auth/types';
42
42
  const user = UserSchema.parse(data);
43
43
  ```
44
44
 
45
+ User role schemas accept plain roles such as `admin` and colon-separated scoped roles such as
46
+ `admin:read` and `admin:write`. Whitespace, underscores, slashes, and backslashes are rejected.
47
+
45
48
  ### Infer types
46
49
 
47
50
  ```ts
@@ -54,6 +57,33 @@ function handleUser(user: User) {
54
57
 
55
58
  ---
56
59
 
60
+ ## Modules
61
+
62
+ Every module is re-exported from the package root, so import from
63
+ `@seamless-auth/types` rather than a subpath.
64
+
65
+ | Module | Covers |
66
+ | -------------- | ------------------------------------------------------------------- |
67
+ | `common` | Pagination, message and error envelopes, metadata |
68
+ | `role` | Role name rules plus the scoped-role matcher (`roleGrantsAccess`) |
69
+ | `user` | User domain model, wire shape, create and update requests |
70
+ | `credential` | WebAuthn credentials and their API responses |
71
+ | `session` | Sessions and session listings |
72
+ | `authEvent` | Auth event model, the event type enum, and event queries |
73
+ | `messaging` | Email and SMS message shapes plus auth delivery instructions |
74
+ | `systemConfig` | System config, login methods, lockout policy, OAuth provider config |
75
+ | `auth` | Login, refresh, registration, OTP, magic link, and logout contracts |
76
+ | `oauth` | Public provider listings and the OAuth login handshake |
77
+ | `webauthn` | Registration and assertion request and response contracts |
78
+ | `totp` | TOTP enrollment, status, and verification |
79
+ | `stepUp` | Step-up freshness status |
80
+ | `organization` | Organizations, memberships, and the org switch response |
81
+ | `me` | The caller's own user and `GET /users/me` |
82
+ | `metrics` | Dashboard metrics, timeseries, and security anomalies |
83
+ | `admin` | Admin-only user detail, anomalies, and device replacement recovery |
84
+
85
+ ---
86
+
57
87
  ## Zod as the Source of Truth
58
88
 
59
89
  All models are defined using Zod:
package/dist/index.d.ts CHANGED
@@ -1,6 +1,19 @@
1
+ export * from './shared.js';
2
+ export * from './schemas/common/schema.js';
3
+ export * from './schemas/role/schema.js';
1
4
  export * from './schemas/user/schema.js';
2
5
  export * from './schemas/credential/schema.js';
3
- export * from './schemas/auth/auth.schema.js';
4
- export * from './schemas/authEvent/schema.js';
5
6
  export * from './schemas/session/schema.js';
7
+ export * from './schemas/authEvent/schema.js';
8
+ export * from './schemas/messaging/schema.js';
9
+ export * from './schemas/systemConfig/schema.js';
10
+ export * from './schemas/auth/auth.schema.js';
11
+ export * from './schemas/oauth/schema.js';
12
+ export * from './schemas/webauthn/schema.js';
13
+ export * from './schemas/totp/schema.js';
14
+ export * from './schemas/stepUp/schema.js';
15
+ export * from './schemas/organization/schema.js';
16
+ export * from './schemas/me/schema.js';
17
+ export * from './schemas/metrics/schema.js';
18
+ export * from './schemas/admin/schema.js';
6
19
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAC;AACzC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,6BAA6B,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAE5B,cAAc,4BAA4B,CAAC;AAC3C,cAAc,0BAA0B,CAAC;AACzC,cAAc,0BAA0B,CAAC;AACzC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,kCAAkC,CAAC;AACjD,cAAc,+BAA+B,CAAC;AAC9C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,0BAA0B,CAAC;AACzC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,kCAAkC,CAAC;AACjD,cAAc,wBAAwB,CAAC;AACvC,cAAc,6BAA6B,CAAC;AAC5C,cAAc,2BAA2B,CAAC"}
package/dist/index.js CHANGED
@@ -1,6 +1,19 @@
1
+ export * from './shared.js';
2
+ export * from './schemas/common/schema.js';
3
+ export * from './schemas/role/schema.js';
1
4
  export * from './schemas/user/schema.js';
2
5
  export * from './schemas/credential/schema.js';
3
- export * from './schemas/auth/auth.schema.js';
4
- export * from './schemas/authEvent/schema.js';
5
6
  export * from './schemas/session/schema.js';
7
+ export * from './schemas/authEvent/schema.js';
8
+ export * from './schemas/messaging/schema.js';
9
+ export * from './schemas/systemConfig/schema.js';
10
+ export * from './schemas/auth/auth.schema.js';
11
+ export * from './schemas/oauth/schema.js';
12
+ export * from './schemas/webauthn/schema.js';
13
+ export * from './schemas/totp/schema.js';
14
+ export * from './schemas/stepUp/schema.js';
15
+ export * from './schemas/organization/schema.js';
16
+ export * from './schemas/me/schema.js';
17
+ export * from './schemas/metrics/schema.js';
18
+ export * from './schemas/admin/schema.js';
6
19
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAC;AACzC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,6BAA6B,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAE5B,cAAc,4BAA4B,CAAC;AAC3C,cAAc,0BAA0B,CAAC;AACzC,cAAc,0BAA0B,CAAC;AACzC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,kCAAkC,CAAC;AACjD,cAAc,+BAA+B,CAAC;AAC9C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,0BAA0B,CAAC;AACzC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,kCAAkC,CAAC;AACjD,cAAc,wBAAwB,CAAC;AACvC,cAAc,6BAA6B,CAAC;AAC5C,cAAc,2BAA2B,CAAC"}
@@ -0,0 +1,99 @@
1
+ import { z } from 'zod';
2
+ export declare const UserIdParamSchema: z.ZodObject<{
3
+ userId: z.ZodString;
4
+ }, z.core.$strip>;
5
+ /**
6
+ * What an operator clears when a user replaces a lost device. Each step is
7
+ * opt-out rather than opt-in so a hurried recovery does not leave the old
8
+ * device's credentials in place.
9
+ */
10
+ export declare const DeviceReplacementRecoverySchema: z.ZodObject<{
11
+ revokeSessions: z.ZodDefault<z.ZodBoolean>;
12
+ removePasskeys: z.ZodDefault<z.ZodBoolean>;
13
+ disableTotp: z.ZodDefault<z.ZodBoolean>;
14
+ }, z.core.$strict>;
15
+ export type DeviceReplacementRecoveryRequest = z.infer<typeof DeviceReplacementRecoverySchema>;
16
+ export declare const DeviceReplacementRecoveryResponseSchema: z.ZodObject<{
17
+ userId: z.ZodString;
18
+ revokedSessions: z.ZodNumber;
19
+ removedCredentials: z.ZodNumber;
20
+ disabledTotpCredentials: z.ZodNumber;
21
+ }, z.core.$strip>;
22
+ export type DeviceReplacementRecoveryResponse = z.infer<typeof DeviceReplacementRecoveryResponseSchema>;
23
+ export declare const AdminUserDetailResponseSchema: z.ZodObject<{
24
+ user: z.ZodObject<{
25
+ id: z.ZodString;
26
+ email: z.ZodEmail;
27
+ phone: z.ZodNullable<z.ZodString>;
28
+ roles: z.ZodDefault<z.ZodArray<z.ZodString>>;
29
+ revoked: z.ZodOptional<z.ZodBoolean>;
30
+ emailVerified: z.ZodOptional<z.ZodBoolean>;
31
+ phoneVerified: z.ZodOptional<z.ZodBoolean>;
32
+ verified: z.ZodOptional<z.ZodBoolean>;
33
+ lastLogin: z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>>>;
34
+ createdAt: z.ZodOptional<z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>>;
35
+ updatedAt: z.ZodOptional<z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>>;
36
+ }, z.core.$strict>;
37
+ sessions: z.ZodArray<z.ZodObject<{
38
+ id: z.ZodString;
39
+ deviceName: z.ZodOptional<z.ZodNullable<z.ZodString>>;
40
+ ipAddress: z.ZodOptional<z.ZodNullable<z.ZodString>>;
41
+ userAgent: z.ZodOptional<z.ZodNullable<z.ZodString>>;
42
+ lastUsedAt: z.ZodString;
43
+ expiresAt: z.ZodString;
44
+ current: z.ZodBoolean;
45
+ }, z.core.$strip>>;
46
+ credentials: z.ZodArray<z.ZodObject<{
47
+ platform: z.ZodOptional<z.ZodNullable<z.ZodString>>;
48
+ id: z.ZodString;
49
+ browser: z.ZodOptional<z.ZodNullable<z.ZodString>>;
50
+ createdAt: z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>;
51
+ counter: z.ZodNumber;
52
+ transports: z.ZodOptional<z.ZodArray<z.ZodEnum<{
53
+ ble: "ble";
54
+ hybrid: "hybrid";
55
+ internal: "internal";
56
+ nfc: "nfc";
57
+ usb: "usb";
58
+ cable: "cable";
59
+ "smart-card": "smart-card";
60
+ }>>>;
61
+ deviceType: z.ZodOptional<z.ZodEnum<{
62
+ singleDevice: "singleDevice";
63
+ multiDevice: "multiDevice";
64
+ }>>;
65
+ friendlyName: z.ZodOptional<z.ZodNullable<z.ZodString>>;
66
+ lastUsedAt: z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>>>;
67
+ deviceInfo: z.ZodOptional<z.ZodNullable<z.ZodString>>;
68
+ backedup: z.ZodBoolean;
69
+ backedUp: z.ZodBoolean;
70
+ prfCapable: z.ZodOptional<z.ZodBoolean>;
71
+ }, z.core.$strip>>;
72
+ events: z.ZodArray<z.ZodObject<{
73
+ id: z.ZodString;
74
+ user_id: z.ZodOptional<z.ZodNullable<z.ZodString>>;
75
+ type: z.ZodString;
76
+ ip_address: z.ZodOptional<z.ZodNullable<z.ZodString>>;
77
+ user_agent: z.ZodOptional<z.ZodNullable<z.ZodString>>;
78
+ metadata: z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
79
+ created_at: z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>;
80
+ updated_at: z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>;
81
+ }, z.core.$strip>>;
82
+ }, z.core.$strip>;
83
+ export type AdminUserDetailResponse = z.infer<typeof AdminUserDetailResponseSchema>;
84
+ export declare const AdminUserAnomaliesResponseSchema: z.ZodObject<{
85
+ suspiciousEvents: z.ZodArray<z.ZodObject<{
86
+ id: z.ZodString;
87
+ user_id: z.ZodOptional<z.ZodNullable<z.ZodString>>;
88
+ type: z.ZodString;
89
+ ip_address: z.ZodOptional<z.ZodNullable<z.ZodString>>;
90
+ user_agent: z.ZodOptional<z.ZodNullable<z.ZodString>>;
91
+ metadata: z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
92
+ created_at: z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>;
93
+ updated_at: z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>;
94
+ }, z.core.$strip>>;
95
+ relatedIps: z.ZodArray<z.ZodString>;
96
+ relatedAgents: z.ZodArray<z.ZodString>;
97
+ }, z.core.$strip>;
98
+ export type AdminUserAnomaliesResponse = z.infer<typeof AdminUserAnomaliesResponseSchema>;
99
+ //# sourceMappingURL=schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../src/schemas/admin/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,iBAAiB;;iBAE5B,CAAC;AAEH;;;;GAIG;AACH,eAAO,MAAM,+BAA+B;;;;kBAMjC,CAAC;AAEZ,MAAM,MAAM,gCAAgC,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,+BAA+B,CAAC,CAAC;AAE/F,eAAO,MAAM,uCAAuC;;;;;iBAKlD,CAAC;AAEH,MAAM,MAAM,iCAAiC,GAAG,CAAC,CAAC,KAAK,CACrD,OAAO,uCAAuC,CAC/C,CAAC;AAEF,eAAO,MAAM,6BAA6B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAKxC,CAAC;AAEH,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,6BAA6B,CAAC,CAAC;AAEpF,eAAO,MAAM,gCAAgC;;;;;;;;;;;;;iBAI3C,CAAC;AAEH,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gCAAgC,CAAC,CAAC"}
@@ -0,0 +1,38 @@
1
+ import { z } from 'zod';
2
+ import { AuthEventSchema } from '../authEvent/schema.js';
3
+ import { CredentialResponseSchema } from '../credential/schema.js';
4
+ import { SessionSchema } from '../session/schema.js';
5
+ import { ApiUserSchema } from '../user/schema.js';
6
+ export const UserIdParamSchema = z.object({
7
+ userId: z.string(),
8
+ });
9
+ /**
10
+ * What an operator clears when a user replaces a lost device. Each step is
11
+ * opt-out rather than opt-in so a hurried recovery does not leave the old
12
+ * device's credentials in place.
13
+ */
14
+ export const DeviceReplacementRecoverySchema = z
15
+ .object({
16
+ revokeSessions: z.boolean().default(true),
17
+ removePasskeys: z.boolean().default(true),
18
+ disableTotp: z.boolean().default(true),
19
+ })
20
+ .strict();
21
+ export const DeviceReplacementRecoveryResponseSchema = z.object({
22
+ userId: z.string(),
23
+ revokedSessions: z.number().int().nonnegative(),
24
+ removedCredentials: z.number().int().nonnegative(),
25
+ disabledTotpCredentials: z.number().int().nonnegative(),
26
+ });
27
+ export const AdminUserDetailResponseSchema = z.object({
28
+ user: ApiUserSchema,
29
+ sessions: z.array(SessionSchema),
30
+ credentials: z.array(CredentialResponseSchema),
31
+ events: z.array(AuthEventSchema),
32
+ });
33
+ export const AdminUserAnomaliesResponseSchema = z.object({
34
+ suspiciousEvents: z.array(AuthEventSchema),
35
+ relatedIps: z.array(z.string()),
36
+ relatedAgents: z.array(z.string()),
37
+ });
38
+ //# sourceMappingURL=schema.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../src/schemas/admin/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AACzD,OAAO,EAAE,wBAAwB,EAAE,MAAM,yBAAyB,CAAC;AACnE,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAElD,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,CAAC,MAAM,CAAC;IACxC,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE;CACnB,CAAC,CAAC;AAEH;;;;GAIG;AACH,MAAM,CAAC,MAAM,+BAA+B,GAAG,CAAC;KAC7C,MAAM,CAAC;IACN,cAAc,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC;IACzC,cAAc,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC;IACzC,WAAW,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC;CACvC,CAAC;KACD,MAAM,EAAE,CAAC;AAIZ,MAAM,CAAC,MAAM,uCAAuC,GAAG,CAAC,CAAC,MAAM,CAAC;IAC9D,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE;IAClB,eAAe,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,WAAW,EAAE;IAC/C,kBAAkB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,WAAW,EAAE;IAClD,uBAAuB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,WAAW,EAAE;CACxD,CAAC,CAAC;AAMH,MAAM,CAAC,MAAM,6BAA6B,GAAG,CAAC,CAAC,MAAM,CAAC;IACpD,IAAI,EAAE,aAAa;IACnB,QAAQ,EAAE,CAAC,CAAC,KAAK,CAAC,aAAa,CAAC;IAChC,WAAW,EAAE,CAAC,CAAC,KAAK,CAAC,wBAAwB,CAAC;IAC9C,MAAM,EAAE,CAAC,CAAC,KAAK,CAAC,eAAe,CAAC;CACjC,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,gCAAgC,GAAG,CAAC,CAAC,MAAM,CAAC;IACvD,gBAAgB,EAAE,CAAC,CAAC,KAAK,CAAC,eAAe,CAAC;IAC1C,UAAU,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;IAC/B,aAAa,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;CACnC,CAAC,CAAC"}
@@ -1,6 +1,164 @@
1
1
  import z from 'zod';
2
+ export declare const IdentifierTypeSchema: z.ZodEnum<{
3
+ email: "email";
4
+ phone: "phone";
5
+ }>;
6
+ export type IdentifierType = z.infer<typeof IdentifierTypeSchema>;
2
7
  export declare const LoginRequestSchema: z.ZodObject<{
3
8
  identifier: z.ZodString;
9
+ passkeyAvailable: z.ZodOptional<z.ZodBoolean>;
4
10
  }, z.core.$strip>;
11
+ export type LoginRequest = z.infer<typeof LoginRequestSchema>;
12
+ export declare const LoginSuccessResponseSchema: z.ZodObject<{
13
+ message: z.ZodString;
14
+ token: z.ZodOptional<z.ZodString>;
15
+ sub: z.ZodOptional<z.ZodString>;
16
+ identifierType: z.ZodOptional<z.ZodEnum<{
17
+ email: "email";
18
+ phone: "phone";
19
+ }>>;
20
+ loginMethods: z.ZodOptional<z.ZodArray<z.ZodEnum<{
21
+ passkey: "passkey";
22
+ magic_link: "magic_link";
23
+ email_otp: "email_otp";
24
+ phone_otp: "phone_otp";
25
+ oauth: "oauth";
26
+ }>>>;
27
+ ttl: z.ZodOptional<z.ZodNumber>;
28
+ }, z.core.$strip>;
29
+ export type LoginSuccessResponse = z.infer<typeof LoginSuccessResponseSchema>;
5
30
  export declare const RefreshTokenRequestSchema: z.ZodObject<{}, z.core.$strip>;
31
+ /** @deprecated Use {@link RefreshTokenRequestSchema}. */
32
+ export declare const RefreshRequestSchema: z.ZodObject<{}, z.core.$strip>;
33
+ /**
34
+ * The token envelope every completed authentication returns, whatever the
35
+ * method. `sessionId` is only present where the flow names the session it
36
+ * created; OTP, magic link, and OAuth completions omit it.
37
+ */
38
+ export declare const RefreshSuccessResponseSchema: z.ZodObject<{
39
+ message: z.ZodString;
40
+ token: z.ZodOptional<z.ZodString>;
41
+ refreshToken: z.ZodOptional<z.ZodString>;
42
+ sub: z.ZodOptional<z.ZodString>;
43
+ sessionId: z.ZodOptional<z.ZodString>;
44
+ organizationId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
45
+ roles: z.ZodOptional<z.ZodArray<z.ZodString>>;
46
+ email: z.ZodOptional<z.ZodString>;
47
+ phone: z.ZodOptional<z.ZodNullable<z.ZodString>>;
48
+ ttl: z.ZodOptional<z.ZodNumber>;
49
+ refreshTtl: z.ZodOptional<z.ZodNumber>;
50
+ }, z.core.$strip>;
51
+ export type RefreshSuccessResponse = z.infer<typeof RefreshSuccessResponseSchema>;
52
+ export declare const LogoutScopeSchema: z.ZodEnum<{
53
+ current_session: "current_session";
54
+ all_sessions: "all_sessions";
55
+ }>;
56
+ export type LogoutScope = z.infer<typeof LogoutScopeSchema>;
57
+ export declare const RegistrationRequestSchema: z.ZodObject<{
58
+ email: z.ZodEmail;
59
+ phone: z.ZodOptional<z.ZodNullable<z.ZodString>>;
60
+ }, z.core.$strip>;
61
+ export type RegistrationRequest = z.infer<typeof RegistrationRequestSchema>;
62
+ export declare const RegistrationSuccessSchema: z.ZodObject<{
63
+ message: z.ZodString;
64
+ sub: z.ZodOptional<z.ZodString>;
65
+ token: z.ZodOptional<z.ZodString>;
66
+ ttl: z.ZodOptional<z.ZodString>;
67
+ delivery: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
68
+ kind: z.ZodLiteral<"otp_email">;
69
+ to: z.ZodString;
70
+ token: z.ZodString;
71
+ }, z.core.$strip>, z.ZodObject<{
72
+ kind: z.ZodLiteral<"otp_sms">;
73
+ to: z.ZodString;
74
+ token: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
75
+ }, z.core.$strip>, z.ZodObject<{
76
+ kind: z.ZodLiteral<"magic_link_email">;
77
+ to: z.ZodString;
78
+ token: z.ZodOptional<z.ZodString>;
79
+ magicLinkUrl: z.ZodString;
80
+ }, z.core.$strip>], "kind">>;
81
+ }, z.core.$strip>;
82
+ export type RegistrationSuccessResponse = z.infer<typeof RegistrationSuccessSchema>;
83
+ export declare const RegisterPhoneRequestSchema: z.ZodObject<{
84
+ phone: z.ZodString;
85
+ }, z.core.$strip>;
86
+ export declare const RegisterPhoneSuccessSchema: z.ZodObject<{
87
+ message: z.ZodString;
88
+ phone: z.ZodString;
89
+ delivery: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
90
+ kind: z.ZodLiteral<"otp_email">;
91
+ to: z.ZodString;
92
+ token: z.ZodString;
93
+ }, z.core.$strip>, z.ZodObject<{
94
+ kind: z.ZodLiteral<"otp_sms">;
95
+ to: z.ZodString;
96
+ token: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
97
+ }, z.core.$strip>, z.ZodObject<{
98
+ kind: z.ZodLiteral<"magic_link_email">;
99
+ to: z.ZodString;
100
+ token: z.ZodOptional<z.ZodString>;
101
+ magicLinkUrl: z.ZodString;
102
+ }, z.core.$strip>], "kind">>;
103
+ }, z.core.$strip>;
104
+ export declare const VerifyOTPRequestSchema: z.ZodObject<{
105
+ verificationToken: z.ZodString;
106
+ }, z.core.$strip>;
107
+ export declare const OTPVerifyTokenSuccessSchema: z.ZodObject<{
108
+ sub: z.ZodOptional<z.ZodString>;
109
+ message: z.ZodString;
110
+ email: z.ZodOptional<z.ZodString>;
111
+ phone: z.ZodOptional<z.ZodNullable<z.ZodString>>;
112
+ roles: z.ZodOptional<z.ZodArray<z.ZodString>>;
113
+ token: z.ZodOptional<z.ZodString>;
114
+ ttl: z.ZodOptional<z.ZodNumber>;
115
+ refreshToken: z.ZodOptional<z.ZodString>;
116
+ organizationId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
117
+ refreshTtl: z.ZodOptional<z.ZodNumber>;
118
+ }, z.core.$strip>;
119
+ export declare const MagicLinkVerifyParamsSchema: z.ZodObject<{
120
+ token: z.ZodString;
121
+ }, z.core.$strip>;
122
+ export declare const MagicLinkPollSuccessSchema: z.ZodObject<{
123
+ sub: z.ZodOptional<z.ZodString>;
124
+ message: z.ZodString;
125
+ email: z.ZodOptional<z.ZodString>;
126
+ phone: z.ZodOptional<z.ZodNullable<z.ZodString>>;
127
+ roles: z.ZodOptional<z.ZodArray<z.ZodString>>;
128
+ token: z.ZodOptional<z.ZodString>;
129
+ ttl: z.ZodOptional<z.ZodNumber>;
130
+ refreshToken: z.ZodOptional<z.ZodString>;
131
+ refreshTtl: z.ZodOptional<z.ZodNumber>;
132
+ }, z.core.$strip>;
133
+ /** Body for endpoints that acknowledge a request and may hand back a delivery. */
134
+ export declare const AuthMessageResponseSchema: z.ZodObject<{
135
+ message: z.ZodString;
136
+ token: z.ZodOptional<z.ZodString>;
137
+ delivery: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
138
+ kind: z.ZodLiteral<"otp_email">;
139
+ to: z.ZodString;
140
+ token: z.ZodString;
141
+ }, z.core.$strip>, z.ZodObject<{
142
+ kind: z.ZodLiteral<"otp_sms">;
143
+ to: z.ZodString;
144
+ token: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
145
+ }, z.core.$strip>, z.ZodObject<{
146
+ kind: z.ZodLiteral<"magic_link_email">;
147
+ to: z.ZodString;
148
+ token: z.ZodOptional<z.ZodString>;
149
+ magicLinkUrl: z.ZodString;
150
+ }, z.core.$strip>], "kind">>;
151
+ }, z.core.$strip>;
152
+ export type AuthMessageResponse = z.infer<typeof AuthMessageResponseSchema>;
153
+ /** The access token's claims, as a resource server reads them off a request. */
154
+ export declare const SeamlessAuthUserSchema: z.ZodObject<{
155
+ id: z.ZodString;
156
+ roles: z.ZodArray<z.ZodString>;
157
+ email: z.ZodOptional<z.ZodString>;
158
+ phone: z.ZodOptional<z.ZodNullable<z.ZodString>>;
159
+ iat: z.ZodOptional<z.ZodNumber>;
160
+ exp: z.ZodOptional<z.ZodNumber>;
161
+ token: z.ZodOptional<z.ZodString>;
162
+ }, z.core.$strip>;
163
+ export type SeamlessAuthUser = z.infer<typeof SeamlessAuthUserSchema>;
6
164
  //# sourceMappingURL=auth.schema.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"auth.schema.d.ts","sourceRoot":"","sources":["../../../src/schemas/auth/auth.schema.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;AAEpB,eAAO,MAAM,kBAAkB;;iBAE7B,CAAC;AAEH,eAAO,MAAM,yBAAyB,gCAAe,CAAC"}
1
+ {"version":3,"file":"auth.schema.d.ts","sourceRoot":"","sources":["../../../src/schemas/auth/auth.schema.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;AAIpB,eAAO,MAAM,oBAAoB;;;EAA6B,CAAC;AAE/D,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAElE,eAAO,MAAM,kBAAkB;;;iBAG7B,CAAC;AAEH,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAE9D,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;iBAOrC,CAAC;AAEH,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,0BA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AC,OAAO,sBAAsB,CAAC,CAAC"}
@@ -1,6 +1,88 @@
1
1
  import z from 'zod';
2
+ import { AuthDeliverySchema } from '../messaging/schema.js';
3
+ import { LoginMethodSchema } from '../systemConfig/schema.js';
4
+ export const IdentifierTypeSchema = z.enum(['email', 'phone']);
2
5
  export const LoginRequestSchema = z.object({
3
6
  identifier: z.string(),
7
+ passkeyAvailable: z.boolean().optional(),
8
+ });
9
+ export const LoginSuccessResponseSchema = z.object({
10
+ message: z.string(),
11
+ token: z.string().optional(),
12
+ sub: z.string().optional(),
13
+ identifierType: IdentifierTypeSchema.optional(),
14
+ loginMethods: z.array(LoginMethodSchema).optional(),
15
+ ttl: z.number().optional(),
4
16
  });
5
17
  export const RefreshTokenRequestSchema = z.object({});
18
+ /** @deprecated Use {@link RefreshTokenRequestSchema}. */
19
+ export const RefreshRequestSchema = RefreshTokenRequestSchema;
20
+ /**
21
+ * The token envelope every completed authentication returns, whatever the
22
+ * method. `sessionId` is only present where the flow names the session it
23
+ * created; OTP, magic link, and OAuth completions omit it.
24
+ */
25
+ export const RefreshSuccessResponseSchema = z.object({
26
+ message: z.string(),
27
+ token: z.string().optional(),
28
+ refreshToken: z.string().optional(),
29
+ sub: z.string().optional(),
30
+ sessionId: z.string().optional(),
31
+ organizationId: z.string().nullable().optional(),
32
+ roles: z.array(z.string()).optional(),
33
+ email: z.string().optional(),
34
+ phone: z.string().nullable().optional(),
35
+ ttl: z.number().optional(),
36
+ refreshTtl: z.number().optional(),
37
+ });
38
+ export const LogoutScopeSchema = z.enum(['current_session', 'all_sessions']);
39
+ export const RegistrationRequestSchema = z.object({
40
+ email: z.email(),
41
+ // Registration only needs an email. A phone can be added and verified later.
42
+ phone: z.string().nullish(),
43
+ });
44
+ export const RegistrationSuccessSchema = z.object({
45
+ message: z.string(),
46
+ sub: z.string().optional(),
47
+ token: z.string().optional(),
48
+ ttl: z.string().optional(),
49
+ delivery: AuthDeliverySchema.optional(),
50
+ });
51
+ export const RegisterPhoneRequestSchema = z.object({
52
+ phone: z.string(),
53
+ });
54
+ export const RegisterPhoneSuccessSchema = z.object({
55
+ message: z.string(),
56
+ phone: z.string(),
57
+ delivery: AuthDeliverySchema.optional(),
58
+ });
59
+ export const VerifyOTPRequestSchema = z.object({
60
+ verificationToken: z.string(),
61
+ });
62
+ export const OTPVerifyTokenSuccessSchema = RefreshSuccessResponseSchema.omit({
63
+ sessionId: true,
64
+ });
65
+ export const MagicLinkVerifyParamsSchema = z.object({
66
+ token: z.string(),
67
+ });
68
+ export const MagicLinkPollSuccessSchema = RefreshSuccessResponseSchema.omit({
69
+ sessionId: true,
70
+ organizationId: true,
71
+ });
72
+ /** Body for endpoints that acknowledge a request and may hand back a delivery. */
73
+ export const AuthMessageResponseSchema = z.object({
74
+ message: z.string(),
75
+ token: z.string().optional(),
76
+ delivery: AuthDeliverySchema.optional(),
77
+ });
78
+ /** The access token's claims, as a resource server reads them off a request. */
79
+ export const SeamlessAuthUserSchema = z.object({
80
+ id: z.string(),
81
+ roles: z.array(z.string()),
82
+ email: z.string().optional(),
83
+ phone: z.string().nullable().optional(),
84
+ iat: z.number().optional(),
85
+ exp: z.number().optional(),
86
+ token: z.string().optional(),
87
+ });
6
88
  //# sourceMappingURL=auth.schema.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"auth.schema.js","sourceRoot":"","sources":["../../../src/schemas/auth/auth.schema.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;AAEpB,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAAC,CAAC,MAAM,CAAC;IACzC,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE;CACvB,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,yBAAyB,GAAG,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC"}
1
+ {"version":3,"file":"auth.schema.js","sourceRoot":"","sources":["../../../src/schemas/auth/auth.schema.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;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