@knowledge-stack/ksapi 2.14.3 → 2.15.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 +2 -0
- package/README.md +4 -2
- package/dist/apis/ApiConnectionsApi.d.ts +8 -8
- package/dist/apis/ApiConnectionsApi.js +4 -4
- package/dist/apis/DataSourcesApi.d.ts +4 -4
- package/dist/apis/DataSourcesApi.js +2 -2
- package/dist/apis/SkillsApi.d.ts +39 -1
- package/dist/apis/SkillsApi.js +49 -0
- package/dist/esm/apis/ApiConnectionsApi.d.ts +8 -8
- package/dist/esm/apis/ApiConnectionsApi.js +4 -4
- package/dist/esm/apis/DataSourcesApi.d.ts +4 -4
- package/dist/esm/apis/DataSourcesApi.js +2 -2
- package/dist/esm/apis/SkillsApi.d.ts +39 -1
- package/dist/esm/apis/SkillsApi.js +50 -1
- package/dist/esm/models/ExportSkillsRequest.d.ts +47 -0
- package/dist/esm/models/ExportSkillsRequest.js +50 -0
- package/dist/esm/models/index.d.ts +1 -0
- package/dist/esm/models/index.js +1 -0
- package/dist/models/ExportSkillsRequest.d.ts +47 -0
- package/dist/models/ExportSkillsRequest.js +58 -0
- package/dist/models/index.d.ts +1 -0
- package/dist/models/index.js +1 -0
- package/docs/ApiConnectionsApi.md +2 -2
- package/docs/DataSourcesApi.md +1 -1
- package/docs/ExportSkillsRequest.md +35 -0
- package/docs/SkillsApi.md +76 -0
- package/package.json +1 -1
- package/src/apis/ApiConnectionsApi.ts +8 -8
- package/src/apis/DataSourcesApi.ts +4 -4
- package/src/apis/SkillsApi.ts +88 -0
- package/src/models/ExportSkillsRequest.ts +88 -0
- package/src/models/index.ts +1 -0
|
@@ -0,0 +1,88 @@
|
|
|
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
|
+
* Skills to pack into one ZIP, each under a top-level folder named after it.
|
|
18
|
+
* @export
|
|
19
|
+
* @interface ExportSkillsRequest
|
|
20
|
+
*/
|
|
21
|
+
export interface ExportSkillsRequest {
|
|
22
|
+
/**
|
|
23
|
+
* Skills whose frozen active versions are packed together; duplicates are ignored. Every skill must exist and be readable.
|
|
24
|
+
* @type {Array<string>}
|
|
25
|
+
* @memberof ExportSkillsRequest
|
|
26
|
+
*/
|
|
27
|
+
skillIds: Array<string>;
|
|
28
|
+
}
|
|
29
|
+
export const ExportSkillsRequestPropertyValidationAttributesMap: {
|
|
30
|
+
[property: string]: {
|
|
31
|
+
maxLength?: number,
|
|
32
|
+
minLength?: number,
|
|
33
|
+
pattern?: string,
|
|
34
|
+
maximum?: number,
|
|
35
|
+
exclusiveMaximum?: boolean,
|
|
36
|
+
minimum?: number,
|
|
37
|
+
exclusiveMinimum?: boolean,
|
|
38
|
+
multipleOf?: number,
|
|
39
|
+
maxItems?: number,
|
|
40
|
+
minItems?: number,
|
|
41
|
+
uniqueItems?: boolean
|
|
42
|
+
}
|
|
43
|
+
} = {
|
|
44
|
+
skillIds: {
|
|
45
|
+
maxItems: 50,
|
|
46
|
+
minItems: 1,
|
|
47
|
+
uniqueItems: false,
|
|
48
|
+
},
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* Check if a given object implements the ExportSkillsRequest interface.
|
|
54
|
+
*/
|
|
55
|
+
export function instanceOfExportSkillsRequest(value: object): value is ExportSkillsRequest {
|
|
56
|
+
if (!('skillIds' in value) || value['skillIds'] === undefined) return false;
|
|
57
|
+
return true;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export function ExportSkillsRequestFromJSON(json: any): ExportSkillsRequest {
|
|
61
|
+
return ExportSkillsRequestFromJSONTyped(json, false);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
export function ExportSkillsRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): ExportSkillsRequest {
|
|
65
|
+
if (json == null) {
|
|
66
|
+
return json;
|
|
67
|
+
}
|
|
68
|
+
return {
|
|
69
|
+
|
|
70
|
+
'skillIds': json['skill_ids'],
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
export function ExportSkillsRequestToJSON(json: any): ExportSkillsRequest {
|
|
75
|
+
return ExportSkillsRequestToJSONTyped(json, false);
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
export function ExportSkillsRequestToJSONTyped(value?: ExportSkillsRequest | null, ignoreDiscriminator: boolean = false): any {
|
|
79
|
+
if (value == null) {
|
|
80
|
+
return value;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
return {
|
|
84
|
+
|
|
85
|
+
'skill_ids': value['skillIds'],
|
|
86
|
+
};
|
|
87
|
+
}
|
|
88
|
+
|
package/src/models/index.ts
CHANGED
|
@@ -138,6 +138,7 @@ export * from './EnrichedThreadMessageContent';
|
|
|
138
138
|
export * from './ErrorResponse';
|
|
139
139
|
export * from './EventResponse';
|
|
140
140
|
export * from './ExcludedCommonFile';
|
|
141
|
+
export * from './ExportSkillsRequest';
|
|
141
142
|
export * from './ExtractRequest';
|
|
142
143
|
export * from './ExtractResponse';
|
|
143
144
|
export * from './FeaturesResponse';
|