@stashfin/grpc 1.2.724 → 1.2.725

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stashfin/grpc",
3
- "version": "1.2.724",
3
+ "version": "1.2.725",
4
4
  "description": "Grpc proto manger",
5
5
  "scripts": {
6
6
  "prebuild": "rimraf src/ts && mkdirp src/ts && mkdirp dist",
@@ -6,6 +6,7 @@ import { getCustomerByIdRequest, getCustomerByIdResponse } from "./eqxcustomers/
6
6
  import { getCustomerByMobileRequest, getCustomerByMobileResponse } from "./eqxcustomers/getcustomerbymobile";
7
7
  import { getDashboardRequest, getDashboardResponse } from "./eqxcustomers/getdashboard";
8
8
  import { getDashboardMainCardRequest, getDashboardMainCardResponse } from "./eqxcustomers/getdashboardmaincard";
9
+ import { getLoanPlansRequest, getLoanPlansResponse } from "./eqxcustomers/getloanplans";
9
10
  import { getNotificationsRequest, getNotificationsResponse } from "./eqxcustomers/getnotifications";
10
11
  import { getStashScoreProfileByIdRequest, getStashScoreProfileByIdResponse } from "./eqxcustomers/getstashscorecustomerprofile";
11
12
  import { getTokensRequest, getTokensResponse } from "./eqxcustomers/gettokens";
@@ -182,6 +183,15 @@ export declare const eqxcustomersService: {
182
183
  readonly responseSerialize: (value: isCustomerRegisteredResponse) => Buffer;
183
184
  readonly responseDeserialize: (value: Buffer) => isCustomerRegisteredResponse;
184
185
  };
186
+ readonly getLoanPlans: {
187
+ readonly path: "/service.eqxcustomers/getLoanPlans";
188
+ readonly requestStream: false;
189
+ readonly responseStream: false;
190
+ readonly requestSerialize: (value: getLoanPlansRequest) => Buffer;
191
+ readonly requestDeserialize: (value: Buffer) => getLoanPlansRequest;
192
+ readonly responseSerialize: (value: getLoanPlansResponse) => Buffer;
193
+ readonly responseDeserialize: (value: Buffer) => getLoanPlansResponse;
194
+ };
185
195
  };
