@incomy/platform-sdk 0.6.0 → 0.6.1-beta.2501

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.
Files changed (60) hide show
  1. package/dist/services/hub/index.d.ts +9 -0
  2. package/dist/services/hub/index.js +2 -0
  3. package/dist/services/hub/models/Accrual.d.ts +12 -0
  4. package/dist/services/hub/models/AccrualEdit.d.ts +6 -0
  5. package/dist/services/hub/models/AccrualInsert.d.ts +12 -0
  6. package/dist/services/hub/models/AppliedTemplate.d.ts +19 -0
  7. package/dist/services/hub/models/AppliedTemplate.js +1 -0
  8. package/dist/services/hub/models/BalanceTimeline.d.ts +17 -0
  9. package/dist/services/hub/models/BalanceTimeline.js +1 -0
  10. package/dist/services/hub/models/BalanceTimelinePoint.d.ts +19 -0
  11. package/dist/services/hub/models/BalanceTimelinePoint.js +1 -0
  12. package/dist/services/hub/models/Document.d.ts +30 -0
  13. package/dist/services/hub/models/Document.js +1 -0
  14. package/dist/services/hub/models/DocumentLinkRequest.d.ts +7 -0
  15. package/dist/services/hub/models/DocumentLinkRequest.js +1 -0
  16. package/dist/services/hub/models/DocumentUploadRequest.d.ts +8 -0
  17. package/dist/services/hub/models/DocumentUploadRequest.js +1 -0
  18. package/dist/services/hub/models/DocumentUploadTicket.d.ts +22 -0
  19. package/dist/services/hub/models/DocumentUploadTicket.js +1 -0
  20. package/dist/services/hub/models/LogAccrual.d.ts +12 -0
  21. package/dist/services/hub/models/LogOperation.d.ts +12 -0
  22. package/dist/services/hub/models/Operation.d.ts +12 -0
  23. package/dist/services/hub/models/OperationEdit.d.ts +6 -0
  24. package/dist/services/hub/models/OperationInsert.d.ts +12 -0
  25. package/dist/services/hub/models/TemplateDefinition.d.ts +7 -1
  26. package/dist/services/hub/models/TrashItem.d.ts +1 -1
  27. package/dist/services/hub/services/AccrualsService.d.ts +27 -22
  28. package/dist/services/hub/services/AccrualsService.js +5 -22
  29. package/dist/services/hub/services/AuthService.d.ts +12 -8
  30. package/dist/services/hub/services/AuthService.js +4 -8
  31. package/dist/services/hub/services/BucketsService.d.ts +24 -19
  32. package/dist/services/hub/services/BucketsService.js +5 -19
  33. package/dist/services/hub/services/CompaniesService.d.ts +24 -19
  34. package/dist/services/hub/services/CompaniesService.js +5 -19
  35. package/dist/services/hub/services/DeletedProjectsService.d.ts +10 -7
  36. package/dist/services/hub/services/DeletedProjectsService.js +3 -7
  37. package/dist/services/hub/services/LabelsService.d.ts +24 -19
  38. package/dist/services/hub/services/LabelsService.js +5 -19
  39. package/dist/services/hub/services/MembersService.d.ts +37 -25
  40. package/dist/services/hub/services/MembersService.js +12 -25
  41. package/dist/services/hub/services/MockStorageService.d.ts +17 -0
  42. package/dist/services/hub/services/MockStorageService.js +30 -0
  43. package/dist/services/hub/services/MultiEventsService.d.ts +28 -23
  44. package/dist/services/hub/services/MultiEventsService.js +5 -23
  45. package/dist/services/hub/services/OperationsService.d.ts +32 -27
  46. package/dist/services/hub/services/OperationsService.js +5 -27
  47. package/dist/services/hub/services/ProjectDocumentsService.d.ts +71 -0
  48. package/dist/services/hub/services/ProjectDocumentsService.js +116 -0
  49. package/dist/services/hub/services/ProjectWalletsService.d.ts +37 -25
  50. package/dist/services/hub/services/ProjectWalletsService.js +12 -25
  51. package/dist/services/hub/services/ProjectsService.d.ts +83 -43
  52. package/dist/services/hub/services/ProjectsService.js +49 -43
  53. package/dist/services/hub/services/TemplatesService.d.ts +37 -19
  54. package/dist/services/hub/services/TemplatesService.js +23 -19
  55. package/dist/services/hub/services/TrashService.d.ts +24 -17
  56. package/dist/services/hub/services/TrashService.js +4 -17
  57. package/dist/services/hub/services/UserSettingsService.d.ts +3 -2
  58. package/dist/services/hub/services/UserSettingsService.js +1 -2
  59. package/meta.json +5 -5
  60. package/package.json +1 -1
