ggez-banking-sdk 0.1.192 → 0.1.193
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/dist/api/clients/user.js +21 -21
- package/dist/api/services/user.d.ts +23 -23
- package/dist/api/services/user.js +24 -24
- package/package.json +1 -1
package/dist/api/clients/user.js
CHANGED
|
@@ -19,10 +19,10 @@ class UserClient extends BaseClient {
|
|
|
19
19
|
if (data.token && data.id) {
|
|
20
20
|
const config = AxiosHelper.GetAxiosConfig(data.token, this.clientData.baseUrl, this.clientData.lang);
|
|
21
21
|
const userService = new UserService({ config, userId: data.id }, this.errorHandler);
|
|
22
|
-
response = await userService.getUser(
|
|
22
|
+
response = await userService.getUser();
|
|
23
23
|
}
|
|
24
24
|
else {
|
|
25
|
-
response = await this.userService.getUser(
|
|
25
|
+
response = await this.userService.getUser();
|
|
26
26
|
}
|
|
27
27
|
return this.responseHelper.GetResponse(response.data);
|
|
28
28
|
}
|
|
@@ -34,7 +34,7 @@ class UserClient extends BaseClient {
|
|
|
34
34
|
};
|
|
35
35
|
GetTermsAndConditions = async () => {
|
|
36
36
|
try {
|
|
37
|
-
const response = await this.userService.getTermsAndConditions(
|
|
37
|
+
const response = await this.userService.getTermsAndConditions();
|
|
38
38
|
return this.responseHelper.GetResponse(response.data);
|
|
39
39
|
}
|
|
40
40
|
catch (error) {
|
|
@@ -45,7 +45,7 @@ class UserClient extends BaseClient {
|
|
|
45
45
|
};
|
|
46
46
|
GetSecurity = async () => {
|
|
47
47
|
try {
|
|
48
|
-
const response = await this.userService.getSecurity(
|
|
48
|
+
const response = await this.userService.getSecurity();
|
|
49
49
|
return this.responseHelper.GetResponse(response.data);
|
|
50
50
|
}
|
|
51
51
|
catch (error) {
|
|
@@ -56,7 +56,7 @@ class UserClient extends BaseClient {
|
|
|
56
56
|
};
|
|
57
57
|
GetPhone = async () => {
|
|
58
58
|
try {
|
|
59
|
-
const response = await this.userService.getPhone(
|
|
59
|
+
const response = await this.userService.getPhone();
|
|
60
60
|
return this.responseHelper.GetResponse(response.data);
|
|
61
61
|
}
|
|
62
62
|
catch (error) {
|
|
@@ -67,7 +67,7 @@ class UserClient extends BaseClient {
|
|
|
67
67
|
};
|
|
68
68
|
GetPreferences = async () => {
|
|
69
69
|
try {
|
|
70
|
-
const response = await this.userService.getPreferences(
|
|
70
|
+
const response = await this.userService.getPreferences();
|
|
71
71
|
return this.responseHelper.GetResponse(response.data);
|
|
72
72
|
}
|
|
73
73
|
catch (error) {
|
|
@@ -78,7 +78,7 @@ class UserClient extends BaseClient {
|
|
|
78
78
|
};
|
|
79
79
|
GetPersonalInfo = async () => {
|
|
80
80
|
try {
|
|
81
|
-
const response = await this.userService.getPersonalInfo(
|
|
81
|
+
const response = await this.userService.getPersonalInfo();
|
|
82
82
|
return this.responseHelper.GetResponse(response.data);
|
|
83
83
|
}
|
|
84
84
|
catch (error) {
|
|
@@ -89,7 +89,7 @@ class UserClient extends BaseClient {
|
|
|
89
89
|
};
|
|
90
90
|
GetLatestHistory = async () => {
|
|
91
91
|
try {
|
|
92
|
-
const response = await this.userService.getLatestHistory(
|
|
92
|
+
const response = await this.userService.getLatestHistory();
|
|
93
93
|
return this.responseHelper.GetResponse(response.data);
|
|
94
94
|
}
|
|
95
95
|
catch (error) {
|
|
@@ -100,7 +100,7 @@ class UserClient extends BaseClient {
|
|
|
100
100
|
};
|
|
101
101
|
GetIdentification = async () => {
|
|
102
102
|
try {
|
|
103
|
-
const response = await this.userService.getIdentification(
|
|
103
|
+
const response = await this.userService.getIdentification();
|
|
104
104
|
return this.responseHelper.GetResponse(response.data);
|
|
105
105
|
}
|
|
106
106
|
catch (error) {
|
|
@@ -111,7 +111,7 @@ class UserClient extends BaseClient {
|
|
|
111
111
|
};
|
|
112
112
|
GetHistory = async () => {
|
|
113
113
|
try {
|
|
114
|
-
const response = await this.userService.getHistory(
|
|
114
|
+
const response = await this.userService.getHistory();
|
|
115
115
|
return this.responseHelper.GetResponse(response.data);
|
|
116
116
|
}
|
|
117
117
|
catch (error) {
|
|
@@ -122,7 +122,7 @@ class UserClient extends BaseClient {
|
|
|
122
122
|
};
|
|
123
123
|
GetGroup = async () => {
|
|
124
124
|
try {
|
|
125
|
-
const response = await this.userService.getGroup(
|
|
125
|
+
const response = await this.userService.getGroup();
|
|
126
126
|
return this.responseHelper.GetResponse(response.data);
|
|
127
127
|
}
|
|
128
128
|
catch (error) {
|
|
@@ -133,7 +133,7 @@ class UserClient extends BaseClient {
|
|
|
133
133
|
};
|
|
134
134
|
GetExternalAuth = async () => {
|
|
135
135
|
try {
|
|
136
|
-
const response = await this.userService.getExternalAuth(
|
|
136
|
+
const response = await this.userService.getExternalAuth();
|
|
137
137
|
return this.responseHelper.GetResponse(response.data);
|
|
138
138
|
}
|
|
139
139
|
catch (error) {
|
|
@@ -144,7 +144,7 @@ class UserClient extends BaseClient {
|
|
|
144
144
|
};
|
|
145
145
|
GetEmail = async () => {
|
|
146
146
|
try {
|
|
147
|
-
const response = await this.userService.getEmail(
|
|
147
|
+
const response = await this.userService.getEmail();
|
|
148
148
|
return this.responseHelper.GetResponse(response.data);
|
|
149
149
|
}
|
|
150
150
|
catch (error) {
|
|
@@ -155,7 +155,7 @@ class UserClient extends BaseClient {
|
|
|
155
155
|
};
|
|
156
156
|
GetDocuments = async () => {
|
|
157
157
|
try {
|
|
158
|
-
const response = await this.userService.getDocuments(
|
|
158
|
+
const response = await this.userService.getDocuments();
|
|
159
159
|
return this.responseHelper.GetResponse(response.data);
|
|
160
160
|
}
|
|
161
161
|
catch (error) {
|
|
@@ -166,7 +166,7 @@ class UserClient extends BaseClient {
|
|
|
166
166
|
};
|
|
167
167
|
GetCurrency = async () => {
|
|
168
168
|
try {
|
|
169
|
-
const response = await this.userService.getCurrency(
|
|
169
|
+
const response = await this.userService.getCurrency();
|
|
170
170
|
return this.responseHelper.GetResponse(response.data);
|
|
171
171
|
}
|
|
172
172
|
catch (error) {
|
|
@@ -177,7 +177,7 @@ class UserClient extends BaseClient {
|
|
|
177
177
|
};
|
|
178
178
|
GetCreditCard = async () => {
|
|
179
179
|
try {
|
|
180
|
-
const response = await this.userService.getCreditCard(
|
|
180
|
+
const response = await this.userService.getCreditCard();
|
|
181
181
|
return this.responseHelper.GetResponse(response.data);
|
|
182
182
|
}
|
|
183
183
|
catch (error) {
|
|
@@ -188,7 +188,7 @@ class UserClient extends BaseClient {
|
|
|
188
188
|
};
|
|
189
189
|
GetBankAccount = async () => {
|
|
190
190
|
try {
|
|
191
|
-
const response = await this.userService.getBankAccount(
|
|
191
|
+
const response = await this.userService.getBankAccount();
|
|
192
192
|
return this.responseHelper.GetResponse(response.data);
|
|
193
193
|
}
|
|
194
194
|
catch (error) {
|
|
@@ -199,7 +199,7 @@ class UserClient extends BaseClient {
|
|
|
199
199
|
};
|
|
200
200
|
GetAddress = async () => {
|
|
201
201
|
try {
|
|
202
|
-
const response = await this.userService.getAddress(
|
|
202
|
+
const response = await this.userService.getAddress();
|
|
203
203
|
return this.responseHelper.GetResponse(response.data);
|
|
204
204
|
}
|
|
205
205
|
catch (error) {
|
|
@@ -210,7 +210,7 @@ class UserClient extends BaseClient {
|
|
|
210
210
|
};
|
|
211
211
|
GetAccount = async () => {
|
|
212
212
|
try {
|
|
213
|
-
const response = await this.userService.getAccount(
|
|
213
|
+
const response = await this.userService.getAccount();
|
|
214
214
|
return this.responseHelper.GetResponse(response.data);
|
|
215
215
|
}
|
|
216
216
|
catch (error) {
|
|
@@ -221,7 +221,7 @@ class UserClient extends BaseClient {
|
|
|
221
221
|
};
|
|
222
222
|
GetSecurityOperations = async () => {
|
|
223
223
|
try {
|
|
224
|
-
const response = await this.userService.getActivity(
|
|
224
|
+
const response = await this.userService.getActivity();
|
|
225
225
|
return this.responseHelper.GetResponse(response.data);
|
|
226
226
|
}
|
|
227
227
|
catch (error) {
|
|
@@ -232,7 +232,7 @@ class UserClient extends BaseClient {
|
|
|
232
232
|
};
|
|
233
233
|
GetDeviceHistory = async () => {
|
|
234
234
|
try {
|
|
235
|
-
const response = await this.userService.getDeviceHistory(
|
|
235
|
+
const response = await this.userService.getDeviceHistory();
|
|
236
236
|
return this.responseHelper.GetResponse(response.data);
|
|
237
237
|
}
|
|
238
238
|
catch (error) {
|
|
@@ -6,26 +6,26 @@ declare class UserService extends BaseService {
|
|
|
6
6
|
userId: number;
|
|
7
7
|
endpoint: string;
|
|
8
8
|
constructor(data: UserServiceParameters, errorHandler: ErrorHandler);
|
|
9
|
-
getUser(
|
|
10
|
-
getTermsAndConditions(
|
|
11
|
-
getSecurity(
|
|
12
|
-
getPhone(
|
|
13
|
-
getPreferences(
|
|
14
|
-
getPersonalInfo(
|
|
15
|
-
getLatestHistory(
|
|
16
|
-
getIdentification(
|
|
17
|
-
getHistory(
|
|
18
|
-
getGroup(
|
|
19
|
-
getExternalAuth(
|
|
20
|
-
getEmail(
|
|
21
|
-
getDocuments(
|
|
22
|
-
getCurrency(
|
|
23
|
-
getCreditCard(
|
|
24
|
-
getBankAccount(
|
|
25
|
-
getAddress(
|
|
26
|
-
getAccount(
|
|
27
|
-
getDeviceHistory(
|
|
28
|
-
getActivity(
|
|
9
|
+
getUser(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
10
|
+
getTermsAndConditions(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
11
|
+
getSecurity(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
12
|
+
getPhone(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
13
|
+
getPreferences(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
14
|
+
getPersonalInfo(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
15
|
+
getLatestHistory(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
16
|
+
getIdentification(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
17
|
+
getHistory(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
18
|
+
getGroup(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
19
|
+
getExternalAuth(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
20
|
+
getEmail(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
21
|
+
getDocuments(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
22
|
+
getCurrency(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
23
|
+
getCreditCard(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
24
|
+
getBankAccount(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
25
|
+
getAddress(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
26
|
+
getAccount(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
27
|
+
getDeviceHistory(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
28
|
+
getActivity(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
29
29
|
createUser(payload: UserData, config: AxiosRequestConfig): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
30
30
|
createPhone(payload: UserData): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
31
31
|
createDevice(payload: UserData): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
@@ -61,14 +61,14 @@ declare class UserService extends BaseService {
|
|
|
61
61
|
updateBankAccount(payload: UserData): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
62
62
|
updateAddress(payload: UserData): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
63
63
|
updateUserType(payload: UserData): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
64
|
-
deleteUser(
|
|
65
|
-
deleteCreditCard(
|
|
64
|
+
deleteUser(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
65
|
+
deleteCreditCard(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
66
66
|
deleteAddress(payload: UserData): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
67
67
|
deleteDevice(payload: UserData): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
68
68
|
deleteBankAccount(payload: UserData): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
69
69
|
deleteIdentification(payload: UserData): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
70
70
|
deleteEmail(payload: UserData): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
71
71
|
deletePhone(payload: UserData): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
72
|
-
deleteExternalAuth(
|
|
72
|
+
deleteExternalAuth(): Promise<import("axios").AxiosResponse<UserData, any, {}>>;
|
|
73
73
|
}
|
|
74
74
|
export { UserService };
|
|
@@ -20,83 +20,83 @@ class UserService extends BaseService {
|
|
|
20
20
|
});
|
|
21
21
|
}
|
|
22
22
|
// #region "GET"
|
|
23
|
-
getUser(
|
|
23
|
+
getUser() {
|
|
24
24
|
const url = this.resolveURL(`/${this.userId}`);
|
|
25
25
|
return this.GET(url);
|
|
26
26
|
}
|
|
27
|
-
getTermsAndConditions(
|
|
27
|
+
getTermsAndConditions() {
|
|
28
28
|
const url = this.resolveURL(`${UserEndpoints.TermsAndConditions}/${this.userId}`);
|
|
29
29
|
return this.GET(url);
|
|
30
30
|
}
|
|
31
|
-
getSecurity(
|
|
31
|
+
getSecurity() {
|
|
32
32
|
const url = this.resolveURL(`${UserEndpoints.Security}/${this.userId}`);
|
|
33
33
|
return this.GET(url);
|
|
34
34
|
}
|
|
35
|
-
getPhone(
|
|
35
|
+
getPhone() {
|
|
36
36
|
const url = this.resolveURL(`${UserEndpoints.Phone}/${this.userId}`);
|
|
37
37
|
return this.GET(url);
|
|
38
38
|
}
|
|
39
|
-
getPreferences(
|
|
39
|
+
getPreferences() {
|
|
40
40
|
const url = this.resolveURL(`${UserEndpoints.Preferences}/${this.userId}`);
|
|
41
41
|
return this.GET(url);
|
|
42
42
|
}
|
|
43
|
-
getPersonalInfo(
|
|
43
|
+
getPersonalInfo() {
|
|
44
44
|
const url = this.resolveURL(`${UserEndpoints.PersonalInfo}/${this.userId}`);
|
|
45
45
|
return this.GET(url);
|
|
46
46
|
}
|
|
47
|
-
getLatestHistory(
|
|
47
|
+
getLatestHistory() {
|
|
48
48
|
const url = this.resolveURL(`${UserEndpoints.HistoryLatest}/${this.userId}`);
|
|
49
49
|
return this.GET(url);
|
|
50
50
|
}
|
|
51
|
-
getIdentification(
|
|
51
|
+
getIdentification() {
|
|
52
52
|
const url = this.resolveURL(`${UserEndpoints.Identification}/${this.userId}`);
|
|
53
53
|
return this.GET(url);
|
|
54
54
|
}
|
|
55
|
-
getHistory(
|
|
55
|
+
getHistory() {
|
|
56
56
|
const url = this.resolveURL(`${UserEndpoints.HistoryLatest}/${this.userId}`);
|
|
57
57
|
return this.GET(url);
|
|
58
58
|
}
|
|
59
|
-
getGroup(
|
|
59
|
+
getGroup() {
|
|
60
60
|
const url = this.resolveURL(`${UserEndpoints.Group}/${this.userId}`);
|
|
61
61
|
return this.GET(url);
|
|
62
62
|
}
|
|
63
|
-
getExternalAuth(
|
|
63
|
+
getExternalAuth() {
|
|
64
64
|
const url = this.resolveURL(`${UserEndpoints.ExternalAuth}/${this.userId}`);
|
|
65
65
|
return this.GET(url);
|
|
66
66
|
}
|
|
67
|
-
getEmail(
|
|
67
|
+
getEmail() {
|
|
68
68
|
const url = this.resolveURL(`${UserEndpoints.Email}/${this.userId}`);
|
|
69
69
|
return this.GET(url);
|
|
70
70
|
}
|
|
71
|
-
getDocuments(
|
|
71
|
+
getDocuments() {
|
|
72
72
|
const url = this.resolveURL(`${UserEndpoints.Documents}/${this.userId}`);
|
|
73
73
|
return this.GET(url);
|
|
74
74
|
}
|
|
75
|
-
getCurrency(
|
|
75
|
+
getCurrency() {
|
|
76
76
|
const url = this.resolveURL(`${UserEndpoints.Currency}/${this.userId}`);
|
|
77
77
|
return this.GET(url);
|
|
78
78
|
}
|
|
79
|
-
getCreditCard(
|
|
79
|
+
getCreditCard() {
|
|
80
80
|
const url = this.resolveURL(`${UserEndpoints.CreditCard}/${this.userId}`);
|
|
81
81
|
return this.GET(url);
|
|
82
82
|
}
|
|
83
|
-
getBankAccount(
|
|
83
|
+
getBankAccount() {
|
|
84
84
|
const url = this.resolveURL(`${UserEndpoints.BankAccount}/${this.userId}`);
|
|
85
85
|
return this.GET(url);
|
|
86
86
|
}
|
|
87
|
-
getAddress(
|
|
87
|
+
getAddress() {
|
|
88
88
|
const url = this.resolveURL(`${UserEndpoints.Address}/${this.userId}`);
|
|
89
89
|
return this.GET(url);
|
|
90
90
|
}
|
|
91
|
-
getAccount(
|
|
91
|
+
getAccount() {
|
|
92
92
|
const url = this.resolveURL(`${UserEndpoints.Account}/${this.userId}`);
|
|
93
93
|
return this.GET(url);
|
|
94
94
|
}
|
|
95
|
-
getDeviceHistory(
|
|
95
|
+
getDeviceHistory() {
|
|
96
96
|
const url = this.resolveURL(`${UserEndpoints.DeviceHistory}/${this.userId}`);
|
|
97
97
|
return this.GET(url);
|
|
98
98
|
}
|
|
99
|
-
getActivity(
|
|
99
|
+
getActivity() {
|
|
100
100
|
const url = this.resolveURL(`${UserEndpoints.Activity}/${this.userId}`);
|
|
101
101
|
return this.GET(url);
|
|
102
102
|
}
|
|
@@ -241,16 +241,16 @@ class UserService extends BaseService {
|
|
|
241
241
|
return this.PUT(url, payload);
|
|
242
242
|
}
|
|
243
243
|
updateUserType(payload) {
|
|
244
|
-
const url = this.resolveURL(`${UserEndpoints.Type}/${this.userId}
|
|
244
|
+
const url = this.resolveURL(`${UserEndpoints.Type}/${this.userId}`);
|
|
245
245
|
return this.PUT(url, payload);
|
|
246
246
|
}
|
|
247
247
|
// #endregion
|
|
248
248
|
// #region "DELETE"
|
|
249
|
-
deleteUser(
|
|
249
|
+
deleteUser() {
|
|
250
250
|
const url = this.resolveURL(`/${this.userId}`);
|
|
251
251
|
return this.DELETE(url);
|
|
252
252
|
}
|
|
253
|
-
deleteCreditCard(
|
|
253
|
+
deleteCreditCard() {
|
|
254
254
|
const url = this.resolveURL(`${UserEndpoints.CreditCard}/${this.userId}`);
|
|
255
255
|
return this.DELETE(url);
|
|
256
256
|
}
|
|
@@ -278,7 +278,7 @@ class UserService extends BaseService {
|
|
|
278
278
|
const url = this.resolveURL(`${UserEndpoints.Phone}/${this.userId}`);
|
|
279
279
|
return this.DELETE(url, payload);
|
|
280
280
|
}
|
|
281
|
-
deleteExternalAuth(
|
|
281
|
+
deleteExternalAuth() {
|
|
282
282
|
const url = this.resolveURL(`${UserEndpoints.ExternalAuth}/${this.userId}`);
|
|
283
283
|
return this.DELETE(url);
|
|
284
284
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ggez-banking-sdk",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.193",
|
|
4
4
|
"description": "A Node.js package to handle GGEZ Banking API endpoints, Simplify the process of managing CRUD operations with this efficient and easy-to-use package.",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"main": "dist/index.js",
|