@incomy/platform-sdk 0.3.0-alpha.21 → 0.3.0-alpha.24
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/services/core/index.d.ts +4 -0
- package/dist/services/core/index.js +2 -0
- package/dist/services/core/models/LogItem.d.ts +4 -4
- package/dist/services/core/models/LogOperation.d.ts +19 -0
- package/dist/services/core/models/LogOperation.js +1 -0
- package/dist/services/core/models/LogSettlement.d.ts +19 -0
- package/dist/services/core/models/LogSettlement.js +1 -0
- package/dist/services/core/services/OperationsService.d.ts +43 -0
- package/dist/services/core/services/OperationsService.js +92 -0
- package/dist/services/core/services/ProjectWalletsService.d.ts +0 -8
- package/dist/services/core/services/ProjectWalletsService.js +0 -16
- package/dist/services/core/services/ProjectsService.d.ts +0 -8
- package/dist/services/core/services/ProjectsService.js +0 -16
- package/dist/services/core/services/SettlementsService.d.ts +43 -0
- package/dist/services/core/services/SettlementsService.js +92 -0
- package/package.json +1 -1
|
@@ -18,6 +18,8 @@ export type { EntryOperations } from './models/EntryOperations';
|
|
|
18
18
|
export type { EntrySettlements } from './models/EntrySettlements';
|
|
19
19
|
export type { InputFieldDefinition } from './models/InputFieldDefinition';
|
|
20
20
|
export type { LogItem } from './models/LogItem';
|
|
21
|
+
export type { LogOperation } from './models/LogOperation';
|
|
22
|
+
export type { LogSettlement } from './models/LogSettlement';
|
|
21
23
|
export type { Member } from './models/Member';
|
|
22
24
|
export type { MemberBalanceReport } from './models/MemberBalanceReport';
|
|
23
25
|
export type { MemberEdit } from './models/MemberEdit';
|
|
@@ -51,6 +53,8 @@ export type { TemplateSettlementDefinition } from './models/TemplateSettlementDe
|
|
|
51
53
|
export type { WalletBalance } from './models/WalletBalance';
|
|
52
54
|
export { BucketsService } from './services/BucketsService';
|
|
53
55
|
export { EntriesService } from './services/EntriesService';
|
|
56
|
+
export { OperationsService } from './services/OperationsService';
|
|
54
57
|
export { ProjectsService } from './services/ProjectsService';
|
|
55
58
|
export { ProjectWalletsService } from './services/ProjectWalletsService';
|
|
59
|
+
export { SettlementsService } from './services/SettlementsService';
|
|
56
60
|
export { TemplatesService } from './services/TemplatesService';
|
|
@@ -7,6 +7,8 @@ export { CancelablePromise, CancelError } from './core/CancelablePromise';
|
|
|
7
7
|
export { OpenAPI } from './core/OpenAPI';
|
|
8
8
|
export { BucketsService } from './services/BucketsService';
|
|
9
9
|
export { EntriesService } from './services/EntriesService';
|
|
10
|
+
export { OperationsService } from './services/OperationsService';
|
|
10
11
|
export { ProjectsService } from './services/ProjectsService';
|
|
11
12
|
export { ProjectWalletsService } from './services/ProjectWalletsService';
|
|
13
|
+
export { SettlementsService } from './services/SettlementsService';
|
|
12
14
|
export { TemplatesService } from './services/TemplatesService';
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import type { Entry } from './Entry';
|
|
2
|
-
import type {
|
|
3
|
-
import type {
|
|
2
|
+
import type { LogOperation } from './LogOperation';
|
|
3
|
+
import type { LogSettlement } from './LogSettlement';
|
|
4
4
|
export type LogItem = {
|
|
5
5
|
type?: 'OPERATION' | 'SETTLEMENT' | 'ENTRY';
|
|
6
|
-
operation?:
|
|
7
|
-
settlement?:
|
|
6
|
+
operation?: LogOperation;
|
|
7
|
+
settlement?: LogSettlement;
|
|
8
8
|
entry?: Entry;
|
|
9
9
|
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { BalanceReport } from './BalanceReport';
|
|
2
|
+
import type { BucketBreakdown } from './BucketBreakdown';
|
|
3
|
+
import type { Money } from './Money';
|
|
4
|
+
export type LogOperation = {
|
|
5
|
+
id: string;
|
|
6
|
+
name: string;
|
|
7
|
+
time: string;
|
|
8
|
+
originWalletId?: string | null;
|
|
9
|
+
targetWalletId?: string | null;
|
|
10
|
+
type: 'in' | 'out' | 'transfer';
|
|
11
|
+
money: Money;
|
|
12
|
+
bucketBreakdown?: Array<BucketBreakdown> | null;
|
|
13
|
+
entryId?: string | null;
|
|
14
|
+
/**
|
|
15
|
+
* If set, operation will be deleted when unlined from an entry or when linked entry is deleted.
|
|
16
|
+
*/
|
|
17
|
+
deleteWithEntryRemoval?: boolean;
|
|
18
|
+
balance?: BalanceReport;
|
|
19
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { BalanceReport } from './BalanceReport';
|
|
2
|
+
import type { BucketBreakdown } from './BucketBreakdown';
|
|
3
|
+
import type { Money } from './Money';
|
|
4
|
+
export type LogSettlement = {
|
|
5
|
+
id: string;
|
|
6
|
+
name: string;
|
|
7
|
+
description?: string | null;
|
|
8
|
+
memberId: string;
|
|
9
|
+
money: Money;
|
|
10
|
+
bucketBreakdown: Array<BucketBreakdown>;
|
|
11
|
+
compensation: boolean;
|
|
12
|
+
occurredAt: string;
|
|
13
|
+
entryId?: string | null;
|
|
14
|
+
/**
|
|
15
|
+
* If set, settlement will be deleted when unlined from an entry or when linked entry is deleted.
|
|
16
|
+
*/
|
|
17
|
+
deleteWithEntryRemoval?: boolean;
|
|
18
|
+
balance?: BalanceReport;
|
|
19
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import type { Operation } from '../models/Operation';
|
|
2
|
+
import type { OperationEdit } from '../models/OperationEdit';
|
|
3
|
+
import type { OperationInsert } from '../models/OperationInsert';
|
|
4
|
+
import type { CancelablePromise } from '../core/CancelablePromise';
|
|
5
|
+
export declare class OperationsService {
|
|
6
|
+
/**
|
|
7
|
+
* @param projectId
|
|
8
|
+
* @param walletId
|
|
9
|
+
* @param standaloneOnly
|
|
10
|
+
* @returns Operation OK
|
|
11
|
+
* @throws ApiError
|
|
12
|
+
*/
|
|
13
|
+
static getProjectsOperations(projectId: string, walletId?: string, standaloneOnly?: boolean): CancelablePromise<Array<Operation>>;
|
|
14
|
+
/**
|
|
15
|
+
* @param projectId
|
|
16
|
+
* @param requestBody
|
|
17
|
+
* @returns Operation OK
|
|
18
|
+
* @throws ApiError
|
|
19
|
+
*/
|
|
20
|
+
static postProjectsOperations(projectId: string, requestBody?: OperationInsert): CancelablePromise<Operation>;
|
|
21
|
+
/**
|
|
22
|
+
* @param projectId
|
|
23
|
+
* @param operationId
|
|
24
|
+
* @returns Operation OK
|
|
25
|
+
* @throws ApiError
|
|
26
|
+
*/
|
|
27
|
+
static getProjectsOperations1(projectId: string, operationId: string): CancelablePromise<Operation>;
|
|
28
|
+
/**
|
|
29
|
+
* @param projectId
|
|
30
|
+
* @param operationId
|
|
31
|
+
* @param requestBody
|
|
32
|
+
* @returns Operation OK
|
|
33
|
+
* @throws ApiError
|
|
34
|
+
*/
|
|
35
|
+
static patchProjectsOperations(projectId: string, operationId: string, requestBody?: OperationEdit): CancelablePromise<Operation>;
|
|
36
|
+
/**
|
|
37
|
+
* @param projectId
|
|
38
|
+
* @param operationId
|
|
39
|
+
* @returns any OK
|
|
40
|
+
* @throws ApiError
|
|
41
|
+
*/
|
|
42
|
+
static deleteProjectsOperations(projectId: string, operationId: string): CancelablePromise<any>;
|
|
43
|
+
}
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import { OpenAPI } from '../core/OpenAPI';
|
|
2
|
+
import { request as __request } from '../core/request';
|
|
3
|
+
export class OperationsService {
|
|
4
|
+
/**
|
|
5
|
+
* @param projectId
|
|
6
|
+
* @param walletId
|
|
7
|
+
* @param standaloneOnly
|
|
8
|
+
* @returns Operation OK
|
|
9
|
+
* @throws ApiError
|
|
10
|
+
*/
|
|
11
|
+
static getProjectsOperations(projectId, walletId, standaloneOnly = false) {
|
|
12
|
+
return __request(OpenAPI, {
|
|
13
|
+
method: 'GET',
|
|
14
|
+
url: '/projects/{projectId}/operations',
|
|
15
|
+
path: {
|
|
16
|
+
'projectId': projectId,
|
|
17
|
+
},
|
|
18
|
+
query: {
|
|
19
|
+
'walletId': walletId,
|
|
20
|
+
'standaloneOnly': standaloneOnly,
|
|
21
|
+
},
|
|
22
|
+
});
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* @param projectId
|
|
26
|
+
* @param requestBody
|
|
27
|
+
* @returns Operation OK
|
|
28
|
+
* @throws ApiError
|
|
29
|
+
*/
|
|
30
|
+
static postProjectsOperations(projectId, requestBody) {
|
|
31
|
+
return __request(OpenAPI, {
|
|
32
|
+
method: 'POST',
|
|
33
|
+
url: '/projects/{projectId}/operations',
|
|
34
|
+
path: {
|
|
35
|
+
'projectId': projectId,
|
|
36
|
+
},
|
|
37
|
+
body: requestBody,
|
|
38
|
+
mediaType: 'application/json;odata.metadata=minimal;odata.streaming=true',
|
|
39
|
+
});
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* @param projectId
|
|
43
|
+
* @param operationId
|
|
44
|
+
* @returns Operation OK
|
|
45
|
+
* @throws ApiError
|
|
46
|
+
*/
|
|
47
|
+
static getProjectsOperations1(projectId, operationId) {
|
|
48
|
+
return __request(OpenAPI, {
|
|
49
|
+
method: 'GET',
|
|
50
|
+
url: '/projects/{projectId}/operations/{operationId}',
|
|
51
|
+
path: {
|
|
52
|
+
'projectId': projectId,
|
|
53
|
+
'operationId': operationId,
|
|
54
|
+
},
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* @param projectId
|
|
59
|
+
* @param operationId
|
|
60
|
+
* @param requestBody
|
|
61
|
+
* @returns Operation OK
|
|
62
|
+
* @throws ApiError
|
|
63
|
+
*/
|
|
64
|
+
static patchProjectsOperations(projectId, operationId, requestBody) {
|
|
65
|
+
return __request(OpenAPI, {
|
|
66
|
+
method: 'PATCH',
|
|
67
|
+
url: '/projects/{projectId}/operations/{operationId}',
|
|
68
|
+
path: {
|
|
69
|
+
'projectId': projectId,
|
|
70
|
+
'operationId': operationId,
|
|
71
|
+
},
|
|
72
|
+
body: requestBody,
|
|
73
|
+
mediaType: 'application/json;odata.metadata=minimal;odata.streaming=true',
|
|
74
|
+
});
|
|
75
|
+
}
|
|
76
|
+
/**
|
|
77
|
+
* @param projectId
|
|
78
|
+
* @param operationId
|
|
79
|
+
* @returns any OK
|
|
80
|
+
* @throws ApiError
|
|
81
|
+
*/
|
|
82
|
+
static deleteProjectsOperations(projectId, operationId) {
|
|
83
|
+
return __request(OpenAPI, {
|
|
84
|
+
method: 'DELETE',
|
|
85
|
+
url: '/projects/{projectId}/operations/{operationId}',
|
|
86
|
+
path: {
|
|
87
|
+
'projectId': projectId,
|
|
88
|
+
'operationId': operationId,
|
|
89
|
+
},
|
|
90
|
+
});
|
|
91
|
+
}
|
|
92
|
+
}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import type { Balance } from '../models/Balance';
|
|
2
|
-
import type { Operation } from '../models/Operation';
|
|
3
2
|
import type { ProjectWallet } from '../models/ProjectWallet';
|
|
4
3
|
import type { ProjectWalletEdit } from '../models/ProjectWalletEdit';
|
|
5
4
|
import type { ProjectWalletInsert } from '../models/ProjectWalletInsert';
|
|
@@ -47,11 +46,4 @@ export declare class ProjectWalletsService {
|
|
|
47
46
|
* @throws ApiError
|
|
48
47
|
*/
|
|
49
48
|
static getProjectsWalletsBalance(projectId: string, walletId: string): CancelablePromise<Balance>;
|
|
50
|
-
/**
|
|
51
|
-
* @param projectId
|
|
52
|
-
* @param walletId
|
|
53
|
-
* @returns Operation OK
|
|
54
|
-
* @throws ApiError
|
|
55
|
-
*/
|
|
56
|
-
static getProjectsWalletsOperations(projectId: string, walletId: string): CancelablePromise<Array<Operation>>;
|
|
57
49
|
}
|
|
@@ -99,20 +99,4 @@ export class ProjectWalletsService {
|
|
|
99
99
|
},
|
|
100
100
|
});
|
|
101
101
|
}
|
|
102
|
-
/**
|
|
103
|
-
* @param projectId
|
|
104
|
-
* @param walletId
|
|
105
|
-
* @returns Operation OK
|
|
106
|
-
* @throws ApiError
|
|
107
|
-
*/
|
|
108
|
-
static getProjectsWalletsOperations(projectId, walletId) {
|
|
109
|
-
return __request(OpenAPI, {
|
|
110
|
-
method: 'GET',
|
|
111
|
-
url: '/projects/{projectId}/wallets/{walletId}/operations',
|
|
112
|
-
path: {
|
|
113
|
-
'projectId': projectId,
|
|
114
|
-
'walletId': walletId,
|
|
115
|
-
},
|
|
116
|
-
});
|
|
117
|
-
}
|
|
118
102
|
}
|
|
@@ -7,7 +7,6 @@ import type { MemberInsert } from '../models/MemberInsert';
|
|
|
7
7
|
import type { Project } from '../models/Project';
|
|
8
8
|
import type { ProjectEdit } from '../models/ProjectEdit';
|
|
9
9
|
import type { ProjectInsert } from '../models/ProjectInsert';
|
|
10
|
-
import type { Settlement } from '../models/Settlement';
|
|
11
10
|
import type { CancelablePromise } from '../core/CancelablePromise';
|
|
12
11
|
export declare class ProjectsService {
|
|
13
12
|
/**
|
|
@@ -94,11 +93,4 @@ export declare class ProjectsService {
|
|
|
94
93
|
* @throws ApiError
|
|
95
94
|
*/
|
|
96
95
|
static getProjectsMembersBalance(projectId: string, memberId: string): CancelablePromise<MemberBalanceReport>;
|
|
97
|
-
/**
|
|
98
|
-
* @param projectId
|
|
99
|
-
* @param memberId
|
|
100
|
-
* @returns Settlement OK
|
|
101
|
-
* @throws ApiError
|
|
102
|
-
*/
|
|
103
|
-
static getProjectsMembersSettlements(projectId: string, memberId: string): CancelablePromise<Array<Settlement>>;
|
|
104
96
|
}
|
|
@@ -195,20 +195,4 @@ export class ProjectsService {
|
|
|
195
195
|
},
|
|
196
196
|
});
|
|
197
197
|
}
|
|
198
|
-
/**
|
|
199
|
-
* @param projectId
|
|
200
|
-
* @param memberId
|
|
201
|
-
* @returns Settlement OK
|
|
202
|
-
* @throws ApiError
|
|
203
|
-
*/
|
|
204
|
-
static getProjectsMembersSettlements(projectId, memberId) {
|
|
205
|
-
return __request(OpenAPI, {
|
|
206
|
-
method: 'GET',
|
|
207
|
-
url: '/projects/{projectId}/members/{memberId}/settlements',
|
|
208
|
-
path: {
|
|
209
|
-
'projectId': projectId,
|
|
210
|
-
'memberId': memberId,
|
|
211
|
-
},
|
|
212
|
-
});
|
|
213
|
-
}
|
|
214
198
|
}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import type { Settlement } from '../models/Settlement';
|
|
2
|
+
import type { SettlementEdit } from '../models/SettlementEdit';
|
|
3
|
+
import type { SettlementInsert } from '../models/SettlementInsert';
|
|
4
|
+
import type { CancelablePromise } from '../core/CancelablePromise';
|
|
5
|
+
export declare class SettlementsService {
|
|
6
|
+
/**
|
|
7
|
+
* @param projectId
|
|
8
|
+
* @param memberId
|
|
9
|
+
* @param standaloneOnly
|
|
10
|
+
* @returns Settlement OK
|
|
11
|
+
* @throws ApiError
|
|
12
|
+
*/
|
|
13
|
+
static getProjectsSettlements(projectId: string, memberId?: string, standaloneOnly?: boolean): CancelablePromise<Array<Settlement>>;
|
|
14
|
+
/**
|
|
15
|
+
* @param projectId
|
|
16
|
+
* @param requestBody
|
|
17
|
+
* @returns Settlement OK
|
|
18
|
+
* @throws ApiError
|
|
19
|
+
*/
|
|
20
|
+
static postProjectsSettlements(projectId: string, requestBody?: SettlementInsert): CancelablePromise<Settlement>;
|
|
21
|
+
/**
|
|
22
|
+
* @param projectId
|
|
23
|
+
* @param settlementId
|
|
24
|
+
* @returns Settlement OK
|
|
25
|
+
* @throws ApiError
|
|
26
|
+
*/
|
|
27
|
+
static getProjectsSettlements1(projectId: string, settlementId: string): CancelablePromise<Settlement>;
|
|
28
|
+
/**
|
|
29
|
+
* @param projectId
|
|
30
|
+
* @param settlementId
|
|
31
|
+
* @param requestBody
|
|
32
|
+
* @returns Settlement OK
|
|
33
|
+
* @throws ApiError
|
|
34
|
+
*/
|
|
35
|
+
static patchProjectsSettlements(projectId: string, settlementId: string, requestBody?: SettlementEdit): CancelablePromise<Settlement>;
|
|
36
|
+
/**
|
|
37
|
+
* @param projectId
|
|
38
|
+
* @param settlementId
|
|
39
|
+
* @returns any OK
|
|
40
|
+
* @throws ApiError
|
|
41
|
+
*/
|
|
42
|
+
static deleteProjectsSettlements(projectId: string, settlementId: string): CancelablePromise<any>;
|
|
43
|
+
}
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import { OpenAPI } from '../core/OpenAPI';
|
|
2
|
+
import { request as __request } from '../core/request';
|
|
3
|
+
export class SettlementsService {
|
|
4
|
+
/**
|
|
5
|
+
* @param projectId
|
|
6
|
+
* @param memberId
|
|
7
|
+
* @param standaloneOnly
|
|
8
|
+
* @returns Settlement OK
|
|
9
|
+
* @throws ApiError
|
|
10
|
+
*/
|
|
11
|
+
static getProjectsSettlements(projectId, memberId, standaloneOnly = false) {
|
|
12
|
+
return __request(OpenAPI, {
|
|
13
|
+
method: 'GET',
|
|
14
|
+
url: '/projects/{projectId}/settlements',
|
|
15
|
+
path: {
|
|
16
|
+
'projectId': projectId,
|
|
17
|
+
},
|
|
18
|
+
query: {
|
|
19
|
+
'memberId': memberId,
|
|
20
|
+
'standaloneOnly': standaloneOnly,
|
|
21
|
+
},
|
|
22
|
+
});
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* @param projectId
|
|
26
|
+
* @param requestBody
|
|
27
|
+
* @returns Settlement OK
|
|
28
|
+
* @throws ApiError
|
|
29
|
+
*/
|
|
30
|
+
static postProjectsSettlements(projectId, requestBody) {
|
|
31
|
+
return __request(OpenAPI, {
|
|
32
|
+
method: 'POST',
|
|
33
|
+
url: '/projects/{projectId}/settlements',
|
|
34
|
+
path: {
|
|
35
|
+
'projectId': projectId,
|
|
36
|
+
},
|
|
37
|
+
body: requestBody,
|
|
38
|
+
mediaType: 'application/json;odata.metadata=minimal;odata.streaming=true',
|
|
39
|
+
});
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* @param projectId
|
|
43
|
+
* @param settlementId
|
|
44
|
+
* @returns Settlement OK
|
|
45
|
+
* @throws ApiError
|
|
46
|
+
*/
|
|
47
|
+
static getProjectsSettlements1(projectId, settlementId) {
|
|
48
|
+
return __request(OpenAPI, {
|
|
49
|
+
method: 'GET',
|
|
50
|
+
url: '/projects/{projectId}/settlements/{settlementId}',
|
|
51
|
+
path: {
|
|
52
|
+
'projectId': projectId,
|
|
53
|
+
'settlementId': settlementId,
|
|
54
|
+
},
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* @param projectId
|
|
59
|
+
* @param settlementId
|
|
60
|
+
* @param requestBody
|
|
61
|
+
* @returns Settlement OK
|
|
62
|
+
* @throws ApiError
|
|
63
|
+
*/
|
|
64
|
+
static patchProjectsSettlements(projectId, settlementId, requestBody) {
|
|
65
|
+
return __request(OpenAPI, {
|
|
66
|
+
method: 'PATCH',
|
|
67
|
+
url: '/projects/{projectId}/settlements/{settlementId}',
|
|
68
|
+
path: {
|
|
69
|
+
'projectId': projectId,
|
|
70
|
+
'settlementId': settlementId,
|
|
71
|
+
},
|
|
72
|
+
body: requestBody,
|
|
73
|
+
mediaType: 'application/json;odata.metadata=minimal;odata.streaming=true',
|
|
74
|
+
});
|
|
75
|
+
}
|
|
76
|
+
/**
|
|
77
|
+
* @param projectId
|
|
78
|
+
* @param settlementId
|
|
79
|
+
* @returns any OK
|
|
80
|
+
* @throws ApiError
|
|
81
|
+
*/
|
|
82
|
+
static deleteProjectsSettlements(projectId, settlementId) {
|
|
83
|
+
return __request(OpenAPI, {
|
|
84
|
+
method: 'DELETE',
|
|
85
|
+
url: '/projects/{projectId}/settlements/{settlementId}',
|
|
86
|
+
path: {
|
|
87
|
+
'projectId': projectId,
|
|
88
|
+
'settlementId': settlementId,
|
|
89
|
+
},
|
|
90
|
+
});
|
|
91
|
+
}
|
|
92
|
+
}
|