@abyss-project/banking 1.0.0 → 1.0.1
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/src/api/abyss.admin.api.ts +0 -16
- package/src/api/banking.admin.api.ts +0 -141
- package/src/api/banking.api.ts +0 -197
- package/src/api/categorization-rule.admin.api.ts +0 -80
- package/src/api/categorization-rule.api.ts +0 -80
- package/src/api/category.admin.api.ts +0 -63
- package/src/api/category.api.ts +0 -74
- package/src/api/index.ts +0 -12
- package/src/api/monitor.api.ts +0 -6
- package/src/api/panel.admin.api.ts +0 -57
- package/src/api/panel.api.ts +0 -45
- package/src/api/user.admin.api.ts +0 -44
- package/src/api/user.api.ts +0 -20
- package/src/index.ts +0 -72
- package/src/types/enum/aggregator-type.enum.ts +0 -4
- package/src/types/enum/api-error.enum.ts +0 -18
- package/src/types/enum/bank-connection-status.enum.ts +0 -6
- package/src/types/enum/cash-account-type.enum.ts +0 -54
- package/src/types/enum/index.ts +0 -7
- package/src/types/enum/panel-component-type.enum.ts +0 -12
- package/src/types/enum/period-configuration.enum.ts +0 -7
- package/src/types/index.ts +0 -2
- package/src/types/interface/api/index.ts +0 -29
- package/src/types/interface/api/requests/abyss.admin.request.ts +0 -3
- package/src/types/interface/api/requests/banking.admin.request.ts +0 -57
- package/src/types/interface/api/requests/banking.request.ts +0 -89
- package/src/types/interface/api/requests/categorization-rule.admin.request.ts +0 -40
- package/src/types/interface/api/requests/categorization-rule.request.ts +0 -38
- package/src/types/interface/api/requests/category.admin.request.ts +0 -27
- package/src/types/interface/api/requests/category.request.ts +0 -31
- package/src/types/interface/api/requests/panel.admin.request.ts +0 -28
- package/src/types/interface/api/requests/panel.request.ts +0 -27
- package/src/types/interface/api/requests/user.admin.request.ts +0 -20
- package/src/types/interface/api/requests/user.request.ts +0 -2
- package/src/types/interface/api/responses/abyss.admin.response.ts +0 -7
- package/src/types/interface/api/responses/banking.admin.response.ts +0 -73
- package/src/types/interface/api/responses/banking.response.ts +0 -119
- package/src/types/interface/api/responses/categorization-rule.admin.response.ts +0 -28
- package/src/types/interface/api/responses/categorization-rule.response.ts +0 -28
- package/src/types/interface/api/responses/category.admin.response.ts +0 -24
- package/src/types/interface/api/responses/category.response.ts +0 -39
- package/src/types/interface/api/responses/monitor.response.ts +0 -8
- package/src/types/interface/api/responses/panel.admin.response.ts +0 -24
- package/src/types/interface/api/responses/panel.response.ts +0 -24
- package/src/types/interface/api/responses/storage.admin.response.ts +0 -4
- package/src/types/interface/api/responses/user.admin.response.ts +0 -18
- package/src/types/interface/api/responses/user.response.ts +0 -16
- package/src/types/interface/api/type-message/api-error.ts +0 -9
- package/src/types/interface/api/type-message/base-order.ts +0 -4
- package/src/types/interface/api/type-message/base-paginate.ts +0 -11
- package/src/types/interface/api/type-message/response.ts +0 -6
- package/src/types/interface/index.ts +0 -15
- package/src/types/interface/models/account-transaction.model.ts +0 -53
- package/src/types/interface/models/aggregator-bank.model.ts +0 -15
- package/src/types/interface/models/aggregator-link.model.ts +0 -15
- package/src/types/interface/models/bank-account-history.model.ts +0 -14
- package/src/types/interface/models/bank-account.model.ts +0 -29
- package/src/types/interface/models/bank-connection.model.ts +0 -20
- package/src/types/interface/models/categorization-rule-category.model.ts +0 -14
- package/src/types/interface/models/categorization-rule.model.ts +0 -48
- package/src/types/interface/models/category.model.ts +0 -17
- package/src/types/interface/models/panel.model.ts +0 -135
- package/src/types/interface/models/transaction-category.model.ts +0 -17
- package/src/types/interface/models/user.model.ts +0 -16
- package/src/utils/error.utils.ts +0 -30
- package/src/utils/index.ts +0 -1
package/package.json
CHANGED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
AbyssBankingCore,
|
|
3
|
-
IActivateUserServiceAbyssAdminBody,
|
|
4
|
-
IActivateUserServiceAbyssAdminResponse,
|
|
5
|
-
} from '..';
|
|
6
|
-
|
|
7
|
-
export const activateUserServiceAbyssAdmin = async (
|
|
8
|
-
body: IActivateUserServiceAbyssAdminBody,
|
|
9
|
-
): Promise<IActivateUserServiceAbyssAdminResponse> => {
|
|
10
|
-
return (
|
|
11
|
-
await AbyssBankingCore.axios.post<IActivateUserServiceAbyssAdminResponse>(
|
|
12
|
-
`abyss/admin/user/activate-service`,
|
|
13
|
-
body,
|
|
14
|
-
)
|
|
15
|
-
).data;
|
|
16
|
-
};
|
|
@@ -1,141 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
AbyssBankingCore,
|
|
3
|
-
IConfirmRequisitionBankingAdminParams,
|
|
4
|
-
IConfirmRequisitionBankingAdminResponse,
|
|
5
|
-
IListInstitutionBankingAdminResponse,
|
|
6
|
-
IListInstitutionBankingAdminQuery,
|
|
7
|
-
IListBankConnectionBankingAdminResponse,
|
|
8
|
-
IListBankBankingAdminResponse,
|
|
9
|
-
IGetBankConnectionBankingAdminResponse,
|
|
10
|
-
IGetBankConnectionBankingAdminParams,
|
|
11
|
-
IPaginateAccountTransactionBankingAdminQuery,
|
|
12
|
-
IPaginateAccountTransactionBankingAdminResponse,
|
|
13
|
-
IGetAccountTransactionBankingAdminParams,
|
|
14
|
-
IGetAccountTransactionBankingAdminResponse,
|
|
15
|
-
IUpdateBankAccountBankingAdminParams,
|
|
16
|
-
IUpdateBankAccountBankingAdminBody,
|
|
17
|
-
IUpdateBankAccountBankingAdminResponse,
|
|
18
|
-
ILoadDemoDataBankingAdminResponse,
|
|
19
|
-
IDeleteDemoDataBankingAdminResponse,
|
|
20
|
-
IListBankConnectionBankingAdminParams,
|
|
21
|
-
ILoadDemoDataBankingAdminParams,
|
|
22
|
-
IDeleteDemoDataBankingAdminParams,
|
|
23
|
-
IUpdateAccountTransactionBankingAdminParams,
|
|
24
|
-
IUpdateAccountTransactionBankingAdminBody,
|
|
25
|
-
} from '..';
|
|
26
|
-
|
|
27
|
-
export const listBankConnectionBankingAdmin = async (
|
|
28
|
-
params: IListBankConnectionBankingAdminParams,
|
|
29
|
-
): Promise<IListBankConnectionBankingAdminResponse> => {
|
|
30
|
-
return (
|
|
31
|
-
await AbyssBankingCore.axios.get<IListBankConnectionBankingAdminResponse>(
|
|
32
|
-
`banking/admin/connection/${params.userId}/list`,
|
|
33
|
-
)
|
|
34
|
-
).data;
|
|
35
|
-
};
|
|
36
|
-
|
|
37
|
-
export const getBankConnectionBankingAdmin = async (
|
|
38
|
-
params: IGetBankConnectionBankingAdminParams,
|
|
39
|
-
): Promise<IGetBankConnectionBankingAdminResponse> => {
|
|
40
|
-
return (
|
|
41
|
-
await AbyssBankingCore.axios.get<IGetBankConnectionBankingAdminResponse>(
|
|
42
|
-
`banking/admin/connection/${params.bankConnectionId}`,
|
|
43
|
-
)
|
|
44
|
-
).data;
|
|
45
|
-
};
|
|
46
|
-
|
|
47
|
-
export const listBankBankingAdmin = async (): Promise<IListBankBankingAdminResponse> => {
|
|
48
|
-
return (
|
|
49
|
-
await AbyssBankingCore.axios.get<IListBankBankingAdminResponse>(`banking/admin/bank/list`)
|
|
50
|
-
).data;
|
|
51
|
-
};
|
|
52
|
-
|
|
53
|
-
export const listInstitutionBankingAdmin = async (
|
|
54
|
-
query: IListInstitutionBankingAdminQuery,
|
|
55
|
-
): Promise<IListInstitutionBankingAdminResponse> => {
|
|
56
|
-
return (
|
|
57
|
-
await AbyssBankingCore.axios.get<IListInstitutionBankingAdminResponse>(
|
|
58
|
-
`banking/admin/institution/list`,
|
|
59
|
-
{ params: query },
|
|
60
|
-
)
|
|
61
|
-
).data;
|
|
62
|
-
};
|
|
63
|
-
|
|
64
|
-
export const confirmRequisitionBankingAdmin = async (
|
|
65
|
-
params: IConfirmRequisitionBankingAdminParams,
|
|
66
|
-
): Promise<IConfirmRequisitionBankingAdminResponse> => {
|
|
67
|
-
return (
|
|
68
|
-
await AbyssBankingCore.axios.post<IConfirmRequisitionBankingAdminResponse>(
|
|
69
|
-
`banking/admin/requisition/confirm/${params.userId}/${params.reference}`,
|
|
70
|
-
)
|
|
71
|
-
).data;
|
|
72
|
-
};
|
|
73
|
-
|
|
74
|
-
export const paginateAccountTransactionBankingAdmin = async (
|
|
75
|
-
query: IPaginateAccountTransactionBankingAdminQuery,
|
|
76
|
-
): Promise<IPaginateAccountTransactionBankingAdminResponse> => {
|
|
77
|
-
return (
|
|
78
|
-
await AbyssBankingCore.axios.get<IPaginateAccountTransactionBankingAdminResponse>(
|
|
79
|
-
`banking/admin/transaction/paginate`,
|
|
80
|
-
{ params: query },
|
|
81
|
-
)
|
|
82
|
-
).data;
|
|
83
|
-
};
|
|
84
|
-
|
|
85
|
-
export const getAccountTransactionBankingAdmin = async (
|
|
86
|
-
params: IGetAccountTransactionBankingAdminParams,
|
|
87
|
-
): Promise<IGetAccountTransactionBankingAdminResponse> => {
|
|
88
|
-
return (
|
|
89
|
-
await AbyssBankingCore.axios.get<IGetAccountTransactionBankingAdminResponse>(
|
|
90
|
-
`banking/admin/transaction/${params.accountTransactionId}`,
|
|
91
|
-
)
|
|
92
|
-
).data;
|
|
93
|
-
};
|
|
94
|
-
|
|
95
|
-
export const updateAccountTransactionBankingAdmin = async (
|
|
96
|
-
params: IUpdateAccountTransactionBankingAdminParams,
|
|
97
|
-
body: IUpdateAccountTransactionBankingAdminBody,
|
|
98
|
-
): Promise<IGetAccountTransactionBankingAdminResponse> => {
|
|
99
|
-
return (
|
|
100
|
-
await AbyssBankingCore.axios.put<IGetAccountTransactionBankingAdminResponse>(
|
|
101
|
-
`banking/admin/transaction/${params.accountTransactionId}`,
|
|
102
|
-
body,
|
|
103
|
-
)
|
|
104
|
-
).data;
|
|
105
|
-
};
|
|
106
|
-
|
|
107
|
-
export const updateBankAccountBankingAdmin = async (
|
|
108
|
-
params: IUpdateBankAccountBankingAdminParams,
|
|
109
|
-
body: IUpdateBankAccountBankingAdminBody,
|
|
110
|
-
): Promise<IUpdateBankAccountBankingAdminResponse> => {
|
|
111
|
-
return (
|
|
112
|
-
await AbyssBankingCore.axios.put<IUpdateBankAccountBankingAdminResponse>(
|
|
113
|
-
`banking/admin/account/${params.bankAccountId}`,
|
|
114
|
-
body,
|
|
115
|
-
)
|
|
116
|
-
).data;
|
|
117
|
-
};
|
|
118
|
-
|
|
119
|
-
export const loadDemoDataBankingAdmin = async (
|
|
120
|
-
params: ILoadDemoDataBankingAdminParams,
|
|
121
|
-
): Promise<ILoadDemoDataBankingAdminResponse> => {
|
|
122
|
-
return (
|
|
123
|
-
await AbyssBankingCore.axios.post<ILoadDemoDataBankingAdminResponse>(
|
|
124
|
-
`banking/admin/demo-data/${params.userId}`,
|
|
125
|
-
)
|
|
126
|
-
).data;
|
|
127
|
-
};
|
|
128
|
-
|
|
129
|
-
export const deleteDemoDataBankingAdmin = async (
|
|
130
|
-
params: IDeleteDemoDataBankingAdminParams,
|
|
131
|
-
): Promise<IDeleteDemoDataBankingAdminResponse> => {
|
|
132
|
-
return (
|
|
133
|
-
await AbyssBankingCore.axios.delete<IDeleteDemoDataBankingAdminResponse>(
|
|
134
|
-
`banking/admin/demo-data/${params.userId}`,
|
|
135
|
-
)
|
|
136
|
-
).data;
|
|
137
|
-
};
|
|
138
|
-
|
|
139
|
-
export const fetchBankingDataBankingAdmin = async (): Promise<string> => {
|
|
140
|
-
return (await AbyssBankingCore.axios.post<string>(`banking/admin/fetch-banking-data`)).data;
|
|
141
|
-
};
|
package/src/api/banking.api.ts
DELETED
|
@@ -1,197 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
AbyssBankingCore,
|
|
3
|
-
IConfirmRequisitionBankingParams,
|
|
4
|
-
IConfirmRequisitionBankingResponse,
|
|
5
|
-
ICreateRequisitionBankingBody,
|
|
6
|
-
ICreateRequisitionBankingResponse,
|
|
7
|
-
IListInstitutionBankingResponse,
|
|
8
|
-
IListInstitutionBankingQuery,
|
|
9
|
-
IListConnectionBankingResponse,
|
|
10
|
-
IListBankBankingResponse,
|
|
11
|
-
IGetBankConnectionBankingResponse,
|
|
12
|
-
IGetBankConnectionBankingParams,
|
|
13
|
-
IRenewRequisitionBankingParams,
|
|
14
|
-
IRenewRequisitionBankingResponse,
|
|
15
|
-
IRenewRequisitionBankingBody,
|
|
16
|
-
IPaginateAccountTransactionBankingQuery,
|
|
17
|
-
IPaginateAccountTransactionBankingResponse,
|
|
18
|
-
IGetAccountTransactionBankingParams,
|
|
19
|
-
IGetAccountTransactionBankingResponse,
|
|
20
|
-
IUpdateBankAccountBankingParams,
|
|
21
|
-
IUpdateBankAccountBankingBody,
|
|
22
|
-
IUpdateBankAccountBankingResponse,
|
|
23
|
-
ILoadDemoDataBankingResponse,
|
|
24
|
-
IDeleteDemoDataBankingResponse,
|
|
25
|
-
IGetTransactionPerCategoryBankingQuery,
|
|
26
|
-
IGetTransactionPerCategoryBankingResponse,
|
|
27
|
-
IGetSumTransactionPerBankAccountPerCategoryQuery,
|
|
28
|
-
IGetSumTransactionPerBankAccountPerCategoryBankingResponse,
|
|
29
|
-
IPaginateBankAccountHistoryBankingQuery,
|
|
30
|
-
IPaginateBankAccountHistoryBankingResponse,
|
|
31
|
-
IListBankAccountHistoryBankingQuery,
|
|
32
|
-
IListBankAccountHistoryBankingResponse,
|
|
33
|
-
IUpdateAccountTransactionBankingParams,
|
|
34
|
-
IUpdateAccountTransactionBankingBody,
|
|
35
|
-
} from '..';
|
|
36
|
-
|
|
37
|
-
export const listConnectionBanking = async (): Promise<IListConnectionBankingResponse> => {
|
|
38
|
-
return (
|
|
39
|
-
await AbyssBankingCore.axios.get<IListConnectionBankingResponse>(`banking/connection/list`)
|
|
40
|
-
).data;
|
|
41
|
-
};
|
|
42
|
-
|
|
43
|
-
export const getBankConnectionBanking = async (
|
|
44
|
-
params: IGetBankConnectionBankingParams,
|
|
45
|
-
): Promise<IGetBankConnectionBankingResponse> => {
|
|
46
|
-
return (
|
|
47
|
-
await AbyssBankingCore.axios.get<IGetBankConnectionBankingResponse>(
|
|
48
|
-
`banking/connection/${params.bankConnectionId}`,
|
|
49
|
-
)
|
|
50
|
-
).data;
|
|
51
|
-
};
|
|
52
|
-
|
|
53
|
-
export const listBankBanking = async (): Promise<IListBankBankingResponse> => {
|
|
54
|
-
return (await AbyssBankingCore.axios.get<IListBankBankingResponse>(`banking/bank/list`)).data;
|
|
55
|
-
};
|
|
56
|
-
|
|
57
|
-
export const listInstitutionBanking = async (
|
|
58
|
-
query: IListInstitutionBankingQuery,
|
|
59
|
-
): Promise<IListInstitutionBankingResponse> => {
|
|
60
|
-
return (
|
|
61
|
-
await AbyssBankingCore.axios.get<IListInstitutionBankingResponse>(`banking/institution/list`, {
|
|
62
|
-
params: query,
|
|
63
|
-
})
|
|
64
|
-
).data;
|
|
65
|
-
};
|
|
66
|
-
|
|
67
|
-
export const createRequisitionBanking = async (
|
|
68
|
-
body: ICreateRequisitionBankingBody,
|
|
69
|
-
): Promise<ICreateRequisitionBankingResponse> => {
|
|
70
|
-
return (
|
|
71
|
-
await AbyssBankingCore.axios.post<ICreateRequisitionBankingResponse>(
|
|
72
|
-
`banking/requisition/create`,
|
|
73
|
-
body,
|
|
74
|
-
)
|
|
75
|
-
).data;
|
|
76
|
-
};
|
|
77
|
-
|
|
78
|
-
export const confirmRequisitionBanking = async (
|
|
79
|
-
params: IConfirmRequisitionBankingParams,
|
|
80
|
-
): Promise<IConfirmRequisitionBankingResponse> => {
|
|
81
|
-
return (
|
|
82
|
-
await AbyssBankingCore.axios.post<IConfirmRequisitionBankingResponse>(
|
|
83
|
-
`banking/requisition/confirm/${params.reference}`,
|
|
84
|
-
)
|
|
85
|
-
).data;
|
|
86
|
-
};
|
|
87
|
-
|
|
88
|
-
export const renewRequisitionBanking = async (
|
|
89
|
-
params: IRenewRequisitionBankingParams,
|
|
90
|
-
body: IRenewRequisitionBankingBody,
|
|
91
|
-
): Promise<IRenewRequisitionBankingResponse> => {
|
|
92
|
-
return (
|
|
93
|
-
await AbyssBankingCore.axios.post<IRenewRequisitionBankingResponse>(
|
|
94
|
-
`banking/requisition/${params.bankConnectionId}/renew`,
|
|
95
|
-
body,
|
|
96
|
-
)
|
|
97
|
-
).data;
|
|
98
|
-
};
|
|
99
|
-
|
|
100
|
-
export const paginateAccountTransactionBanking = async (
|
|
101
|
-
query: IPaginateAccountTransactionBankingQuery,
|
|
102
|
-
): Promise<IPaginateAccountTransactionBankingResponse> => {
|
|
103
|
-
return (
|
|
104
|
-
await AbyssBankingCore.axios.get<IPaginateAccountTransactionBankingResponse>(
|
|
105
|
-
`banking/transaction/paginate`,
|
|
106
|
-
{ params: query },
|
|
107
|
-
)
|
|
108
|
-
).data;
|
|
109
|
-
};
|
|
110
|
-
|
|
111
|
-
export const getAccountTransactionBanking = async (
|
|
112
|
-
params: IGetAccountTransactionBankingParams,
|
|
113
|
-
): Promise<IGetAccountTransactionBankingResponse> => {
|
|
114
|
-
return (
|
|
115
|
-
await AbyssBankingCore.axios.get<IGetAccountTransactionBankingResponse>(
|
|
116
|
-
`banking/transaction/${params.accountTransactionId}`,
|
|
117
|
-
)
|
|
118
|
-
).data;
|
|
119
|
-
};
|
|
120
|
-
|
|
121
|
-
export const updateAccountTransactionBanking = async (
|
|
122
|
-
params: IUpdateAccountTransactionBankingParams,
|
|
123
|
-
body: IUpdateAccountTransactionBankingBody,
|
|
124
|
-
): Promise<IGetAccountTransactionBankingResponse> => {
|
|
125
|
-
return (
|
|
126
|
-
await AbyssBankingCore.axios.put<IGetAccountTransactionBankingResponse>(
|
|
127
|
-
`banking/transaction/${params.accountTransactionId}`,
|
|
128
|
-
body,
|
|
129
|
-
)
|
|
130
|
-
).data;
|
|
131
|
-
};
|
|
132
|
-
|
|
133
|
-
export const updateBankAccountBanking = async (
|
|
134
|
-
params: IUpdateBankAccountBankingParams,
|
|
135
|
-
body: IUpdateBankAccountBankingBody,
|
|
136
|
-
): Promise<IUpdateBankAccountBankingResponse> => {
|
|
137
|
-
return (
|
|
138
|
-
await AbyssBankingCore.axios.put<IUpdateBankAccountBankingResponse>(
|
|
139
|
-
`banking/account/${params.bankAccountId}`,
|
|
140
|
-
body,
|
|
141
|
-
)
|
|
142
|
-
).data;
|
|
143
|
-
};
|
|
144
|
-
|
|
145
|
-
export const loadDemoDataBanking = async (): Promise<ILoadDemoDataBankingResponse> => {
|
|
146
|
-
return (await AbyssBankingCore.axios.post<ILoadDemoDataBankingResponse>(`banking/demo-data`))
|
|
147
|
-
.data;
|
|
148
|
-
};
|
|
149
|
-
|
|
150
|
-
export const deleteDemoDataBanking = async (): Promise<IDeleteDemoDataBankingResponse> => {
|
|
151
|
-
return (await AbyssBankingCore.axios.delete<IDeleteDemoDataBankingResponse>(`banking/demo-data`))
|
|
152
|
-
.data;
|
|
153
|
-
};
|
|
154
|
-
|
|
155
|
-
export const getTransactionPerCategoryBanking = async (
|
|
156
|
-
query: IGetTransactionPerCategoryBankingQuery,
|
|
157
|
-
): Promise<IGetTransactionPerCategoryBankingResponse> => {
|
|
158
|
-
return (
|
|
159
|
-
await AbyssBankingCore.axios.get<IGetTransactionPerCategoryBankingResponse>(
|
|
160
|
-
`banking/transaction-per-category`,
|
|
161
|
-
{ params: query },
|
|
162
|
-
)
|
|
163
|
-
).data;
|
|
164
|
-
};
|
|
165
|
-
|
|
166
|
-
export const getSumTransactionPerBankAccountPerCategoryBanking = async (
|
|
167
|
-
query: IGetSumTransactionPerBankAccountPerCategoryQuery,
|
|
168
|
-
): Promise<IGetSumTransactionPerBankAccountPerCategoryBankingResponse> => {
|
|
169
|
-
return (
|
|
170
|
-
await AbyssBankingCore.axios.get<IGetSumTransactionPerBankAccountPerCategoryBankingResponse>(
|
|
171
|
-
`banking/sum-transaction-per-bank-account-category`,
|
|
172
|
-
{ params: query },
|
|
173
|
-
)
|
|
174
|
-
).data;
|
|
175
|
-
};
|
|
176
|
-
|
|
177
|
-
export const paginateBankAccountHistoryBanking = async (
|
|
178
|
-
query: IPaginateBankAccountHistoryBankingQuery,
|
|
179
|
-
): Promise<IPaginateBankAccountHistoryBankingResponse> => {
|
|
180
|
-
return (
|
|
181
|
-
await AbyssBankingCore.axios.get<IPaginateBankAccountHistoryBankingResponse>(
|
|
182
|
-
`banking/bank-account-history/paginate`,
|
|
183
|
-
{ params: query },
|
|
184
|
-
)
|
|
185
|
-
).data;
|
|
186
|
-
};
|
|
187
|
-
|
|
188
|
-
export const listBankAccountHistoryBanking = async (
|
|
189
|
-
query: IListBankAccountHistoryBankingQuery,
|
|
190
|
-
): Promise<IListBankAccountHistoryBankingResponse> => {
|
|
191
|
-
return (
|
|
192
|
-
await AbyssBankingCore.axios.get<IListBankAccountHistoryBankingResponse>(
|
|
193
|
-
`banking/bank-account-history/list`,
|
|
194
|
-
{ params: query },
|
|
195
|
-
)
|
|
196
|
-
).data;
|
|
197
|
-
};
|
|
@@ -1,80 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
AbyssBankingCore,
|
|
3
|
-
IApplyCategorizationRuleAdminParams,
|
|
4
|
-
IApplyCategorizationRuleAdminResponse,
|
|
5
|
-
ICreateCategorizationRuleAdminBody,
|
|
6
|
-
ICreateCategorizationRuleAdminResponse,
|
|
7
|
-
IDeleteCategorizationRuleAdminParams,
|
|
8
|
-
IDeleteCategorizationRuleAdminResponse,
|
|
9
|
-
IGetCategorizationRuleAdminParams,
|
|
10
|
-
IGetCategorizationRuleAdminResponse,
|
|
11
|
-
IPaginateCategorizationRuleAdminQuery,
|
|
12
|
-
IPaginateCategorizationRuleAdminResponse,
|
|
13
|
-
IUpdateCategorizationRuleAdminBody,
|
|
14
|
-
IUpdateCategorizationRuleAdminParams,
|
|
15
|
-
IUpdateCategorizationRuleAdminResponse,
|
|
16
|
-
} from '..';
|
|
17
|
-
|
|
18
|
-
export const getCategorizationRuleAdmin = async (
|
|
19
|
-
params: IGetCategorizationRuleAdminParams,
|
|
20
|
-
): Promise<IGetCategorizationRuleAdminResponse> => {
|
|
21
|
-
return (
|
|
22
|
-
await AbyssBankingCore.axios.get<IGetCategorizationRuleAdminResponse>(
|
|
23
|
-
`categorization-rule/admin/${params.categorizationRuleId}`,
|
|
24
|
-
)
|
|
25
|
-
).data;
|
|
26
|
-
};
|
|
27
|
-
|
|
28
|
-
export const applyCategorizationRuleAdmin = async (
|
|
29
|
-
params: IApplyCategorizationRuleAdminParams,
|
|
30
|
-
): Promise<IApplyCategorizationRuleAdminResponse> => {
|
|
31
|
-
return (
|
|
32
|
-
await AbyssBankingCore.axios.post<IApplyCategorizationRuleAdminResponse>(
|
|
33
|
-
`categorization-rule/admin/${params.categorizationRuleId}/apply`,
|
|
34
|
-
)
|
|
35
|
-
).data;
|
|
36
|
-
};
|
|
37
|
-
|
|
38
|
-
export const paginateCategorizationRuleAdmin = async (
|
|
39
|
-
query: IPaginateCategorizationRuleAdminQuery,
|
|
40
|
-
): Promise<IPaginateCategorizationRuleAdminResponse> => {
|
|
41
|
-
return (
|
|
42
|
-
await AbyssBankingCore.axios.get<IPaginateCategorizationRuleAdminResponse>(
|
|
43
|
-
`categorization-rule/admin/paginate`,
|
|
44
|
-
{ params: query },
|
|
45
|
-
)
|
|
46
|
-
).data;
|
|
47
|
-
};
|
|
48
|
-
|
|
49
|
-
export const deleteCategorizationRuleAdmin = async (
|
|
50
|
-
params: IDeleteCategorizationRuleAdminParams,
|
|
51
|
-
): Promise<IDeleteCategorizationRuleAdminResponse> => {
|
|
52
|
-
return (
|
|
53
|
-
await AbyssBankingCore.axios.delete<IDeleteCategorizationRuleAdminResponse>(
|
|
54
|
-
`categorization-rule/admin/${params.categorizationRuleId}`,
|
|
55
|
-
)
|
|
56
|
-
).data;
|
|
57
|
-
};
|
|
58
|
-
|
|
59
|
-
export const createCategorizationRuleAdmin = async (
|
|
60
|
-
body: ICreateCategorizationRuleAdminBody,
|
|
61
|
-
): Promise<ICreateCategorizationRuleAdminResponse> => {
|
|
62
|
-
return (
|
|
63
|
-
await AbyssBankingCore.axios.post<ICreateCategorizationRuleAdminResponse>(
|
|
64
|
-
`categorization-rule/admin`,
|
|
65
|
-
body,
|
|
66
|
-
)
|
|
67
|
-
).data;
|
|
68
|
-
};
|
|
69
|
-
|
|
70
|
-
export const updateCategorizationRuleAdmin = async (
|
|
71
|
-
params: IUpdateCategorizationRuleAdminParams,
|
|
72
|
-
body: IUpdateCategorizationRuleAdminBody,
|
|
73
|
-
): Promise<IUpdateCategorizationRuleAdminResponse> => {
|
|
74
|
-
return (
|
|
75
|
-
await AbyssBankingCore.axios.put<IUpdateCategorizationRuleAdminResponse>(
|
|
76
|
-
`categorization-rule/admin/${params.categorizationRuleId}`,
|
|
77
|
-
body,
|
|
78
|
-
)
|
|
79
|
-
).data;
|
|
80
|
-
};
|
|
@@ -1,80 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
AbyssBankingCore,
|
|
3
|
-
IApplyCategorizationRuleParams,
|
|
4
|
-
IApplyCategorizationRuleResponse,
|
|
5
|
-
ICreateCategorizationRuleBody,
|
|
6
|
-
ICreateCategorizationRuleResponse,
|
|
7
|
-
IDeleteCategorizationRuleParams,
|
|
8
|
-
IDeleteCategorizationRuleResponse,
|
|
9
|
-
IGetCategorizationRuleParams,
|
|
10
|
-
IGetCategorizationRuleResponse,
|
|
11
|
-
IPaginateCategorizationRuleQuery,
|
|
12
|
-
IPaginateCategorizationRuleResponse,
|
|
13
|
-
IUpdateCategorizationRuleBody,
|
|
14
|
-
IUpdateCategorizationRuleParams,
|
|
15
|
-
IUpdateCategorizationRuleResponse,
|
|
16
|
-
} from '..';
|
|
17
|
-
|
|
18
|
-
export const getCategorizationRule = async (
|
|
19
|
-
params: IGetCategorizationRuleParams,
|
|
20
|
-
): Promise<IGetCategorizationRuleResponse> => {
|
|
21
|
-
return (
|
|
22
|
-
await AbyssBankingCore.axios.get<IGetCategorizationRuleResponse>(
|
|
23
|
-
`categorization-rule/${params.categorizationRuleId}`,
|
|
24
|
-
)
|
|
25
|
-
).data;
|
|
26
|
-
};
|
|
27
|
-
|
|
28
|
-
export const applyCategorizationRule = async (
|
|
29
|
-
params: IApplyCategorizationRuleParams,
|
|
30
|
-
): Promise<IApplyCategorizationRuleResponse> => {
|
|
31
|
-
return (
|
|
32
|
-
await AbyssBankingCore.axios.post<IApplyCategorizationRuleResponse>(
|
|
33
|
-
`categorization-rule/${params.categorizationRuleId}/apply`,
|
|
34
|
-
)
|
|
35
|
-
).data;
|
|
36
|
-
};
|
|
37
|
-
|
|
38
|
-
export const paginateCategorizationRule = async (
|
|
39
|
-
query: IPaginateCategorizationRuleQuery,
|
|
40
|
-
): Promise<IPaginateCategorizationRuleResponse> => {
|
|
41
|
-
return (
|
|
42
|
-
await AbyssBankingCore.axios.get<IPaginateCategorizationRuleResponse>(
|
|
43
|
-
`categorization-rule/paginate`,
|
|
44
|
-
{ params: query },
|
|
45
|
-
)
|
|
46
|
-
).data;
|
|
47
|
-
};
|
|
48
|
-
|
|
49
|
-
export const deleteCategorizationRule = async (
|
|
50
|
-
params: IDeleteCategorizationRuleParams,
|
|
51
|
-
): Promise<IDeleteCategorizationRuleResponse> => {
|
|
52
|
-
return (
|
|
53
|
-
await AbyssBankingCore.axios.delete<IDeleteCategorizationRuleResponse>(
|
|
54
|
-
`categorization-rule/${params.categorizationRuleId}`,
|
|
55
|
-
)
|
|
56
|
-
).data;
|
|
57
|
-
};
|
|
58
|
-
|
|
59
|
-
export const createCategorizationRule = async (
|
|
60
|
-
body: ICreateCategorizationRuleBody,
|
|
61
|
-
): Promise<ICreateCategorizationRuleResponse> => {
|
|
62
|
-
return (
|
|
63
|
-
await AbyssBankingCore.axios.post<ICreateCategorizationRuleResponse>(
|
|
64
|
-
`categorization-rule`,
|
|
65
|
-
body,
|
|
66
|
-
)
|
|
67
|
-
).data;
|
|
68
|
-
};
|
|
69
|
-
|
|
70
|
-
export const updateCategorizationRule = async (
|
|
71
|
-
params: IUpdateCategorizationRuleParams,
|
|
72
|
-
body: IUpdateCategorizationRuleBody,
|
|
73
|
-
): Promise<IUpdateCategorizationRuleResponse> => {
|
|
74
|
-
return (
|
|
75
|
-
await AbyssBankingCore.axios.put<IUpdateCategorizationRuleResponse>(
|
|
76
|
-
`categorization-rule/${params.categorizationRuleId}`,
|
|
77
|
-
body,
|
|
78
|
-
)
|
|
79
|
-
).data;
|
|
80
|
-
};
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
import { AbyssBankingCore } from '..';
|
|
2
|
-
import {
|
|
3
|
-
IGetCategoryAdminParams,
|
|
4
|
-
IGetCategoryAdminResponse,
|
|
5
|
-
IPaginateCategoryAdminQuery,
|
|
6
|
-
IPaginateCategoryAdminResponse,
|
|
7
|
-
IDeleteCategoryAdminResponse,
|
|
8
|
-
IDeleteCategoryAdminParams,
|
|
9
|
-
ICreateCategoryAdminBody,
|
|
10
|
-
ICreateCategoryAdminResponse,
|
|
11
|
-
IUpdateCategoryAdminBody,
|
|
12
|
-
IUpdateCategoryAdminParams,
|
|
13
|
-
IUpdateCategoryAdminResponse,
|
|
14
|
-
} from '../types';
|
|
15
|
-
|
|
16
|
-
export const getCategoryAdmin = async (
|
|
17
|
-
params: IGetCategoryAdminParams,
|
|
18
|
-
): Promise<IGetCategoryAdminResponse> => {
|
|
19
|
-
return (
|
|
20
|
-
await AbyssBankingCore.axios.get<IGetCategoryAdminResponse>(
|
|
21
|
-
`category/admin/${params.categoryId}`,
|
|
22
|
-
)
|
|
23
|
-
).data;
|
|
24
|
-
};
|
|
25
|
-
|
|
26
|
-
export const paginateCategoryAdmin = async (
|
|
27
|
-
query: IPaginateCategoryAdminQuery,
|
|
28
|
-
): Promise<IPaginateCategoryAdminResponse> => {
|
|
29
|
-
return (
|
|
30
|
-
await AbyssBankingCore.axios.get<IPaginateCategoryAdminResponse>(`category/admin/paginate`, {
|
|
31
|
-
params: query,
|
|
32
|
-
})
|
|
33
|
-
).data;
|
|
34
|
-
};
|
|
35
|
-
|
|
36
|
-
export const deleteCategoryAdmin = async (
|
|
37
|
-
params: IDeleteCategoryAdminParams,
|
|
38
|
-
): Promise<IDeleteCategoryAdminResponse> => {
|
|
39
|
-
return (
|
|
40
|
-
await AbyssBankingCore.axios.delete<IDeleteCategoryAdminResponse>(
|
|
41
|
-
`category/admin/${params.categoryId}`,
|
|
42
|
-
)
|
|
43
|
-
).data;
|
|
44
|
-
};
|
|
45
|
-
|
|
46
|
-
export const createCategoryAdmin = async (
|
|
47
|
-
body: ICreateCategoryAdminBody,
|
|
48
|
-
): Promise<ICreateCategoryAdminResponse> => {
|
|
49
|
-
return (await AbyssBankingCore.axios.post<ICreateCategoryAdminResponse>(`category/admin`, body))
|
|
50
|
-
.data;
|
|
51
|
-
};
|
|
52
|
-
|
|
53
|
-
export const updateCategoryAdmin = async (
|
|
54
|
-
params: IUpdateCategoryAdminParams,
|
|
55
|
-
body: IUpdateCategoryAdminBody,
|
|
56
|
-
): Promise<IUpdateCategoryAdminResponse> => {
|
|
57
|
-
return (
|
|
58
|
-
await AbyssBankingCore.axios.put<IUpdateCategoryAdminResponse>(
|
|
59
|
-
`category/admin/${params.categoryId}`,
|
|
60
|
-
body,
|
|
61
|
-
)
|
|
62
|
-
).data;
|
|
63
|
-
};
|
package/src/api/category.api.ts
DELETED
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
import { AbyssBankingCore } from '..';
|
|
2
|
-
import {
|
|
3
|
-
IListCategoryResponse,
|
|
4
|
-
IRemoveCategoryResponse,
|
|
5
|
-
IAddCategoryResponse,
|
|
6
|
-
IDeleteCategoryResponse,
|
|
7
|
-
ICreateCategoryResponse,
|
|
8
|
-
IUpdateCategoryResponse,
|
|
9
|
-
IListAnalyticsCategoryResponse,
|
|
10
|
-
} from '../types';
|
|
11
|
-
import {
|
|
12
|
-
IRemoveCategoryParams,
|
|
13
|
-
IAddCategoryParams,
|
|
14
|
-
IDeleteCategoryParams,
|
|
15
|
-
ICreateCategoryBody,
|
|
16
|
-
IUpdateCategoryParams,
|
|
17
|
-
IUpdateCategoryBody,
|
|
18
|
-
IListAnalyticsCategoryQuery,
|
|
19
|
-
} from '../types/interface/api/requests/category.request';
|
|
20
|
-
|
|
21
|
-
export const listCategory = async (): Promise<IListCategoryResponse> => {
|
|
22
|
-
return (await AbyssBankingCore.axios.get<IListCategoryResponse>(`category/list`)).data;
|
|
23
|
-
};
|
|
24
|
-
|
|
25
|
-
export const listAnalyticsCategory = async (
|
|
26
|
-
query: IListAnalyticsCategoryQuery,
|
|
27
|
-
): Promise<IListAnalyticsCategoryResponse> => {
|
|
28
|
-
return (
|
|
29
|
-
await AbyssBankingCore.axios.get<IListAnalyticsCategoryResponse>(`category/list/analytics`, {
|
|
30
|
-
params: query,
|
|
31
|
-
})
|
|
32
|
-
).data;
|
|
33
|
-
};
|
|
34
|
-
|
|
35
|
-
export const removeCategory = async (
|
|
36
|
-
params: IRemoveCategoryParams,
|
|
37
|
-
): Promise<IRemoveCategoryResponse> => {
|
|
38
|
-
return (
|
|
39
|
-
await AbyssBankingCore.axios.delete<IRemoveCategoryResponse>(
|
|
40
|
-
`category/transaction/${params.transactionCategoryId}`,
|
|
41
|
-
)
|
|
42
|
-
).data;
|
|
43
|
-
};
|
|
44
|
-
|
|
45
|
-
export const addCategory = async (params: IAddCategoryParams): Promise<IAddCategoryResponse> => {
|
|
46
|
-
return (
|
|
47
|
-
await AbyssBankingCore.axios.post<IAddCategoryResponse>(
|
|
48
|
-
`category/${params.categoryId}/transaction/${params.accountTransactionId}`,
|
|
49
|
-
)
|
|
50
|
-
).data;
|
|
51
|
-
};
|
|
52
|
-
|
|
53
|
-
export const deleteCategory = async (
|
|
54
|
-
params: IDeleteCategoryParams,
|
|
55
|
-
): Promise<IDeleteCategoryResponse> => {
|
|
56
|
-
return (
|
|
57
|
-
await AbyssBankingCore.axios.delete<IDeleteCategoryResponse>(`category/${params.categoryId}`)
|
|
58
|
-
).data;
|
|
59
|
-
};
|
|
60
|
-
|
|
61
|
-
export const createCategory = async (
|
|
62
|
-
body: ICreateCategoryBody,
|
|
63
|
-
): Promise<ICreateCategoryResponse> => {
|
|
64
|
-
return (await AbyssBankingCore.axios.post<ICreateCategoryResponse>(`category`, body)).data;
|
|
65
|
-
};
|
|
66
|
-
|
|
67
|
-
export const updateCategory = async (
|
|
68
|
-
params: IUpdateCategoryParams,
|
|
69
|
-
body: IUpdateCategoryBody,
|
|
70
|
-
): Promise<IUpdateCategoryResponse> => {
|
|
71
|
-
return (
|
|
72
|
-
await AbyssBankingCore.axios.put<IUpdateCategoryResponse>(`category/${params.categoryId}`, body)
|
|
73
|
-
).data;
|
|
74
|
-
};
|
package/src/api/index.ts
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
export * from './abyss.admin.api';
|
|
2
|
-
export * from './user.admin.api';
|
|
3
|
-
export * from './user.api';
|
|
4
|
-
export * from './monitor.api';
|
|
5
|
-
export * from './banking.admin.api';
|
|
6
|
-
export * from './banking.api';
|
|
7
|
-
export * from './category.admin.api';
|
|
8
|
-
export * from './category.api';
|
|
9
|
-
export * from './categorization-rule.admin.api';
|
|
10
|
-
export * from './categorization-rule.api';
|
|
11
|
-
export * from './panel.api';
|
|
12
|
-
export * from './panel.admin.api';
|
package/src/api/monitor.api.ts
DELETED