@substrat-run/contracts 0.2.1 → 0.4.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/attachments.d.ts +4 -1
- package/dist/attachments.d.ts.map +1 -1
- package/dist/control-plane.d.ts +47 -55
- package/dist/control-plane.d.ts.map +1 -1
- package/dist/events.d.ts +34 -160
- package/dist/events.d.ts.map +1 -1
- package/dist/ids.d.ts +9 -9
- package/dist/ids.d.ts.map +1 -1
- package/dist/index.d.ts +19 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +19 -0
- package/dist/index.js.map +1 -1
- package/dist/manifest.d.ts +29 -347
- package/dist/manifest.d.ts.map +1 -1
- package/dist/money.d.ts +5 -11
- package/dist/money.d.ts.map +1 -1
- package/dist/permission.d.ts +58 -222
- package/dist/permission.d.ts.map +1 -1
- package/dist/permission.js +14 -0
- package/dist/permission.js.map +1 -1
- package/dist/tenancy.d.ts +50 -65
- package/dist/tenancy.d.ts.map +1 -1
- package/dist/tenancy.js +10 -0
- package/dist/tenancy.js.map +1 -1
- package/package.json +2 -2
package/dist/attachments.d.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
export declare const visibility: z.ZodEnum<
|
|
2
|
+
export declare const visibility: z.ZodEnum<{
|
|
3
|
+
internal: "internal";
|
|
4
|
+
customer: "customer";
|
|
5
|
+
}>;
|
|
3
6
|
export type Visibility = z.infer<typeof visibility>;
|
|
4
7
|
//# sourceMappingURL=attachments.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"attachments.d.ts","sourceRoot":"","sources":["../src/attachments.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAQxB,eAAO,MAAM,UAAU,
|
|
1
|
+
{"version":3,"file":"attachments.d.ts","sourceRoot":"","sources":["../src/attachments.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAQxB,eAAO,MAAM,UAAU;;;EAAmC,CAAC;AAC3D,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC"}
|
package/dist/control-plane.d.ts
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
export declare const adminAction: z.ZodEnum<
|
|
2
|
+
export declare const adminAction: z.ZodEnum<{
|
|
3
|
+
defineRole: "defineRole";
|
|
4
|
+
assignRole: "assignRole";
|
|
5
|
+
grant: "grant";
|
|
6
|
+
grantToOrg: "grantToOrg";
|
|
7
|
+
addMember: "addMember";
|
|
8
|
+
createTenant: "createTenant";
|
|
9
|
+
setTenantStatus: "setTenantStatus";
|
|
10
|
+
provisionScope: "provisionScope";
|
|
11
|
+
suspendScope: "suspendScope";
|
|
12
|
+
unsuspendScope: "unsuspendScope";
|
|
13
|
+
archiveScope: "archiveScope";
|
|
14
|
+
unarchiveScope: "unarchiveScope";
|
|
15
|
+
grantEntitlement: "grantEntitlement";
|
|
16
|
+
revokeEntitlement: "revokeEntitlement";
|
|
17
|
+
linkIdentity: "linkIdentity";
|
|
18
|
+
}>;
|
|
3
19
|
export type AdminAction = z.infer<typeof adminAction>;
|
|
4
20
|
/**
|
|
5
21
|
* The neutral identity seam (D-16; control-plane.md §6 "principal derivation").
|
|
@@ -12,36 +28,16 @@ export type AdminAction = z.infer<typeof adminAction>;
|
|
|
12
28
|
export declare const identityLink: z.ZodObject<{
|
|
13
29
|
provider: z.ZodString;
|
|
14
30
|
externalId: z.ZodString;
|
|
15
|
-
principal: z.ZodBranded<z.ZodString, "PrincipalId">;
|
|
16
|
-
tenantId: z.ZodBranded<z.ZodString, "TenantId">;
|
|
17
|
-
scopeId: z.ZodOptional<z.ZodBranded<z.ZodString, "ScopeId">>;
|
|
18
|
-
},
|
|
19
|
-
provider: string;
|
|
20
|
-
externalId: string;
|
|
21
|
-
principal: string & z.BRAND<"PrincipalId">;
|
|
22
|
-
tenantId: string & z.BRAND<"TenantId">;
|
|
23
|
-
scopeId?: (string & z.BRAND<"ScopeId">) | undefined;
|
|
24
|
-
}, {
|
|
25
|
-
provider: string;
|
|
26
|
-
externalId: string;
|
|
27
|
-
principal: string;
|
|
28
|
-
tenantId: string;
|
|
29
|
-
scopeId?: string | undefined;
|
|
30
|
-
}>;
|
|
31
|
+
principal: z.core.$ZodBranded<z.ZodString, "PrincipalId", "out">;
|
|
32
|
+
tenantId: z.core.$ZodBranded<z.ZodString, "TenantId", "out">;
|
|
33
|
+
scopeId: z.ZodOptional<z.core.$ZodBranded<z.ZodString, "ScopeId", "out">>;
|
|
34
|
+
}, z.core.$strip>;
|
|
31
35
|
export type IdentityLink = z.infer<typeof identityLink>;
|
|
32
36
|
export declare const resolvedIdentity: z.ZodObject<{
|
|
33
|
-
principal: z.ZodBranded<z.ZodString, "PrincipalId">;
|
|
34
|
-
tenantId: z.ZodBranded<z.ZodString, "TenantId">;
|
|
35
|
-
scopeId: z.ZodNullable<z.ZodBranded<z.ZodString, "ScopeId">>;
|
|
36
|
-
},
|
|
37
|
-
principal: string & z.BRAND<"PrincipalId">;
|
|
38
|
-
tenantId: string & z.BRAND<"TenantId">;
|
|
39
|
-
scopeId: (string & z.BRAND<"ScopeId">) | null;
|
|
40
|
-
}, {
|
|
41
|
-
principal: string;
|
|
42
|
-
tenantId: string;
|
|
43
|
-
scopeId: string | null;
|
|
44
|
-
}>;
|
|
37
|
+
principal: z.core.$ZodBranded<z.ZodString, "PrincipalId", "out">;
|
|
38
|
+
tenantId: z.core.$ZodBranded<z.ZodString, "TenantId", "out">;
|
|
39
|
+
scopeId: z.ZodNullable<z.core.$ZodBranded<z.ZodString, "ScopeId", "out">>;
|
|
40
|
+
}, z.core.$strip>;
|
|
45
41
|
export type ResolvedIdentity = z.infer<typeof resolvedIdentity>;
|
|
46
42
|
/**
|
|
47
43
|
* An append-only admin audit row (control-plane.md §4.4). Every field except
|
|
@@ -55,34 +51,30 @@ export type ResolvedIdentity = z.infer<typeof resolvedIdentity>;
|
|
|
55
51
|
*/
|
|
56
52
|
export declare const adminLogEntry: z.ZodObject<{
|
|
57
53
|
id: z.ZodString;
|
|
58
|
-
actor: z.ZodBranded<z.ZodString, "PlatformActorId">;
|
|
59
|
-
action: z.ZodEnum<
|
|
60
|
-
|
|
61
|
-
|
|
54
|
+
actor: z.core.$ZodBranded<z.ZodString, "PlatformActorId", "out">;
|
|
55
|
+
action: z.ZodEnum<{
|
|
56
|
+
defineRole: "defineRole";
|
|
57
|
+
assignRole: "assignRole";
|
|
58
|
+
grant: "grant";
|
|
59
|
+
grantToOrg: "grantToOrg";
|
|
60
|
+
addMember: "addMember";
|
|
61
|
+
createTenant: "createTenant";
|
|
62
|
+
setTenantStatus: "setTenantStatus";
|
|
63
|
+
provisionScope: "provisionScope";
|
|
64
|
+
suspendScope: "suspendScope";
|
|
65
|
+
unsuspendScope: "unsuspendScope";
|
|
66
|
+
archiveScope: "archiveScope";
|
|
67
|
+
unarchiveScope: "unarchiveScope";
|
|
68
|
+
grantEntitlement: "grantEntitlement";
|
|
69
|
+
revokeEntitlement: "revokeEntitlement";
|
|
70
|
+
linkIdentity: "linkIdentity";
|
|
71
|
+
}>;
|
|
72
|
+
tenantId: z.core.$ZodBranded<z.ZodString, "TenantId", "out">;
|
|
73
|
+
scopeId: z.ZodNullable<z.core.$ZodBranded<z.ZodString, "ScopeId", "out">>;
|
|
62
74
|
vertical: z.ZodNullable<z.ZodString>;
|
|
63
75
|
before: z.ZodNullable<z.ZodUnknown>;
|
|
64
76
|
after: z.ZodNullable<z.ZodUnknown>;
|
|
65
|
-
at: z.ZodBranded<z.ZodString, "Instant">;
|
|
66
|
-
},
|
|
67
|
-
at: string & z.BRAND<"Instant">;
|
|
68
|
-
tenantId: string & z.BRAND<"TenantId">;
|
|
69
|
-
scopeId: (string & z.BRAND<"ScopeId">) | null;
|
|
70
|
-
id: string;
|
|
71
|
-
actor: string & z.BRAND<"PlatformActorId">;
|
|
72
|
-
action: "defineRole" | "assignRole" | "grant" | "grantToOrg" | "addMember" | "createTenant" | "setTenantStatus" | "provisionScope" | "suspendScope" | "unsuspendScope" | "archiveScope" | "unarchiveScope" | "grantEntitlement" | "revokeEntitlement" | "linkIdentity";
|
|
73
|
-
vertical: string | null;
|
|
74
|
-
before?: unknown;
|
|
75
|
-
after?: unknown;
|
|
76
|
-
}, {
|
|
77
|
-
at: string;
|
|
78
|
-
tenantId: string;
|
|
79
|
-
scopeId: string | null;
|
|
80
|
-
id: string;
|
|
81
|
-
actor: string;
|
|
82
|
-
action: "defineRole" | "assignRole" | "grant" | "grantToOrg" | "addMember" | "createTenant" | "setTenantStatus" | "provisionScope" | "suspendScope" | "unsuspendScope" | "archiveScope" | "unarchiveScope" | "grantEntitlement" | "revokeEntitlement" | "linkIdentity";
|
|
83
|
-
vertical: string | null;
|
|
84
|
-
before?: unknown;
|
|
85
|
-
after?: unknown;
|
|
86
|
-
}>;
|
|
77
|
+
at: z.core.$ZodBranded<z.ZodString, "Instant", "out">;
|
|
78
|
+
}, z.core.$strip>;
|
|
87
79
|
export type AdminLogEntry = z.infer<typeof adminLogEntry>;
|
|
88
80
|
//# sourceMappingURL=control-plane.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"control-plane.d.ts","sourceRoot":"","sources":["../src/control-plane.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAUxB,eAAO,MAAM,WAAW
|
|
1
|
+
{"version":3,"file":"control-plane.d.ts","sourceRoot":"","sources":["../src/control-plane.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAUxB,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;EAgBtB,CAAC;AACH,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,CAAC;AAEtD;;;;;;;GAOG;AACH,eAAO,MAAM,YAAY;;;;;;iBAMvB,CAAC;AACH,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;AAExD,eAAO,MAAM,gBAAgB;;;;iBAI3B,CAAC;AACH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAEhE;;;;;;;;;GASG;AACH,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;iBAUxB,CAAC;AACH,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC"}
|
package/dist/events.d.ts
CHANGED
|
@@ -2,185 +2,59 @@ import { z } from 'zod';
|
|
|
2
2
|
export declare const entityRef: z.ZodObject<{
|
|
3
3
|
entityType: z.ZodString;
|
|
4
4
|
entityId: z.ZodString;
|
|
5
|
-
},
|
|
6
|
-
entityType: string;
|
|
7
|
-
entityId: string;
|
|
8
|
-
}, {
|
|
9
|
-
entityType: string;
|
|
10
|
-
entityId: string;
|
|
11
|
-
}>;
|
|
5
|
+
}, z.core.$strip>;
|
|
12
6
|
export type EntityRef = z.infer<typeof entityRef>;
|
|
13
|
-
export declare const piiClass: z.ZodEnum<
|
|
7
|
+
export declare const piiClass: z.ZodEnum<{
|
|
8
|
+
none: "none";
|
|
9
|
+
pseudonymous: "pseudonymous";
|
|
10
|
+
direct: "direct";
|
|
11
|
+
}>;
|
|
14
12
|
export type PiiClass = z.infer<typeof piiClass>;
|
|
15
13
|
export declare const eventType: z.ZodString;
|
|
16
14
|
export declare const systemActor: z.ZodObject<{
|
|
17
|
-
system: z.ZodBranded<z.ZodString, "ModuleId">;
|
|
18
|
-
},
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
}>;
|
|
23
|
-
export declare const actor: z.ZodUnion<[z.ZodBranded<z.ZodString, "PrincipalId">, z.ZodObject<{
|
|
24
|
-
system: z.ZodBranded<z.ZodString, "ModuleId">;
|
|
25
|
-
}, "strip", z.ZodTypeAny, {
|
|
26
|
-
system: string & z.BRAND<"ModuleId">;
|
|
27
|
-
}, {
|
|
28
|
-
system: string;
|
|
29
|
-
}>]>;
|
|
15
|
+
system: z.core.$ZodBranded<z.ZodString, "ModuleId", "out">;
|
|
16
|
+
}, z.core.$strip>;
|
|
17
|
+
export declare const actor: z.ZodUnion<readonly [z.core.$ZodBranded<z.ZodString, "PrincipalId", "out">, z.ZodObject<{
|
|
18
|
+
system: z.core.$ZodBranded<z.ZodString, "ModuleId", "out">;
|
|
19
|
+
}, z.core.$strip>]>;
|
|
30
20
|
export type Actor = z.infer<typeof actor>;
|
|
31
|
-
export declare const domainEventInput: z.
|
|
21
|
+
export declare const domainEventInput: z.ZodObject<{
|
|
32
22
|
type: z.ZodString;
|
|
33
23
|
schemaVersion: z.ZodNumber;
|
|
34
24
|
entity: z.ZodObject<{
|
|
35
25
|
entityType: z.ZodString;
|
|
36
26
|
entityId: z.ZodString;
|
|
37
|
-
},
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
entityId: string;
|
|
27
|
+
}, z.core.$strip>;
|
|
28
|
+
piiClass: z.ZodEnum<{
|
|
29
|
+
none: "none";
|
|
30
|
+
pseudonymous: "pseudonymous";
|
|
31
|
+
direct: "direct";
|
|
43
32
|
}>;
|
|
44
|
-
|
|
45
|
-
subjectId: z.ZodOptional<z.ZodBranded<z.ZodString, "DataSubjectId">>;
|
|
33
|
+
subjectId: z.ZodOptional<z.core.$ZodBranded<z.ZodString, "DataSubjectId", "out">>;
|
|
46
34
|
payload: z.ZodUnknown;
|
|
47
|
-
},
|
|
48
|
-
type: string;
|
|
49
|
-
schemaVersion: number;
|
|
50
|
-
entity: {
|
|
51
|
-
entityType: string;
|
|
52
|
-
entityId: string;
|
|
53
|
-
};
|
|
54
|
-
piiClass: "none" | "pseudonymous" | "direct";
|
|
55
|
-
subjectId?: (string & z.BRAND<"DataSubjectId">) | undefined;
|
|
56
|
-
payload?: unknown;
|
|
57
|
-
}, {
|
|
58
|
-
type: string;
|
|
59
|
-
schemaVersion: number;
|
|
60
|
-
entity: {
|
|
61
|
-
entityType: string;
|
|
62
|
-
entityId: string;
|
|
63
|
-
};
|
|
64
|
-
piiClass: "none" | "pseudonymous" | "direct";
|
|
65
|
-
subjectId?: string | undefined;
|
|
66
|
-
payload?: unknown;
|
|
67
|
-
}>, {
|
|
68
|
-
type: string;
|
|
69
|
-
schemaVersion: number;
|
|
70
|
-
entity: {
|
|
71
|
-
entityType: string;
|
|
72
|
-
entityId: string;
|
|
73
|
-
};
|
|
74
|
-
piiClass: "none" | "pseudonymous" | "direct";
|
|
75
|
-
subjectId?: (string & z.BRAND<"DataSubjectId">) | undefined;
|
|
76
|
-
payload?: unknown;
|
|
77
|
-
}, {
|
|
78
|
-
type: string;
|
|
79
|
-
schemaVersion: number;
|
|
80
|
-
entity: {
|
|
81
|
-
entityType: string;
|
|
82
|
-
entityId: string;
|
|
83
|
-
};
|
|
84
|
-
piiClass: "none" | "pseudonymous" | "direct";
|
|
85
|
-
subjectId?: string | undefined;
|
|
86
|
-
payload?: unknown;
|
|
87
|
-
}>;
|
|
35
|
+
}, z.core.$strip>;
|
|
88
36
|
export type DomainEventInput = z.infer<typeof domainEventInput>;
|
|
89
|
-
export declare const domainEvent: z.
|
|
90
|
-
id: z.ZodBranded<z.ZodString, "EventId">;
|
|
37
|
+
export declare const domainEvent: z.ZodObject<{
|
|
38
|
+
id: z.core.$ZodBranded<z.ZodString, "EventId", "out">;
|
|
91
39
|
type: z.ZodString;
|
|
92
40
|
schemaVersion: z.ZodNumber;
|
|
93
|
-
occurredAt: z.ZodBranded<z.ZodString, "Instant">;
|
|
94
|
-
tenantId: z.ZodBranded<z.ZodString, "TenantId">;
|
|
95
|
-
scopeId: z.ZodBranded<z.ZodString, "ScopeId">;
|
|
96
|
-
actor: z.ZodUnion<[z.ZodBranded<z.ZodString, "PrincipalId">, z.ZodObject<{
|
|
97
|
-
system: z.ZodBranded<z.ZodString, "ModuleId">;
|
|
98
|
-
},
|
|
99
|
-
system: string & z.BRAND<"ModuleId">;
|
|
100
|
-
}, {
|
|
101
|
-
system: string;
|
|
102
|
-
}>]>;
|
|
41
|
+
occurredAt: z.core.$ZodBranded<z.ZodString, "Instant", "out">;
|
|
42
|
+
tenantId: z.core.$ZodBranded<z.ZodString, "TenantId", "out">;
|
|
43
|
+
scopeId: z.core.$ZodBranded<z.ZodString, "ScopeId", "out">;
|
|
44
|
+
actor: z.ZodUnion<readonly [z.core.$ZodBranded<z.ZodString, "PrincipalId", "out">, z.ZodObject<{
|
|
45
|
+
system: z.core.$ZodBranded<z.ZodString, "ModuleId", "out">;
|
|
46
|
+
}, z.core.$strip>]>;
|
|
103
47
|
entity: z.ZodObject<{
|
|
104
48
|
entityType: z.ZodString;
|
|
105
49
|
entityId: z.ZodString;
|
|
106
|
-
},
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
entityId: string;
|
|
50
|
+
}, z.core.$strip>;
|
|
51
|
+
piiClass: z.ZodEnum<{
|
|
52
|
+
none: "none";
|
|
53
|
+
pseudonymous: "pseudonymous";
|
|
54
|
+
direct: "direct";
|
|
112
55
|
}>;
|
|
113
|
-
|
|
114
|
-
subjectId: z.ZodOptional<z.ZodBranded<z.ZodString, "DataSubjectId">>;
|
|
56
|
+
subjectId: z.ZodOptional<z.core.$ZodBranded<z.ZodString, "DataSubjectId", "out">>;
|
|
115
57
|
payload: z.ZodUnknown;
|
|
116
|
-
},
|
|
117
|
-
type: string;
|
|
118
|
-
tenantId: string & z.BRAND<"TenantId">;
|
|
119
|
-
scopeId: string & z.BRAND<"ScopeId">;
|
|
120
|
-
id: string & z.BRAND<"EventId">;
|
|
121
|
-
actor: (string & z.BRAND<"PrincipalId">) | {
|
|
122
|
-
system: string & z.BRAND<"ModuleId">;
|
|
123
|
-
};
|
|
124
|
-
schemaVersion: number;
|
|
125
|
-
entity: {
|
|
126
|
-
entityType: string;
|
|
127
|
-
entityId: string;
|
|
128
|
-
};
|
|
129
|
-
piiClass: "none" | "pseudonymous" | "direct";
|
|
130
|
-
occurredAt: string & z.BRAND<"Instant">;
|
|
131
|
-
subjectId?: (string & z.BRAND<"DataSubjectId">) | undefined;
|
|
132
|
-
payload?: unknown;
|
|
133
|
-
}, {
|
|
134
|
-
type: string;
|
|
135
|
-
tenantId: string;
|
|
136
|
-
scopeId: string;
|
|
137
|
-
id: string;
|
|
138
|
-
actor: string | {
|
|
139
|
-
system: string;
|
|
140
|
-
};
|
|
141
|
-
schemaVersion: number;
|
|
142
|
-
entity: {
|
|
143
|
-
entityType: string;
|
|
144
|
-
entityId: string;
|
|
145
|
-
};
|
|
146
|
-
piiClass: "none" | "pseudonymous" | "direct";
|
|
147
|
-
occurredAt: string;
|
|
148
|
-
subjectId?: string | undefined;
|
|
149
|
-
payload?: unknown;
|
|
150
|
-
}>, {
|
|
151
|
-
type: string;
|
|
152
|
-
tenantId: string & z.BRAND<"TenantId">;
|
|
153
|
-
scopeId: string & z.BRAND<"ScopeId">;
|
|
154
|
-
id: string & z.BRAND<"EventId">;
|
|
155
|
-
actor: (string & z.BRAND<"PrincipalId">) | {
|
|
156
|
-
system: string & z.BRAND<"ModuleId">;
|
|
157
|
-
};
|
|
158
|
-
schemaVersion: number;
|
|
159
|
-
entity: {
|
|
160
|
-
entityType: string;
|
|
161
|
-
entityId: string;
|
|
162
|
-
};
|
|
163
|
-
piiClass: "none" | "pseudonymous" | "direct";
|
|
164
|
-
occurredAt: string & z.BRAND<"Instant">;
|
|
165
|
-
subjectId?: (string & z.BRAND<"DataSubjectId">) | undefined;
|
|
166
|
-
payload?: unknown;
|
|
167
|
-
}, {
|
|
168
|
-
type: string;
|
|
169
|
-
tenantId: string;
|
|
170
|
-
scopeId: string;
|
|
171
|
-
id: string;
|
|
172
|
-
actor: string | {
|
|
173
|
-
system: string;
|
|
174
|
-
};
|
|
175
|
-
schemaVersion: number;
|
|
176
|
-
entity: {
|
|
177
|
-
entityType: string;
|
|
178
|
-
entityId: string;
|
|
179
|
-
};
|
|
180
|
-
piiClass: "none" | "pseudonymous" | "direct";
|
|
181
|
-
occurredAt: string;
|
|
182
|
-
subjectId?: string | undefined;
|
|
183
|
-
payload?: unknown;
|
|
184
|
-
}>;
|
|
58
|
+
}, z.core.$strip>;
|
|
185
59
|
export type DomainEvent = z.infer<typeof domainEvent>;
|
|
186
60
|
//# sourceMappingURL=events.d.ts.map
|
package/dist/events.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../src/events.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAYxB,eAAO,MAAM,SAAS
|
|
1
|
+
{"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../src/events.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAYxB,eAAO,MAAM,SAAS;;;iBAGpB,CAAC;AACH,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,SAAS,CAAC,CAAC;AAIlD,eAAO,MAAM,QAAQ;;;;EAA6C,CAAC;AACnE,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,QAAQ,CAAC,CAAC;AAGhD,eAAO,MAAM,SAAS,aAA+C,CAAC;AAEtE,eAAO,MAAM,WAAW;;iBAAiC,CAAC;AAC1D,eAAO,MAAM,KAAK;;mBAAsC,CAAC;AACzD,MAAM,MAAM,KAAK,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,KAAK,CAAC,CAAC;AAiB1C,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;iBASD,CAAC;AAC7B,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAGhE,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;iBAcI,CAAC;AAC7B,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,CAAC"}
|
package/dist/ids.d.ts
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
export declare const tenantId: z.ZodBranded<z.ZodString, "TenantId">;
|
|
2
|
+
export declare const tenantId: z.core.$ZodBranded<z.ZodString, "TenantId", "out">;
|
|
3
3
|
export type TenantId = z.infer<typeof tenantId>;
|
|
4
|
-
export declare const scopeId: z.ZodBranded<z.ZodString, "ScopeId">;
|
|
4
|
+
export declare const scopeId: z.core.$ZodBranded<z.ZodString, "ScopeId", "out">;
|
|
5
5
|
export type ScopeId = z.infer<typeof scopeId>;
|
|
6
|
-
export declare const principalId: z.ZodBranded<z.ZodString, "PrincipalId">;
|
|
6
|
+
export declare const principalId: z.core.$ZodBranded<z.ZodString, "PrincipalId", "out">;
|
|
7
7
|
export type PrincipalId = z.infer<typeof principalId>;
|
|
8
|
-
export declare const platformActorId: z.ZodBranded<z.ZodString, "PlatformActorId">;
|
|
8
|
+
export declare const platformActorId: z.core.$ZodBranded<z.ZodString, "PlatformActorId", "out">;
|
|
9
9
|
export type PlatformActorId = z.infer<typeof platformActorId>;
|
|
10
|
-
export declare const eventId: z.ZodBranded<z.ZodString, "EventId">;
|
|
10
|
+
export declare const eventId: z.core.$ZodBranded<z.ZodString, "EventId", "out">;
|
|
11
11
|
export type EventId = z.infer<typeof eventId>;
|
|
12
|
-
export declare const dataSubjectId: z.ZodBranded<z.ZodString, "DataSubjectId">;
|
|
12
|
+
export declare const dataSubjectId: z.core.$ZodBranded<z.ZodString, "DataSubjectId", "out">;
|
|
13
13
|
export type DataSubjectId = z.infer<typeof dataSubjectId>;
|
|
14
|
-
export declare const moduleId: z.ZodBranded<z.ZodString, "ModuleId">;
|
|
14
|
+
export declare const moduleId: z.core.$ZodBranded<z.ZodString, "ModuleId", "out">;
|
|
15
15
|
export type ModuleId = z.infer<typeof moduleId>;
|
|
16
|
-
export declare const instant: z.ZodBranded<z.ZodString, "Instant">;
|
|
16
|
+
export declare const instant: z.core.$ZodBranded<z.ZodString, "Instant", "out">;
|
|
17
17
|
export type Instant = z.infer<typeof instant>;
|
|
18
|
-
export declare const permissionKey: z.ZodBranded<z.ZodString, "PermissionKey">;
|
|
18
|
+
export declare const permissionKey: z.core.$ZodBranded<z.ZodString, "PermissionKey", "out">;
|
|
19
19
|
export type PermissionKey = z.infer<typeof permissionKey>;
|
|
20
20
|
export declare const slug: z.ZodString;
|
|
21
21
|
//# sourceMappingURL=ids.d.ts.map
|
package/dist/ids.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ids.d.ts","sourceRoot":"","sources":["../src/ids.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAQxB,eAAO,MAAM,QAAQ,
|
|
1
|
+
{"version":3,"file":"ids.d.ts","sourceRoot":"","sources":["../src/ids.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAQxB,eAAO,MAAM,QAAQ,oDAA6C,CAAC;AACnE,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,QAAQ,CAAC,CAAC;AAEhD,eAAO,MAAM,OAAO,mDAA4C,CAAC;AACjE,MAAM,MAAM,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,OAAO,CAAC,CAAC;AAE9C,eAAO,MAAM,WAAW,uDAAgD,CAAC;AACzE,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,CAAC;AAKtD,eAAO,MAAM,eAAe,2DAAoD,CAAC;AACjF,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AAE9D,eAAO,MAAM,OAAO,mDAA4C,CAAC;AACjE,MAAM,MAAM,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,OAAO,CAAC,CAAC;AAE9C,eAAO,MAAM,aAAa,yDAAkD,CAAC;AAC7E,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;AAG1D,eAAO,MAAM,QAAQ,oDAGC,CAAC;AACvB,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,QAAQ,CAAC,CAAC;AAGhD,eAAO,MAAM,OAAO,mDAA2D,CAAC;AAChF,MAAM,MAAM,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,OAAO,CAAC,CAAC;AAG9C,eAAO,MAAM,aAAa,yDAGC,CAAC;AAC5B,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;AAE1D,eAAO,MAAM,IAAI,aAAwD,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,3 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The Zod instance these schemas were built with.
|
|
3
|
+
*
|
|
4
|
+
* Import `z` FROM HERE, not from 'zod', whenever you compose a contracts schema
|
|
5
|
+
* into your own — `z.object({ facility: entityRef, unitPrice: money })` is the
|
|
6
|
+
* pattern the engines themselves use, and it is what "parse, don't trust" asks
|
|
7
|
+
* of every operation input.
|
|
8
|
+
*
|
|
9
|
+
* Zod schemas do not compose across copies or majors: the mix fails at RUNTIME
|
|
10
|
+
* with `Invalid element at key "…": expected a Zod schema`, an error that points
|
|
11
|
+
* nowhere near the cause. We are on Zod 4, which is what `pnpm add zod` gives
|
|
12
|
+
* you today — so the trap is currently dormant, not gone. It re-arms the day Zod
|
|
13
|
+
* 5 ships, and it bit us once already (the packages were Zod 3 while the docs
|
|
14
|
+
* told users to install the then-current Zod 4).
|
|
15
|
+
*
|
|
16
|
+
* Importing `z` from here means the consumer never installs zod at all, so the
|
|
17
|
+
* versions cannot diverge no matter what the registry's `latest` becomes.
|
|
18
|
+
*/
|
|
19
|
+
export { z } from 'zod';
|
|
1
20
|
export * from './ids.js';
|
|
2
21
|
export * from './tenancy.js';
|
|
3
22
|
export * from './control-plane.js';
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,oBAAoB,CAAC;AACnC,cAAc,iBAAiB,CAAC;AAChC,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,YAAY,CAAC;AAC3B,cAAc,kBAAkB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AACH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,oBAAoB,CAAC;AACnC,cAAc,iBAAiB,CAAC;AAChC,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,YAAY,CAAC;AAC3B,cAAc,kBAAkB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -1,3 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The Zod instance these schemas were built with.
|
|
3
|
+
*
|
|
4
|
+
* Import `z` FROM HERE, not from 'zod', whenever you compose a contracts schema
|
|
5
|
+
* into your own — `z.object({ facility: entityRef, unitPrice: money })` is the
|
|
6
|
+
* pattern the engines themselves use, and it is what "parse, don't trust" asks
|
|
7
|
+
* of every operation input.
|
|
8
|
+
*
|
|
9
|
+
* Zod schemas do not compose across copies or majors: the mix fails at RUNTIME
|
|
10
|
+
* with `Invalid element at key "…": expected a Zod schema`, an error that points
|
|
11
|
+
* nowhere near the cause. We are on Zod 4, which is what `pnpm add zod` gives
|
|
12
|
+
* you today — so the trap is currently dormant, not gone. It re-arms the day Zod
|
|
13
|
+
* 5 ships, and it bit us once already (the packages were Zod 3 while the docs
|
|
14
|
+
* told users to install the then-current Zod 4).
|
|
15
|
+
*
|
|
16
|
+
* Importing `z` from here means the consumer never installs zod at all, so the
|
|
17
|
+
* versions cannot diverge no matter what the registry's `latest` becomes.
|
|
18
|
+
*/
|
|
19
|
+
export { z } from 'zod';
|
|
1
20
|
export * from './ids.js';
|
|
2
21
|
export * from './tenancy.js';
|
|
3
22
|
export * from './control-plane.js';
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,oBAAoB,CAAC;AACnC,cAAc,iBAAiB,CAAC;AAChC,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,YAAY,CAAC;AAC3B,cAAc,kBAAkB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AACH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,oBAAoB,CAAC;AACnC,cAAc,iBAAiB,CAAC;AAChC,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,YAAY,CAAC;AAC3B,cAAc,kBAAkB,CAAC"}
|