@temboplus/afloat 0.1.77-beta.18 → 0.1.77-beta.20

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.
Files changed (34) hide show
  1. package/dist/index.cjs.js +1 -1
  2. package/dist/index.cjs.js.map +1 -1
  3. package/dist/index.esm.js +1 -1
  4. package/dist/index.esm.js.map +1 -1
  5. package/dist/lib/api/base-repository.d.ts +3 -1
  6. package/dist/modules/auth/auth.contract.d.ts +2 -2
  7. package/dist/modules/auth/company-membership.model.d.ts +4 -4
  8. package/dist/modules/auth/index.d.ts +0 -1
  9. package/dist/modules/auth/user.model.d.ts +10 -10
  10. package/dist/modules/contact/contact.api-contract.d.ts +8 -8
  11. package/dist/modules/contact/contact.dtos.d.ts +2 -2
  12. package/dist/modules/contact/contact.model.d.ts +4 -4
  13. package/dist/modules/login/login.api-contract.d.ts +2 -2
  14. package/dist/modules/login/login.dtos.d.ts +4 -4
  15. package/dist/modules/login/login.model.d.ts +2 -2
  16. package/dist/modules/payout/payout.api-contract.d.ts +37 -37
  17. package/dist/modules/payout/payout.dtos.d.ts +26 -26
  18. package/dist/modules/payout/payout.model.d.ts +6 -6
  19. package/dist/modules/payout/payout.repository.d.ts +13 -2
  20. package/dist/modules/team-member/role.model.d.ts +2 -2
  21. package/dist/modules/team-member/team-member.contract.d.ts +44 -44
  22. package/dist/modules/team-member/team-member.dtos.d.ts +14 -14
  23. package/dist/modules/team-member/team-member.model.d.ts +6 -6
  24. package/dist/modules/wallet/index.d.ts +0 -1
  25. package/dist/modules/wallet/wallet.contract.d.ts +6 -6
  26. package/dist/modules/wallet/wallet.dtos.d.ts +12 -12
  27. package/dist/modules/wallet/wallet.model.d.ts +4 -4
  28. package/package.json +1 -1
  29. package/dist/modules/auth/auth.manager.d.ts +0 -249
  30. package/dist/modules/auth/auth.store.d.ts +0 -139
  31. package/dist/modules/auth/storage/client-store.d.ts +0 -29
  32. package/dist/modules/auth/storage/client-token-handler.d.ts +0 -31
  33. package/dist/modules/auth/storage/types.d.ts +0 -41
  34. package/dist/modules/wallet/wallet-manager.session.d.ts +0 -143
@@ -1,5 +1,7 @@
1
1
  import { AppRouter } from "@ts-rest/core";
2
2
  import { InitClientArgs } from "@ts-rest/core";
