@knowledge-stack/ksapi 1.139.0 → 1.140.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/.openapi-generator/FILES +28 -0
- package/README.md +25 -11
- package/dist/apis/AdminKbApi.d.ts +109 -0
- package/dist/apis/AdminKbApi.js +172 -0
- package/dist/apis/AdminWorkflowsApi.d.ts +252 -0
- package/dist/apis/AdminWorkflowsApi.js +337 -0
- package/dist/apis/SkillsApi.d.ts +4 -4
- package/dist/apis/SkillsApi.js +2 -2
- package/dist/apis/index.d.ts +2 -0
- package/dist/apis/index.js +2 -0
- package/dist/esm/apis/AdminKbApi.d.ts +109 -0
- package/dist/esm/apis/AdminKbApi.js +135 -0
- package/dist/esm/apis/AdminWorkflowsApi.d.ts +252 -0
- package/dist/esm/apis/AdminWorkflowsApi.js +300 -0
- package/dist/esm/apis/SkillsApi.d.ts +4 -4
- package/dist/esm/apis/SkillsApi.js +2 -2
- package/dist/esm/apis/index.d.ts +2 -0
- package/dist/esm/apis/index.js +2 -0
- package/dist/esm/models/DefinitionOutputStat.d.ts +65 -0
- package/dist/esm/models/DefinitionOutputStat.js +56 -0
- package/dist/esm/models/HourHistogramResponse.d.ts +53 -0
- package/dist/esm/models/HourHistogramResponse.js +54 -0
- package/dist/esm/models/KbMetric.d.ts +26 -0
- package/dist/esm/models/KbMetric.js +44 -0
- package/dist/esm/models/KbSummaryResponse.d.ts +152 -0
- package/dist/esm/models/KbSummaryResponse.js +109 -0
- package/dist/esm/models/KbTimeseriesResponse.d.ts +71 -0
- package/dist/esm/models/KbTimeseriesResponse.js +57 -0
- package/dist/esm/models/LabeledSeries.d.ts +54 -0
- package/dist/esm/models/LabeledSeries.js +47 -0
- package/dist/esm/models/LeaderboardEntry.d.ts +59 -0
- package/dist/esm/models/LeaderboardEntry.js +52 -0
- package/dist/esm/models/RunTimeseriesResponse.d.ts +61 -0
- package/dist/esm/models/RunTimeseriesResponse.js +52 -0
- package/dist/esm/models/SkillResponse.d.ts +7 -0
- package/dist/esm/models/SkillResponse.js +3 -0
- package/dist/esm/models/TimeBucket.d.ts +27 -0
- package/dist/esm/models/TimeBucket.js +45 -0
- package/dist/esm/models/TimeseriesPoint.d.ts +53 -0
- package/dist/esm/models/TimeseriesPoint.js +48 -0
- package/dist/esm/models/WorkflowLeaderboardResponse.d.ts +54 -0
- package/dist/esm/models/WorkflowLeaderboardResponse.js +45 -0
- package/dist/esm/models/WorkflowOutputStatsResponse.d.ts +54 -0
- package/dist/esm/models/WorkflowOutputStatsResponse.js +47 -0
- package/dist/esm/models/index.d.ts +12 -0
- package/dist/esm/models/index.js +12 -0
- package/dist/models/DefinitionOutputStat.d.ts +65 -0
- package/dist/models/DefinitionOutputStat.js +64 -0
- package/dist/models/HourHistogramResponse.d.ts +53 -0
- package/dist/models/HourHistogramResponse.js +62 -0
- package/dist/models/KbMetric.d.ts +26 -0
- package/dist/models/KbMetric.js +52 -0
- package/dist/models/KbSummaryResponse.d.ts +152 -0
- package/dist/models/KbSummaryResponse.js +117 -0
- package/dist/models/KbTimeseriesResponse.d.ts +71 -0
- package/dist/models/KbTimeseriesResponse.js +65 -0
- package/dist/models/LabeledSeries.d.ts +54 -0
- package/dist/models/LabeledSeries.js +55 -0
- package/dist/models/LeaderboardEntry.d.ts +59 -0
- package/dist/models/LeaderboardEntry.js +60 -0
- package/dist/models/RunTimeseriesResponse.d.ts +61 -0
- package/dist/models/RunTimeseriesResponse.js +60 -0
- package/dist/models/SkillResponse.d.ts +7 -0
- package/dist/models/SkillResponse.js +3 -0
- package/dist/models/TimeBucket.d.ts +27 -0
- package/dist/models/TimeBucket.js +53 -0
- package/dist/models/TimeseriesPoint.d.ts +53 -0
- package/dist/models/TimeseriesPoint.js +56 -0
- package/dist/models/WorkflowLeaderboardResponse.d.ts +54 -0
- package/dist/models/WorkflowLeaderboardResponse.js +53 -0
- package/dist/models/WorkflowOutputStatsResponse.d.ts +54 -0
- package/dist/models/WorkflowOutputStatsResponse.js +55 -0
- package/dist/models/index.d.ts +12 -0
- package/dist/models/index.js +12 -0
- package/docs/AdminKbApi.md +163 -0
- package/docs/AdminWorkflowsApi.md +424 -0
- package/docs/DefinitionOutputStat.md +41 -0
- package/docs/FolderResponseOrDocumentResponseOrWorkflowDefinitionResponseOrWorkflowRunResponseOrDataSourceResponseOrDataSourceSchemaR.md +2 -0
- package/docs/HourHistogramResponse.md +37 -0
- package/docs/KbMetric.md +33 -0
- package/docs/KbSummaryResponse.md +67 -0
- package/docs/KbTimeseriesResponse.md +41 -0
- package/docs/LabeledSeries.md +37 -0
- package/docs/LeaderboardEntry.md +39 -0
- package/docs/RunTimeseriesResponse.md +39 -0
- package/docs/SkillResponse.md +2 -0
- package/docs/SkillsApi.md +1 -1
- package/docs/TimeBucket.md +33 -0
- package/docs/TimeseriesPoint.md +37 -0
- package/docs/WorkflowLeaderboardResponse.md +37 -0
- package/docs/WorkflowOutputStatsResponse.md +37 -0
- package/package.json +1 -1
- package/src/apis/AdminKbApi.ts +237 -0
- package/src/apis/AdminWorkflowsApi.ts +539 -0
- package/src/apis/SkillsApi.ts +4 -4
- package/src/apis/index.ts +2 -0
- package/src/models/DefinitionOutputStat.ts +110 -0
- package/src/models/HourHistogramResponse.ts +97 -0
- package/src/models/KbMetric.ts +54 -0
- package/src/models/KbSummaryResponse.ts +235 -0
- package/src/models/KbTimeseriesResponse.ts +136 -0
- package/src/models/LabeledSeries.ts +99 -0
- package/src/models/LeaderboardEntry.ts +101 -0
- package/src/models/RunTimeseriesResponse.ts +117 -0
- package/src/models/SkillResponse.ts +15 -0
- package/src/models/TimeBucket.ts +55 -0
- package/src/models/TimeseriesPoint.ts +92 -0
- package/src/models/WorkflowLeaderboardResponse.ts +98 -0
- package/src/models/WorkflowOutputStatsResponse.ts +99 -0
- package/src/models/index.ts +12 -0
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Knowledge Stack API
|
|
5
|
+
* Knowledge Stack backend API for authentication and knowledge management. ## Integrating (RPA / machine clients) **Base URL.** Knowledge Stack is self-hosted — point at your own deployment host (see `servers`). The `localhost` entry is for local development only. **Authentication.** Send `Authorization: Bearer <api-key>` on every request. Mint an API key once via `POST /v1/api-keys` from a signed-in browser session; the raw `sk-user-...` secret is returned **only** at creation, so store it then. A key inherits its owning user\'s live tenant role and path permissions — create RPA keys from a least-privilege user, and set `expires_at` for rotation. The `ks_uat` cookie scheme is browser-only and cannot be used by headless clients. **Async work is polled, not pushed.** There are no outbound webhooks. - `POST /v1/documents/ingest` returns `201` immediately with a `workflow_id`; poll `GET /v1/system-jobs/document_versions/{workflow_id}` until `status` is terminal (anything other than `pending`/`processing`). The `Location` response header points at this poll resource. - `POST /v1/workflow-runs/{run_id}/start` returns `202`; poll `GET /v1/workflow-runs/{run_id}` until `execution_state` is `COMPLETED` or `FAILED`. The `Location` header points at the run resource. - `POST /v1/agent/ask` is **synchronous** — it blocks until the agent finishes and returns the answer inline. Use a generous HTTP timeout. **Pagination.** List endpoints accept `limit`/`offset` and return `{items, total, limit, offset}`. **Errors.** Every non-2xx body is `{detail, code, request_id}`. `code` is a stable value from a closed set (see the `ErrorResponse` schema\'s `code` enum) — branch on it rather than parsing `detail`. Quota rejections return `429` with a `Retry-After` header; transient lock contention returns a retryable `503`. Quote `request_id` (also the `x-request-id` response header) to support. **Idempotency.** `POST /v1/workflow-runs` accepts an `idempotency_key` to dedupe retried run creation. `agent/ask` charges one message *before* running and does not refund a client-cancelled call.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 0.1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { TimeseriesPoint } from './TimeseriesPoint';
|
|
17
|
+
import {
|
|
18
|
+
TimeseriesPointFromJSON,
|
|
19
|
+
TimeseriesPointFromJSONTyped,
|
|
20
|
+
TimeseriesPointToJSON,
|
|
21
|
+
TimeseriesPointToJSONTyped,
|
|
22
|
+
} from './TimeseriesPoint';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* A named series (e.g. one per document origin or ingestion outcome).
|
|
26
|
+
* @export
|
|
27
|
+
* @interface LabeledSeries
|
|
28
|
+
*/
|
|
29
|
+
export interface LabeledSeries {
|
|
30
|
+
/**
|
|
31
|
+
* Series label, e.g. 'SOURCE' or 'FAILED'.
|
|
32
|
+
* @type {string}
|
|
33
|
+
* @memberof LabeledSeries
|
|
34
|
+
*/
|
|
35
|
+
label: string;
|
|
36
|
+
/**
|
|
37
|
+
*
|
|
38
|
+
* @type {Array<TimeseriesPoint>}
|
|
39
|
+
* @memberof LabeledSeries
|
|
40
|
+
*/
|
|
41
|
+
points?: Array<TimeseriesPoint>;
|
|
42
|
+
}
|
|
43
|
+
export const LabeledSeriesPropertyValidationAttributesMap: {
|
|
44
|
+
[property: string]: {
|
|
45
|
+
maxLength?: number,
|
|
46
|
+
minLength?: number,
|
|
47
|
+
pattern?: string,
|
|
48
|
+
maximum?: number,
|
|
49
|
+
exclusiveMaximum?: boolean,
|
|
50
|
+
minimum?: number,
|
|
51
|
+
exclusiveMinimum?: boolean,
|
|
52
|
+
multipleOf?: number,
|
|
53
|
+
maxItems?: number,
|
|
54
|
+
minItems?: number,
|
|
55
|
+
uniqueItems?: boolean
|
|
56
|
+
}
|
|
57
|
+
} = {
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
* Check if a given object implements the LabeledSeries interface.
|
|
63
|
+
*/
|
|
64
|
+
export function instanceOfLabeledSeries(value: object): value is LabeledSeries {
|
|
65
|
+
if (!('label' in value) || value['label'] === undefined) return false;
|
|
66
|
+
return true;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
export function LabeledSeriesFromJSON(json: any): LabeledSeries {
|
|
70
|
+
return LabeledSeriesFromJSONTyped(json, false);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export function LabeledSeriesFromJSONTyped(json: any, ignoreDiscriminator: boolean): LabeledSeries {
|
|
74
|
+
if (json == null) {
|
|
75
|
+
return json;
|
|
76
|
+
}
|
|
77
|
+
return {
|
|
78
|
+
|
|
79
|
+
'label': json['label'],
|
|
80
|
+
'points': json['points'] == null ? undefined : ((json['points'] as Array<any>).map(TimeseriesPointFromJSON)),
|
|
81
|
+
};
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
export function LabeledSeriesToJSON(json: any): LabeledSeries {
|
|
85
|
+
return LabeledSeriesToJSONTyped(json, false);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
export function LabeledSeriesToJSONTyped(value?: LabeledSeries | null, ignoreDiscriminator: boolean = false): any {
|
|
89
|
+
if (value == null) {
|
|
90
|
+
return value;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
return {
|
|
94
|
+
|
|
95
|
+
'label': value['label'],
|
|
96
|
+
'points': value['points'] == null ? undefined : ((value['points'] as Array<any>).map(TimeseriesPointToJSON)),
|
|
97
|
+
};
|
|
98
|
+
}
|
|
99
|
+
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Knowledge Stack API
|
|
5
|
+
* Knowledge Stack backend API for authentication and knowledge management. ## Integrating (RPA / machine clients) **Base URL.** Knowledge Stack is self-hosted — point at your own deployment host (see `servers`). The `localhost` entry is for local development only. **Authentication.** Send `Authorization: Bearer <api-key>` on every request. Mint an API key once via `POST /v1/api-keys` from a signed-in browser session; the raw `sk-user-...` secret is returned **only** at creation, so store it then. A key inherits its owning user\'s live tenant role and path permissions — create RPA keys from a least-privilege user, and set `expires_at` for rotation. The `ks_uat` cookie scheme is browser-only and cannot be used by headless clients. **Async work is polled, not pushed.** There are no outbound webhooks. - `POST /v1/documents/ingest` returns `201` immediately with a `workflow_id`; poll `GET /v1/system-jobs/document_versions/{workflow_id}` until `status` is terminal (anything other than `pending`/`processing`). The `Location` response header points at this poll resource. - `POST /v1/workflow-runs/{run_id}/start` returns `202`; poll `GET /v1/workflow-runs/{run_id}` until `execution_state` is `COMPLETED` or `FAILED`. The `Location` header points at the run resource. - `POST /v1/agent/ask` is **synchronous** — it blocks until the agent finishes and returns the answer inline. Use a generous HTTP timeout. **Pagination.** List endpoints accept `limit`/`offset` and return `{items, total, limit, offset}`. **Errors.** Every non-2xx body is `{detail, code, request_id}`. `code` is a stable value from a closed set (see the `ErrorResponse` schema\'s `code` enum) — branch on it rather than parsing `detail`. Quota rejections return `429` with a `Retry-After` header; transient lock contention returns a retryable `503`. Quote `request_id` (also the `x-request-id` response header) to support. **Idempotency.** `POST /v1/workflow-runs` accepts an `idempotency_key` to dedupe retried run creation. `agent/ask` charges one message *before* running and does not refund a client-cancelled call.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 0.1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
* One ranked entry (a workflow definition or a user).
|
|
18
|
+
* @export
|
|
19
|
+
* @interface LeaderboardEntry
|
|
20
|
+
*/
|
|
21
|
+
export interface LeaderboardEntry {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof LeaderboardEntry
|
|
26
|
+
*/
|
|
27
|
+
id: string;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof LeaderboardEntry
|
|
32
|
+
*/
|
|
33
|
+
name: string;
|
|
34
|
+
/**
|
|
35
|
+
* Run count.
|
|
36
|
+
* @type {number}
|
|
37
|
+
* @memberof LeaderboardEntry
|
|
38
|
+
*/
|
|
39
|
+
count: number;
|
|
40
|
+
}
|
|
41
|
+
export const LeaderboardEntryPropertyValidationAttributesMap: {
|
|
42
|
+
[property: string]: {
|
|
43
|
+
maxLength?: number,
|
|
44
|
+
minLength?: number,
|
|
45
|
+
pattern?: string,
|
|
46
|
+
maximum?: number,
|
|
47
|
+
exclusiveMaximum?: boolean,
|
|
48
|
+
minimum?: number,
|
|
49
|
+
exclusiveMinimum?: boolean,
|
|
50
|
+
multipleOf?: number,
|
|
51
|
+
maxItems?: number,
|
|
52
|
+
minItems?: number,
|
|
53
|
+
uniqueItems?: boolean
|
|
54
|
+
}
|
|
55
|
+
} = {
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
/**
|
|
60
|
+
* Check if a given object implements the LeaderboardEntry interface.
|
|
61
|
+
*/
|
|
62
|
+
export function instanceOfLeaderboardEntry(value: object): value is LeaderboardEntry {
|
|
63
|
+
if (!('id' in value) || value['id'] === undefined) return false;
|
|
64
|
+
if (!('name' in value) || value['name'] === undefined) return false;
|
|
65
|
+
if (!('count' in value) || value['count'] === undefined) return false;
|
|
66
|
+
return true;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
export function LeaderboardEntryFromJSON(json: any): LeaderboardEntry {
|
|
70
|
+
return LeaderboardEntryFromJSONTyped(json, false);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export function LeaderboardEntryFromJSONTyped(json: any, ignoreDiscriminator: boolean): LeaderboardEntry {
|
|
74
|
+
if (json == null) {
|
|
75
|
+
return json;
|
|
76
|
+
}
|
|
77
|
+
return {
|
|
78
|
+
|
|
79
|
+
'id': json['id'],
|
|
80
|
+
'name': json['name'],
|
|
81
|
+
'count': json['count'],
|
|
82
|
+
};
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
export function LeaderboardEntryToJSON(json: any): LeaderboardEntry {
|
|
86
|
+
return LeaderboardEntryToJSONTyped(json, false);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
export function LeaderboardEntryToJSONTyped(value?: LeaderboardEntry | null, ignoreDiscriminator: boolean = false): any {
|
|
90
|
+
if (value == null) {
|
|
91
|
+
return value;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
return {
|
|
95
|
+
|
|
96
|
+
'id': value['id'],
|
|
97
|
+
'name': value['name'],
|
|
98
|
+
'count': value['count'],
|
|
99
|
+
};
|
|
100
|
+
}
|
|
101
|
+
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Knowledge Stack API
|
|
5
|
+
* Knowledge Stack backend API for authentication and knowledge management. ## Integrating (RPA / machine clients) **Base URL.** Knowledge Stack is self-hosted — point at your own deployment host (see `servers`). The `localhost` entry is for local development only. **Authentication.** Send `Authorization: Bearer <api-key>` on every request. Mint an API key once via `POST /v1/api-keys` from a signed-in browser session; the raw `sk-user-...` secret is returned **only** at creation, so store it then. A key inherits its owning user\'s live tenant role and path permissions — create RPA keys from a least-privilege user, and set `expires_at` for rotation. The `ks_uat` cookie scheme is browser-only and cannot be used by headless clients. **Async work is polled, not pushed.** There are no outbound webhooks. - `POST /v1/documents/ingest` returns `201` immediately with a `workflow_id`; poll `GET /v1/system-jobs/document_versions/{workflow_id}` until `status` is terminal (anything other than `pending`/`processing`). The `Location` response header points at this poll resource. - `POST /v1/workflow-runs/{run_id}/start` returns `202`; poll `GET /v1/workflow-runs/{run_id}` until `execution_state` is `COMPLETED` or `FAILED`. The `Location` header points at the run resource. - `POST /v1/agent/ask` is **synchronous** — it blocks until the agent finishes and returns the answer inline. Use a generous HTTP timeout. **Pagination.** List endpoints accept `limit`/`offset` and return `{items, total, limit, offset}`. **Errors.** Every non-2xx body is `{detail, code, request_id}`. `code` is a stable value from a closed set (see the `ErrorResponse` schema\'s `code` enum) — branch on it rather than parsing `detail`. Quota rejections return `429` with a `Retry-After` header; transient lock contention returns a retryable `503`. Quote `request_id` (also the `x-request-id` response header) to support. **Idempotency.** `POST /v1/workflow-runs` accepts an `idempotency_key` to dedupe retried run creation. `agent/ask` charges one message *before* running and does not refund a client-cancelled call.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 0.1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { TimeseriesPoint } from './TimeseriesPoint';
|
|
17
|
+
import {
|
|
18
|
+
TimeseriesPointFromJSON,
|
|
19
|
+
TimeseriesPointFromJSONTyped,
|
|
20
|
+
TimeseriesPointToJSON,
|
|
21
|
+
TimeseriesPointToJSONTyped,
|
|
22
|
+
} from './TimeseriesPoint';
|
|
23
|
+
import type { TimeBucket } from './TimeBucket';
|
|
24
|
+
import {
|
|
25
|
+
TimeBucketFromJSON,
|
|
26
|
+
TimeBucketFromJSONTyped,
|
|
27
|
+
TimeBucketToJSON,
|
|
28
|
+
TimeBucketToJSONTyped,
|
|
29
|
+
} from './TimeBucket';
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* Workflow runs bucketed over time.
|
|
33
|
+
* @export
|
|
34
|
+
* @interface RunTimeseriesResponse
|
|
35
|
+
*/
|
|
36
|
+
export interface RunTimeseriesResponse {
|
|
37
|
+
/**
|
|
38
|
+
* IANA timezone the buckets are in.
|
|
39
|
+
* @type {string}
|
|
40
|
+
* @memberof RunTimeseriesResponse
|
|
41
|
+
*/
|
|
42
|
+
timezone: string;
|
|
43
|
+
/**
|
|
44
|
+
*
|
|
45
|
+
* @type {TimeBucket}
|
|
46
|
+
* @memberof RunTimeseriesResponse
|
|
47
|
+
*/
|
|
48
|
+
bucket: TimeBucket;
|
|
49
|
+
/**
|
|
50
|
+
*
|
|
51
|
+
* @type {Array<TimeseriesPoint>}
|
|
52
|
+
* @memberof RunTimeseriesResponse
|
|
53
|
+
*/
|
|
54
|
+
points?: Array<TimeseriesPoint>;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
export const RunTimeseriesResponsePropertyValidationAttributesMap: {
|
|
59
|
+
[property: string]: {
|
|
60
|
+
maxLength?: number,
|
|
61
|
+
minLength?: number,
|
|
62
|
+
pattern?: string,
|
|
63
|
+
maximum?: number,
|
|
64
|
+
exclusiveMaximum?: boolean,
|
|
65
|
+
minimum?: number,
|
|
66
|
+
exclusiveMinimum?: boolean,
|
|
67
|
+
multipleOf?: number,
|
|
68
|
+
maxItems?: number,
|
|
69
|
+
minItems?: number,
|
|
70
|
+
uniqueItems?: boolean
|
|
71
|
+
}
|
|
72
|
+
} = {
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
/**
|
|
77
|
+
* Check if a given object implements the RunTimeseriesResponse interface.
|
|
78
|
+
*/
|
|
79
|
+
export function instanceOfRunTimeseriesResponse(value: object): value is RunTimeseriesResponse {
|
|
80
|
+
if (!('timezone' in value) || value['timezone'] === undefined) return false;
|
|
81
|
+
if (!('bucket' in value) || value['bucket'] === undefined) return false;
|
|
82
|
+
return true;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
export function RunTimeseriesResponseFromJSON(json: any): RunTimeseriesResponse {
|
|
86
|
+
return RunTimeseriesResponseFromJSONTyped(json, false);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
export function RunTimeseriesResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): RunTimeseriesResponse {
|
|
90
|
+
if (json == null) {
|
|
91
|
+
return json;
|
|
92
|
+
}
|
|
93
|
+
return {
|
|
94
|
+
|
|
95
|
+
'timezone': json['timezone'],
|
|
96
|
+
'bucket': TimeBucketFromJSON(json['bucket']),
|
|
97
|
+
'points': json['points'] == null ? undefined : ((json['points'] as Array<any>).map(TimeseriesPointFromJSON)),
|
|
98
|
+
};
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
export function RunTimeseriesResponseToJSON(json: any): RunTimeseriesResponse {
|
|
102
|
+
return RunTimeseriesResponseToJSONTyped(json, false);
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
export function RunTimeseriesResponseToJSONTyped(value?: RunTimeseriesResponse | null, ignoreDiscriminator: boolean = false): any {
|
|
106
|
+
if (value == null) {
|
|
107
|
+
return value;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
return {
|
|
111
|
+
|
|
112
|
+
'timezone': value['timezone'],
|
|
113
|
+
'bucket': TimeBucketToJSON(value['bucket']),
|
|
114
|
+
'points': value['points'] == null ? undefined : ((value['points'] as Array<any>).map(TimeseriesPointToJSON)),
|
|
115
|
+
};
|
|
116
|
+
}
|
|
117
|
+
|
|
@@ -20,6 +20,13 @@ import {
|
|
|
20
20
|
ItemPermissionsToJSON,
|
|
21
21
|
ItemPermissionsToJSONTyped,
|
|
22
22
|
} from './ItemPermissions';
|
|
23
|
+
import type { SkillScriptFile } from './SkillScriptFile';
|
|
24
|
+
import {
|
|
25
|
+
SkillScriptFileFromJSON,
|
|
26
|
+
SkillScriptFileFromJSONTyped,
|
|
27
|
+
SkillScriptFileToJSON,
|
|
28
|
+
SkillScriptFileToJSONTyped,
|
|
29
|
+
} from './SkillScriptFile';
|
|
23
30
|
import type { PathPartApprovalState } from './PathPartApprovalState';
|
|
24
31
|
import {
|
|
25
32
|
PathPartApprovalStateFromJSON,
|
|
@@ -101,6 +108,12 @@ export interface SkillResponse {
|
|
|
101
108
|
* @memberof SkillResponse
|
|
102
109
|
*/
|
|
103
110
|
scriptNames?: Array<string>;
|
|
111
|
+
/**
|
|
112
|
+
* Bundled scripts with their contents; populated only on the detail read (GET /skills/{id}), null on list. Lets the editor read the current script set so a PATCH can safely resubmit the whole set.
|
|
113
|
+
* @type {Array<SkillScriptFile>}
|
|
114
|
+
* @memberof SkillResponse
|
|
115
|
+
*/
|
|
116
|
+
scripts?: Array<SkillScriptFile> | null;
|
|
104
117
|
/**
|
|
105
118
|
* Whether the working copy differs from the active published version. Always present (incl. list responses) so the UI can flag a skill with an unpublished draft.
|
|
106
119
|
* @type {boolean}
|
|
@@ -203,6 +216,7 @@ export function SkillResponseFromJSONTyped(json: any, ignoreDiscriminator: boole
|
|
|
203
216
|
'description': json['description'],
|
|
204
217
|
'skillMd': json['skill_md'] == null ? undefined : json['skill_md'],
|
|
205
218
|
'scriptNames': json['script_names'] == null ? undefined : json['script_names'],
|
|
219
|
+
'scripts': json['scripts'] == null ? undefined : ((json['scripts'] as Array<any>).map(SkillScriptFileFromJSON)),
|
|
206
220
|
'hasUnpublishedChanges': json['has_unpublished_changes'] == null ? undefined : json['has_unpublished_changes'],
|
|
207
221
|
'approvalState': PathPartApprovalStateFromJSON(json['approval_state']),
|
|
208
222
|
'owner': json['owner'] == null ? undefined : UserInfoFromJSON(json['owner']),
|
|
@@ -233,6 +247,7 @@ export function SkillResponseToJSONTyped(value?: SkillResponse | null, ignoreDis
|
|
|
233
247
|
'description': value['description'],
|
|
234
248
|
'skill_md': value['skillMd'],
|
|
235
249
|
'script_names': value['scriptNames'],
|
|
250
|
+
'scripts': value['scripts'] == null ? undefined : ((value['scripts'] as Array<any>).map(SkillScriptFileToJSON)),
|
|
236
251
|
'has_unpublished_changes': value['hasUnpublishedChanges'],
|
|
237
252
|
'approval_state': PathPartApprovalStateToJSON(value['approvalState']),
|
|
238
253
|
'owner': UserInfoToJSON(value['owner']),
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Knowledge Stack API
|
|
5
|
+
* Knowledge Stack backend API for authentication and knowledge management. ## Integrating (RPA / machine clients) **Base URL.** Knowledge Stack is self-hosted — point at your own deployment host (see `servers`). The `localhost` entry is for local development only. **Authentication.** Send `Authorization: Bearer <api-key>` on every request. Mint an API key once via `POST /v1/api-keys` from a signed-in browser session; the raw `sk-user-...` secret is returned **only** at creation, so store it then. A key inherits its owning user\'s live tenant role and path permissions — create RPA keys from a least-privilege user, and set `expires_at` for rotation. The `ks_uat` cookie scheme is browser-only and cannot be used by headless clients. **Async work is polled, not pushed.** There are no outbound webhooks. - `POST /v1/documents/ingest` returns `201` immediately with a `workflow_id`; poll `GET /v1/system-jobs/document_versions/{workflow_id}` until `status` is terminal (anything other than `pending`/`processing`). The `Location` response header points at this poll resource. - `POST /v1/workflow-runs/{run_id}/start` returns `202`; poll `GET /v1/workflow-runs/{run_id}` until `execution_state` is `COMPLETED` or `FAILED`. The `Location` header points at the run resource. - `POST /v1/agent/ask` is **synchronous** — it blocks until the agent finishes and returns the answer inline. Use a generous HTTP timeout. **Pagination.** List endpoints accept `limit`/`offset` and return `{items, total, limit, offset}`. **Errors.** Every non-2xx body is `{detail, code, request_id}`. `code` is a stable value from a closed set (see the `ErrorResponse` schema\'s `code` enum) — branch on it rather than parsing `detail`. Quota rejections return `429` with a `Retry-After` header; transient lock contention returns a retryable `503`. Quote `request_id` (also the `x-request-id` response header) to support. **Idempotency.** `POST /v1/workflow-runs` accepts an `idempotency_key` to dedupe retried run creation. `agent/ask` charges one message *before* running and does not refund a client-cancelled call.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 0.1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* Granularity for a bucketed time series.
|
|
18
|
+
* @export
|
|
19
|
+
*/
|
|
20
|
+
export const TimeBucket = {
|
|
21
|
+
Hour: 'hour',
|
|
22
|
+
Day: 'day',
|
|
23
|
+
Week: 'week',
|
|
24
|
+
Month: 'month'
|
|
25
|
+
} as const;
|
|
26
|
+
export type TimeBucket = typeof TimeBucket[keyof typeof TimeBucket];
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
export function instanceOfTimeBucket(value: any): boolean {
|
|
30
|
+
for (const key in TimeBucket) {
|
|
31
|
+
if (Object.prototype.hasOwnProperty.call(TimeBucket, key)) {
|
|
32
|
+
if (TimeBucket[key as keyof typeof TimeBucket] === value) {
|
|
33
|
+
return true;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
return false;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
export function TimeBucketFromJSON(json: any): TimeBucket {
|
|
41
|
+
return TimeBucketFromJSONTyped(json, false);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export function TimeBucketFromJSONTyped(json: any, ignoreDiscriminator: boolean): TimeBucket {
|
|
45
|
+
return json as TimeBucket;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
export function TimeBucketToJSON(value?: TimeBucket | null): any {
|
|
49
|
+
return value as any;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
export function TimeBucketToJSONTyped(value: any, ignoreDiscriminator: boolean): TimeBucket {
|
|
53
|
+
return value as TimeBucket;
|
|
54
|
+
}
|
|
55
|
+
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Knowledge Stack API
|
|
5
|
+
* Knowledge Stack backend API for authentication and knowledge management. ## Integrating (RPA / machine clients) **Base URL.** Knowledge Stack is self-hosted — point at your own deployment host (see `servers`). The `localhost` entry is for local development only. **Authentication.** Send `Authorization: Bearer <api-key>` on every request. Mint an API key once via `POST /v1/api-keys` from a signed-in browser session; the raw `sk-user-...` secret is returned **only** at creation, so store it then. A key inherits its owning user\'s live tenant role and path permissions — create RPA keys from a least-privilege user, and set `expires_at` for rotation. The `ks_uat` cookie scheme is browser-only and cannot be used by headless clients. **Async work is polled, not pushed.** There are no outbound webhooks. - `POST /v1/documents/ingest` returns `201` immediately with a `workflow_id`; poll `GET /v1/system-jobs/document_versions/{workflow_id}` until `status` is terminal (anything other than `pending`/`processing`). The `Location` response header points at this poll resource. - `POST /v1/workflow-runs/{run_id}/start` returns `202`; poll `GET /v1/workflow-runs/{run_id}` until `execution_state` is `COMPLETED` or `FAILED`. The `Location` header points at the run resource. - `POST /v1/agent/ask` is **synchronous** — it blocks until the agent finishes and returns the answer inline. Use a generous HTTP timeout. **Pagination.** List endpoints accept `limit`/`offset` and return `{items, total, limit, offset}`. **Errors.** Every non-2xx body is `{detail, code, request_id}`. `code` is a stable value from a closed set (see the `ErrorResponse` schema\'s `code` enum) — branch on it rather than parsing `detail`. Quota rejections return `429` with a `Retry-After` header; transient lock contention returns a retryable `503`. Quote `request_id` (also the `x-request-id` response header) to support. **Idempotency.** `POST /v1/workflow-runs` accepts an `idempotency_key` to dedupe retried run creation. `agent/ask` charges one message *before* running and does not refund a client-cancelled call.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 0.1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
* One bucket of a time series.
|
|
18
|
+
* @export
|
|
19
|
+
* @interface TimeseriesPoint
|
|
20
|
+
*/
|
|
21
|
+
export interface TimeseriesPoint {
|
|
22
|
+
/**
|
|
23
|
+
* Start of the bucket, in the resolved timezone.
|
|
24
|
+
* @type {Date}
|
|
25
|
+
* @memberof TimeseriesPoint
|
|
26
|
+
*/
|
|
27
|
+
bucketStart: Date;
|
|
28
|
+
/**
|
|
29
|
+
* Row count in this bucket.
|
|
30
|
+
* @type {number}
|
|
31
|
+
* @memberof TimeseriesPoint
|
|
32
|
+
*/
|
|
33
|
+
count: number;
|
|
34
|
+
}
|
|
35
|
+
export const TimeseriesPointPropertyValidationAttributesMap: {
|
|
36
|
+
[property: string]: {
|
|
37
|
+
maxLength?: number,
|
|
38
|
+
minLength?: number,
|
|
39
|
+
pattern?: string,
|
|
40
|
+
maximum?: number,
|
|
41
|
+
exclusiveMaximum?: boolean,
|
|
42
|
+
minimum?: number,
|
|
43
|
+
exclusiveMinimum?: boolean,
|
|
44
|
+
multipleOf?: number,
|
|
45
|
+
maxItems?: number,
|
|
46
|
+
minItems?: number,
|
|
47
|
+
uniqueItems?: boolean
|
|
48
|
+
}
|
|
49
|
+
} = {
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* Check if a given object implements the TimeseriesPoint interface.
|
|
55
|
+
*/
|
|
56
|
+
export function instanceOfTimeseriesPoint(value: object): value is TimeseriesPoint {
|
|
57
|
+
if (!('bucketStart' in value) || value['bucketStart'] === undefined) return false;
|
|
58
|
+
if (!('count' in value) || value['count'] === undefined) return false;
|
|
59
|
+
return true;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
export function TimeseriesPointFromJSON(json: any): TimeseriesPoint {
|
|
63
|
+
return TimeseriesPointFromJSONTyped(json, false);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export function TimeseriesPointFromJSONTyped(json: any, ignoreDiscriminator: boolean): TimeseriesPoint {
|
|
67
|
+
if (json == null) {
|
|
68
|
+
return json;
|
|
69
|
+
}
|
|
70
|
+
return {
|
|
71
|
+
|
|
72
|
+
'bucketStart': (new Date(json['bucket_start'])),
|
|
73
|
+
'count': json['count'],
|
|
74
|
+
};
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
export function TimeseriesPointToJSON(json: any): TimeseriesPoint {
|
|
78
|
+
return TimeseriesPointToJSONTyped(json, false);
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
export function TimeseriesPointToJSONTyped(value?: TimeseriesPoint | null, ignoreDiscriminator: boolean = false): any {
|
|
82
|
+
if (value == null) {
|
|
83
|
+
return value;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
return {
|
|
87
|
+
|
|
88
|
+
'bucket_start': value['bucketStart'].toISOString(),
|
|
89
|
+
'count': value['count'],
|
|
90
|
+
};
|
|
91
|
+
}
|
|
92
|
+
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Knowledge Stack API
|
|
5
|
+
* Knowledge Stack backend API for authentication and knowledge management. ## Integrating (RPA / machine clients) **Base URL.** Knowledge Stack is self-hosted — point at your own deployment host (see `servers`). The `localhost` entry is for local development only. **Authentication.** Send `Authorization: Bearer <api-key>` on every request. Mint an API key once via `POST /v1/api-keys` from a signed-in browser session; the raw `sk-user-...` secret is returned **only** at creation, so store it then. A key inherits its owning user\'s live tenant role and path permissions — create RPA keys from a least-privilege user, and set `expires_at` for rotation. The `ks_uat` cookie scheme is browser-only and cannot be used by headless clients. **Async work is polled, not pushed.** There are no outbound webhooks. - `POST /v1/documents/ingest` returns `201` immediately with a `workflow_id`; poll `GET /v1/system-jobs/document_versions/{workflow_id}` until `status` is terminal (anything other than `pending`/`processing`). The `Location` response header points at this poll resource. - `POST /v1/workflow-runs/{run_id}/start` returns `202`; poll `GET /v1/workflow-runs/{run_id}` until `execution_state` is `COMPLETED` or `FAILED`. The `Location` header points at the run resource. - `POST /v1/agent/ask` is **synchronous** — it blocks until the agent finishes and returns the answer inline. Use a generous HTTP timeout. **Pagination.** List endpoints accept `limit`/`offset` and return `{items, total, limit, offset}`. **Errors.** Every non-2xx body is `{detail, code, request_id}`. `code` is a stable value from a closed set (see the `ErrorResponse` schema\'s `code` enum) — branch on it rather than parsing `detail`. Quota rejections return `429` with a `Retry-After` header; transient lock contention returns a retryable `503`. Quote `request_id` (also the `x-request-id` response header) to support. **Idempotency.** `POST /v1/workflow-runs` accepts an `idempotency_key` to dedupe retried run creation. `agent/ask` charges one message *before* running and does not refund a client-cancelled call.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 0.1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { LeaderboardEntry } from './LeaderboardEntry';
|
|
17
|
+
import {
|
|
18
|
+
LeaderboardEntryFromJSON,
|
|
19
|
+
LeaderboardEntryFromJSONTyped,
|
|
20
|
+
LeaderboardEntryToJSON,
|
|
21
|
+
LeaderboardEntryToJSONTyped,
|
|
22
|
+
} from './LeaderboardEntry';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* Top workflows and top users by run count over a window.
|
|
26
|
+
* @export
|
|
27
|
+
* @interface WorkflowLeaderboardResponse
|
|
28
|
+
*/
|
|
29
|
+
export interface WorkflowLeaderboardResponse {
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {Array<LeaderboardEntry>}
|
|
33
|
+
* @memberof WorkflowLeaderboardResponse
|
|
34
|
+
*/
|
|
35
|
+
topWorkflows?: Array<LeaderboardEntry>;
|
|
36
|
+
/**
|
|
37
|
+
*
|
|
38
|
+
* @type {Array<LeaderboardEntry>}
|
|
39
|
+
* @memberof WorkflowLeaderboardResponse
|
|
40
|
+
*/
|
|
41
|
+
topUsers?: Array<LeaderboardEntry>;
|
|
42
|
+
}
|
|
43
|
+
export const WorkflowLeaderboardResponsePropertyValidationAttributesMap: {
|
|
44
|
+
[property: string]: {
|
|
45
|
+
maxLength?: number,
|
|
46
|
+
minLength?: number,
|
|
47
|
+
pattern?: string,
|
|
48
|
+
maximum?: number,
|
|
49
|
+
exclusiveMaximum?: boolean,
|
|
50
|
+
minimum?: number,
|
|
51
|
+
exclusiveMinimum?: boolean,
|
|
52
|
+
multipleOf?: number,
|
|
53
|
+
maxItems?: number,
|
|
54
|
+
minItems?: number,
|
|
55
|
+
uniqueItems?: boolean
|
|
56
|
+
}
|
|
57
|
+
} = {
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
* Check if a given object implements the WorkflowLeaderboardResponse interface.
|
|
63
|
+
*/
|
|
64
|
+
export function instanceOfWorkflowLeaderboardResponse(value: object): value is WorkflowLeaderboardResponse {
|
|
65
|
+
return true;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
export function WorkflowLeaderboardResponseFromJSON(json: any): WorkflowLeaderboardResponse {
|
|
69
|
+
return WorkflowLeaderboardResponseFromJSONTyped(json, false);
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
export function WorkflowLeaderboardResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): WorkflowLeaderboardResponse {
|
|
73
|
+
if (json == null) {
|
|
74
|
+
return json;
|
|
75
|
+
}
|
|
76
|
+
return {
|
|
77
|
+
|
|
78
|
+
'topWorkflows': json['top_workflows'] == null ? undefined : ((json['top_workflows'] as Array<any>).map(LeaderboardEntryFromJSON)),
|
|
79
|
+
'topUsers': json['top_users'] == null ? undefined : ((json['top_users'] as Array<any>).map(LeaderboardEntryFromJSON)),
|
|
80
|
+
};
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
export function WorkflowLeaderboardResponseToJSON(json: any): WorkflowLeaderboardResponse {
|
|
84
|
+
return WorkflowLeaderboardResponseToJSONTyped(json, false);
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
export function WorkflowLeaderboardResponseToJSONTyped(value?: WorkflowLeaderboardResponse | null, ignoreDiscriminator: boolean = false): any {
|
|
88
|
+
if (value == null) {
|
|
89
|
+
return value;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
return {
|
|
93
|
+
|
|
94
|
+
'top_workflows': value['topWorkflows'] == null ? undefined : ((value['topWorkflows'] as Array<any>).map(LeaderboardEntryToJSON)),
|
|
95
|
+
'top_users': value['topUsers'] == null ? undefined : ((value['topUsers'] as Array<any>).map(LeaderboardEntryToJSON)),
|
|
96
|
+
};
|
|
97
|
+
}
|
|
98
|
+
|