@fuzdev/fuz_app 0.155.1 → 0.157.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/actions/CLAUDE.md +27 -14
- package/dist/actions/action_codegen.d.ts +10 -3
- package/dist/actions/action_codegen.d.ts.map +1 -1
- package/dist/actions/action_codegen.js +52 -13
- package/dist/actions/action_event.d.ts.map +1 -1
- package/dist/actions/action_event.js +13 -11
- package/dist/actions/action_rpc.d.ts +4 -3
- package/dist/actions/action_rpc.d.ts.map +1 -1
- package/dist/actions/action_rpc.js +4 -3
- package/dist/actions/action_spec.d.ts +102 -206
- package/dist/actions/action_spec.d.ts.map +1 -1
- package/dist/actions/action_spec.js +18 -96
- package/dist/actions/action_types.d.ts +4 -4
- package/dist/actions/action_types.d.ts.map +1 -1
- package/dist/actions/action_types.js +2 -2
- package/dist/actions/broadcast_api.d.ts.map +1 -1
- package/dist/actions/broadcast_api.js +6 -5
- package/dist/actions/compile_action_registry.d.ts +11 -6
- package/dist/actions/compile_action_registry.d.ts.map +1 -1
- package/dist/actions/compile_action_registry.js +15 -9
- package/dist/actions/perform_action.d.ts +4 -4
- package/dist/actions/perform_action.d.ts.map +1 -1
- package/dist/actions/perform_action.js +11 -11
- package/dist/auth/CLAUDE.md +1 -1
- package/dist/auth/account_action_specs.d.ts +50 -23
- package/dist/auth/account_action_specs.d.ts.map +1 -1
- package/dist/auth/account_action_specs.js +18 -8
- package/dist/auth/account_route_schema.d.ts +10 -10
- package/dist/auth/account_schema.d.ts +21 -21
- package/dist/auth/actor_lookup_action_specs.d.ts +7 -7
- package/dist/auth/actor_search_action_specs.d.ts +6 -6
- package/dist/auth/admin_action_specs.d.ts +98 -98
- package/dist/auth/app_settings_schema.d.ts +2 -2
- package/dist/auth/audit_log_route_schema.d.ts +1 -1
- package/dist/auth/audit_log_schema.d.ts +44 -44
- package/dist/auth/auth_guard_resolver.d.ts +2 -2
- package/dist/auth/auth_guard_resolver.js +2 -2
- package/dist/auth/bootstrap_route_schema.d.ts +4 -4
- package/dist/auth/cell_action_specs.d.ts +241 -241
- package/dist/auth/cell_actions.js +3 -3
- package/dist/auth/cell_audit_action_specs.d.ts +14 -14
- package/dist/auth/cell_audit_metadata.d.ts +6 -6
- package/dist/auth/cell_field_action_specs.d.ts +38 -38
- package/dist/auth/cell_field_audit_metadata.d.ts +4 -4
- package/dist/auth/cell_grant_action_specs.d.ts +61 -61
- package/dist/auth/cell_grant_audit_metadata.d.ts +10 -10
- package/dist/auth/cell_item_action_specs.d.ts +50 -50
- package/dist/auth/cell_item_audit_metadata.d.ts +5 -5
- package/dist/auth/invite_schema.d.ts +6 -6
- package/dist/auth/role_grant_offer_action_specs.d.ts +120 -120
- package/dist/auth/role_grant_offer_notifications.d.ts +66 -66
- package/dist/auth/role_grant_offer_schema.d.ts +6 -6
- package/dist/auth/self_service_role_action_specs.d.ts +2 -2
- package/dist/auth/signup_route_schema.d.ts +2 -2
- package/dist/http/CLAUDE.md +26 -17
- package/dist/http/auth_shape.d.ts +51 -17
- package/dist/http/auth_shape.d.ts.map +1 -1
- package/dist/http/auth_shape.js +101 -52
- package/dist/http/error_schemas.d.ts +15 -8
- package/dist/http/error_schemas.d.ts.map +1 -1
- package/dist/http/error_schemas.js +4 -9
- package/dist/http/jsonrpc_errors.d.ts +11 -4
- package/dist/http/jsonrpc_errors.d.ts.map +1 -1
- package/dist/http/jsonrpc_errors.js +11 -4
- package/dist/http/jsonrpc_helpers.d.ts.map +1 -1
- package/dist/http/jsonrpc_helpers.js +2 -1
- package/dist/http/route_spec.d.ts +37 -19
- package/dist/http/route_spec.d.ts.map +1 -1
- package/dist/http/route_spec.js +54 -24
- package/dist/http/schema_helpers.d.ts +27 -24
- package/dist/http/schema_helpers.d.ts.map +1 -1
- package/dist/http/schema_helpers.js +24 -19
- package/dist/http/surface.d.ts.map +1 -1
- package/dist/http/surface.js +7 -3
- package/dist/primitive_schemas.d.ts +16 -5
- package/dist/primitive_schemas.d.ts.map +1 -1
- package/dist/primitive_schemas.js +26 -4
- package/dist/primitive_schemas_fuz.d.ts +67 -0
- package/dist/primitive_schemas_fuz.d.ts.map +1 -0
- package/dist/primitive_schemas_fuz.js +47 -0
- package/dist/realtime/sse.d.ts +3 -3
- package/dist/realtime/sse.d.ts.map +1 -1
- package/dist/realtime/sse.js +4 -4
- package/dist/schema_issues.d.ts +91 -4
- package/dist/schema_issues.d.ts.map +1 -1
- package/dist/schema_issues.js +262 -1
- package/dist/schema_meta.d.ts +24 -8
- package/dist/schema_meta.d.ts.map +1 -1
- package/dist/schema_meta.js +31 -10
- package/dist/server/serve_fact_route.d.ts.map +1 -1
- package/dist/server/serve_fact_route.js +2 -1
- package/dist/testing/CLAUDE.md +23 -17
- package/dist/testing/admin_integration.d.ts.map +1 -1
- package/dist/testing/admin_integration.js +3 -2
- package/dist/testing/adversarial_404.d.ts +2 -2
- package/dist/testing/adversarial_404.d.ts.map +1 -1
- package/dist/testing/adversarial_404.js +8 -5
- package/dist/testing/adversarial_input.js +1 -1
- package/dist/testing/adversarial_input_cases.d.ts +18 -23
- package/dist/testing/adversarial_input_cases.d.ts.map +1 -1
- package/dist/testing/adversarial_input_cases.js +51 -46
- package/dist/testing/assertions.d.ts +6 -5
- package/dist/testing/assertions.d.ts.map +1 -1
- package/dist/testing/assertions.js +9 -4
- package/dist/testing/cross_backend/action_manifest.d.ts +2 -1
- package/dist/testing/cross_backend/action_manifest.d.ts.map +1 -1
- package/dist/testing/cross_backend/action_manifest.js +3 -3
- package/dist/testing/cross_backend/cell_crud.d.ts.map +1 -1
- package/dist/testing/cross_backend/cell_crud.js +3 -8
- package/dist/testing/cross_backend/conformance_table.d.ts.map +1 -1
- package/dist/testing/cross_backend/conformance_table.js +5 -4
- package/dist/testing/cross_backend/cross_rpc.d.ts +4 -2
- package/dist/testing/cross_backend/cross_rpc.d.ts.map +1 -1
- package/dist/testing/cross_backend/cross_rpc.js +6 -4
- package/dist/testing/cross_backend/rpc_success_fixtures.d.ts.map +1 -1
- package/dist/testing/cross_backend/sse_round_trip.d.ts.map +1 -1
- package/dist/testing/cross_backend/sse_round_trip.js +3 -2
- package/dist/testing/cross_backend/testing_reset_actions.d.ts +8 -8
- package/dist/testing/error_coverage.d.ts +9 -17
- package/dist/testing/error_coverage.d.ts.map +1 -1
- package/dist/testing/error_coverage.js +20 -3
- package/dist/testing/integration_helpers.d.ts.map +1 -1
- package/dist/testing/integration_helpers.js +7 -6
- package/dist/testing/rpc_envelope_cases.d.ts +3 -3
- package/dist/testing/rpc_envelope_cases.d.ts.map +1 -1
- package/dist/testing/rpc_envelope_cases.js +1 -1
- package/dist/testing/rpc_helpers.d.ts +12 -8
- package/dist/testing/rpc_helpers.d.ts.map +1 -1
- package/dist/testing/rpc_helpers.js +18 -15
- package/dist/testing/schema_generators.d.ts +75 -40
- package/dist/testing/schema_generators.d.ts.map +1 -1
- package/dist/testing/schema_generators.js +273 -99
- package/dist/testing/sse_round_trip.d.ts.map +1 -1
- package/dist/testing/sse_round_trip.js +4 -3
- package/dist/ui/admin_accounts_state.svelte.d.ts +10 -10
- package/dist/ui/admin_accounts_state.svelte.d.ts.map +1 -1
- package/dist/ui/admin_invites_state.svelte.d.ts +1 -1
- package/dist/ui/admin_invites_state.svelte.d.ts.map +1 -1
- package/dist/ui/admin_sessions_state.svelte.d.ts +2 -2
- package/dist/ui/admin_sessions_state.svelte.d.ts.map +1 -1
- package/dist/ui/role_grant_offers_state.svelte.d.ts +6 -6
- package/dist/zod.d.ts +23 -5
- package/dist/zod.d.ts.map +1 -1
- package/dist/zod.js +2 -2
- package/package.json +6 -6
|
@@ -59,13 +59,13 @@ export declare const ROLE_GRANT_REVOKE_NOTIFICATION_METHOD = "role_grant_revoke"
|
|
|
59
59
|
/** Params for `role_grant_offer_received` — offer delivered to its recipient. */
|
|
60
60
|
export declare const RoleGrantOfferReceivedParams: z.ZodObject<{
|
|
61
61
|
offer: z.ZodObject<{
|
|
62
|
-
id: z.
|
|
63
|
-
from_actor_id: z.
|
|
64
|
-
to_account_id: z.
|
|
65
|
-
to_actor_id: z.ZodNullable<z.
|
|
62
|
+
id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
63
|
+
from_actor_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
64
|
+
to_account_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
65
|
+
to_actor_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
66
66
|
role: z.ZodString;
|
|
67
67
|
scope_kind: z.ZodNullable<z.ZodString>;
|
|
68
|
-
scope_id: z.ZodNullable<z.
|
|
68
|
+
scope_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
69
69
|
message: z.ZodNullable<z.ZodString>;
|
|
70
70
|
created_at: z.ZodString;
|
|
71
71
|
expires_at: z.ZodString;
|
|
@@ -74,20 +74,20 @@ export declare const RoleGrantOfferReceivedParams: z.ZodObject<{
|
|
|
74
74
|
decline_reason: z.ZodNullable<z.ZodString>;
|
|
75
75
|
retracted_at: z.ZodNullable<z.ZodString>;
|
|
76
76
|
superseded_at: z.ZodNullable<z.ZodString>;
|
|
77
|
-
resulting_role_grant_id: z.ZodNullable<z.
|
|
77
|
+
resulting_role_grant_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
78
78
|
}, z.core.$strict>;
|
|
79
79
|
}, z.core.$strict>;
|
|
80
80
|
export type RoleGrantOfferReceivedParams = z.infer<typeof RoleGrantOfferReceivedParams>;
|
|
81
81
|
/** Params for `role_grant_offer_retracted` — grantor-side retraction. */
|
|
82
82
|
export declare const RoleGrantOfferRetractedParams: z.ZodObject<{
|
|
83
83
|
offer: z.ZodObject<{
|
|
84
|
-
id: z.
|
|
85
|
-
from_actor_id: z.
|
|
86
|
-
to_account_id: z.
|
|
87
|
-
to_actor_id: z.ZodNullable<z.
|
|
84
|
+
id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
85
|
+
from_actor_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
86
|
+
to_account_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
87
|
+
to_actor_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
88
88
|
role: z.ZodString;
|
|
89
89
|
scope_kind: z.ZodNullable<z.ZodString>;
|
|
90
|
-
scope_id: z.ZodNullable<z.
|
|
90
|
+
scope_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
91
91
|
message: z.ZodNullable<z.ZodString>;
|
|
92
92
|
created_at: z.ZodString;
|
|
93
93
|
expires_at: z.ZodString;
|
|
@@ -96,20 +96,20 @@ export declare const RoleGrantOfferRetractedParams: z.ZodObject<{
|
|
|
96
96
|
decline_reason: z.ZodNullable<z.ZodString>;
|
|
97
97
|
retracted_at: z.ZodNullable<z.ZodString>;
|
|
98
98
|
superseded_at: z.ZodNullable<z.ZodString>;
|
|
99
|
-
resulting_role_grant_id: z.ZodNullable<z.
|
|
99
|
+
resulting_role_grant_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
100
100
|
}, z.core.$strict>;
|
|
101
101
|
}, z.core.$strict>;
|
|
102
102
|
export type RoleGrantOfferRetractedParams = z.infer<typeof RoleGrantOfferRetractedParams>;
|
|
103
103
|
/** Params for `role_grant_offer_accepted` — recipient accepted the offer. */
|
|
104
104
|
export declare const RoleGrantOfferAcceptedParams: z.ZodObject<{
|
|
105
105
|
offer: z.ZodObject<{
|
|
106
|
-
id: z.
|
|
107
|
-
from_actor_id: z.
|
|
108
|
-
to_account_id: z.
|
|
109
|
-
to_actor_id: z.ZodNullable<z.
|
|
106
|
+
id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
107
|
+
from_actor_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
108
|
+
to_account_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
109
|
+
to_actor_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
110
110
|
role: z.ZodString;
|
|
111
111
|
scope_kind: z.ZodNullable<z.ZodString>;
|
|
112
|
-
scope_id: z.ZodNullable<z.
|
|
112
|
+
scope_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
113
113
|
message: z.ZodNullable<z.ZodString>;
|
|
114
114
|
created_at: z.ZodString;
|
|
115
115
|
expires_at: z.ZodString;
|
|
@@ -118,7 +118,7 @@ export declare const RoleGrantOfferAcceptedParams: z.ZodObject<{
|
|
|
118
118
|
decline_reason: z.ZodNullable<z.ZodString>;
|
|
119
119
|
retracted_at: z.ZodNullable<z.ZodString>;
|
|
120
120
|
superseded_at: z.ZodNullable<z.ZodString>;
|
|
121
|
-
resulting_role_grant_id: z.ZodNullable<z.
|
|
121
|
+
resulting_role_grant_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
122
122
|
}, z.core.$strict>;
|
|
123
123
|
}, z.core.$strict>;
|
|
124
124
|
export type RoleGrantOfferAcceptedParams = z.infer<typeof RoleGrantOfferAcceptedParams>;
|
|
@@ -129,13 +129,13 @@ export type RoleGrantOfferAcceptedParams = z.infer<typeof RoleGrantOfferAccepted
|
|
|
129
129
|
*/
|
|
130
130
|
export declare const RoleGrantOfferDeclinedParams: z.ZodObject<{
|
|
131
131
|
offer: z.ZodObject<{
|
|
132
|
-
id: z.
|
|
133
|
-
from_actor_id: z.
|
|
134
|
-
to_account_id: z.
|
|
135
|
-
to_actor_id: z.ZodNullable<z.
|
|
132
|
+
id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
133
|
+
from_actor_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
134
|
+
to_account_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
135
|
+
to_actor_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
136
136
|
role: z.ZodString;
|
|
137
137
|
scope_kind: z.ZodNullable<z.ZodString>;
|
|
138
|
-
scope_id: z.ZodNullable<z.
|
|
138
|
+
scope_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
139
139
|
message: z.ZodNullable<z.ZodString>;
|
|
140
140
|
created_at: z.ZodString;
|
|
141
141
|
expires_at: z.ZodString;
|
|
@@ -144,7 +144,7 @@ export declare const RoleGrantOfferDeclinedParams: z.ZodObject<{
|
|
|
144
144
|
decline_reason: z.ZodNullable<z.ZodString>;
|
|
145
145
|
retracted_at: z.ZodNullable<z.ZodString>;
|
|
146
146
|
superseded_at: z.ZodNullable<z.ZodString>;
|
|
147
|
-
resulting_role_grant_id: z.ZodNullable<z.
|
|
147
|
+
resulting_role_grant_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
148
148
|
}, z.core.$strict>;
|
|
149
149
|
}, z.core.$strict>;
|
|
150
150
|
export type RoleGrantOfferDeclinedParams = z.infer<typeof RoleGrantOfferDeclinedParams>;
|
|
@@ -160,13 +160,13 @@ export type RoleGrantOfferDeclinedParams = z.infer<typeof RoleGrantOfferDeclined
|
|
|
160
160
|
*/
|
|
161
161
|
export declare const RoleGrantOfferSupersedeParams: z.ZodObject<{
|
|
162
162
|
offer: z.ZodObject<{
|
|
163
|
-
id: z.
|
|
164
|
-
from_actor_id: z.
|
|
165
|
-
to_account_id: z.
|
|
166
|
-
to_actor_id: z.ZodNullable<z.
|
|
163
|
+
id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
164
|
+
from_actor_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
165
|
+
to_account_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
166
|
+
to_actor_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
167
167
|
role: z.ZodString;
|
|
168
168
|
scope_kind: z.ZodNullable<z.ZodString>;
|
|
169
|
-
scope_id: z.ZodNullable<z.
|
|
169
|
+
scope_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
170
170
|
message: z.ZodNullable<z.ZodString>;
|
|
171
171
|
created_at: z.ZodString;
|
|
172
172
|
expires_at: z.ZodString;
|
|
@@ -175,14 +175,14 @@ export declare const RoleGrantOfferSupersedeParams: z.ZodObject<{
|
|
|
175
175
|
decline_reason: z.ZodNullable<z.ZodString>;
|
|
176
176
|
retracted_at: z.ZodNullable<z.ZodString>;
|
|
177
177
|
superseded_at: z.ZodNullable<z.ZodString>;
|
|
178
|
-
resulting_role_grant_id: z.ZodNullable<z.
|
|
178
|
+
resulting_role_grant_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
179
179
|
}, z.core.$strict>;
|
|
180
180
|
reason: z.ZodEnum<{
|
|
181
181
|
sibling_accepted: "sibling_accepted";
|
|
182
182
|
role_grant_revoked: "role_grant_revoked";
|
|
183
183
|
scope_destroyed: "scope_destroyed";
|
|
184
184
|
}>;
|
|
185
|
-
cause_id: z.
|
|
185
|
+
cause_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
186
186
|
}, z.core.$strict>;
|
|
187
187
|
export type RoleGrantOfferSupersedeParams = z.infer<typeof RoleGrantOfferSupersedeParams>;
|
|
188
188
|
/**
|
|
@@ -193,9 +193,9 @@ export type RoleGrantOfferSupersedeParams = z.infer<typeof RoleGrantOfferSuperse
|
|
|
193
193
|
* target.
|
|
194
194
|
*/
|
|
195
195
|
export declare const RoleGrantRevokeParams: z.ZodObject<{
|
|
196
|
-
role_grant_id: z.
|
|
196
|
+
role_grant_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
197
197
|
role: z.ZodString;
|
|
198
|
-
scope_id: z.ZodNullable<z.
|
|
198
|
+
scope_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
199
199
|
reason: z.ZodNullable<z.ZodString>;
|
|
200
200
|
}, z.core.$strict>;
|
|
201
201
|
export type RoleGrantRevokeParams = z.infer<typeof RoleGrantRevokeParams>;
|
|
@@ -207,13 +207,13 @@ export declare const role_grant_offer_received_notification_spec: {
|
|
|
207
207
|
side_effects: true;
|
|
208
208
|
input: z.ZodObject<{
|
|
209
209
|
offer: z.ZodObject<{
|
|
210
|
-
id: z.
|
|
211
|
-
from_actor_id: z.
|
|
212
|
-
to_account_id: z.
|
|
213
|
-
to_actor_id: z.ZodNullable<z.
|
|
210
|
+
id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
211
|
+
from_actor_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
212
|
+
to_account_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
213
|
+
to_actor_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
214
214
|
role: z.ZodString;
|
|
215
215
|
scope_kind: z.ZodNullable<z.ZodString>;
|
|
216
|
-
scope_id: z.ZodNullable<z.
|
|
216
|
+
scope_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
217
217
|
message: z.ZodNullable<z.ZodString>;
|
|
218
218
|
created_at: z.ZodString;
|
|
219
219
|
expires_at: z.ZodString;
|
|
@@ -222,7 +222,7 @@ export declare const role_grant_offer_received_notification_spec: {
|
|
|
222
222
|
decline_reason: z.ZodNullable<z.ZodString>;
|
|
223
223
|
retracted_at: z.ZodNullable<z.ZodString>;
|
|
224
224
|
superseded_at: z.ZodNullable<z.ZodString>;
|
|
225
|
-
resulting_role_grant_id: z.ZodNullable<z.
|
|
225
|
+
resulting_role_grant_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
226
226
|
}, z.core.$strict>;
|
|
227
227
|
}, z.core.$strict>;
|
|
228
228
|
output: z.ZodVoid;
|
|
@@ -237,13 +237,13 @@ export declare const role_grant_offer_retracted_notification_spec: {
|
|
|
237
237
|
side_effects: true;
|
|
238
238
|
input: z.ZodObject<{
|
|
239
239
|
offer: z.ZodObject<{
|
|
240
|
-
id: z.
|
|
241
|
-
from_actor_id: z.
|
|
242
|
-
to_account_id: z.
|
|
243
|
-
to_actor_id: z.ZodNullable<z.
|
|
240
|
+
id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
241
|
+
from_actor_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
242
|
+
to_account_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
243
|
+
to_actor_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
244
244
|
role: z.ZodString;
|
|
245
245
|
scope_kind: z.ZodNullable<z.ZodString>;
|
|
246
|
-
scope_id: z.ZodNullable<z.
|
|
246
|
+
scope_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
247
247
|
message: z.ZodNullable<z.ZodString>;
|
|
248
248
|
created_at: z.ZodString;
|
|
249
249
|
expires_at: z.ZodString;
|
|
@@ -252,7 +252,7 @@ export declare const role_grant_offer_retracted_notification_spec: {
|
|
|
252
252
|
decline_reason: z.ZodNullable<z.ZodString>;
|
|
253
253
|
retracted_at: z.ZodNullable<z.ZodString>;
|
|
254
254
|
superseded_at: z.ZodNullable<z.ZodString>;
|
|
255
|
-
resulting_role_grant_id: z.ZodNullable<z.
|
|
255
|
+
resulting_role_grant_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
256
256
|
}, z.core.$strict>;
|
|
257
257
|
}, z.core.$strict>;
|
|
258
258
|
output: z.ZodVoid;
|
|
@@ -267,13 +267,13 @@ export declare const role_grant_offer_accepted_notification_spec: {
|
|
|
267
267
|
side_effects: true;
|
|
268
268
|
input: z.ZodObject<{
|
|
269
269
|
offer: z.ZodObject<{
|
|
270
|
-
id: z.
|
|
271
|
-
from_actor_id: z.
|
|
272
|
-
to_account_id: z.
|
|
273
|
-
to_actor_id: z.ZodNullable<z.
|
|
270
|
+
id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
271
|
+
from_actor_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
272
|
+
to_account_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
273
|
+
to_actor_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
274
274
|
role: z.ZodString;
|
|
275
275
|
scope_kind: z.ZodNullable<z.ZodString>;
|
|
276
|
-
scope_id: z.ZodNullable<z.
|
|
276
|
+
scope_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
277
277
|
message: z.ZodNullable<z.ZodString>;
|
|
278
278
|
created_at: z.ZodString;
|
|
279
279
|
expires_at: z.ZodString;
|
|
@@ -282,7 +282,7 @@ export declare const role_grant_offer_accepted_notification_spec: {
|
|
|
282
282
|
decline_reason: z.ZodNullable<z.ZodString>;
|
|
283
283
|
retracted_at: z.ZodNullable<z.ZodString>;
|
|
284
284
|
superseded_at: z.ZodNullable<z.ZodString>;
|
|
285
|
-
resulting_role_grant_id: z.ZodNullable<z.
|
|
285
|
+
resulting_role_grant_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
286
286
|
}, z.core.$strict>;
|
|
287
287
|
}, z.core.$strict>;
|
|
288
288
|
output: z.ZodVoid;
|
|
@@ -297,13 +297,13 @@ export declare const role_grant_offer_declined_notification_spec: {
|
|
|
297
297
|
side_effects: true;
|
|
298
298
|
input: z.ZodObject<{
|
|
299
299
|
offer: z.ZodObject<{
|
|
300
|
-
id: z.
|
|
301
|
-
from_actor_id: z.
|
|
302
|
-
to_account_id: z.
|
|
303
|
-
to_actor_id: z.ZodNullable<z.
|
|
300
|
+
id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
301
|
+
from_actor_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
302
|
+
to_account_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
303
|
+
to_actor_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
304
304
|
role: z.ZodString;
|
|
305
305
|
scope_kind: z.ZodNullable<z.ZodString>;
|
|
306
|
-
scope_id: z.ZodNullable<z.
|
|
306
|
+
scope_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
307
307
|
message: z.ZodNullable<z.ZodString>;
|
|
308
308
|
created_at: z.ZodString;
|
|
309
309
|
expires_at: z.ZodString;
|
|
@@ -312,7 +312,7 @@ export declare const role_grant_offer_declined_notification_spec: {
|
|
|
312
312
|
decline_reason: z.ZodNullable<z.ZodString>;
|
|
313
313
|
retracted_at: z.ZodNullable<z.ZodString>;
|
|
314
314
|
superseded_at: z.ZodNullable<z.ZodString>;
|
|
315
|
-
resulting_role_grant_id: z.ZodNullable<z.
|
|
315
|
+
resulting_role_grant_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
316
316
|
}, z.core.$strict>;
|
|
317
317
|
}, z.core.$strict>;
|
|
318
318
|
output: z.ZodVoid;
|
|
@@ -327,13 +327,13 @@ export declare const role_grant_offer_supersede_notification_spec: {
|
|
|
327
327
|
side_effects: true;
|
|
328
328
|
input: z.ZodObject<{
|
|
329
329
|
offer: z.ZodObject<{
|
|
330
|
-
id: z.
|
|
331
|
-
from_actor_id: z.
|
|
332
|
-
to_account_id: z.
|
|
333
|
-
to_actor_id: z.ZodNullable<z.
|
|
330
|
+
id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
331
|
+
from_actor_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
332
|
+
to_account_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
333
|
+
to_actor_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
334
334
|
role: z.ZodString;
|
|
335
335
|
scope_kind: z.ZodNullable<z.ZodString>;
|
|
336
|
-
scope_id: z.ZodNullable<z.
|
|
336
|
+
scope_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
337
337
|
message: z.ZodNullable<z.ZodString>;
|
|
338
338
|
created_at: z.ZodString;
|
|
339
339
|
expires_at: z.ZodString;
|
|
@@ -342,14 +342,14 @@ export declare const role_grant_offer_supersede_notification_spec: {
|
|
|
342
342
|
decline_reason: z.ZodNullable<z.ZodString>;
|
|
343
343
|
retracted_at: z.ZodNullable<z.ZodString>;
|
|
344
344
|
superseded_at: z.ZodNullable<z.ZodString>;
|
|
345
|
-
resulting_role_grant_id: z.ZodNullable<z.
|
|
345
|
+
resulting_role_grant_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
346
346
|
}, z.core.$strict>;
|
|
347
347
|
reason: z.ZodEnum<{
|
|
348
348
|
sibling_accepted: "sibling_accepted";
|
|
349
349
|
role_grant_revoked: "role_grant_revoked";
|
|
350
350
|
scope_destroyed: "scope_destroyed";
|
|
351
351
|
}>;
|
|
352
|
-
cause_id: z.
|
|
352
|
+
cause_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
353
353
|
}, z.core.$strict>;
|
|
354
354
|
output: z.ZodVoid;
|
|
355
355
|
async: true;
|
|
@@ -362,9 +362,9 @@ export declare const role_grant_revoke_notification_spec: {
|
|
|
362
362
|
auth: null;
|
|
363
363
|
side_effects: true;
|
|
364
364
|
input: z.ZodObject<{
|
|
365
|
-
role_grant_id: z.
|
|
365
|
+
role_grant_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
366
366
|
role: z.ZodString;
|
|
367
|
-
scope_id: z.ZodNullable<z.
|
|
367
|
+
scope_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
368
368
|
reason: z.ZodNullable<z.ZodString>;
|
|
369
369
|
}, z.core.$strict>;
|
|
370
370
|
output: z.ZodVoid;
|
|
@@ -111,13 +111,13 @@ export interface CreateRoleGrantOfferInput {
|
|
|
111
111
|
}
|
|
112
112
|
/** Zod schema for client-safe role_grant offer data. */
|
|
113
113
|
export declare const RoleGrantOfferJson: z.ZodObject<{
|
|
114
|
-
id: z.
|
|
115
|
-
from_actor_id: z.
|
|
116
|
-
to_account_id: z.
|
|
117
|
-
to_actor_id: z.ZodNullable<z.
|
|
114
|
+
id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
115
|
+
from_actor_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
116
|
+
to_account_id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
117
|
+
to_actor_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
118
118
|
role: z.ZodString;
|
|
119
119
|
scope_kind: z.ZodNullable<z.ZodString>;
|
|
120
|
-
scope_id: z.ZodNullable<z.
|
|
120
|
+
scope_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
121
121
|
message: z.ZodNullable<z.ZodString>;
|
|
122
122
|
created_at: z.ZodString;
|
|
123
123
|
expires_at: z.ZodString;
|
|
@@ -126,7 +126,7 @@ export declare const RoleGrantOfferJson: z.ZodObject<{
|
|
|
126
126
|
decline_reason: z.ZodNullable<z.ZodString>;
|
|
127
127
|
retracted_at: z.ZodNullable<z.ZodString>;
|
|
128
128
|
superseded_at: z.ZodNullable<z.ZodString>;
|
|
129
|
-
resulting_role_grant_id: z.ZodNullable<z.
|
|
129
|
+
resulting_role_grant_id: z.ZodNullable<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
130
130
|
}, z.core.$strict>;
|
|
131
131
|
export type RoleGrantOfferJson = z.infer<typeof RoleGrantOfferJson>;
|
|
132
132
|
/** Convert a `RoleGrantOffer` row to its JSON payload shape. */
|
|
@@ -15,7 +15,7 @@ export declare const ERROR_ROLE_NOT_SELF_SERVICE_ELIGIBLE: "role_not_self_servic
|
|
|
15
15
|
export declare const SelfServiceRoleSetInput: z.ZodObject<{
|
|
16
16
|
role: z.ZodString;
|
|
17
17
|
enabled: z.ZodBoolean;
|
|
18
|
-
acting: z.ZodOptional<z.
|
|
18
|
+
acting: z.ZodOptional<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
19
19
|
}, z.core.$strict>;
|
|
20
20
|
export type SelfServiceRoleSetInput = z.infer<typeof SelfServiceRoleSetInput>;
|
|
21
21
|
/**
|
|
@@ -55,7 +55,7 @@ export declare const self_service_role_set_action_spec: {
|
|
|
55
55
|
input: z.ZodObject<{
|
|
56
56
|
role: z.ZodString;
|
|
57
57
|
enabled: z.ZodBoolean;
|
|
58
|
-
acting: z.ZodOptional<z.
|
|
58
|
+
acting: z.ZodOptional<z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>>;
|
|
59
59
|
}, z.core.$strict>;
|
|
60
60
|
output: z.ZodObject<{
|
|
61
61
|
ok: z.ZodLiteral<true>;
|
|
@@ -30,11 +30,11 @@ export type SignupInput = z.infer<typeof SignupInput>;
|
|
|
30
30
|
export declare const SignupOutput: z.ZodObject<{
|
|
31
31
|
ok: z.ZodLiteral<true>;
|
|
32
32
|
account: z.ZodObject<{
|
|
33
|
-
id: z.
|
|
33
|
+
id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
34
34
|
username: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
35
35
|
}, z.core.$strict>;
|
|
36
36
|
actor: z.ZodObject<{
|
|
37
|
-
id: z.
|
|
37
|
+
id: z.ZodUUID & z.ZodType<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string, z.core.$ZodTypeInternals<import("@fuzdev/fuz_schema/schema.js").Branded<string, "Uuid">, string>>;
|
|
38
38
|
}, z.core.$strict>;
|
|
39
39
|
}, z.core.$strict>;
|
|
40
40
|
export type SignupOutput = z.infer<typeof SignupOutput>;
|
package/dist/http/CLAUDE.md
CHANGED
|
@@ -15,7 +15,7 @@ effects, see ../../../docs/architecture.md.
|
|
|
15
15
|
## Module Map
|
|
16
16
|
|
|
17
17
|
- `http/route_spec.ts` — `RouteSpec` + `apply_route_specs`, validation pipeline, transactions.
|
|
18
|
-
- `http/auth_shape.ts` — canonical `RouteAuth` Zod schema + cross-axis invariants
|
|
18
|
+
- `http/auth_shape.ts` — canonical `RouteAuth` Zod schema + predicates + the registration-time checks: `assert_route_auth_invariants` (the cross-axis invariants 1, 3, 4) and `assert_route_auth_acting_biconditional` (invariant 2), both run by `apply_route_specs` and `compile_action_registry` on every spec.
|
|
19
19
|
- `http/error_schemas.ts` — `ERROR_*` constants, standard error shapes, `derive_error_schemas`.
|
|
20
20
|
- `http/schema_helpers.ts` — shared Zod introspection (null/void/strict/surface/merge/middleware-applies) + `to_void_params` / `to_input_params` / `json_has_own_proto_key` / `safe_parse_dropping_unknown_keys`.
|
|
21
21
|
- `http/middleware_spec.ts` — `MiddlewareSpec` interface.
|
|
@@ -48,19 +48,26 @@ consumers.
|
|
|
48
48
|
- `auth: RouteAuth` — flat record `{account, actor, roles?, credential_types?, required_scope?}` from `http/auth_shape.ts`. `account` / `actor` are `'none' | 'optional' | 'required'`. `required_scope` names the capability a narrowed api token's scope must admit — `surface:<name>`, a non-RPC surface refused to every narrowed token (an `rpc:<method>` capability throws at registration: it is the dispatcher's per-method gate, which a route never reaches) — and is route-spec-only: `compile_action_registry` rejects it on an `ActionSpec`, where the dispatcher derives `rpc:<method>` from `spec.method`. Otherwise the same shape governs `ActionSpec.auth` (see `actions/CLAUDE.md`).
|
|
49
49
|
- `handler: RouteHandler` — `(c: Context, route: RouteContext) => Response | Promise<Response>`
|
|
50
50
|
- `description` — free-text, surfaced in `AppSurface`
|
|
51
|
-
- `params?: z.ZodObject` — strict-object schema for URL path params
|
|
52
|
-
- `query?: z.ZodObject` — strict-object schema for URL query string
|
|
53
|
-
- `input:
|
|
54
|
-
- `output:
|
|
51
|
+
- `params?: z.ZodObject | AnySchema` — strict-object schema for URL path params
|
|
52
|
+
- `query?: z.ZodObject | AnySchema` — strict-object schema for URL query string
|
|
53
|
+
- `input: ValidationSchema` — request body schema; `z.null()` (or fuz_schema `literal(null)`) for no-body (GET/DELETE)
|
|
54
|
+
- `output: ValidationSchema` — success response schema
|
|
55
55
|
- `mints_credential?: boolean` — the route issues a session cookie while declaring no auth (login, signup, bootstrap); assembly refuses it outside `AUTH_MIDDLEWARE_PATH`, as it does any route whose `auth.account` is not `'none'` (`assert_credential_routes_in_auth_scope` in `auth/middleware.ts`)
|
|
56
56
|
- `reads_credential?: boolean` — the handler reads the resolved account while the route declares no auth gate, answering an anonymous caller itself (account status, the cell-scoped fact read, `create_rpc_endpoint`'s pair, whose dispatcher gates per action); held inside `AUTH_MIDDLEWARE_PATH` by the same assertion. Such a handler reads the account through `get_public_account_id` (`auth/request_context.ts`), which answers a scope-narrowed token as anonymous — the RPC pair excepted, its dispatcher gating each method
|
|
57
57
|
- `rate_limit?: RateLimitKey` — metadata only (`'ip' | 'account' | 'both'`); auto-derives 429
|
|
58
58
|
- `errors?: RouteErrorSchemas` — handler-specific error schemas keyed by HTTP status
|
|
59
59
|
- `transaction?: boolean` — declarative transaction wrapping (see below)
|
|
60
60
|
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
61
|
+
Every schema field takes a Zod or a `@fuzdev/fuz_schema` schema
|
|
62
|
+
(`ValidationSchema`, `schema_issues.ts`), validated through `parse_any`, its
|
|
63
|
+
refusals answered with `to_wire_issues`'s `WireIssue`s either way. A fuz_schema
|
|
64
|
+
`params` or `query` must be an object schema under any wrappers
|
|
65
|
+
(`get_schema_entries`); `apply_route_specs` throws naming the route on one that
|
|
66
|
+
isn't. Input/output naming mirrors SAES `ActionSpec`. Use a strict object for
|
|
67
|
+
inputs — `z.strictObject()` or fuz_schema's `object` — the surface diagnostic
|
|
68
|
+
warns on non-strict objects because unknown keys are silently stripped by Zod
|
|
69
|
+
4's default `z.object()` (and by fuz_schema's `strip_object`, kept by its
|
|
70
|
+
`loose_object`); the warning names the library's strict form.
|
|
64
71
|
|
|
65
72
|
### `RouteContext` — per-request deps
|
|
66
73
|
|
|
@@ -99,12 +106,12 @@ wrapper). See `auth/signup_routes.ts`.
|
|
|
99
106
|
|
|
100
107
|
`apply_route_specs` assembles the following middleware chain per spec:
|
|
101
108
|
|
|
102
|
-
1. **Params validation** — `spec.params` → `validated_params` context var; mismatch returns 400 `ERROR_INVALID_ROUTE_PARAMS` with
|
|
109
|
+
1. **Params validation** — `spec.params` → `validated_params` context var; mismatch returns 400 `ERROR_INVALID_ROUTE_PARAMS` with `issues`
|
|
103
110
|
2. **Query validation** — `spec.query` → `validated_query`; mismatch returns 400 `ERROR_INVALID_QUERY_PARAMS`
|
|
104
111
|
3. **Pre-authorization auth guards** — every gate that reads only what the auth middleware set, in coarse-to-fine order: `require_auth` (401 `ERROR_AUTHENTICATION_REQUIRED`) when `auth.account === 'required'` or `auth.actor === 'required'`; `require_credential_types(types)` (403 `ERROR_CREDENTIAL_TYPE_REQUIRED` with `required_credential_types: ReadonlyArray<string>`) when `auth.credential_types?.length`; `require_token_scope(capability)` (403 `ERROR_TOKEN_SCOPE_REQUIRED` with `required_scope`, the token-scope refusal) when `auth.required_scope` names a capability. All fire before any body parsing — so a caller they refuse never sees route-shape information from input parse failures — and before actor resolution, so a wrong channel costs no DB work and never learns account state (e.g. that the account is multi-actor). The `AuthGuardResolver` (e.g. `fuz_auth_guard_resolver` from `auth/auth_guard_resolver.ts`) returns this set as `pre_authorization: Array<MiddlewareHandler>`.
|
|
105
112
|
4. **Authorization phase** — when `spec.auth.actor !== 'none'`, resolves the acting actor against the resolved credential's account (`get_resolved_auth`, set by the auth middleware) plus the `acting` selector (`validated_query.acting` on GETs; read off the raw body on mutations, since body validation now runs after the gates), builds `RequestContext` via `build_request_context`, and sets `REQUEST_CONTEXT_KEY`. When `auth.account !== 'none' && auth.actor === 'none'`, an account-only context is built. Resolution failures return 400 `ERROR_ACTOR_REQUIRED` (with `available[]`) or `ERROR_ACTOR_NOT_ON_ACCOUNT` (or 500 `ERROR_NO_ACTORS_ON_ACCOUNT` on signup-invariant violation, 500 `ERROR_ACCOUNT_VANISHED` on torn account/actor reads after a successful resolve). Public routes (`account: 'none' && actor: 'none'`) skip this phase entirely.
|
|
106
113
|
5. **Post-authorization auth guards** — `require_role(roles)` (403 `ERROR_INSUFFICIENT_PERMISSIONS` with `required_roles: ReadonlyArray<string>`) when `auth.roles?.length`. The only gate in this phase, because it is the only one that reads `REQUEST_CONTEXT_KEY` (populated by step 4) rather than the auth middleware's own context vars. Multi-role specs admit any-of via `has_any_scoped_role(ctx, roles, null)`.
|
|
107
|
-
6. **Input validation** — JSON body parsed + validated; mismatch returns 400 `ERROR_INVALID_JSON_BODY` (not JSON) or `ERROR_INVALID_REQUEST_BODY` (schema failure with `issues`). Skipped on GET and `z.null()` inputs. The validated input lands on `c.var.validated_input`.
|
|
114
|
+
6. **Input validation** — JSON body parsed + validated; mismatch returns 400 `ERROR_INVALID_JSON_BODY` (not JSON) or `ERROR_INVALID_REQUEST_BODY` (schema failure with `issues`). Every schema refusal's `issues` are `WireIssue`s (`to_wire_issues`, `schema_issues.ts`), sent under DEV only (`dev_only`). Skipped on GET and `z.null()` inputs. The validated input lands on `c.var.validated_input`.
|
|
108
115
|
7. **Handler** — wrapped in transaction when `use_transaction` (see above), receives `RouteContext`
|
|
109
116
|
8. **Error catch** — catches a thrown JSON-RPC error (`ThrownJsonrpcError`, recognized by brand through `to_thrown_jsonrpc_error`, so one from a second fuz_app copy maps too; a foreign error class carrying a JSON-RPC `code` falls to the generic path) → maps to HTTP status + the flat REST `ApiError` body (`{error: <reason>, message?, ...rest_data}`); catches generic `Error` → 500 `{error: 'internal_error', message?}` (message only in DEV). The reason string comes from `err.data.reason` when set (consumer-supplied canonical reason override) or from `jsonrpc_error_code_to_name(err.code)` (e.g. `-32003 → 'not_found'`). The flat shape matches what middleware and direct handlers emit — REST callers see one envelope across every emit site, while the JSON-RPC dispatcher keeps its own `{jsonrpc, id, error: {code, message, data}}` envelope on the RPC mount.
|
|
110
117
|
9. **DEV-only output + error validation** — wraps the error catch (see below), so a body built from a thrown error is validated like a returned one
|
|
@@ -124,7 +131,8 @@ Duplicate `method path` pairs throw at registration.
|
|
|
124
131
|
|
|
125
132
|
Validated values are accessed via `get_route_input(c, schema)`,
|
|
126
133
|
`get_route_params(c, schema)`, `get_route_query(c, schema)` — pass the
|
|
127
|
-
matching Zod
|
|
134
|
+
matching schema, Zod or fuz_schema, and the return type infers as
|
|
135
|
+
`ValidationOutput<typeof schema>`.
|
|
128
136
|
Each helper has a `<T>(c)` overload (no schema arg) for callers without the
|
|
129
137
|
schema in scope.
|
|
130
138
|
|
|
@@ -157,7 +165,7 @@ WS); see ../../../docs/architecture.md §DEV-only Output Validation.
|
|
|
157
165
|
|
|
158
166
|
- `ERROR_*` `snake_case` string constants — single source of truth; use `.literal(ERROR_*)` in Zod schemas and inline checks in handlers
|
|
159
167
|
- `ApiError`, `ValidationError`, `PermissionError`, `CredentialTypeRequiredError`, `RateLimitError`, `PayloadTooLargeError`, `UnsupportedContentTypeError`, `ForeignKeyError` — standard shapes
|
|
160
|
-
- `RouteErrorSchemas = Partial<Record<number,
|
|
168
|
+
- `RouteErrorSchemas = Partial<Record<number, ValidationSchema>>` — Zod or fuz_schema, on `RouteSpec.errors` and `MiddlewareSpec.errors`; `derive_error_schemas` returns the Zod-only `DerivedErrorSchemas`
|
|
161
169
|
- `RateLimitKey = 'ip' | 'account' | 'both'`
|
|
162
170
|
|
|
163
171
|
All standard shapes use `z.looseObject` — intentional because multiple
|
|
@@ -199,8 +207,9 @@ documents the framework's own emissions; consumers tighten via
|
|
|
199
207
|
|
|
200
208
|
The same auto-derivation pattern is **not** appropriate for
|
|
201
209
|
consumer-authored inputs (or handler outputs). A consumer's spec declares
|
|
202
|
-
the exact `acting?: ActingActor` slot
|
|
203
|
-
|
|
210
|
+
the exact `acting?: ActingActor` slot (the Zod one, or its fuz_schema twin
|
|
211
|
+
in `primitive_schemas_fuz.ts` for a fuz_schema input), and the framework
|
|
212
|
+
reads it back via reference-equality to drive the authorization phase — auto-extending
|
|
204
213
|
schemas at registration time would obscure the source of truth ("did the
|
|
205
214
|
spec declare this, or did the framework graft it on?") and quietly shadow
|
|
206
215
|
consumer fields named `acting` that aren't the canonical `ActingActor`.
|
|
@@ -234,9 +243,9 @@ only imports and re-uses them for generation logic.
|
|
|
234
243
|
Key helpers:
|
|
235
244
|
|
|
236
245
|
- `is_null_schema(schema)` — `instanceof z.ZodNull`, or a fuz_schema `literal(null)` (a kind check, not parse-null, to avoid false positives from `z.nullable(z.string())`)
|
|
237
|
-
- `is_void_schema(schema)` — `instanceof z.ZodVoid
|
|
238
|
-
- `to_void_params(raw_params)` — reads absent, `null`, and `{}` params of a
|
|
239
|
-
- `to_input_params(input, raw_params)` — the one params normalizer every receiving end runs before the input parse (`parse_any`): `to_void_params` for a
|
|
246
|
+
- `is_void_schema(schema)` — `instanceof z.ZodVoid`, or a fuz_schema `literal(undefined)` (what `s.void` is, a `meta` copy included; a kind check like `is_null_schema`, so neither `z.undefined()` nor an optional schema is void); a void input declares a parameterless RPC method
|
|
247
|
+
- `to_void_params(raw_params)` — reads absent, `null`, and `{}` params of a void input as the no-arg call (`undefined`), passing any other shape through for the void schema to refuse — the twin of the Rust spine's `require_void_params`
|
|
248
|
+
- `to_input_params(input, raw_params)` — the one params normalizer every receiving end runs before the input parse (`parse_any`), Zod or fuz_schema: `to_void_params` for a void input, else absent/`null` → `{}`; used by both the server dispatch core (`perform_action`) and the peer receive path (`ActionDispatcher`)
|
|
240
249
|
- `json_has_own_proto_key(value)` — whether any object in a parsed JSON value has an own `__proto__` key, by an iterative walk (no recursion — `JSON.parse` nests deeper than the call stack); the dispatcher refuses such params with `ERROR_PARAMS_PROTO_KEY`. Twin of the Rust `fuz_http::json_has_own_proto_key`
|
|
241
250
|
- `safe_parse_dropping_unknown_keys(schema, value)` — the forward-compatible read of a remote-authored payload, Zod or fuz_schema, returning `parse_any`'s `{ok, value}` / `{ok: false, issues}`: while every issue is an unknown key (`unknown_key_targets`), strips them from a copy and reparses — after the first parse that reports unknown keys, one schema-guided pass deletes every key a strict fuz_schema `object` doesn't name anywhere the schema reaches (entries, array items, record values, the `variant` option), as a fuz_schema parse reports at most a hundred issues; a key under a fuz_schema `union` is never stripped (the union fails as one issue of its own), and a later `pipe` stage is stripped only as reported — until nothing is left to strip, capped at `UNKNOWN_KEY_PASSES_MAX` passes (the last failure returned past it); any other issue still fails. A Zod union of strict objects reports the key and is stripped, a fuz_schema `union` reports one issue of its own and is not. Used for response `result`s (`ActionEvent`) and peer replies (`peer/ping`); matches serde's ignore-unknown-fields default on the Rust spine
|
|
242
251
|
- `is_strict_object_schema(schema)` — detects `z.strictObject()` by checking `schema.def.catchall instanceof z.ZodNever`, or a fuz_schema `object` (not `strip_object` / `loose_object`); a fuz_schema `pipe` is read through to its first schema when no stage is a `transform` (so a refined `object` reads strict), while any Zod `ZodPipe` — even `O.pipe(O)` with no transform — reads not strict
|