squarefi-bff-api-module 1.25.5 → 1.25.6

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.
@@ -11,13 +11,15 @@ export declare const auth: {
11
11
  };
12
12
  signin: {
13
13
  omni: {
14
- email: (data: API.Auth.SignIn.Email.OTP.Request) => Promise<API.Auth.Tokens>;
15
- phone: ({ phone, ...data }: API.Auth.SignIn.Phone.OTP.Request) => Promise<API.Auth.Tokens>;
14
+ email: (data: API.Auth.SignIn.Omni.Email.OTP.Request) => Promise<API.Auth.Tokens>;
15
+ phone: ({ phone, ...data }: API.Auth.SignIn.Omni.Phone.OTP.Request) => Promise<API.Auth.Tokens>;
16
16
  };
17
+ byType: (data: API.Auth.SignIn.ByType.Request) => Promise<API.Auth.Tokens>;
17
18
  telegram: (data: API.Auth.Telegram.Signin.Request) => Promise<API.Auth.Telegram.Signin.Response>;
18
19
  password: (email: string, password: string) => Promise<API.Auth.Tokens>;
19
20
  };
20
21
  signup: {
22
+ byType: (data: API.Auth.SignUp.ByType.Request) => Promise<API.Auth.Tokens>;
21
23
  password: (email: string, password: string) => Promise<API.Auth.Tokens>;
22
24
  telegram: (data: API.Auth.Telegram.Signup.Request) => Promise<API.Auth.Telegram.Signup.Response>;
23
25
  };
package/dist/api/auth.js CHANGED
@@ -39,6 +39,7 @@ exports.auth = {
39
39
  });
40
40
  },
41
41
  },
42
+ byType: (data) => apiClientFactory_1.apiClientV2.postRequest('/auth/sign-in', { data }),
42
43
  telegram: (data) => apiClientFactory_1.apiClientV2.postRequest(exports.telegramSignInPath, { data }),
43
44
  password: (email, password // check on backend V2
44
45
  ) => apiClientFactory_1.apiClientV2.postRequest('/auth/sign-in/password/email', {
@@ -46,6 +47,7 @@ exports.auth = {
46
47
  }),
47
48
  },
