@stashfin/grpc 1.2.139 → 1.2.140

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 (169) hide show
  1. package/package.json +4 -1
  2. package/ts/bureau/getbasicdetails.d.ts +57 -0
  3. package/ts/bureau/getbasicdetails.js +341 -0
  4. package/ts/bureau/getdemogs.d.ts +113 -0
  5. package/ts/bureau/getdemogs.js +611 -0
  6. package/ts/bureau/getreport.d.ts +184 -0
  7. package/ts/bureau/getreport.js +1581 -0
  8. package/ts/bureau.d.ts +56 -0
  9. package/ts/bureau.js +44 -0
  10. package/ts/colender/disburseLoan.d.ts +44 -0
  11. package/ts/colender/disburseLoan.js +256 -0
  12. package/ts/colender/forecloseLoan.d.ts +41 -0
  13. package/ts/colender/forecloseLoan.js +205 -0
  14. package/ts/colender/repayLoan.d.ts +48 -0
  15. package/ts/colender/repayLoan.js +313 -0
  16. package/ts/colender.d.ts +56 -0
  17. package/ts/colender.js +44 -0
  18. package/ts/customers/aa/getbanklist.d.ts +48 -0
  19. package/ts/customers/aa/getbanklist.js +198 -0
  20. package/ts/customers/aa/initiate.d.ts +40 -0
  21. package/ts/customers/aa/initiate.js +209 -0
  22. package/ts/customers/addaddress.d.ts +50 -0
  23. package/ts/customers/addaddress.js +265 -0
  24. package/ts/customers/addbankaccountdetails.d.ts +37 -0
  25. package/ts/customers/addbankaccountdetails.js +147 -0
  26. package/ts/customers/addgstnumber.d.ts +35 -0
  27. package/ts/customers/addgstnumber.js +117 -0
  28. package/ts/customers/addsuspendedcustomer.d.ts +36 -0
  29. package/ts/customers/addsuspendedcustomer.js +133 -0
  30. package/ts/customers/adduserapps.d.ts +74 -0
  31. package/ts/customers/adduserapps.js +210 -0
  32. package/ts/customers/changempin.d.ts +36 -0
  33. package/ts/customers/changempin.js +133 -0
  34. package/ts/customers/createcustomerreference.d.ts +43 -0
  35. package/ts/customers/createcustomerreference.js +226 -0
  36. package/ts/customers/deleteprofile.d.ts +35 -0
  37. package/ts/customers/deleteprofile.js +120 -0
  38. package/ts/customers/disablempin.d.ts +34 -0
  39. package/ts/customers/disablempin.js +104 -0
  40. package/ts/customers/fetchrcprofile.d.ts +45 -0
  41. package/ts/customers/fetchrcprofile.js +271 -0
  42. package/ts/customers/forgotmpin.d.ts +35 -0
  43. package/ts/customers/forgotmpin.js +117 -0
  44. package/ts/customers/forgotmpinverify.d.ts +36 -0
  45. package/ts/customers/forgotmpinverify.js +133 -0
  46. package/ts/customers/getbankaccountdetails.d.ts +36 -0
  47. package/ts/customers/getbankaccountdetails.js +134 -0
  48. package/ts/customers/getbasicinfo.d.ts +56 -0
  49. package/ts/customers/getbasicinfo.js +323 -0
  50. package/ts/customers/getcities.d.ts +47 -0
  51. package/ts/customers/getcities.js +183 -0
  52. package/ts/customers/getcustomerbyid.d.ts +128 -0
  53. package/ts/customers/getcustomerbyid.js +1411 -0
  54. package/ts/customers/getdashboard.d.ts +91 -0
  55. package/ts/customers/getdashboard.js +618 -0
  56. package/ts/customers/getdashboardmaincard.d.ts +69 -0
  57. package/ts/customers/getdashboardmaincard.js +520 -0
  58. package/ts/customers/getdocuments.d.ts +36 -0
  59. package/ts/customers/getdocuments.js +134 -0
  60. package/ts/customers/getprofessionalinfo.d.ts +54 -0
  61. package/ts/customers/getprofessionalinfo.js +286 -0
  62. package/ts/customers/getprofile.d.ts +54 -0
  63. package/ts/customers/getprofile.js +296 -0
  64. package/ts/customers/getselfieetxnid.d.ts +34 -0
  65. package/ts/customers/getselfieetxnid.js +104 -0
  66. package/ts/customers/getstates.d.ts +46 -0
  67. package/ts/customers/getstates.js +170 -0
  68. package/ts/customers/getstep.d.ts +69 -0
  69. package/ts/customers/getstep.js +406 -0
  70. package/ts/customers/profilebasic.d.ts +38 -0
  71. package/ts/customers/profilebasic.js +161 -0
  72. package/ts/customers/profileupdatetnc.d.ts +35 -0
  73. package/ts/customers/profileupdatetnc.js +117 -0
  74. package/ts/customers/savebasicdetails.d.ts +47 -0
  75. package/ts/customers/savebasicdetails.js +185 -0
  76. package/ts/customers/saveunlocklimit.d.ts +34 -0
  77. package/ts/customers/saveunlocklimit.js +104 -0
  78. package/ts/customers/sendotp.d.ts +38 -0
  79. package/ts/customers/sendotp.js +165 -0
  80. package/ts/customers/sendotptoemail.d.ts +35 -0
  81. package/ts/customers/sendotptoemail.js +117 -0
  82. package/ts/customers/setmpin.d.ts +36 -0
  83. package/ts/customers/setmpin.js +133 -0
  84. package/ts/customers/step10.d.ts +73 -0
  85. package/ts/customers/step10.js +459 -0
  86. package/ts/customers/step7.d.ts +68 -0
  87. package/ts/customers/step7.js +381 -0
  88. package/ts/customers/step8.d.ts +69 -0
  89. package/ts/customers/step8.js +395 -0
  90. package/ts/customers/step9.d.ts +75 -0
  91. package/ts/customers/step9.js +489 -0
  92. package/ts/customers/stepstatic.d.ts +66 -0
  93. package/ts/customers/stepstatic.js +354 -0
  94. package/ts/customers/updatedob.d.ts +35 -0
  95. package/ts/customers/updatedob.js +117 -0
  96. package/ts/customers/updatelocstatus.d.ts +36 -0
  97. package/ts/customers/updatelocstatus.js +133 -0
  98. package/ts/customers/updatemobilesendotp.d.ts +35 -0
  99. package/ts/customers/updatemobilesendotp.js +117 -0
  100. package/ts/customers/updatemobileverifyotp.d.ts +36 -0
  101. package/ts/customers/updatemobileverifyotp.js +133 -0
  102. package/ts/customers/updateokyctxn.d.ts +37 -0
  103. package/ts/customers/updateokyctxn.js +147 -0
  104. package/ts/customers/updateselfieetxn.d.ts +36 -0
  105. package/ts/customers/updateselfieetxn.js +133 -0
  106. package/ts/customers/validatepan.d.ts +45 -0
  107. package/ts/customers/validatepan.js +274 -0
  108. package/ts/customers/verifympin.d.ts +37 -0
  109. package/ts/customers/verifympin.js +149 -0
  110. package/ts/customers/verifyotp.d.ts +41 -0
  111. package/ts/customers/verifyotp.js +205 -0
  112. package/ts/customers/verifyotptoemail.d.ts +35 -0
  113. package/ts/customers/verifyotptoemail.js +117 -0
  114. package/ts/customers.d.ts +764 -0
  115. package/ts/customers.js +548 -0
  116. package/ts/example.d.ts +78 -0
  117. package/ts/example.js +199 -0
  118. package/ts/loans/approveloan.d.ts +40 -0
  119. package/ts/loans/approveloan.js +189 -0
  120. package/ts/loans/banklist.d.ts +37 -0
  121. package/ts/loans/banklist.js +148 -0
  122. package/ts/loans/calculateemi.d.ts +57 -0
  123. package/ts/loans/calculateemi.js +340 -0
  124. package/ts/loans/creditlimit.d.ts +51 -0
  125. package/ts/loans/creditlimit.js +381 -0
  126. package/ts/loans/futurepaymentmoredetails.d.ts +50 -0
  127. package/ts/loans/futurepaymentmoredetails.js +230 -0
  128. package/ts/loans/getcustomerloanstatus.d.ts +34 -0
  129. package/ts/loans/getcustomerloanstatus.js +104 -0
  130. package/ts/loans/getloanbyid.d.ts +53 -0
  131. package/ts/loans/getloanbyid.js +393 -0
  132. package/ts/loans/getpendingemiamount.d.ts +34 -0
  133. package/ts/loans/getpendingemiamount.js +104 -0
  134. package/ts/loans/getsummarystaticfields.d.ts +80 -0
  135. package/ts/loans/getsummarystaticfields.js +700 -0
  136. package/ts/loans/loansummary.d.ts +66 -0
  137. package/ts/loans/loansummary.js +593 -0
  138. package/ts/loans/paymentallocation.d.ts +37 -0
  139. package/ts/loans/paymentallocation.js +147 -0
  140. package/ts/loans/paymenthistory.d.ts +47 -0
  141. package/ts/loans/paymenthistory.js +188 -0
  142. package/ts/loans/restructureloan.d.ts +36 -0
  143. package/ts/loans/restructureloan.js +133 -0
  144. package/ts/loans/sendemail.d.ts +35 -0
  145. package/ts/loans/sendemail.js +117 -0
  146. package/ts/loans/sendnocemail.d.ts +35 -0
  147. package/ts/loans/sendnocemail.js +117 -0
  148. package/ts/loans/transactionlist.d.ts +52 -0
  149. package/ts/loans/transactionlist.js +257 -0
  150. package/ts/loans/updateinstallments.d.ts +42 -0
  151. package/ts/loans/updateinstallments.js +226 -0
  152. package/ts/loans/updateloan.d.ts +39 -0
  153. package/ts/loans/updateloan.js +175 -0
  154. package/ts/loans.d.ts +266 -0
  155. package/ts/loans.js +194 -0
  156. package/ts/payments.d.ts +239 -0
  157. package/ts/payments.js +1117 -0
  158. package/ts/stashcash/creditsc.d.ts +54 -0
  159. package/ts/stashcash/creditsc.js +301 -0
  160. package/ts/stashcash/debitsc.d.ts +59 -0
  161. package/ts/stashcash/debitsc.js +380 -0
  162. package/ts/stashcash/getscbalance.d.ts +53 -0
  163. package/ts/stashcash/getscbalance.js +293 -0
  164. package/ts/stashcash/getschistory.d.ts +73 -0
  165. package/ts/stashcash/getschistory.js +479 -0
  166. package/ts/stashcash/reversesc.d.ts +52 -0
  167. package/ts/stashcash/reversesc.js +273 -0
  168. package/ts/stashcash.d.ts +84 -0
  169. package/ts/stashcash.js +64 -0
