@connectreport/connectreport-js 2.81.0-beta.2 → 2.81.0-beta.3
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/api.ts +225 -0
- package/dist/index.cjs +7 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +224 -1
- package/dist/index.d.ts +224 -1
- package/dist/index.js +6 -0
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/api.ts
CHANGED
|
@@ -21,6 +21,150 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj
|
|
|
21
21
|
// @ts-ignore
|
|
22
22
|
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from './base';
|
|
23
23
|
|
|
24
|
+
/**
|
|
25
|
+
* Configuration for data-driven report cycles where each row in a data source creates a child report task
|
|
26
|
+
* @export
|
|
27
|
+
* @interface CycleConfig
|
|
28
|
+
*/
|
|
29
|
+
export interface CycleConfig {
|
|
30
|
+
/**
|
|
31
|
+
* Type of cycle configuration - \'filters\' for Dynamic Filters, \'recipients\' for Dynamic Recipients
|
|
32
|
+
* @type {string}
|
|
33
|
+
* @memberof CycleConfig
|
|
34
|
+
*/
|
|
35
|
+
configType: CycleConfigConfigTypeEnum;
|
|
36
|
+
/**
|
|
37
|
+
* Data connector name (case-insensitive)
|
|
38
|
+
* @type {string}
|
|
39
|
+
* @memberof CycleConfig
|
|
40
|
+
*/
|
|
41
|
+
connector: string;
|
|
42
|
+
/**
|
|
43
|
+
* Data source document ID
|
|
44
|
+
* @type {string}
|
|
45
|
+
* @memberof CycleConfig
|
|
46
|
+
*/
|
|
47
|
+
docId: string;
|
|
48
|
+
/**
|
|
49
|
+
* Columns to query - defines what data to fetch (each row creates a child task)
|
|
50
|
+
* @type {Array<FieldInfo>}
|
|
51
|
+
* @memberof CycleConfig
|
|
52
|
+
*/
|
|
53
|
+
tableColumns: Array<FieldInfo>;
|
|
54
|
+
/**
|
|
55
|
+
*
|
|
56
|
+
* @type {RowExclusion}
|
|
57
|
+
* @memberof CycleConfig
|
|
58
|
+
*/
|
|
59
|
+
excludedValues?: RowExclusion;
|
|
60
|
+
/**
|
|
61
|
+
* Map source fields to report filter fields
|
|
62
|
+
* @type {Array<FilterMapping>}
|
|
63
|
+
* @memberof CycleConfig
|
|
64
|
+
*/
|
|
65
|
+
filterMappings?: Array<FilterMapping>;
|
|
66
|
+
/**
|
|
67
|
+
*
|
|
68
|
+
* @type {FieldInfo}
|
|
69
|
+
* @memberof CycleConfig
|
|
70
|
+
*/
|
|
71
|
+
recipientsFieldInfo?: FieldInfo;
|
|
72
|
+
/**
|
|
73
|
+
*
|
|
74
|
+
* @type {FieldInfo}
|
|
75
|
+
* @memberof CycleConfig
|
|
76
|
+
*/
|
|
77
|
+
emailSubjectFieldInfo?: FieldInfo;
|
|
78
|
+
/**
|
|
79
|
+
*
|
|
80
|
+
* @type {FieldInfo}
|
|
81
|
+
* @memberof CycleConfig
|
|
82
|
+
*/
|
|
83
|
+
emailBodyFieldInfo?: FieldInfo;
|
|
84
|
+
/**
|
|
85
|
+
*
|
|
86
|
+
* @type {FieldInfo}
|
|
87
|
+
* @memberof CycleConfig
|
|
88
|
+
*/
|
|
89
|
+
titleFieldInfo?: FieldInfo;
|
|
90
|
+
/**
|
|
91
|
+
*
|
|
92
|
+
* @type {FieldInfo}
|
|
93
|
+
* @memberof CycleConfig
|
|
94
|
+
*/
|
|
95
|
+
oneDriveParentFolderIdFieldInfo?: FieldInfo;
|
|
96
|
+
/**
|
|
97
|
+
*
|
|
98
|
+
* @type {FieldInfo}
|
|
99
|
+
* @memberof CycleConfig
|
|
100
|
+
*/
|
|
101
|
+
tagsFieldInfo?: FieldInfo;
|
|
102
|
+
/**
|
|
103
|
+
*
|
|
104
|
+
* @type {FieldInfo}
|
|
105
|
+
* @memberof CycleConfig
|
|
106
|
+
*/
|
|
107
|
+
groupsToShareWithFieldInfo?: FieldInfo;
|
|
108
|
+
/**
|
|
109
|
+
*
|
|
110
|
+
* @type {FieldInfo}
|
|
111
|
+
* @memberof CycleConfig
|
|
112
|
+
*/
|
|
113
|
+
emailFieldInfo?: FieldInfo;
|
|
114
|
+
/**
|
|
115
|
+
* Automatically tag child reports with first column value
|
|
116
|
+
* @type {boolean}
|
|
117
|
+
* @memberof CycleConfig
|
|
118
|
+
*/
|
|
119
|
+
autotag?: boolean;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
/**
|
|
123
|
+
* @export
|
|
124
|
+
* @enum {string}
|
|
125
|
+
*/
|
|
126
|
+
export enum CycleConfigConfigTypeEnum {
|
|
127
|
+
Filters = 'filters',
|
|
128
|
+
Recipients = 'recipients'
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
/**
|
|
132
|
+
* Field metadata from data source
|
|
133
|
+
* @export
|
|
134
|
+
* @interface FieldInfo
|
|
135
|
+
*/
|
|
136
|
+
export interface FieldInfo {
|
|
137
|
+
/**
|
|
138
|
+
* Display name of the field
|
|
139
|
+
* @type {string}
|
|
140
|
+
* @memberof FieldInfo
|
|
141
|
+
*/
|
|
142
|
+
fieldName?: string;
|
|
143
|
+
/**
|
|
144
|
+
* Definition/expression of the field
|
|
145
|
+
* @type {string}
|
|
146
|
+
* @memberof FieldInfo
|
|
147
|
+
*/
|
|
148
|
+
fieldDef: string;
|
|
149
|
+
/**
|
|
150
|
+
* Unique identifier of the field
|
|
151
|
+
* @type {string}
|
|
152
|
+
* @memberof FieldInfo
|
|
153
|
+
*/
|
|
154
|
+
id?: string;
|
|
155
|
+
/**
|
|
156
|
+
* Table identifier
|
|
157
|
+
* @type {string}
|
|
158
|
+
* @memberof FieldInfo
|
|
159
|
+
*/
|
|
160
|
+
table?: string;
|
|
161
|
+
/**
|
|
162
|
+
* Display name of the table
|
|
163
|
+
* @type {string}
|
|
164
|
+
* @memberof FieldInfo
|
|
165
|
+
*/
|
|
166
|
+
tableName?: string;
|
|
167
|
+
}
|
|
24
168
|
/**
|
|
25
169
|
*
|
|
26
170
|
* @export
|
|
@@ -171,6 +315,12 @@ export interface FilterCycle {
|
|
|
171
315
|
* @memberof FilterCycle
|
|
172
316
|
*/
|
|
173
317
|
onedriveParentFolderId?: string;
|
|
318
|
+
/**
|
|
319
|
+
*
|
|
320
|
+
* @type {CycleConfig}
|
|
321
|
+
* @memberof FilterCycle
|
|
322
|
+
*/
|
|
323
|
+
cycle?: CycleConfig;
|
|
174
324
|
/**
|
|
175
325
|
*
|
|
176
326
|
* @type {FilterCycleAllOfFieldInfo}
|
|
@@ -338,6 +488,25 @@ export interface FilterCycleAllOfFieldValues {
|
|
|
338
488
|
*/
|
|
339
489
|
number?: number;
|
|
340
490
|
}
|
|
491
|
+
/**
|
|
492
|
+
* Maps a source table field to a report filter field
|
|
493
|
+
* @export
|
|
494
|
+
* @interface FilterMapping
|
|
495
|
+
*/
|
|
496
|
+
export interface FilterMapping {
|
|
497
|
+
/**
|
|
498
|
+
*
|
|
499
|
+
* @type {FieldInfo}
|
|
500
|
+
* @memberof FilterMapping
|
|
501
|
+
*/
|
|
502
|
+
from: FieldInfo;
|
|
503
|
+
/**
|
|
504
|
+
*
|
|
505
|
+
* @type {FieldInfo}
|
|
506
|
+
* @memberof FilterMapping
|
|
507
|
+
*/
|
|
508
|
+
to: FieldInfo;
|
|
509
|
+
}
|
|
341
510
|
/**
|
|
342
511
|
*
|
|
343
512
|
* @export
|
|
@@ -753,6 +922,12 @@ export interface ReportTask {
|
|
|
753
922
|
* @memberof ReportTask
|
|
754
923
|
*/
|
|
755
924
|
onedriveParentFolderId?: string;
|
|
925
|
+
/**
|
|
926
|
+
*
|
|
927
|
+
* @type {CycleConfig}
|
|
928
|
+
* @memberof ReportTask
|
|
929
|
+
*/
|
|
930
|
+
cycle?: CycleConfig;
|
|
756
931
|
}
|
|
757
932
|
|
|
758
933
|
/**
|
|
@@ -1030,6 +1205,12 @@ export interface ReportTaskRequest {
|
|
|
1030
1205
|
* @memberof ReportTaskRequest
|
|
1031
1206
|
*/
|
|
1032
1207
|
onedriveParentFolderId?: string;
|
|
1208
|
+
/**
|
|
1209
|
+
*
|
|
1210
|
+
* @type {CycleConfig}
|
|
1211
|
+
* @memberof ReportTaskRequest
|
|
1212
|
+
*/
|
|
1213
|
+
cycle?: CycleConfig;
|
|
1033
1214
|
/**
|
|
1034
1215
|
* Emails to send the report to. This is only allowed if \"Allow reports to be shared with any email\" is to true.
|
|
1035
1216
|
* @type {Array<string>}
|
|
@@ -1268,6 +1449,12 @@ export interface ReportTaskResponse {
|
|
|
1268
1449
|
* @memberof ReportTaskResponse
|
|
1269
1450
|
*/
|
|
1270
1451
|
onedriveParentFolderId?: string;
|
|
1452
|
+
/**
|
|
1453
|
+
*
|
|
1454
|
+
* @type {CycleConfig}
|
|
1455
|
+
* @memberof ReportTaskResponse
|
|
1456
|
+
*/
|
|
1457
|
+
cycle?: CycleConfig;
|
|
1271
1458
|
/**
|
|
1272
1459
|
* Users to share the published report with. This field will be updated entirely if provided
|
|
1273
1460
|
* @type {Array<ReportTaskResponseAllOfUsersToShareWith>}
|
|
@@ -1521,6 +1708,44 @@ export interface ReportTaskVariables {
|
|
|
1521
1708
|
*/
|
|
1522
1709
|
value?: string;
|
|
1523
1710
|
}
|
|
1711
|
+
/**
|
|
1712
|
+
* Filter out rows where field matches specified values
|
|
1713
|
+
* @export
|
|
1714
|
+
* @interface RowExclusion
|
|
1715
|
+
*/
|
|
1716
|
+
export interface RowExclusion {
|
|
1717
|
+
/**
|
|
1718
|
+
*
|
|
1719
|
+
* @type {FieldInfo}
|
|
1720
|
+
* @memberof RowExclusion
|
|
1721
|
+
*/
|
|
1722
|
+
exclusionFieldInfo: FieldInfo;
|
|
1723
|
+
/**
|
|
1724
|
+
*
|
|
1725
|
+
* @type {Array<RowExclusionFieldValues>}
|
|
1726
|
+
* @memberof RowExclusion
|
|
1727
|
+
*/
|
|
1728
|
+
fieldValues: Array<RowExclusionFieldValues>;
|
|
1729
|
+
}
|
|
1730
|
+
/**
|
|
1731
|
+
*
|
|
1732
|
+
* @export
|
|
1733
|
+
* @interface RowExclusionFieldValues
|
|
1734
|
+
*/
|
|
1735
|
+
export interface RowExclusionFieldValues {
|
|
1736
|
+
/**
|
|
1737
|
+
*
|
|
1738
|
+
* @type {string}
|
|
1739
|
+
* @memberof RowExclusionFieldValues
|
|
1740
|
+
*/
|
|
1741
|
+
text: string;
|
|
1742
|
+
/**
|
|
1743
|
+
*
|
|
1744
|
+
* @type {number}
|
|
1745
|
+
* @memberof RowExclusionFieldValues
|
|
1746
|
+
*/
|
|
1747
|
+
number?: number;
|
|
1748
|
+
}
|
|
1524
1749
|
/**
|
|
1525
1750
|
*
|
|
1526
1751
|
* @export
|
package/dist/index.cjs
CHANGED
|
@@ -78,6 +78,7 @@ __export(index_exports, {
|
|
|
78
78
|
BaseTemplatesApiFactory: () => BaseTemplatesApiFactory,
|
|
79
79
|
BaseTemplatesApiFp: () => BaseTemplatesApiFp,
|
|
80
80
|
ConnectReport: () => ConnectReport,
|
|
81
|
+
CycleConfigConfigTypeEnum: () => CycleConfigConfigTypeEnum,
|
|
81
82
|
DocumentsApi: () => DocumentsApi,
|
|
82
83
|
DocumentsApiAxiosParamCreator: () => DocumentsApiAxiosParamCreator,
|
|
83
84
|
DocumentsApiFactory: () => DocumentsApiFactory,
|
|
@@ -198,6 +199,11 @@ var createRequestFunction = function(axiosArgs, globalAxios3, BASE_PATH2, config
|
|
|
198
199
|
};
|
|
199
200
|
|
|
200
201
|
// api.ts
|
|
202
|
+
var CycleConfigConfigTypeEnum = /* @__PURE__ */ ((CycleConfigConfigTypeEnum2) => {
|
|
203
|
+
CycleConfigConfigTypeEnum2["Filters"] = "filters";
|
|
204
|
+
CycleConfigConfigTypeEnum2["Recipients"] = "recipients";
|
|
205
|
+
return CycleConfigConfigTypeEnum2;
|
|
206
|
+
})(CycleConfigConfigTypeEnum || {});
|
|
201
207
|
var FilterCycleFrequencyEnum = /* @__PURE__ */ ((FilterCycleFrequencyEnum2) => {
|
|
202
208
|
FilterCycleFrequencyEnum2["Monthly"] = "Monthly";
|
|
203
209
|
FilterCycleFrequencyEnum2["OnceNow"] = "Once - now";
|
|
@@ -3127,6 +3133,7 @@ globalThis.ConnectReport = ConnectReport;
|
|
|
3127
3133
|
BaseTemplatesApiFactory,
|
|
3128
3134
|
BaseTemplatesApiFp,
|
|
3129
3135
|
ConnectReport,
|
|
3136
|
+
CycleConfigConfigTypeEnum,
|
|
3130
3137
|
DocumentsApi,
|
|
3131
3138
|
DocumentsApiAxiosParamCreator,
|
|
3132
3139
|
DocumentsApiFactory,
|