Skip to content

Commit 5b333ec

Browse files
committed
feat: user:pre_registration
1 parent bdd51bb commit 5b333ec

File tree

1 file changed

+27
-1
lines changed

1 file changed

+27
-1
lines changed

lib/types.ts

Lines changed: 27 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,7 @@ export enum WorkflowTrigger {
9595
NewPasswordProvided = "user:new_password_provided",
9696
PlanSelection = "user:plan_selection",
9797
PlanCancellationRequest = "user:plan_cancellation_request",
98+
UserPreRegistration = "user:pre_registration",
9899
}
99100

100101
export type WorkflowEvents =
@@ -105,7 +106,8 @@ export type WorkflowEvents =
105106
| onNewPasswordProvidedEvent
106107
| onUserPreMFA
107108
| onPlanSelection
108-
| onPlanCancellationRequest;
109+
| onPlanCancellationRequest
110+
| onUserPreRegistrationEvent;
109111

110112
type EventBase = {
111113
request: RequestContext;
@@ -201,6 +203,30 @@ export type onPostAuthenticationEvent = EventBase & {
201203
};
202204
};
203205

206+
export type onUserPreRegistrationEvent = EventBase & {
207+
request: {
208+
ip: string;
209+
userAgent: string;
210+
authUrlParams: LoginMethodParams & {
211+
state: string;
212+
};
213+
},
214+
context: {
215+
auth: {
216+
connectionId: string;
217+
},
218+
workflow: {
219+
trigger: WorkflowTrigger.UserPreRegistration;
220+
};
221+
domains: {
222+
kindeDomain: string;
223+
};
224+
application: {
225+
clientId: string;
226+
};
227+
};
228+
};
229+
204230
export type onExistingPasswordProvidedEvent = EventBase & {
205231
request: {
206232
auth: never;

0 commit comments

Comments
 (0)