@stashfin/grpc 1.2.194 → 1.2.197
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.
- package/package.json +1 -1
- package/ts/bureau/getobligation.d.ts +83 -0
- package/ts/bureau/getobligation.js +517 -0
- package/ts/bureau.d.ts +14 -0
- package/ts/bureau.js +10 -0
- package/ts/customers/getappsubmittedscreen.d.ts +1 -1
- package/ts/customers/getappsubmittedscreen.js +9 -7
- package/ts/customers/getcustomerbyid.d.ts +1 -1
- package/ts/customers/getcustomerbyid.js +8 -8
- package/ts/customers/sendemailtoken.d.ts +0 -35
- package/ts/customers/sendemailtoken.js +0 -117
- package/ts/customers/skipdlrcscreen.d.ts +0 -35
- package/ts/customers/skipdlrcscreen.js +0 -117
- package/ts/customers/step1.d.ts +0 -69
- package/ts/customers/step1.js +0 -395
- package/ts/customers/step10.d.ts +0 -73
- package/ts/customers/step10.js +0 -459
- package/ts/customers/step2.d.ts +0 -68
- package/ts/customers/step2.js +0 -381
- package/ts/customers/step7.d.ts +0 -68
- package/ts/customers/step7.js +0 -381
- package/ts/customers/step8.d.ts +0 -69
- package/ts/customers/step8.js +0 -395
- package/ts/customers/step9.d.ts +0 -75
- package/ts/customers/step9.js +0 -489
- package/ts/customers/stepstatic.d.ts +0 -66
- package/ts/customers/stepstatic.js +0 -354
- package/ts/customers/verifyemail.d.ts +0 -35
- package/ts/customers/verifyemail.js +0 -117
- package/ts/google/protobuf/timestamp.d.ts +0 -127
- package/ts/google/protobuf/timestamp.js +0 -97
package/package.json
CHANGED
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import _m0 from "protobufjs/minimal";
|
|
2
|
+
export declare const protobufPackage = "bureau.getobligation";
|
|
3
|
+
export interface obligationRequest {
|
|
4
|
+
customer_id: number;
|
|
5
|
+
}
|
|
6
|
+
export interface obligationResponse {
|
|
7
|
+
status: string;
|
|
8
|
+
data?: Data | undefined;
|
|
9
|
+
}
|
|
10
|
+
export interface Data {
|
|
11
|
+
max_allowed_dbr: number;
|
|
12
|
+
active_loans_obligation: number;
|
|
13
|
+
monthly_obligations: number;
|
|
14
|
+
bureau_month_obligations: number;
|
|
15
|
+
max_obligation: number;
|
|
16
|
+
salary: number;
|
|
17
|
+
max_emi: number;
|
|
18
|
+
bureau?: Bureau | undefined;
|
|
19
|
+
bureau_obligation_rows: AccountList[];
|
|
20
|
+
}
|
|
21
|
+
export interface Bureau {
|
|
22
|
+
score: number;
|
|
23
|
+
pull_date: string;
|
|
24
|
+
}
|
|
25
|
+
export interface AccountList {
|
|
26
|
+
id: number;
|
|
27
|
+
account_type: number;
|
|
28
|
+
current_balance: number;
|
|
29
|
+
sanctioned_amount: number;
|
|
30
|
+
emi_amount: number;
|
|
31
|
+
obligation: number;
|
|
32
|
+
}
|
|
33
|
+
export declare const obligationRequest: {
|
|
34
|
+
encode(message: obligationRequest, writer?: _m0.Writer): _m0.Writer;
|
|
35
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): obligationRequest;
|
|
36
|
+
fromJSON(object: any): obligationRequest;
|
|
37
|
+
toJSON(message: obligationRequest): unknown;
|
|
38
|
+
create<I extends Exact<DeepPartial<obligationRequest>, I>>(base?: I): obligationRequest;
|
|
39
|
+
fromPartial<I extends Exact<DeepPartial<obligationRequest>, I>>(object: I): obligationRequest;
|
|
40
|
+
};
|
|
41
|
+
export declare const obligationResponse: {
|
|
42
|
+
encode(message: obligationResponse, writer?: _m0.Writer): _m0.Writer;
|
|
43
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): obligationResponse;
|
|
44
|
+
fromJSON(object: any): obligationResponse;
|
|
45
|
+
toJSON(message: obligationResponse): unknown;
|
|
46
|
+
create<I extends Exact<DeepPartial<obligationResponse>, I>>(base?: I): obligationResponse;
|
|
47
|
+
fromPartial<I extends Exact<DeepPartial<obligationResponse>, I>>(object: I): obligationResponse;
|
|
48
|
+
};
|
|
49
|
+
export declare const Data: {
|
|
50
|
+
encode(message: Data, writer?: _m0.Writer): _m0.Writer;
|
|
51
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): Data;
|
|
52
|
+
fromJSON(object: any): Data;
|
|
53
|
+
toJSON(message: Data): unknown;
|
|
54
|
+
create<I extends Exact<DeepPartial<Data>, I>>(base?: I): Data;
|
|
55
|
+
fromPartial<I extends Exact<DeepPartial<Data>, I>>(object: I): Data;
|
|
56
|
+
};
|
|
57
|
+
export declare const Bureau: {
|
|
58
|
+
encode(message: Bureau, writer?: _m0.Writer): _m0.Writer;
|
|
59
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): Bureau;
|
|
60
|
+
fromJSON(object: any): Bureau;
|
|
61
|
+
toJSON(message: Bureau): unknown;
|
|
62
|
+
create<I extends Exact<DeepPartial<Bureau>, I>>(base?: I): Bureau;
|
|
63
|
+
fromPartial<I extends Exact<DeepPartial<Bureau>, I>>(object: I): Bureau;
|
|
64
|
+
};
|
|
65
|
+
export declare const AccountList: {
|
|
66
|
+
encode(message: AccountList, writer?: _m0.Writer): _m0.Writer;
|
|
67
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): AccountList;
|
|
68
|
+
fromJSON(object: any): AccountList;
|
|
69
|
+
toJSON(message: AccountList): unknown;
|
|
70
|
+
create<I extends Exact<DeepPartial<AccountList>, I>>(base?: I): AccountList;
|
|
71
|
+
fromPartial<I extends Exact<DeepPartial<AccountList>, I>>(object: I): AccountList;
|
|
72
|
+
};
|
|
73
|
+
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
74
|
+
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 {} ? {
|
|
75
|
+
[K in keyof T]?: DeepPartial<T[K]>;
|
|
76
|
+
} : Partial<T>;
|
|
77
|
+
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
78
|
+
export type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
79
|
+
[K in keyof P]: Exact<P[K], I[K]>;
|
|
80
|
+
} & {
|
|
81
|
+
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
82
|
+
};
|
|
83
|
+
export {};
|
|
@@ -0,0 +1,517 @@
|
|
|
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.28.0
|
|
6
|
+
// source: bureau/getobligation.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.AccountList = exports.Bureau = exports.Data = exports.obligationResponse = exports.obligationRequest = exports.protobufPackage = void 0;
|
|
12
|
+
/* eslint-disable */
|
|
13
|
+
const long_1 = __importDefault(require("long"));
|
|
14
|
+
const minimal_1 = __importDefault(require("protobufjs/minimal"));
|
|
15
|
+
exports.protobufPackage = "bureau.getobligation";
|
|
16
|
+
function createBaseobligationRequest() {
|
|
17
|
+
return { customer_id: 0 };
|
|
18
|
+
}
|
|
19
|
+
exports.obligationRequest = {
|
|
20
|
+
encode(message, writer = minimal_1.default.Writer.create()) {
|
|
21
|
+
if (message.customer_id !== 0) {
|
|
22
|
+
writer.uint32(8).int64(message.customer_id);
|
|
23
|
+
}
|
|
24
|
+
return writer;
|
|
25
|
+
},
|
|
26
|
+
decode(input, length) {
|
|
27
|
+
const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
|
|
28
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
29
|
+
const message = createBaseobligationRequest();
|
|
30
|
+
while (reader.pos < end) {
|
|
31
|
+
const tag = reader.uint32();
|
|
32
|
+
switch (tag >>> 3) {
|
|
33
|
+
case 1:
|
|
34
|
+
if (tag !== 8) {
|
|
35
|
+
break;
|
|
36
|
+
}
|
|
37
|
+
message.customer_id = longToNumber(reader.int64());
|
|
38
|
+
continue;
|
|
39
|
+
}
|
|
40
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
41
|
+
break;
|
|
42
|
+
}
|
|
43
|
+
reader.skipType(tag & 7);
|
|
44
|
+
}
|
|
45
|
+
return message;
|
|
46
|
+
},
|
|
47
|
+
fromJSON(object) {
|
|
48
|
+
return { customer_id: isSet(object.customer_id) ? globalThis.Number(object.customer_id) : 0 };
|
|
49
|
+
},
|
|
50
|
+
toJSON(message) {
|
|
51
|
+
const obj = {};
|
|
52
|
+
if (message.customer_id !== 0) {
|
|
53
|
+
obj.customer_id = Math.round(message.customer_id);
|
|
54
|
+
}
|
|
55
|
+
return obj;
|
|
56
|
+
},
|
|
57
|
+
create(base) {
|
|
58
|
+
return exports.obligationRequest.fromPartial(base ?? {});
|
|
59
|
+
},
|
|
60
|
+
fromPartial(object) {
|
|
61
|
+
const message = createBaseobligationRequest();
|
|
62
|
+
message.customer_id = object.customer_id ?? 0;
|
|
63
|
+
return message;
|
|
64
|
+
},
|
|
65
|
+
};
|
|
66
|
+
function createBaseobligationResponse() {
|
|
67
|
+
return { status: "", data: undefined };
|
|
68
|
+
}
|
|
69
|
+
exports.obligationResponse = {
|
|
70
|
+
encode(message, writer = minimal_1.default.Writer.create()) {
|
|
71
|
+
if (message.status !== "") {
|
|
72
|
+
writer.uint32(10).string(message.status);
|
|
73
|
+
}
|
|
74
|
+
if (message.data !== undefined) {
|
|
75
|
+
exports.Data.encode(message.data, writer.uint32(18).fork()).ldelim();
|
|
76
|
+
}
|
|
77
|
+
return writer;
|
|
78
|
+
},
|
|
79
|
+
decode(input, length) {
|
|
80
|
+
const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
|
|
81
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
82
|
+
const message = createBaseobligationResponse();
|
|
83
|
+
while (reader.pos < end) {
|
|
84
|
+
const tag = reader.uint32();
|
|
85
|
+
switch (tag >>> 3) {
|
|
86
|
+
case 1:
|
|
87
|
+
if (tag !== 10) {
|
|
88
|
+
break;
|
|
89
|
+
}
|
|
90
|
+
message.status = reader.string();
|
|
91
|
+
continue;
|
|
92
|
+
case 2:
|
|
93
|
+
if (tag !== 18) {
|
|
94
|
+
break;
|
|
95
|
+
}
|
|
96
|
+
message.data = exports.Data.decode(reader, reader.uint32());
|
|
97
|
+
continue;
|
|
98
|
+
}
|
|
99
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
100
|
+
break;
|
|
101
|
+
}
|
|
102
|
+
reader.skipType(tag & 7);
|
|
103
|
+
}
|
|
104
|
+
return message;
|
|
105
|
+
},
|
|
106
|
+
fromJSON(object) {
|
|
107
|
+
return {
|
|
108
|
+
status: isSet(object.status) ? globalThis.String(object.status) : "",
|
|
109
|
+
data: isSet(object.data) ? exports.Data.fromJSON(object.data) : undefined,
|
|
110
|
+
};
|
|
111
|
+
},
|
|
112
|
+
toJSON(message) {
|
|
113
|
+
const obj = {};
|
|
114
|
+
if (message.status !== "") {
|
|
115
|
+
obj.status = message.status;
|
|
116
|
+
}
|
|
117
|
+
if (message.data !== undefined) {
|
|
118
|
+
obj.data = exports.Data.toJSON(message.data);
|
|
119
|
+
}
|
|
120
|
+
return obj;
|
|
121
|
+
},
|
|
122
|
+
create(base) {
|
|
123
|
+
return exports.obligationResponse.fromPartial(base ?? {});
|
|
124
|
+
},
|
|
125
|
+
fromPartial(object) {
|
|
126
|
+
const message = createBaseobligationResponse();
|
|
127
|
+
message.status = object.status ?? "";
|
|
128
|
+
message.data = (object.data !== undefined && object.data !== null) ? exports.Data.fromPartial(object.data) : undefined;
|
|
129
|
+
return message;
|
|
130
|
+
},
|
|
131
|
+
};
|
|
132
|
+
function createBaseData() {
|
|
133
|
+
return {
|
|
134
|
+
max_allowed_dbr: 0,
|
|
135
|
+
active_loans_obligation: 0,
|
|
136
|
+
monthly_obligations: 0,
|
|
137
|
+
bureau_month_obligations: 0,
|
|
138
|
+
max_obligation: 0,
|
|
139
|
+
salary: 0,
|
|
140
|
+
max_emi: 0,
|
|
141
|
+
bureau: undefined,
|
|
142
|
+
bureau_obligation_rows: [],
|
|
143
|
+
};
|
|
144
|
+
}
|
|
145
|
+
exports.Data = {
|
|
146
|
+
encode(message, writer = minimal_1.default.Writer.create()) {
|
|
147
|
+
if (message.max_allowed_dbr !== 0) {
|
|
148
|
+
writer.uint32(8).int32(message.max_allowed_dbr);
|
|
149
|
+
}
|
|
150
|
+
if (message.active_loans_obligation !== 0) {
|
|
151
|
+
writer.uint32(16).int32(message.active_loans_obligation);
|
|
152
|
+
}
|
|
153
|
+
if (message.monthly_obligations !== 0) {
|
|
154
|
+
writer.uint32(24).int32(message.monthly_obligations);
|
|
155
|
+
}
|
|
156
|
+
if (message.bureau_month_obligations !== 0) {
|
|
157
|
+
writer.uint32(32).int32(message.bureau_month_obligations);
|
|
158
|
+
}
|
|
159
|
+
if (message.max_obligation !== 0) {
|
|
160
|
+
writer.uint32(40).int32(message.max_obligation);
|
|
161
|
+
}
|
|
162
|
+
if (message.salary !== 0) {
|
|
163
|
+
writer.uint32(48).int32(message.salary);
|
|
164
|
+
}
|
|
165
|
+
if (message.max_emi !== 0) {
|
|
166
|
+
writer.uint32(56).int32(message.max_emi);
|
|
167
|
+
}
|
|
168
|
+
if (message.bureau !== undefined) {
|
|
169
|
+
exports.Bureau.encode(message.bureau, writer.uint32(66).fork()).ldelim();
|
|
170
|
+
}
|
|
171
|
+
for (const v of message.bureau_obligation_rows) {
|
|
172
|
+
exports.AccountList.encode(v, writer.uint32(74).fork()).ldelim();
|
|
173
|
+
}
|
|
174
|
+
return writer;
|
|
175
|
+
},
|
|
176
|
+
decode(input, length) {
|
|
177
|
+
const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
|
|
178
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
179
|
+
const message = createBaseData();
|
|
180
|
+
while (reader.pos < end) {
|
|
181
|
+
const tag = reader.uint32();
|
|
182
|
+
switch (tag >>> 3) {
|
|
183
|
+
case 1:
|
|
184
|
+
if (tag !== 8) {
|
|
185
|
+
break;
|
|
186
|
+
}
|
|
187
|
+
message.max_allowed_dbr = reader.int32();
|
|
188
|
+
continue;
|
|
189
|
+
case 2:
|
|
190
|
+
if (tag !== 16) {
|
|
191
|
+
break;
|
|
192
|
+
}
|
|
193
|
+
message.active_loans_obligation = reader.int32();
|
|
194
|
+
continue;
|
|
195
|
+
case 3:
|
|
196
|
+
if (tag !== 24) {
|
|
197
|
+
break;
|
|
198
|
+
}
|
|
199
|
+
message.monthly_obligations = reader.int32();
|
|
200
|
+
continue;
|
|
201
|
+
case 4:
|
|
202
|
+
if (tag !== 32) {
|
|
203
|
+
break;
|
|
204
|
+
}
|
|
205
|
+
message.bureau_month_obligations = reader.int32();
|
|
206
|
+
continue;
|
|
207
|
+
case 5:
|
|
208
|
+
if (tag !== 40) {
|
|
209
|
+
break;
|
|
210
|
+
}
|
|
211
|
+
message.max_obligation = reader.int32();
|
|
212
|
+
continue;
|
|
213
|
+
case 6:
|
|
214
|
+
if (tag !== 48) {
|
|
215
|
+
break;
|
|
216
|
+
}
|
|
217
|
+
message.salary = reader.int32();
|
|
218
|
+
continue;
|
|
219
|
+
case 7:
|
|
220
|
+
if (tag !== 56) {
|
|
221
|
+
break;
|
|
222
|
+
}
|
|
223
|
+
message.max_emi = reader.int32();
|
|
224
|
+
continue;
|
|
225
|
+
case 8:
|
|
226
|
+
if (tag !== 66) {
|
|
227
|
+
break;
|
|
228
|
+
}
|
|
229
|
+
message.bureau = exports.Bureau.decode(reader, reader.uint32());
|
|
230
|
+
continue;
|
|
231
|
+
case 9:
|
|
232
|
+
if (tag !== 74) {
|
|
233
|
+
break;
|
|
234
|
+
}
|
|
235
|
+
message.bureau_obligation_rows.push(exports.AccountList.decode(reader, reader.uint32()));
|
|
236
|
+
continue;
|
|
237
|
+
}
|
|
238
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
239
|
+
break;
|
|
240
|
+
}
|
|
241
|
+
reader.skipType(tag & 7);
|
|
242
|
+
}
|
|
243
|
+
return message;
|
|
244
|
+
},
|
|
245
|
+
fromJSON(object) {
|
|
246
|
+
return {
|
|
247
|
+
max_allowed_dbr: isSet(object.max_allowed_dbr) ? globalThis.Number(object.max_allowed_dbr) : 0,
|
|
248
|
+
active_loans_obligation: isSet(object.active_loans_obligation)
|
|
249
|
+
? globalThis.Number(object.active_loans_obligation)
|
|
250
|
+
: 0,
|
|
251
|
+
monthly_obligations: isSet(object.monthly_obligations) ? globalThis.Number(object.monthly_obligations) : 0,
|
|
252
|
+
bureau_month_obligations: isSet(object.bureau_month_obligations)
|
|
253
|
+
? globalThis.Number(object.bureau_month_obligations)
|
|
254
|
+
: 0,
|
|
255
|
+
max_obligation: isSet(object.max_obligation) ? globalThis.Number(object.max_obligation) : 0,
|
|
256
|
+
salary: isSet(object.salary) ? globalThis.Number(object.salary) : 0,
|
|
257
|
+
max_emi: isSet(object.max_emi) ? globalThis.Number(object.max_emi) : 0,
|
|
258
|
+
bureau: isSet(object.bureau) ? exports.Bureau.fromJSON(object.bureau) : undefined,
|
|
259
|
+
bureau_obligation_rows: globalThis.Array.isArray(object?.bureau_obligation_rows)
|
|
260
|
+
? object.bureau_obligation_rows.map((e) => exports.AccountList.fromJSON(e))
|
|
261
|
+
: [],
|
|
262
|
+
};
|
|
263
|
+
},
|
|
264
|
+
toJSON(message) {
|
|
265
|
+
const obj = {};
|
|
266
|
+
if (message.max_allowed_dbr !== 0) {
|
|
267
|
+
obj.max_allowed_dbr = Math.round(message.max_allowed_dbr);
|
|
268
|
+
}
|
|
269
|
+
if (message.active_loans_obligation !== 0) {
|
|
270
|
+
obj.active_loans_obligation = Math.round(message.active_loans_obligation);
|
|
271
|
+
}
|
|
272
|
+
if (message.monthly_obligations !== 0) {
|
|
273
|
+
obj.monthly_obligations = Math.round(message.monthly_obligations);
|
|
274
|
+
}
|
|
275
|
+
if (message.bureau_month_obligations !== 0) {
|
|
276
|
+
obj.bureau_month_obligations = Math.round(message.bureau_month_obligations);
|
|
277
|
+
}
|
|
278
|
+
if (message.max_obligation !== 0) {
|
|
279
|
+
obj.max_obligation = Math.round(message.max_obligation);
|
|
280
|
+
}
|
|
281
|
+
if (message.salary !== 0) {
|
|
282
|
+
obj.salary = Math.round(message.salary);
|
|
283
|
+
}
|
|
284
|
+
if (message.max_emi !== 0) {
|
|
285
|
+
obj.max_emi = Math.round(message.max_emi);
|
|
286
|
+
}
|
|
287
|
+
if (message.bureau !== undefined) {
|
|
288
|
+
obj.bureau = exports.Bureau.toJSON(message.bureau);
|
|
289
|
+
}
|
|
290
|
+
if (message.bureau_obligation_rows?.length) {
|
|
291
|
+
obj.bureau_obligation_rows = message.bureau_obligation_rows.map((e) => exports.AccountList.toJSON(e));
|
|
292
|
+
}
|
|
293
|
+
return obj;
|
|
294
|
+
},
|
|
295
|
+
create(base) {
|
|
296
|
+
return exports.Data.fromPartial(base ?? {});
|
|
297
|
+
},
|
|
298
|
+
fromPartial(object) {
|
|
299
|
+
const message = createBaseData();
|
|
300
|
+
message.max_allowed_dbr = object.max_allowed_dbr ?? 0;
|
|
301
|
+
message.active_loans_obligation = object.active_loans_obligation ?? 0;
|
|
302
|
+
message.monthly_obligations = object.monthly_obligations ?? 0;
|
|
303
|
+
message.bureau_month_obligations = object.bureau_month_obligations ?? 0;
|
|
304
|
+
message.max_obligation = object.max_obligation ?? 0;
|
|
305
|
+
message.salary = object.salary ?? 0;
|
|
306
|
+
message.max_emi = object.max_emi ?? 0;
|
|
307
|
+
message.bureau = (object.bureau !== undefined && object.bureau !== null)
|
|
308
|
+
? exports.Bureau.fromPartial(object.bureau)
|
|
309
|
+
: undefined;
|
|
310
|
+
message.bureau_obligation_rows = object.bureau_obligation_rows?.map((e) => exports.AccountList.fromPartial(e)) || [];
|
|
311
|
+
return message;
|
|
312
|
+
},
|
|
313
|
+
};
|
|
314
|
+
function createBaseBureau() {
|
|
315
|
+
return { score: 0, pull_date: "" };
|
|
316
|
+
}
|
|
317
|
+
exports.Bureau = {
|
|
318
|
+
encode(message, writer = minimal_1.default.Writer.create()) {
|
|
319
|
+
if (message.score !== 0) {
|
|
320
|
+
writer.uint32(8).int32(message.score);
|
|
321
|
+
}
|
|
322
|
+
if (message.pull_date !== "") {
|
|
323
|
+
writer.uint32(18).string(message.pull_date);
|
|
324
|
+
}
|
|
325
|
+
return writer;
|
|
326
|
+
},
|
|
327
|
+
decode(input, length) {
|
|
328
|
+
const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
|
|
329
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
330
|
+
const message = createBaseBureau();
|
|
331
|
+
while (reader.pos < end) {
|
|
332
|
+
const tag = reader.uint32();
|
|
333
|
+
switch (tag >>> 3) {
|
|
334
|
+
case 1:
|
|
335
|
+
if (tag !== 8) {
|
|
336
|
+
break;
|
|
337
|
+
}
|
|
338
|
+
message.score = reader.int32();
|
|
339
|
+
continue;
|
|
340
|
+
case 2:
|
|
341
|
+
if (tag !== 18) {
|
|
342
|
+
break;
|
|
343
|
+
}
|
|
344
|
+
message.pull_date = reader.string();
|
|
345
|
+
continue;
|
|
346
|
+
}
|
|
347
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
348
|
+
break;
|
|
349
|
+
}
|
|
350
|
+
reader.skipType(tag & 7);
|
|
351
|
+
}
|
|
352
|
+
return message;
|
|
353
|
+
},
|
|
354
|
+
fromJSON(object) {
|
|
355
|
+
return {
|
|
356
|
+
score: isSet(object.score) ? globalThis.Number(object.score) : 0,
|
|
357
|
+
pull_date: isSet(object.pull_date) ? globalThis.String(object.pull_date) : "",
|
|
358
|
+
};
|
|
359
|
+
},
|
|
360
|
+
toJSON(message) {
|
|
361
|
+
const obj = {};
|
|
362
|
+
if (message.score !== 0) {
|
|
363
|
+
obj.score = Math.round(message.score);
|
|
364
|
+
}
|
|
365
|
+
if (message.pull_date !== "") {
|
|
366
|
+
obj.pull_date = message.pull_date;
|
|
367
|
+
}
|
|
368
|
+
return obj;
|
|
369
|
+
},
|
|
370
|
+
create(base) {
|
|
371
|
+
return exports.Bureau.fromPartial(base ?? {});
|
|
372
|
+
},
|
|
373
|
+
fromPartial(object) {
|
|
374
|
+
const message = createBaseBureau();
|
|
375
|
+
message.score = object.score ?? 0;
|
|
376
|
+
message.pull_date = object.pull_date ?? "";
|
|
377
|
+
return message;
|
|
378
|
+
},
|
|
379
|
+
};
|
|
380
|
+
function createBaseAccountList() {
|
|
381
|
+
return { id: 0, account_type: 0, current_balance: 0, sanctioned_amount: 0, emi_amount: 0, obligation: 0 };
|
|
382
|
+
}
|
|
383
|
+
exports.AccountList = {
|
|
384
|
+
encode(message, writer = minimal_1.default.Writer.create()) {
|
|
385
|
+
if (message.id !== 0) {
|
|
386
|
+
writer.uint32(8).int64(message.id);
|
|
387
|
+
}
|
|
388
|
+
if (message.account_type !== 0) {
|
|
389
|
+
writer.uint32(16).int32(message.account_type);
|
|
390
|
+
}
|
|
391
|
+
if (message.current_balance !== 0) {
|
|
392
|
+
writer.uint32(24).int32(message.current_balance);
|
|
393
|
+
}
|
|
394
|
+
if (message.sanctioned_amount !== 0) {
|
|
395
|
+
writer.uint32(32).int32(message.sanctioned_amount);
|
|
396
|
+
}
|
|
397
|
+
if (message.emi_amount !== 0) {
|
|
398
|
+
writer.uint32(40).int32(message.emi_amount);
|
|
399
|
+
}
|
|
400
|
+
if (message.obligation !== 0) {
|
|
401
|
+
writer.uint32(48).int32(message.obligation);
|
|
402
|
+
}
|
|
403
|
+
return writer;
|
|
404
|
+
},
|
|
405
|
+
decode(input, length) {
|
|
406
|
+
const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
|
|
407
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
408
|
+
const message = createBaseAccountList();
|
|
409
|
+
while (reader.pos < end) {
|
|
410
|
+
const tag = reader.uint32();
|
|
411
|
+
switch (tag >>> 3) {
|
|
412
|
+
case 1:
|
|
413
|
+
if (tag !== 8) {
|
|
414
|
+
break;
|
|
415
|
+
}
|
|
416
|
+
message.id = longToNumber(reader.int64());
|
|
417
|
+
continue;
|
|
418
|
+
case 2:
|
|
419
|
+
if (tag !== 16) {
|
|
420
|
+
break;
|
|
421
|
+
}
|
|
422
|
+
message.account_type = reader.int32();
|
|
423
|
+
continue;
|
|
424
|
+
case 3:
|
|
425
|
+
if (tag !== 24) {
|
|
426
|
+
break;
|
|
427
|
+
}
|
|
428
|
+
message.current_balance = reader.int32();
|
|
429
|
+
continue;
|
|
430
|
+
case 4:
|
|
431
|
+
if (tag !== 32) {
|
|
432
|
+
break;
|
|
433
|
+
}
|
|
434
|
+
message.sanctioned_amount = reader.int32();
|
|
435
|
+
continue;
|
|
436
|
+
case 5:
|
|
437
|
+
if (tag !== 40) {
|
|
438
|
+
break;
|
|
439
|
+
}
|
|
440
|
+
message.emi_amount = reader.int32();
|
|
441
|
+
continue;
|
|
442
|
+
case 6:
|
|
443
|
+
if (tag !== 48) {
|
|
444
|
+
break;
|
|
445
|
+
}
|
|
446
|
+
message.obligation = reader.int32();
|
|
447
|
+
continue;
|
|
448
|
+
}
|
|
449
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
450
|
+
break;
|
|
451
|
+
}
|
|
452
|
+
reader.skipType(tag & 7);
|
|
453
|
+
}
|
|
454
|
+
return message;
|
|
455
|
+
},
|
|
456
|
+
fromJSON(object) {
|
|
457
|
+
return {
|
|
458
|
+
id: isSet(object.id) ? globalThis.Number(object.id) : 0,
|
|
459
|
+
account_type: isSet(object.account_type) ? globalThis.Number(object.account_type) : 0,
|
|
460
|
+
current_balance: isSet(object.current_balance) ? globalThis.Number(object.current_balance) : 0,
|
|
461
|
+
sanctioned_amount: isSet(object.sanctioned_amount) ? globalThis.Number(object.sanctioned_amount) : 0,
|
|
462
|
+
emi_amount: isSet(object.emi_amount) ? globalThis.Number(object.emi_amount) : 0,
|
|
463
|
+
obligation: isSet(object.obligation) ? globalThis.Number(object.obligation) : 0,
|
|
464
|
+
};
|
|
465
|
+
},
|
|
466
|
+
toJSON(message) {
|
|
467
|
+
const obj = {};
|
|
468
|
+
if (message.id !== 0) {
|
|
469
|
+
obj.id = Math.round(message.id);
|
|
470
|
+
}
|
|
471
|
+
if (message.account_type !== 0) {
|
|
472
|
+
obj.account_type = Math.round(message.account_type);
|
|
473
|
+
}
|
|
474
|
+
if (message.current_balance !== 0) {
|
|
475
|
+
obj.current_balance = Math.round(message.current_balance);
|
|
476
|
+
}
|
|
477
|
+
if (message.sanctioned_amount !== 0) {
|
|
478
|
+
obj.sanctioned_amount = Math.round(message.sanctioned_amount);
|
|
479
|
+
}
|
|
480
|
+
if (message.emi_amount !== 0) {
|
|
481
|
+
obj.emi_amount = Math.round(message.emi_amount);
|
|
482
|
+
}
|
|
483
|
+
if (message.obligation !== 0) {
|
|
484
|
+
obj.obligation = Math.round(message.obligation);
|
|
485
|
+
}
|
|
486
|
+
return obj;
|
|
487
|
+
},
|
|
488
|
+
create(base) {
|
|
489
|
+
return exports.AccountList.fromPartial(base ?? {});
|
|
490
|
+
},
|
|
491
|
+
fromPartial(object) {
|
|
492
|
+
const message = createBaseAccountList();
|
|
493
|
+
message.id = object.id ?? 0;
|
|
494
|
+
message.account_type = object.account_type ?? 0;
|
|
495
|
+
message.current_balance = object.current_balance ?? 0;
|
|
496
|
+
message.sanctioned_amount = object.sanctioned_amount ?? 0;
|
|
497
|
+
message.emi_amount = object.emi_amount ?? 0;
|
|
498
|
+
message.obligation = object.obligation ?? 0;
|
|
499
|
+
return message;
|
|
500
|
+
},
|
|
501
|
+
};
|
|
502
|
+
function longToNumber(long) {
|
|
503
|
+
if (long.gt(globalThis.Number.MAX_SAFE_INTEGER)) {
|
|
504
|
+
throw new globalThis.Error("Value is larger than Number.MAX_SAFE_INTEGER");
|
|
505
|
+
}
|
|
506
|
+
if (long.lt(globalThis.Number.MIN_SAFE_INTEGER)) {
|
|
507
|
+
throw new globalThis.Error("Value is smaller than Number.MIN_SAFE_INTEGER");
|
|
508
|
+
}
|
|
509
|
+
return long.toNumber();
|
|
510
|
+
}
|
|
511
|
+
if (minimal_1.default.util.Long !== long_1.default) {
|
|
512
|
+
minimal_1.default.util.Long = long_1.default;
|
|
513
|
+
minimal_1.default.configure();
|
|
514
|
+
}
|
|
515
|
+
function isSet(value) {
|
|
516
|
+
return value !== null && value !== undefined;
|
|
517
|
+
}
|
package/ts/bureau.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { type CallOptions, ChannelCredentials, Client, type ClientOptions, type ClientUnaryCall, type handleUnaryCall, Metadata, type ServiceError, type UntypedServiceImplementation } from "@grpc/grpc-js";
|
|
2
2
|
import { detailsRequest, detailsResponse } from "./bureau/getbasicdetails";
|
|
3
3
|
import { demogsRequest, demogsResponse } from "./bureau/getdemogs";
|
|
4
|
+
import { obligationRequest, obligationResponse } from "./bureau/getobligation";
|
|
4
5
|
import { bureauRequest, bureauResponse } from "./bureau/getreport";
|
|
5
6
|
export declare const protobufPackage = "service";
|
|
6
7
|
export type bureauService = typeof bureauService;
|
|
@@ -32,11 +33,21 @@ export declare const bureauService: {
|
|
|
32
33
|
readonly responseSerialize: (value: demogsResponse) => Buffer;
|
|
33
34
|
readonly responseDeserialize: (value: Buffer) => demogsResponse;
|
|
34
35
|
};
|
|
36
|
+
readonly getObligationData: {
|
|
37
|
+
readonly path: "/service.bureau/getObligationData";
|
|
38
|
+
readonly requestStream: false;
|
|
39
|
+
readonly responseStream: false;
|
|
40
|
+
readonly requestSerialize: (value: obligationRequest) => Buffer;
|
|
41
|
+
readonly requestDeserialize: (value: Buffer) => obligationRequest;
|
|
42
|
+
readonly responseSerialize: (value: obligationResponse) => Buffer;
|
|
43
|
+
readonly responseDeserialize: (value: Buffer) => obligationResponse;
|
|
44
|
+
};
|
|
35
45
|
};
|
|
36
46
|
export interface bureauServer extends UntypedServiceImplementation {
|
|
37
47
|
getBasicDetails: handleUnaryCall<detailsRequest, detailsResponse>;
|
|
38
48
|
getReport: handleUnaryCall<bureauRequest, bureauResponse>;
|
|
39
49
|
getDemogs: handleUnaryCall<demogsRequest, demogsResponse>;
|
|
50
|
+
getObligationData: handleUnaryCall<obligationRequest, obligationResponse>;
|
|
40
51
|
}
|
|
41
52
|
export interface bureauClient extends Client {
|
|
42
53
|
getBasicDetails(request: detailsRequest, callback: (error: ServiceError | null, response: detailsResponse) => void): ClientUnaryCall;
|
|
@@ -48,6 +59,9 @@ export interface bureauClient extends Client {
|
|
|
48
59
|
getDemogs(request: demogsRequest, callback: (error: ServiceError | null, response: demogsResponse) => void): ClientUnaryCall;
|
|
49
60
|
getDemogs(request: demogsRequest, metadata: Metadata, callback: (error: ServiceError | null, response: demogsResponse) => void): ClientUnaryCall;
|
|
50
61
|
getDemogs(request: demogsRequest, metadata: Metadata, options: Partial<CallOptions>, callback: (error: ServiceError | null, response: demogsResponse) => void): ClientUnaryCall;
|
|
62
|
+
getObligationData(request: obligationRequest, callback: (error: ServiceError | null, response: obligationResponse) => void): ClientUnaryCall;
|
|
63
|
+
getObligationData(request: obligationRequest, metadata: Metadata, callback: (error: ServiceError | null, response: obligationResponse) => void): ClientUnaryCall;
|
|
64
|
+
getObligationData(request: obligationRequest, metadata: Metadata, options: Partial<CallOptions>, callback: (error: ServiceError | null, response: obligationResponse) => void): ClientUnaryCall;
|
|
51
65
|
}
|
|
52
66
|
export declare const bureauClient: {
|
|
53
67
|
new (address: string, credentials: ChannelCredentials, options?: Partial<ClientOptions>): bureauClient;
|
package/ts/bureau.js
CHANGED
|
@@ -10,6 +10,7 @@ exports.bureauClient = exports.bureauService = exports.protobufPackage = void 0;
|
|
|
10
10
|
const grpc_js_1 = require("@grpc/grpc-js");
|
|
11
11
|
const getbasicdetails_1 = require("./bureau/getbasicdetails");
|
|
12
12
|
const getdemogs_1 = require("./bureau/getdemogs");
|
|
13
|
+
const getobligation_1 = require("./bureau/getobligation");
|
|
13
14
|
const getreport_1 = require("./bureau/getreport");
|
|
14
15
|
exports.protobufPackage = "service";
|
|
15
16
|
exports.bureauService = {
|
|
@@ -40,5 +41,14 @@ exports.bureauService = {
|
|
|
40
41
|
responseSerialize: (value) => Buffer.from(getdemogs_1.demogsResponse.encode(value).finish()),
|
|
41
42
|
responseDeserialize: (value) => getdemogs_1.demogsResponse.decode(value),
|
|
42
43
|
},
|
|
44
|
+
getObligationData: {
|
|
45
|
+
path: "/service.bureau/getObligationData",
|
|
46
|
+
requestStream: false,
|
|
47
|
+
responseStream: false,
|
|
48
|
+
requestSerialize: (value) => Buffer.from(getobligation_1.obligationRequest.encode(value).finish()),
|
|
49
|
+
requestDeserialize: (value) => getobligation_1.obligationRequest.decode(value),
|
|
50
|
+
responseSerialize: (value) => Buffer.from(getobligation_1.obligationResponse.encode(value).finish()),
|
|
51
|
+
responseDeserialize: (value) => getobligation_1.obligationResponse.decode(value),
|
|
52
|
+
},
|
|
43
53
|
};
|
|
44
54
|
exports.bureauClient = (0, grpc_js_1.makeGenericClientConstructor)(exports.bureauService, "service.bureau");
|