1 | import { Handler } from "../../handler";
|
2 | import { BaseTriggerEvent, StringMap } from "./_common";
|
3 |
|
4 | export interface BaseCustomSMSSenderTriggerEvent<T extends string> extends BaseTriggerEvent<T> {
|
5 | request: {
|
6 | type: string;
|
7 | code: string | null;
|
8 | userAttributes: StringMap;
|
9 | clientMetadata?: StringMap | undefined;
|
10 | };
|
11 | }
|
12 |
|
13 | export interface CustomSMSSenderSignUpTriggerEvent extends BaseCustomSMSSenderTriggerEvent<"CustomSMSSender_SignUp"> {}
|
14 |
|
15 | export interface CustomSMSSenderResendCodeTriggerEvent
|
16 | extends BaseCustomSMSSenderTriggerEvent<"CustomSMSSender_ResendCode">
|
17 | {}
|
18 |
|
19 | export interface CustomSMSSenderForgotPasswordTriggerEvent
|
20 | extends BaseCustomSMSSenderTriggerEvent<"CustomSMSSender_ForgotPassword">
|
21 | {}
|
22 |
|
23 | export interface CustomSMSSenderUpdateUserAttributeTriggerEvent
|
24 | extends BaseCustomSMSSenderTriggerEvent<"CustomSMSSender_UpdateUserAttribute">
|
25 | {}
|
26 |
|
27 | export interface CustomSMSSenderVerifyUserAttributeTriggerEvent
|
28 | extends BaseCustomSMSSenderTriggerEvent<"CustomSMSSender_VerifyUserAttribute">
|
29 | {}
|
30 |
|
31 | export interface CustomSMSSenderAdminCreateUserTriggerEvent
|
32 | extends BaseCustomSMSSenderTriggerEvent<"CustomSMSSender_AdminCreateUser">
|
33 | {}
|
34 |
|
35 | export interface CustomSMSSenderAuthenticationUserTriggerEvent
|
36 | extends BaseCustomSMSSenderTriggerEvent<"CustomSMSSender_Authentication">
|
37 | {}
|
38 |
|
39 |
|
40 |
|
41 |
|
42 | export type CustomSMSSenderTriggerEvent =
|
43 | | CustomSMSSenderSignUpTriggerEvent
|
44 | | CustomSMSSenderResendCodeTriggerEvent
|
45 | | CustomSMSSenderForgotPasswordTriggerEvent
|
46 | | CustomSMSSenderUpdateUserAttributeTriggerEvent
|
47 | | CustomSMSSenderVerifyUserAttributeTriggerEvent
|
48 | | CustomSMSSenderAdminCreateUserTriggerEvent
|
49 | | CustomSMSSenderAuthenticationUserTriggerEvent;
|
50 |
|
51 | export type CustomSMSSenderTriggerHandler = Handler<CustomSMSSenderTriggerEvent>;
|