@@ -0,0 +1,116 @@
1
+ import { OpenAPI } from '../core/OpenAPI';
2
+ import { request as __request } from '../core/request';
3
+ export class ProjectDocumentsService {
4
+ /**
5
+ * Documents attached to an event — supply exactly one of `operationId`/`accrualId`.
6
+ * @returns Document OK
7
+ * @throws ApiError
8
+ */
9
+ static getProjectsDocuments({ projectId, operationId, accrualId, }) {
10
+ return __request(OpenAPI, {
11
+ method: 'GET',
12
+ url: '/projects/{projectId}/documents',
13
+ path: {
14
+ 'projectId': projectId,
15
+ },
16
+ query: {
17
+ 'operationId': operationId,
18
+ 'accrualId': accrualId,
19
+ },
20
+ });
21
+ }
22
+ /**
23
+ * @returns DocumentUploadTicket OK
24
+ * @throws ApiError
25
+ */
26
+ static postProjectsDocuments({ projectId, requestBody, }) {
27
+ return __request(OpenAPI, {
28
+ method: 'POST',
29
+ url: '/projects/{projectId}/documents',
30
+ path: {
31
+ 'projectId': projectId,
32
+ },
33
+ body: requestBody,
34
+ mediaType: 'application/json',
35
+ });
36
+ }
37
+ /**
38
+ * Delete the whole document (from every event). Unlinked/Pending → hard-delete; linked, Ready → Trash.
39
+ * @returns any OK
40
+ * @throws ApiError
41
+ */
42
+ static deleteProjectsDocuments({ projectId, documentId, }) {
43
+ return __request(OpenAPI, {
44
+ method: 'DELETE',
45
+ url: '/projects/{projectId}/documents/{documentId}',
46
+ path: {
47
+ 'projectId': projectId,
48
+ 'documentId': documentId,
49
+ },
50
+ });
51
+ }
52
+ /**
53
+ * @returns Document OK
54
+ * @throws ApiError
55
+ */
56
+ static getProjectsDocuments1({ projectId, documentId, }) {
57
+ return __request(OpenAPI, {
58
+ method: 'GET',
59
+ url: '/projects/{projectId}/documents/{documentId}',
60
+ path: {
61
+ 'projectId': projectId,
62
+ 'documentId': documentId,
63
+ },
64
+ });
65
+ }
66
+ /**
67
+ * @returns Document OK
68
+ * @throws ApiError
69
+ */
70
+ static postProjectsDocumentsComplete({ projectId, documentId, }) {
71
+ return __request(OpenAPI, {
72
+ method: 'POST',
73
+ url: '/projects/{projectId}/documents/{documentId}/complete',
74
+ path: {
75
+ 'projectId': projectId,
76
+ 'documentId': documentId,
77
+ },
78
+ });
79
+ }
80
+ /**
81
+ * Detach a document from one event — supply exactly one of `operationId`/`accrualId`.
82
+ * @returns any OK
83
+ * @throws ApiError
84
+ */
85
+ static deleteProjectsDocumentsLinks({ projectId, documentId, operationId, accrualId, }) {
86
+ return __request(OpenAPI, {
87
+ method: 'DELETE',
88
+ url: '/projects/{projectId}/documents/{documentId}/links',
89
+ path: {
90
+ 'projectId': projectId,
91
+ 'documentId': documentId,
92
+ },
93
+ query: {
94
+ 'operationId': operationId,
95
+ 'accrualId': accrualId,
96
+ },
97
+ });
98
+ }
99
+ /**
100
+ * Attach a document to an event (many-to-many) — the body sets exactly one of the two event ids.
101
+ * @returns any OK
102
+ * @throws ApiError
103
+ */
104
+ static postProjectsDocumentsLinks({ projectId, documentId, requestBody, }) {
105
+ return __request(OpenAPI, {
106
+ method: 'POST',
107
+ url: '/projects/{projectId}/documents/{documentId}/links',
108
+ path: {
109
+ 'projectId': projectId,
110
+ 'documentId': documentId,
111
+ },
112
+ body: requestBody,
113
+ mediaType: 'application/json',
114
+ });
115
+ }
116
+ }
@@ -6,52 +6,64 @@ import type { ProjectWalletPaginatedList } from '../models/ProjectWalletPaginate
6
6
  import type { CancelablePromise } from '../core/CancelablePromise';
