@stashfin/grpc 1.2.204 → 1.2.205
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/loans/foreclosepayment.d.ts +39 -0
- package/ts/loans/foreclosepayment.js +175 -0
- package/ts/loans/getloanbyid.d.ts +2 -0
- package/ts/loans/getloanbyid.js +30 -0
- package/ts/loans.d.ts +14 -0
- package/ts/loans.js +10 -0
package/package.json
CHANGED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import _m0 from "protobufjs/minimal";
|
|
2
|
+
export declare const protobufPackage = "loans.foreclosepayment";
|
|
3
|
+
export interface foreclosePaymentRequest {
|
|
4
|
+
amount: number;
|
|
5
|
+
customerid: number;
|
|
6
|
+
loan_id: number;
|
|
7
|
+
payment_id: number;
|
|
8
|
+
mode: string;
|
|
9
|
+
}
|
|
10
|
+
export interface foreclosePaymentResponse {
|
|
11
|
+
message: string;
|
|
12
|
+
}
|
|
13
|
+
export declare const foreclosePaymentRequest: {
|
|
14
|
+
encode(message: foreclosePaymentRequest, writer?: _m0.Writer): _m0.Writer;
|
|
15
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): foreclosePaymentRequest;
|
|
16
|
+
fromJSON(object: any): foreclosePaymentRequest;
|
|
17
|
+
toJSON(message: foreclosePaymentRequest): unknown;
|
|
18
|
+
create<I extends Exact<DeepPartial<foreclosePaymentRequest>, I>>(base?: I): foreclosePaymentRequest;
|
|
19
|
+
fromPartial<I extends Exact<DeepPartial<foreclosePaymentRequest>, I>>(object: I): foreclosePaymentRequest;
|
|
20
|
+
};
|
|
21
|
+
export declare const foreclosePaymentResponse: {
|
|
22
|
+
encode(message: foreclosePaymentResponse, writer?: _m0.Writer): _m0.Writer;
|
|
23
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): foreclosePaymentResponse;
|
|
24
|
+
fromJSON(object: any): foreclosePaymentResponse;
|
|
25
|
+
toJSON(message: foreclosePaymentResponse): unknown;
|
|
26
|
+
create<I extends Exact<DeepPartial<foreclosePaymentResponse>, I>>(base?: I): foreclosePaymentResponse;
|
|
27
|
+
fromPartial<I extends Exact<DeepPartial<foreclosePaymentResponse>, I>>(object: I): foreclosePaymentResponse;
|
|
28
|
+
};
|
|
29
|
+
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
30
|
+
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 {} ? {
|
|
31
|
+
[K in keyof T]?: DeepPartial<T[K]>;
|
|
32
|
+
} : Partial<T>;
|
|
33
|
+
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
34
|
+
export type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
35
|
+
[K in keyof P]: Exact<P[K], I[K]>;
|
|
36
|
+
} & {
|
|
37
|
+
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
38
|
+
};
|
|
39
|
+
export {};
|
|
@@ -0,0 +1,175 @@
|
|
|
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: loans/foreclosepayment.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.foreclosePaymentResponse = exports.foreclosePaymentRequest = exports.protobufPackage = void 0;
|
|
12
|
+
/* eslint-disable */
|
|
13
|
+
const minimal_1 = __importDefault(require("protobufjs/minimal"));
|
|
14
|
+
exports.protobufPackage = "loans.foreclosepayment";
|
|
15
|
+
function createBaseforeclosePaymentRequest() {
|
|
16
|
+
return { amount: 0, customerid: 0, loan_id: 0, payment_id: 0, mode: "" };
|
|
17
|
+
}
|
|
18
|
+
exports.foreclosePaymentRequest = {
|
|
19
|
+
encode(message, writer = minimal_1.default.Writer.create()) {
|
|
20
|
+
if (message.amount !== 0) {
|
|
21
|
+
writer.uint32(8).int32(message.amount);
|
|
22
|
+
}
|
|
23
|
+
if (message.customerid !== 0) {
|
|
24
|
+
writer.uint32(16).int32(message.customerid);
|
|
25
|
+
}
|
|
26
|
+
if (message.loan_id !== 0) {
|
|
27
|
+
writer.uint32(24).int32(message.loan_id);
|
|
28
|
+
}
|
|
29
|
+
if (message.payment_id !== 0) {
|
|
30
|
+
writer.uint32(32).int32(message.payment_id);
|
|
31
|
+
}
|
|
32
|
+
if (message.mode !== "") {
|
|
33
|
+
writer.uint32(42).string(message.mode);
|
|
34
|
+
}
|
|
35
|
+
return writer;
|
|
36
|
+
},
|
|
37
|
+
decode(input, length) {
|
|
38
|
+
const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
|
|
39
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
40
|
+
const message = createBaseforeclosePaymentRequest();
|
|
41
|
+
while (reader.pos < end) {
|
|
42
|
+
const tag = reader.uint32();
|
|
43
|
+
switch (tag >>> 3) {
|
|
44
|
+
case 1:
|
|
45
|
+
if (tag !== 8) {
|
|
46
|
+
break;
|
|
47
|
+
}
|
|
48
|
+
message.amount = reader.int32();
|
|
49
|
+
continue;
|
|
50
|
+
case 2:
|
|
51
|
+
if (tag !== 16) {
|
|
52
|
+
break;
|
|
53
|
+
}
|
|
54
|
+
message.customerid = reader.int32();
|
|
55
|
+
continue;
|
|
56
|
+
case 3:
|
|
57
|
+
if (tag !== 24) {
|
|
58
|
+
break;
|
|
59
|
+
}
|
|
60
|
+
message.loan_id = reader.int32();
|
|
61
|
+
continue;
|
|
62
|
+
case 4:
|
|
63
|
+
if (tag !== 32) {
|
|
64
|
+
break;
|
|
65
|
+
}
|
|
66
|
+
message.payment_id = reader.int32();
|
|
67
|
+
continue;
|
|
68
|
+
case 5:
|
|
69
|
+
if (tag !== 42) {
|
|
70
|
+
break;
|
|
71
|
+
}
|
|
72
|
+
message.mode = reader.string();
|
|
73
|
+
continue;
|
|
74
|
+
}
|
|
75
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
76
|
+
break;
|
|
77
|
+
}
|
|
78
|
+
reader.skipType(tag & 7);
|
|
79
|
+
}
|
|
80
|
+
return message;
|
|
81
|
+
},
|
|
82
|
+
fromJSON(object) {
|
|
83
|
+
return {
|
|
84
|
+
amount: isSet(object.amount) ? globalThis.Number(object.amount) : 0,
|
|
85
|
+
customerid: isSet(object.customerid) ? globalThis.Number(object.customerid) : 0,
|
|
86
|
+
loan_id: isSet(object.loan_id) ? globalThis.Number(object.loan_id) : 0,
|
|
87
|
+
payment_id: isSet(object.payment_id) ? globalThis.Number(object.payment_id) : 0,
|
|
88
|
+
mode: isSet(object.mode) ? globalThis.String(object.mode) : "",
|
|
89
|
+
};
|
|
90
|
+
},
|
|
91
|
+
toJSON(message) {
|
|
92
|
+
const obj = {};
|
|
93
|
+
if (message.amount !== 0) {
|
|
94
|
+
obj.amount = Math.round(message.amount);
|
|
95
|
+
}
|
|
96
|
+
if (message.customerid !== 0) {
|
|
97
|
+
obj.customerid = Math.round(message.customerid);
|
|
98
|
+
}
|
|
99
|
+
if (message.loan_id !== 0) {
|
|
100
|
+
obj.loan_id = Math.round(message.loan_id);
|
|
101
|
+
}
|
|
102
|
+
if (message.payment_id !== 0) {
|
|
103
|
+
obj.payment_id = Math.round(message.payment_id);
|
|
104
|
+
}
|
|
105
|
+
if (message.mode !== "") {
|
|
106
|
+
obj.mode = message.mode;
|
|
107
|
+
}
|
|
108
|
+
return obj;
|
|
109
|
+
},
|
|
110
|
+
create(base) {
|
|
111
|
+
return exports.foreclosePaymentRequest.fromPartial(base ?? {});
|
|
112
|
+
},
|
|
113
|
+
fromPartial(object) {
|
|
114
|
+
const message = createBaseforeclosePaymentRequest();
|
|
115
|
+
message.amount = object.amount ?? 0;
|
|
116
|
+
message.customerid = object.customerid ?? 0;
|
|
117
|
+
message.loan_id = object.loan_id ?? 0;
|
|
118
|
+
message.payment_id = object.payment_id ?? 0;
|
|
119
|
+
message.mode = object.mode ?? "";
|
|
120
|
+
return message;
|
|
121
|
+
},
|
|
122
|
+
};
|
|
123
|
+
function createBaseforeclosePaymentResponse() {
|
|
124
|
+
return { message: "" };
|
|
125
|
+
}
|
|
126
|
+
exports.foreclosePaymentResponse = {
|
|
127
|
+
encode(message, writer = minimal_1.default.Writer.create()) {
|
|
128
|
+
if (message.message !== "") {
|
|
129
|
+
writer.uint32(10).string(message.message);
|
|
130
|
+
}
|
|
131
|
+
return writer;
|
|
132
|
+
},
|
|
133
|
+
decode(input, length) {
|
|
134
|
+
const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
|
|
135
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
136
|
+
const message = createBaseforeclosePaymentResponse();
|
|
137
|
+
while (reader.pos < end) {
|
|
138
|
+
const tag = reader.uint32();
|
|
139
|
+
switch (tag >>> 3) {
|
|
140
|
+
case 1:
|
|
141
|
+
if (tag !== 10) {
|
|
142
|
+
break;
|
|
143
|
+
}
|
|
144
|
+
message.message = reader.string();
|
|
145
|
+
continue;
|
|
146
|
+
}
|
|
147
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
148
|
+
break;
|
|
149
|
+
}
|
|
150
|
+
reader.skipType(tag & 7);
|
|
151
|
+
}
|
|
152
|
+
return message;
|
|
153
|
+
},
|
|
154
|
+
fromJSON(object) {
|
|
155
|
+
return { message: isSet(object.message) ? globalThis.String(object.message) : "" };
|
|
156
|
+
},
|
|
157
|
+
toJSON(message) {
|
|
158
|
+
const obj = {};
|
|
159
|
+
if (message.message !== "") {
|
|
160
|
+
obj.message = message.message;
|
|
161
|
+
}
|
|
162
|
+
return obj;
|
|
163
|
+
},
|
|
164
|
+
create(base) {
|
|
165
|
+
return exports.foreclosePaymentResponse.fromPartial(base ?? {});
|
|
166
|
+
},
|
|
167
|
+
fromPartial(object) {
|
|
168
|
+
const message = createBaseforeclosePaymentResponse();
|
|
169
|
+
message.message = object.message ?? "";
|
|
170
|
+
return message;
|
|
171
|
+
},
|
|
172
|
+
};
|
|
173
|
+
function isSet(value) {
|
|
174
|
+
return value !== null && value !== undefined;
|
|
175
|
+
}
|
|
@@ -20,6 +20,8 @@ export interface getLoanByIdResponse {
|
|
|
20
20
|
processing_fee: number;
|
|
21
21
|
colenderId: number;
|
|
22
22
|
fees: getLoanByIdResponse_Field | undefined;
|
|
23
|
+
loan_create_date: string;
|
|
24
|
+
net_payable_amount: number;
|
|
23
25
|
}
|
|
24
26
|
export interface getLoanByIdResponse_Field {
|
|
25
27
|
processing_fee: number;
|
package/ts/loans/getloanbyid.js
CHANGED
|
@@ -80,6 +80,8 @@ function createBasegetLoanByIdResponse() {
|
|
|
80
80
|
processing_fee: 0,
|
|
81
81
|
colenderId: 0,
|
|
82
82
|
fees: undefined,
|
|
83
|
+
loan_create_date: "",
|
|
84
|
+
net_payable_amount: 0,
|
|
83
85
|
};
|
|
84
86
|
}
|
|
85
87
|
exports.getLoanByIdResponse = {
|
|
@@ -132,6 +134,12 @@ exports.getLoanByIdResponse = {
|
|
|
132
134
|
if (message.fees !== undefined) {
|
|
133
135
|
exports.getLoanByIdResponse_Field.encode(message.fees, writer.uint32(130).fork()).ldelim();
|
|
134
136
|
}
|
|
137
|
+
if (message.loan_create_date !== "") {
|
|
138
|
+
writer.uint32(138).string(message.loan_create_date);
|
|
139
|
+
}
|
|
140
|
+
if (message.net_payable_amount !== 0) {
|
|
141
|
+
writer.uint32(144).int32(message.net_payable_amount);
|
|
142
|
+
}
|
|
135
143
|
return writer;
|
|
136
144
|
},
|
|
137
145
|
decode(input, length) {
|
|
@@ -237,6 +245,18 @@ exports.getLoanByIdResponse = {
|
|
|
237
245
|
}
|
|
238
246
|
message.fees = exports.getLoanByIdResponse_Field.decode(reader, reader.uint32());
|
|
239
247
|
continue;
|
|
248
|
+
case 17:
|
|
249
|
+
if (tag !== 138) {
|
|
250
|
+
break;
|
|
251
|
+
}
|
|
252
|
+
message.loan_create_date = reader.string();
|
|
253
|
+
continue;
|
|
254
|
+
case 18:
|
|
255
|
+
if (tag !== 144) {
|
|
256
|
+
break;
|
|
257
|
+
}
|
|
258
|
+
message.net_payable_amount = reader.int32();
|
|
259
|
+
continue;
|
|
240
260
|
}
|
|
241
261
|
if ((tag & 7) === 4 || tag === 0) {
|
|
242
262
|
break;
|
|
@@ -265,6 +285,8 @@ exports.getLoanByIdResponse = {
|
|
|
265
285
|
processing_fee: isSet(object.processing_fee) ? globalThis.Number(object.processing_fee) : 0,
|
|
266
286
|
colenderId: isSet(object.colenderId) ? globalThis.Number(object.colenderId) : 0,
|
|
267
287
|
fees: isSet(object.fees) ? exports.getLoanByIdResponse_Field.fromJSON(object.fees) : undefined,
|
|
288
|
+
loan_create_date: isSet(object.loan_create_date) ? globalThis.String(object.loan_create_date) : "",
|
|
289
|
+
net_payable_amount: isSet(object.net_payable_amount) ? globalThis.Number(object.net_payable_amount) : 0,
|
|
268
290
|
};
|
|
269
291
|
},
|
|
270
292
|
toJSON(message) {
|
|
@@ -317,6 +339,12 @@ exports.getLoanByIdResponse = {
|
|
|
317
339
|
if (message.fees !== undefined) {
|
|
318
340
|
obj.fees = exports.getLoanByIdResponse_Field.toJSON(message.fees);
|
|
319
341
|
}
|
|
342
|
+
if (message.loan_create_date !== "") {
|
|
343
|
+
obj.loan_create_date = message.loan_create_date;
|
|
344
|
+
}
|
|
345
|
+
if (message.net_payable_amount !== 0) {
|
|
346
|
+
obj.net_payable_amount = Math.round(message.net_payable_amount);
|
|
347
|
+
}
|
|
320
348
|
return obj;
|
|
321
349
|
},
|
|
322
350
|
create(base) {
|
|
@@ -342,6 +370,8 @@ exports.getLoanByIdResponse = {
|
|
|
342
370
|
message.fees = (object.fees !== undefined && object.fees !== null)
|
|
343
371
|
? exports.getLoanByIdResponse_Field.fromPartial(object.fees)
|
|
344
372
|
: undefined;
|
|
373
|
+
message.loan_create_date = object.loan_create_date ?? "";
|
|
374
|
+
message.net_payable_amount = object.net_payable_amount ?? 0;
|
|
345
375
|
return message;
|
|
346
376
|
},
|
|
347
377
|
};
|
package/ts/loans.d.ts
CHANGED
|
@@ -6,6 +6,7 @@ import { calculateEmiRequest, calculateEmiResponse } from "./loans/calculateemi"
|
|
|
6
6
|
import { creditLimitRequest, creditLimitResponse } from "./loans/creditlimit";
|
|
7
7
|
import { fcpPaymentRequest, fcpPaymentResponse } from "./loans/fcppayment";
|
|
8
8
|
import { forecloseAmountRequest, forecloseAmountResponse } from "./loans/forecloseamount";
|
|
9
|
+
import { foreclosePaymentRequest, foreclosePaymentResponse } from "./loans/foreclosepayment";
|
|
9
10
|
import { futurePaymentMoreDetailsRequest, futurePaymentMoreDetailsResponse } from "./loans/futurepaymentmoredetails";
|
|
10
11
|
import { getBillDetailsRequest, getBillDetailsResponse } from "./loans/getbilldetails";
|
|
11
12
|
import { getCustomerLoanStatusRequest, getCustomerLoanStatusResponse } from "./loans/getcustomerloanstatus";
|
|
@@ -242,6 +243,15 @@ export declare const loansService: {
|
|
|
242
243
|
readonly responseSerialize: (value: forecloseAmountResponse) => Buffer;
|
|
243
244
|
readonly responseDeserialize: (value: Buffer) => forecloseAmountResponse;
|
|
244
245
|
};
|
|
246
|
+
readonly foreclosePayment: {
|
|
247
|
+
readonly path: "/service.loans/foreclosePayment";
|
|
248
|
+
readonly requestStream: false;
|
|
249
|
+
readonly responseStream: false;
|
|
250
|
+
readonly requestSerialize: (value: foreclosePaymentRequest) => Buffer;
|
|
251
|
+
readonly requestDeserialize: (value: Buffer) => foreclosePaymentRequest;
|
|
252
|
+
readonly responseSerialize: (value: foreclosePaymentResponse) => Buffer;
|
|
253
|
+
readonly responseDeserialize: (value: Buffer) => foreclosePaymentResponse;
|
|
254
|
+
};
|
|
245
255
|
};
|
|
246
256
|
export interface loansServer extends UntypedServiceImplementation {
|
|
247
257
|
creditlimit: handleUnaryCall<creditLimitRequest, creditLimitResponse>;
|
|
@@ -268,6 +278,7 @@ export interface loansServer extends UntypedServiceImplementation {
|
|
|
268
278
|
amortization: handleUnaryCall<amortizationRequest, amortizationResponse>;
|
|
269
279
|
fcpPayment: handleUnaryCall<fcpPaymentRequest, fcpPaymentResponse>;
|
|
270
280
|
forecloseAmount: handleUnaryCall<forecloseAmountRequest, forecloseAmountResponse>;
|
|
281
|
+
foreclosePayment: handleUnaryCall<foreclosePaymentRequest, foreclosePaymentResponse>;
|
|
271
282
|
}
|
|
272
283
|
export interface loansClient extends Client {
|
|
273
284
|
creditlimit(request: creditLimitRequest, callback: (error: ServiceError | null, response: creditLimitResponse) => void): ClientUnaryCall;
|
|
@@ -342,6 +353,9 @@ export interface loansClient extends Client {
|
|
|
342
353
|
forecloseAmount(request: forecloseAmountRequest, callback: (error: ServiceError | null, response: forecloseAmountResponse) => void): ClientUnaryCall;
|
|
343
354
|
forecloseAmount(request: forecloseAmountRequest, metadata: Metadata, callback: (error: ServiceError | null, response: forecloseAmountResponse) => void): ClientUnaryCall;
|
|
344
355
|
forecloseAmount(request: forecloseAmountRequest, metadata: Metadata, options: Partial<CallOptions>, callback: (error: ServiceError | null, response: forecloseAmountResponse) => void): ClientUnaryCall;
|
|
356
|
+
foreclosePayment(request: foreclosePaymentRequest, callback: (error: ServiceError | null, response: foreclosePaymentResponse) => void): ClientUnaryCall;
|
|
357
|
+
foreclosePayment(request: foreclosePaymentRequest, metadata: Metadata, callback: (error: ServiceError | null, response: foreclosePaymentResponse) => void): ClientUnaryCall;
|
|
358
|
+
foreclosePayment(request: foreclosePaymentRequest, metadata: Metadata, options: Partial<CallOptions>, callback: (error: ServiceError | null, response: foreclosePaymentResponse) => void): ClientUnaryCall;
|
|
345
359
|
}
|
|
346
360
|
export declare const loansClient: {
|
|
347
361
|
new (address: string, credentials: ChannelCredentials, options?: Partial<ClientOptions>): loansClient;
|
package/ts/loans.js
CHANGED
|
@@ -15,6 +15,7 @@ const calculateemi_1 = require("./loans/calculateemi");
|
|
|
15
15
|
const creditlimit_1 = require("./loans/creditlimit");
|
|
16
16
|
const fcppayment_1 = require("./loans/fcppayment");
|
|
17
17
|
const forecloseamount_1 = require("./loans/forecloseamount");
|
|
18
|
+
const foreclosepayment_1 = require("./loans/foreclosepayment");
|
|
18
19
|
const futurepaymentmoredetails_1 = require("./loans/futurepaymentmoredetails");
|
|
19
20
|
const getbilldetails_1 = require("./loans/getbilldetails");
|
|
20
21
|
const getcustomerloanstatus_1 = require("./loans/getcustomerloanstatus");
|
|
@@ -250,5 +251,14 @@ exports.loansService = {
|
|
|
250
251
|
responseSerialize: (value) => Buffer.from(forecloseamount_1.forecloseAmountResponse.encode(value).finish()),
|
|
251
252
|
responseDeserialize: (value) => forecloseamount_1.forecloseAmountResponse.decode(value),
|
|
252
253
|
},
|
|
254
|
+
foreclosePayment: {
|
|
255
|
+
path: "/service.loans/foreclosePayment",
|
|
256
|
+
requestStream: false,
|
|
257
|
+
responseStream: false,
|
|
258
|
+
requestSerialize: (value) => Buffer.from(foreclosepayment_1.foreclosePaymentRequest.encode(value).finish()),
|
|
259
|
+
requestDeserialize: (value) => foreclosepayment_1.foreclosePaymentRequest.decode(value),
|
|
260
|
+
responseSerialize: (value) => Buffer.from(foreclosepayment_1.foreclosePaymentResponse.encode(value).finish()),
|
|
261
|
+
responseDeserialize: (value) => foreclosepayment_1.foreclosePaymentResponse.decode(value),
|
|
262
|
+
},
|
|
253
263
|
};
|
|
254
264
|
exports.loansClient = (0, grpc_js_1.makeGenericClientConstructor)(exports.loansService, "service.loans");
|