186
196
  export interface eqxcustomersServer extends UntypedServiceImplementation {
187
197
  sendOtp: handleUnaryCall<sendOtpRequest, sendOtpResponse>;
@@ -202,6 +212,7 @@ export interface eqxcustomersServer extends UntypedServiceImplementation {
202
212
  getCreditGuidanceDetails: handleUnaryCall<getCreditGuidanceRequest, getCreditGuidanceResponse>;
203
213
  updateSubscriptionStatus: handleUnaryCall<updateSubscriptionStatusRequest, updateSubscriptionStatusResponse>;
204
214
  isCustomerRegistered: handleUnaryCall<isCustomerRegisteredRequest, isCustomerRegisteredResponse>;
215
+ getLoanPlans: handleUnaryCall<getLoanPlansRequest, getLoanPlansResponse>;
205
216
  }
206
217
  export interface eqxcustomersClient extends Client {
207
218
  sendOtp(request: sendOtpRequest, callback: (error: ServiceError | null, response: sendOtpResponse) => void): ClientUnaryCall;
@@ -258,6 +269,9 @@ export interface eqxcustomersClient extends Client {
258
269
  isCustomerRegistered(request: isCustomerRegisteredRequest, callback: (error: ServiceError | null, response: isCustomerRegisteredResponse) => void): ClientUnaryCall;
259
270
  isCustomerRegistered(request: isCustomerRegisteredRequest, metadata: Metadata, callback: (error: ServiceError | null, response: isCustomerRegisteredResponse) => void): ClientUnaryCall;
260
271
  isCustomerRegistered(request: isCustomerRegisteredRequest, metadata: Metadata, options: Partial<CallOptions>, callback: (error: ServiceError | null, response: isCustomerRegisteredResponse) => void): ClientUnaryCall;
272
+ getLoanPlans(request: getLoanPlansRequest, callback: (error: ServiceError | null, response: getLoanPlansResponse) => void): ClientUnaryCall;
273
+ getLoanPlans(request: getLoanPlansRequest, metadata: Metadata, callback: (error: ServiceError | null, response: getLoanPlansResponse) => void): ClientUnaryCall;
274
+ getLoanPlans(request: getLoanPlansRequest, metadata: Metadata, options: Partial<CallOptions>, callback: (error: ServiceError | null, response: getLoanPlansResponse) => void): ClientUnaryCall;
261
275
  }
262
276
  export declare const eqxcustomersClient: {
263
277
  new (address: string, credentials: ChannelCredentials, options?: Partial<ClientOptions>): eqxcustomersClient;
package/ts/eqxcustomer.js CHANGED
@@ -15,6 +15,7 @@ const getcustomerbyid_1 = require("./eqxcustomers/getcustomerbyid");
15
15
  const getcustomerbymobile_1 = require("./eqxcustomers/getcustomerbymobile");
16
16
  const getdashboard_1 = require("./eqxcustomers/getdashboard");
17
17
  const getdashboardmaincard_1 = require("./eqxcustomers/getdashboardmaincard");
18
+ const getloanplans_1 = require("./eqxcustomers/getloanplans");
18
19
  const getnotifications_1 = require("./eqxcustomers/getnotifications");
19
20
  const getstashscorecustomerprofile_1 = require("./eqxcustomers/getstashscorecustomerprofile");
20
21
  const gettokens_1 = require("./eqxcustomers/gettokens");
@@ -190,5 +191,14 @@ exports.eqxcustomersService = {
190
191
  responseSerialize: (value) => Buffer.from(iscustomerregistered_1.isCustomerRegisteredResponse.encode(value).finish()),
191
192
  responseDeserialize: (value) => iscustomerregistered_1.isCustomerRegisteredResponse.decode(value),
192
193
  },
194
+ getLoanPlans: {
195
+ path: "/service.eqxcustomers/getLoanPlans",
196
+ requestStream: false,
197
+ responseStream: false,
198
+ requestSerialize: (value) => Buffer.from(getloanplans_1.getLoanPlansRequest.encode(value).finish()),
199
+ requestDeserialize: (value) => getloanplans_1.getLoanPlansRequest.decode(value),
200
+ responseSerialize: (value) => Buffer.from(getloanplans_1.getLoanPlansResponse.encode(value).finish()),
201
+ responseDeserialize: (value) => getloanplans_1.getLoanPlansResponse.decode(value),
202
+ },
193
203
  };
194
204
  exports.eqxcustomersClient = (0, grpc_js_1.makeGenericClientConstructor)(exports.eqxcustomersService, "service.eqxcustomers");
@@ -0,0 +1,49 @@
1
+ import _m0 from "protobufjs/minimal";
2
+ export declare const protobufPackage = "eqxcustomers.getloanplans";
3
+ export interface getLoanPlansRequest {
4
+ }
5
+ export interface loanPlansData {
6
+ header_image: string;
7
+ header_title: string;
8
+ benifits: string[];
9
+ }
10
+ export interface getLoanPlansResponse {
11
+ message: string;
12
+ status: string;
13
+ data: loanPlansData[];
14
+ }
15
+ export declare const getLoanPlansRequest: {
16
+ encode(_: getLoanPlansRequest, writer?: _m0.Writer): _m0.Writer;
17
+ decode(input: _m0.Reader | Uint8Array, length?: number): getLoanPlansRequest;
18
+ fromJSON(_: any): getLoanPlansRequest;
19
+ toJSON(_: getLoanPlansRequest): unknown;
20
+ create<I extends Exact<DeepPartial<getLoanPlansRequest>, I>>(base?: I): getLoanPlansRequest;
21
+ fromPartial<I extends Exact<DeepPartial<getLoanPlansRequest>, I>>(_: I): getLoanPlansRequest;
22
+ };
23
+ export declare const loanPlansData: {
24
+ encode(message: loanPlansData, writer?: _m0.Writer): _m0.Writer;
25
+ decode(input: _m0.Reader | Uint8Array, length?: number): loanPlansData;
26
+ fromJSON(object: any): loanPlansData;
27
+ toJSON(message: loanPlansData): unknown;
28
+ create<I extends Exact<DeepPartial<loanPlansData>, I>>(base?: I): loanPlansData;
29
+ fromPartial<I extends Exact<DeepPartial<loanPlansData>, I>>(object: I): loanPlansData;
30
+ };
31
+ export declare const getLoanPlansResponse: {
32
+ encode(message: getLoanPlansResponse, writer?: _m0.Writer): _m0.Writer;
33
+ decode(input: _m0.Reader | Uint8Array, length?: number): getLoanPlansResponse;
34
+ fromJSON(object: any): getLoanPlansResponse;
35
+ toJSON(message: getLoanPlansResponse): unknown;
36
+ create<I extends Exact<DeepPartial<getLoanPlansResponse>, I>>(base?: I): getLoanPlansResponse;
37
+ fromPartial<I extends Exact<DeepPartial<getLoanPlansResponse>, I>>(object: I): getLoanPlansResponse;
38
+ };
39
+ type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
40
+ 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 {} ? {
41
+ [K in keyof T]?: DeepPartial<T[K]>;
42
+ } : Partial<T>;
43
+ type KeysOfUnion<T> = T extends T ? keyof T : never;
44
+ export type Exact<P, I extends P> = P extends Builtin ? P : P & {
45
+ [K in keyof P]: Exact<P[K], I[K]>;
46
+ } & {
47
+ [K in Exclude<keyof I, KeysOfUnion<P>>]: never;
48
+ };
49
+ export {};
@@ -0,0 +1,214 @@
1
+ "use strict";
2
+ // Code generated by protoc-gen-ts_proto. DO NOT EDIT.
3
+ // versions:
4
+ // protoc-gen-ts_proto v1.181.1
5
+ // protoc v3.20.3
6
+ // source: eqxcustomers/getloanplans.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.getLoanPlansResponse = exports.loanPlansData = exports.getLoanPlansRequest = exports.protobufPackage = void 0;
12
+ /* eslint-disable */
13
+ const minimal_1 = __importDefault(require("protobufjs/minimal"));
14
+ exports.protobufPackage = "eqxcustomers.getloanplans";
15
+ function createBasegetLoanPlansRequest() {
16
+ return {};
17
+ }
18
+ exports.getLoanPlansRequest = {
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 = createBasegetLoanPlansRequest();
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.getLoanPlansRequest.fromPartial(base ?? {});
46
+ },
47
+ fromPartial(_) {
48
+ const message = createBasegetLoanPlansRequest();
49
+ return message;
50
+ },
51
+ };
52
+ function createBaseloanPlansData() {
53
+ return { header_image: "", header_title: "", benifits: [] };
54
+ }
55
+ exports.loanPlansData = {
56
+ encode(message, writer = minimal_1.default.Writer.create()) {
57
+ if (message.header_image !== "") {
58
+ writer.uint32(10).string(message.header_image);
59
+ }
60
+ if (message.header_title !== "") {
61
+ writer.uint32(18).string(message.header_title);
62
+ }
63
+ for (const v of message.benifits) {
64
+ writer.uint32(26).string(v);
65
+ }
66
+ return writer;
67
+ },
68
+ decode(input, length) {
69
+ const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
70
+ let end = length === undefined ? reader.len : reader.pos + length;
71
+ const message = createBaseloanPlansData();
72
+ while (reader.pos < end) {
73
+ const tag = reader.uint32();
74
+ switch (tag >>> 3) {
75
+ case 1:
76
+ if (tag !== 10) {
77
+ break;
78
+ }
79
+ message.header_image = reader.string();
80
+ continue;
81
+ case 2:
82
+ if (tag !== 18) {
83
+ break;
84
+ }
85
+ message.header_title = reader.string();
86
+ continue;
87
+ case 3:
88
+ if (tag !== 26) {
89
+ break;
90
+ }
91
+ message.benifits.push(reader.string());
92
+ continue;
93
+ }
94
+ if ((tag & 7) === 4 || tag === 0) {
95
+ break;
96
+ }
97
+ reader.skipType(tag & 7);
98
+ }
99
+ return message;
100
+ },
101
+ fromJSON(object) {
102
+ return {
103
+ header_image: isSet(object.header_image) ? globalThis.String(object.header_image) : "",
104
+ header_title: isSet(object.header_title) ? globalThis.String(object.header_title) : "",
105
+ benifits: globalThis.Array.isArray(object?.benifits) ? object.benifits.map((e) => globalThis.String(e)) : [],
106
+ };
107
+ },
108
+ toJSON(message) {
109
+ const obj = {};
110
+ if (message.header_image !== "") {
111
+ obj.header_image = message.header_image;
112
+ }
113
+ if (message.header_title !== "") {
114
+ obj.header_title = message.header_title;
115
+ }
116
+ if (message.benifits?.length) {
117
+ obj.benifits = message.benifits;
118
+ }
119
+ return obj;
120
+ },
121
+ create(base) {
122
+ return exports.loanPlansData.fromPartial(base ?? {});
123
+ },
124
+ fromPartial(object) {
125
+ const message = createBaseloanPlansData();
126
+ message.header_image = object.header_image ?? "";
127
+ message.header_title = object.header_title ?? "";
128
+ message.benifits = object.benifits?.map((e) => e) || [];
129
+ return message;
130
+ },
131
+ };
132
+ function createBasegetLoanPlansResponse() {
133
+ return { message: "", status: "", data: [] };
134
+ }
135
+ exports.getLoanPlansResponse = {
136
+ encode(message, writer = minimal_1.default.Writer.create()) {
137
+ if (message.message !== "") {
138
+ writer.uint32(10).string(message.message);
139
+ }
140
+ if (message.status !== "") {
141
+ writer.uint32(18).string(message.status);
142
+ }
143
+ for (const v of message.data) {
144
+ exports.loanPlansData.encode(v, writer.uint32(26).fork()).ldelim();
145
+ }
146
+ return writer;
147
+ },
148
+ decode(input, length) {
149
+ const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
150
+ let end = length === undefined ? reader.len : reader.pos + length;
151
+ const message = createBasegetLoanPlansResponse();
152
+ while (reader.pos < end) {
153
+ const tag = reader.uint32();
154
+ switch (tag >>> 3) {
155
+ case 1:
156
+ if (tag !== 10) {
157
+ break;
158
+ }
159
+ message.message = reader.string();
160
+ continue;
161
+ case 2:
162
+ if (tag !== 18) {
163
+ break;
164
+ }
165
+ message.status = reader.string();
166
+ continue;
167
+ case 3:
168
+ if (tag !== 26) {
169
+ break;
170
+ }
171
+ message.data.push(exports.loanPlansData.decode(reader, reader.uint32()));
172
+ continue;
173
+ }
174
+ if ((tag & 7) === 4 || tag === 0) {
175
+ break;
176
+ }
177
+ reader.skipType(tag & 7);
178
+ }
179
+ return message;
180
+ },
181
+ fromJSON(object) {
182
+ return {
183
+ message: isSet(object.message) ? globalThis.String(object.message) : "",
184
+ status: isSet(object.status) ? globalThis.String(object.status) : "",
185
+ data: globalThis.Array.isArray(object?.data) ? object.data.map((e) => exports.loanPlansData.fromJSON(e)) : [],
186
+ };
187
+ },
188
+ toJSON(message) {
189
+ const obj = {};
190
+ if (message.message !== "") {
191
+ obj.message = message.message;
192
+ }
193
+ if (message.status !== "") {
194
+ obj.status = message.status;
195
+ }
196
+ if (message.data?.length) {
197
+ obj.data = message.data.map((e) => exports.loanPlansData.toJSON(e));
198
+ }
199
+ return obj;
200
+ },
201
+ create(base) {
202
+ return exports.getLoanPlansResponse.fromPartial(base ?? {});
203
+ },
204
+ fromPartial(object) {
205
+ const message = createBasegetLoanPlansResponse();
206
+ message.message = object.message ?? "";
207
+ message.status = object.status ?? "";
208
+ message.data = object.data?.map((e) => exports.loanPlansData.fromPartial(e)) || [];
209
+ return message;
210
+ },
211
+ };
212
+ function isSet(value) {
213
+ return value !== null && value !== undefined;
214
+ }
@@ -4,8 +4,8 @@ export interface GetLocDisburseRequest {
4
4
  customer_id: number;
5
5
  }
6
6
  export interface GetLocDisburseResponse {
7
- msg: string;
8
- status: string;
7
+ msg?: string | undefined;
8
+ status?: string | undefined;
9
9
  }
10
10
  export declare const GetLocDisburseRequest: {
11
11
  encode(message: GetLocDisburseRequest, writer?: _m0.Writer): _m0.Writer;
@@ -63,14 +63,14 @@ exports.GetLocDisburseRequest = {
63
63
  },
64
64
  };
65
65
  function createBaseGetLocDisburseResponse() {
66
- return { msg: "", status: "" };
66
+ return { msg: undefined, status: undefined };
67
67
  }
68
68
  exports.GetLocDisburseResponse = {
69
69
  encode(message, writer = minimal_1.default.Writer.create()) {
70
- if (message.msg !== "") {
70
+ if (message.msg !== undefined) {
71
71
  writer.uint32(10).string(message.msg);
72
72
  }
73
- if (message.status !== "") {
73
+ if (message.status !== undefined) {
74
74
  writer.uint32(18).string(message.status);
75
75
  }
76
76
  return writer;
@@ -104,16 +104,16 @@ exports.GetLocDisburseResponse = {
104
104
  },
105
105
  fromJSON(object) {
106
106
  return {
107
- msg: isSet(object.msg) ? globalThis.String(object.msg) : "",
108
- status: isSet(object.status) ? globalThis.String(object.status) : "",
107
+ msg: isSet(object.msg) ? globalThis.String(object.msg) : undefined,
108
+ status: isSet(object.status) ? globalThis.String(object.status) : undefined,
109
109
  };
110
110
  },
111
111
  toJSON(message) {
112
112
  const obj = {};
113
- if (message.msg !== "") {
113
+ if (message.msg !== undefined) {
114
114
  obj.msg = message.msg;
115
115
  }
116
- if (message.status !== "") {
116
+ if (message.status !== undefined) {
117
117
  obj.status = message.status;
118
118
  }
119
119
  return obj;
@@ -123,8 +123,8 @@ exports.GetLocDisburseResponse = {
123
123
  },
124
124
  fromPartial(object) {
125
125
  const message = createBaseGetLocDisburseResponse();
126
- message.msg = object.msg ?? "";
127
- message.status = object.status ?? "";
126
+ message.msg = object.msg ?? undefined;
127
+ message.status = object.status ?? undefined;
128
128
  return message;
129
129
  },
130
130
  };