7
7
  export declare class ProjectWalletsService {
8
8
  /**
9
- * @param projectId
10
- * @param query
11
- * @param orderByName
12
- * @param limit
13
- * @param next
14
- * @param includeBalance
15
- * @param includeDeletability
16
9
  * @returns ProjectWalletPaginatedList OK
17
10
  * @throws ApiError
18
11
  */
19
- static getProjectsWallets(projectId: string, query?: string, orderByName?: 'Desc' | 'Asc', limit?: number, next?: string, includeBalance?: boolean, includeDeletability?: boolean): CancelablePromise<ProjectWalletPaginatedList>;
12
+ static getProjectsWallets({ projectId, query, orderByName, limit, next, includeBalance, includeDeletability, types, walletIds, labelIds, companyIds, from, to, }: {
13
+ projectId: string;
14
+ query?: string;
15
+ orderByName?: 'Desc' | 'Asc';
16
+ limit?: number;
17
+ next?: string;
18
+ includeBalance?: boolean;
19
+ includeDeletability?: boolean;
20
+ types?: Array<'income' | 'outcome' | 'transfer' | 'receivable' | 'settlement' | 'multiEvent'>;
21
+ walletIds?: Array<string>;
22
+ labelIds?: Array<string>;
23
+ companyIds?: Array<string>;
24
+ from?: string;
25
+ to?: string;
26
+ }): CancelablePromise<ProjectWalletPaginatedList>;
20
27
  /**
21
- * @param projectId
22
- * @param requestBody
23
28
  * @returns ProjectWallet OK
24
29
  * @throws ApiError
25
30
  */
26
- static postProjectsWallets(projectId: string, requestBody?: ProjectWalletInsert): CancelablePromise<ProjectWallet>;
31
+ static postProjectsWallets({ projectId, requestBody, }: {
32
+ projectId: string;
33
+ requestBody?: ProjectWalletInsert;
34
+ }): CancelablePromise<ProjectWallet>;
27
35
  /**
28
- * @param projectId
29
- * @param walletId
30
36
  * @returns any OK
31
37
  * @throws ApiError
32
38
  */
33
- static deleteProjectsWallets(projectId: string, walletId: string): CancelablePromise<any>;
39
+ static deleteProjectsWallets({ projectId, walletId, }: {
40
+ projectId: string;
41
+ walletId: string;
42
+ }): CancelablePromise<any>;
34
43
  /**
35
- * @param projectId
36
- * @param walletId
37
- * @param includeDeletability
38
44
  * @returns ProjectWallet OK
39
45
  * @throws ApiError
40
46
  */
41
- static getProjectsWallets1(projectId: string, walletId: string, includeDeletability?: boolean): CancelablePromise<ProjectWallet>;
47
+ static getProjectsWallets1({ projectId, walletId, includeDeletability, }: {
48
+ projectId: string;
49
+ walletId: string;
50
+ includeDeletability?: boolean;
51
+ }): CancelablePromise<ProjectWallet>;
42
52
  /**
43
- * @param projectId
44
- * @param walletId
45
- * @param requestBody
46
53
  * @returns ProjectWallet OK
47
54
  * @throws ApiError
48
55
  */
49
- static patchProjectsWallets(projectId: string, walletId: string, requestBody?: ProjectWalletEdit): CancelablePromise<ProjectWallet>;
56
+ static patchProjectsWallets({ projectId, walletId, requestBody, }: {
57
+ projectId: string;
58
+ walletId: string;
59
+ requestBody?: ProjectWalletEdit;
60
+ }): CancelablePromise<ProjectWallet>;
50
61
  /**
51
- * @param projectId
52
- * @param walletId
53
62
  * @returns Balance OK
54
63
  * @throws ApiError
55
64
  */
56
- static getProjectsWalletsBalance(projectId: string, walletId: string): CancelablePromise<Balance>;
65
+ static getProjectsWalletsBalance({ projectId, walletId, }: {
66
+ projectId: string;
67
+ walletId: string;
68
+ }): CancelablePromise<Balance>;
57
69
  }