@@ -0,0 +1,91 @@
1
+ import _m0 from "protobufjs/minimal";
2
+ export declare const protobufPackage = "customers.getdashboard";
3
+ export interface getDashboardRequest {
4
+ }
5
+ export interface getDashboardResponse {
6
+ user_state: string;
7
+ father_name_dialog: boolean;
8
+ current_step: string;
9
+ blocks: Block[];
10
+ }
11
+ export interface Block {
12
+ block_name: string;
13
+ block_title: string;
14
+ block_code: string;
15
+ block_data: BlockData[];
16
+ }
17
+ export interface BlockData {
18
+ text: string;
19
+ sub_text: string;
20
+ image_url: string;
21
+ video_url: string;
22
+ video_length: number;
23
+ action_url: string;
24
+ landing_page: string;
25
+ api_mode: string;
26
+ app_version: string;
27
+ old_customers: boolean;
28
+ is_new: boolean;
29
+ action_type: string;
30
+ color1: string;
31
+ color2: string;
32
+ image_trailing: string;
33
+ tag: Tag | undefined;
34
+ overlay_image: string;
35
+ }
36
+ export interface Tag {
37
+ text: string;
38
+ bg_color: string;
39
+ text_color: string;
40
+ }
41
+ export declare const getDashboardRequest: {
42
+ encode(_: getDashboardRequest, writer?: _m0.Writer): _m0.Writer;
43
+ decode(input: _m0.Reader | Uint8Array, length?: number): getDashboardRequest;
44
+ fromJSON(_: any): getDashboardRequest;
45
+ toJSON(_: getDashboardRequest): unknown;
46
+ create<I extends Exact<DeepPartial<getDashboardRequest>, I>>(base?: I): getDashboardRequest;
47
+ fromPartial<I extends Exact<DeepPartial<getDashboardRequest>, I>>(_: I): getDashboardRequest;
48
+ };
49
+ export declare const getDashboardResponse: {
50
+ encode(message: getDashboardResponse, writer?: _m0.Writer): _m0.Writer;
51
+ decode(input: _m0.Reader | Uint8Array, length?: number): getDashboardResponse;
52
+ fromJSON(object: any): getDashboardResponse;
53
+ toJSON(message: getDashboardResponse): unknown;
54
+ create<I extends Exact<DeepPartial<getDashboardResponse>, I>>(base?: I): getDashboardResponse;
55
+ fromPartial<I extends Exact<DeepPartial<getDashboardResponse>, I>>(object: I): getDashboardResponse;
56
+ };
57
+ export declare const Block: {
58
+ encode(message: Block, writer?: _m0.Writer): _m0.Writer;
59
+ decode(input: _m0.Reader | Uint8Array, length?: number): Block;
60
+ fromJSON(object: any): Block;
61
+ toJSON(message: Block): unknown;
62
+ create<I extends Exact<DeepPartial<Block>, I>>(base?: I): Block;
63
+ fromPartial<I extends Exact<DeepPartial<Block>, I>>(object: I): Block;
64
+ };
65
+ export declare const BlockData: {
66
+ encode(message: BlockData, writer?: _m0.Writer): _m0.Writer;
67
+ decode(input: _m0.Reader | Uint8Array, length?: number): BlockData;
68
+ fromJSON(object: any): BlockData;
69
+ toJSON(message: BlockData): unknown;
70
+ create<I extends Exact<DeepPartial<BlockData>, I>>(base?: I): BlockData;
71
+ fromPartial<I extends Exact<DeepPartial<BlockData>, I>>(object: I): BlockData;
72
+ };
73
+ export declare const Tag: {
74
+ encode(message: Tag, writer?: _m0.Writer): _m0.Writer;
75
+ decode(input: _m0.Reader | Uint8Array, length?: number): Tag;
76
+ fromJSON(object: any): Tag;
77
+ toJSON(message: Tag): unknown;
78
+ create<I extends Exact<DeepPartial<Tag>, I>>(base?: I): Tag;
79
+ fromPartial<I extends Exact<DeepPartial<Tag>, I>>(object: I): Tag;
80
+ };
81
+ type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
82
+ export type DeepPartial<T> = T extends Builtin ? T : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>> : T extends {} ? {
83
+ [K in keyof T]?: DeepPartial<T[K]>;
84
+ } : Partial<T>;
85
+ type KeysOfUnion<T> = T extends T ? keyof T : never;
86
+ export type Exact<P, I extends P> = P extends Builtin ? P : P & {
87
+ [K in keyof P]: Exact<P[K], I[K]>;
88
+ } & {
89
+ [K in Exclude<keyof I, KeysOfUnion<P>>]: never;
90
+ };
91
+ export {};
@@ -0,0 +1,618 @@
1
+ "use strict";
2
+ // Code generated by protoc-gen-ts_proto. DO NOT EDIT.
3
+ // versions:
4
+ // protoc-gen-ts_proto v1.181.0
5
+ // protoc v5.27.3
6
+ // source: customers/getdashboard.proto
7
+ var __importDefault = (this && this.__importDefault) || function (mod) {
8
+ return (mod && mod.__esModule) ? mod : { "default": mod };
9
+ };
10
+ Object.defineProperty(exports, "__esModule", { value: true });
11
+ exports.Tag = exports.BlockData = exports.Block = exports.getDashboardResponse = exports.getDashboardRequest = exports.protobufPackage = void 0;
12
+ /* eslint-disable */
13
+ const minimal_1 = __importDefault(require("protobufjs/minimal"));
14
+ exports.protobufPackage = "customers.getdashboard";
15
+ function createBasegetDashboardRequest() {
16
+ return {};
17
+ }
18
+ exports.getDashboardRequest = {
19
+ encode(_, writer = minimal_1.default.Writer.create()) {
20
+ return writer;
21
+ },
22
+ decode(input, length) {
23
+ const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
24
+ let end = length === undefined ? reader.len : reader.pos + length;
25
+ const message = createBasegetDashboardRequest();
26
+ while (reader.pos < end) {
27
+ const tag = reader.uint32();
28
+ switch (tag >>> 3) {
29
+ }
30
+ if ((tag & 7) === 4 || tag === 0) {
31
+ break;
32
+ }
33
+ reader.skipType(tag & 7);
34
+ }
35
+ return message;
36
+ },
37
+ fromJSON(_) {
38
+ return {};
39
+ },
40
+ toJSON(_) {
41
+ const obj = {};
42
+ return obj;
43
+ },
44
+ create(base) {
45
+ return exports.getDashboardRequest.fromPartial(base ?? {});
46
+ },
47
+ fromPartial(_) {
48
+ const message = createBasegetDashboardRequest();
49
+ return message;
50
+ },
51
+ };
52
+ function createBasegetDashboardResponse() {
53
+ return { user_state: "", father_name_dialog: false, current_step: "", blocks: [] };
54
+ }
55
+ exports.getDashboardResponse = {
56
+ encode(message, writer = minimal_1.default.Writer.create()) {
57
+ if (message.user_state !== "") {
58
+ writer.uint32(10).string(message.user_state);
59
+ }
60
+ if (message.father_name_dialog !== false) {
61
+ writer.uint32(16).bool(message.father_name_dialog);
62
+ }
63
+ if (message.current_step !== "") {
64
+ writer.uint32(26).string(message.current_step);
65
+ }
66
+ for (const v of message.blocks) {
67
+ exports.Block.encode(v, writer.uint32(34).fork()).ldelim();
68
+ }
69
+ return writer;
70
+ },
71
+ decode(input, length) {
72
+ const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
73
+ let end = length === undefined ? reader.len : reader.pos + length;
74
+ const message = createBasegetDashboardResponse();
75
+ while (reader.pos < end) {
76
+ const tag = reader.uint32();
77
+ switch (tag >>> 3) {
78
+ case 1:
79
+ if (tag !== 10) {
80
+ break;
81
+ }
82
+ message.user_state = reader.string();
83
+ continue;
84
+ case 2:
85
+ if (tag !== 16) {
86
+ break;
87
+ }
88
+ message.father_name_dialog = reader.bool();
89
+ continue;
90
+ case 3:
91
+ if (tag !== 26) {
92
+ break;
93
+ }
94
+ message.current_step = reader.string();
95
+ continue;
96
+ case 4:
97
+ if (tag !== 34) {
98
+ break;
99
+ }
100
+ message.blocks.push(exports.Block.decode(reader, reader.uint32()));
101
+ continue;
102
+ }
103
+ if ((tag & 7) === 4 || tag === 0) {
104
+ break;
105
+ }
106
+ reader.skipType(tag & 7);
107
+ }
108
+ return message;
109
+ },
110
+ fromJSON(object) {
111
+ return {
112
+ user_state: isSet(object.user_state) ? globalThis.String(object.user_state) : "",
113
+ father_name_dialog: isSet(object.father_name_dialog) ? globalThis.Boolean(object.father_name_dialog) : false,
114
+ current_step: isSet(object.current_step) ? globalThis.String(object.current_step) : "",
115
+ blocks: globalThis.Array.isArray(object?.blocks) ? object.blocks.map((e) => exports.Block.fromJSON(e)) : [],
116
+ };
117
+ },
118
+ toJSON(message) {
119
+ const obj = {};
120
+ if (message.user_state !== "") {
121
+ obj.user_state = message.user_state;
122
+ }
123
+ if (message.father_name_dialog !== false) {
124
+ obj.father_name_dialog = message.father_name_dialog;
125
+ }
126
+ if (message.current_step !== "") {
127
+ obj.current_step = message.current_step;
128
+ }
129
+ if (message.blocks?.length) {
130
+ obj.blocks = message.blocks.map((e) => exports.Block.toJSON(e));
131
+ }
132
+ return obj;
133
+ },
134
+ create(base) {
135
+ return exports.getDashboardResponse.fromPartial(base ?? {});
136
+ },
137
+ fromPartial(object) {
138
+ const message = createBasegetDashboardResponse();
139
+ message.user_state = object.user_state ?? "";
140
+ message.father_name_dialog = object.father_name_dialog ?? false;
141
+ message.current_step = object.current_step ?? "";
142
+ message.blocks = object.blocks?.map((e) => exports.Block.fromPartial(e)) || [];
143
+ return message;
144
+ },
145
+ };
146
+ function createBaseBlock() {
147
+ return { block_name: "", block_title: "", block_code: "", block_data: [] };
148
+ }
149
+ exports.Block = {
150
+ encode(message, writer = minimal_1.default.Writer.create()) {
151
+ if (message.block_name !== "") {
152
+ writer.uint32(10).string(message.block_name);
153
+ }
154
+ if (message.block_title !== "") {
155
+ writer.uint32(18).string(message.block_title);
156
+ }
157
+ if (message.block_code !== "") {
158
+ writer.uint32(26).string(message.block_code);
159
+ }
160
+ for (const v of message.block_data) {
161
+ exports.BlockData.encode(v, writer.uint32(34).fork()).ldelim();
162
+ }
163
+ return writer;
164
+ },
165
+ decode(input, length) {
166
+ const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
167
+ let end = length === undefined ? reader.len : reader.pos + length;
168
+ const message = createBaseBlock();
169
+ while (reader.pos < end) {
170
+ const tag = reader.uint32();
171
+ switch (tag >>> 3) {
172
+ case 1:
173
+ if (tag !== 10) {
174
+ break;
175
+ }
176
+ message.block_name = reader.string();
177
+ continue;
178
+ case 2:
179
+ if (tag !== 18) {
180
+ break;
181
+ }
182
+ message.block_title = reader.string();
183
+ continue;
184
+ case 3:
185
+ if (tag !== 26) {
186
+ break;
187
+ }
188
+ message.block_code = reader.string();
189
+ continue;
190
+ case 4:
191
+ if (tag !== 34) {
192
+ break;
193
+ }
194
+ message.block_data.push(exports.BlockData.decode(reader, reader.uint32()));
195
+ continue;
196
+ }
197
+ if ((tag & 7) === 4 || tag === 0) {
198
+ break;
199
+ }
200
+ reader.skipType(tag & 7);
201
+ }
202
+ return message;
203
+ },
204
+ fromJSON(object) {
205
+ return {
206
+ block_name: isSet(object.block_name) ? globalThis.String(object.block_name) : "",
207
+ block_title: isSet(object.block_title) ? globalThis.String(object.block_title) : "",
208
+ block_code: isSet(object.block_code) ? globalThis.String(object.block_code) : "",
209
+ block_data: globalThis.Array.isArray(object?.block_data)
210
+ ? object.block_data.map((e) => exports.BlockData.fromJSON(e))
211
+ : [],
212
+ };
213
+ },
214
+ toJSON(message) {
215
+ const obj = {};
216
+ if (message.block_name !== "") {
217
+ obj.block_name = message.block_name;
218
+ }
219
+ if (message.block_title !== "") {
220
+ obj.block_title = message.block_title;
221
+ }
222
+ if (message.block_code !== "") {
223
+ obj.block_code = message.block_code;
224
+ }
225
+ if (message.block_data?.length) {
226
+ obj.block_data = message.block_data.map((e) => exports.BlockData.toJSON(e));
227
+ }
228
+ return obj;
229
+ },
230
+ create(base) {
231
+ return exports.Block.fromPartial(base ?? {});
232
+ },
233
+ fromPartial(object) {
234
+ const message = createBaseBlock();
235
+ message.block_name = object.block_name ?? "";
236
+ message.block_title = object.block_title ?? "";
237
+ message.block_code = object.block_code ?? "";
238
+ message.block_data = object.block_data?.map((e) => exports.BlockData.fromPartial(e)) || [];
239
+ return message;
240
+ },
241
+ };
242
+ function createBaseBlockData() {
243
+ return {
244
+ text: "",
245
+ sub_text: "",
246
+ image_url: "",
247
+ video_url: "",
248
+ video_length: 0,
249
+ action_url: "",
250
+ landing_page: "",
251
+ api_mode: "",
252
+ app_version: "",
253
+ old_customers: false,
254
+ is_new: false,
255
+ action_type: "",
256
+ color1: "",
257
+ color2: "",
258
+ image_trailing: "",
259
+ tag: undefined,
260
+ overlay_image: "",
261
+ };
262
+ }
263
+ exports.BlockData = {
264
+ encode(message, writer = minimal_1.default.Writer.create()) {
265
+ if (message.text !== "") {
266
+ writer.uint32(10).string(message.text);
267
+ }
268
+ if (message.sub_text !== "") {
269
+ writer.uint32(18).string(message.sub_text);
270
+ }
271
+ if (message.image_url !== "") {
272
+ writer.uint32(26).string(message.image_url);
273
+ }
274
+ if (message.video_url !== "") {
275
+ writer.uint32(34).string(message.video_url);
276
+ }
277
+ if (message.video_length !== 0) {
278
+ writer.uint32(40).int32(message.video_length);
279
+ }
280
+ if (message.action_url !== "") {
281
+ writer.uint32(50).string(message.action_url);
282
+ }
283
+ if (message.landing_page !== "") {
284
+ writer.uint32(58).string(message.landing_page);
285
+ }
286
+ if (message.api_mode !== "") {
287
+ writer.uint32(66).string(message.api_mode);
288
+ }
289
+ if (message.app_version !== "") {
290
+ writer.uint32(74).string(message.app_version);
291
+ }
292
+ if (message.old_customers !== false) {
293
+ writer.uint32(80).bool(message.old_customers);
294
+ }
295
+ if (message.is_new !== false) {
296
+ writer.uint32(88).bool(message.is_new);
297
+ }
298
+ if (message.action_type !== "") {
299
+ writer.uint32(98).string(message.action_type);
300
+ }
301
+ if (message.color1 !== "") {
302
+ writer.uint32(106).string(message.color1);
303
+ }
304
+ if (message.color2 !== "") {
305
+ writer.uint32(114).string(message.color2);
306
+ }
307
+ if (message.image_trailing !== "") {
308
+ writer.uint32(122).string(message.image_trailing);
309
+ }
310
+ if (message.tag !== undefined) {
311
+ exports.Tag.encode(message.tag, writer.uint32(130).fork()).ldelim();
312
+ }
313
+ if (message.overlay_image !== "") {
314
+ writer.uint32(138).string(message.overlay_image);
315
+ }
316
+ return writer;
317
+ },
318
+ decode(input, length) {
319
+ const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
320
+ let end = length === undefined ? reader.len : reader.pos + length;
321
+ const message = createBaseBlockData();
322
+ while (reader.pos < end) {
323
+ const tag = reader.uint32();
324
+ switch (tag >>> 3) {
325
+ case 1:
326
+ if (tag !== 10) {
327
+ break;
328
+ }
329
+ message.text = reader.string();
330
+ continue;
331
+ case 2:
332
+ if (tag !== 18) {
333
+ break;
334
+ }
335
+ message.sub_text = reader.string();
336
+ continue;
337
+ case 3:
338
+ if (tag !== 26) {
339
+ break;
340
+ }
341
+ message.image_url = reader.string();
342
+ continue;
343
+ case 4:
344
+ if (tag !== 34) {
345
+ break;
346
+ }
347
+ message.video_url = reader.string();
348
+ continue;
349
+ case 5:
350
+ if (tag !== 40) {
351
+ break;
352
+ }
353
+ message.video_length = reader.int32();
354
+ continue;
355
+ case 6:
356
+ if (tag !== 50) {
357
+ break;
358
+ }
359
+ message.action_url = reader.string();
360
+ continue;
361
+ case 7:
362
+ if (tag !== 58) {
363
+ break;
364
+ }
365
+ message.landing_page = reader.string();
366
+ continue;
367
+ case 8:
368
+ if (tag !== 66) {
369
+ break;
370
+ }
371
+ message.api_mode = reader.string();
372
+ continue;
373
+ case 9:
374
+ if (tag !== 74) {
375
+ break;
376
+ }
377
+ message.app_version = reader.string();
378
+ continue;
379
+ case 10:
380
+ if (tag !== 80) {
381
+ break;
382
+ }
383
+ message.old_customers = reader.bool();
384
+ continue;
385
+ case 11:
386
+ if (tag !== 88) {
387
+ break;
388
+ }
389
+ message.is_new = reader.bool();
390
+ continue;
391
+ case 12:
392
+ if (tag !== 98) {
393
+ break;
394
+ }
395
+ message.action_type = reader.string();
396
+ continue;
397
+ case 13:
398
+ if (tag !== 106) {
399
+ break;
400
+ }
401
+ message.color1 = reader.string();
402
+ continue;
403
+ case 14:
404
+ if (tag !== 114) {
405
+ break;
406
+ }
407
+ message.color2 = reader.string();
408
+ continue;
409
+ case 15:
410
+ if (tag !== 122) {
411
+ break;
412
+ }
413
+ message.image_trailing = reader.string();
414
+ continue;
415
+ case 16:
416
+ if (tag !== 130) {
417
+ break;
418
+ }
419
+ message.tag = exports.Tag.decode(reader, reader.uint32());
420
+ continue;
421
+ case 17:
422
+ if (tag !== 138) {
423
+ break;
424
+ }
425
+ message.overlay_image = reader.string();
426
+ continue;
427
+ }
428
+ if ((tag & 7) === 4 || tag === 0) {
429
+ break;
430
+ }
431
+ reader.skipType(tag & 7);
432
+ }
433
+ return message;
434
+ },
435
+ fromJSON(object) {
436
+ return {
437
+ text: isSet(object.text) ? globalThis.String(object.text) : "",
438
+ sub_text: isSet(object.sub_text) ? globalThis.String(object.sub_text) : "",
439
+ image_url: isSet(object.image_url) ? globalThis.String(object.image_url) : "",
440
+ video_url: isSet(object.video_url) ? globalThis.String(object.video_url) : "",
441
+ video_length: isSet(object.video_length) ? globalThis.Number(object.video_length) : 0,
442
+ action_url: isSet(object.action_url) ? globalThis.String(object.action_url) : "",
443
+ landing_page: isSet(object.landing_page) ? globalThis.String(object.landing_page) : "",
444
+ api_mode: isSet(object.api_mode) ? globalThis.String(object.api_mode) : "",
445
+ app_version: isSet(object.app_version) ? globalThis.String(object.app_version) : "",
446
+ old_customers: isSet(object.old_customers) ? globalThis.Boolean(object.old_customers) : false,
447
+ is_new: isSet(object.is_new) ? globalThis.Boolean(object.is_new) : false,
448
+ action_type: isSet(object.action_type) ? globalThis.String(object.action_type) : "",
449
+ color1: isSet(object.color1) ? globalThis.String(object.color1) : "",
450
+ color2: isSet(object.color2) ? globalThis.String(object.color2) : "",
451
+ image_trailing: isSet(object.image_trailing) ? globalThis.String(object.image_trailing) : "",
452
+ tag: isSet(object.tag) ? exports.Tag.fromJSON(object.tag) : undefined,
453
+ overlay_image: isSet(object.overlay_image) ? globalThis.String(object.overlay_image) : "",
454
+ };
455
+ },
456
+ toJSON(message) {
457
+ const obj = {};
458
+ if (message.text !== "") {
459
+ obj.text = message.text;
460
+ }
461
+ if (message.sub_text !== "") {
462
+ obj.sub_text = message.sub_text;
463
+ }
464
+ if (message.image_url !== "") {
465
+ obj.image_url = message.image_url;
466
+ }
467
+ if (message.video_url !== "") {
468
+ obj.video_url = message.video_url;
469
+ }
470
+ if (message.video_length !== 0) {
471
+ obj.video_length = Math.round(message.video_length);
472
+ }
473
+ if (message.action_url !== "") {
474
+ obj.action_url = message.action_url;
475
+ }
476
+ if (message.landing_page !== "") {
477
+ obj.landing_page = message.landing_page;
478
+ }
479
+ if (message.api_mode !== "") {
480
+ obj.api_mode = message.api_mode;
481
+ }
482
+ if (message.app_version !== "") {
483
+ obj.app_version = message.app_version;
484
+ }
485
+ if (message.old_customers !== false) {
486
+ obj.old_customers = message.old_customers;
487
+ }
488
+ if (message.is_new !== false) {
489
+ obj.is_new = message.is_new;
490
+ }
491
+ if (message.action_type !== "") {
492
+ obj.action_type = message.action_type;
493
+ }
494
+ if (message.color1 !== "") {
495
+ obj.color1 = message.color1;
496
+ }
497
+ if (message.color2 !== "") {
498
+ obj.color2 = message.color2;
499
+ }
500
+ if (message.image_trailing !== "") {
501
+ obj.image_trailing = message.image_trailing;
502
+ }
503
+ if (message.tag !== undefined) {
504
+ obj.tag = exports.Tag.toJSON(message.tag);
505
+ }
506
+ if (message.overlay_image !== "") {
507
+ obj.overlay_image = message.overlay_image;
508
+ }
509
+ return obj;
510
+ },
511
+ create(base) {
512
+ return exports.BlockData.fromPartial(base ?? {});
513
+ },
514
+ fromPartial(object) {
515
+ const message = createBaseBlockData();
516
+ message.text = object.text ?? "";
517
+ message.sub_text = object.sub_text ?? "";
518
+ message.image_url = object.image_url ?? "";
519
+ message.video_url = object.video_url ?? "";
520
+ message.video_length = object.video_length ?? 0;
521
+ message.action_url = object.action_url ?? "";
522
+ message.landing_page = object.landing_page ?? "";
523
+ message.api_mode = object.api_mode ?? "";
524
+ message.app_version = object.app_version ?? "";
525
+ message.old_customers = object.old_customers ?? false;
526
+ message.is_new = object.is_new ?? false;
527
+ message.action_type = object.action_type ?? "";
528
+ message.color1 = object.color1 ?? "";
529
+ message.color2 = object.color2 ?? "";
530
+ message.image_trailing = object.image_trailing ?? "";
531
+ message.tag = (object.tag !== undefined && object.tag !== null) ? exports.Tag.fromPartial(object.tag) : undefined;
532
+ message.overlay_image = object.overlay_image ?? "";
533
+ return message;
534
+ },
535
+ };
536
+ function createBaseTag() {
537
+ return { text: "", bg_color: "", text_color: "" };
538
+ }
539
+ exports.Tag = {
540
+ encode(message, writer = minimal_1.default.Writer.create()) {
541
+ if (message.text !== "") {
542
+ writer.uint32(10).string(message.text);
543
+ }
544
+ if (message.bg_color !== "") {
545
+ writer.uint32(18).string(message.bg_color);
546
+ }
547
+ if (message.text_color !== "") {
548
+ writer.uint32(26).string(message.text_color);
549
+ }
550
+ return writer;
551
+ },
552
+ decode(input, length) {
553
+ const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
554
+ let end = length === undefined ? reader.len : reader.pos + length;
555
+ const message = createBaseTag();
556
+ while (reader.pos < end) {
557
+ const tag = reader.uint32();
558
+ switch (tag >>> 3) {
559
+ case 1:
560
+ if (tag !== 10) {
561
+ break;
562
+ }
563
+ message.text = reader.string();
564
+ continue;
565
+ case 2:
566
+ if (tag !== 18) {
567
+ break;
568
+ }
569
+ message.bg_color = reader.string();
570
+ continue;
571
+ case 3:
572
+ if (tag !== 26) {
573
+ break;
574
+ }
575
+ message.text_color = reader.string();
576
+ continue;
577
+ }
578
+ if ((tag & 7) === 4 || tag === 0) {
579
+ break;
580
+ }
581
+ reader.skipType(tag & 7);
582
+ }
583
+ return message;
584
+ },
585
+ fromJSON(object) {
586
+ return {
587
+ text: isSet(object.text) ? globalThis.String(object.text) : "",
588
+ bg_color: isSet(object.bg_color) ? globalThis.String(object.bg_color) : "",
589
+ text_color: isSet(object.text_color) ? globalThis.String(object.text_color) : "",
590
+ };
591
+ },
592
+ toJSON(message) {
593
+ const obj = {};
594
+ if (message.text !== "") {
595
+ obj.text = message.text;
596
+ }
597
+ if (message.bg_color !== "") {
598
+ obj.bg_color = message.bg_color;
599
+ }
600
+ if (message.text_color !== "") {
601
+ obj.text_color = message.text_color;
602
+ }
603
+ return obj;
604
+ },
605
+ create(base) {
606
+ return exports.Tag.fromPartial(base ?? {});
607
+ },
608
+ fromPartial(object) {
609
+ const message = createBaseTag();
610
+ message.text = object.text ?? "";
611
+ message.bg_color = object.bg_color ?? "";
612
+ message.text_color = object.text_color ?? "";
613
+ return message;
614
+ },
615
+ };
616
+ function isSet(value) {
617
+ return value !== null && value !== undefined;
618
+ }