rtc4js 0.0.6 → 0.1.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/.env +5 -5
- package/README.md +49 -1
- package/package.json +1 -1
package/.env
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
RTC4J_TEST_PROJECT_ID=WfNzIMYphSkgBiEzqz049
|
|
2
|
-
RTC4J_TEST_WORKSPACE_ID=qZle8BmYD8C5GS_94pUIF
|
|
3
1
|
RTC4J_TEST_ACCESS_ID=dev.e.hirakawa@gmail.com
|
|
2
|
+
RTC4J_TEST_ACCESS_KEY=sUF5m5GWwkpKZG3K9r9v3
|
|
4
3
|
RTC4J_TEST_ENDPOINT=localhost:8082
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
4
|
+
RTC4J_TEST_OBJECT_ID=Hx8qKT4ZE5hfozm13c-5d
|
|
5
|
+
RTC4J_TEST_PROJECT_ID=XJ-sbocpVOsKlmaUyzJfT
|
|
6
|
+
RTC4J_TEST_REPORT_ID=HXuoIwN2C5AXtkGJq0eRB
|
|
7
|
+
RTC4J_TEST_WORKSPACE_ID=Q0zYXCJGho-er9Mh5FtGD
|
package/README.md
CHANGED
|
@@ -88,6 +88,16 @@ try {
|
|
|
88
88
|
|
|
89
89
|
## Usage - Projects Report
|
|
90
90
|
|
|
91
|
+
### Projects - Get schema
|
|
92
|
+
> Gets schema information within a specific project in this any workspace.
|
|
93
|
+
```java
|
|
94
|
+
const request = SchemaGetRequest.builder()
|
|
95
|
+
.workspaceId('RTC4J_TEST_WORKSPACE_ID')
|
|
96
|
+
.projectId('RTC4J_TEST_PROJECT_ID')
|
|
97
|
+
.build();
|
|
98
|
+
const results = await connector.get<SchemaField[]>(request);
|
|
99
|
+
```
|
|
100
|
+
|
|
91
101
|
### Projects - Search reports
|
|
92
102
|
> Search reports for a specific project in this any workspace.
|
|
93
103
|
```js
|
|
@@ -103,6 +113,20 @@ const results = await connector.search(request, ReportResponse.of);
|
|
|
103
113
|
console.log('results', results);
|
|
104
114
|
```
|
|
105
115
|
|
|
116
|
+
### Projects - Search reports (Bulk operation)
|
|
117
|
+
> Search reports for multiple projects in this any workspace.
|
|
118
|
+
```js
|
|
119
|
+
import { ReportBulkSearchRequest, ReportResponse } from 'rtc4js';
|
|
120
|
+
|
|
121
|
+
const request = ReportBulkSearchRequest.builder()
|
|
122
|
+
.workspaceId("EXAMPLE WORKSPACE_ID")
|
|
123
|
+
.ids("EXAMPLE PROJECT_ID1", "EXAMPLE PROJECT_ID2")
|
|
124
|
+
.page(0)
|
|
125
|
+
.size(15)
|
|
126
|
+
.build();
|
|
127
|
+
const response = connector.search(request, ReportResponse.of);
|
|
128
|
+
```
|
|
129
|
+
|
|
106
130
|
### Projects - Count reports
|
|
107
131
|
> Count reports for a specific project in this any workspace.
|
|
108
132
|
```js
|
|
@@ -113,7 +137,18 @@ const request = ReportCountRequest.builder()
|
|
|
113
137
|
.projectId('RTC4J_TEST_PROJECT_ID')
|
|
114
138
|
.build();
|
|
115
139
|
const results = await connector.count(request);
|
|
116
|
-
|
|
140
|
+
```
|
|
141
|
+
|
|
142
|
+
### Projects - Count reports (Bulk operation)
|
|
143
|
+
> Count reports for for multiple projects in this any workspace.
|
|
144
|
+
```js
|
|
145
|
+
import { ReportBulkCountRequest } from 'rtc4js';
|
|
146
|
+
|
|
147
|
+
const request = ReportBulkCountRequest.builder()
|
|
148
|
+
.workspaceId('RTC4J_TEST_WORKSPACE_ID')
|
|
149
|
+
.ids("EXAMPLE PROJECT_ID1", "EXAMPLE PROJECT_ID2")
|
|
150
|
+
.build();
|
|
151
|
+
const results = await connector.count(request);
|
|
117
152
|
```
|
|
118
153
|
|
|
119
154
|
### Projects - Get report
|
|
@@ -287,6 +322,19 @@ const request = ReportDeleteObjectRequest.builder()
|
|
|
287
322
|
await connector.delete(request);
|
|
288
323
|
```
|
|
289
324
|
|
|
325
|
+
### Projects - Aggregate report values
|
|
326
|
+
> Aggregates the values of a report field for multiple projects in this any workspace
|
|
327
|
+
```js
|
|
328
|
+
import { ReportAggregateValueRequest, AggregateValueResponse } from 'rtc4js';
|
|
329
|
+
|
|
330
|
+
const request = ReportAggregateValueRequest.builder()
|
|
331
|
+
.workspaceId('RTC4J_TEST_WORKSPACE_ID')
|
|
332
|
+
.ids("EXAMPLE PROJECT_ID1", "EXAMPLE PROJECT_ID2")
|
|
333
|
+
.fieldId("EXAMPLE_TARGET_FIELD_ID")
|
|
334
|
+
.build();
|
|
335
|
+
const results = await connector.bulkGet(request, AggregateValueResponse.of);
|
|
336
|
+
```
|
|
337
|
+
|
|
290
338
|
### Sample code for report registration
|
|
291
339
|
```js
|
|
292
340
|
function makeDummyFields(): { [key: string]: unknown } {
|
package/package.json
CHANGED