@v3finance/core-sdk 0.1.0 → 0.2.0
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/CHANGELOG.md +397 -7
- package/README.md +215 -72
- package/dist/cjs/client.d.ts +67 -22
- package/dist/cjs/client.d.ts.map +1 -1
- package/dist/cjs/client.js +38 -2
- package/dist/cjs/client.js.map +1 -1
- package/dist/cjs/core/errors.d.ts +30 -10
- package/dist/cjs/core/errors.d.ts.map +1 -1
- package/dist/cjs/core/errors.js +47 -15
- package/dist/cjs/core/errors.js.map +1 -1
- package/dist/cjs/core/gated.d.ts +21 -3
- package/dist/cjs/core/gated.d.ts.map +1 -1
- package/dist/cjs/core/gated.js +12 -3
- package/dist/cjs/core/gated.js.map +1 -1
- package/dist/cjs/core/http.d.ts +12 -8
- package/dist/cjs/core/http.d.ts.map +1 -1
- package/dist/cjs/core/http.js +130 -40
- package/dist/cjs/core/http.js.map +1 -1
- package/dist/cjs/core/pagination.d.ts +28 -1
- package/dist/cjs/core/pagination.d.ts.map +1 -1
- package/dist/cjs/core/pagination.js +36 -1
- package/dist/cjs/core/pagination.js.map +1 -1
- package/dist/cjs/generated/operations.js +1 -1
- package/dist/cjs/generated/types.d.ts +948 -172
- package/dist/cjs/generated/types.d.ts.map +1 -1
- package/dist/cjs/index.d.ts +32 -8
- package/dist/cjs/index.d.ts.map +1 -1
- package/dist/cjs/index.js +12 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/resources/addresses.d.ts +22 -8
- package/dist/cjs/resources/addresses.d.ts.map +1 -1
- package/dist/cjs/resources/addresses.js +7 -1
- package/dist/cjs/resources/addresses.js.map +1 -1
- package/dist/cjs/resources/admin.d.ts +150 -25
- package/dist/cjs/resources/admin.d.ts.map +1 -1
- package/dist/cjs/resources/admin.js +94 -23
- package/dist/cjs/resources/admin.js.map +1 -1
- package/dist/cjs/resources/approvals.d.ts +46 -5
- package/dist/cjs/resources/approvals.d.ts.map +1 -1
- package/dist/cjs/resources/approvals.js +27 -4
- package/dist/cjs/resources/approvals.js.map +1 -1
- package/dist/cjs/resources/balances.d.ts +152 -16
- package/dist/cjs/resources/balances.d.ts.map +1 -1
- package/dist/cjs/resources/balances.js +9 -5
- package/dist/cjs/resources/balances.js.map +1 -1
- package/dist/cjs/resources/categories.d.ts +93 -21
- package/dist/cjs/resources/categories.d.ts.map +1 -1
- package/dist/cjs/resources/categories.js +65 -18
- package/dist/cjs/resources/categories.js.map +1 -1
- package/dist/cjs/resources/counterparties.d.ts +26 -3
- package/dist/cjs/resources/counterparties.d.ts.map +1 -1
- package/dist/cjs/resources/counterparties.js +17 -0
- package/dist/cjs/resources/counterparties.js.map +1 -1
- package/dist/cjs/resources/folders.d.ts +51 -10
- package/dist/cjs/resources/folders.d.ts.map +1 -1
- package/dist/cjs/resources/folders.js +36 -5
- package/dist/cjs/resources/folders.js.map +1 -1
- package/dist/cjs/resources/history.d.ts +20 -2
- package/dist/cjs/resources/history.d.ts.map +1 -1
- package/dist/cjs/resources/history.js.map +1 -1
- package/dist/cjs/resources/me.d.ts +27 -4
- package/dist/cjs/resources/me.d.ts.map +1 -1
- package/dist/cjs/resources/me.js +22 -1
- package/dist/cjs/resources/me.js.map +1 -1
- package/dist/cjs/resources/members.d.ts +19 -4
- package/dist/cjs/resources/members.d.ts.map +1 -1
- package/dist/cjs/resources/members.js +15 -6
- package/dist/cjs/resources/members.js.map +1 -1
- package/dist/cjs/resources/operations.d.ts +64 -8
- package/dist/cjs/resources/operations.d.ts.map +1 -1
- package/dist/cjs/resources/operations.js +26 -2
- package/dist/cjs/resources/operations.js.map +1 -1
- package/dist/cjs/resources/registries.d.ts +87 -9
- package/dist/cjs/resources/registries.d.ts.map +1 -1
- package/dist/cjs/resources/registries.js +54 -11
- package/dist/cjs/resources/registries.js.map +1 -1
- package/dist/cjs/resources/reports.d.ts +300 -41
- package/dist/cjs/resources/reports.d.ts.map +1 -1
- package/dist/cjs/resources/reports.js +135 -7
- package/dist/cjs/resources/reports.js.map +1 -1
- package/dist/cjs/resources/sharing.d.ts +61 -10
- package/dist/cjs/resources/sharing.d.ts.map +1 -1
- package/dist/cjs/resources/sharing.js +51 -4
- package/dist/cjs/resources/sharing.js.map +1 -1
- package/dist/cjs/resources/transfers.d.ts +26 -4
- package/dist/cjs/resources/transfers.d.ts.map +1 -1
- package/dist/cjs/resources/transfers.js +23 -1
- package/dist/cjs/resources/transfers.js.map +1 -1
- package/dist/cjs/resources/types.d.ts +20 -0
- package/dist/cjs/resources/types.d.ts.map +1 -1
- package/dist/cjs/units.d.ts.map +1 -1
- package/dist/cjs/units.js +18 -2
- package/dist/cjs/units.js.map +1 -1
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/client.d.ts +67 -22
- package/dist/esm/client.d.ts.map +1 -1
- package/dist/esm/client.js +38 -2
- package/dist/esm/client.js.map +1 -1
- package/dist/esm/core/errors.d.ts +30 -10
- package/dist/esm/core/errors.d.ts.map +1 -1
- package/dist/esm/core/errors.js +47 -15
- package/dist/esm/core/errors.js.map +1 -1
- package/dist/esm/core/gated.d.ts +21 -3
- package/dist/esm/core/gated.d.ts.map +1 -1
- package/dist/esm/core/gated.js +12 -3
- package/dist/esm/core/gated.js.map +1 -1
- package/dist/esm/core/http.d.ts +12 -8
- package/dist/esm/core/http.d.ts.map +1 -1
- package/dist/esm/core/http.js +131 -41
- package/dist/esm/core/http.js.map +1 -1
- package/dist/esm/core/pagination.d.ts +28 -1
- package/dist/esm/core/pagination.d.ts.map +1 -1
- package/dist/esm/core/pagination.js +36 -1
- package/dist/esm/core/pagination.js.map +1 -1
- package/dist/esm/generated/operations.js +1 -1
- package/dist/esm/generated/types.d.ts +948 -172
- package/dist/esm/generated/types.d.ts.map +1 -1
- package/dist/esm/index.d.ts +32 -8
- package/dist/esm/index.d.ts.map +1 -1
- package/dist/esm/index.js +17 -5
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/resources/addresses.d.ts +22 -8
- package/dist/esm/resources/addresses.d.ts.map +1 -1
- package/dist/esm/resources/addresses.js +7 -1
- package/dist/esm/resources/addresses.js.map +1 -1
- package/dist/esm/resources/admin.d.ts +150 -25
- package/dist/esm/resources/admin.d.ts.map +1 -1
- package/dist/esm/resources/admin.js +94 -23
- package/dist/esm/resources/admin.js.map +1 -1
- package/dist/esm/resources/approvals.d.ts +46 -5
- package/dist/esm/resources/approvals.d.ts.map +1 -1
- package/dist/esm/resources/approvals.js +27 -4
- package/dist/esm/resources/approvals.js.map +1 -1
- package/dist/esm/resources/balances.d.ts +152 -16
- package/dist/esm/resources/balances.d.ts.map +1 -1
- package/dist/esm/resources/balances.js +9 -5
- package/dist/esm/resources/balances.js.map +1 -1
- package/dist/esm/resources/categories.d.ts +93 -21
- package/dist/esm/resources/categories.d.ts.map +1 -1
- package/dist/esm/resources/categories.js +65 -18
- package/dist/esm/resources/categories.js.map +1 -1
- package/dist/esm/resources/counterparties.d.ts +26 -3
- package/dist/esm/resources/counterparties.d.ts.map +1 -1
- package/dist/esm/resources/counterparties.js +17 -0
- package/dist/esm/resources/counterparties.js.map +1 -1
- package/dist/esm/resources/folders.d.ts +51 -10
- package/dist/esm/resources/folders.d.ts.map +1 -1
- package/dist/esm/resources/folders.js +36 -5
- package/dist/esm/resources/folders.js.map +1 -1
- package/dist/esm/resources/history.d.ts +20 -2
- package/dist/esm/resources/history.d.ts.map +1 -1
- package/dist/esm/resources/history.js.map +1 -1
- package/dist/esm/resources/me.d.ts +27 -4
- package/dist/esm/resources/me.d.ts.map +1 -1
- package/dist/esm/resources/me.js +22 -1
- package/dist/esm/resources/me.js.map +1 -1
- package/dist/esm/resources/members.d.ts +19 -4
- package/dist/esm/resources/members.d.ts.map +1 -1
- package/dist/esm/resources/members.js +15 -6
- package/dist/esm/resources/members.js.map +1 -1
- package/dist/esm/resources/operations.d.ts +64 -8
- package/dist/esm/resources/operations.d.ts.map +1 -1
- package/dist/esm/resources/operations.js +26 -2
- package/dist/esm/resources/operations.js.map +1 -1
- package/dist/esm/resources/registries.d.ts +87 -9
- package/dist/esm/resources/registries.d.ts.map +1 -1
- package/dist/esm/resources/registries.js +54 -11
- package/dist/esm/resources/registries.js.map +1 -1
- package/dist/esm/resources/reports.d.ts +300 -41
- package/dist/esm/resources/reports.d.ts.map +1 -1
- package/dist/esm/resources/reports.js +135 -7
- package/dist/esm/resources/reports.js.map +1 -1
- package/dist/esm/resources/sharing.d.ts +61 -10
- package/dist/esm/resources/sharing.d.ts.map +1 -1
- package/dist/esm/resources/sharing.js +51 -4
- package/dist/esm/resources/sharing.js.map +1 -1
- package/dist/esm/resources/transfers.d.ts +26 -4
- package/dist/esm/resources/transfers.d.ts.map +1 -1
- package/dist/esm/resources/transfers.js +23 -1
- package/dist/esm/resources/transfers.js.map +1 -1
- package/dist/esm/resources/types.d.ts +20 -0
- package/dist/esm/resources/types.d.ts.map +1 -1
- package/dist/esm/units.d.ts.map +1 -1
- package/dist/esm/units.js +18 -2
- package/dist/esm/units.js.map +1 -1
- package/dist/esm/version.d.ts +1 -1
- package/dist/esm/version.js +1 -1
- package/docs/concepts.md +191 -0
- package/docs/errors.md +471 -0
- package/package.json +7 -6
- package/src/client.ts +89 -25
- package/src/core/errors.ts +49 -15
- package/src/core/gated.ts +22 -4
- package/src/core/http.ts +156 -46
- package/src/core/pagination.ts +38 -1
- package/src/generated/operations.ts +1 -1
- package/src/generated/types.ts +983 -173
- package/src/index.ts +64 -7
- package/src/resources/addresses.ts +23 -8
- package/src/resources/admin.ts +186 -33
- package/src/resources/approvals.ts +55 -9
- package/src/resources/balances.ts +186 -14
- package/src/resources/categories.ts +125 -30
- package/src/resources/counterparties.ts +23 -6
- package/src/resources/folders.ts +74 -18
- package/src/resources/history.ts +27 -2
- package/src/resources/me.ts +30 -5
- package/src/resources/members.ts +26 -7
- package/src/resources/operations.ts +73 -8
- package/src/resources/registries.ts +90 -11
- package/src/resources/reports.ts +348 -67
- package/src/resources/sharing.ts +71 -18
- package/src/resources/transfers.ts +33 -5
- package/src/resources/types.ts +20 -0
- package/src/units.ts +19 -2
- package/src/version.ts +1 -1
|
@@ -1,12 +1,17 @@
|
|
|
1
1
|
import { type HttpClient } from '../core/http.js';
|
|
2
|
-
import type {
|
|
2
|
+
import type { AccountStatementReport, AddressActivityReport, AnyReport, ApprovalActivityReport, AssetMovementReport, BalancePositionReport, CategoryAnalytics, CounterpartyActivityReport, CounterpartyGroupActivityReport, CreateReportExportBody, CreateReportSnapshotBody, CreateReportTemplateBody, DrilldownResponse, OperationsExceptionsReport, PatchReportTemplateBody, ReportDrilldownBody, ReportExport, ReportMeta, ReportSnapshot, ReportSnapshotDetail as GeneratedReportSnapshotDetail, ReportSnapshotList, ReportSnapshotListItem as GeneratedReportSnapshotListItem, ReportTemplate, TransactionActivityReport } from '../generated/types.js';
|
|
3
3
|
/**
|
|
4
4
|
* Report type. snake_case, and the SAME spelling everywhere: in the path, in
|
|
5
5
|
* the `?type=` alias, in a snapshot's `reportType` and in `report.type` of
|
|
6
6
|
* the answer. Paths and the alias once used kebab-case while snapshots used
|
|
7
7
|
* snake, so a client with a single `fetchReport` got a 400 on every snapshot.
|
|
8
|
+
*
|
|
9
|
+
* Taken from the document's own enum (`report.type` of an answer) rather than
|
|
10
|
+
* spelled out here, so a type the API grows shows up at once — as a compile
|
|
11
|
+
* error in `ReportParams` and `ReportResult`, which are keyed by it and would
|
|
12
|
+
* then lack an entry.
|
|
8
13
|
*/
|
|
9
|
-
export type ReportType = '
|
|
14
|
+
export type ReportType = ReportMeta['type'];
|
|
10
15
|
/**
|
|
11
16
|
* Filters shared by the reporting endpoints.
|
|
12
17
|
*
|
|
@@ -23,8 +28,8 @@ export interface ReportFilters {
|
|
|
23
28
|
to?: string | undefined;
|
|
24
29
|
timezone?: string | undefined;
|
|
25
30
|
/** Which date the period is measured by. */
|
|
26
|
-
dateBasis?:
|
|
27
|
-
groupBy?:
|
|
31
|
+
dateBasis?: ReportMeta['dateBasis'] | undefined;
|
|
32
|
+
groupBy?: 'day' | 'week' | 'month' | undefined;
|
|
28
33
|
/** Currency the totals are expressed in. */
|
|
29
34
|
baseCurrency?: string | undefined;
|
|
30
35
|
statuses?: readonly string[] | undefined;
|
|
@@ -51,12 +56,12 @@ export interface ReportFilters {
|
|
|
51
56
|
minimumAmount?: string | undefined;
|
|
52
57
|
maximumAmount?: string | undefined;
|
|
53
58
|
includeInternal?: boolean | undefined;
|
|
54
|
-
counterpartyClassification?:
|
|
55
|
-
folderClassification?:
|
|
56
|
-
comparison?:
|
|
59
|
+
counterpartyClassification?: ReportMeta['classificationMode'] | undefined;
|
|
60
|
+
folderClassification?: ReportMeta['classificationMode'] | undefined;
|
|
61
|
+
comparison?: 'none' | 'previous_period' | 'previous_year' | undefined;
|
|
57
62
|
userId?: string | undefined;
|
|
58
63
|
/** Split the figures by owner of the address. */
|
|
59
|
-
breakdownBy?:
|
|
64
|
+
breakdownBy?: 'owner' | undefined;
|
|
60
65
|
/** Include addresses shared with you. */
|
|
61
66
|
includeShared?: boolean | undefined;
|
|
62
67
|
tokenId?: string | undefined;
|
|
@@ -67,7 +72,7 @@ export interface ReportFilters {
|
|
|
67
72
|
categoryKey?: string | undefined;
|
|
68
73
|
groupByField?: string | undefined;
|
|
69
74
|
metricField?: string | undefined;
|
|
70
|
-
agg?:
|
|
75
|
+
agg?: 'sum' | 'avg' | 'min' | 'max' | 'median' | 'count' | undefined;
|
|
71
76
|
at?: string | undefined;
|
|
72
77
|
includeAdjustments?: boolean | undefined;
|
|
73
78
|
minimumAgeSeconds?: number | undefined;
|
|
@@ -78,11 +83,27 @@ export interface ReportFilters {
|
|
|
78
83
|
}
|
|
79
84
|
/**
|
|
80
85
|
* What a snapshot looks like IN A LISTING — eleven fields, not the whole
|
|
81
|
-
* record.
|
|
82
|
-
*
|
|
83
|
-
*
|
|
86
|
+
* record. A strict alias of the generated schema.
|
|
87
|
+
*
|
|
88
|
+
* The figures themselves are not among them: a list of snapshots would
|
|
89
|
+
* otherwise carry every report it mentions. Fetch one with `snapshot(id)`
|
|
90
|
+
* when you need its contents.
|
|
84
91
|
*/
|
|
85
|
-
export type ReportSnapshotListItem =
|
|
92
|
+
export type ReportSnapshotListItem = GeneratedReportSnapshotListItem;
|
|
93
|
+
/**
|
|
94
|
+
* A single snapshot, as `snapshot(id)` answers. A strict alias of the
|
|
95
|
+
* generated schema.
|
|
96
|
+
*
|
|
97
|
+
* The figures come back under `resultJson`, which is the column's own name.
|
|
98
|
+
* Only the CREATE call names the same thing `result` — hence two schemas,
|
|
99
|
+
* `ReportSnapshot` for `createSnapshot` and this one for the detail. Reading
|
|
100
|
+
* `result` off a detail, or `resultJson` off a fresh snapshot, is a compile
|
|
101
|
+
* error rather than an `undefined`.
|
|
102
|
+
*
|
|
103
|
+
* `resultJson` is `null` only for a snapshot that did not finish
|
|
104
|
+
* (`status` other than `completed`).
|
|
105
|
+
*/
|
|
106
|
+
export type ReportSnapshotDetail = GeneratedReportSnapshotDetail;
|
|
86
107
|
/** A period. Required by every report except `balance_position`. */
|
|
87
108
|
interface Period {
|
|
88
109
|
from: string;
|
|
@@ -97,12 +118,36 @@ interface Period {
|
|
|
97
118
|
*/
|
|
98
119
|
export interface ReportParams {
|
|
99
120
|
account_statement: Period;
|
|
100
|
-
|
|
121
|
+
/**
|
|
122
|
+
* Exactly one of the two. Neither, or both, is a 400 — and from this
|
|
123
|
+
* endpoint it arrives as `REPORT_INVALID_PERIOD`, a code that points at the
|
|
124
|
+
* dates and sends the reader looking in the wrong place.
|
|
125
|
+
*/
|
|
126
|
+
address_activity: Period & ({
|
|
127
|
+
addressId: string;
|
|
128
|
+
folderId?: never;
|
|
129
|
+
} | {
|
|
130
|
+
folderId: string;
|
|
131
|
+
addressId?: never;
|
|
132
|
+
});
|
|
101
133
|
approval_activity: Period;
|
|
102
134
|
asset_movement: Period & {
|
|
103
135
|
tokenId: string;
|
|
104
136
|
};
|
|
105
|
-
|
|
137
|
+
/**
|
|
138
|
+
* Nothing is required: the moment is `?at=` (omitted means now), and it
|
|
139
|
+
* lives in `ReportFilters` with the rest of what this report reads —
|
|
140
|
+
* `tokenIds`, `addressIds`, `folderIds`, `userId`, `includeShared`.
|
|
141
|
+
*
|
|
142
|
+
* `Record<never, never>` and NOT `Record<string, never>`. The latter is an
|
|
143
|
+
* easy thing to reach for and silently breaks the type: it carries an index
|
|
144
|
+
* signature, and in the intersection `ReportFilters & ReportParams[T]` that
|
|
145
|
+
* signature applies to every filter as well, narrowing each of them to
|
|
146
|
+
* `never`. The report then accepted no arguments at all — `{}` compiled and
|
|
147
|
+
* `{ at }` did not. `Record<never, never>` has no index signature, so it
|
|
148
|
+
* contributes no keys and takes none away.
|
|
149
|
+
*/
|
|
150
|
+
balance_position: Record<never, never>;
|
|
106
151
|
category_analytics: Period & {
|
|
107
152
|
categoryKey: string;
|
|
108
153
|
};
|
|
@@ -115,18 +160,104 @@ export interface ReportParams {
|
|
|
115
160
|
operations_exceptions: Period;
|
|
116
161
|
transaction_activity: Period;
|
|
117
162
|
}
|
|
118
|
-
/**
|
|
163
|
+
/**
|
|
164
|
+
* The report filters a DRILL-DOWN honours.
|
|
165
|
+
*
|
|
166
|
+
* Deliberately narrower than `ReportFilters`: the drill-down endpoint takes
|
|
167
|
+
* `filters` as a free-form bag and reads only these keys out of it, so
|
|
168
|
+
* anything else is accepted and then dropped — the silence that makes a
|
|
169
|
+
* figure and its breakdown disagree. Built with `Pick` so the two cannot
|
|
170
|
+
* drift apart as filters are added.
|
|
171
|
+
*/
|
|
172
|
+
export type DrilldownFilters = Pick<ReportFilters, 'from' | 'to' | 'dateBasis' | 'tokenIds' | 'networkIds' | 'addressIds' | 'ownAddressIds' | 'folderIds' | 'counterpartyIds' | 'counterpartyGroupIds' | 'counterpartyAddressIds' | 'statuses' | 'flowTypes' | 'categories' | 'categoryKeys' | 'categoryField' | 'initiatorIds' | 'decisionPolicyIds' | 'counterpartyClassification' | 'userId'> & {
|
|
173
|
+
/** `in`/`out`. The query-string reports have no equivalent filter. */
|
|
174
|
+
directions?: readonly ('in' | 'out')[] | undefined;
|
|
175
|
+
/**
|
|
176
|
+
* A STRING, not the boolean this flag is everywhere else in the package.
|
|
177
|
+
* `filters` reaches the handler unparsed and the comparison there is
|
|
178
|
+
* against `'true'`, so a boolean `true` is read as "not shared" and the
|
|
179
|
+
* shared addresses quietly drop out of the list.
|
|
180
|
+
*/
|
|
181
|
+
includeShared?: 'true' | 'false' | undefined;
|
|
182
|
+
};
|
|
183
|
+
/**
|
|
184
|
+
* WHICH cell of the report was clicked.
|
|
185
|
+
*
|
|
186
|
+
* These REFINE `filters`; where a key means the same thing in both, the click
|
|
187
|
+
* REPLACES the filter — with one exception, `categoryField`, where the two
|
|
188
|
+
* are combined instead. `periodStart` alone covers the following 24 hours;
|
|
189
|
+
* pass `periodEnd` for any other span.
|
|
190
|
+
*/
|
|
191
|
+
export interface DrilldownSelection {
|
|
192
|
+
direction?: 'in' | 'out' | undefined;
|
|
193
|
+
periodStart?: string | undefined;
|
|
194
|
+
periodEnd?: string | undefined;
|
|
195
|
+
tokenId?: string | undefined;
|
|
196
|
+
ownAddressId?: string | undefined;
|
|
197
|
+
counterpartyId?: string | undefined;
|
|
198
|
+
counterpartyAddressId?: string | undefined;
|
|
199
|
+
status?: string | undefined;
|
|
200
|
+
category?: string | undefined;
|
|
201
|
+
/**
|
|
202
|
+
* One group of a category-field report: `ticker:EUR`. COMBINED with
|
|
203
|
+
* `filters.categoryField` rather than replacing it, so a report already
|
|
204
|
+
* narrowed by field stays narrowed when a group of it is opened.
|
|
205
|
+
*/
|
|
206
|
+
categoryField?: string | undefined;
|
|
207
|
+
initiatorId?: string | undefined;
|
|
208
|
+
decisionPolicyId?: string | undefined;
|
|
209
|
+
}
|
|
210
|
+
/** `ReportDrilldownBody` minus the two free-form bags refined below. */
|
|
211
|
+
type DrilldownEnvelope = Omit<ReportDrilldownBody, 'filters' | 'drilldown'>;
|
|
212
|
+
/**
|
|
213
|
+
* Body of the drill-down request.
|
|
214
|
+
*
|
|
215
|
+
* The generated `ReportDrilldownBody` is the same request with `filters` and
|
|
216
|
+
* `drilldown` as free-form bags (`{ [key: string]: unknown }`) — which is
|
|
217
|
+
* what the API validates, and also why it is not used as-is: the endpoint
|
|
218
|
+
* reads a fixed set of keys out of each bag and drops the rest in silence.
|
|
219
|
+
* `DrilldownFilters` and `DrilldownSelection` name those keys. Everything
|
|
220
|
+
* else is taken from the generated schema, so a field the API adds to the
|
|
221
|
+
* envelope appears here without an edit:
|
|
222
|
+
*
|
|
223
|
+
* • `reportType` — informational, the handler does not branch on it;
|
|
224
|
+
* • `snapshotId` — build the list from a snapshot's manifest instead of
|
|
225
|
+
* from live data;
|
|
226
|
+
* • `limit` — 1..500, 100 by default;
|
|
227
|
+
* • `cursor` — `nextCursor` of the previous page.
|
|
228
|
+
*
|
|
229
|
+
* Each of those may also be passed as an explicit `undefined`, which is left
|
|
230
|
+
* out of the request.
|
|
231
|
+
*/
|
|
232
|
+
export type DrilldownQuery = {
|
|
233
|
+
[K in keyof DrilldownEnvelope]: DrilldownEnvelope[K] | undefined;
|
|
234
|
+
} & {
|
|
235
|
+
filters?: DrilldownFilters | undefined;
|
|
236
|
+
drilldown?: DrilldownSelection | undefined;
|
|
237
|
+
};
|
|
238
|
+
/**
|
|
239
|
+
* What each report type ANSWERS with — one generated schema per type.
|
|
240
|
+
*
|
|
241
|
+
* The ten reports share almost nothing beyond `report` (and, except for
|
|
242
|
+
* `category_analytics`, `dataQuality`): a position report has `totalsByAsset`
|
|
243
|
+
* and no `summary`, an approval report counts requests rather than money, an
|
|
244
|
+
* account statement is opening and closing balances. So `run('x', …)` hands
|
|
245
|
+
* back the schema of `x`, and a block that report does not have is a compile
|
|
246
|
+
* error instead of an `undefined` at runtime.
|
|
247
|
+
*
|
|
248
|
+
* `ReportResult[ReportType]` — every entry at once — is `AnyReport`.
|
|
249
|
+
*/
|
|
119
250
|
export interface ReportResult {
|
|
120
|
-
account_statement:
|
|
121
|
-
address_activity:
|
|
122
|
-
approval_activity:
|
|
123
|
-
asset_movement:
|
|
124
|
-
balance_position:
|
|
251
|
+
account_statement: AccountStatementReport;
|
|
252
|
+
address_activity: AddressActivityReport;
|
|
253
|
+
approval_activity: ApprovalActivityReport;
|
|
254
|
+
asset_movement: AssetMovementReport;
|
|
255
|
+
balance_position: BalancePositionReport;
|
|
125
256
|
category_analytics: CategoryAnalytics;
|
|
126
|
-
counterparty_activity:
|
|
127
|
-
counterparty_group_activity:
|
|
128
|
-
operations_exceptions:
|
|
129
|
-
transaction_activity:
|
|
257
|
+
counterparty_activity: CounterpartyActivityReport;
|
|
258
|
+
counterparty_group_activity: CounterpartyGroupActivityReport;
|
|
259
|
+
operations_exceptions: OperationsExceptionsReport;
|
|
260
|
+
transaction_activity: TransactionActivityReport;
|
|
130
261
|
}
|
|
131
262
|
/**
|
|
132
263
|
* Reports, templates, snapshots and exports.
|
|
@@ -144,20 +275,99 @@ export interface ReportResult {
|
|
|
144
275
|
export declare class ReportsResource {
|
|
145
276
|
#private;
|
|
146
277
|
constructor(http: HttpClient, vaultCode: string);
|
|
147
|
-
/**
|
|
278
|
+
/**
|
|
279
|
+
* Runs a report. The compiler requires whatever that type needs, and the
|
|
280
|
+
* answer is the schema of THAT type — see `ReportResult`.
|
|
281
|
+
*
|
|
282
|
+
* Money in a report is DECIMAL, not raw smallest units: every `AssetAmount`
|
|
283
|
+
* (`…ByAsset[].amount`), the `byAsset` rows, and the balances of
|
|
284
|
+
* `asset_movement`, `account_statement` and `balance_position` are strings
|
|
285
|
+
* like `"1.5"`. Read them with `parseDecimal`; `amount` would take `"1.5"`
|
|
286
|
+
* for an integer and reject it. The one exception is `address_activity`,
|
|
287
|
+
* whose `openingBalances`/`closingBalances` are raw (`balanceRaw`).
|
|
288
|
+
*
|
|
289
|
+
* Percentages — `comparison.*ChangePercent`, `observations[].changePercent`,
|
|
290
|
+
* the `…ShareUsd` and `…RatePercent` fields — are decimal STRINGS too
|
|
291
|
+
* (`"12.5"`, `"-40"`), and `null` where the figure cannot be worked out:
|
|
292
|
+
* no previous period to compare with, no USD valuation, a zero base.
|
|
293
|
+
*/
|
|
148
294
|
run<T extends ReportType>(type: T, params: ReportFilters & ReportParams[T]): Promise<ReportResult[T]>;
|
|
149
|
-
/**
|
|
295
|
+
/**
|
|
296
|
+
* The same thing through the unified endpoint, choosing the type by alias.
|
|
297
|
+
*
|
|
298
|
+
* The document types this endpoint's answer as `AnyReport`, the union of
|
|
299
|
+
* all ten. The type you pass decides which member arrives, so the return is
|
|
300
|
+
* narrowed to it; call it with a `ReportType` known only at runtime and you
|
|
301
|
+
* get the whole union back.
|
|
302
|
+
*/
|
|
150
303
|
runUnified<T extends ReportType>(type: T, params: ReportFilters & ReportParams[T]): Promise<ReportResult[T]>;
|
|
151
|
-
/**
|
|
152
|
-
|
|
304
|
+
/**
|
|
305
|
+
* Drill-down: the operations behind a figure in a report.
|
|
306
|
+
*
|
|
307
|
+
* A PERIOD IS REQUIRED even though every field of the body is optional. The
|
|
308
|
+
* endpoint takes it from `drilldown.periodStart` or else from
|
|
309
|
+
* `filters.from`/`filters.to`, and with neither it answers 400
|
|
310
|
+
* `REPORT_INVALID_PERIOD` — `queryOperations({})` is not a "whole history"
|
|
311
|
+
* query.
|
|
312
|
+
*
|
|
313
|
+
* The other defaults narrow harder than people expect: with no
|
|
314
|
+
* `filters.statuses` only `confirmed` operations are listed, and with no
|
|
315
|
+
* `filters.flowTypes` only `external` ones. Pass the report's own filters
|
|
316
|
+
* through, or the breakdown comes back smaller than the figure it explains.
|
|
317
|
+
*
|
|
318
|
+
* `totals.byAsset[].amount` is a DECIMAL string, like every `AssetAmount`
|
|
319
|
+
* in the reports. Read it with `parseDecimal`, not `amount` — the latter
|
|
320
|
+
* would take `'1.5'` for an integer and reject it.
|
|
321
|
+
*/
|
|
322
|
+
queryOperations(body?: DrilldownQuery): Promise<DrilldownResponse>;
|
|
153
323
|
/** Every saved template. The endpoint takes no parameters and no cursor. */
|
|
154
324
|
templates(): Promise<{
|
|
155
325
|
items: ReportTemplate[];
|
|
156
326
|
}>;
|
|
157
327
|
template(templateId: string): Promise<ReportTemplate>;
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
328
|
+
/**
|
|
329
|
+
* Saves a set of report parameters under a name.
|
|
330
|
+
*
|
|
331
|
+
* `parameters` is what the live report takes, as an object — with one
|
|
332
|
+
* addition: instead of `from`/`to` it may carry
|
|
333
|
+
* `relativePeriod: { unit: 'day' | 'week' | 'month', offset }`, resolved to
|
|
334
|
+
* dates each time the template runs.
|
|
335
|
+
*
|
|
336
|
+
* NOTHING IN `parameters` IS CHECKED ON SAVE — it is a free-form bag to the
|
|
337
|
+
* API. A template with no period, or one aimed at a counterparty that does
|
|
338
|
+
* not exist, saves fine and fails at `runTemplate`.
|
|
339
|
+
*
|
|
340
|
+
* `isShared: true` makes the template visible to the whole vault and is for
|
|
341
|
+
* administrators only. Sharing lends nobody the author's reach: the scope
|
|
342
|
+
* is worked out for whoever RUNS it, on every run, so two people get
|
|
343
|
+
* different figures from the same template.
|
|
344
|
+
*
|
|
345
|
+
* THE BAG IS NOT A QUERY STRING, and three things that work on a live
|
|
346
|
+
* report silently do not work here. It is stored and later handed to the
|
|
347
|
+
* report builder as it is — nothing parses it, nothing fills defaults:
|
|
348
|
+
*
|
|
349
|
+
* - a multi-value filter must be a real ARRAY; a comma-separated string is
|
|
350
|
+
* not split;
|
|
351
|
+
* - `categoryField` IS IGNORED. A live report parses `'ticker:EUR'` into a
|
|
352
|
+
* filter; this path does not, so a template or snapshot built from the
|
|
353
|
+
* filters of a report narrowed by `categoryField` answers 200 with
|
|
354
|
+
* figures for EVERY value — the wrong report, with no error. Until the
|
|
355
|
+
* API parses it here, send the parsed form the builder reads instead:
|
|
356
|
+
* `categoryFieldValues: { ticker: ['EUR'] }`;
|
|
357
|
+
* - `timezone` has no default. The live endpoints fall back to `UTC`; here
|
|
358
|
+
* an absent one reaches the builder as `undefined`. Always pass it.
|
|
359
|
+
*
|
|
360
|
+
* So spreading a `ReportFilters` value into `parameters` is safe only when
|
|
361
|
+
* it carries no `categoryField` and does carry a `timezone`. (The spread
|
|
362
|
+
* itself is needed because the type is an index signature, which an
|
|
363
|
+
* interface-typed value does not fit directly.)
|
|
364
|
+
*/
|
|
365
|
+
createTemplate(body: CreateReportTemplateBody): Promise<ReportTemplate>;
|
|
366
|
+
/** Partial: only the fields you send change. `parameters` is replaced whole, not merged. */
|
|
367
|
+
updateTemplate(templateId: string, body: PatchReportTemplateBody): Promise<ReportTemplate>;
|
|
368
|
+
deleteTemplate(templateId: string): Promise<{
|
|
369
|
+
deleted: true;
|
|
370
|
+
}>;
|
|
161
371
|
/**
|
|
162
372
|
* Runs a saved template with the filters stored IN IT.
|
|
163
373
|
*
|
|
@@ -166,8 +376,20 @@ export declare class ReportsResource {
|
|
|
166
376
|
* template's period while believing you had asked for another one. To
|
|
167
377
|
* change the filters, read the template and call `run()` with them, or
|
|
168
378
|
* edit the template.
|
|
379
|
+
*
|
|
380
|
+
* The answer is `AnyReport`: which of the ten shapes arrives depends on the
|
|
381
|
+
* template's `reportType`, which is not known to the compiler. `report.type`
|
|
382
|
+
* says which one it is at runtime, but it does NOT narrow the union — the
|
|
383
|
+
* document types that field as the same ten-value enum on every member. So
|
|
384
|
+
* narrow by a block only that report has (`'totalsByAsset' in report`), or
|
|
385
|
+
* check `report.type` and assert the type yourself.
|
|
386
|
+
*
|
|
387
|
+
* This is also where a template's mistakes surface, since its parameters
|
|
388
|
+
* were not checked when it was saved: no period is a 400, a target that no
|
|
389
|
+
* longer exists a 404, and a template built for somebody else's `userId`
|
|
390
|
+
* run by a non-administrator a 403.
|
|
169
391
|
*/
|
|
170
|
-
runTemplate(templateId: string): Promise<
|
|
392
|
+
runTemplate(templateId: string): Promise<AnyReport>;
|
|
171
393
|
/**
|
|
172
394
|
* A snapshot freezes a report's figures. Worth taking before anything that
|
|
173
395
|
* changes history, because a report recomputed later is a different report.
|
|
@@ -179,21 +401,58 @@ export declare class ReportsResource {
|
|
|
179
401
|
snapshots(params?: {
|
|
180
402
|
reportType?: ReportType;
|
|
181
403
|
limit?: number;
|
|
182
|
-
}): Promise<
|
|
183
|
-
|
|
404
|
+
}): Promise<ReportSnapshotList>;
|
|
405
|
+
/**
|
|
406
|
+
* One snapshot WITH its figures — under `resultJson`, not `result`; see
|
|
407
|
+
* `ReportSnapshotDetail`. A non-admin can only read snapshots they
|
|
408
|
+
* generated themselves, and a missing one is 404 either way, so "not yours"
|
|
409
|
+
* and "not there" are indistinguishable.
|
|
410
|
+
*/
|
|
411
|
+
snapshot(snapshotId: string): Promise<ReportSnapshotDetail>;
|
|
412
|
+
/**
|
|
413
|
+
* Builds the report and freezes it. The answer carries the figures under
|
|
414
|
+
* `result` — the detail (`snapshot(id)`) calls the same thing `resultJson`.
|
|
415
|
+
*
|
|
416
|
+
* `parameters` follows the same rules as a template's — read them at
|
|
417
|
+
* `createTemplate`, because two of them fail silently: `categoryField` is
|
|
418
|
+
* ignored (the snapshot would freeze UNFILTERED figures; send
|
|
419
|
+
* `categoryFieldValues` instead) and `timezone` has no default. Unlike a
|
|
420
|
+
* template the parameters ARE used at once, so a bad period or a missing
|
|
421
|
+
* target fails here.
|
|
422
|
+
*
|
|
423
|
+
* `result` is the report of type `reportType`, but the type cannot say so:
|
|
424
|
+
* the spec declares it as a free-form object. Narrow it yourself —
|
|
425
|
+
* `snap.result as unknown as ReportResult['transaction_activity']` (the
|
|
426
|
+
* double cast is required; the detail's `resultJson` takes the same one).
|
|
427
|
+
* For the same reason the per-type REQUIRED parameters are not checked by
|
|
428
|
+
* the compiler here, as they are in `run()`.
|
|
429
|
+
*
|
|
430
|
+
* A result over roughly 900 KB is refused with 400
|
|
431
|
+
* `REPORT_PERIOD_TOO_LARGE` — narrow the filters.
|
|
432
|
+
*/
|
|
433
|
+
createSnapshot(body: CreateReportSnapshotBody): Promise<ReportSnapshot>;
|
|
434
|
+
deleteSnapshot(snapshotId: string): Promise<{
|
|
435
|
+
deleted: true;
|
|
184
436
|
}>;
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
437
|
+
/**
|
|
438
|
+
* Exports a snapshot. The file is fetched separately, with `downloadExport`.
|
|
439
|
+
*
|
|
440
|
+
* Only `format` matters, and only two of its four values work: `json` (the
|
|
441
|
+
* frozen result) and `csv` (a flat register of operations). `xlsx` and
|
|
442
|
+
* `pdf` pass validation and are then refused with 400
|
|
443
|
+
* `REPORT_UNSUPPORTED_FORMAT`. `locale`, `timezone` and
|
|
444
|
+
* `includeOperationRegister` are accepted and currently change nothing.
|
|
445
|
+
*/
|
|
446
|
+
createExport(snapshotId: string, body: CreateReportExportBody): Promise<ReportExport>;
|
|
190
447
|
export(exportId: string): Promise<ReportExport>;
|
|
191
448
|
/**
|
|
192
449
|
* The exported FILE. Returns the raw `Response` on purpose: an export can
|
|
193
450
|
* be CSV or another binary format, and parsing that as JSON fails every
|
|
194
451
|
* time. Read it with `.blob()`, `.text()` or `.arrayBuffer()`.
|
|
195
452
|
*
|
|
196
|
-
*
|
|
453
|
+
* Exports are produced synchronously today, so the record `createExport`
|
|
454
|
+
* answers with is already `completed` and can be downloaded at once. The
|
|
455
|
+
* `status` field exists for a queued path — check it rather than assuming.
|
|
197
456
|
*/
|
|
198
457
|
downloadExport(exportId: string): Promise<Response>;
|
|
199
458
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"reports.d.ts","sourceRoot":"","sources":["../../../src/resources/reports.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,KAAK,UAAU,EAAc,MAAM,iBAAiB,CAAA;AAClE,OAAO,KAAK,EACV,
|
|
1
|
+
{"version":3,"file":"reports.d.ts","sourceRoot":"","sources":["../../../src/resources/reports.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,KAAK,UAAU,EAAc,MAAM,iBAAiB,CAAA;AAClE,OAAO,KAAK,EACV,sBAAsB,EACtB,qBAAqB,EACrB,SAAS,EACT,sB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