48
49
  signup: {
50
+ byType: (data) => apiClientFactory_1.apiClientV2.postRequest('/auth/sign-up', { data }),
49
51
  password: (email, password) => apiClientFactory_1.apiClientV2.postRequest('/auth/sign-up/password/email', {
50
52
  data: { email, password },
51
53
  }),
@@ -1888,6 +1888,7 @@ export interface components {
1888
1888
  /** @enum {string} */
1889
1889
  action: "verification";
1890
1890
  type: string;
1891
+ full_name: string | null;
1891
1892
  url: string;
1892
1893
  };
1893
1894
  WalletKycRailTermsAndConditionsDto: {
@@ -29,27 +29,35 @@ export declare namespace API {
29
29
  }
30
30
  }
31
31
  namespace SignIn {
32
- namespace Email {
33
- namespace OTP {
34
- interface Request {
35
- email: string;
36
- invite_code?: string;
37
- referrer?: string;
38
- redirect_url?: string;
32
+ namespace ByType {
33
+ type Request = operations['AuthController_signIn']['requestBody']['content']['application/json'];
34
+ }
35
+ namespace Omni {
36
+ namespace Email {
37
+ namespace OTP {
38
+ interface Request {
39
+ email: string;
40
+ invite_code?: string;
41
+ referrer?: string;
42
+ redirect_url?: string;
43
+ }
39
44
  }
40
45
  }
41
- }
42
- namespace Phone {
43
- namespace OTP {
44
- interface Request {
45
- phone: string;
46
- invite_code?: string;
47
- referrer?: string;
46
+ namespace Phone {
47
+ namespace OTP {
48
+ interface Request {
49
+ phone: string;
50
+ invite_code?: string;
51
+ referrer?: string;
52
+ }
48
53
  }
49
54
  }
50
55
  }
51
56
  }
52
57
  namespace SignUp {
58
+ namespace ByType {
59
+ type Request = operations['AuthController_signUp']['requestBody']['content']['application/json'];
60
+ }
53
61
  namespace Password {
54
62
  interface Request {
55
63
  email: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "squarefi-bff-api-module",
3
- "version": "1.25.5",
3
+ "version": "1.25.6",
4
4
  "description": "Squarefi BFF API client module",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
package/src/api/auth.ts CHANGED
@@ -24,13 +24,15 @@ export const auth = {
24
24
  },
25
25
  signin: {
26
26
  omni: {
27
- email: (data: API.Auth.SignIn.Email.OTP.Request): Promise<API.Auth.Tokens> =>
28
- apiClientV2.postRequest<API.Auth.Tokens>('/auth/sign-in/omni/email/otp', { data }),
29
- phone: ({ phone, ...data }: API.Auth.SignIn.Phone.OTP.Request): Promise<API.Auth.Tokens> =>
30
- apiClientV2.postRequest<API.Auth.Tokens>('/auth/sign-in/omni/phone/otp', {
27
+ email: (data: API.Auth.SignIn.Omni.Email.OTP.Request): Promise<API.Auth.Tokens> =>
28
+ apiClientV2.postRequest('/auth/sign-in/omni/email/otp', { data }),
29
+ phone: ({ phone, ...data }: API.Auth.SignIn.Omni.Phone.OTP.Request): Promise<API.Auth.Tokens> =>
30
+ apiClientV2.postRequest('/auth/sign-in/omni/phone/otp', {
31
31
  data: { phone: convertPhoneToSupabaseFormat(phone), ...data },
32
32
  }),
33
33
  },
34
+ byType: (data: API.Auth.SignIn.ByType.Request): Promise<API.Auth.Tokens> =>
35
+ apiClientV2.postRequest('/auth/sign-in', { data }),
34
36
  telegram: (data: API.Auth.Telegram.Signin.Request): Promise<API.Auth.Telegram.Signin.Response> =>
35
37
  apiClientV2.postRequest<API.Auth.Telegram.Signin.Response>(telegramSignInPath, { data }),
36
38
  password: (
@@ -42,6 +44,8 @@ export const auth = {
42
44
  }),
43
45
  },
44
46
  signup: {
47
+ byType: (data: API.Auth.SignUp.ByType.Request): Promise<API.Auth.Tokens> =>
48
+ apiClientV2.postRequest('/auth/sign-up', { data }),
45
49
  password: (email: string, password: string): Promise<API.Auth.Tokens> =>
46
50
  apiClientV2.postRequest<API.Auth.Tokens>('/auth/sign-up/password/email', {
47
51
  data: { email, password },
@@ -1889,6 +1889,7 @@ export interface components {
1889
1889
  /** @enum {string} */
1890
1890
  action: "verification";
1891
1891
  type: string;
1892
+ full_name: string | null;
1892
1893
  url: string;
1893
1894
  };
1894
1895
  WalletKycRailTermsAndConditionsDto: {
@@ -55,29 +55,39 @@ export namespace API {
55
55
  }
56
56
 
57
57
  export namespace SignIn {
58
- export namespace Email {
59
- export namespace OTP {
60
- export interface Request {
61
- email: string;
62
- invite_code?: string;
63
- referrer?: string;
64
- redirect_url?: string;
58
+ export namespace ByType {
59
+ export type Request = operations['AuthController_signIn']['requestBody']['content']['application/json'];
60
+ }
61
+
62
+ export namespace Omni {
63
+ export namespace Email {
64
+ export namespace OTP {
65
+ export interface Request {
66
+ email: string;
67
+ invite_code?: string;
68
+ referrer?: string;
69
+ redirect_url?: string;
70
+ }
65
71
  }
66
72
  }
67
- }
68
73
 
69
- export namespace Phone {
70
- export namespace OTP {
71
- export interface Request {
72
- phone: string;
73
- invite_code?: string;
74
- referrer?: string;
74
+ export namespace Phone {
75
+ export namespace OTP {
76
+ export interface Request {
77
+ phone: string;
78
+ invite_code?: string;
79
+ referrer?: string;
80
+ }
75
81
  }
76
82
  }
77
83
  }
78
84
  }
79
85
 
80
86
  export namespace SignUp {
87
+ export namespace ByType {
88
+ export type Request = operations['AuthController_signUp']['requestBody']['content']['application/json'];
89
+ }
90
+
81
91
  export namespace Password {
82
92
  export interface Request {
83
93
  email: string;