@squidcloud/client 1.0.472 → 1.0.474
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/dist/cjs/index.js +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/internal-common/src/metric-name.d.ts +14 -0
- package/dist/internal-common/src/public-types/ai-agent-integrations.public-types.d.ts +17 -0
- package/dist/internal-common/src/public-types/ai-agent.public-types.d.ts +84 -3
- package/dist/internal-common/src/public-types/ai-common.public-types.d.ts +3 -3
- package/dist/internal-common/src/public-types/ai-knowledge-base.public-types.d.ts +66 -11
- package/dist/internal-common/src/public-types/connector.public-types.d.ts +12 -0
- package/dist/internal-common/src/public-types-backend/api-call.public-context.d.ts +30 -0
- package/dist/internal-common/src/public-types-backend/mutation.public-context.d.ts +148 -0
- package/dist/internal-common/src/public-types-backend/native-query.public-context.d.ts +72 -0
- package/dist/internal-common/src/public-types-backend/query.public-context.d.ts +190 -0
- package/dist/internal-common/src/types/ai-agent.types.d.ts +242 -0
- package/dist/internal-common/src/types/ai-knowledge-base.types.d.ts +202 -0
- package/dist/internal-common/src/types/ai-matchmaking.types.d.ts +59 -0
- package/dist/internal-common/src/types/backend-function.types.d.ts +1 -0
- package/dist/internal-common/src/types/communication.types.d.ts +1 -0
- package/dist/internal-common/src/types/document.types.d.ts +1 -0
- package/dist/internal-common/src/types/file.types.d.ts +6 -0
- package/dist/internal-common/src/types/headers.types.d.ts +17 -0
- package/dist/internal-common/src/types/management-api-key.types.d.ts +92 -0
- package/dist/internal-common/src/types/mutation.types.d.ts +1 -0
- package/dist/internal-common/src/types/notification.types.d.ts +5 -0
- package/dist/internal-common/src/types/observability.types.d.ts +162 -0
- package/dist/internal-common/src/types/query.types.d.ts +15 -0
- package/dist/internal-common/src/types/secret.types.d.ts +7 -0
- package/dist/internal-common/src/types/socket.types.d.ts +1 -0
- package/dist/internal-common/src/types/stage.d.ts +9 -0
- package/dist/internal-common/src/types/time-units.d.ts +1 -0
- package/dist/internal-common/src/types/url-shortener.types.d.ts +45 -0
- package/dist/internal-common/src/utils/array.d.ts +7 -0
- package/dist/internal-common/src/utils/e2e-test-utils.d.ts +2 -0
- package/dist/internal-common/src/utils/file-utils.d.ts +2 -0
- package/dist/internal-common/src/utils/global.utils.d.ts +1 -0
- package/dist/internal-common/src/utils/http.d.ts +11 -0
- package/dist/internal-common/src/utils/lock.manager.d.ts +14 -0
- package/dist/internal-common/src/utils/metric-utils.d.ts +4 -0
- package/dist/internal-common/src/utils/metrics.types.d.ts +7 -0
- package/dist/internal-common/src/utils/object.d.ts +86 -0
- package/dist/internal-common/src/utils/serialization.d.ts +18 -0
- package/dist/internal-common/src/utils/squid.constants.d.ts +6 -0
- package/dist/internal-common/src/utils/trace-id-generator.d.ts +1 -0
- package/dist/internal-common/src/utils/validation.d.ts +19 -0
- package/dist/internal-common/src/websocket.impl.d.ts +26 -0
- package/dist/typescript-client/src/admin-client.d.ts +7 -1
- package/dist/typescript-client/src/ai-client.d.ts +4 -1
- package/dist/typescript-client/src/ai-knowledge-base/ai-knowledge-base-client-reference.d.ts +9 -1
- package/dist/typescript-client/src/connector-client.d.ts +32 -0
- package/dist/typescript-client/src/index.d.ts +1 -0
- package/dist/typescript-client/src/public-types.d.ts +1 -0
- package/dist/typescript-client/src/version.d.ts +1 -1
- package/package.json +1 -2
|
@@ -90,6 +90,9 @@ export declare class AiClient {
|
|
|
90
90
|
* understand and respond to, taking into account the nature of the task or the information
|
|
91
91
|
* sought.
|
|
92
92
|
* @param options Additional options to customize the query execution.
|
|
93
|
+
* @param abortSignal Optional signal used to abort the underlying request. When the signal aborts, the in-flight
|
|
94
|
+
* HTTP request is cancelled and its promise rejects, allowing callers to bound a single call
|
|
95
|
+
* without leaking the request.
|
|
93
96
|
* @returns A promise that resolves to an `ExecuteAiQueryResponse`. This response includes the AI's
|
|
94
97
|
* reply to the provided prompt, along with any other relevant information that is part of
|
|
95
98
|
* the AI's response. The promise can be awaited to handle the response asynchronously.
|
|
@@ -105,7 +108,7 @@ export declare class AiClient {
|
|
|
105
108
|
* For more details on the usage and capabilities of the AI Assistant, refer to the documentation provided at
|
|
106
109
|
* {@link https://docs.squid.cloud/docs/ai}.
|
|
107
110
|
*/
|
|
108
|
-
executeAiQuery(integrationId: IntegrationId, prompt: string, options?: AiQueryOptions): Promise<AiQueryResponse>;
|
|
111
|
+
executeAiQuery(integrationId: IntegrationId, prompt: string, options?: AiQueryOptions, abortSignal?: AbortSignal): Promise<AiQueryResponse>;
|
|
109
112
|
/**
|
|
110
113
|
* Executes an AI-powered API call using a specific integration.
|
|
111
114
|
* The AI will select appropriate endpoints, generate request bodies,
|
package/dist/typescript-client/src/ai-knowledge-base/ai-knowledge-base-client-reference.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AiEmbeddingsModelWithOptionalFields, AiKnowledgeBase, AiKnowledgeBaseChatOptions, AiKnowledgeBaseContext, AiKnowledgeBaseContextRequest, AiKnowledgeBaseContextWithReasoning, AiKnowledgeBaseDownloadContextResponse, AiKnowledgeBaseSearchContextsWithContextIdRequest, AiKnowledgeBaseSearchContextsWithPromptRequest, AiKnowledgeBaseSearchResultChunk, UpsertKnowledgeBaseContextResponse, UpsertKnowledgeBaseContextsResponse } from '../../../internal-common/src/public-types/ai-knowledge-base.public-types';
|
|
1
|
+
import { AiEmbeddingsModelWithOptionalFields, AiKnowledgeBase, AiKnowledgeBaseChatOptions, AiKnowledgeBaseContext, AiKnowledgeBaseContextRequest, AiKnowledgeBaseContextWithReasoning, AiKnowledgeBaseDownloadContextResponse, AiKnowledgeBaseSearchContextsWithContextIdRequest, AiKnowledgeBaseSearchContextsWithPromptRequest, AiKnowledgeBaseSearchResultChunk, GenerateMetadataFieldDescriptionsRequest, GenerateMetadataFieldDescriptionsResponse, UpsertKnowledgeBaseContextResponse, UpsertKnowledgeBaseContextsResponse } from '../../../internal-common/src/public-types/ai-knowledge-base.public-types';
|
|
2
2
|
import { AiContextId } from '../../../internal-common/src/public-types/communication.public-types';
|
|
3
3
|
/**
|
|
4
4
|
* Parameters for creating or updating an AI agent.
|
|
@@ -28,6 +28,14 @@ export declare class AiKnowledgeBaseReference {
|
|
|
28
28
|
* @param knowledgeBase
|
|
29
29
|
*/
|
|
30
30
|
upsertKnowledgeBase(knowledgeBase: Omit<AiEmbeddingsModelWithOptionalFields, 'id' | 'appId' | 'updatedAt'>): Promise<void>;
|
|
31
|
+
/**
|
|
32
|
+
* AI-generates descriptions for this knowledge base's metadata fields and returns them WITHOUT
|
|
33
|
+
* persisting — the caller saves them onto the KB (e.g. via `upsertKnowledgeBase`). By default only
|
|
34
|
+
* fields with an empty description are generated; pass `overwriteExisting` to regenerate all.
|
|
35
|
+
* @param options Optional `fieldNames` to limit generation to specific fields, and `overwriteExisting`.
|
|
36
|
+
* @returns The (re)generated fields with their new descriptions (not yet persisted).
|
|
37
|
+
*/
|
|
38
|
+
generateMetadataFieldDescriptions(options?: Omit<GenerateMetadataFieldDescriptionsRequest, 'knowledgeBaseId'>): Promise<GenerateMetadataFieldDescriptionsResponse>;
|
|
31
39
|
/**
|
|
32
40
|
* Deletes the AI knowledge base.
|
|
33
41
|
* @returns A promise that resolves when the deletion is complete.
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { ConnectorId } from './public-types';
|
|
2
|
+
/**
|
|
3
|
+
* ConnectorClient manages app-level (integration-less) connectors attached to an application.
|
|
4
|
+
*
|
|
5
|
+
* Unlike integrations, these connectors carry no per-connector configuration record — attaching one
|
|
6
|
+
* simply adds it to the application's `appConnectors` list and (re)deploys its bundle. Any configuration
|
|
7
|
+
* the connector needs is provided out of band (e.g. via application secrets).
|
|
8
|
+
* @category Platform
|
|
9
|
+
*/
|
|
10
|
+
export declare class ConnectorClient {
|
|
11
|
+
private readonly rpcManager;
|
|
12
|
+
private readonly iacBaseUrl;
|
|
13
|
+
/**
|
|
14
|
+
* Lists the connectors explicitly attached to the application.
|
|
15
|
+
*
|
|
16
|
+
* @returns A promise that resolves with the list of attached connector ids.
|
|
17
|
+
*/
|
|
18
|
+
list(): Promise<Array<ConnectorId>>;
|
|
19
|
+
/**
|
|
20
|
+
* Attaches a connector to the application. Idempotent — attaching an already-attached connector is a
|
|
21
|
+
* no-op on the platform side.
|
|
22
|
+
*
|
|
23
|
+
* @param connectorId - The id of the connector to attach.
|
|
24
|
+
*/
|
|
25
|
+
connect(connectorId: ConnectorId): Promise<void>;
|
|
26
|
+
/**
|
|
27
|
+
* Detaches a connector from the application.
|
|
28
|
+
*
|
|
29
|
+
* @param connectorId - The id of the connector to detach.
|
|
30
|
+
*/
|
|
31
|
+
disconnect(connectorId: ConnectorId): Promise<void>;
|
|
32
|
+
}
|
|
@@ -17,6 +17,7 @@ export * from './client-id.service';
|
|
|
17
17
|
export * from './collection-reference';
|
|
18
18
|
export * from './collection-reference.factory';
|
|
19
19
|
export * from './connection-details';
|
|
20
|
+
export * from './connector-client';
|
|
20
21
|
export * from './console-utils';
|
|
21
22
|
export * from './data.manager';
|
|
22
23
|
export * from './destruct.manager';
|
|
@@ -11,6 +11,7 @@ export * from '../../internal-common/src/public-types/api.public-types';
|
|
|
11
11
|
export * from '../../internal-common/src/public-types/backend.public-types';
|
|
12
12
|
export * from '../../internal-common/src/public-types/code-executor.public-types';
|
|
13
13
|
export * from '../../internal-common/src/public-types/communication.public-types';
|
|
14
|
+
export * from '../../internal-common/src/public-types/connector.public-types';
|
|
14
15
|
export * from '../../internal-common/src/public-types/context.public-types';
|
|
15
16
|
export * from '../../internal-common/src/public-types/document.public-types';
|
|
16
17
|
export * from '../../internal-common/src/public-types/event.public-types';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@squidcloud/client",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.474",
|
|
4
4
|
"description": "A typescript implementation of the Squid client",
|
|
5
5
|
"main": "dist/cjs/index.js",
|
|
6
6
|
"module": "dist/esm/index.js",
|
|
@@ -53,7 +53,6 @@
|
|
|
53
53
|
"@supercharge/promise-pool": "^3.2.0",
|
|
54
54
|
"@webpack-cli/generators": "^3.0.7",
|
|
55
55
|
"copy-webpack-plugin": "^14.0.0",
|
|
56
|
-
"cpx": "^1.5.0",
|
|
57
56
|
"generate-package-json-webpack-plugin": "^2.6.0",
|
|
58
57
|
"otrie": "^1.2.2",
|
|
59
58
|
"tsconfig-paths-webpack-plugin": "^4.1.0",
|