3
+ export type TokenGetter = () => string | undefined;
4
+ export declare const setGlobalTokenGetter: (getter: TokenGetter) => void;
3
5
  /**
4
6
  * BaseRepository - Generic base class for API repositories
5
7
  *
@@ -75,7 +77,7 @@ export declare class BaseRepository<TContract extends AppRouter> {
75
77
  *
76
78
  * Uses a fallback chain to find a valid token:
77
79
  * 1. Instance token (set in constructor)
78
- * 2. Global authentication state via getCurrentToken()
80
+ * 2. Global token getter (set by host app)
79
81
  * 3. Return an empty string if no token is found (e.g., for public/unauthenticated endpoints)
80
82
  *
81
83
  * @protected
@@ -53,9 +53,9 @@ export declare const authContract: {
53
53
  access: z.ZodArray<z.ZodString, "many">;
54
54
  resetPassword: z.ZodBoolean;
55
55
  }, "strip", z.ZodTypeAny, {
56
+ token: string;
56
57
  resetPassword: boolean;
57
58
  access: string[];
58
- token: string;
59
59
  profile: {
60
60
  id: string;
61
61
  displayName: string;
@@ -67,9 +67,9 @@ export declare const authContract: {
67
67
  autoApprove?: boolean | null | undefined;
68
68
  };
69
69
  }, {
70
+ token: string;
70
71
  resetPassword: boolean;
71
72
  access: string[];
72
- token: string;
73
73
  profile: {
74
74
  id: string;
75
75
  displayName: string;
@@ -46,16 +46,16 @@ export declare const CompanyMembershipJSONSchema: z.ZodObject<{
46
46
  version: z.ZodDefault<z.ZodOptional<z.ZodString>>;
47
47
  }, "strip", z.ZodTypeAny, {
48
48
  name: string;
49
+ createdAt: string;
49
50
  id: string;
50
51
  version: string;
51
- createdAt: string;
52
52
  updatedAt: string;
53
53
  access: string[];
54
54
  description?: string | undefined;
55
55
  }, {
56
56
  name: string;
57
- id: string;
58
57
  createdAt: string;
58
+ id: string;
59
59
  updatedAt: string;
60
60
  access: string[];
61
61
  version?: string | undefined;
@@ -77,9 +77,9 @@ export declare const CompanyMembershipJSONSchema: z.ZodObject<{
77
77
  };
78
78
  role?: {
79
79
  name: string;
80
+ createdAt: string;
80
81
  id: string;
81
82
  version: string;
82
- createdAt: string;
83
83
  updatedAt: string;
84
84
  access: string[];
85
85
  description?: string | undefined;
@@ -99,8 +99,8 @@ export declare const CompanyMembershipJSONSchema: z.ZodObject<{
99
99
  version?: string | undefined;
100
100
  role?: {
101
101
  name: string;
102
- id: string;
103
102
  createdAt: string;
103
+ id: string;
104
104
  updatedAt: string;
105
105
  access: string[];
106
106
  version?: string | undefined;
@@ -1,4 +1,3 @@
1
- export * from "./auth.manager.js";
2
1
  export * from "./auth.repository.js";
3
2
  export * from "./user.model.js";
4
3
  export * from "./company-membership.model.js";
@@ -26,6 +26,7 @@ export declare const UserJSONSchema: z.ZodObject<{
26
26
  }, "strip", z.ZodTypeAny, {
27
27
  type: string;
28
28
  name: string;
29
+ createdAt: string;
29
30
  id: string;
30
31
  version: string;
31
32
  profileId: string;
@@ -34,12 +35,12 @@ export declare const UserJSONSchema: z.ZodObject<{
34
35
  isActive: boolean;
35
36
  isArchived: boolean;
36
37
  resetPassword: boolean;
37
- createdAt: string;
38
38
  updatedAt: string;
39
39
  access: string[];
40
40
  }, {
41
41
  type: string;
42
42
  name: string;
43
+ createdAt: string;
43
44
  id: string;
44
45
  profileId: string;
45
46
  identity: string;
@@ -47,7 +48,6 @@ export declare const UserJSONSchema: z.ZodObject<{
47
48
  isActive: boolean;
48
49
  isArchived: boolean;
49
50
  resetPassword: boolean;
50
- createdAt: string;
51
51
  updatedAt: string;
52
52
  access: string[];
53
53
  version?: string | undefined;
@@ -93,16 +93,16 @@ export declare const UserJSONSchema: z.ZodObject<{
93
93
  version: z.ZodDefault<z.ZodOptional<z.ZodString>>;
94
94
  }, "strip", z.ZodTypeAny, {
95
95
  name: string;
96
+ createdAt: string;
96
97
  id: string;
97
98
  version: string;
98
- createdAt: string;
99
99
  updatedAt: string;
100
100
  access: string[];
101
101
  description?: string | undefined;
102
102
  }, {
103
103
  name: string;
104
- id: string;
105
104
  createdAt: string;
105
+ id: string;
106
106
  updatedAt: string;
107
107
  access: string[];
108
108
  version?: string | undefined;
@@ -111,6 +111,7 @@ export declare const UserJSONSchema: z.ZodObject<{
111
111
  token: z.ZodString;
112
112
  version: z.ZodDefault<z.ZodOptional<z.ZodString>>;
113
113
  }, "strip", z.ZodTypeAny, {
114
+ token: string;
114
115
  version: string;
115
116
  companyProfile: {
116
117
  id: string;
@@ -126,6 +127,7 @@ export declare const UserJSONSchema: z.ZodObject<{
126
127
  logIn: {
127
128
  type: string;
128
129
  name: string;
130
+ createdAt: string;
129
131
  id: string;
130
132
  version: string;
131
133
  profileId: string;
@@ -134,21 +136,20 @@ export declare const UserJSONSchema: z.ZodObject<{
134
136
  isActive: boolean;
135
137
  isArchived: boolean;
136
138
  resetPassword: boolean;
137
- createdAt: string;
138
139
  updatedAt: string;
139
140
  access: string[];
140
141
  };
141
- token: string;
142
142
  role?: {
143
143
  name: string;
144
+ createdAt: string;
144
145
  id: string;
145
146
  version: string;
146
- createdAt: string;
147
147
  updatedAt: string;
148
148
  access: string[];
149
149
  description?: string | undefined;
150
150
  } | undefined;
151
151
  }, {
152
+ token: string;
152
153
  companyProfile: {
153
154
  id: string;
154
155
  displayName: string;
@@ -163,6 +164,7 @@ export declare const UserJSONSchema: z.ZodObject<{
163
164
  logIn: {
164
165
  type: string;
165
166
  name: string;
167
+ createdAt: string;
166
168
  id: string;
167
169
  profileId: string;
168
170
  identity: string;
@@ -170,17 +172,15 @@ export declare const UserJSONSchema: z.ZodObject<{
170
172
  isActive: boolean;
171
173
  isArchived: boolean;
172
174
  resetPassword: boolean;
173
- createdAt: string;
174
175
  updatedAt: string;
175
176
  access: string[];
176
177
  version?: string | undefined;
177
178
  };
178
- token: string;
179
179
  version?: string | undefined;
180
180
  role?: {
181
181
  name: string;
182
- id: string;
183
182
  createdAt: string;
183
+ id: string;
184
184
  updatedAt: string;
185
185
  access: string[];
186
186
  version?: string | undefined;
@@ -41,20 +41,20 @@ export declare const contract: {
41
41
  type: z.ZodNativeEnum<typeof import("./contact.dtos.js").ContactType>;
42
42
  }, "strip", z.ZodTypeAny, {
43
43
  type: import("./contact.dtos.js").ContactType;
44
+ createdAt: string;
44
45
  id: string;
45
46
  displayName: string;
46
47
  accountNo: string;
47
48
  profileId: string;
48
- createdAt: string;
49
49
  updatedAt: string;
50
50
  channel: string;
51
51
  }, {
52
52
  type: import("./contact.dtos.js").ContactType;
53
+ createdAt: string;
53
54
  id: string;
54
55
  displayName: string;
55
56
  accountNo: string;
56
57
  profileId: string;
57
- createdAt: string;
58
58
  updatedAt: string;
59
59
  channel: string;
60
60
  }>;
@@ -92,20 +92,20 @@ export declare const contract: {
92
92
  type: z.ZodNativeEnum<typeof import("./contact.dtos.js").ContactType>;
93
93
  }, "strip", z.ZodTypeAny, {
94
94
  type: import("./contact.dtos.js").ContactType;
95
+ createdAt: string;
95
96
  id: string;
96
97
  displayName: string;
97
98
  accountNo: string;
98
99
  profileId: string;
99
- createdAt: string;
100
100
  updatedAt: string;
101
101
  channel: string;
102
102
  }, {
103
103
  type: import("./contact.dtos.js").ContactType;
104
+ createdAt: string;
104
105
  id: string;
105
106
  displayName: string;
106
107
  accountNo: string;
107
108
  profileId: string;
108
- createdAt: string;
109
109
  updatedAt: string;
110
110
  channel: string;
111
111
  }>;
@@ -134,20 +134,20 @@ export declare const contract: {
134
134
  type: z.ZodNativeEnum<typeof import("./contact.dtos.js").ContactType>;
135
135
  }, "strip", z.ZodTypeAny, {
136
136
  type: import("./contact.dtos.js").ContactType;
137
+ createdAt: string;
137
138
  id: string;
138
139
  displayName: string;
139
140
  accountNo: string;
140
141
  profileId: string;
141
- createdAt: string;
142
142
  updatedAt: string;
143
143
  channel: string;
144
144
  }, {
145
145
  type: import("./contact.dtos.js").ContactType;
146
+ createdAt: string;
146
147
  id: string;
147
148
  displayName: string;
148
149
  accountNo: string;
149
150
  profileId: string;
150
- createdAt: string;
151
151
  updatedAt: string;
152
152
  channel: string;
153
153
  }>, "many">;
@@ -169,20 +169,20 @@ export declare const contract: {
169
169
  type: z.ZodNativeEnum<typeof import("./contact.dtos.js").ContactType>;
170
170
  }, "strip", z.ZodTypeAny, {
171
171
  type: import("./contact.dtos.js").ContactType;
172
+ createdAt: string;
172
173
  id: string;
173
174
  displayName: string;
174
175
  accountNo: string;
175
176
  profileId: string;
176
- createdAt: string;
177
177
  updatedAt: string;
178
178
  channel: string;
179
179
  }, {
180
180
  type: import("./contact.dtos.js").ContactType;
181
+ createdAt: string;
181
182
  id: string;
182
183
  displayName: string;
183
184
  accountNo: string;
184
185
  profileId: string;
185
- createdAt: string;
186
186
  updatedAt: string;
187
187
  channel: string;
188
188
  }>;
@@ -45,20 +45,20 @@ export declare const ContactDTOSchemas: {
45
45
  type: z.ZodNativeEnum<typeof ContactType>;
46
46
  }, "strip", z.ZodTypeAny, {
47
47
  type: ContactType;
48
+ createdAt: string;
48
49
  id: string;
49
50
  displayName: string;
50
51
  accountNo: string;
51
52
  profileId: string;
52
- createdAt: string;
53
53
  updatedAt: string;
54
54
  channel: string;
55
55
  }, {
56
56
  type: ContactType;
57
+ createdAt: string;
57
58
  id: string;
58
59
  displayName: string;
59
60
  accountNo: string;
60
61
  profileId: string;
61
- createdAt: string;
62
62
  updatedAt: string;
63
63
  channel: string;
64
64
  }>;
@@ -22,20 +22,20 @@ export declare const ContactJSONSchema: z.ZodObject<{
22
22
  type: z.ZodNativeEnum<typeof ContactType>;
23
23
  }, "strip", z.ZodTypeAny, {
24
24
  type: ContactType;
25
+ createdAt: string;
25
26
  id: string;
26
27
  displayName: string;
27
28
  accountNo: string;
28
29
  profileId: string;
29
- createdAt: string;
30
30
  updatedAt: string;
31
31
  channel: string;
32
32
  }, {
33
33
  type: ContactType;
34
+ createdAt: string;
34
35
  id: string;
35
36
  displayName: string;
36
37
  accountNo: string;
37
38
  profileId: string;
38
- createdAt: string;
39
39
  updatedAt: string;
40
40
  channel: string;
41
41
  }>;
@@ -45,22 +45,22 @@ export declare const ContactJSONSchema: z.ZodObject<{
45
45
  version: string;
46
46
  data: {
47
47
  type: ContactType;
48
+ createdAt: string;
48
49
  id: string;
49
50
  displayName: string;
50
51
  accountNo: string;
51
52
  profileId: string;
52
- createdAt: string;
53
53
  updatedAt: string;
54
54
  channel: string;
55
55
  };
56
56
  }, {
57
57
  data: {
58
58
  type: ContactType;
59
+ createdAt: string;
59
60
  id: string;
60
61
  displayName: string;
61
62
  accountNo: string;
62
63
  profileId: string;
63
- createdAt: string;
64
64
  updatedAt: string;
65
65
  channel: string;
66
66
  };
@@ -22,6 +22,7 @@ export declare const identityContract: {
22
22
  }, "strip", import("zod").ZodTypeAny, {
23
23
  type: string;
24
24
  name: string;
25
+ createdAt: string;
25
26
  id: string;
26
27
  profileId: string;
27
28
  identity: string;
@@ -29,12 +30,12 @@ export declare const identityContract: {
29
30
  isActive: boolean;
30
31
  isArchived: boolean;
31
32
  resetPassword: boolean;
32
- createdAt: string;
33
33
  updatedAt: string;
34
34
  access: string[];
35
35
  }, {
36
36
  type: string;
37
37
  name: string;
38
+ createdAt: string;
38
39
  id: string;
39
40
  profileId: string;
40
41
  identity: string;
@@ -42,7 +43,6 @@ export declare const identityContract: {
42
43
  isActive: boolean;
43
44
  isArchived: boolean;
44
45
  resetPassword: boolean;
45
- createdAt: string;
46
46
  updatedAt: string;
47
47
  access: string[];
48
48
  }>;
@@ -15,6 +15,7 @@ declare const LogInDTOSchema: z.ZodObject<{
15
15
  }, "strip", z.ZodTypeAny, {
16
16
  type: string;
17
17
  name: string;
18
+ createdAt: string;
18
19
  id: string;
19
20
  profileId: string;
20
21
  identity: string;
@@ -22,12 +23,12 @@ declare const LogInDTOSchema: z.ZodObject<{
22
23
  isActive: boolean;
23
24
  isArchived: boolean;
24
25
  resetPassword: boolean;
25
- createdAt: string;
26
26
  updatedAt: string;
27
27
  access: string[];
28
28
  }, {
29
29
  type: string;
30
30
  name: string;
31
+ createdAt: string;
31
32
  id: string;
32
33
  profileId: string;
33
34
  identity: string;
@@ -35,7 +36,6 @@ declare const LogInDTOSchema: z.ZodObject<{
35
36
  isActive: boolean;
36
37
  isArchived: boolean;
37
38
  resetPassword: boolean;
38
- createdAt: string;
39
39
  updatedAt: string;
40
40
  access: string[];
41
41
  }>;
@@ -56,6 +56,7 @@ export declare const LogInSchemas: {
56
56
  }, "strip", z.ZodTypeAny, {
57
57
  type: string;
58
58
  name: string;
59
+ createdAt: string;
59
60
  id: string;
60
61
  profileId: string;
61
62
  identity: string;
@@ -63,12 +64,12 @@ export declare const LogInSchemas: {
63
64
  isActive: boolean;
64
65
  isArchived: boolean;
65
66
  resetPassword: boolean;
66
- createdAt: string;
67
67
  updatedAt: string;
68
68
  access: string[];
69
69
  }, {
70
70
  type: string;
71
71
  name: string;
72
+ createdAt: string;
72
73
  id: string;
73
74
  profileId: string;
74
75
  identity: string;
@@ -76,7 +77,6 @@ export declare const LogInSchemas: {
76
77
  isActive: boolean;
77
78
  isArchived: boolean;
78
79
  resetPassword: boolean;
79
- createdAt: string;
80
80
  updatedAt: string;
81
81
  access: string[];
82
82
  }>;
@@ -21,6 +21,7 @@ export declare const LogInJSONSchema: z.ZodObject<{
21
21
  }, "strip", z.ZodTypeAny, {
22
22
  type: string;
23
23
  name: string;
24
+ createdAt: string;
24
25
  id: string;
25
26
  version: string;
26
27
  profileId: string;
@@ -29,12 +30,12 @@ export declare const LogInJSONSchema: z.ZodObject<{
29
30
  isActive: boolean;
30
31
  isArchived: boolean;
31
32
  resetPassword: boolean;
32
- createdAt: string;
33
33
  updatedAt: string;
34
34
  access: string[];
35
35
  }, {
36
36
  type: string;
37
37
  name: string;
38
+ createdAt: string;
38
39
  id: string;
39
40
  profileId: string;
40
41
  identity: string;
@@ -42,7 +43,6 @@ export declare const LogInJSONSchema: z.ZodObject<{
42
43
  isActive: boolean;
43
44
  isArchived: boolean;
44
45
  resetPassword: boolean;
45
- createdAt: string;
46
46
  updatedAt: string;
47
47
  access: string[];
48
48
  version?: string | undefined;