@@ -2,17 +2,10 @@ import { OpenAPI } from '../core/OpenAPI';
2
2
  import { request as __request } from '../core/request';
3
3
  export class ProjectWalletsService {
4
4
  /**
5
- * @param projectId
6
- * @param query
7
- * @param orderByName
8
- * @param limit
9
- * @param next
10
- * @param includeBalance
11
- * @param includeDeletability
12
5
  * @returns ProjectWalletPaginatedList OK
13
6
  * @throws ApiError
14
7
  */
15
- static getProjectsWallets(projectId, query, orderByName, limit = 10, next, includeBalance = false, includeDeletability = false) {
8
+ static getProjectsWallets({ projectId, query, orderByName, limit = 10, next, includeBalance = false, includeDeletability = false, types, walletIds, labelIds, companyIds, from, to, }) {
16
9
  return __request(OpenAPI, {
17
10
  method: 'GET',
18
11
  url: '/projects/{projectId}/wallets',
@@ -26,16 +19,20 @@ export class ProjectWalletsService {
26
19
  'next': next,
27
20
  'includeBalance': includeBalance,
28
21
  'includeDeletability': includeDeletability,
22
+ 'types': types,
23
+ 'walletIds': walletIds,
24
+ 'labelIds': labelIds,
25
+ 'companyIds': companyIds,
26
+ 'from': from,
27
+ 'to': to,
29
28
  },
30
29
  });
31
30
  }
32
31
  /**
33
- * @param projectId
34
- * @param requestBody
35
32
  * @returns ProjectWallet OK
36
33
  * @throws ApiError
37
34
  */
38
- static postProjectsWallets(projectId, requestBody) {
35
+ static postProjectsWallets({ projectId, requestBody, }) {
39
36
  return __request(OpenAPI, {
40
37
  method: 'POST',
41
38
  url: '/projects/{projectId}/wallets',
@@ -47,12 +44,10 @@ export class ProjectWalletsService {
47
44
  });
48
45
  }
49
46
  /**
50
- * @param projectId
51
- * @param walletId
52
47
  * @returns any OK
53
48
  * @throws ApiError
54
49
  */
55
- static deleteProjectsWallets(projectId, walletId) {
50
+ static deleteProjectsWallets({ projectId, walletId, }) {
56
51
  return __request(OpenAPI, {
57
52
  method: 'DELETE',
58
53
  url: '/projects/{projectId}/wallets/{walletId}',
@@ -63,13 +58,10 @@ export class ProjectWalletsService {
63
58
  });
64
59
  }
65
60
  /**
66
- * @param projectId
67
- * @param walletId
68
- * @param includeDeletability
69
61
  * @returns ProjectWallet OK
70
62
  * @throws ApiError
71
63
  */
72
- static getProjectsWallets1(projectId, walletId, includeDeletability = false) {
64
+ static getProjectsWallets1({ projectId, walletId, includeDeletability = false, }) {
73
65
  return __request(OpenAPI, {
74
66
  method: 'GET',
75
67
  url: '/projects/{projectId}/wallets/{walletId}',
@@ -83,13 +75,10 @@ export class ProjectWalletsService {
83
75
  });
84
76
  }
85
77
  /**
86
- * @param projectId
87
- * @param walletId
88
- * @param requestBody
89
78
  * @returns ProjectWallet OK
90
79
  * @throws ApiError
91
80
  */
92
- static patchProjectsWallets(projectId, walletId, requestBody) {
81
+ static patchProjectsWallets({ projectId, walletId, requestBody, }) {
93
82
  return __request(OpenAPI, {
94
83
  method: 'PATCH',
95
84
  url: '/projects/{projectId}/wallets/{walletId}',
@@ -102,12 +91,10 @@ export class ProjectWalletsService {
102
91
  });
103
92
  }
104
93
  /**
105
- * @param projectId
106
- * @param walletId
107
94
  * @returns Balance OK
108
95
  * @throws ApiError
109
96
  */
110
- static getProjectsWalletsBalance(projectId, walletId) {
97
+ static getProjectsWalletsBalance({ projectId, walletId, }) {
111
98
  return __request(OpenAPI, {
112
99
  method: 'GET',
113
100
  url: '/projects/{projectId}/wallets/{walletId}/balance',
@@ -1,4 +1,5 @@
1
1
  import type { BalanceReport } from '../models/BalanceReport';
2
+ import type { BalanceTimeline } from '../models/BalanceTimeline';
2
3
  import type { LogItemPaginatedList } from '../models/LogItemPaginatedList';
3
4
  import type { MemberBalancePaginatedList } from '../models/MemberBalancePaginatedList';
4
5
  import type { Project } from '../models/Project';
@@ -11,87 +12,126 @@ import type { WalletBalancePaginatedList } from '../models/WalletBalancePaginate
11
12
  import type { CancelablePromise } from '../core/CancelablePromise';
12
13
  export declare class ProjectsService {
13
14
  /**
14
- * @param query
15
- * @param orderByName
16
- * @param limit
17
- * @param next
18
15
  * @returns ProjectPaginatedList OK
19
16
  * @throws ApiError
20
17
  */
21
- static getProjects(query?: string, orderByName?: 'Desc' | 'Asc', limit?: number, next?: string): CancelablePromise<ProjectPaginatedList>;
18
+ static getProjects({ query, orderByName, limit, next, }: {
19
+ query?: string;
20
+ orderByName?: 'Desc' | 'Asc';
21
+ limit?: number;
22
+ next?: string;
23
+ }): CancelablePromise<ProjectPaginatedList>;
22
24
  /**
23
- * @param requestBody
24
25
  * @returns Project OK
25
26
  * @throws ApiError
26
27
  */
27
- static postProjects(requestBody?: ProjectInsert): CancelablePromise<Project>;
28
+ static postProjects({ requestBody, }: {
29
+ requestBody?: ProjectInsert;
30
+ }): CancelablePromise<Project>;
28
31
  /**
29
32
  * Get projects in bulk.
30
- * @param requestBody
31
33
  * @returns ProjectBatchGetResult OK
32
34
  * @throws ApiError
33
35
  */
34
- static batchGetProjects(requestBody: ProjectBatchGet): CancelablePromise<ProjectBatchGetResult>;
36
+ static batchGetProjects({ requestBody, }: {
37
+ requestBody: ProjectBatchGet;
38
+ }): CancelablePromise<ProjectBatchGetResult>;
35
39
  /**
36
- * @param projectId
37
40
  * @returns any OK
38
41
  * @throws ApiError
39
42
  */
40
- static deleteProjects(projectId: string): CancelablePromise<any>;
43
+ static deleteProjects({ projectId, }: {
44
+ projectId: string;
45
+ }): CancelablePromise<any>;
41
46
  /**
42
- * @param projectId
43
47
  * @returns Project OK
44
48
  * @throws ApiError
45
49
  */
46
- static getProjects1(projectId: string): CancelablePromise<Project>;
50
+ static getProjects1({ projectId, }: {
51
+ projectId: string;
52
+ }): CancelablePromise<Project>;
47
53
  /**
48
- * @param projectId
49
- * @param requestBody
50
54
  * @returns Project OK
51
55
  * @throws ApiError
52
56
  */
53
- static patchProjects(projectId: string, requestBody?: ProjectEdit): CancelablePromise<Project>;
57
+ static patchProjects({ projectId, requestBody, }: {
58
+ projectId: string;
59
+ requestBody?: ProjectEdit;
60
+ }): CancelablePromise<Project>;
54
61
  /**
55
- * @param projectId
56
62
  * @returns BalanceReport OK
57
63
  * @throws ApiError
58
64
  */
59
- static getProjectsBalance(projectId: string): CancelablePromise<BalanceReport>;
65
+ static getProjectsBalance({ projectId, query, types, walletIds, labelIds, companyIds, memberIds, from, to, }: {
66
+ projectId: string;
67
+ query?: string;
68
+ types?: Array<'income' | 'outcome' | 'transfer' | 'receivable' | 'settlement' | 'multiEvent'>;
69
+ walletIds?: Array<string>;
70
+ labelIds?: Array<string>;
71
+ companyIds?: Array<string>;
72
+ memberIds?: Array<string>;
73
+ from?: string;
74
+ to?: string;
75
+ }): CancelablePromise<BalanceReport>;
60
76
  /**
61
- * @param projectId
62
- * @param orderByName
63
- * @param orderByAmount
64
- * @param limit
65
- * @param next
66
77
  * @returns MemberBalancePaginatedList OK
67
78
  * @throws ApiError
68
79
  */
69
- static getProjectsBalanceMembers(projectId: string, orderByName?: 'Desc' | 'Asc', orderByAmount?: 'Desc' | 'Asc', limit?: number, next?: string): CancelablePromise<MemberBalancePaginatedList>;
80
+ static getProjectsBalanceMembers({ projectId, orderByName, orderByAmount, limit, next, }: {
81
+ projectId: string;
82
+ orderByName?: 'Desc' | 'Asc';
83
+ orderByAmount?: 'Desc' | 'Asc';
84
+ limit?: number;
85
+ next?: string;
86
+ }): CancelablePromise<MemberBalancePaginatedList>;
87
+ /**
88
+ * Balance-over-time series for the project: an actual (wallet-state) line up to now and an effective line that
89
+ * combines accruals and may extend into the future as a prediction. Filters mirror the log feed: a wallet
90
+ * filter scopes operations (actual line), a member filter scopes accruals (effective line), and label/company
91
+ * narrow both. With no `from`, the series starts at the project's first recorded event; `to` defaults
92
+ * to now; the default interval is daily.
93
+ * @returns BalanceTimeline OK
94
+ * @throws ApiError
95
+ */
96
+ static getProjectsBalanceTimeline({ projectId, from, to, interval, walletIds, labelIds, companyIds, memberIds, }: {
97
+ projectId: string;
98
+ from?: string;
99
+ to?: string;
100
+ interval?: 'day' | 'week' | 'month';
101
+ walletIds?: Array<string>;
102
+ labelIds?: Array<string>;
103
+ companyIds?: Array<string>;
104
+ memberIds?: Array<string>;
105
+ }): CancelablePromise<BalanceTimeline>;
70
106
  /**
71
- * @param projectId
72
- * @param orderByName
73
- * @param orderByAmount
74
- * @param limit
75
- * @param next
76
107
  * @returns WalletBalancePaginatedList OK
77
108
  * @throws ApiError
78
109
  */
79
- static getProjectsBalanceWallets(projectId: string, orderByName?: 'Desc' | 'Asc', orderByAmount?: 'Desc' | 'Asc', limit?: number, next?: string): CancelablePromise<WalletBalancePaginatedList>;
110
+ static getProjectsBalanceWallets({ projectId, orderByName, orderByAmount, limit, next, }: {
111
+ projectId: string;
112
+ orderByName?: 'Desc' | 'Asc';
113
+ orderByAmount?: 'Desc' | 'Asc';
114
+ limit?: number;
115
+ next?: string;
116
+ }): CancelablePromise<WalletBalancePaginatedList>;
80
117
  /**
81
- * @param projectId
82
- * @param query
83
- * @param types
84
- * @param walletIds
85
- * @param labelIds
86
- * @param companyIds
87
- * @param from
88
- * @param to
89
- * @param orderByName
90
- * @param orderByTime
91
- * @param limit
92
- * @param next
93
118
  * @returns LogItemPaginatedList OK
94
119
  * @throws ApiError
95
120
  */
96
- static getProjectsLog(projectId: string, query?: string, types?: Array<'income' | 'outcome' | 'transfer' | 'receivable' | 'settlement' | 'multiEvent'>, walletIds?: Array<string>, labelIds?: Array<string>, companyIds?: Array<string>, from?: string, to?: string, orderByName?: 'Desc' | 'Asc', orderByTime?: 'Desc' | 'Asc', limit?: number, next?: string): CancelablePromise<LogItemPaginatedList>;
121
+ static getProjectsLog({ projectId, query, types, walletIds, labelIds, companyIds, memberIds, from, to, orderByName, orderByTime, grouped, limit, next, }: {
122
+ projectId: string;
123
+ query?: string;
124
+ types?: Array<'income' | 'outcome' | 'transfer' | 'receivable' | 'settlement' | 'multiEvent'>;
125
+ walletIds?: Array<string>;
126
+ labelIds?: Array<string>;
127
+ companyIds?: Array<string>;
128
+ memberIds?: Array<string>;
129
+ from?: string;
130
+ to?: string;
131
+ orderByName?: 'Desc' | 'Asc';
132
+ orderByTime?: 'Desc' | 'Asc';
133
+ grouped?: boolean;
134
+ limit?: number;
135
+ next?: string;
136
+ }): CancelablePromise<LogItemPaginatedList>;
97
137
  }
@@ -2,14 +2,10 @@ import { OpenAPI } from '../core/OpenAPI';
2
2
  import { request as __request } from '../core/request';
3
3
  export class ProjectsService {
4
4
  /**
5
- * @param query
6
- * @param orderByName
7
- * @param limit
8
- * @param next
9
5
  * @returns ProjectPaginatedList OK
10
6
  * @throws ApiError
11
7
  */
12
- static getProjects(query, orderByName, limit = 100, next) {
8
+ static getProjects({ query, orderByName, limit = 100, next, }) {
13
9
  return __request(OpenAPI, {
14
10
  method: 'GET',
15
11
  url: '/projects',
@@ -22,11 +18,10 @@ export class ProjectsService {
22
18
  });
23
19
  }
24
20
  /**
25
- * @param requestBody
26
21
  * @returns Project OK
27
22
  * @throws ApiError
28
23
  */
29
- static postProjects(requestBody) {
24
+ static postProjects({ requestBody, }) {
30
25
  return __request(OpenAPI, {
31
26
  method: 'POST',
32
27
  url: '/projects',
@@ -36,11 +31,10 @@ export class ProjectsService {
36
31
  }
37
32
  /**
38
33
  * Get projects in bulk.
39
- * @param requestBody
40
34
  * @returns ProjectBatchGetResult OK
41
35
  * @throws ApiError
42
36
  */
43
- static batchGetProjects(requestBody) {
37
+ static batchGetProjects({ requestBody, }) {
44
38
  return __request(OpenAPI, {
45
39
  method: 'POST',
46
40
  url: '/projects/$batchGet',
@@ -49,11 +43,10 @@ export class ProjectsService {
49
43
  });
50
44
  }
51
45
  /**
52
- * @param projectId
53
46
  * @returns any OK
54
47
  * @throws ApiError
55
48
  */
56
- static deleteProjects(projectId) {
49
+ static deleteProjects({ projectId, }) {
57
50
  return __request(OpenAPI, {
58
51
  method: 'DELETE',
59
52
  url: '/projects/{projectId}',
@@ -63,11 +56,10 @@ export class ProjectsService {
63
56
  });
64
57
  }
65
58
  /**
66
- * @param projectId
67
59
  * @returns Project OK
68
60
  * @throws ApiError
69
61
  */
70
- static getProjects1(projectId) {
62
+ static getProjects1({ projectId, }) {
71
63
  return __request(OpenAPI, {
72
64
  method: 'GET',
73
65
  url: '/projects/{projectId}',
@@ -77,12 +69,10 @@ export class ProjectsService {
77
69
  });
78
70
  }
79
71
  /**
80
- * @param projectId
81
- * @param requestBody
82
72
  * @returns Project OK
83
73
  * @throws ApiError
84
74
  */
85
- static patchProjects(projectId, requestBody) {
75
+ static patchProjects({ projectId, requestBody, }) {
86
76
  return __request(OpenAPI, {
87
77
  method: 'PATCH',
88
78
  url: '/projects/{projectId}',
@@ -94,29 +84,33 @@ export class ProjectsService {
94
84
  });
95
85
  }
96
86
  /**
97
- * @param projectId
98
87
  * @returns BalanceReport OK
99
88
  * @throws ApiError
100
89
  */
101
- static getProjectsBalance(projectId) {
90
+ static getProjectsBalance({ projectId, query, types, walletIds, labelIds, companyIds, memberIds, from, to, }) {
102
91
  return __request(OpenAPI, {
103
92
  method: 'GET',
104
93
  url: '/projects/{projectId}/balance',
105
94
  path: {
106
95
  'projectId': projectId,
107
96
  },
97
+ query: {
98
+ 'query': query,
99
+ 'types': types,
100
+ 'walletIds': walletIds,
101
+ 'labelIds': labelIds,
102
+ 'companyIds': companyIds,
103
+ 'memberIds': memberIds,
104
+ 'from': from,
105
+ 'to': to,
106
+ },
108
107
  });
109
108
  }
110
109
  /**
111
- * @param projectId
112
- * @param orderByName
113
- * @param orderByAmount
114
- * @param limit
115
- * @param next
116
110
  * @returns MemberBalancePaginatedList OK
117
111
  * @throws ApiError
118
112
  */
119
- static getProjectsBalanceMembers(projectId, orderByName, orderByAmount, limit = 100, next) {
113
+ static getProjectsBalanceMembers({ projectId, orderByName, orderByAmount, limit = 100, next, }) {
120
114
  return __request(OpenAPI, {
121
115
  method: 'GET',
122
116
  url: '/projects/{projectId}/balance/members',
@@ -132,15 +126,37 @@ export class ProjectsService {
132
126
  });
133
127
  }
134
128
  /**
135
- * @param projectId
136
- * @param orderByName
137
- * @param orderByAmount
138
- * @param limit
139
- * @param next
129
+ * Balance-over-time series for the project: an actual (wallet-state) line up to now and an effective line that
130
+ * combines accruals and may extend into the future as a prediction. Filters mirror the log feed: a wallet
131
+ * filter scopes operations (actual line), a member filter scopes accruals (effective line), and label/company
132
+ * narrow both. With no `from`, the series starts at the project's first recorded event; `to` defaults
133
+ * to now; the default interval is daily.
134
+ * @returns BalanceTimeline OK
135
+ * @throws ApiError
136
+ */
137
+ static getProjectsBalanceTimeline({ projectId, from, to, interval, walletIds, labelIds, companyIds, memberIds, }) {
138
+ return __request(OpenAPI, {
139
+ method: 'GET',
140
+ url: '/projects/{projectId}/balance/timeline',
141
+ path: {
142
+ 'projectId': projectId,
143
+ },
144
+ query: {
145
+ 'from': from,
146
+ 'to': to,
147
+ 'interval': interval,
148
+ 'walletIds': walletIds,
149
+ 'labelIds': labelIds,
150
+ 'companyIds': companyIds,
151
+ 'memberIds': memberIds,
152
+ },
153
+ });
154
+ }
155
+ /**
140
156
  * @returns WalletBalancePaginatedList OK
141
157
  * @throws ApiError
142
158
  */
143
- static getProjectsBalanceWallets(projectId, orderByName, orderByAmount, limit = 100, next) {
159
+ static getProjectsBalanceWallets({ projectId, orderByName, orderByAmount, limit = 100, next, }) {
144
160
  return __request(OpenAPI, {
145
161
  method: 'GET',
146
162
  url: '/projects/{projectId}/balance/wallets',
@@ -156,22 +172,10 @@ export class ProjectsService {
156
172
  });
157
173
  }
158
174
  /**
159
- * @param projectId
160
- * @param query
161
- * @param types
162
- * @param walletIds
163
- * @param labelIds
164
- * @param companyIds
165
- * @param from
166
- * @param to
167
- * @param orderByName
168
- * @param orderByTime
169
- * @param limit
170
- * @param next
171
175
  * @returns LogItemPaginatedList OK
172
176
  * @throws ApiError
173
177
  */
174
- static getProjectsLog(projectId, query, types, walletIds, labelIds, companyIds, from, to, orderByName, orderByTime, limit = 100, next) {
178
+ static getProjectsLog({ projectId, query, types, walletIds, labelIds, companyIds, memberIds, from, to, orderByName, orderByTime, grouped = true, limit = 100, next, }) {
175
179
  return __request(OpenAPI, {
176
180
  method: 'GET',
177
181
  url: '/projects/{projectId}/log',
@@ -184,10 +188,12 @@ export class ProjectsService {
184
188
  'walletIds': walletIds,
185
189
  'labelIds': labelIds,
186
190
  'companyIds': companyIds,
191
+ 'memberIds': memberIds,
187
192
  'from': from,
188
193
  'to': to,
189
194
  'orderByName': orderByName,
190
195
  'orderByTime': orderByTime,
196
+ 'grouped': grouped,
191
197
  'limit': limit,
192
198
  'next': next,
193
199
  },